Enable and disable pigpiod daemon.

This commit is contained in:
Simon Long 2017-08-11 14:48:00 +01:00
parent f8772a5fdc
commit 0493c7ffe4
2 changed files with 13 additions and 3 deletions

6
debian/changelog vendored
View File

@ -1,3 +1,9 @@
raspi-config (20170811) stretch; urgency=medium
* Enable and disable pigpiod daemon with remote access
-- Simon Long <simon@raspberrypi.org> Fri, 11 Aug 2017 14:40:50 +0100
raspi-config (20170803) stretch; urgency=medium raspi-config (20170803) stretch; urgency=medium
* Allow splash screen with fake KMS. * Allow splash screen with fake KMS.

View File

@ -990,15 +990,19 @@ do_rgpio() {
ExecStart= ExecStart=
ExecStart=/usr/bin/pigpiod ExecStart=/usr/bin/pigpiod
EOF EOF
systemctl daemon-reload
systemctl restart pigpiod
systemctl enable pigpiod
STATUS=enabled STATUS=enabled
elif [ $RET -eq 1 ]; then elif [ $RET -eq 1 ]; then
rm -f /etc/systemd/system/pigpiod.service.d/public.conf rm -f /etc/systemd/system/pigpiod.service.d/public.conf
systemctl daemon-reload
systemctl stop pigpiod
systemctl disable pigpiod
STATUS=disabled STATUS=disabled
else else
return $RET return $RET
fi fi
systemctl daemon-reload
systemctl restart pigpiod
if [ "$INTERACTIVE" = True ]; then if [ "$INTERACTIVE" = True ]; then
whiptail --msgbox "Remote access to the GPIO server is $STATUS" 20 60 1 whiptail --msgbox "Remote access to the GPIO server is $STATUS" 20 60 1
fi fi
@ -1449,7 +1453,7 @@ do_interface_menu() {
"P5 I2C" "Enable/Disable automatic loading of I2C kernel module" \ "P5 I2C" "Enable/Disable automatic loading of I2C kernel module" \
"P6 Serial" "Enable/Disable shell and kernel messages on the serial connection" \ "P6 Serial" "Enable/Disable shell and kernel messages on the serial connection" \
"P7 1-Wire" "Enable/Disable one-wire interface" \ "P7 1-Wire" "Enable/Disable one-wire interface" \
"P8 Remote GPIO" "Enable/Disable remote access to GPIO pins" \ "P8 GPIO Server" "Enable/Disable remote access to GPIO pins" \
3>&1 1>&2 2>&3) 3>&1 1>&2 2>&3)
RET=$? RET=$?
if [ $RET -eq 1 ]; then if [ $RET -eq 1 ]; then