Acknowledged

UserProfile API returning incorrect sleepTime

I'm trying to get the user specified sleep time with the call:

var time = UserProfile.getProfile.sleepTime;

Unfortunately, the value returned does not match what is set on my Venu3.  If I set the sleep time to 12:00AM this API returns a Time.Duration representing 10:00PM.  I'm reasonably sure my code is correct because the sample app UserProfile exhibits the same error.

Note, this code and the UserProfile app both work correctly in the simulator, it's only on real hardware that there is a problem.

Parents
  • Good catch.  I changed the sleep/wake time just for today (without setting them for the rest of the week) and now the API is returning the correct times (at least for today).  I'll have to wait until tomorrow to see if the API remains correct or not.

    Tnx for the insight.

Comment
  • Good catch.  I changed the sleep/wake time just for today (without setting them for the rest of the week) and now the API is returning the correct times (at least for today).  I'll have to wait until tomorrow to see if the API remains correct or not.

    Tnx for the insight.

Children
  • For my f7 it doesn't work probably because I have 2 devices registered to the same profile.

    I've changed (on watch) sleep/wake for tomorrow, maybe watch refresh profile on midnight (after sync I can see new values in gcm).