This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to create unique reverence code to connect to app

Dear Community,

We are working on a bike finding device that you connect with trough an app. When you are in range of the device you can press a knob on the app and it will show the location. 

We want to give every nRF52810 a unique number or code so that the app can have a first time connection trough BLE and lock this number to a personal account. This way only 1 person with that account can connect to the device with the app. 

Are there any solutions for this? We wanted to change the UUID but that isnt the solution. 

Thank you!

  • Hello,

    I believe what you are looking for is something called bonding. 

    This is typically what is used with personal Bluetooth devices. 

    So all your devices will have the same UUID. If the device never connected to a phone, it advertises, and anyone can connect. The first time it connects, the devices pair (enables encryption) and bond (stores the encryption keys for later use). That way, the next time the device is turned on, it will use something called directed advertising, indicating that it will only connect to already known devices that are previously bonded. 

    I don't know what SDK you use (Legacy SDK or NCS), and the pairing/bonding procedure is done a bit differently depending on the SDK. Look into if you can figure out how to enable bonding, or if you can find an example/sample that already does this by default.

    Best regards,

    Edvin

Related