News for hackers. Stuff that matters.
Re:Chemists discover how blue light speeds blindness by priccis on Thursday August 09, 2018 @12:59PM (#17725999)
I'm sorry I can't help you, but after reading an article posted here about melatonin I got interested in light therapy, but commercial devices are a bit expensive. Are you documenting your project?
Re:Chemists discover how blue light speeds blindness by mafuyu on Thursday August 09, 2018 @01:28PM (#17726346)
Sure, it's not the most exciting project, but I might do a short writeup when I'm done.

I originally purchased these nice LED strip bars with enclosure in blue[0], but after reading this site by the manufacturers of a commercial green therapy light[1], I was convinced to switch to turquoise/cyan.

Turquoise isn't that popular so I wasn't able to find any strips/bars, and I got these individual 3W bead LED modules instead.[2]

For the Hue integration, I'm using a Mesh Bee + UartSBee v5[3] with firmware from PeeVeeOne[4]. It outputs PWM, and I'm hooking it up to a cheapo constant current LED driver I got from Aliexpress. Since all the LEDs need to be in series for a constant current driver, I'm probably looking at a ~20V power supply to power the whole thing.

My bedframe has a headboard, so I'm planning on 3D printing some mounts that clamp on top.

[0]: https://www.ebay.com/itm/50CM-U-Aluminium-shell-DC-12V-36-SM...

[1]: http://www.sunnexbiotech.com/blue%20vs%20green%20light.html

[2]: https://www.aliexpress.com/item/10-pcs-3W-Turquoise-Cyan-LED...

[3a]: https://www.seeedstudio.com/Mesh-Bee-Open-Source-Zigbee-Pro-...

[3b]: https://www.seeedstudio.com/UartSBee-V5-p-1752.html

[4]: https://peeveeone.com/?page_id=252

Re:Chemists discover how blue light speeds blindness by bb88 on Thursday August 09, 2018 @06:24PM (#17729080)
So those cyan LED's have a forward voltage drop of 3.2-3.6 volts. So you'd be looking at a 32V-36V 350ma power supply or thereabouts to hook them up in series.

If it were me, I'd probably run everything in parallel just to keep the voltages lower, and be able to use readily available power adapters.

Aliexpress has a PWM controlled constant current driver that takes 5-35V in and outputs 350ma max [1]. 10 of them are $20, so they're not too expensive.

At a forward voltage of 3.3V for the LED's, you'd be looking at slightly more than 1W per LED at 350ma (P = VI).

Those constant current supplies probably have an efficiency of maybe 66%, taking that into consideration, I would think a 12V 2A power supply would be enough to drive the entire thing. And that could be a wall wart that you get at the local hardware store.

[1] https://www.aliexpress.com/store/product/10PCS-A58B-1W-LED-D...

Re:Chemists discover how blue light speeds blindness by mafuyu on Thursday August 09, 2018 @07:34PM (#17729488)
Just tested with my power supply, and the minimum V_on seems to be about 2.7V. So if I want to drive all 10 in series, I'll need 30V+. If I had three banks in a 4,3,3 configuration, I could get away with a 12V power supply as well, which would be nice since I already have a bunch of 12V 5A wall warts.

I already got the board you linked, supposedly configured for 700 mA. Haven't tested yet. The datasheet for the part says it can go up to 2A[0], so I could potentially modify the feedback circuit for 1A, which would reach the full 3W rating of the LEDs.

One issue with that driver chip is that the PWM/enable is active low, so I think I may just stick an inverter on the output of the Mesh Bee. The SDK for the NXP part has changed since the ZLL repo was updated, and I haven't had much luck getting it to compile myself.

[0]: http://www.xlsemi.com/datasheet/XL4001%20datasheet.pdf

Re:Chemists discover how blue light speeds blindness by therein on Friday August 10, 2018 @01:13AM (#17730851)
Why do you want to drive the 10 LEDs in series?
Re:Chemists discover how blue light speeds blindness by bb88 on Friday August 10, 2018 @01:08AM (#17730826)
So note the I/V curve on the diode [3]. The minimum on at 2.7V is probably going to be the "knee" voltage. Sending 1A through the led will be a higher voltage.

The easiest way to test it is to get a multimeter, and put 1A through the led, then measure the voltage across the diode, and that will be the voltage you're targeting. (or you can just use one of the 700ma current regulators for a good estimate, placing the enable to ground.)

Also keep in mind that those current regulators are buck converters and they're not 100% efficient (no regulator is, really). So you're going to want to add 20-30% more power at a minimum on top of the load you're planning on driving with it.

And if you're going to drive 12V of LED's, expect to need 15-18V to drive the buck converter. That's because of the way buck converters work.

The feedback voltage on that chip is a fixed 1.2V and that's used as an internal voltage reference (I guess because they didn't add one into the chip).

They have a circuit diagram for that part, and it looks like CS and Rcs are the most important things on that sheet. CS is the "Current Sense" that measures the voltage across the current sense resistor (Rcs). They give the formula for Calculating Rcs to get to 1A (ILED = 0.155 / Rcs), and I get .15 ohm for Rcs at 1A.

Then you can either replace it with another sense resistor with something like this [2], or an appropriate length of copper wire [1] to give you the correct resistance.

As far as the PWM/enable inversion goes, just invert it in software. 100% full duty cycle would be off and 0% would be on. If you have a Raspberry PI laying around you can easily set one of the pins to PWM to test out your inverter code [4].

I'm going down a similar path to build a UV light box for exposing PCB's and the like.

Best of luck!

[1] http://hyperphysics.phy-astr.gsu.edu/hbase/Tables/wirega.htm...

[2] https://www.mouser.com/ProductDetail/Bourns/CRM2512-FX-R150E...

[3] https://www.electronics-tutorials.ws/blog/i-v-characteristic...

[4] https://circuitdigest.com/microcontroller-projects/raspberry...

Re:Chemists discover how blue light speeds blindness by fpgaminer on Thursday August 09, 2018 @01:42PM (#17726500)
You're a hero; thank you for posting details.
Re:Chemists discover how blue light speeds blindness by justinc8687 on Thursday August 09, 2018 @03:09PM (#17727428)
I would be very interested to see a write up of what you are doing here as I have a similar problem. Any chance you could share one if you create one? Email in my profile.
Re:Chemists discover how blue light speeds blindness by mafuyu on Thursday August 09, 2018 @03:16PM (#17727493)
Yep, will do!