When should I protect the circuit components?

Go To Last Post
20 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi,

I'm looking for a general rule of thumb how to protect the circuit when it's not specified.

- First case, when should I use a fuse/regulating resistors?
For example I know I should put a resistor before a led for regulating the current that it won't pull too much and burn itself.
Do I need it for ICs (AVR mC, 74XX..)?
HD44780 LCD (on the VCC should I put a 100 oHm resistor)?

How much resistance should I put?

- Second case noise. When should I use a decoupling capacitors?
How and what capacity?

Thanks..

Without the journey the reward in the end is half as sweet..
I am a newbie.
Call me Zohar.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Zohar - Two big questions.

Circuit protection first. The common practice is to protect those things that lead off-board or have external, possibly uncontrolled, voltages. For example, excessive input to ADC. Example: external supply voltage for system regulator. Sometimes RS232 I/O. There are three scenarios that people normally worry about: (1) reversed voltages (-12V on a power supply input that SHOULD be +12V), (2) excessive voltages (12V on an ADC input that should be no higher than 5V), and transients (especially electrostatic discharge - ESD) on connections that a user might accidently zap. All of this said, these things are not very often done by hobby builders, though their device reliability might be better if they did.

Current limiting resistors for LEDs CAN be sized so they do not burn out. Determine the current you want through the LED. Look up on the spec sheet to find the LED voltage drop at that current. Find the voltage drop by subtracting the LED voltage from the supply voltage. Voltage drop times current is power. Make sure the power rating for the resistor is large enough to handle at least this much power.

Decoupling caps: where you put and how much you put depends, somewhat on the construction method you use. If it is wiring such as "wire wrap" or point-point wiring, then you need a good ceramic cap close to the micro, say 0.01uf, and a larger one, say 10uf aluminum, between that and the power supply, to ground. It is pretty rare, these days, to use a cap at each peripheral chip unless the manufacturer recommends. If you use a circuit board with through-holes, then similar caps. If you use surface mount, then you might use a 0.1uf ceramic close to the micro and an aluminum or tantalum between the micro and the regulator (to ground). Be sure to use the capacitors recommended for the voltage regulator; LDOs are particularly picky on type and value. Switchers also have very definite preferred values recommended by the manufacturer.

Hope this helps
Jim

Jim Wagner Oregon Research Electronics, Consulting Div. Tangent, OR, USA http://www.orelectronics.net

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Good information Jim, thanks!

I will admit that I use ceramics at all my decoupling locations and have never worried about overcurrent but, usually know the max "I" value and size my traces/components with plenty of capacity. All of my projects so far are battery powered and I pick an LDO with around 300ma greater capacity than my circuit and place a Schottky for reverse polarity protection. I know this is probably not the best way to manage power consumption.
I did enjoy the simple explanation regarding the LED's...very easy to understand!!

John

You may only be one person in the world but, you may be the world to one person! "Life! Life, do you hear me? Give my creation LIFE!" Gene Wilder SKYPE Name: JonRobrt

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

John -

The way you determine the actual resistance of the LED current limiting resistor is this (in case there is a reader out there who does not know):

Determine the current you want to flow through the LED. Normally, you base this on the maximum current from the LED spec sheet. Depending on HOW you are operating, this may be the "maximum continuous current" or "max peak currtent".

Determine the LED voltage drop at this current from the spec sheet.

Subtract the LED voltage from the supply voltage to get the necessary voltage drop.

Divide the voltage drop by the LED current to get the resistance. If the current is stated in mA, then the resulting resistance value is in Kohms.

Jim

Jim Wagner Oregon Research Electronics, Consulting Div. Tangent, OR, USA http://www.orelectronics.net

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

zoharl wrote:
Do I need it for ICs (AVR mC, 74XX..)?
HD44780 LCD (on the VCC should I put a 100 oHm resistor)?
If you're connecting to a CMOS gate (like the IC's you referenced), they have significant capacitance but teraohms of impedance. You don't need a resistor unless the IC is "far" away. For AVR's and usually construction techniques, far is around 5 inches. If the IC is "far", for best signal integrity use a 20 ohm resistor close to the AVR pin to avoid overshooting/undershooting voltage with reflections to IC. You can also use such a resistor on a "short" connection, but is not needed.

For the LCD, no, you shouldn't put a resistor on Vcc pin anymore than you should put a resistor on the Vcc of your AVR. However, if you using the LED backlight on your LCD panel, then you will need a current limiting resistor on the LED backlighting pins (on either the + or - terminal). The advice that Jim gave you will allow you to size the resistor.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

It has been awhile since I have looked at the electrical characteristics of different caps based on their construction material so, I will have to look "back" unless Jim is in the mood to enlighten me as to why he would use one capacitor type over another for decoupling (other that the polarized electrolytics)

