Pin protection (yes, another thread)

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

I hope you don't mind me asking about this, I know there are other threads, and I did read through them, but I want to be sure I understand.

 

I have a UART open to the "outside world" (usually those cheap USB-UART cables from aliexpress).  They run at 3.3V, and will feed this 3.3V to RX (and some to TX) when my board is shut down.

 

Currently I have 1k resistors in series with TX and RX, to limit current, but perhaps that won't be quite enough.  It shows around 1V on the pins (when shut down), which is over the 0.5V limit.  4.7k might be better as long as it doesn't interfere with bit rate (57600).  The internal diodes are supposedly good to 1mA, so 4.7k qualifies, but 1k does not.

 

I haven't added any caps yet (from uart pins to gnd), should I?

 

Should I bother with a regular or TVS diodes as well, for fear of esd?  Or is the 4.7k enough protection?

 

As usual: "What else do people normally do"?  I think protecting against 3.3V applied to these pins (maybe 5V) and ESD when the system is off would be sufficient.

 

This topic has a solution.
Last Edited: Wed. Aug 19, 2020 - 02:14 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

jrs454 wrote:
I haven't added any caps yet (from uart pins to gnd), should I?
Yes plus another resistor (R-C-R) in addition to the AVR's Schmitt-trigger input (restores edge speed)  Time constant at AVR approximate to ESD time constant (150ns)

jrs454 wrote:
Should I bother with a regular or TVS diodes as well, for fear of esd?
(consider concern in-lieu of fear) Such would be more than good enough (R-TVS-R)

jrs454 wrote:
Or is the 4.7k enough protection?
for ESD tolerance, about half that.

jrs454 wrote:
"What else do people normally do"?
Depends on surge's energy (ESD, EFT, lightning)

 


Protecting Inputs from Damage— EOS - The Signal - Archives - TI E2E support forums

Engineer It - How to prevent electrical overstress of analog integrated circuits - YouTube (9m29s, Texas Instruments)

AN_1619 AVR040: EMC Design Considerations

The Art of Electronics 3rd Edition | by Horowitz and Hill

[pages 804 and 805]

12.1.5 Input protection

 

"Dare to be naïve." - Buckminster Fuller

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

How fast?  

 

Higher ohms limit speed due to capacitance (slower rise/fall times).  Really, your best bet is to use some of the ESD chips made for this purpose.  Note ESD is not the same as a steady overvoltage or reverse voltage  (may depend upon the protective chip, how it handles that).

Say you accidentally tie the input to 12V.

 

In extreme situations, optoisolators keep the  AVR safe.

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

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

Thanks!  Looks like 2.2k-C-D,D-200 or so is the most reasonably comprehensive layout.  I'll probably use some regular diodes instead of TVS specific to protect against someone leaving 5V or whatever plugged in all the time.  I have a dual diode package SDMG0340LS I'm using elsewhere so maybe that will be sufficient.?

 

I don't need to protect from anything severe, just regular "office" usage with reasonable diligence.

 

Dumb question - I assume the same applies to the output pin?

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

avrcandies wrote:

How fast?  

 

Higher ohms limit speed due to capacitance (slower rise/fall times).  Really, your best bet is to use some of the ESD chips made for this purpose.  Note ESD is not the same as a steady overvoltage or reverse voltage  (may depend upon the protective chip, how it handles that).

Say you accidentally tie the input to 12V.

 

In extreme situations, optoisolators keep the  AVR safe.

 

Thanks for responding!  Only bothering with 57600 for now but maybe 115k eventually.  Nothing crazy.  I'd need to guard against steady voltage (5V is enough I think) and ESD.

This reply has been marked as the solution. 
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0


jrs454 wrote:
... 2.2k-C-D,D-200 ...
With current steering diodes, the impedance can be greatly reduced (increased edge speed) though do see your point about 5V; most of the excess current will be through the steering diode so do clamp VCC (most voltage regulators aren't two-quadrant, iow current source and sink)

jrs454 wrote:
... regular diodes instead of TVS specific ...
Jellybean 4148, or such, are good enough for common current steering.

jrs454 wrote:
I have a dual diode package SDMG0340LS I'm using elsewhere so maybe that will be sufficient.?
Yes (dual Schottky, leakage appears to be acceptable other than for megaAVR ADC max source resistance (10K ohms), 30mAdc max, 200mA peak)

jrs454 wrote:
Dumb question - ...
not

jrs454 wrote:
I assume the same applies to the output pin?
Depends on where that output goes.

AVR don't have an ESD spec though very likely meet CDM; "tiny" logic is somewhat common and these have an ESD spec (ie buffer)

Bipolar transistors are ESD rugged; base bias is a current divider (increases AVR ESD tolerance)

 


SDMG0340LS (Schottky (Less than .5A)) (Diodes)

CDM - Charged-Device Model

 

edit : absolute maximum

AVR DA-series absolute maximum clamp current is +/- 20mA.

in AVR128DA Preliminary Data Sheet (page 560) via AVR128DA28 - 8-bit AVR Microcontrollers

wow

 

"Dare to be naïve." - Buckminster Fuller

Last Edited: Wed. Aug 19, 2020 - 02:14 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

jrs454 wrote:
... just regular "office" usage ...
Damaged gateway in a house office due to a close lightning strike.

"Dare to be naïve." - Buckminster Fuller

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

You could always embed the USB-UART converter and then use specific USB line ESD protection devices such as PRTR5V0U2X.

This way your device can control when the idle signals are present at the uC by powering the USB-UART peripheral.

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

By the time you have put that many passive components on the board you may as well drop a couple of optos on their instead.

#1 Hardware Problem? https://www.avrfreaks.net/forum/...

#2 Hardware Problem? Read AVR042.

#3 All grounds are not created equal

#4 Have you proved your chip is running at xxMHz?

#5 "If you think you need floating point to solve the problem then you don't understand the problem. If you really do need floating point then you have a problem you do not understand."

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

Excellent, thanks. The output goes to the same cheapo USB-UART connector, ideally, or some similar customer-made UART.  Probably to play it reasonably safe I can do the same R-C-D,D-R chain, or maybe just a (ATMEGA)-D,D-R?  The R would protect the diodes against overcurrent if someone hooked up 5V, and the diodes would protect against ESD and overvoltage to the microcontroller pin if someone hooked up an output to it accidentally.

Last Edited: Wed. Aug 19, 2020 - 02:19 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You're welcome.

jrs454 wrote:
... or maybe just a (ATMEGA)-D,D-R?
A current divider between the TVS and AVR ESD suppressors; do add some resistance between the TVS and AVR (value dependent on TVS, time constant at AVR is 3ns with complete EOS suppression)

 


though this TVS is a SCR, it's reduced leakage than jellybean TVS :

ESD and Transient Protection Using the SP720 | Littelfuse AN9304.4

[page 8, bottom of right column]

Range of Capability

[second paragraph]

...

However, even a few ohms of resistance can substantially improve ESD protection levels.

...

due to AD converter input protection | AVR Freaks

 

"Dare to be naïve." - Buckminster Fuller

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

Great, for the output I'll probably just use the same dual diode as above and add resistance on both ends, I think that should work well.  I can allow a much longer time constant for this modest bitrate.  No AD in this circuit.