Solar power/fuel generator + arduino

What are the loads you want to run on this system?

One of the key components of my off-grid setup is an inverter-charger with an automatic transfer switch. This is wired into the building wiring. When the generator runs, the loads are switched automatically to the generator. As long as the generator is running my batteries are charged through a 20A 3-stage charger. I recommend getting one of these.

With all this in place, the only thing you need to program is when to run the generator, which could a function of the battery state-of-charge. To a first approximation, it is possible to estimate the state of charge of a lead acid battery if you know the cell voltage, current draw, battery capacity and temperature.