Hello,
struct net_buf_simple *ad)
{
printk("Coming in callback again and again\n");
}
Hello,
Hello,
I am terribly sorry for the slow response.
I see that you added the "coming in callback again and again" is something you have added. Please note that there is an "insert -> code" option on devzone, to insert code so that the formatting is not ignored.
Is this callback always coming from the same device, with the same address? And is this the address of one of the devices you are already connected to?
Is it possible to zip attach the projects that you are using to replicate this so that I can try on my own setup?
Best regards,
Edvin
I have attached 3 zip folders for your reference.
(you might have to change the name of the folder in order to build these projects)
1) central_uart_v1.3.2 - You will see that the device addresses are not repeated at all. You might see some addresses coming 2 times, but that's the adv type 0 and 4. The option is set to "BT_LE_SCAN_OPT_FILTER_DUPLICATE".
2) central_uart_v1.4.99-dev1_without_config - You will see that the same address come again and again even if the scan option is set to "BT_LE_SCAN_OPT_FILTER_DUPLICATE"
3) central_uart_v1.4.99-dev1_with_config - You will see that the same address WILL NOT come again and again when the scan option is set to "BT_LE_SCAN_OPT_FILTER_DUPLICATE". In this I have set the config option as CONFIG_BT_LL_SW_SPLIT=y (you can find it in the prj.conf file)
4643.central_uart_v1.3.2.zip 8666.central_uart_v1.4.99-dev_without_config.zip 2313.central_uart_v1.4.99-dev1_with_config.zip
Yes, you can keep ".connect_if_match = 0," to avoid connection.
When you run "central_uart_with_config" - Note that you see the duplicates only 2 times, which is correct. It is because of advertising data and scan response data.
When you run "central_uart_without_config" - You will see the duplicates many times (Continuously printing)
That's the difference.
Can you post terminal screenshot of both these code by keeping "connect_if_match=0" and NOT editing the scan_init() function?
..\ncs\v1.4.2\zephyr\include\bluetooth\bluetooth.h - File where "BT_LE_SCAN_OPT_FILTER_DUPLICATE" is set
Hello,
Do you have any update?
Thanks
Hello,
Sorry again for the late reply.
I talked to our Softdevice Controller team, and they said that the BT_LE_SCAN_OPT_FILTER_DUPLICATE is not implemented in the Softdevice Controller, which is the BLE stack that Nordic delivers. The reason that it was working in v1.3.0 was probably that the default BLE controller in that version was the Zephyr controller. From 1.4.0, the default BLE controller is the SoftDevice Controller from Nordic.
As far as I know there are no plans to implement this filter in the softdevice controller. If you want to do this filtering, it needs to be applied in the application layer.
It would be quite simple, I believe. Just keep track of the last N advertisement addresses in a circular buffer, and check whether or not the received advertisement is using an advertisement address from your buffer or not. Please be aware that by using such a filter, you will not receive any scan responses.
Best regards,
Edvin
How does someone know which Zephyr options are not implemented in a Nordic Softdevice (SD) Controller?
If I go to the Zephyr documentation for the BT_LE_SCAN_OPT_FILTER_DUPLICATE, would I know that that option is a Zephyr BLE controller option and not a Zephyr BLE host option? If we know what options are controller options, then we would have to know to check if we are using the Nordic or Zephyr controller to determine if that Zephyr option is supported. Right?
Hello,
This one, in particular is going to be added to the known issues page. It is currently waiting to be approved:
https://github.com/nrfconnect/sdk-nrf/pull/4122/commits/27e8b3bc4aec1d321334da26b014b7afe3aea14d
But it should be up soon.
Best regards,
Edvin
Hello,
This one, in particular is going to be added to the known issues page. It is currently waiting to be approved:
https://github.com/nrfconnect/sdk-nrf/pull/4122/commits/27e8b3bc4aec1d321334da26b014b7afe3aea14d
But it should be up soon.
Best regards,
Edvin