1
# bluez - bluetooth daemon
3
description "bluetooth daemon"
8
env UART_CONF=/etc/bluetooth/uart
9
env RFCOMM_CONF=/etc/bluetooth/rfcomm.conf
14
exec /usr/sbin/bluetoothd
17
[ "$VERBOSE" = no ] && redirect='>/dev/null 2>&1' || redirect=
20
if [ -x /usr/sbin/hciattach ] && [ -f $UART_CONF ];
22
grep -v '^#' $UART_CONF | while read i; do
23
eval "/usr/sbin/hciattach $i $redirect" || :
28
if [ -x /usr/bin/rfcomm ] && [ -f $RFCOMM_CONF ] ;
30
# rfcomm must always succeed for now: users
31
# may not yet have an rfcomm-enabled kernel
32
eval "/usr/bin/rfcomm -f $RFCOMM_CONF bind all $redirect" || :
38
logger -t bluez "Stopping uarts"
39
killall hciattach >/dev/null 2>&1 || :
42
logger -t bluez "Stopping rfcomm"
43
if [ -x /usr/bin/rfcomm ];
45
eval "/usr/bin/rfcomm unbind all $redirect" || :