From: Chan-yeol Park <[email protected]>
kernel side has updated its control channel id from 1 to 3.
---
lib/hci.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/hci.h b/lib/hci.h
index 3dbb221..2c573a4 100644
--- a/lib/hci.h
+++ b/lib/hci.h
@@ -2279,8 +2279,8 @@ struct sockaddr_hci {
#define HCI_DEV_NONE 0xffff
#define HCI_CHANNEL_RAW 0
-#define HCI_CHANNEL_CONTROL 1
#define HCI_CHANNEL_MONITOR 2
+#define HCI_CHANNEL_CONTROL 3
struct hci_filter {
uint32_t type_mask;
--
1.7.9.5
From: Chan-yeol Park <[email protected]>
---
src/hcidump.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/hcidump.c b/src/hcidump.c
index 089d444..7423cdd 100644
--- a/src/hcidump.c
+++ b/src/hcidump.c
@@ -590,8 +590,10 @@ static int open_socket(int dev, unsigned long flags)
memset(&addr, 0, sizeof(addr));
addr.hci_family = AF_BLUETOOTH;
addr.hci_dev = dev;
+ addr.hci_channel = HCI_CHANNEL_RAW;
+
if (bind(sk, (struct sockaddr *) &addr, sizeof(addr)) < 0) {
- printf("Can't attach to device hci%d. %s(%d)\n",
+ printf("Can't attach to device hci%d. %s(%d)\n",
dev, strerror(errno), errno);
return -1;
}
--
1.7.9.5