pi pwm circuit

General project help for Adafruit customers

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
cmitcham
 
Posts: 2
Joined: Tue Nov 29, 2022 12:18 pm

pi pwm circuit

Post by cmitcham »

relay-driver.jpg
relay-driver.jpg (14.11 KiB) Viewed 65 times
another newbie :)

will the circuit in mike's picture above switch fast enough to use on a pi pwm pin? i need to dim a cheap string of leds. and (if so) i'm guessing with a led load, i wont need the protection diode?

thanks!

User avatar
dastels
 
Posts: 15653
Joined: Tue Oct 20, 2015 3:22 pm

Re: pi pwm circuit

Post by dastels »

So... not that circuit?

Relays are way too slow to PWM. What LEDs are you using?

Have a look at https://learn.adafruit.com/transistors-101/example-uses. In that example I PWM a 12v LED strip to control brightness which sounds like what you want to do.

Dave

User avatar
adafruit_support_mike
 
Posts: 67446
Joined: Thu Feb 11, 2010 2:51 pm

Re: pi pwm circuit

Post by adafruit_support_mike »

cmitcham wrote: Tue Nov 29, 2022 12:25 pm will the circuit in mike's picture above switch fast enough to use on a pi pwm pin?
Easily.

BJTs usually start to have trouble around 300MHz (meaning you have a specific need for the ones that operate into the gigahertz range), and power mosfets can handle 1MHz without too much trouble.

That said, Dave's right: most of a relay driver circuit is unnecessary for what you want to do. A simple power mosfet switch will be fine.

User avatar
cmitcham
 
Posts: 2
Joined: Tue Nov 29, 2022 12:18 pm

Re: pi pwm circuit

Post by cmitcham »

thanks!

Locked
Please be positive and constructive with your questions and comments.

Return to “General Project help”