# How to structure your flows

**URL:** <https://community.homey.app/t/how-to-structure-your-flows/25109>\
**Category:** Flows\
**Created:** [January 27, 2020, 10:31pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109 "2020-01-27T22:31:04Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 10:31pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/1 "2020-01-27T22:31:04Z")

</div>

Posted in the flow category. Although it does not match the flow category definition, I thought this was the best place…

I would like to share my view on structuring flows. Hope its usefull for others

You will find that, in time, with more devices and sensors, flows become more complex and will cause entanglements.

This post is not about how to build a flow. But a way too keep your flows readable, less entangled and easy to understand.

If this does not work for you, [other users have other approaches](https://community.homey.app/t/how-to-alternative-approach-to-structure-and-organise-your-flows/60765). See what works best for you.

So, here we go:

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 10:31pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/2 "2020-01-27T22:31:12Z")

</div>

**How to structure your flows: using folders**

- A folder “settings” contains all Trigger flows based on time (tag: @)

- I create a folder for every zone and keep the related flows there. Since I have a lot of flows I created subfolders: settings, trigger ON, trigger OFF per zone folder

\*\* Action flows (tag: \>) are in the folder that refers to the zone where the action takes place.

\*\* Trigger flows from sensors (tag: !) are in the (sub)folder that refers to the zone the sensor is in.

\*\* Scene flows (tag: #) are in the folder that refers to the zone the scene is build for (build a scene per zone)

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 10:31pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/3 "2020-01-27T22:31:23Z")

</div>

**How to structure flows: keep flows simple**

After working a lot with flows I currently have the habit of splitting up my flows.

My personal motto is: more flows is not bad!

I use A few “types” of flows and try not mix these types in one flow (explained in more detail below)

I also use a “tag” in the naming of the flow, so I can easily recognize the type (inspired by @AcE_Krystal a few years ago)  
Update: or use icons as described by @Ploegske in the responses [below](https://community.homey.app/t/how-to-structure-your-flows/25109/29)

**My flow types:**

- _Trigger flow_: a flow triggered by a time event (tag: **@** or 🕐) or a sensor (tag: \*\*!\*\*or 📳)

Examples for naming: @ 06:50 get out of bed, ⏱ dinertime, ! Lux kitchen, 📳 PIR kitchen

WHEN typically contains a trigger like time or sensors like motion, temp, etc.

THEN typically contains a card from the flow section: “start flow” / “enable flow” / “disable flow” or change the status of a virtual devices.

THEN typically _does not_ contain cards for actual devices (lights, plugs etc).

Time triggered flows (tag: @/⏱) will often have multiple cards in the THEN

- _Action flow_: flow that starts an action (Tag: **\>** or 🚀)

Examples for naming: \> Radio ON, 🚀 lights living OFF

WHEN typically contains a card “when this flow is started” or a virtual device status change

THEN contains an action: switching devices or starting a scene flow (explained below)

- _Scene flow_: flow that defines a “scene” or “mode” (tag: **#** or 💡)

Examples of naming: 💡 kitchen bright, # movie time light living, # Alarm armed modus, # Holiday modus

WHEN contains a “when this flow is started” or a virtual device button (not a switch!)

THEN contains settings for a group of devices, lights etc in a specific zone

Keep scene flows specific to one zone that makes it easier to use them in multiple flows.

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 10:31pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/4 "2020-01-27T22:31:31Z")

</div>

**How to structure your flows: using virtual devices**

I use virtual devices (button not switch!) to start my action (tag: \>) and scene (tag: #) flows. I prefer it over using “when this flow is started”

1. Virtual devices show in which flow they are used. It makes it easier to track in which flow actions and scenes are used

2. Using virtual devices makes it easier to create new flows triggered by events.

Examples

Trigger flow that starts my day, but not every day start at the same time…

It triggers a virtual device (button not a switch!). This device is used to trigger the action flows. Remember, I keep my time trigger flows together in one folder “settings”

This is the virtual button showing the flows its triggering:

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/2/e/2e7416eb0407053a163cc6cc1eb2fe8fba547c16.jpeg)

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/2/125fa373a18b808236d38aedbb0d31fda826b37f.jpeg)

I trigger the same button at different times

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/8/4/8468ee395dea771ab54c0bb800c8fef9c96e09bb.png)  
Sleeping in on sundays…  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/d/b/dbc4480d6e12aaefb7b8ec4988c1ed2eb6d5d50b.png)

**how to structure your flows: grouping of sensors**  
In some cases you will have multiple sensors that should control the same action (scene).  
Homey only allows one card in the IF sextion. That would mean you need to create the same flow for every sensor.

