I am currently working with two STM32F401RE Nucleo boards with IDB05A1 Bluetooth LE extensions using the BlueNRG-MS stack. One board is configured in advertiser mode. The other boards is configured in observer mode and is supposed to print all messages received from the advertiser.
When I start the observation procedure with the vendor specific command as seen below, all works fine and I can process LE_ADVERTISING_EVENT
in the HCI_EVENT_CB
function.
aci_gap_start_observation_procedure(0x4000, 0x4000, 0x00, 0x00, 0x00);
When I try to do the same thing with the standardised Bluetooth commands as shown below, no LE_ADVERTISING_REPORT
is generated and processable in HCI_EVENT_CB
, even though the Bluetooth standard say it should.
hci_le_set_scan_parameters(0x00, 0x4000, 0x4000, 0x00, 0x00);
hci_le_set_scan_enable(0x01, 0x00);
Any ideas on what I am doing wrong?
Thanks in advance!
You will need to enable
LL_WITOHUT_HOST
mode by callingACI_HAL_WRITE_CONFIG_DATA
with parameters:However, it is recommended to stick with GAP and GATT (not to enable this mode) because the host guarantees the full compatibility with the BLE specification.