- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What I am doing is to synchronize multiple Bluetooth devices by broadcasting non-connectable advertisement (only 1 packet) to 2 devices which are scanning. I register advertisement report function using blecm_RegleAdvReportCb. In that function, I use bleapputils_currentNativeBtClk(); to get receiving timestamp. Then, I can know time offset on those 2 devices.
In the situation that I transmit nothing else among those devices, the offset I get are very consistent. It varies only 1 - 3 unit (less than 1 ms; good enough). However, when I experimented in the situation that they transmit information continuously, the time offset is not consistent anymore with the range up to 35 units (~11 ms).
Therefore, I conclude that the callback function might start quite late after it actually receive the advertisement packet. Then, I am finding for a way to get the timestamp at the point it is receiving (not in the callback) for more consistent time offset. Is it possible? or Is there any patch for that feature?
I'm using WICED Sense.
Solved! Go to Solution.
- Labels:
-
Scanning-Advertising
-
Timers
-
WICED Sense
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Unfortunatley, because all of the tasks are queued serially within the same thread and processed in order, priority cannot be given to the advertisement report callback relative to other callbacks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
My problem is not at the broadcaster (the advertising device), but my problem is at the scanner devices.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I think it's difficult.
But, to synchronize two observers,
if you can use the timestamp of broadcaster,
boont's suggestion will work.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Is it possible to give more priority to the advertisement report callback (relatives to other callbacks that run in application thread) ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Unfortunatley, because all of the tasks are queued serially within the same thread and processed in order, priority cannot be given to the advertisement report callback relative to other callbacks.