Posts with «shutdown» label

Raspberry Pi Gets Turned On

The Raspberry Pi and other similar Linux-based single board computers simplify many projects. However, one issue with Linux is that it doesn’t like being turned off abruptly. Things have gotten better, and you can certainly configure things to minimize the risk, but–in general–shutting a Linux system down while it is running will eventually lead to file system corruption.

If your project has an interface, you can always provide a shutdown option, but that doesn’t help if your application is headless. You can provide a shutdown button, but that leaves the problem of turning the device back on.

[Ivan] solved this problem with–what else–an Arduino (see the video below). Simplistically, the Arduino reads a button and uses a FET to turn off the power to the Pi. The reason for the Arduino, is that the tiny processor (which draws less than a Pi and doesn’t mind being shut down abruptly) can log into the Pi and properly shut it down. The real advantage, though, is that you could use other Arduino inputs to determine when to turn the Pi on and off.

For example, it is easy to imagine a Pi in an automotive application where the Arduino would sense the ignition was off for a certain period of time and then go ahead and shut off the Pi. Or maybe the Pi needs to be turned on when a motion sensor fires and then turned off again once there is no motion for a particular time period. Any of these strategies would be simple to build with the Arduino.

We’ve seen a similar project that used an IR remote as the trigger instead of a physical button. If you are afraid the Pi will just lose power unexpectedly, you might consider a battery backup. If powering a Pi with regular electricity is too tame for you, try steam.

Filed under: Arduino Hacks, Raspberry Pi

Arduino And IR Remote Turn Off Raspberry Pi

With all of the cool features on the Raspberry Pi, it is somewhat notable that it lacks a power button. In a simple setup, the only way to cut power to the tiny computer is to physically remove the power cord. [Dalton63841] found that this was below his wife’s tolerance level for electronics, and built a simple remote control for his Raspberry Pi.

[Dalton63841] started this project by trying to use the UART TX pin, but this turned out to be a dead-end. He decided instead to use an Arduino to monitor the 3.3V power rail on the Pi. When the Pi is shut down in software, the Arduino can sense that the Pi isn’t on any more and disconnect the power. The remote control is used to turn the Pi on. The Arduino reads the IR code from a remote and simply powers up the Pi. This is a very simple and elegant solution that requires absolutely no software to be installed on the Raspberry Pi.

We know that this isn’t the most technically complex project we’ve ever featured, but it is a good beginner project for anyone just getting started with a Pi, Arduino, or using IR. Plus, this could be the perfect thing to pair up with a battery-backup Raspberry Pi shutdown device that allows it to power itself down in a controlled way when a power outage is sensed.

Filed under: Arduino Hacks