John

You may only be one person in the world but, you may be the world to one person! "Life! Life, do you hear me? Give my creation LIFE!" Gene Wilder SKYPE Name: JonRobrt

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Here is a try -

Electrolytics give you relatively big capacitance, but tend to be physically large. The "aluminum" variety tend to have relatively large effective series resistance (ESR) and this limits how well they work for high speed transient currents, such as those generated by modern high-speed CMOS logic or switch-mode power supplies. Aluminum electrolytic caps can be built to handle voltages up to 60V in small physical sizes. Aluminum electrolytics tend to have high temperature problems. Their life decreases as the operating temperature goes up, and it is pretty drastic above about about 50C; the numbers are often a few thousand hours at 70C, but sometimes less for certain types. Its a matter of the electrolytic material slowly boiling off.

Tantalum electrolytic caps have much lower ESR and are smaller (for a given value and voltage) but are generally not made for very high voltages (say, above 12-15V, maybe a bit more). They also have a nasty habit of shorting; this is only a temporary situation if the power supply is current limited as they will "heal" but if the current limit is not low enough, they can, and will, make copious smoke and fire and send pieces flying through the air.

Ceramic caps are generally smaller for a given C and V than corresponding electrolytic caps. They have a much lower ESR (as well as series inductance) which makes them among the base for handing high speed current transients. In the last very few years, they have broken the 10uf barrier, though they remain quite costly in comparison to the others. Even so, the large values tend to have higher series R and L than the small ones, making the old recommendation of a smaller value cap (perhaps 0.01uf) near the noise maker and a larger one a bit further away, still valid.

A useful note: for a given technology (aluminum, tantalum, ceramic, etc). there tends to be a fixed C*V limit for a given volume. That is, an aluminum cap with a rating of 10uf and 6.3V will have about the same volume as one rated for 12V and 4.7uf. In fact, for a given technology, the volume tends to be proportional to C*V. In other words, a 20uf, 6.3V ceramic will be about twice the volume of a 10uf, 6.3V ceramic made from the SAME materials. You can trade material for size, but, at least for ceramics, the materials that give the highest C*V value have MUCH worse temperature sensitivity than the other materials.

A second note: low dropout regulators and some switch-mode power supplies tend to be sensitive to ESR of caps used at certain locations in the circuit., The regulator will become unstable (and oscillate) if the ESR is too SMALL! The data sheets will tell you about this limitation but you may have to look carefully for it. For the LDOs, some will actually advertise "works with ceramic caps". Some will actually have a graph showing the range that the capacitance and ESR has to fall into.

So, there are LOTS of factors that go into the choice of a cap for a given application. Capacitance, voltage, cost, size, mounting (leads vs smt), temperature sensitivity, ESR, effective series inductance, high temperature failure rate, and more.

Hope this helps someone....

Jim

Jim Wagner Oregon Research Electronics, Consulting Div. Tangent, OR, USA http://www.orelectronics.net

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ka7ehk wrote:
for a given technology (aluminum, tantalum, ceramic, etc). there tends to be a fixed C*V limit for a given volume.
I'm sure you know this, Jim, but for those who don't: this volume equivalency comes because C*V is the charge in Coulombs which takes a certain volume for a given technology.
Quote:
low dropout regulators and some switch-mode power supplies tend to be sensitive to ESR of caps used at certain locations in the circuit., The regulator will become unstable (and oscillate) if the ESR is too SMALL!
I'm not an expert in LDO regulators, but I imagine the issue is the same if you mix a number of capacitors on your power distribution bus with low ESRs. With low ESR, you can get oscillations from the parasitic inductance mixed with the capacitance forming an LC oscillator. So, very low ESR in bypass capacitors can sometimes form such oscillator tanks. I consider favorable bypass capacitors having low inductance with a moderate ESR.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks for taking the time to write that fellas!! Very good information!!

John

You may only be one person in the world but, you may be the world to one person! "Life! Life, do you hear me? Give my creation LIFE!" Gene Wilder SKYPE Name: JonRobrt

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks for the short overview, let see if I got the practical staff right.

About the impedance.
My power supply is 5V.

1.
For a led the typical voltage is 2.2V with a max. of 15mA. Then the drop voltage is 2.8V, and it will need 2.8/0.015 = 186 Ohm resistor.

2.
As kmr verified, the lcd typical power supply is 5V, then it doesn't need anything. Although its back light is 4.2 with 170mA, which means a 0.8/0.17 Ohm resistor.

3.
ATmega32 vcc needs nothing, and the input legs on input high voltage input (except RESET AND XTAL1) also don't need anything: max = vcc + 0.5.

(Then why is it common to put a 10k resistor for a high input on a port pin?)

