Struggling with my first simple flow

I figured I would start with a simple flow to get myself familiar with Advanced Flow but am already running into challenges.
What I am trying to do:

  • count the number of times a sensor is making contact. For this purpose I created a variable (number) named ’ zoutblokteller’ with a starting value of 0.
  • every time the sensor makes contact the variable ‘zoutblokteller’ increases by 1
    This bit is represented in the two step flow at the top of the screenshot and is working fine.

The other flow start with an IF statement to determine if the variable has changed. When it changed the flow continuous to an AND statement to determine if the variable is equal to 3. If it meets that criteria it will send a notification to the timeline.

What is working: the counting is working fine. Every time the sensor makes contact the variable is increased by 1
However, every time the sensor is making contact the flow will send the message to the timeline whereas the value of the variable is definitely not 3 yet.
When you use the testing procedure in advanced flow it will check for the value of the variable right? Hope somebody can shine some light on this.

Is there also anyway to see whether step in the flow is e.g. an AND or THEN ?

While trying to resolve this I added the variable to the output show on the timeline. Oddly enough it will show all values except when the variable is 3.
My thinking:

  1. if variable has changed the bottom flow will start (which it does when I close the sensor
  2. the second criteria in the bottom flow is an AND statement to check if the value is equal to 3
  3. my assumption is that nothing will be triggered when the value is not 3 and only when it is a 3 it will actually execute the THEN statement of sending a message to the timeline.

Now it always sends a message to the timeline except when the variabel is equal to 3 (???)

OK, resolved it. Turns out there is a difference between the blue and yellow lines you can create.
Blue line is followed when the criteria is met (THEN)
Yellow line is followed when the criteria not met (ELSE)
Red line is ???

Is there any documentation available where these kind of things are explained?

Anyways: case closed for now. I can now start to finish my first advanced flow :smiley:

Red line is error. No documentation besides the tutorials on the homey website

1 Like

Additional: many Q&A here:

1 Like