This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Significant difference in connection time with different adv intervals

Hi,

I have the following set up:

The remote: nrf51822 acts as central

The wheels: Each wheel has nrf51822 acting as peripheral.

The remote needs to first connect(at time: T1), then bond with both the wheels, exchange some handshake information regarding wheel status with both wheels, then proceed to active mode at time: T2(where both wheels are controlled by the remote).Connection interval is : 7.5msec to 30msec.

Case 1: When both wheels have advertisement interval as: 50msec, T2-T1 is less than a second.

Case 2: When both wheels have advertisement interval as: 200msec, T2-T1 is approximately 3 seconds.

Why is the huge time difference (more than a second) in case 1 and 2? Is this an expected behaviour?

Thanks.

  • Hi run_ar, thanks for the reply. What if I have advertisement interval as 200msec and scan window as 1000msec and scan interval as 2000msec? Then, more chances are for not missing all 5 advertisement packets (0 to 1000msec has five 200 msec advertisement packets). Will there be any problems in this set up?Your thoughts, please.

  • As long as you only need to interact with one device that would probably be fine. But you risk that it still takes a couple of seconds to establish the connection. If you are interacting with several devices I would recommend that you use a shorter scan interval, i.e. something that matches your connection interval.

  • Hi run_ar,

    thanks for the reply.

    I thought that once connection has established, if the connection interval is short and frequent that would have less impact even if the scan interval is long - please correct me if I am wrong (in my case, my min connection interval = 7.5msec and max connection interval = 30msec; adv interval = 200msec; scan window = 300msec and scan interval = 600msec). In other words, do you mind explaining the relation between the connection interval and scan interval in my case and the cons of having the above settings in my set-up once the connection has established? Thanks. 

  • The problem is the scanner will block the radio for 300 ms during the scan window. So you need a connection supervision timeout that is long enough to allow that, and accept that you could get that amount of latency on the connection. For reference the scheduling documentation for the SD is available here.

Related