Another advantage of grouping is: if you ever need to exchange a sensor you do not need to update your flows! Just make sure at least one sensor stays in the group. Add the new sensor and then remove the old one. And you are done

But there is a nice solution for it: grouping of sensors.

_Motion sensors_: this is supported by athom via the “zone activity”. In the IF section select zone & devices, select the zone that your motion sensors are in  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/c/d/cd0482c5698e9250e0fea44c80f224c6b264d462.png)

Select the desired action

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/f/5/f5323a5bcfec8b530358018d5c5c0ebf3637c87a.png)

_Other sensors (temperature, lux etc):_  
Install the [group app](https://homey.app/nl-nl/app/com.swttt.devicegroups/%3C-group-%3E/). This app allows you to group sensors and provides card to put in the flows  
IF cards:  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/a/2/a2544bb786ab127f6fef4a8adf1354967ac4997d.png)  
Action for the IF cards

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/2/b/2bb92ae9c9b67759084ed9acc869a0d40353a795.png)

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 10:31pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/5 "2020-01-27T22:31:38Z")

</div>

The trigger flows:

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/3/b/3b8d90ad8a333d1ddfe162d188bf40aa968c0a81.jpeg)

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/7/e/7e5fa7b5f6400fad8195f051663b559dfe7850ca.jpeg) ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/1/11a808b1b7d152f6a15b9e51238c9b8fc202081e.jpeg)

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 10:31pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/6 "2020-01-27T22:31:46Z")

</div>

- The action flow:

Action flow, tiggered by the virtual device from the trigger flow.  
It turns on the lights in the livingroom (unless it is light). The same trigger is used to switch on the light in the kitchen and the hallway, notice these are separate flows for every zone. I could have added kitchen and livingroom in one flow. But it would have been much harder to also build in the darkness check.

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/c/8/c8842675c5c5e49b5f5db493303ca26feb91d150.jpeg) ![image|240x4w5](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/0/3/03377e6d3c6978a12a9c31eabf33fd238be46b04.jpeg)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/2/b/2b1bead540cdae202974db766b174ebf467d09b1.jpeg) ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/a/d/ade7565e5cd08fdda586da454a2bcc2dde1ea998.jpeg)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/2/f/2fe2c8d0d232bc5da0e679b00d1ead6987f1bb7f.jpeg) ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/2/12c5028f144d19aa88a6359be8548f5a38a6286c.jpeg)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/b/5/b58b5d421e90735b47924256414227a05d768b34.jpeg) ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/e/2/e26c773a4fc290d528694966b0fd5738f926c54e.jpeg)

—

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/6/1/61e2d68522d26106a3daa34a76c9beb28f8d799f.jpeg)

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/c/8/c8842675c5c5e49b5f5db493303ca26feb91d150.jpeg)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/2/b/2b1bead540cdae202974db766b174ebf467d09b1.jpeg)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/2/f/2fe2c8d0d232bc5da0e679b00d1ead6987f1bb7f.jpeg)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/b/5/b58b5d421e90735b47924256414227a05d768b34.jpeg)

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 10:31pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/7 "2020-01-27T22:31:54Z")

</div>

The kitchen lighting is a virtual device too, but in this case a switch. This way homey knows if the lights are switched on. I use this status in other flows (ea motion triggered in the garden switches the lights on and off. But the kitchen should not go off when they are turned on)

Also notice I have 2 virtual devices (switch) that represent a status. Based on the a scene is selected. (During cleaning and diner the light should be more bright

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/b/e/be5c4883405127eddef63eef3ad9b8722a3f1acd.jpeg)

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/2/9/29e0d78810cb602cbc34035465bc1dd0a2388b0d.jpeg)

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/4/c/4c3f58e056955e14048d7a5510fb33c71a4ff84c.jpeg)

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 10:39pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/8 "2020-01-27T22:39:20Z")

</div>

- the scenes flow  
These flows actualy set the light to a desired setting

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/f/d/fd8d5bc2dad49b6fe01be460c0c1882eba9ccbc7.jpeg)

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/d/1ddd02ec1eafafef19ec6d4dfbafcc2bfb935f64.jpeg)

![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/5/4/547eefb71592cde371e51dabfb1099d3abde0fb7.jpeg)

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 10:39pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/9 "2020-01-27T22:39:50Z")

</div>

Yes it is a lot of flows. But homey is not bothered by a lot of flows. And the flows are simple, no complex AND / OR.

Advantage:

- You can easily change your dayly routines. Just change the time trigger in this one flow and all the rest is unchanged.

