Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs
This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Filter Eddystone UUID

Greetings Friends.

I'm having some trouble trying to figure out if I'm doing this the write way or not...

I'm developing a Eddystone scanner central on SDK15 with my NRF52-DK, using the ble_app_uart_c example...

In order to do so, I changed the ble_evt_handler and added a case for the BLE_GAP_EVT_ADV_REPORT event. Inside of it, I'm filtering reports like this:

const ble_gap_evt_adv_report_t * p_adv_report = &p_gap_evt->params.adv_report;

if(p_adv_report->data.p_data[5] == 0xFE && p_adv_report->data.p_data[6] == 0xAA){
    //Add Advertise to queue...
}

This works ok... but I don't I'm not sure if I'm doing this in the most efficient way or in the best practices for the SDK...

I've also tried to implement it in the scan_evt_handler and adding a filter to eddystone UUID on scan_init but it didn't worked... (Not quite sure if I've understood the difference between the ble and scan events...)

Any thoughts? 

Parents
  • I think everyone is doing this their own way depending on their own requirements, but I would say this is the most efficient way, since you are accessing the adv_report directly. I am not familiar with the Eddystone beacon format, but I don't see any problems doing it this way as long as you are checking the exact bytes as described in the Eddystone beacon format.

    Best regards,
    Kenneth

Reply
  • I think everyone is doing this their own way depending on their own requirements, but I would say this is the most efficient way, since you are accessing the adv_report directly. I am not familiar with the Eddystone beacon format, but I don't see any problems doing it this way as long as you are checking the exact bytes as described in the Eddystone beacon format.

    Best regards,
    Kenneth

Children
No Data
Related