Simple Ruby problem
Posted: Wed May 29, 2013 7:44 am
I'm having a go at turning my green counting systems over to ruby,
but stuck with a some real simple logic.
This code gets me a trigger on each count.....???
I know I'm probably still thinking "Visual basic".... but i just don't get it
.
If the value is =1 then give me a trigger.....seems a very straightforward instruction....
What am i missing here.....
but stuck with a some real simple logic.
Code: Select all
def event i,v,t
if v = 1 then output 0,t
end
end
This code gets me a trigger on each count.....???
I know I'm probably still thinking "Visual basic".... but i just don't get it
If the value is =1 then give me a trigger.....seems a very straightforward instruction....
What am i missing here.....