I would like reduce TX Power in DFU secure bootloader, I would like use sd_ble_gap_tx_power_set function but I faced with the following problem, I don't know how to get conn_handle.
I saw nrf_dfu_ble.c file and saw static variable m_conn_handle but how can I extract it without code modification?
My approach the following:
Any advice? Any other ways to change TX power?
Thank you!
static void dfu_observer(nrf_dfu_evt_type_t evt_type)
{
switch (evt_type) {
case NRF_DFU_EVT_TRANSPORT_ACTIVATED:
sd_ble_gap_tx_power_set(
BLE_GAP_TX_POWER_ROLE_CONN,
0, //WTF? How to get conection handle?
-16);
break;
}
}Any advice? Any other ways to change TX power?
Thank you!