Reply To: Power Button extension to start and safely shutdown the Raspberry PI

Max2Play Home 2016 (en) Forums Max2Play Development (Ideas, Wishes) Power Button extension to start and safely shutdown the Raspberry PI Reply To: Power Button extension to start and safely shutdown the Raspberry PI

9. Juli 2019 at 3:46 #46208

Great plugin. AFAICS you can also use it with just a button without all the rest of the circuitry, to safely shutdown the Raspberry pi (it will end up in a low power sleep mode rather than being completely off). If you use GPIO3 (pin 5) for this, you can even power it on again with the same button.

However, I noticed this plugin uses a bash script and wiringpi to read the button. It might be possible to simplify this using dtoverlays. See [url=https://www.stderr.nl/Blog/Hardware/RaspberryPi/PowerButton.html]this post[/url] I wrote about this a while back. The post is only about letting the kernel handle the shutdown pin, but I believe there is also a gpio-poweroff overlay that handles toggling a pin on shutdown (though the [url=https://github.com/raspberrypi/firmware/blob/master/boot/overlays/README]docs[/url] suggest it might be tricky when the pin must be low to poweroff).