How to compare values?

Apr 14, 2013
663
343
I want to compare a value from a math_counter to 0. When it gets bigger than 0, it should trigger a logic_relay, and when it becomes equal to 0, it should trigger a different logic relay.
Basically:
if counter>0
trigger logic1​
end if

if counter=0
trigger logic 2​
end if

Problem is, I have no idea how to do that. Any ideas?
 
Apr 14, 2013
663
343
Well, this certainly helps, but the problem is the vdc documentation about what's a logic_compare is very confusing, to say the least.
SetValue <float>
Set the value that will be compared against the compare value.
SetValueCompare <float>
Set the value that will be compared against the compare value and performs the comparison.
SetCompareValue <float>
Set the compare value.
Compare
Force a compare of the input value with the compare value.

Right now the math_counter has the following output logic:
Code:
 OutValue,  logic_compare,  Compare
.
Then, the logic_compare has the output logic:
Code:
 OnEqualTo,  relay_0,  Trigger
and
Code:
 OnGreaterThan,  relay_1,  Trigger
. But how do you cause it to compare?