From 5c2e0bddf8816b423b6422875d9b2a009254c140 Mon Sep 17 00:00:00 2001 From: Matthias Ringwald Date: Wed, 3 May 2017 14:07:15 +0200 Subject: [PATCH] posix/windows-h4: correct local info printout --- port/posix-h4/main.c | 6 +++--- port/posix-h5/main.c | 6 +++--- port/windows-h4/main.c | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/port/posix-h4/main.c b/port/posix-h4/main.c index 0ef51625f..4a8df459b 100644 --- a/port/posix-h4/main.c +++ b/port/posix-h4/main.c @@ -148,9 +148,9 @@ static void use_fast_uart(void){ static void local_version_information_handler(uint8_t * packet){ printf("Local version information:\n"); - uint16_t hci_version = little_endian_read_16(packet, 4); - uint16_t hci_revision = little_endian_read_16(packet, 6); - uint16_t lmp_version = little_endian_read_16(packet, 8); + uint16_t hci_version = packet[6]; + uint16_t hci_revision = little_endian_read_16(packet, 7); + uint16_t lmp_version = packet[9]; uint16_t manufacturer = little_endian_read_16(packet, 10); uint16_t lmp_subversion = little_endian_read_16(packet, 12); printf("- HCI Version 0x%04x\n", hci_version); diff --git a/port/posix-h5/main.c b/port/posix-h5/main.c index 0d4fbb45b..634a2f30c 100644 --- a/port/posix-h5/main.c +++ b/port/posix-h5/main.c @@ -110,9 +110,9 @@ static void use_fast_uart(void){ static void local_version_information_handler(uint8_t * packet){ printf("Local version information:\n"); - uint16_t hci_version = little_endian_read_16(packet, 4); - uint16_t hci_revision = little_endian_read_16(packet, 6); - uint16_t lmp_version = little_endian_read_16(packet, 8); + uint16_t hci_version = packet[6]; + uint16_t hci_revision = little_endian_read_16(packet, 7); + uint16_t lmp_version = packet[9]; uint16_t manufacturer = little_endian_read_16(packet, 10); uint16_t lmp_subversion = little_endian_read_16(packet, 12); printf("- HCI Version 0x%04x\n", hci_version); diff --git a/port/windows-h4/main.c b/port/windows-h4/main.c index 49c9fb208..5a07aa2f2 100644 --- a/port/windows-h4/main.c +++ b/port/windows-h4/main.c @@ -136,9 +136,9 @@ static void use_fast_uart(void){ static void local_version_information_handler(uint8_t * packet){ printf("Local version information:\n"); - uint16_t hci_version = little_endian_read_16(packet, 4); - uint16_t hci_revision = little_endian_read_16(packet, 6); - uint16_t lmp_version = little_endian_read_16(packet, 8); + uint16_t hci_version = packet[6]; + uint16_t hci_revision = little_endian_read_16(packet, 7); + uint16_t lmp_version = packet[9]; uint16_t manufacturer = little_endian_read_16(packet, 10); uint16_t lmp_subversion = little_endian_read_16(packet, 12); printf("- HCI Version 0x%04x\n", hci_version);