Download TruSleep data and extract ACC and PPG packets.
For now the data is only extracted and provided to an analysis
function that does nothing as printing the data as the TruSleep
algorithm is unknown.
With this patch it's possible to do sleep analysis using open source
algorithms, however it's not clear which one to use and how similar
the results would be. A possible use case would be Sleep as Android.
The extracted data contains of Accelerometer data (ACC) and
photoplethysmogram (PPG) data.
ACC packets:
- about every 60 seconds
- contain a timestamp
- contain the activity on one accelerometer axis
0x00: no activity
0xff: high activity (like walking)
PPG packets:
- contain a timestamp
- contain raw PPG samples, each with a 10msec based timestamp
This commit allows more developers and researchers to look into sleep
analysis as they gain access to the raw sleep data optained from the watch.
For issue #3860.
Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
As per the CalendarContract, the begin timestamp corresponds to the UTC
midnight-boundary of the start of the day.
- Remove the redundant logic to truncate the date to the start of day
- Remove the workaround for negative timezones (confirmed not workin
with some EDT users)
- Ensure birthdays also respect the UTC boundary
- Offset the garmin timestamps by the UTC offset, ensuring they match
midnight on the user's timezome (fixes all-day events offset by 1 day)
All the required functionality is included:
- Move the desk up and down manually
- See the current height and speed
- Store three desk positions
- Move to any of those desk positions