RF Testing using BTool

Note

For a step by step explanation about how to execute a sequence of commands for testing, please refer to the Application Note on How to Do RF Radio Test With Your Bluetooth Product. Information related to Packet Error Rate (PER) and RSSI measurements can be found there.

Tool Configuration

  1. In order to set the device to perform RF tests, we need an image capable of receive and executing HCI commands.

  • Flash the device with the respective host_test example, which can be found inside the SDK folder <SDK>/examples/rtos/LP_EM_CC26xx/ble5stack/host_test. You can import the project in CCS or IAR and tune it to fit your own design (e.g. change the UART mapping).

  • If your design allows it (or if you are running the tests on a TI LaunchPad), you can directly flash the pre-built hexfile on the device. To do so, use UniFlash and use the following image <SDK>/examples/rtos/LP_EM_CC26xx/ble5stack/hexfiles/host_test_app.hex.

  • Finally, it is recommended to power cycle the device after flashing it.

  1. BTool can be found within the SDK. Execute the file <SDK>/tools/ble5stack/btool/btool.exe to open the tool.

  2. When opening BTool, you are prompt to select the COM interface used by your device. Make sure to choose the interface COMXX - XDS110 Class Application/User UART.

  3. At start BTool automatically sends a few commands to the device. These commands are not relevant for this use case, so just wait for the commands to be executed, then right click on the log and click Clear Log.

  4. Move to the panel Advanced Commands. From this panel you can send commands to the device. For this use case, the commands within HCI Extended and HCI should be the most useful.

  5. Send a reset command HCI_Reset. A UART command is sent to the device (displayed in green) and the device resets and sends back an answer.

../_images/Btool.png

Figure 112. BTool interface - Advanced Commands

Assuming you have reached this point, it means the device is properly flashed, the UART commands are properly sent and executed by the device. Now we can look at sending more test commands to the device.

  1. The HCI commands are specified by the Bluetooth Specifications. In order to offer more testing possibilities, these commands are completed by HCI Extended commands. Documentation for all these commands can be found in the API references section of the user’s guide.

  2. Only a subset of the commands will be used for testing (see below). Commands in bold are the ones commonly used:

    Continuous Wave (Non-signaling)

    Command

    Parameters

    Comments

    HCI_Reset

    none

    To reset the device

    HCIExt_EndModemTestCmd

    none

    To terminate a modem test

    HCIExt_ModemTestTxCmd

    Modulation, Channel

    For the 1M PHY only

    HCIExt_ModemTestRxCmd

    Channel

    For the 1M PHY only

    HCIExt_EnhancedModemTestTxCmd

    Modulation, PHY, Channel

    HCIExt_EnhancedModemTestRxCmd

    PHY, Channel

    HCIExt_SetTxPowerCmd

    dBm

    To set TxPower for modem tests

    Direct Test Mode - DTM (Signaling)

    Command

    Parameters

    Comments

    HCI_Reset

    none

    To reset the device

    HCI_LE_TestEnd

    none

    To terminate a DTM test

    HCI_LE_TransmitterTest

    Channel, Data Length, Data

    For the 1M PHY only

    HCI_LE_ReceiverTest

    Channel

    For the 1M PHY only

    HCI_LE_EnhancedTransmitterTest

    Channel, Data Length, Payload, PHY

    Payload to be selected from DTM standard

    HCI_LE_EnhancedReceiverTest

    Channel, PHY, modulationIndex

    HCIExt_SetMaxDtmTxPowerCmd

    dBm

    To set TxPower for DTM tests