From 00df067a93236865cea580d432b0ed17e27812e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Rymanowski?= Date: Fri, 31 Mar 2017 10:52:53 +0200 Subject: [PATCH] nimble/controller: Change LL and HCI version to Bluetooth 5.0 We start adding features from Bluetooth 5.0 so lets move on with version first < HCI Command: Read Local Version Information (0x04|0x0001) plen 0 > HCI Event: Command Complete (0x0e) plen 12 Read Local Version Information (0x04|0x0001) ncmd 1 Status: Success (0x00) HCI version: Bluetooth 5.0 (0x09) - Revision 0 (0x0000) LMP version: Bluetooth 5.0 (0x09) - Subversion 0 (0x0000) Manufacturer: internal use (65535) X-Original-Commit: 9ed2a9e611f2485caa06b371770ad04867ae9dcc --- nimble/controller/src/ble_ll_ctrl.c | 2 +- nimble/controller/src/ble_ll_hci.c | 4 ++-- nimble/include/nimble/hci_common.h | 2 ++ 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/nimble/controller/src/ble_ll_ctrl.c b/nimble/controller/src/ble_ll_ctrl.c index a93375373..87a66ced8 100644 --- a/nimble/controller/src/ble_ll_ctrl.c +++ b/nimble/controller/src/ble_ll_ctrl.c @@ -777,7 +777,7 @@ ble_ll_ctrl_version_ind_make(struct ble_ll_conn_sm *connsm, uint8_t *pyld) connsm->csmflags.cfbit.version_ind_sent = 1; /* Fill out response */ - pyld[0] = BLE_HCI_VER_BCS_4_2; + pyld[0] = BLE_HCI_VER_BCS_5_0; put_le16(pyld + 1, MYNEWT_VAL(BLE_LL_MFRG_ID)); put_le16(pyld + 3, BLE_LL_SUB_VERS_NR); } diff --git a/nimble/controller/src/ble_ll_hci.c b/nimble/controller/src/ble_ll_hci.c index 336cd0345..83d99a757 100644 --- a/nimble/controller/src/ble_ll_hci.c +++ b/nimble/controller/src/ble_ll_hci.c @@ -183,9 +183,9 @@ ble_ll_hci_rd_local_version(uint8_t *rspbuf, uint8_t *rsplen) mfrg = MYNEWT_VAL(BLE_LL_MFRG_ID); /* Place the data packet length and number of packets in the buffer */ - rspbuf[0] = BLE_HCI_VER_BCS_4_2; + rspbuf[0] = BLE_HCI_VER_BCS_5_0; put_le16(rspbuf + 1, hci_rev); - rspbuf[3] = BLE_LMP_VER_BCS_4_2; + rspbuf[3] = BLE_LMP_VER_BCS_5_0; put_le16(rspbuf + 4, mfrg); put_le16(rspbuf + 6, lmp_subver); *rsplen = BLE_HCI_RD_LOC_VER_INFO_RSPLEN; diff --git a/nimble/include/nimble/hci_common.h b/nimble/include/nimble/hci_common.h index ff343169a..6e80d4969 100644 --- a/nimble/include/nimble/hci_common.h +++ b/nimble/include/nimble/hci_common.h @@ -558,6 +558,7 @@ extern "C" { #define BLE_HCI_VER_BCS_4_0 (6) #define BLE_HCI_VER_BCS_4_1 (7) #define BLE_HCI_VER_BCS_4_2 (8) +#define BLE_HCI_VER_BCS_5_0 (9) #define BLE_LMP_VER_BCS_1_0b (0) #define BLE_LMP_VER_BCS_1_1 (1) @@ -568,6 +569,7 @@ extern "C" { #define BLE_LMP_VER_BCS_4_0 (6) #define BLE_LMP_VER_BCS_4_1 (7) #define BLE_LMP_VER_BCS_4_2 (8) +#define BLE_LMP_VER_BCS_5_0 (9) /* Sub-event 0x0A: enhanced connection complete */ #define BLE_HCI_LE_ENH_CONN_COMPLETE_LEN (31)