Nap till rested, a power nap app

I would like to have a nap during the day but without falling into deep sleep. There is no way with Garmin to set the alarm to ring depending on the sleep state, that's why I've created the "Nap till rested" app: https://apps.garmin.com/en-US/apps/639b8e5f-dfa1-4ecd-b6c7-99e865622264

The app gives me the possibility to set how long (min/max) I would like to rest and a desired stress / body battery levels. Whenever I rest for a least the min-time and my stress level drops to the set target stress level or the body battery climbs to the set level, the watch will notify me. Also whenever the max-time is reached the watch will notify, regardless of the stress/body battery level.

This is also a learning place for me to learn about payment options, so I've implemented payments with kiezelpay.com. I will write about that in a separate post in the developer discussion forum.

Currently the app is only available for the Instinct 2 watch, but I will extend the support to other watched soon.

Other ideas:

  • show "statistics" on how much the user calmed down
  • export an activity (or rather passivity) to garmin see https://forums.garmin.com/developer/connect-iq/f/app-ideas/320054/nap-app
  • menu option to pay immediately and not only after the trial period - currently the user is requested to pay (after the trial period) just when a nap is started - that would be annoying
  • check not only stress but also the body battery ✓ since v1.7.0
  • check also the HR
  • of course there are a lot of code optimizations possible
  • support more devices

I would love to hear your thoughts

  • Version 1.1.0 supports now many more devices:
    DescentTm G1, EnduroTm, EnduroTm 2, Forerunner® 245, Forerunner® 245 Music, Forerunner® 255, Forerunner® 255 Music, Forerunner® 255S, Forerunner® 745, Forerunner® 945 LTE, Forerunner® 955, Instinct® 2, Instinct® 2S, Instinct® Crossover, MARQTm Adventurer, MARQTm Athlete, MARQTm Aviator, MARQTm Captain, MARQTm Commander, MARQTm Driver, MARQTm Expedition, MARQTm Golfer, fēnix® 6, fēnix® 6 Dual Power, fēnix® 6 Pro, fēnix® 6 Pro Dual Power, fēnix® 6 Pro Solar, fēnix® 6 Solar, fēnix® 6S, fēnix® 6S Dual Power, fēnix® 6S Pro, fēnix® 6S Pro Dual Power, fēnix® 6S Pro Solar, fēnix® 6S Solar, fēnix® 6X Pro, fēnix® 7, fēnix® 7S, fēnix® 7X, quatix® 6, quatix® 6X, tactix® 7

    Also a menu option is shown, to allow the user to purchase the app. If will only be shown after the watch managed to contact the kiezelpay server and to check the license status.

    1. The option to wake me up, when my body battery reached x%, but latest is 8h. 
  • A new version is online. Thank you for everyone who helped out with ideas and translations!

    Changes 1.2 => 1.3.1

    1. Italian translation
    2. debug info on the purchase view
    3. wake-up page when the time is over
    4. simple summary page that shows then duration of the nap and the change in stress-level
    5. the select/GPS button brings you from the napview to the summary view
    6. shows remaining trial period in the main menu (in the "purchase") menu item
  • After some issues with the Garmin site were solved, the version 1.4 was deployed and can be downloaded now.

    It uses significantly less battery compared to 1.3

  • In version 1.5.0 the list of supported devices grew again, a helper supplied a better translation for the Italian language and I fixed an issue with the launcher icons (https://forums.garmin.com/developer/connect-iq/f/discussion/324843/launchericon-disappeared-on-instinct2-solar-after-update-to-11-18)

  • Hi,

    Firstly, you mentioned that the app avoid getting into deep sleep, is it working ? How does it affects the nap duration ? 

    Secondly, could you show a graph showing stress during time ?

    I am trying to know how I lower stress over time and to estimate what duration has the best ratio duration/stress gain (actually stress lowering).

    Finally, can you add the sleep state in the graph ? In order to show when we are awake and the states of sleep. 

    I think your app is an excellent idea ! So thank you for implementing that app missing in Garmin.

  • I was thinking maybe adding the body battery would be a good idea... So much to do ;) 

    1. The app is working my monitoring your stress, you have to pick a stress level that you want to get down to.
      E.g. in practice it works well for me to pick min 15min, max 30min, stress: 26
      I think if I get down to stress level 26, I will not be sleeping deeply yet and I will not stay at that level too long, because the watch will wake me up when the 15min are over and I'm at stess level 26 or lower.
    2. I'm currently trying to integrate it with connect-IQ, so that it will show the stress graph and other details in the connect app, I think it would be nicer to have it shown on the mobile. But that is a bit of a struggle and maybe impossible. See my questions here: https://forums.garmin.com/developer/connect-iq/f/discussion/325086/record-stress-during-activity
      A graph only shown on the watch is an alternative
    3. sadly there is no way to check the sleep states as an app. Garmin does not allow app-developers to access that data.
    4. The body battery is definitely on the ToDo list
  • With v1.6.0 its possible to save the Nap as an activity in Connect IQ.

    Sadly the options are very limited. The only option I found is to make a 1sec activity that will be called something like "Nap Report" and for the start will show you

    1. duration of the nap
    2. start stress before the nap
    3. end stress after the nap
    4. max stress during the period
    5. min stress during the period

    I would have loved to have an activity recorded for the whole nap, but if I do that I cannot read the stress value, what is in my opinion, just a stupid limitation by Garmin
    If you are interested in the technical details you can read about my struggles and questions here: https://forums.garmin.com/developer/connect-iq/f/discussion/325086/record-stress-during-activity

  • I really like the overall idea of the app!

    I wish Garmin had some in-built nap detection, but your way of checking seems pretty smart.

    However, I can't really try it without buying, because after download and playing around with it a bit I pressed purchase just to see how it works and since that it doesn't let me start, always just show the purchase screen. I happily donate, but it's still a bug to fix.

    Also, I have an idea: would it be possible to add an option for a new way of measurement? For most people, the Garmin recorded resting heart rate is only achieved right before sleep, so I think it would be possible to measure sleep with minutes spent bellow (or after reaching) resting heart rate. This way it could record it as normal activity and have chart and everything else. I'm also pretty sure that Garmin has some hidden nap-detecting in the background to know when body battery needs to go up, so that could also be used as a source.