hello everyone will see I have an arduino one which is connected to an ups so that when the power goes out it stays on.
What I want to do is for the Arduino to detect that drop in energy. I have thought about placing a cable to pin 3 (for example) which injects the arduino 5v of current from an external source so that when the power is cut the pin stops receiving those 5v ... does anyone know if this is possible? and how should it be done to read if on the pin I am receiving energy.
Thanks!
in summary: I need to detect a cut of energy by arduino. any concrete idea is welcome!
Why not take a inexpensive wall wart (charger), divide the voltage so it is safe for your arduino and connect that divided voltage to a port pin. I do this type of thing a lot. There is one gotcha the wall wart probably has a capacitor so you will have to add a load to cause it to discharge, since you are not interested in speed a LED would work just fine. This response is to help you get started in solving your problem, not solve it for you.
Good Luck & Have Fun!
Gil
1)Your system to keep working when there's no power. You probably need a battery to hold your arduino up
2)You probably need to send the signal "POWER OUT!!" somewhere, but make sure it can be sent with no power (so if your UPS powers the Wifi router, you need al alternate way)
3)You need a pin that monitors the power supply. Yes a cheap 5V USB charger can be used and will be cheaper than other more specific solutions like an opto+resistor+capacitor. Just provide thos 5V to any digital IO pin and monitor when it goes LOW