I want my raspberry pi to keep running even when the power goes out. I have a large deep cycle 12v battery that will power the pi, and my backup sump pump when the power is out. I power the pi + it's additional sensors with a single 12v feed. From there I power my 12v sensors, and power a buck converter to power the pi through the 5v pin.
My plan was to always power the pi from the marine battery, and keep a charger on the battery to make sure it doesn't discharge. But I think what I am running into is the parasitic drain of the pi is causing my chargers (I've tried 3) to over charge the battery (almost to 15v in one case).
So new plan - run the pi from a 12v power supply, and somehow automatically switch over to the battery when the power goes out. I see they sell circuit boards that do this on ebay, here's one for $3.35. I wonder if the relay switching delay might ever cause the pi to reboot though?
Could I solve this problem with diodes? The 12v/pi system (my pi + sensors) draws less than 1A. Could I put a diode on the positive lines of both the battery and the power supply? My buck converter is not picky about it's input voltage, and my 12v sensor is not either. So the diode should prevent the power supply from charging the battery. But will the 12v/pi system draw power from both the power supply and the battery at the same time? That defeats the purpose. If I made the power supply always higher than the battery voltage (say 15v), then would that prevent current from flowing from the battery into the 12v/pi circuit?
Thanks.
Here is a rough diagram
My plan was to always power the pi from the marine battery, and keep a charger on the battery to make sure it doesn't discharge. But I think what I am running into is the parasitic drain of the pi is causing my chargers (I've tried 3) to over charge the battery (almost to 15v in one case).
So new plan - run the pi from a 12v power supply, and somehow automatically switch over to the battery when the power goes out. I see they sell circuit boards that do this on ebay, here's one for $3.35. I wonder if the relay switching delay might ever cause the pi to reboot though?
Could I solve this problem with diodes? The 12v/pi system (my pi + sensors) draws less than 1A. Could I put a diode on the positive lines of both the battery and the power supply? My buck converter is not picky about it's input voltage, and my 12v sensor is not either. So the diode should prevent the power supply from charging the battery. But will the 12v/pi system draw power from both the power supply and the battery at the same time? That defeats the purpose. If I made the power supply always higher than the battery voltage (say 15v), then would that prevent current from flowing from the battery into the 12v/pi circuit?
Thanks.
Here is a rough diagram