summaryrefslogtreecommitdiff
path: root/tools/hcitool.c
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2014-09-29 12:09:56 +0200
committerMarcel Holtmann <marcel@holtmann.org>2014-09-29 12:09:56 +0200
commit2ac4e7cc5cc6be9ba07ec9d8c78ecae9295d9743 (patch)
tree60429762324cfa9e1baa54c6af1f705a5f558faa /tools/hcitool.c
parent9838cb51c36c58036858b19df9804275e33cd36f (diff)
downloadbluez-2ac4e7cc5cc6be9ba07ec9d8c78ecae9295d9743.tar.gz
tools: Request LE remote version information as well
Diffstat (limited to 'tools/hcitool.c')
-rw-r--r--tools/hcitool.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/tools/hcitool.c b/tools/hcitool.c
index d51c6885f..3aa77b67b 100644
--- a/tools/hcitool.c
+++ b/tools/hcitool.c
@@ -2573,6 +2573,7 @@ static void cmd_leinfo(int dev_id, int argc, char **argv)
uint8_t bdaddr_type;
uint16_t handle;
uint8_t features[8];
+ struct hci_version version;
uint16_t interval, latency, max_ce_length, max_interval, min_ce_length;
uint16_t min_interval, supervision_timeout, window;
uint8_t initiator_filter, own_type;
@@ -2627,6 +2628,19 @@ static void cmd_leinfo(int dev_id, int argc, char **argv)
printf("\tHandle: %d (0x%04x)\n", handle, handle);
+ if (hci_read_remote_version(dd, handle, &version, 20000) == 0) {
+ char *ver = lmp_vertostr(version.lmp_ver);
+ printf("\tLMP Version: %s (0x%x) LMP Subversion: 0x%x\n"
+ "\tManufacturer: %s (%d)\n",
+ ver ? ver : "n/a",
+ version.lmp_ver,
+ version.lmp_subver,
+ bt_compidtostr(version.manufacturer),
+ version.manufacturer);
+ if (ver)
+ bt_free(ver);
+ }
+
memset(features, 0, sizeof(features));
hci_le_read_remote_features(dd, handle, features, 20000);