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

How to Respond with pairing unsupported

Again I am asking a question I should not because I cannot find it documented.

I get a pairing request from the central. I need to respond with sd_ble_gap_sec_params_reply()

There is a status parameter in the method and that I figure I can set to BLE_GAP_SEC_STATUS_PAIRING_NOT_SUPP. But what about the remaining parameters? There is nothing in the documentation which indicates how to set the other fields when I set the status to BLE_GAP_SEC_STATUS_PAIRING_NOT_SUPP. I want to set them to NULL but there may be a NULL check in there that returns an error.

Found no help in the GAP sequence diagrams either.

So how do I respond to a pairing request with BLE_GAP_SEC_STATUS_PAIRING_NOT_SUPP?

Parents Reply
  • I think you misunderstand the question. I am not getting the error, but I have GOTTEN a pairing request ( BLE_GAP_EVT_SEC_PARAMS_REQUEST,)  from the client but I do not support pairing. I want to send that error message to the client in the sd_ble_gap_sec_params_reply().

    However, there is nothing in the documentation that says how I should populate the remaining fields (keys and other stuff) when I set the status entry to BLE_GAP_SEC_STATUS_PAIRING_NOT_SUPP.

    I WANT TO SEND THE ERROR IN RESPONSE TO THE CLIENT REQUEST, I am not getting an error from the client!

Children
Related