case "$PRODUCT" in
T10*TA|HP*Omni*)
BTUART_PORT=/dev/ttyS1
+ set_property hal.bluetooth.uart.proto bcm
;;
MacBookPro8*)
rmmod b43
for bt in $(lsusb -v | awk ' /Class:.E0/ { print $9 } '); do
chown 1002.1002 $bt && chmod 660 $bt
done
- modprobe btusb
;;
esac
if [ -n "$BTUART_PORT" ]; then
set_property hal.bluetooth.uart $BTUART_PORT
chown bluetooth.bluetooth $BTUART_PORT
- start btattach:-B$BTUART_PORT
- log -t hciconfig -p i "`hciconfig`"
+ start btattach
fi
}
post_bootcomplete
}
-function do_hci()
-{
- local hci=`hciconfig | grep ^hci | cut -d: -f1`
- local btd="`getprop init.svc.bluetoothd`"
- log -t bluetoothd -p i "$btd ($hci)"
- if [ -n "`getprop hal.bluetooth.uart`" ]; then
- [ "`getprop init.svc.bluetoothd`" = "running" ] && hciconfig $hci up
- fi
-}
-
PATH=/sbin:/system/bin:/system/xbin
DMIPATH=/sys/class/dmi/id
bootcomplete)
do_bootcomplete
;;
- hci)
- do_hci
- ;;
init|"")
do_init
;;
-import /init.bluetooth.rc
import /init.superuser.rc
on early-init
service logcat /system/bin/logcat -v threadtime -f /data/log.txt
class debug
-service btattach /system/bin/btattach -Pbcm
+service btattach /system/bin/btattach
class main
disabled
oneshot
write /proc/sys/kernel/ctrl-alt-del 0
exec -- /system/bin/logwrapper /system/bin/sh /system/etc/init.sh bootcomplete
-on property:init.svc.bluetoothd=running
- exec -- /system/bin/logwrapper /system/bin/sh /system/etc/init.sh hci
-
-on property:init.svc.bluetoothd=stopped
- exec -- /system/bin/logwrapper /system/bin/sh /system/etc/init.sh hci
-
on property:net.dns1=*
exec -- /system/bin/logwrapper /system/bin/sh /system/etc/init.sh netconsole