This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

about ble_gatts_hvx

I'm doing experiments on high throughput and need to call sd_ble_gatts_hvx, but there are a lot of confusing things so it's hard to get started.

If I want to know if notify is successful, which of the following events are likely to occur and I should be concerned

1, when returning NRF_SUCCESS, it must be sent successfully, if LL layer packet loss occurs, softdevice will automatically reissue until the successful sending will return BLE_GATTS_EVT_HVN_TX_COMPLETE event

2, when returning NRF_SUCCESS, it may also send failure, if LL layer packet loss occurs, softdevice does not automatically re-send, but will also send BLE_GATTS_EVT_HVN_TX_COMPLETE event to the user, and modify p_hvx_params-> p_len

3, when returning NRF_SUCCESS, it is possible to write only part of the data to the softdevice, this time to check p_hvx_params-> p_len to see the true length of the data written to the softdevice, and then follow the case1 process

Thanks

Parents Reply
  • Sigurd was quite clear on this point, you MAY NOT modify the data buffer after you give it to the softdevice. Until you receive the message that the TX buffer has been finished with, the softdevice owns it.

    I would recommend if you have more questions you start a new topic. More people see unanswered questions than answered ones and it's better if each question deals with .. one question.

Children
No Data
Related