Hi Sai,
Please see the parameters that you need to save a device into the whitelist.
bleResult_t Gap_AddDeviceToWhiteList
(
bleAddressType_t addressType,
const bleDeviceAddress_t address
);
2. How can i "advertise only to whitelisted devices"?
You have to change the filter policy. gap_types.h gScanWithWhiteList_c
#define gGapDefaultScanningParameters_d \
{ \
gScanTypePassive_c, \
gGapScanIntervalDefault_d, \
gGapScanWindowDefault_d, \
gBleAddrTypePublic_c, \
gScanWithWhiteList_c, \
gLePhy1MFlag_c\
}
Regards,
Mario