- Its easier to group flows in folders named after the zones in the flow section. Makes it easy to find flows

- it makes adding a flow easier: When I create a new flow that should start when I go to bed. I only need to create that flow. No need to also update the trigger flow that starts at bedtime with a “start a flow card”

- it makes you more flexible: bedtime can be different per day. So I will have multiple trigger flows for time (tag: @). When I use “start a flow”, in case of creating a new flow I would need to add that flow to every trigger flow defining bedtime.

- Easily trigger multiple action flows with one trigger. Without the flows becoming complex. The living, kitchen and hall are nicely separated.

- Because flows are split, you can use the AND column in both flows. This gives more options and makes it better readable, less complex. As you see in the flows, every room has its own lux measurement in the AND, All triggered by one timer flow.

If I want the coffeemachine to heat up, I just create an extra flow with the same virtaul device as a trigger

If I want the kitchen lights to turn on later… I just change the WHEN to an other virtual device that is linked to a different time trigger.

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 11:05pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/10 "2020-01-27T23:05:16Z")

</div>

How to structure flows: **reduce number of flows by using variables**  
Sometimes exactly the same flows are used, only with different values. Just to set different situation/scenes  
You can simplify this by using variables and just one basic flow.

Example:

- the lights in my kitchen are controlled by a lux measurement.
- but I have different situation,these require different lux to trigger: at dinner I want the light to go on a little sooner. During cleaning I really want more light, so the lights should stay on even longer

What did is:  
I have one flow triggering the lights based on lux measurement.  
“KK is donker lux” is the variable controlling the switching  
“Helderheid” is the homey tag for the lux measurement of the hue motion sensor  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/6/6/66e88fd9cb689b162cc69eec592379d4883ee4a0.jpeg)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/8/7/87aac7227d9b911c7a009aee103c408206f81d5f.jpeg)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/b/8/b8a660d2e248ff712116edf3edea9cca8751f8c3.jpeg)

In logic I created several variables that I use only to define lux Pre-sets (desired lux levels for switching)  
(You can use a value in the flow instead of these presets, but I prefer to use variables because these are easier to update and can be re-used in other flows)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/b/b/bb2ff180c794fb29c4cb4c4d32475f8543f847ef.jpeg)

Now I can control the lux level that the light switch on.  
What I do is set the value of the variable “KK is donker lux” with logic command to one of the predefined values.  
So during the day I change the value “KK is donker lux”  
When I get up:  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/9/7/97d81687250ca609989b80014f3c325c59babede.jpeg)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/b/5/b5ae73cc26800b9e4f8dd77e3cb740252e31ebc5.jpeg)

When diner starts:  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/c/4/c46014e9783bd77c56be95fdfa69595cebf1e47d.jpeg)  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/8/4/84751456d325e46eb7a71e055f14f8e26beafecb.jpeg)

Notice: I am using the virtual devices to trigger flows as described above…

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 11:11pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/11 "2020-01-27T23:11:19Z")

</div>

How to structure flows: **prepare your flows for debugging**

Bugs and strange behaviour, it will always happen.  
So you better be prepared…  
Structuring your flows makes it easier to find bugs, but you need a start for your bug search

