Send message only when there is a change

I want a notification when it lose X weight. Now it was sending me one every second. But I want only send it to me once.

So you never want a second notification? What if it goes down 2X or increases then drops again?

Sorry, you are right

I need this notifications, but only if there is a big change.

What do you mean by 'big'?

More than 50%

So if the first reading is 300, you won’t get a notification until the next is greater than 450 and the if the value drops you won’t get a notification until the number drops below 225?
And if it drops again, a notification will happen when the number drops by 112.5 and then when it drops by 56.25, the by 28.125, then by 14.062 ...

Notice the values are getting smaller??

Yes, of course. It is for a farm pig. And I only need the notification for request more material. Then when it is drop to 300 kg or something like that, the system send a notification to the factory. But, at the moment, the system send me a notification every minute and I only want once the weight drop below 200 or a dynamic weight.

Thanks!

Well then use the rbe node. Add a bunch of injects with different values and test it out.

Do I add the injects in the RBE or where?

The inject nodes are to act as way for you to send test data thru your flow. I would suggest placing them where the data would be entering the flow. Then you can simulate actual data while you test your Flow’s logic

Thanks! Now I'm trying with this and it sendme every 30 seconds. Its possible that the issue is in timestamp?
Screenshot_7

I can't see the fail

Try unchecking the “Apply mode for each msg.topic seperately” option

I don’t see any injects.

Yes, because at this moment I was try another thing.

I got it, it works perfect!

Thank you so much!!! :blush:

Hi Arzur,

Can you post the final result ?

Regards,

René.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.