4.
In the following Nard's PPPD programmer:

http://www.aplomb.nl/TechStuff/PPPD/MyFinalPPPD.png

It when through a few evolutions, most of them concerning the resistors value. 330 Ohm ==> 1 kOhm ==> 1k + 2 * 330 ..
What's the deal with these magic numbers, or how do they matter?

(Can be compared to an older version:
http://www.lancos.com/e2p/betterSTK200.gif).

About the decoupling.

5.
By distinguishing between wire-wrap and through holes, you imply the routes themselves create noise?

Then although my LDO is decoupled as needed, I need to put two parallel capacitors near (how much is near?) the ATmega32 vcc?

Or is it all redundant since it's not practical to decouple every chip and the manufacturer doesn't insist on this, and kmr rule enough: I don't need capacitors, and only if the distance is larger than 5 inch a 20 Ohm resistor would be enough?

Without the journey the reward in the end is half as sweet..
I am a newbie.
Call me Zohar.

Last Edited: Fri. Jan 4, 2008 - 01:42 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:
What's the deal with these magic numbers, or how do they matter?
I tend to use a few standard values for resistors: the 1k is one of them. (10k is another favorite). It worked fine, that combination of 1k and 100 pF. But after a discussion with a fellow member (KPP), I changed it to 330 Ohm. A better choice seen from a transmission-line-Point-Of-View. And that 330 Ohm required a 330 pF capacitor as its mate to keep the cut-off-frequency the same.

Btw, the thread in the Tutorial section explains quite a bit. So you may consider reading it again with the acquired knowledge of the past few weeks.

A GIF is worth a thousend words   She is called Rosa, lives at Mint17.3 https://www.linuxmint.com/

Dragon broken ? http://aplomb.nl/TechStuff/Dragon/Dragon.html for how-to-fix tips

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:
2.
As kmr verified, the lcd typical power supply is 5V, then it doesn't need anything. Although its back light is 4.2 with 170mA, which means a 4.2/0.17 Ohm resistor.

You mean R=(5.0-4.2)V/0.17A, I suppose.

Just a quick note on backlights. If you want to read the display at night, all the backlights I have seen are way too bright at full power IMO. If you intend to control the backlight with PWM, it could make sense to calculate the resistor for max. current. But if you simply want to switch the backlight on/off I would experiment a bit in order to find a resistor value giving suitable brightness.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Right, I meant 0.8/0.17, I'll fix that.

Thanks for the back light tip, but I'm fine with the brightest.

Without the journey the reward in the end is half as sweet..
I am a newbie.
Call me Zohar.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Decoupling caps for EVERY IC!!!! nice roule :)

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

With Controllers and similar digital chips, the decoupling caps should be as close as possible to the pins. Most newer ones have the VCC/GND pins in pairs together, to get the capacitor closer. And usually every pais want one capacitor. All the decoupling capacitors may not be needed to make the circuit work, but they also help to keep radio emissions low. Even when using through hole components for the rest, it is a good idea to use SMD for the decoupling.
For use on a breadboard I sometimes even solder the decoupling cap directly on top of an DIP Package IC.

Capacitors of constant volume (and same technology) usually have a constant C*V*V and thus stored energy, except for extra low voltages or very small ones.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I believe you mean C*V, not C*V*V.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The energy-content of a capacitor is IIRC:

½*C*U²

(just want to show I can find the special characters :) :) )

Nard

A GIF is worth a thousend words   She is called Rosa, lives at Mint17.3 https://www.linuxmint.com/

Dragon broken ? http://aplomb.nl/TechStuff/Dragon/Dragon.html for how-to-fix tips

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

Determine the LED voltage drop at this current from the spec sheet.

Subtract the LED voltage from the supply voltage to get the necessary voltage drop.

Divide the voltage drop by the LED current to get the resistance. If the current is stated in mA, then the resulting resistance value is in Kohms.

I want to see if I understand the limiting resistor part right. For example if you look at This LED http://search.digikey.com/script...

It has a voltage rating of 3.4V, and a current test of 20mA. And I have a 5V power source.

So voltage drop will be 5-3.4 = 1.6V,
Now we take 1.6V/20mA = 80.

Since its in mA then it becomes 80K ohms.

That sounds really high to me...

Nothin's ever easy. But the hard part makes it all worth while.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Well, 1.6/20 is not 80. But 1.6/.02 (current is now in Amperes) is 80 so you need 80 ohms series resistance. The nearest standard value is 82 and you will never see the difference!

Jim

Jim Wagner Oregon Research Electronics, Consulting Div. Tangent, OR, USA http://www.orelectronics.net

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

yeah I noticed that right after I posted it, my bad. thanks for the help.

Nothin's ever easy. But the hard part makes it all worth while.