Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 30052a36d2
Fetching contributors…

Cannot retrieve contributors at this time

59 lines (52 sloc) 1.056 kb
#!/bin/sh
#
# irda This shell script takes care of starting and stopping
# IrDA support
#
# chkconfig: 2345 45 96
#
# description: IrDA stack for Linux
#
# Source IrDA networking configuration.
. /etc/sysconfig/irda
# Check that irda is up.
[ ${IRDA} = "no" ] && exit 0
[ -f /usr/sbin/irattach ] || exit 0
ARGS=
if [ $DONGLE ]; then
ARGS="$ARGS -d $DONGLE"
fi
if [ "$DISCOVERY" = "yes" ];then
ARGS="$ARGS -s"
fi
# See how we were called.
case "$1" in
start)
# Attach irda device
echo -n "Starting IrDA: "
/usr/sbin/irattach ${DEVICE} ${ARGS}
touch /var/lock/subsys/irda
echo
;;
stop)
# Stop service.
echo -n "Shutting down IrDA: "
killproc irattach
rm -f /var/lock/subsys/irda
echo
;;
status)
if [ -f /var/lock/subsys/irda ];
then echo -n "IrDA already running"
else echo -n "IrDA is not running"
fi
;;
restart|reload)
$0 stop
$0 start
;;
*)
echo "Usage: irda {start|stop|restart|reload|status}"
exit 1
esac
exit 0
Jump to Line
Something went wrong with that request. Please try again.