From 32c8a21b7da2397da204015f4bf45983226cbed9 Mon Sep 17 00:00:00 2001 From: Marcel Holtmann Date: Thu, 13 Jan 2005 20:16:40 +0000 Subject: Add function for reading the RSSI and the link quality --- include/hci.h | 6 +++--- include/hci_lib.h | 2 ++ 2 files changed, 5 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/hci.h b/include/hci.h index 683c988f..54bb8849 100644 --- a/include/hci.h +++ b/include/hci.h @@ -791,13 +791,13 @@ typedef struct { } __attribute__ ((packed)) reset_failed_contact_counter_rp; #define RESET_FAILED_CONTACT_COUNTER_RP_SIZE 4 -#define OCF_GET_LINK_QUALITY 0x0003 +#define OCF_READ_LINK_QUALITY 0x0003 typedef struct { uint8_t status; uint16_t handle; uint8_t link_quality; -} __attribute__ ((packed)) get_link_quality_rp; -#define GET_LINK_QUALITY_RP_SIZE 4 +} __attribute__ ((packed)) read_link_quality_rp; +#define READ_LINK_QUALITY_RP_SIZE 4 #define OCF_READ_RSSI 0x0005 typedef struct { diff --git a/include/hci_lib.h b/include/hci_lib.h index 5c83b5e8..969db1f2 100644 --- a/include/hci_lib.h +++ b/include/hci_lib.h @@ -92,6 +92,8 @@ int hci_write_inquiry_mode(int dd, uint8_t mode, int to); int hci_read_afh_mode(int dd, uint8_t *mode, int to); int hci_write_afh_mode(int dd, uint8_t mode, int to); int hci_set_afh_classification(int dd, uint8_t *map, int to); +int hci_read_link_quality(int dd, uint16_t handle, uint8_t *link_quality, int to); +int hci_read_rssi(int dd, uint16_t handle, int8_t *rssi, int to); int hci_read_afh_map(int dd, uint16_t handle, uint8_t *mode, uint8_t *map, int to); int hci_for_each_dev(int flag, int(*func)(int s, int dev_id, long arg), long arg); -- cgit