cancel
Showing results for 
Search instead for 
Did you mean: 

I would like to establish secure connection between nucleo stm32wb55 and mobile phone

JKore.6
Associate

In application note AN5289 page 35 it is written that you need to wait for the connection to be established and then call aci_gap_set_pairing_req(). 

I call this function when connection established event happens, but when I do this return status is 0x46 -> BLE_STATUS_NOT_ALLOWED. 

My question is if this is the right time to call this function, should I call any other function before or this status flag has to do something with wrong settings before the function call?

Do you happen to have an example of how security pairing is established, or maybe an application note that I missed?

Thank you in advance,

Jaka

1 REPLY 1
Remi QUINTIN
ST Employee

This error received by the master means that the slave device is not ready to receive the command.

This should happen after the connection is complete.

The salve device  has to send an aci_gap_slave_security_req command to request a secure connection  while the  master has to send an aci_gap_send_pairing_req command when it is the initiator of the secure connection.

Please have a look at the Hearth Rate example in CubeWB FW pacakge.