1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-feeds.git synced 2025-02-12 10:31:51 +00:00

Simplify z8102 watchdog command

This commit is contained in:
Ycarus (Yannick Chabanois) 2024-05-02 09:46:53 +02:00
parent 20f0ff5eb3
commit f7a591f3dc

View file

@ -10,14 +10,14 @@ do
if [ -f /usr/bin/gpiofind ]; then
gpioset `gpiofind "watchdog"`=1 2>&1 >/dev/null
else
gpioset --hold-period 100ms -t0 watchdog=1 2>&1 >/dev/null
gpioset -t0 watchdog=1 2>&1 >/dev/null
fi
sleep 1
#echo "0" > /sys/class/gpio/gpio${i}/value
if [ -f /usr/bin/gpiofind ]; then
gpioset `gpiofind "watchdog"`=0 2>&1 >/dev/null
else
gpioset --hold-period 100ms -t0 watchdog=0 2>&1 >/dev/null
gpioset -t0 watchdog=0 2>&1 >/dev/null
fi
sleep 1
done