1

i made a project with arduino in wich I used arduino to activate 18 n-ch mosfet with PWM. I used the softPWM library to use PWM in 18 output pins, I used a nano v3.

The question is about the maximum current a single pin (and a group) can handle. A raw info can be found here http://www.pighixxx.com/test/wp-content/uploads/2014/11/nano.png and it's a 20mA/pin and 200mA/group but it's not explained if that current is a peak current or an average current.

Increasing the load resistor will case a smaller peak current but will increase the time in wich the mosfet is resistive (hence it will heat up the mosfet). Considering that the pwm frequency is lower than the one defined by the resistor-mosfet, the average drained current is related to the PWM frequency and to the mosfet capacitor (NOT to the load resistor).

Is the current defined as maximum peak current or as continuous current (and which is a typical peak time for the CPU)?

Mr google gives me different and contradictory informations, i found people that uses PWM without load resistors and people that limit the peak current to 20mA. In my project i limited the maximum current to 50mA so I'm sure to have the worst performance i can have keeping the risk of burning my small friend.

Thanks

  • What is the PWM frequency? If it's quite small, you can afford that, for a certain amount of time, the MOSFET is not fully ON/OFF. – next-hack Sep 6 '17 at 16:17
  • I set a 250Hz frequency to trimmer leds and a 256 resolution hence the load must be faster than 15us. I used an IRLZ44N (1700pF) that with a resistor of 100ohm means a tau=1.7E-7s that is 90times less than the previous one. If I use a 330ohm resistor the value is 26times less. Note that 250Hz is the minimum to avoid flickering – brazoayeye Sep 6 '17 at 16:55
  • If we were talking about DACs, a DNL error <1/4 LSB would be good for many applications. We can use a similar thinking here. You want the turn-on+turn-off faster than 15us. Let's suppose 4 times faster (similar error of the DAC example). So you can increase the resistors accordingly. The problem is, the slower the transition, the larger the power dissipated. Even if half the LED power were dissipated on the MOSFETs during the 15/4 us transition, the average power dissipation on the MOSFET would be 1/2048 of that of the LED (+Ron*I^2). It's up to you to decide if it's acceptable. – next-hack Sep 6 '17 at 17:13
  • if you're using mosfets, the supply capability of the gpio isn't important. you would still have actual spikes of 50, but the accumulated heat would be that of only 20ma on avg – dandavis Sep 6 '17 at 18:36
  • @dandavis That's the point of the question: could i have a spike of 200mA to charge the 1700pF or not? Higher the current shorter the time, if it's all related to heating the resistor should not matter. But is it true? Can i load a 8uF capacitor with a 250Hz PWM? (8uF -> 40uC -> 0.02C/s -> 20mA) – brazoayeye Sep 7 '17 at 10:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.