2022-09-13 08:11 AM
2022-10-17 07:52 AM
It isn't at all obvious how you do that from the link you provided, but okay, uncle. The whitelist option isn't great if you don't know ahead of time the devices you want to whitelist. As I stated before, other vendors let you do this. You might want to think about it.
2022-09-21 04:59 AM
Hello,
There isn't any API to reject all pairing requests, it's sufficient to not answer to the pairing request. Can you explain a bit more your use case ? Are you working with a PC, a smartphone or another STM32WB ?
Best Regards
2022-09-26 05:12 AM
Sorry for the long delay, I didn't see a notice that there was a response. For my device I'm using a passkey to pair to an iOS device. The only API calls that I see that have anything to do with pairing are the ones that ask me for the passkey and tell me pairing is complete. I don't see a callback that tells me a pairing request has come in. Are you saying just don't respond to the passkey callback to effectively disable pairing?
2022-10-12 01:44 AM
Hello,
Which smartphone application are you using? Can you explain why you want to reject the pairing, if you don't ask pairing from the smartphone, I don't really understand your use case.
Best Regards
2022-10-12 04:56 AM
This isn't that hard a question. There are other BLE/microprocessor systems out there that make this easy. I know, we have fielded them. We have a custom iOS application that is part of a medical device system. You can probably understand why I want complete control of the pairing process. It should be simple to just refuse the pairing request. The ST part really can't do this?
2022-10-14 07:09 AM
Hello,
The pairing request are managed by the BLE Stack and not by the application. Indeed, there isn't any API to reject all pairing requests. If you want to have only specific devices that can connect to your device, you can use the whitelist mechanism. If you want to ignore every pairing request, you can bypass the SMP using the ACI_HAL_WRITE_CONFIG_DATA command, see STM32WB_BLE_Wireless_Interface.html documentation.
Best Regards
2022-10-17 07:52 AM
It isn't at all obvious how you do that from the link you provided, but okay, uncle. The whitelist option isn't great if you don't know ahead of time the devices you want to whitelist. As I stated before, other vendors let you do this. You might want to think about it.
2022-10-18 12:37 AM
Hello,
To bypass the SMP, call ACI_HAL_WRITE_CONFIG_DATA command with the following parameters in Ble_Hci_Gap_Gatt_Init function (app_ble.c):
static const uint8_t SMP_bypass = 0x01;
ret = aci_hal_write_config_data(CONFIG_DATA_SMP_MODE_OFFSET, CONFIG_DATA_SMP_MODE_LEN, &SMP_bypass);
if (ret != BLE_STATUS_SUCCESS)
{
APP_DBG_MSG(" Fail : aci_hal_write_config_data command - CONFIG_DATA_SMP_MODE_OFFSET, result: 0x%x \n", ret);
}
else
{
APP_DBG_MSG(" Success: aci_hal_write_config_data command - CONFIG_DATA_SMP_MODE_OFFSET\n");
}
When the SMP is bypassed, the pairing request will be ignored by the BLE Stack.
Best Regards
2022-10-19 07:10 AM
All right, just to complain a little more then: I really don't want to bypass the security manager and wonder what else happens when that's set. I have to use at least security level three for my application. This started because I was using aci_gap_set_authentication_requirement() and was surprised that the "no bonding mode" argument still let clients temporarily pair and connect it. I have a workaround for this, but it still seems to me to be a deficiency in the API.
2022-10-26 07:52 AM
Hello,
The "bonding mode" parameter allow if enabled (0x01) to store the bonding information in flash.
Best Regards