- install a logging app (search the app store: [papertrails](https://homey.app/nl-nl/app/nu.dijker.papertrails/PaperTrails-Logboek/), [simple log](https://homey.app/nl-nl/app/nl.nielsdeklerk.log/Simple-LOG/)…)

1. Make sure _every THEN section_ in your flows has a logging point
2. If you use an AND also make sure to add a logging point in _the ELSE section_. Especially if your Else section does not have any cards! (How else can you determine if the flow triggered and hit the Else or did not trigger at all)
3. If you add a (long) delay, make sure to also add a logging point with that same delay. (After 1hr switch off the light, how will you ever trace that one if you do not log)

- set up [flow viewer](https://community.homey.app/t/how-to-view-your-homey-v2-flows-in-a-browser/7427)

1. In case of bugs, run flow viewer
2. Use the web browser to print to pdf
3. Open the file in a pdf viewer that support searching
4. Now you can search for the logging text or a device

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [January 27, 2020, 11:11pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/12 "2020-01-27T23:11:38Z")

</div>

How to structure flows: **Add comments to your flows**  
Splitting up flows can also be confusing sometimes.  
For better understand and for refernece you can add comment to a flow.

I created an app that allows you to add comment.  
Find the app description [here](https://community.homey.app/t/32251)  
And the app [here](https://homey.app/nl-nl/app/nu.fkey.CommentsForFlow/FlowNotities/)

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/8/6/865301b349ce0b5008daa98b289a8b548dc4925a.png)

---

<div class="post-metadata">

**Author:** ![tralle](https://avatars.discourse-cdn.com/v4/letter/t/b3f665/32.png) [@tralle](https://community.homey.app/u/tralle)\
**Post date:** [January 30, 2020, 9:03pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/13 "2020-01-30T21:03:13Z")

</div>

Thanks for this guide. I have not yet found a system I am happy with, so will definitely consider this when I decide to reorganize my 150 flows for the 4th time.

---

<div class="post-metadata">

**Author:** ![Bas](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/bas/32/12539_2.png) [@Bas](https://community.homey.app/u/Bas)\
**Post date:** [February 3, 2020, 9:12am UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/14 "2020-02-03T09:12:32Z")

</div>

I use almost an identical structure. it does, however, require some discipline. Some flows are fairly simple (if movement, then switch con one light) so it is tempting to just make one flow for it. Instead, the structure requires to cut up also these simple flows in two. Feels a bit like adding complexity, but it does help a lot in circumstances where unintentional or unforseen actions happen that could be triggered by several trigger-events. In these cases It took less time to identify the responsible trigger and tweak it.

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [February 7, 2020, 8:39pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/15 "2020-02-07T20:39:24Z")

</div>

I added another section with new tips atthe top…:

> [@FKey](#):
>
> How to structure flows: **reduce number of flows by using variables**

---

<div class="post-metadata">

**Author:** ![victoroos](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/victoroos/32/8344_2.png) [@victoroos](https://community.homey.app/u/victoroos)\
**Post date:** [February 27, 2020, 7:00pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/16 "2020-02-27T19:00:45Z")

</div>

I lost you a bit at the logic part. What did you do with all the different values?  
I like your flow attitude. I’ll see how I’ll work with it 🙂

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [February 28, 2020, 3:46pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/17 "2020-02-28T15:46:23Z")

</div>

Thanks for your feedback.  
I tried to clarify it a bit (old text in _italic_)

_Some flows are copied to set different situation/scenes._

Sometimes exactly the same flows are used, only with different values. Just to set different situation/scenes

Added:  
“Helderheid” is the homey tag for the lux measurement of the hue motion sensor

_In logic I created several lux settings:_

In logic I created several variables that I use only to define lux Pre-sets (desired lux levels for switching)

(You can use the value in the flow instead of these presets, but I prefer to use variables because these are easier to update and can be re-used in other flows)

_Now I can control the lux level that the light switch on._

- What I do is change the value of the variable “KK is donker lux” with logic command.\*

_So during the day I change the that value:_

Now I can control the lux level that the light switch on.

What I do is set the value of the variable “KK is donker lux” with logic command to one of the predefined values.

So during the day I change the value “KK is donker lux”

---

<div class="post-metadata">

**Author:** ![victoroos](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/victoroos/32/8344_2.png) [@victoroos](https://community.homey.app/u/victoroos)\
**Post date:** [March 2, 2020, 9:24am UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/18 "2020-03-02T09:24:29Z")

</div>

aaah, KK is donker is the minimum value when the lights don’t need to turn on.  
After that they turn on, I see. And at different moments (opstaan 9wakeup) etc you set a different required “helderheid” from the motion sensor? Right?

How would you turn on " eten"’ eg?

---

<div class="post-metadata">

**Author:** ![FKey](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/fkey/32/14793_2.png) [@FKey](https://community.homey.app/u/FKey)\
**Post date:** [March 2, 2020, 6:12pm UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/19 "2020-03-02T18:12:17Z")

</div>

> [@victoroos](#):
>
> aaah, KK is donker is the minimum value when the lights don’t need to turn on

That is correct. And I change this value based on the situation.  
The cleaninglady needs more light so I change the value to turn the lights on earlier

> [@victoroos](#):
>
> And at different moments (opstaan 9wakeup) etc you set a different required “helderheid” from the motion sensor? Right?

Nope, “helderheid” is the value that is measured by the motionsensor (tag).  
This value is compared to “KK is donker”

The value “KK is donker” is changed at different moments during the day, matching the need.

---

<div class="post-metadata">

**Author:** ![victoroos](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/victoroos/32/8344_2.png) [@victoroos](https://community.homey.app/u/victoroos)\
**Post date:** [March 3, 2020, 8:23am UTC](https://community.homey.app/t/how-to-structure-your-flows/25109/20 "2020-03-03T08:23:54Z")

</div>

ah, checked.  
And the need changes via one of the buttons or voice commands, or time of day right?

[Next page](https://community.homey.app/t/how-to-structure-your-flows/25109.md?page=2)
