I want to send Tx power in advertisement packet.
Currently I am using following code.
I want to send Tx power in advertisement packet.
Currently I am using following code.
Hi,
There is not direct dependency between when you set .advdata.p_tx_power_level and call sd_ble_gap_tx_power_set(). It is in theory possible to dynamically change the output power at any time by calling sd_ble_gap_tx_power_set(). However it make sense to call it before you start advertisement.
Best regards,
Kenneth
Hi Kenneth,
Thanks for your reply.
However it make sense to call it before you start advertisement.
Is there a way by which I can update the advt. packet to transmit the power level without starting and stopping the advertisement?
I mean in my application, I change the transmit power as needed but everytime restarting the advertisement is not feasible.
How can I update .advdata.p_tx_power_level to show the change in power in advt. packet?
Check out this thread, which I think discuss the same:
https://devzone.nordicsemi.com/f/nordic-q-a/55296/how-to-update-advertised-tx-power