Am I GUARANTEED not to ruin arduino circuit if I use this trick???????

Thread Starter

cjthatdj

Joined Jul 5, 2020
9
Hello I have an arduino uno which outputs 5 volts and recommends a maximum current of 20mA
If I use a 250ohm resistor in series with any circuit am I GUARANTEED not to blow the arduino uno because V = IR and (V / R) = I and
(5 / R) < 20mA therefore R needs to be greater than 250ohms and then I am GUARANTEED not to go over 20mA

Is this a correct assumption or am I way off here?
 
Last edited by a moderator:

Thread Starter

cjthatdj

Joined Jul 5, 2020
9
Sorry I do not know how to edit this post but I made a huge mistake and said "parallel" in the post instead of in series.

Mod: Edited for you.E
 
Last edited by a moderator:

geekoftheweek

Joined Oct 6, 2013
1,216
Sort of... The resistor needs to be in series which will drop voltage also so it depends on what you are powering. It will limit to 20mA, but your connected device may not get enough volts to work. A polyfuse or constant current device like microchip's cl2.
 

Thread Starter

cjthatdj

Joined Jul 5, 2020
9
Sort of... The resistor needs to be in series which will drop voltage also so it depends on what you are powering. It will limit to 20mA, but your connected device may not get enough volts to work. A polyfuse or constant current device like microchip's cl2.
My connected device may not get enough volts to work or it may not get enough current to work?
 

LesJones

Joined Jan 8, 2017
4,190
It is not a valid assumption. Assuming that you mean that you are connecting the 250 ohm resistor between an output pin and either ground or + 5 volts then it means that the resistor is loading the output up to it's maximum rating. You can do things to reduce the risk of damaging the outputs to deal with specific possible situations but I don't think there is a way to protect against all possible situations. Even just to protect a pin from a direct connection to the mains would probably cost more than the Arduino.

Les.
 

Thread Starter

cjthatdj

Joined Jul 5, 2020
9
It is not a valid assumption. Assuming that you mean that you are connecting the 250 ohm resistor between an output pin and either ground or + 5 volts then it means that the resistor is loading the output up to it's maximum rating. You can do things to reduce the risk of damaging the outputs to deal with specific possible situations but I don't think there is a way to protect against all possible situations. Even just to protect a pin from a direct connection to the mains would probably cost more than the Arduino.

Les.
I meant to say that if I put a resistor in series with the output pin and my circuit. I know that I am going to have a voltage drop due to the resistor which may limit the amount of things I can use with my circuit, but will this at least guarantee to protect the arduino
 

jpanhalt

Joined Jan 18, 2008
11,087
Yes, that provides protection. When building analog and discrete circuits, I may put a 100 Ω resistor in series with the power (VCC) rail. Same theory. Something (e.g., a short) might get warm but not blow. Tantalum caps might be an exception.

The question is whether you need it. Are Arduino outputs protected against shorts? Are they protected from very short periods of overcurrent, e.g., charging the gate of a mosfet? You also might consider a lower value resistor, such as 100 Ω.

As for your second worry about not having enough power for whatever is being driven, I would handle that on a case by case basis. Also, I would use the resistor as a safety device for when you first turn the circuit on. In a final design, there is probably little need for it, except in situations like charging a large capacitance.
 

Thread Starter

cjthatdj

Joined Jul 5, 2020
9
Yes, that provides protection. When building analog and discrete circuits, I may put a 100 Ω resistor in series with the power (VCC) rail. Same theory. Something (e.g., a short) might get warm but not blow. Tantalum caps might be an exception.

The question is whether you need it. Are Arduino outputs protected against shorts? Are they protected from very short periods of overcurrent, e.g., charging the gate of a mosfet? You also might consider a lower value resistor, such as 100 Ω.

As for your second worry about not having enough power for whatever is being driven, I would handle that on a case by case basis. Also, I would use the resistor as a safety device for when you first turn the circuit on. In a final design, there is probably little need for it, except in situations like charging a large capacitance.
I am not sure about if arduino outputs are protected against shorts, I'll have to look into that.

Okay that sounds good, thanks for the response
 

Irving

Joined Jan 30, 2016
3,885
The Arduino outputs are not protected against shorts but, having said that, we use them in a teaching lab where shorts to ground are expected and common and we've not lost an Arduino that way yet!

But if you're worried, connect your external circuit via a 30mA resettable PTC fuse (about 25p/30c each in 10s on eBay).
 

Deleted member 115935

Joined Dec 31, 1969
0
Protecting a CPU circuit is a short question, long answer.

There are rugged arduinos around,
https://www.rugged-circuits.com/

look at the lengths they go to. they publish details.

It really depends what you trying to protect against.
If its a 5v arduino, and you want to protect against shorts to 5v or 0v, then a PTC or a resistor is a good idea.
The down side is the resistance you add forms a RC low pass filter with the capacitance on any wires / pins.
slowing down the edges,. Unlikely to be a problem, but just be aware.

If you want to protect against say mains or 50 volts being conencted to the pin, then that more of a dificult quesiont,
things like opto isolation are then called for,

One other thign,

you say GARUNTEE,

IMHO, their is no such things as a full proof IO.
over the decades I have seen so many ways of blowing up IO,
one example. company spent fortune purchasing a Big CNC system, .
they then promptly wired all the 24 V digital IO direct to the 415V mains
 
Last edited by a moderator:

BobTPH

Joined Jun 5, 2013
8,961
One example of why you cannot do that: If the pin is connected to the gate of a high current MOSFET that needs to switch fast, the resistor will slow down the switching way too much.

Bob
 

Irving

Joined Jan 30, 2016
3,885
True, but thats fairly specialised and while possible, I'd probably use a gate driver for additional protection, especially if its doing high votage/high current.
 

KeithWalker

Joined Jul 10, 2017
3,092
Why are you so concerned about finding a universal protection system for arduino outputs? You really don't need it. All you need to do if you are designing your own circuits to drive with the arduino is to make sure that they do not draw more current the the specified maximum. Commercially availble devices that are recommended for use with the arduino are designed that way.
Regards,
Keith
 

dl324

Joined Mar 30, 2015
16,918
If I use a 250ohm resistor in series with any circuit am I GUARANTEED not to blow the arduino uno
No. A better solution is to pay attention to what you're doing.

As others have noted, you need to observe maximum power dissipation by the microcontroller.
 

geekoftheweek

Joined Oct 6, 2013
1,216
Why are you so concerned about finding a universal protection system for arduino outputs? You really don't need it. All you need to do if you are designing your own circuits to drive with the arduino is to make sure that they do not draw more current the the specified maximum. Commercially availble devices that are recommended for use with the arduino are designed that way.
Regards,
Keith

I'd venture a guess to say to prevent accidents. I'm sure I'm not the only one who has deformed bread board holes... Luckily I've stuck with PICs and lately the under two dollar versions have done everything I want to do with them.
 
Top