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

Is it possible to refuse a connection from a central device?

I'm developing a project based on the Nordik UART Service and I wouldn't use pairing as in the example.

However I have some problem when a central device is already connected to my nRF52, if I try to connect a second central, I don't have any refuse but some sort of timeout from my second central.

It's actually possible to refuse a pairing by responding BLE_GAP_SEC_STATUS_PAIRING_NOT_SUPP on a BLE_GAP_EVT_SEC_PARAMS_REQUEST, is it possible to do something similar with connection to clearly signal to a new central device that the peripheral isn't accessible or the only asumption is that the advertisement will stop after a connection ?

Thanks

Parents
  • Imagine that 2 central a seing the advertising from the device. The first central initiate the connection with the device and it's then connected.

    The second central doesn't receive anymore the advertisement but keep a trace of the discovered device (in Android for example, you will still see the device in the list). At this moment, if you try to connect your second central to the device, there is a timeout (on my test however, I may be modified something wrong).

    I agree this is a special situation which doesn't append very often but I would like to know if there is something to handle this case or at least to understand the process behind this case.

    Based on your response, I understand that in this case, I can't refuse CONNECT_REQ packet.

    Thanks

Reply
  • Imagine that 2 central a seing the advertising from the device. The first central initiate the connection with the device and it's then connected.

    The second central doesn't receive anymore the advertisement but keep a trace of the discovered device (in Android for example, you will still see the device in the list). At this moment, if you try to connect your second central to the device, there is a timeout (on my test however, I may be modified something wrong).

    I agree this is a special situation which doesn't append very often but I would like to know if there is something to handle this case or at least to understand the process behind this case.

    Based on your response, I understand that in this case, I can't refuse CONNECT_REQ packet.

    Thanks

Children
No Data
Related