Service to Safe Shutdown Headless Raspberry Pi Boards - Raspberry Pi Forums


everytime when need shutdown headless pi boards, either need plugin monitor or ssh pi. connecting pushbutton across gpio , running service, can safe shutdown , restart pi boards.

1. clone git:

code: select all

git clone https://github.com/shivasiddharth/pi-shut
2. run installer.

code: select all

sudo chmod +x /home/pi/pi-shut/installer.sh   sudo /home/pi/pi-shut/installer.sh  
3. wire pi per diagram.
image

4. start shutdown service.

code: select all

 sudo systemctl start on-off-pushbutton.service
now, have service safe shutdown , restart pi working.

the capability shutdown , restart raspberry pi using open momentary pushbutton switch connected gpio pins 5 & 6 present in raspbian stretch , requires no additional software. enable it:

1. add following line /boot/config.txt:

dtoverlay=gpio-shutdown

2. run rpi-update

depressing pushbutton on running system shut down if had issued "shutdown -h now".

depressing pushbutton on halted system restart system.


raspberrypi



Comments

Popular posts from this blog

Error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode - Raspberry Pi Forums

class MPU6050 has no member named begin

missing filename after '-o'