The Backup Box is used in a residential rooftop PV plant system to control the inverter grid-tied or off-grid state. When the grid fails, the inverter switches to the off-grid state and supplies power to off-grid loads in backup mode. When the grid recovers, the inverter switches back to the grid-tied state.