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

ble pairing after poweroff mode

kindly check this thread at first

my question is when I tried to power off the system using sd_power_off(); then waked up the system then try to connect, it requests to pair again,

my question is how to save the pairing information to be used after the wake up of the power off mode.

Parents
  • When the system is woken up from system off, a system reset is applied and all the short term keys will be lost. Also the peer to which your device was connected will forget this keys because going to system off means the peer device most probably disconnected from your device. Which means that even if you have saved paring STK, you wont be able to use it as the peer will not recognize it. Use bonding instead of pairing in this case.

Reply
  • When the system is woken up from system off, a system reset is applied and all the short term keys will be lost. Also the peer to which your device was connected will forget this keys because going to system off means the peer device most probably disconnected from your device. Which means that even if you have saved paring STK, you wont be able to use it as the peer will not recognize it. Use bonding instead of pairing in this case.

Children
Related