From 34aafef2dbe70bd2724a33ce8e68a0cb20b114b5 Mon Sep 17 00:00:00 2001 From: Jesse Gilles Date: Thu, 13 Sep 2012 17:33:52 -0500 Subject: bluez: add bluetooth init script for mt100eocg-pcie-dk --- multitech/recipes/bluez/files/bluetooth.init | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100755 multitech/recipes/bluez/files/bluetooth.init (limited to 'multitech/recipes/bluez/files/bluetooth.init') diff --git a/multitech/recipes/bluez/files/bluetooth.init b/multitech/recipes/bluez/files/bluetooth.init new file mode 100755 index 0000000..411fd6d --- /dev/null +++ b/multitech/recipes/bluez/files/bluetooth.init @@ -0,0 +1,7 @@ +#!/bin/sh + +echo "Enabling bluetooth..." +mts-io-sysfs store bt-enabled 1 +sleep 1 +echo "Setting up bluetooth device..." +hciattach /dev/bt texas -- cgit v1.2.3 From c573dda027b9f56d67365ca7abde0875af0000aa Mon Sep 17 00:00:00 2001 From: Jesse Gilles Date: Fri, 14 Sep 2012 14:20:40 -0500 Subject: bluez: mt100ecog-pcie-dk: update bluetooth init script --- multitech/recipes/bluez/files/bluetooth.init | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'multitech/recipes/bluez/files/bluetooth.init') diff --git a/multitech/recipes/bluez/files/bluetooth.init b/multitech/recipes/bluez/files/bluetooth.init index 411fd6d..41312e2 100755 --- a/multitech/recipes/bluez/files/bluetooth.init +++ b/multitech/recipes/bluez/files/bluetooth.init @@ -1,7 +1,11 @@ #!/bin/sh -echo "Enabling bluetooth..." -mts-io-sysfs store bt-enabled 1 -sleep 1 -echo "Setting up bluetooth device..." -hciattach /dev/bt texas +case "$1" in + start) + echo "Enabling bluetooth..." + mts-io-sysfs store bt-enabled 1 + sleep 1 + echo "Setting up bluetooth device..." + hciattach /dev/bt texas + ;; +esac -- cgit v1.2.3 From 165908091aaa5b6f08a14f1bf67bf50e62e36ed4 Mon Sep 17 00:00:00 2001 From: Jesse Gilles Date: Tue, 18 Sep 2012 13:21:38 -0500 Subject: bluez4: mt100eocg-pcie-dk: update bluetooth.init script, add stop/restart --- multitech/recipes/bluez/files/bluetooth.init | 30 +++++++++++++++++++++++++--- 1 file changed, 27 insertions(+), 3 deletions(-) (limited to 'multitech/recipes/bluez/files/bluetooth.init') diff --git a/multitech/recipes/bluez/files/bluetooth.init b/multitech/recipes/bluez/files/bluetooth.init index 41312e2..58318c3 100755 --- a/multitech/recipes/bluez/files/bluetooth.init +++ b/multitech/recipes/bluez/files/bluetooth.init @@ -1,11 +1,35 @@ -#!/bin/sh +#!/bin/bash -case "$1" in - start) +bt_start() +{ echo "Enabling bluetooth..." + mts-io-sysfs store bt-enabled 0 + usleep 200000 mts-io-sysfs store bt-enabled 1 sleep 1 echo "Setting up bluetooth device..." hciattach /dev/bt texas +} + +bt_stop() { + echo "Disabling bluetooth..." + killall hciattach + mts-io-sysfs store bt-enabled 0 +} + +case "$1" in + start) + bt_start + ;; + stop) + bt_stop + ;; + restart) + bt_stop + bt_start + ;; + *) + echo "Usage $0: start|stop|restart" + exit 1 ;; esac -- cgit v1.2.3