This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Porting code from S332 V2.0 to V4.0, BLE_ERROR_NO_TX_PACKETS

With version v2.0 of S332, I checked for a return of BLE_ERROR_NO_TX_PACKET when using the ble_nus_string_send function. I use this test in a routine which writes buffers larger than 20.

When I ported to v4.0 of S332 I see that BLE_ERROR_NO_TX_PACKET is no longer defined in ble_err.h.

I have searched the softdevice API for a replacement, but I can't find a replacement error code. Is there an equivalent error code in v4.0 of the S332 softdevice?

Parents
  • Hi,

    In S332 v4.0, BLE_ERROR_NO_TX_PACKETS has been replaced by NRF_ERROR_RESOURCES.

    The application packet concept has been replaced with a dedicated transmission queue for Handle Value Notifications. The number of Handle Value Notifications that can be queued is configured by ble_gatts_conn_cfg_t::hvn_tx_queue_size. When the queue is full, the sd_ble_gatts_hvx() function will now return NRF_ERROR_RESOURCES. BLE_ERROR_NO_TX_PACKETS / BLE_ERROR_NO_TX_BUFFERS is no longer used. A BLE_GATTS_EVT_HVN_TX_COMPLETE event will be issued as soon as the transmission of the notification is complete

Reply
  • Hi,

    In S332 v4.0, BLE_ERROR_NO_TX_PACKETS has been replaced by NRF_ERROR_RESOURCES.

    The application packet concept has been replaced with a dedicated transmission queue for Handle Value Notifications. The number of Handle Value Notifications that can be queued is configured by ble_gatts_conn_cfg_t::hvn_tx_queue_size. When the queue is full, the sd_ble_gatts_hvx() function will now return NRF_ERROR_RESOURCES. BLE_ERROR_NO_TX_PACKETS / BLE_ERROR_NO_TX_BUFFERS is no longer used. A BLE_GATTS_EVT_HVN_TX_COMPLETE event will be issued as soon as the transmission of the notification is complete

Children
Related