I am trying to retrieve my sleep data in REAL TIME. I cannot find how to achieve it from docs: UP Platform Android SDK
P.S. : I am willing to conduct sleep experiment th
Using the UP APIs, the closest you can get to real time updates is to have your application register for PubSub event notifications for sleep events:
There are two limitations that will keep these event notifications from occurring exactly in real-time:
Regarding #1, the band (UP24 and newer) must have an active bluetooth connection with the phone and then syncs will usually occur within 15 minutes.
For #2, calculation of the different sleep phases currently requires reviewing the band data for the entire sleep event, so the API cannot send individual event notifications for phase changes.