Protecting inputs when powered down

Jan 19, 2024 Last reply: 2 years ago 4 Replies

When you power down a Pi is there any simple way to protect inputs which are being driven by externally powered equipment?



I have A2D devices on the I2C bus which are powered from the Pi, if the Pi has power removed the A2D's will be unhappy I think as their inputs will still have the voltages they are measuring applied to them.



Similarly I may have one or two logic inputs which are driven by external signals (to see if things are turned on for example) and these inputs will still be there (at 3.3v logic levels) when the Pi is powered down.



Would diode clamps to the Pi's 3.3v supply be OK or are there better ways?


??? If they are powered from the pi, how can they still have voltage? ?? if they are on the I2C bus, how are they connected to the A2D inputs on the Pi?

I suspect those already exist internally. It is more relevant to prevent those getting smacked with high current.

a small resistor would limit any current

If the external signals are strong enough to feed a pull-up that's low enough in value to be fast enough, one way is to feed the external signal into the emitter of an NPN bipolar transistor, with a pull-up from the collector to the Pi's 3.3V supply, and a pull-up from the base of something like 20 times the resistance, also to the Pi's 3.3V supply.

It's unusual, but it's just a common-base saturated level shifter.

David

They are ADs1116 I2C devices on the I2C bus. Their VDD suppy comes from the Pi, their inputs come from whataver they are measuring which doesn't get turned off whe n the Pi is turned off.

Yes, the ADS1115 has internal diode clamps but it does say in the datasheet that external Schottky diode clamps are recommended.

That's an idea, thank you, for logic inputs it'll be fine.

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required