Report
2 months, 3 weeks ago.

Get BLE connection parameters on ble.gap().updateConnectionParams()

Hi,

I am wondering if it is possible to retrieve the current connection parameters (connection interval, slave latency etc...) on a BLE peripheral device that is requesting to update connection parameters to a central?

I am a bit surprised that there is no immediately obvious way to do this. I am using an nRF52832 at the moment but this would be a useful feature to have available on a number of other platforms too.

Kind regards, Adam

Comment on this question

1 Answer

2 months, 2 weeks ago.

Hi Adam,

Since Mbed OS already introduced Arm Cordio BLE stack, which is mainly used in Mbed OS and is with complete BLE5 feature, to enable Cordio, please modify mbed_app.json https://github.com/ARMmbed/mbed-os-example-ble/blob/f75c72dac3f80f1500d3454f6830fbd432f1a52c/BLE_BatteryLevel/mbed_app.json#L15.

Back to your question, you can get the negotiated connection parameters through the event void GenericGap::on_connection_update(const pal::GapConnectionUpdateEvent &e).

Thanks, Desmond, team Mbed


To post an answer, please log in.