05-11-2018 03:50 AM
Hi,
I want to detect the change in value in my indicator, I managed to do it with this solution that you see in the photo below.
But my HMI bug when i do that. wath's the problem? and do you have an other solutions for detect change of value of indicator.
Thank you for your help.
Solved! Go to Solution.
05-11-2018 04:33 AM
Hello,
Event structure will not respond to change of value because it is software generated event,It will respond to any user events such as click of mouse etc.
One way to detect the change in indicator value is to use shift registrar(to store previous value) and a compare with new value. (not sure this will suits for your application or not)
05-11-2018 04:43 AM
If you don't put a Wait (ms) in the right side loop, events will be generated at an incredibly high rate (maybe millions of times per second). Try with a 1000 ms wait or more.
05-11-2018 06:16 AM
it works, but I hope there will be no problems if I add others events,
Thank youuuu very much.
05-11-2018 01:46 PM
@Sarah_LAB wrote:I want to detect the change in value in my indicator, I managed to do it with this solution that you see in the photo below.
Can you take a step back and explain what you really want to do. What should happen based on values, value changes, and operator interactions. Your current code makes no sense, so please explain in detail what you want to do.
Let's look at your snippet.
In summary, your current code could be written as follows.
Obviously, you probably want to do something much more interesting and elaborate, so please enlighten us what you really need. I am sure there is a simple solution for that too! 😄