How to compare the received data over able to the specific value...

Dear team,

1. I am using the Ble_app_uart example from the SDK.

2. I had received the data successfully from the nrf_connect app.

3. Once the data was received over a ble after that I want to compare that data with string & want to perform an action accordingly.

4. if there is any example in sdk then please let me know with the above criteria.

5. please help me above senario.

Parents
  • Hello,

    The standard behavior of the example is just to forward any data received over the NUS service to the UART peripheral. This happens as part of the BLE_NUS_EVT_RX_DATA event handling in the nus_data_handler function. If you wish to modify the example to do something else with this data, or check it for some special sequence, you could implement this as part of the BLE_NUS_EVT_RX_DATA event as well / instead of the existing functionality.

    Best regards,
    Karl

Reply
  • Hello,

    The standard behavior of the example is just to forward any data received over the NUS service to the UART peripheral. This happens as part of the BLE_NUS_EVT_RX_DATA event handling in the nus_data_handler function. If you wish to modify the example to do something else with this data, or check it for some special sequence, you could implement this as part of the BLE_NUS_EVT_RX_DATA event as well / instead of the existing functionality.

    Best regards,
    Karl

Children
Related