I was talking with a friend a couple days ago about project that I am working on, and he is helping me to understand the electronic components that I will be adding to the system.
One of the questions that he asked me is what is the margin of safety on the 3.3V GPIO pins. For example, he had recommended using a 3.3V zener diode to cap some of the input voltages where there might be issues or a Schottky diode.
The zener diode that I am looking at is rated at 3.3V, but that is typical, and it has a max rating of 3.465V. As example of tolerances that the Arduino has to be built with, USB power is set at 5 V, but tolerances say that USB power can ± 5% (i.e., 4.75V to 5.25V). I'm just wondering if this zener diode is within the margin of safety of the Arduino Giga GPIO pins.
A 5 psi pressure sensor that is 5V (with 0.5-4.5V for the signal), but I need to read pressure only from 0–2.3 psi. If I don't use a voltage divider to bring the signal down from 5V to 3.3V (i.e., a signal from 0.33–2.97V), I can read up to 3.5 psi (i.e., a voltage from 0.5–3.3), which will allow me to better discriminate the pressure in that range. I don't expect to see pressures in excess of this, so I am fine with clamping the voltage at 3.3V to protect the circuit.
It's not the voltage that destroys GPIOs but the current. Limiting the current is key to protecting the GPIO. I’m not sure which board you’re using, but if you check the datasheet for the processor, it will specify the safe current limits.
As a general rule, I aim to stay below 10mA and prefer to keep it under 1mA if possible. For example, using a 10k resistor allows up to 0.17mA into the pin, which should be safe. However, be cautious of stray wiring or other factors that could introduce additional noise into the circuit.
Be careful that you do not push more current then the circuit is using else it will cause the voltage to rise.