Difference: WoodenBox (2 vs. 3)

Revision 32018-08-26 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 19 to 19
 
box-psu.jpg
Box with the Raspberry Pi Universal Power Supply
box-running.jpg
RaspiElf running
Added:
>
>

GPIO Shutdown

To keep prices down, the Raspberry Pi is missing something that most electronic devices come with: a switch to turn it on and off. That’s OK, you say, we’ll just pull the plug to turn it off. Unfortunately, this can lead to corruption problems with the SD card. All the instructions say you should run the shutdown command before pulling the plug, but this is not always possible, particularly when your Raspberry Pi is running headless without a connected keyboard and monitor, and possibly even without a network connection. So, what can a self-respecting DIYer do? The answer, of course, is ‘add your own switch’!

To switch off the Raspberry Pi from the console: sudo poweroff

shutdown -h now sudo halt

shutdown -r now sudo reboot

https://github.com/raspberrypi/firmware/tree/master/boot/overlays

  • gpio-poweroff
 
  • gpio-shutdown
Changed:
<
<
P6 Pinout
>
>
/boot/config.txt

dtoverlay=gpio-shutdown,gpio_pin=21

Run

If the Raspberry Pi is in HALT mode then you can start it again with switch off (pull the plug) and switch on again or hit the RUN button.

P6 Pinout

 
Pin Number Pin Name Rev2 Hardware Notes
P6-01 RUN Short to ground to reset the BCM2835
P6-02 GND  
Deleted:
<
<
/boot/config.txt

dtoverlay=gpio-shutdown,gpio_pin=26

 
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2025 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback