I have a lot of simple devices that have no battery backed clock but do BLE (Pi Pico W and ItsyBitsyNRF52840). When they are switched on, I want them to get the current time and date using BLE from my phone so they can timestamp their data. They should not have to connect, rather just read a BLE advertisement that contains the current time.
Is there a Android app that broadcast the current time (Beacon Simulator)?
Is there a Beacon that broadcasts the current time?
My projects need the current time from a phone
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- bobr530
- Posts: 6
- Joined: Mon Jul 06, 2015 4:23 pm
- mikeysklar
- Posts: 13936
- Joined: Mon Aug 01, 2016 8:10 pm
Re: My projects need the current time from a phone
Did you take a look at BLEClientCts? It mentions iPhone/iPad not Android which might be a deal breaker for you if it is limited to iOS.
https://learn.adafruit.com/bluefruit-nr ... eclientctsBLEClientCts is a helper class that implements adopted Current Time Service , which enables you to receive time from devices such as an iPhone or iPad.
- bobr530
- Posts: 6
- Joined: Mon Jul 06, 2015 4:23 pm
Re: My projects need the current time from a phone
Thanks, I am looking into it. I suspect it requires pairing with each individual device and would involve fidgeting with the phone. I would be activating dozens of sensors in a short period of time and would not have time to deal with pairing. In a Beacon scenario, I would turn on the Beacon app which would continuously broadcast the current time and each device would scan for it as needed.
- mikeysklar
- Posts: 13936
- Joined: Mon Aug 01, 2016 8:10 pm
Re: My projects need the current time from a phone
Yes, the BLEClientCts example does require pairing. However, it is the only example I can find to get time so it might be worth experimenting with enough to get working and then try to find away around the pairing process.
Please be positive and constructive with your questions and comments.