Input Protection - Long Ground Wire, multiple switches

Hi all,

I was going to tag this onto the end of another thread but I think it's actually a bit of a different question. I started by reading this document: https://www.digikey.com/en/articles/protecting-inputs-in-digital-electronics

I understand what's going on, and it seems that voltage spikes can come from long wires, particularly in an Automotive environment. I have one instance on a board design, where I want to read several switches from an indicator and wiper stalk in a car, and they all switch to ground. The switches will only be a few cm from the Teensy Arduino I intend to read them with, but the ground path to the battery will obviously be much longer, so I guess any voltage spikes are likely to come from further down the path. Since I have 13 input, I want to try to avoid placing 13 optocouplers and resistors on my small PCB, so I was wondering whether I could be a bit smart and put the spike protection on the ground side, like I show below and thereby using just the one schottky diode. Could this work? I guess I may still need to add a small cap on each input, perhaps 100nF?

5

I can see a couple different levels of protection. Automotive is an ugly environment.

First question: In the Teensy ground and the stalk ground at the same location?

You definitely need a cap on each input at the Teensy.
You would do well to add a resistor from each input to +V to up the current making it more difficult for noise to be "picked up" on your inputs.

Let me know how "bullet proof" you wish to be.

Thanks JohnRob! Yes, I would ground them on the same ground line since they'll be right beside each other.

Ok, so you think better to run like this:

5

What kind of value would I need for the resistor if the cap was 100nF? Would I still need the schottky or could I bin that? I'm trying to keep the components to a minimum since there are many inputs - do you think this would work well enough or more protection needed?

Yes but:

  1. the BATxxxx is not gaining you anything. To be useful there would have to be one on each input.

  2. If you run the external pull up resistor to a higher local voltage 5V? and have a divider to the Teensy and cap you would have more noise rejection.

  3. The external resistor should draw a couple of ma when grounded.

Ok so this would work ok..?

5

I had been using 0805 sized components, but I'm going to need to add 52 components to make this work which is going to push the board size. Is there a realistic min case size I can use here? What kind of wattage would I need for the resistors to be safe?

50mA ones look nice and tiny... ! 0201 case size: https://my.mouser.com/ProductDetail/Panasonic/ERJ-1GNF4701C?qs=nuXzIS8loXGfExYPqsk5mg%3D%3D

Wattage is not an issue. The 1k to 5v dissipates: 5*5/1000 = 0.025Watts

Size has no effect of function.

What will make a difference is the physical layout. You must keep the input lines away from the Teensy input of another input. Said differently, the inputs should enter the board at one location, to through the 4.7k then the 100nf.

1 Like