problem: in BLE data length negotiation , In the response from slave tx doesnt go above 216, and rx doesnot go above 54.
s140
Experimental UDP example - sdk v16.0 (UDP example)
Gatt module added and initialized
MIN_CONN_INTERVAL 6 // increasing or decreasing this doesnt have any effect
MIN_CONN_INTERVAL 6 /// increasing or decreasing this doesnt have any effect
static void gap_params_set(void)
{
memset(&m_gap_params, 0x00, sizeof(m_gap_params));
BLE_GAP_CONN_SEC_MODE_SET_OPEN(&m_gap_params.sec_mode);
m_gap_params.appearance = BLE_APPEARANCE_UNKNOWN;
m_gap_params.p_dev_name = (const uint8_t *)DEVICE_NAME;
m_gap_params.dev_name_len = strlen(DEVICE_NAME);
m_gap_params.gap_conn_params.min_conn_interval = (uint16_t)MIN_CONN_INTERVAL;
m_gap_params.gap_conn_params.max_conn_interval = (uint16_t)MAX_CONN_INTERVAL;
m_gap_params.gap_conn_params.slave_latency = SLAVE_LATENCY;
m_gap_params.gap_conn_params.conn_sup_timeout = CONN_SUP_TIMEOUT;
}
in sdk_config:
NRF_SDH_BLE_GAP_DATA_LENGTH 251 NRF_SDH_BLE_GAP_EVENT_LENGTH 320 NRF_SDH_BLE_GATT_MAX_MTU_SIZE 247
case BLE_GAP_EVT_DATA_LENGTH_UPDATE_REQUEST:
{
NRF_LOG_DEBUG("BLE_GAP_EVT_DATA_LENGTH_UPDATE_REQUEST");
ble_gap_data_length_params_t response = {
.max_tx_octets =100,
.max_rx_octets = 100,
.max_tx_time_us = BLE_GAP_DATA_LENGTH_AUTO,
.max_rx_time_us = BLE_GAP_DATA_LENGTH_AUTO
};
ble_gap_data_length_limitation_t lims;
ret_code_t err_code;
err_code = sd_ble_gap_data_length_update(p_ble_evt->evt.gap_evt.conn_handle, &response, &lims);
.....
.....
returned error code is : NRF_ERROR_RESOURCES
ble_gap_data_length_limitation_t shows:
tx limit 0
rx limit 46
tx_rx_time_limit 0x00
If I try this:
err_code = sd_ble_gap_data_length_update(p_ble_evt->evt.gap_evt.conn_handle, &response, &lims);
and observe OTA using sniffer I see: from master

and response from slave as:
