There are some use cases where the system is remote or up-time is critical, yet consume too much power to run for long periods on batteries. So whilst a high performance battery back-up power supply is essential to ensure an orderly shutdown when there is an external power outage, you may also want to restart everything as soon as the external power is restored.

Whilst the Red Reactor can easily support a Pi4 with accessories and cleanly switch to battery power, you can also use the Vin port and ON button interface to easily integrate additional functionality into your project. In a previous video we showed how to add an RTC alarm to manage timed power-on and power-off requirements.

This new video shows you how to add a simple circuit to detect when external power is restored, which connects to the Vin port and operates alongside an ON button to create a trigger (even if you’re using USB as the power input). A simple script (here running on the Pi4 with display, USB hub, mouse and keyboard) will detect a power outage over I2C and perform a safe shutdown, whilst the system is automatically rebooted when external power returns!

4 thoughts on “Auto Power-ON!

  1. Pascal says:

    Feel free to leave a comment if you found this video useful!

  2. Charlie says:

    That’s really helpful and is just how a UPS backed up system should work. So i could use this as a remote 24/7 file server – eg for A/V media sharing with the knowledge that if the power drops i needn’t worry about file integrity ?!

    Thanks!

  3. Pascal says:

    Indeed – a Pi A/V server is an excellent example where you really need a battery backup to prevent corrupting the file system as a result of external power problems. The whole system perhaps draws too much power to run for long without mains, so you could safely shut everything down after say, 30 minutes, and use this example as a way to restart everything automatically!

Leave a Reply

Your email address will not be published. Required fields are marked *

16 − one =