Hello,
I'm trying to determine the actual used data rate for the coded PHY but cannot find the corresponding API / data structure / enums.
Am I missing something? Can someone give me a pointer?
Regards
Hardy
Hello,
I'm trying to determine the actual used data rate for the coded PHY but cannot find the corresponding API / data structure / enums.
Am I missing something? Can someone give me a pointer?
Regards
Hardy
Hello Vidar,
as far as I understood, one can specify multiply PHYs for the secondary. So used PHY is not clear.
Number of packets is a connection optimization which I would like to set to 6 (central supports this) if 1MBps PHY is used and to two if PHY_CODED is used.
Also the connection interval has to be set accordingly, especially if you have power constraints, so that a maximum of 10ms radio time is allowed in a certain interval.
So... how to determine used PHY?
Thanks & kind regards
Hardy
Hello Hardy,
Do you have an existing application that switches between multiple PHYs? You can't specify multiple secondary PHYs for a single adv. set nor does the softdevice support configuration of multiple sets.
I would recommend you try the nRF Sniffer for Bluetooth LE if you want to check what happens on-air.
Kind regards,
Vidar
Hello Vidar,
sorry... I guess I mixed up several things. I also meant the central in this case.
For the peripheral the procedure is to my understanding as follows:
So no problem here.
But for the central:
For your understanding: there is already a working application which uses 1MBit and we are currently discussing how to introduce PHY_CODED etc.
Thanks for your support & regards
Hardy
Hello Hardy,
I agree with your summary of the peripheral role. Except it's still not clear to me why you need to change the connection interval for the long range mode. You are not guaranteed 6 packets per connection event even if the interval is long enough. Does it have something to do with how you handle the transfer in your application maybe?
rgrr2 said:advertisement packets are coming in, but it is not clear (to me), which PHYs the peer is supporting
You can read the this from the ble_gap_evt_adv_report_t struct included with the BLE_GAP_EVT_ADV_REPORT event.
Regards,
Vidar
Hello Vidar,
apologies... I would like to reply to your latest post, but unfortunately this is not possible because there is no button to do it.
Anyway: I understood, that on the central side one has to get an advertisement to know the PHY used by the peripheral.
But what if the connection has been created via sd_ble_gap_connect() with a known peripheral so that no advertisements had to be received ahead?
To answer your question: changing the connection interval is a matter of power/speed optimization. Our peripheral tries to send as many packets per event as the central is accepting. Sometimes the behavior of the central (esp Androids) is not very consistent and we try to offer the central several connection parameters until both sides are happy.
Kind regards
Hardy