our device has current limitations in the range of 1mA. We were examining several ways to limit the actual connection parameters to keep current consumption low. But one will find always central devices which do not do it the "expected" way.
So the current idea is to catch current peaks thru omitting connection intervals thru slave latency.
Unfortunately the communication is bidirectional, so the mice example does not really fit.
I'm wondering now, if the following setup is legal, because documentation is not very clear about this and tests showed that it might work:
"allow communication" is done by "sd_ble_opt_set( BLE_GAP_OPT_LOCAL_CONN_LATENCY, latency=0 )",
"delay communication" is done by "sd_ble_opt_set( BLE_GAP_OPT_LOCAL_CONN_LATENCY, latency=3 )".
Comments / suggestions are highly welcome!
In general I would not recommend that you use the Local connection latency feature as there is a risk your device might disconnect in case of a channel map update or other procedures that happens at a specific instanse (the local slave latency feature is proprietary and will work most of the time, but there are corner cases that will lead to link loss). In stead I could recommend using the standard slave latency if possible.
thakns for the input. With standard slave latency I guess you mean the API sd_ble_gap_conn_param_update()? This is too slow.
In my case the 7.5ms connection interval during connection setup is the problem. Some Android devices ignore the requested parameters and instead try to use 7.5 slots which is too fast for the current limited device.
I recognized, that even when setting the local slave latency, the radio notification still shows 7.5ms connection intervals. Which means, that the device "crashes". Really too bad.
Any other idea how to switch temporarily the radio to slow motion?
If you are able to work around this by using the local connection latency feature until the connection parameter update is finished you can do that. But be aware that there is a risk you might loose the connection if you use the local connection latency feature. but if you run out of power I guess you are in the same situation...
Unfortunately the local slave latency does not seem to work... is there another way to make the softdevice ignore connection intervals?
EDIT: I'm sorry, there is no other way to force the softdevice to ignore connection events. What do you mean when you say it does not work? what is returned in the sd call? and are you following the guidelines in the documentation?