From e4531c468325407d111f7d5cf3a53604f6b596b5 Mon Sep 17 00:00:00 2001 From: chatty Date: Mon, 28 Jun 1999 15:54:00 +0000 Subject: Now handle configuration options read from file /etc/irbox.conf --- src/irbox.init | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) (limited to 'src/irbox.init') diff --git a/src/irbox.init b/src/irbox.init index e1e383a..1fa91c4 100755 --- a/src/irbox.init +++ b/src/irbox.init @@ -13,11 +13,33 @@ # Source function library. . /etc/rc.d/init.d/functions +. /etc/irbox.conf + +if [ -z $BUS ]; then + busopt= +else + busopt="-b $BUS" +fi + +if [ -z $DEVICE ]; then + devopt= +else + devopt="-d $DEVICE" +fi + +if [ -z $APPNAME ]; then + appopt= +else + appopt="-n $APPNAME" +fi + + + # See how we were called. case "$1" in start) echo -n "Infra-red Ivy driver... " - daemon irbox -b 143.196.53,143.196.1:2019 & + daemon irbox $busopt $devopt $appopt & echo touch /var/lock/subsys/irbox ;; -- cgit v1.1