CYBLE_EVT_GAPC_SCAN_PROGRESS_RESULT event being processed twice

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

I am running a simple code to just print the address of nearby peripheral devices. But, while trying so I figured out that for the same peripheral device the SCAN_PROGRESS_RESULT event was being called twice and hence the routine inside it was being executed twice. Is there any way I can stop this from happening?

   

I have made a simple project which just prints a character once the event is executed to verify my observation. That character was printed twice on the terminal.[Project file is attached below.]

   

Kindly provide solution/suggestion on how can I solve this problem.

   

PS:The advertising peripheral device is PRoC dongle running a Find Me profile.

   

In the future I wish to use the Service Data in the advertising packet.

0 Likes
1 Solution
AnjanaM_61
Moderator
Moderator
Moderator
5 comments on KBA First comment on KBA 5 questions asked

Hi,

   

CYBLE_EVT_GAPC_SCAN_PROGRESS_RESULT will get trigger when the Central will receive adv data from any BLE peripheral. So what you were seeing may not be the same device, it will be different devices.

   

Please refer our Central projects for reference: https://github.com/cypresssemiconductorco/PSoC-4-BLE/tree/master/100_Projects_in_100_Days

   

Refer Day 10, 11

   

Thanks & Regards,

   

Anjana

View solution in original post

0 Likes
2 Replies