0
\$\begingroup\$

I'm using a Hobby King remote and 2.4ghz receiver to control an animatronic head. I'd like to enhance things a bit by putting a 5V SMD LED (ws2812b type) in each eye. Each channel of the receiver has 3 pins: ground, Vin and PWM. I get plenty of power to light the LED, but I'd like to use the PWM info (ideally without a microcontroller) to determine how bright the LED is. Depending on the position of the transmitter's potentiometer, the output voltage on the PWM is between .13 and .36.

Simply put, when the servo for the eyelids are in a closed position, I'd like the LEDs to be off or super dim, but when they are open, I want them to brighten up, all menacing like. Is there a simple circuit to facilitate this, maybe using a transistor or 555 timer? Or am I gonna need to use a 'duino to read in the PWM and pass it back out to light them up.

\$\endgroup\$
0

1 Answer 1

0
\$\begingroup\$

This could be done with a 555 timer, somehow, with a few hundred dollars of testing and man hours and expertise. Maybe. Or you can use any common microcontroller, for a few cents, and a lot less headache. You could use a pic10f, a 6 pin ic that many manufacturers have used to do exactly what you plan.

enter image description here

Of course, that's a simple RC to ON-OFF type switch. That would be simple for a 555 timer type setup, maybe. But your needs are much more complex. You need to program the PWM reading because you want to adjust the brightness, and then program the output for the ws2812b protocol. It is a smart led, and needs a fairly complex protocol and timings to work.

An arduino would work. A ATtiny would be small and simple. Not many passives needed. Decoupling caps pretty much it.

\$\endgroup\$
2
  • \$\begingroup\$ Fair enough. I didn't think using a dedicated microcontroller was worth it just to hook up a couple of LEDs. Would it make a difference to swap out the ws2812bs with just a plain old red LED? Is there a sort of if/then circuit (i.e. a transistor) to turn it on and off based on the low voltage of the PWM signal? \$\endgroup\$ Commented Sep 22, 2016 at 6:24
  • \$\begingroup\$ Maybe. The voltage levels you mention are too low without an opamp. A common transistor wouldn't work well as its under its VBE. But the readings are false. Averages of the actual pwm by your multimeter. It's probably higher voltage, with a different period for full on and full off or center. You could try with a simple 2n3904 and a single 5mm 20mA led and resistor. You may see a difference when "off" and "on", more like dim and less dim, maybe medium to high brightness. \$\endgroup\$
    – Passerby
    Commented Sep 24, 2016 at 3:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.