cancel
Showing results for 
Search instead for 
Did you mean: 

BLE Scanning on single channel only

K C
Associate II
Posted on January 30, 2018 at 17:41

Hello, 

I am currently working with STEVAL-IDB007V1 evaluation board along with BlueNRG GUI, to scan/debug Bluetooth device.

For development purposes, I have advertisement packet broadcasting on a single channel only (Ch37). 

Is there a way to adjust the scanner to listen only on a single channel? I read on Bluetooth documents that there is no specific rule on scanning, but I would like to check on interval of advertisement packet right now. 

Thank you for looking into my question!

#channel #bluetooth-le #steval-idb007v1 #scanning
1 ACCEPTED SOLUTION

Accepted Solutions
Winfred LU
ST Employee
Posted on February 01, 2018 at 06:29

Hi KC,

Actually, the spec says that

the Link Layer shall use all the primary advertising channel indices.

The followed is from Bluetooth core spec, Vol 6, Part B, 4.4.3

4.4.3 Scanning State

The Link Layer shall enter the Scanning State when directed by the Host.

When scanning, the Link Layer shall listen on the primary advertising channel.

There are two types of scanning, determined by the Host: passive and active.

There are no strict timing or advertising channel index selection rules for

scanning.

During scanning, the Link Layer listens on a primary advertising channel index

for the duration of the scan window, scanWindow. The scan interval,

scanInterval, is defined as the interval between the start of two consecutive

scan windows.

The Link Layer should listen for the complete scanWindow every scanInterval

as directed by the Host unless there is a scheduling conflict. In each scan

window, the Link Layer should scan on a different primary advertising channel

index. The Link Layer shall use all the primary advertising channel indices.

Thank you.

Regards,

Winfred

View solution in original post

6 REPLIES 6
Antonio Vilei
Senior III
Posted on January 31, 2018 at 15:55

Hi,

According to the standard, you can select the channel map when you start advertising, but there is no such primitive for scanning.

In our implementation, we followed the primitives as specified by the Bluetooth SIG, so the BlueNRG-1 stack will scan on all of the three advertising channels (37, 38, 39).

Unfortunately, these primitives are asymmetrical and don't enable the use case that you have described. For the time being, there is no way to specify a single channel for scanning.

Best regards,

Antonio

Winfred LU
ST Employee
Posted on February 01, 2018 at 06:29

Hi KC,

Actually, the spec says that

the Link Layer shall use all the primary advertising channel indices.

The followed is from Bluetooth core spec, Vol 6, Part B, 4.4.3

4.4.3 Scanning State

The Link Layer shall enter the Scanning State when directed by the Host.

When scanning, the Link Layer shall listen on the primary advertising channel.

There are two types of scanning, determined by the Host: passive and active.

There are no strict timing or advertising channel index selection rules for

scanning.

During scanning, the Link Layer listens on a primary advertising channel index

for the duration of the scan window, scanWindow. The scan interval,

scanInterval, is defined as the interval between the start of two consecutive

scan windows.

The Link Layer should listen for the complete scanWindow every scanInterval

as directed by the Host unless there is a scheduling conflict. In each scan

window, the Link Layer should scan on a different primary advertising channel

index. The Link Layer shall use all the primary advertising channel indices.

Thank you.

Regards,

Winfred

Posted on February 01, 2018 at 06:34

If a scanner can scan only single channel,

chances are a scanner will never see an advertiser which only advertises on another channel.

Posted on February 01, 2018 at 16:51

Hi Winfred,

thanks for this clarification. In my previous post I was referring to the GAP (Generic Access Profile) and not to the Link Layer. As you correctly pointed out, the Link Layer must be able to scan on a single channel.

Even if supported by the Link Layer, scanning on a single channel is not supported by GAP, though. This means that users can't specify the channel when using the ACI_GAP_START_OBSERVATION_PROC and ACI_GAP_START_GENERAL_DISCOVER_PROC command.

As you already mentioned, scanning on a single channel poses the risk to miss advertisements on the other two channels. That's why it's safer to let the GAP handle all of the three advertising channels automatically.

Best regards,

Antonio

Posted on February 02, 2018 at 04:51

Hi Antonio,

Indeed. Link layer keeps the data flow and

in BLE it provides interfaces for upper layer's usage but not for application directly.

As you mentioned, the idea is also shown in ST ACI commands.

Thank you so much for making it more clear.

Best Regards,

Winfred

Posted on February 06, 2018 at 19:24

Thank you for clear answer + discussion!