Hello
I'm driving a LED through PWM port of an arduino pro mini 328
I'm really limit on the max amp that the 328 can drive : 40mA
after few minutes , the 328 over heat and ,don't manage to work properly .
I would like to use a transistor to drive my led and ,save my arduino board .
My trouble is that , with a PNP transistor ,the led is always on .
Any idea of what I can do to keep the PWM effect , using a transistor to drive more amp ?
Why are you holding back on us.
We can’t help unless we know what you have. Without knowing what you are doing we can’t tell what you are doing wrong.
Now what LEDs do you have, post a link to their data sheet or where you got them from.
Post a schematic of how you wired them up.
I'm really limit on the max amp that the 328 can drive : 40mA
No it hasn’t, 40mA is where damage started being done to a pin. So what makes you think this is the limit for the whole processor?
Thanks for your reply .
led using 5v , works perfectly with PWM is I reduce a little bit the voltage to save some mA ...
PWM does not reduce the peak voltage or current so things can STILL get damaged. [u]PWM[/u] reduces the average voltage & current and it makes the LED appear to dim.
Standard practice is to use a current-limiting resistor in series with the LED. Even if the LED is rated for 40mA, it needs a resistor (or something) to limit/control the current.
...At this point, I'm betting you have a regular-everyday LED and all you need is a ~220 Ohm series resistor.
I don't talk of limit of the whole processor , but by pin . it takes 40mA @5v , so too high for my pin . that's why I would like to pass through a transistor ,
But , my solution is maybe to use a MOSFET instead of a PNP transistor ? !
DVDdoug:
PWM does not reduce the peak voltage or current so things can STILL get damaged. [u]PWM[/u] reduces the average voltage & current and it makes the LED appear to dim.
Standard practice is to use a current-limiting resistor in series with the LED. Even if the LED is rated for 40mA, it needs a resistor (or something) to limit/control the current.
I don't use it to reduce the current , but , to dim the LED , no problem for that .
I connect the LED to a different power source ,and , if I reduce the voltage ,the LED takes less mA for example 20mA @ 4v ... and like that the arduino works well .
A simple Google of PNP high side switch or PNP Arduino should get you going. That or use low side switching and an NPN a Google of Low Side Switching NPN or Arduino NPN should get you going.