LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Old and new value of value change event are same


@GerdW wrote:

 

Simple: delete that "value (sgl)" property node in the timeout event!

Now your VI will only react on user interaction…


Head bump. Completely missed that. Should ban myself from the forum on Fridays.

0 Kudos
Message 11 of 15
(873 Views)

@wiebe@CARYA

I can not post complete VI but I am posting similar to that. 

 

 

Jasraj Rajpurohit
0 Kudos
Message 12 of 15
(868 Views)

Hi Jasraj,

 

do you really need to check a ROI each 5ms?

Do you really need to fire a value change event in the timeout each 5ms?

Why don't you place the content of the "Code rectangle" event case into the Timeout event? No need to fire an event at all…

 

(RubeGoldberg: Just change the comparison mode of the Equal? function to avoid that Unbundle and OR functions…)

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 13 of 15
(862 Views)

Dear GerdW,

see the code again.

Why don't you place the content of the "Code rectangle" event case into the Timeout event? No need to fire an event at all

 

this VI is the part of my application.

I want to execute that particular function when old value and new value are not same.

The default value of ROI is given so when I change the ROI the code rectangle will change.

Theoretically the old value and new value should not the same but I am getting the same values.

 

Jasraj Rajpurohit
0 Kudos
Message 14 of 15
(858 Views)

@jasrajrajpurohit wrote:

 

I want to execute that particular function when old value and new value are not same.

 

 


You are still not understanding the event structure. You are polling a value in the timeout case, so all you need is use e.g. a feedback node to see if it changes and execute a case structure accordingly (image). Events are not for that!

 

(As has been mentioned, the "not equal" is set to "compare aggregates" to output a single boolean).

 

NOEvent.png

0 Kudos
Message 15 of 15
(848 Views)