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

How to disconnect and enter to advertising without reconnecting to latest device

Hi,

On a button press I need to enter to disconnect from the currently connected device and then start advertising in order to allow a new device to connect.

I manage to disconnect and put the device in FAST_ADV but when the master device detects it, it sends a connection request, so I need to prevent the nrf from accepting connection queries from the latest master. 

How to do that ?

Thanks a lot for your help.

Parents
  • Unfortunately, we don't have a blacklist feature, only the whitelist. If you need to blacklist a device the only option I see is to check the address on the connected event, and disconnect if it is the blacklisted device. After x amount of tries, the peripheral should inevitably connect to the second master instead of the initial master device. What kind of filter did you have in mind?

    If you are developing the master side of this application as well, you can, for example, set a delay after a disconnect before it starts scanning again. This should give your advertising device a few seconds to advertise to any other scanners before it is connected to the initial master again.

    Best regards,

    Simon

Reply
  • Unfortunately, we don't have a blacklist feature, only the whitelist. If you need to blacklist a device the only option I see is to check the address on the connected event, and disconnect if it is the blacklisted device. After x amount of tries, the peripheral should inevitably connect to the second master instead of the initial master device. What kind of filter did you have in mind?

    If you are developing the master side of this application as well, you can, for example, set a delay after a disconnect before it starts scanning again. This should give your advertising device a few seconds to advertise to any other scanners before it is connected to the initial master again.

    Best regards,

    Simon

Children
No Data
Related