The project shows you how to build PIC-based emergency power system for 12-Volt device system. The hearts of the project is PIC16F870. The system will monitoring battery voltage both charging and discharging currents, control 4 digit display, and switches the AC and load relays.
“The basic operation is as follows: While AC power is available, the battery voltage is constantly monitored and topped off as needed. When the AC power fails, the load relay engages the 12-volt system. This connects to lights, fans, and other 12 volt devices as needed. Should the battery voltage fall too low, the load relay is disengaged, preventing the acid batteries from being damaged by over discharging”, said Luhan Monat, the designer.
.01 ohm resistors were made out of about 5 inches of #22 solid hookup wire in order to measure currents up to 10 amps. To monitor the voltage, the project use simple resistor divider. Here are schematic, source and object (hex) files.