# Advanced Flows - Structuring of flows

**URL:** <https://community.homey.app/t/advanced-flows-structuring-of-flows/65348>\
**Category:** Questions & Help\
**Tags:** advancedflow\
**Created:** [July 1, 2022, 9:12am UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348 "2022-07-01T09:12:19Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jo\_San](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jo_san/32/3732_2.png) [@Jo\_San](https://community.homey.app/u/Jo_San)\
**Post date:** [July 1, 2022, 9:12am UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/1 "2022-07-01T09:12:19Z")

</div>

With the “old” flows, I ended up with some kind of structure to get a grip on the large number of flows.  
I divided them in “actions” and “triggers”. The trigger-flows started one or more action-flows.

Now with the Advanced Flows, it brings nice possibilities to re-structure flows and make things way more insighful.

My first idea would be to combine all flows on a “subject” (for example “sunscreens”) in 1 Advanced Flow. That will work for all flows that are triggered by an event other than a manual start.  
I am in doubt what to do with a manual start, as an advanced flow can only have one “start” element. For instance with the sunscreens, if you have multiple sunscreens and would like to manually start a flow to open close only one of them, that would be hard to achieve. Or is there a way to start a flow with an additional parameter? E.g. “start flow Sunscreens action=close item=front-window”?

I am very curious on how you guys structure your flows. All ideas are welcome!

---

<div class="post-metadata">

**Author:** ![Peter\_Kawa](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/peter_kawa/32/173848_2.png) [@Peter\_Kawa](https://community.homey.app/u/Peter_Kawa)\
**Post date:** [July 1, 2022, 12:30pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/2 "2022-07-01T12:30:18Z")

</div>

Below is a nice example I think.  
Replace the Fibaro switches (they trigger the 2 flows at the bottom) by virtual switches and you can manually control the screens

In case you’d like to use the mobile phone fav flow widgets, you can create flows with “this flow has started” which  
control the created virtual switches, one for up and one for down.  
Then add them to fav flows.

 ![2022-06-30_19-28-58](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/e/5/e5a15499f536de557645bd26c8f1094fd31d2236.png)

Source

> [@Advanced Flow Zonnescherm](https://community.homey.app/t/advanced-flow-zonnescherm/65304):
>
> Hallo Homeys, Ik heb zojuist mijn eerste advanced flow gemaakt. Ik ben redelijk nieuw met de Homey dus kan we wat inspiratie gebruiken om deze flow verder te optimaliseren. Ik maak gebruik van de Fibaro Rolluikschakelaar 3, de buienrader app, de Openweather app. En de variabelen Zonnescherm Uit Nee/Ja en Donker Nee/Ja Het zonnescherm kan ook met een dubbele pulsschakelaar worden bediend en ik vermoed dat zeker op dat vlak de Adv. Flow verbeterd en geoptimaliseerd kan w…

---

<div class="post-metadata">

**Author:** ![Michel\_Bos](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/michel_bos/32/5481_2.png) [@Michel\_Bos](https://community.homey.app/u/Michel_Bos)\
**Post date:** [July 2, 2022, 5:21am UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/3 "2022-07-02T05:21:44Z")

</div>

Hi there,

to start: nice flow on your sunscreen! With Advanced Homey, we can make ‘art’ 🙂

I had the same idea as yourself, structure per function. SO “Light living room”, “Sonos, follow me” (about Sonos joining when I arrive upstairs with music downstairs and leaving it when I leave again), “TV downstairs” (On and Off, only to keep it simple. The lowering of the temp outside the TV room, I want to place in another flow, as also Pausing Sonos, and dimming lights in other rooms etc).

So, till now, clustering ‘same’ functions.

Keep up the fun with these Advanced flows!

Michel

---

<div class="post-metadata">

**Author:** ![Mats\_Johnson](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mats_johnson/32/56590_2.png) [@Mats\_Johnson](https://community.homey.app/u/Mats_Johnson)\
**Post date:** [July 4, 2022, 3:44pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/4 "2022-07-04T15:44:28Z")

</div>

Hi, I really like the advanced flows.  
If I have a flow that can be started with a parameter, is it possible to also add a when-card that triggers at a specific time and gives the parameter (“Start tag”) a value, or would I need to have that timer card in a different flow?

---

<div class="post-metadata">

**Author:** ![Jo\_San](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jo_san/32/3732_2.png) [@Jo\_San](https://community.homey.app/u/Jo_San)\
**Post date:** [July 4, 2022, 4:36pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/5 "2022-07-04T16:36:36Z")

</div>

Not entirely sure what you mean but you can have multiple When cards in a flow.

---

<div class="post-metadata">

**Author:** ![Mats\_Johnson](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mats_johnson/32/56590_2.png) [@Mats\_Johnson](https://community.homey.app/u/Mats_Johnson)\
**Post date:** [July 4, 2022, 5:37pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/6 "2022-07-04T17:37:22Z")

</div>

Yes, but can you create a value for the “Start tag” from a timer when-card?  
I just tried to start the same flow again using a “Start flow card” with a parameter, and that worked,  
but is there a way to do the same thing without doing that?

---

<div class="post-metadata">

**Author:** ![Mats\_Johnson](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mats_johnson/32/56590_2.png) [@Mats\_Johnson](https://community.homey.app/u/Mats_Johnson)\
**Post date:** [July 4, 2022, 5:56pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/7 "2022-07-04T17:56:12Z")

</div>

![Screenshot 2022-07-04 at 19.53.09](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/f/f/ffc0ee60d1e89f3153331ae8387ed62d4b5dbf56.jpeg)

This is how I can do it by having the flow start itself. What I’m wondering is if there is a way to instead use some card to set the “Start tag” and draw a line to the “Logic card”.

---

<div class="post-metadata">

**Author:** ![Jero](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jero/32/17556_2.png) [@Jero](https://community.homey.app/u/Jero)\
**Post date:** [July 4, 2022, 6:00pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/9 "2022-07-04T18:00:22Z")

</div>

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

Like this?

---

<div class="post-metadata">

**Author:** ![Mats\_Johnson](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mats_johnson/32/56590_2.png) [@Mats\_Johnson](https://community.homey.app/u/Mats_Johnson)\
**Post date:** [July 5, 2022, 7:42am UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/10 "2022-07-05T07:42:42Z")

</div>

Nice, I’d missed that there was a way to create constant tags.  
But still, it’s then a “Converted tag”. I tried transforming the “Start tag” to a “Converted tag” as well,  
but even if they have the same name, they’re not the same tags apparently.  
Is there a way to merge tags from different paths into one tag?  
Otherwise probably the only way is to convert them to a chosen arrow by duplicating the logic condition.

---

<div class="post-metadata">

**Author:** ![JMH](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jmh/32/29230_2.png) [@JMH](https://community.homey.app/u/JMH)\
**Post date:** [July 7, 2022, 9:59am UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/11 "2022-07-07T09:59:55Z")

</div>

Still building here, but will keep trigger- and action-flows separately. Action-flows will be merged. For example one flow for lights in one room, instead of one flow for lights on, one for lights off, one for lights in movie-setting, one for lights for reading, and so on.  
I’m going to do (try) the samething for sunscreens, Sonos and more.

Triggers I will merge to all the same type of triggers in one advanced flow, from there I will start te action-flows. For example al zone activities on one canvas.

---

<div class="post-metadata">

**Author:** ![Eternity](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/eternity/32/102113_2.png) [@Eternity](https://community.homey.app/u/Eternity)\
**Post date:** [July 8, 2022, 1:03pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/12 "2022-07-08T13:03:51Z")

</div>

Today I activated Advanced Flows on my Homey Pro and I am now trying to rewrite standard flows to AF’s. I have a question and hope I am allowed to ask it here…

This was the standard flow:

 ![Schermafbeelding 2022-07-08 om 14.23.12](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/8/7/8776759b56aa4a6f16bc0df1cfffefd51a2b05f9.jpeg)

In AF I made it like this:

 ![Schermafbeelding 2022-07-08 om 14.55.01](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/8/d/8d9ea3c0b68035a411ecc55500370380472dca45.jpeg)

But could also make it like this:

 ![Schermafbeelding 2022-07-08 om 14.57.02](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/4/14ab3f61842c401e8ef64a1f12b2df09ba34a242.jpeg)

Is this correct??

Also, in the old flow I could run a test and visually see which of the conditions failed. In AF I can run a test, but only the second AF shows proper feedback. Here:

 ![Schermafbeelding 2022-07-08 om 15.00.03](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/2/f/2fd29e8184feb2ba243956ed931980bb99147e48.jpeg)

The other AF shows feedback in the ALL box, but it does not follow with an action. Why is that?

 ![Schermafbeelding 2022-07-08 om 15.01.20](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/5/15bdf7d75a513ce777e732fad67bef2e396bb876.jpeg)

---

<div class="post-metadata">

**Author:** ![Jo\_San](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jo_san/32/3732_2.png) [@Jo\_San](https://community.homey.app/u/Jo_San)\
**Post date:** [July 8, 2022, 1:11pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/13 "2022-07-08T13:11:09Z")

</div>

In your first example, you should connect the start tag to all the “And” tags.  
So you either connect them parallel (connections from the start to all the And), or you do it serial, like in your second example (which should work).  
Testing of all the conditions can only be done if you connect in parallel, because otherwise the cards are only executed one after another. So if the first is false, the flow stops.

---

<div class="post-metadata">

**Author:** ![Eternity](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/eternity/32/102113_2.png) [@Eternity](https://community.homey.app/u/Eternity)\
**Post date:** [July 8, 2022, 1:16pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/14 "2022-07-08T13:16:01Z")

</div>

Aha…thanks 🙂

You mean like this:

 ![Schermafbeelding 2022-07-08 om 15.14.53](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/d/e/def52aed88ec2c62432bff7a3148ab7e0a10239a.jpeg)

(the other AND conditions had no input / were not connected in the first flow… stupid me…)

What is the ‘best’ way: parallel or serial?

---

<div class="post-metadata">

**Author:** ![Jo\_San](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jo_san/32/3732_2.png) [@Jo\_San](https://community.homey.app/u/Jo_San)\
**Post date:** [July 8, 2022, 1:20pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/15 "2022-07-08T13:20:09Z")

</div>

Yep, that is the way. Or at least, if you want them to run parallel. Otherwise your other approach would also be good.

I have most of my “and’s” in parallel. Mostly a matter of taste in my opinion, but sometimes it makes more sense to check something first before you check something else, that is where in serial works well.

---

<div class="post-metadata">

**Author:** ![Peter\_Kawa](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/peter_kawa/32/173848_2.png) [@Peter\_Kawa](https://community.homey.app/u/Peter_Kawa)\
**Post date:** [July 8, 2022, 1:59pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/16 "2022-07-08T13:59:23Z")

</div>

> [@Eternity](#):
>
> What is the ‘best’ way: parallel or serial?

I think it acts like this

- serial: like Standard flow AND cards (they all have to be True to continue)
- parallel: like SF OR cards (one has to be True to continue)

---

<div class="post-metadata">

**Author:** ![Jo\_San](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jo_san/32/3732_2.png) [@Jo\_San](https://community.homey.app/u/Jo_San)\
**Post date:** [July 8, 2022, 2:53pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/17 "2022-07-08T14:53:36Z")

</div>

Correct about parallel, with the addition that you make it an “all have to be true” again by applying an “ALL” to all of them.  
And then, I don’t see much difference other that the one or the other way might be slightly faster or slighly better on resources.

---

<div class="post-metadata">

**Author:** ![Hamster](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/hamster/32/16580_2.png) [@Hamster](https://community.homey.app/u/Hamster)\
**Post date:** [January 13, 2023, 10:25am UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/18 "2023-01-13T10:25:21Z")

</div>

> [@Michel\_Bos](#):
>
> “Sonos, follow me” (about Sonos joining when I arrive upstairs with music downstairs and leaving it when I leave again)

Do you use some sort of “room presence” for this flow, so Homey can detect when you leave and enter specific rooms in your house? (For example with BLE beacons)

Or do you use NFC tags? Or a button?

---

<div class="post-metadata">

**Author:** ![Michel\_Bos](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/michel_bos/32/5481_2.png) [@Michel\_Bos](https://community.homey.app/u/Michel_Bos)\
**Post date:** [January 13, 2023, 8:03pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/19 "2023-01-13T20:03:34Z")

</div>

Hi @Hamster yes indeed. Most of my rooms are ‘follow me’ rooms. Whenever I enter a room (on movement or on activating zone, I use the latter) and music is playing downstairs in the living room, I join the Sonos in that room. And whenever that zone is unactive for 1 minute, I have the Sonos of the room leave the group.

When I’m working I block it, by ‘checking in’. I press a remote and a variable is set. When that variable is set, I do not join . I canb ‘check-out’ again, or leave the room for at least 15 minutes. Same effect.

Does this help? If not, let me know.

Good luck!

Michel

---

<div class="post-metadata">

**Author:** ![Hamster](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/hamster/32/16580_2.png) [@Hamster](https://community.homey.app/u/Hamster)\
**Post date:** [January 13, 2023, 8:05pm UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/20 "2023-01-13T20:05:36Z")

</div>

So that only works if only one person is in the house? (Checking for activity in a zone)

---

<div class="post-metadata">

**Author:** ![Michel\_Bos](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/michel_bos/32/5481_2.png) [@Michel\_Bos](https://community.homey.app/u/Michel_Bos)\
**Post date:** [January 17, 2023, 10:40am UTC](https://community.homey.app/t/advanced-flows-structuring-of-flows/65348/21 "2023-01-17T10:40:50Z")

</div>

(@Hamster Although it is not a part of this topic: it indeed works work when a zone is (de)activated regardless of the number of people present. Maybe you want something else? Then I suggest to create a new topic. This one is about how to structure Advanced flows…so it’s not about content per se ;-))
