source: freewrt/package/broadcom-watchbutton/watchbutton.init@ 6fc4520e

freewrt_1_0 freewrt_2_0
Last change on this file since 6fc4520e was e1dfb1a, checked in by Markus Wigge <markus@…>, 19 years ago

added small watchdog for WRT54G3G button. This is intended to be replaces as soon as gpio is handled on interupts.

git-svn-id: svn://www.freewrt.org/trunk/freewrt@658 afb5a338-a214-0410-bd46-81f09a774fd1

  • Property mode set to 100644
File size: 337 bytes
Line 
1#!/bin/sh
2
3. /etc/rc.conf
4
5case $1 in
6autostart)
7 test x"$watchbutton" = x"NO" && exit 0
8 exec $0 start
9 ;;
10start)
11 ps ax | grep -q [w]atchbutton 2> /dev/null && exit
12 /sbin/watchbutton >&- 2>&- &
13 ;;
14stop)
15 killall watchbutton
16 ;;
17restart)
18 $0 stop && $0 start
19 ;;
20*)
21 echo "Usage: $0 {start | stop | restart}"
22 exit 1
23 ;;
24esac
25exit $?
Note: See TracBrowser for help on using the repository browser.