This is not what you want, but it is the setup I have that essentially performs the same purpose. It's easy. Control depends on a single DPDT mechanical relay.
I have a 3 stage charger for a 12 volt deep cycle battery. (The final stage is a float charge.)
The charger plugs into an electrical outlet. Thus, it is ON when the electrical power is ON.
I have a 120 volt coil DPDT relay. It plugs into an electrical outlet. (I bought the relay at Radio Shack.)
When the electricity is ON, the relay contacts are connected to nothing. (They can be connected to an indicator light.)
When the electricity goes OFF the relay contacts connect the battery to the LEDs.
I have a switch that allows me to control how many LEDs are running. 3 or 12. (More LEDs - more light - more current drain.) But the warm white LEDs I'm using draw less than 1 watt each.
When the power comes back ON, the battery is disconnected from the LEDs by the relay.
And the charger which was OFF during the power outage is is powered ON and begins to to recharge the battery.
To test the system, I just unplug the plug that is connected to the relay. Yes. I could put a switch in there to do this. I haven't really seen a need for it.
I'm currently working on an auto-cutoff to disconnect the battery from the LEDs when the battery voltage drops to a certain level. I'd also like to add a photocell to keep the LEDs from coming ON during the daylight hours. Both of these will require DC voltage. But they would only have to be powered when the charger is OFF.
The relay was about $10. The charger was about $30 (I already had it.) The battery I use is a 35 amp-hour deep cycle. But you can find them in a variety of capacities. I already had the 35 AH. I think it cost me $65. This same simple concept will work for any battery of any voltage. You just have to match the charger and the battery. I have it all in a small project project box - except for the battery and the charger.
I'm sure what you have will be more sophisticated. But sometimes simple works too.
Good luck with your project.
Bach On