Below is a link to a auto power off circuit I built that utilizes a single coil 5vdc latching relay. This relay coil only draws 13ma so no transistor switches or H-bridge required. The series cap serves two functions, one to eliminate continuous current draw while in the set mode (while the digital output pin is high) and to store a charge to allow a brief reverse current flow when the digital output pin is brought low to reset the relay. Note that you can NOT use a parallel diode across the coil as it would allow current to bypass the coil in one direction and prevent the bipolar current flow through the coil required of single coil latching relays.
The circuit works as follows, user presses manual momentary switch to power processor chip, first steps in the chip’s program sets the output pin high to set the relay and seal the contacts across the manual switch thus allowing power to be latched on. As the cap charges fully current stops flowing. When the program wants to power the board off it just has to bring the output pin low which resets the relay removing power from the board.
This could be useful for applications where the board is powered with Li-po batteries where you could measure the battery value via analog input (voltage divider may be needed) and have the program turn off the board when the battery reaches end of charge voltage, thus preventing over-discharge damage to the Li-po battery.
The relay I used is still avalible on e-bay at a nice price: