Variables not updating correct in flows

First i am using the new Bridge.

When running this flow a get a strange resultate.


If this 2 variables Initial value is “Oldtemp=10” and “Tempdiff=0” it should change like this:

Oldtemp=9, Tempdiff=9
Oldtemp=8, Tempdiff=8
Oldtemp=7, Tempdiff=7
But i get this
Oldtemp=10, Tempdiff=0
Oldtemp=0, Tempdiff=9
Oldtemp=9, Tempdiff=-1
Oldtemp=-1, Tempdiff=8
Oldtemp=8, Tempdiff=-2

It´s like “Oldtemp” is updated with “Tempdiff” of the run before not the current.

Is there something wrong with flow or is this a bug ?

You need a delay for your second (1 second) and third (2 seconds) card. The order of the card is not how Homey is processing the cards.

Second card > delay 2 seconds, Third card > delay 1 second

Re-Ordered cards: First card (no delay) > Calculate, Second card (delay 1s) > Message, Third card (delay 2s) > Set value for next run of the Flow

1 Like