CC2640R2 BLE5 Long Range mode
来源:互联网 发布:手机淘宝店铺怎么激活 编辑:程序博客网 时间:2024/06/05 12:46
How do I evaluate Long Range mode?
In addition to the High Speed 2 Mbps mode supported in the BLE5-Stack v1.0 protocol stack, TI has also enabled the ability to evaluate the LE Coded PHYs which are used to enable longer range Bluetooth connections at the same transmit power. The longer range is enabled by using Forward Error Correction (FEC) to improve receiver sensitivity. If you want to know more about the science behind coded PHYs and how they improve link budget without increasing transmit power, check out our blog How does Bluetooth® 5 increase the achievable range of a Bluetooth low energy connection? which includes a video demonstration of a 1.6 km BLE Long Range connection between CC2640R2 LaunchPads.
To enable the evaluation of the LE Coded PHYs in the SDK, enable the feature in the protocol stack’s build_config.opt file. Connections are established at the default 1 Mbps link speed (same as Bluetooth 4.x) and then can be switched to a LE Coded PHY via the PHY Update Procedure. Use of the LE Coded PHYs is also demonstrated in the Throughput Demo on GitHub. Evaluating the LE Coded PHYs will help you to measure actual performance your device will expect to achieve in the long range configuration.
Please note that you cannot certify your device with Bluetooth SIG when using the LE Coded PHY evaluation configuration from this SDK. TI intends to provides updates to the BLE5-Stack at a later time which will include additional features, such as Advertising Extensions, required to support a Bluetooth 5 LE Coded PHY certification.
实际操作一下:
请看下面的HCI_LE_EVENT_CODE,我们需要使用的HCI_PHY_OPT_S8即,选择使用coding n=8, 125kbps,同时设置发射功率5DBM:
HCI_EXT_SetTxPowerCmd(HCI_EXT_TX_POWER_5_DBM); HCI_EXT_SetRxGainCmd(HCI_EXT_RX_GAIN_HIGH);
static uint8_t SimpleBLEPeripheral_processStackMsg(ICall_Hdr *pMsg){ uint8_t safeToDealloc = TRUE; switch (pMsg->event) { case GATT_MSG_EVENT: // Process GATT message safeToDealloc = SimpleBLEPeripheral_processGATTMsg((gattMsgEvent_t *)pMsg); break; case HCI_GAP_EVENT_EVENT: { // Process HCI message switch(pMsg->status) { case HCI_COMMAND_COMPLETE_EVENT_CODE: // Process HCI Command Complete Event break; case HCI_BLE_HARDWARE_ERROR_EVENT_CODE: AssertHandler(HAL_ASSERT_CAUSE_HARDWARE_ERROR,0); break; case HCI_LE_EVENT_CODE: { hciEvt_BLEPhyUpdateComplete_t *pPUC = (hciEvt_BLEPhyUpdateComplete_t*) pMsg; if (pPUC->BLEEventCode == HCI_BLE_PHY_UPDATE_COMPLETE_EVENT) { if (pPUC->status != SUCCESS) { Display_print0(dispHandle, SBP_ROW_STATUS_1, 0, "PHY Change failure"); } else { Display_print0(dispHandle, SBP_ROW_STATUS_1, 0, "PHY Update Complete"); uint8_t index = 0; switch(pPUC->rxPhy) { case HCI_PHY_1_MBPS: index = 0; break; case HCI_PHY_2_MBPS: index = 1; break; case HCI_PHY_CODED: { if(phyOptions == HCI_PHY_OPT_S2) index = 2; else if (phyOptions == HCI_PHY_OPT_S8) index = 3; Util_startClock(&periodicLED); } break; } Display_print1(dispHandle, SBP_ROW_STATUS_3, 0, "Current PHY: %s", phyName[index]); } } if (pPUC->BLEEventCode == HCI_BLE_DATA_LENGTH_CHANGE_EVENT) { // TX PDU Size Updated hciEvt_BLEDataLengthChange_t *dleEvt = (hciEvt_BLEDataLengthChange_t *)pMsg; Display_print1(dispHandle, SBP_ROW_STATUS_2, 0, "PDU Size: %dB", dleEvt->maxTxOctets); } } break; default: break; } } break; default: // do nothing break; } return (safeToDealloc);}
第二种方式:
使用SmartRF Studio 7:
- CC2640R2 BLE5 Long Range mode
- CC2640R2F BLE5.0 CC2640R2&BLE5.0开发文档
- long mode 资料链接
- Long Range RFID Reader
- CC2640R2 ANCS
- long mode 下的 interrupt/trap gate
- long mode 下的 call gate
- long mode 模式下的中断服务例程
- long mode 模式下 system/gate descriptor 的疑惑
- long mode 下的 TSS 和 task gate
- Binary translation is incompatible with long mode on this platform
- 【CC2640R2】CC2640R2F OAD 用户指导
- TI-CC2640R2-程序复位API
- TI-CC2640R2-断线不广播
- ble5.0特性
- How to change mode from c++98 mode in Dev-C++ to a mode that supports C++0x (range based for)?
- mode
- Mode
- SPIFFS技术手册
- 581. Shortest Unsorted Continuous Subarray
- Eclipse FindBugs插件安装与使用
- USB Class Codes
- mybatis中使用Java8的日期LocalDate、LocalDateTime
- CC2640R2 BLE5 Long Range mode
- python 爬取学信网登录页面
- 微软创立全新人工智能实验室,与DeepMind、OpenAI同台竞技
- 线程
- 网络基础之iso,osi七层模型
- sqlServer里面查询一张表里面有没有自增字段
- LeetCode 189 Rotate Array (思维)
- Bootstrap轮播图不兼容IE的问题
- Java注解全解