In our product we offer the ability to scan for Bluetooth advertising messages, however obviously scanning continuously requires quite a large amount of power.
If we want to scan for just a single beacon then after a while we can figure out the advertising interval and start scanning only when we expect the packet to be sent - which drastically reduces power consumption.
Is any functionality like that built into the Softdevice or Nordic SDK, or is this something we should be implementing ourselves?
I think it's a nice trick to save some extra current. Note that you would need to take into account the random 10ms delay (advDelay at 188.8.131.52.1 Vol 6 Part B Bluetooth Spec v5.0) .
I don't think we have a already made implementation for this but I don't see any reason this wouldn't work. You just need to set a scan interval matches with the advertising interval and a big enough scan window to cover the 10ms delay and the size of the advertising package.
That's great - thanks! I figured there might be some randomisation - thanks for pointing me to exactly how much - a big enough window to cover the 10ms jitter once a second still saves a bunch of power over scanning continuously.
Looking at the bit of the spec you pointed me to, the random time period is based on the time of the last (randomised) advertisement, so after 10 advertisements the next one could be anywhere within 100ms - not just 10ms. If anyone else is attempting this it's worth bearing in mind.