2020-05-15 02:32 AM
Hi,
I am trying to use resolvable private addresses with BLE on two STM32WB-NUCLEO, one acting as P2PClient, one as P2PServer.
The Architecture i would like to realize is:
I have thought about this implementation:
I succeeded in direct advertise and connect with public addresses (for now only one server), now i am trying to switch to resolvable private addresses. For semplicity, right now i am using the the same IRK for both part, client and server.
I am following AN5289 "Building wireless applications with
STM32WB Series microcontrollers", in particular chapter 6.7.
in aci_gap_init() i have set the privacy as 0x02, in order to not resolve the addresses in code but automatically.
I am finding difficulties in compile aci_gap_add_devices_to_resolving_list() , in particular in the Whitelist_Identity_Entry_t. This structure has 2 fields, the first is intended to select the type of address to add in whitelist, so i picked "0x01: Random (static) Identity Address", but i don't understand the second one. If addess is resolvable, it has a random part and the hash, and i can resolve it using the IRK key, so what should i write here? if part of the address is random i can't forecast it, so it is impossible to know witch will be the address, also if i have the IRK.
How can i add all the IRK keys of the servers to the client? I have read that is possible to "add keys", but i have not found an API that is specific for this.
Is there some example of using of resolvable private addresses? I have searched on the web but found nothing.
Thank you in advance
Lorenzo