BLE Scan request callback

⚠️
Hi there.. thanks for coming to the forums. Exciting news! we’re now in the process of moving to our new forum platform that will offer better functionality and is contained within the main Dialog website. All posts and accounts have been migrated. We’re now accepting traffic on the new forum only - please POST any new threads at//www.xmece.com/support. We’ll be fixing bugs / optimising the searching and tagging over the coming days.
7 posts / 0 new
Last post
mapart
Offline
Last seen:1 month 1 week ago
加入:2018-11-30 15:58
BLE Scan request callback

Hi,

Is it possible to configure a callback or get some kind of indication when the advertising device receives a SCAN_REQ packet?
I found a similar question here:
https://support.dialog-semiconductor.com/forums/post/dialog-smartbond-bl...
But I cant find the function BLE_EVENT_Handler() in my SDK.
I'm using the barebone project as a base for my application from SDK version 6.0.10.

Best Regards
Martin

Device:
PM_Dialog
Offline
Last seen:4 hours 14 min ago
工作人员
加入:2018-02-08 11:03
Hi mapart,

Hi mapart,

The BLE_EVENT_Handler() is for the SDK of the DA14580, so that’s why you are not able to find it. In the SDK version 6.0.10, the corresponding function is the dlg_event_isr() in the located to the rwble.c file. This function is triggered as soon as you get BLE_EVT_END last ble event.

Thanks, PM_Dialog

mapart
Offline
Last seen:1 month 1 week ago
加入:2018-11-30 15:58
Hi and thanks for your reply,

Hi and thanks for your reply,

In the post I linked in my previous post, the accepted answer the accepted answer mentions:
" and be able to count the scan requests that you have and also obtain the address of the scanner that issued the scan request and the PDU of the packet so that you can tell if its a connection indication or a scan request"

I'd like to be able to monitor scan_req packets and the address of the scanning device.
How can I retrieve this information?

Best regards
Martin

PM_Dialog
Offline
Last seen:4 hours 14 min ago
工作人员
加入:2018-02-08 11:03
Hi mapart,

Hi mapart,

A possible workaround for you issue would be to check if there are data packets received during the last advertising event. After that, you might check if there is a scan response packet received during the last BLE adv event. If there is, you should send an indication to application.

Thanks, PM_Dialog

PM_Dialog
Offline
Last seen:4 hours 14 min ago
工作人员
加入:2018-02-08 11:03
Hi mapart,

Hi mapart,

Could you please let us know if your issue has been fixed? I will strongly recommend you to check the DA14585/DA14586 Scan Tracking peripheral software example from our support portal. Please follow the link below:

https://support.dialog-semiconductor.com/resource/sw-example-da14585da14586-scan-tracking-peripheral

Be aware that if the Master's address isnot public addressthen the actual master device address is not exposed over the air.

Thanks, PM_Dialog

mapart
Offline
Last seen:1 month 1 week ago
加入:2018-11-30 15:58
Hi,

Hi,
The example you supplied would solve my problem.
But as you stated we might not be able to use this method if the master uses a random address.
Thanks a bunch for your support!

Best regards
Martin

PM_Dialog
Offline
Last seen:4 hours 14 min ago
工作人员
加入:2018-02-08 11:03
Hi mapart,

Hi mapart,

Glad that you figured your issue out.

Thanks, PM_Dialog