KWh value of plug not always copied

Hi all,

I have a small problem which i don’t understand.
In a flow i want to store the KWh value of one of my powerplugs into a variable.
When that’s is done i also set a boolean (“kwh opgehaald”) to TRUE .

When i trigger this flow from a virtual knob (so i trigger it myself) everything is working fine.
The value is stored in variable “Kwh Wasmachine” and the boolean “kwh opgehaald” is set correctly to TRUE.

But when i call this flow at the end of a another flow the variable for the kwh value is not set.
It stays zero (0).
I can see that Homey correctly entered and had run the flow because the boolean “kwh opgehaald” is set from FALSE to TRUE.

What am i forgetting ? DO i have to do something extra when i call this flow from another flow ?
I’ve tried to set some delay’s but that does not do the trick.

Can somebody help me here ?

Thanks,
Peter

It can depend on what the “calling” routine does, maybe you have to delay the starting of this flow.

@JPe4619 , thanks.

De previous routine calls this flow at it’s own end, so there are no following ‘cards’.
But i’ll try to build in the delay right before the calling routine calls the flow.
But even then it is still strange that the boolean is set but the variable not.

We’ll see.

Thanks,
Peter

U also did set the variable to false somewhere?

Yes,

There is another routine which calculates with de KWh variable.
After that the boolean is set to false and the variable is set to zero (0).

And before testing again i set the boolean (false) en variable (0) by hand.

Peter

Hi @JPe4619 ,

I set a small delay and did also reset Homey.
It’s working fine now ! Thanks.

Peter

1 Like