https://www.electricaltechnology.org/2012/11/automatic-ups-system-wiring-circuit_23.html
Automatic UPS / Inverter Connection Diagram to the Home Panel Board