I followed those instructions and did that:
- set config.txt back to original (no "dtoverlay=gpio-shutdown")
- installed "Raspberry Pi Tools" from repository
- created the "autostart.sh" and "off-button.py"
- set both files as executable (chmod +x)
GPIO3 now still works as power on (it always does), but the next trigger to power off does nothing.
The python script ("off-button.py") looks OK:
- the necessary lib from "Raspberry Pi Tools" exists (/storage/.kodi/addons/virtual.rpi-tools/lib/GPIO.so)
- the pin mode "GPIO.BCM" is correct for my model 3b+ with GPIO3 power button
Any hints?
PS: The command line response when starting from ssh ("sh /storage/.config/autostart.sh") is this:
Traceback (most recent call last):
File "/storage/scripts/off-button.py", line 6, in <module>
import syss
ImportError: No module named syss