# Flow to set alarm wake-up time based on time going to bed and add 8 hours

**URL:** <https://community.homey.app/t/flow-to-set-alarm-wake-up-time-based-on-time-going-to-bed-and-add-8-hours/42330>\
**Category:** Questions & Help\
**Created:** [February 3, 2021, 9:13am UTC](https://community.homey.app/t/flow-to-set-alarm-wake-up-time-based-on-time-going-to-bed-and-add-8-hours/42330 "2021-02-03T09:13:26Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![G-balizer](https://avatars.discourse-cdn.com/v4/letter/g/e0b2c6/32.png) [@G-balizer](https://community.homey.app/u/G-balizer)\
**Post date:** [February 3, 2021, 9:13am UTC](https://community.homey.app/t/flow-to-set-alarm-wake-up-time-based-on-time-going-to-bed-and-add-8-hours/42330/1 "2021-02-03T09:13:27Z")

</div>

Hi all,  
Hopefully you can help me.

**Introduction:**  
When I go to bed I manually start a flow that says I’m asleep and after that other flows makes sure that lights, devices go out and logics are set.

**Flow**  
I would like to create a flow that does the following.  
When I go to bed register the time ie. 22:00 add 8 hours and set my alarm to 6:00

This way when I go to bed a little earlier or later my alarm will auto adjust to my preferred 8 hours of sleep.

I was hoping this could be done by usign logic and the option to set alarm but I haven’t found a solution yet.

So you have any ideas?

---

<div class="post-metadata">

**Author:** ![peltsi51](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/peltsi51/32/12564_2.png) [@peltsi51](https://community.homey.app/u/peltsi51)\
**Post date:** [February 3, 2021, 4:08pm UTC](https://community.homey.app/t/flow-to-set-alarm-wake-up-time-based-on-time-going-to-bed-and-add-8-hours/42330/2 "2021-02-03T16:08:04Z")

</div>

Flow1  
When this flow is started

Then start countdown timer AlarmTimer of 28800s

Flow2  
When countdown timer AlarmTimer reached 0

Then do the things you want to wake you up

---

<div class="post-metadata">

**Author:** ![G-balizer](https://avatars.discourse-cdn.com/v4/letter/g/e0b2c6/32.png) [@G-balizer](https://community.homey.app/u/G-balizer)\
**Post date:** [February 4, 2021, 9:23am UTC](https://community.homey.app/t/flow-to-set-alarm-wake-up-time-based-on-time-going-to-bed-and-add-8-hours/42330/3 "2021-02-04T09:23:44Z")

</div>

Nice!  
I also had this idea but assumed that the Countdown timer app would have issues with such large numbers. Tested it last night and this works perfectly!  
Thanks @peltsi51
