How does the DA14580 act as a host to initiate pairing requests and save data and enable link encryption?

⚠️
Hi there.. thanks for coming to the forums. Exciting news! we’re now in the process of moving to our new forum platform that will offer better functionality and is contained within the main Dialog website. All posts and accounts have been migrated. We’re now accepting traffic on the new forum only - please POST any new threads at//www.xmece.com/support. We’ll be fixing bugs / optimising the searching and tagging over the coming days.
2 posts / 0 new
Last post
Dionysus
Offline
Last seen:2 years 3 weeks ago
加入:2019-01-13 14:48
How does the DA14580 act as a host to initiate pairing requests and save data and enable link encryption?

How does the DA14580 act as a host to initiate pairing requests and save data and enable link encryption? I tested in the official sps_host routine that app_easy_security_request() could not successfully issue a pairing request. After the function call, I used Dongle to capture the packet and found that the DA14580 did not issue a pairing request.

Does the DA14580 do the relevant routines for the host to issue a pairing request?

Another: the connection from the opportunity to issue Security_Request, but I can not receive any callback on the DA14580, how can I receive the Security_Request from this slave?

我怎么能使LE加密后我的爸爸吗iring is successful? Is there a relevant code?

Device:
PM_Dialog
Offline
Last seen:5 hours 54 min ago
Staff
加入:2018-02-08 11:03
Hi Dionysus,

Hi Dionysus,

Since your device is acting as a central, be aware that a central cannot request security from a peripheral. If the peripheral implements security the central will understand it by the following ways:

  • when the central tries to read or write or subscribe to one of the characteristics, the peripheral will respond with an error that will indicate that this characteristic requires security in order to be read and then the stack will start the pairing procedure.
  • The peripheral will indicate that it demands security upon connection (the message that you are trying to send from the central). This message that its send to the stack via the app_easy_security_request() it sends a GAPC_SECURITY_CMD which is not supported since your device is operating as central.

Please check the ble_app_security example of the SDK. Encryption is automatically enabled when the Authentication (AUTH) is enabled on the characteristic. Also, you can have encryption on each characteristic when the Un-authentication (UNAUTH) is enabled. For more information about the security, please read theTutorial 5 : Pairing , Bonding & Securityfrom our support page. Regarding the dynamically switch, let me check and I will get back to you as soon as possible. Be aware that we don’t have any example with this functionality.

Thanks, PM_Dialog