I'm going to have to admit to having troble with: if.
I've ckecked the basic commands .pdf and found the if section but there is so much that if can be used for with so many other "else" or "endif" endings an add-ons that I'm lost.
Here's a quote from page 72 in the manual:
This doesn't work. Syntax error. How do I express that without needing to create at least six different labels.
It is for a grid referance system that will end up with 7 horizontal and 7 vertical. This "dummy code" just has 2 horiz' and 1 vert'.
Horizontal varible is b1 vertical is b2. when these numbers are displayed with a comma between they give a nice grid referance.
I've ckecked the basic commands .pdf and found the if section but there is so much that if can be used for with so many other "else" or "endif" endings an add-ons that I'm lost.
Here's a quote from page 72 in the manual:
This is what I want to say:Syntax:
IF variable ?? value {AND/OR variable ?? value ...} THEN
{code}
ELSEIF variable ?? value {AND/OR variable ?? value ...} THEN
{code}
ELSE
{code}
ENDIF
Code:
label_3_1: if pin1 = 1 then let b1 = 1
goto label_3_2
label_3_2: if pin2 = 1 then let b1 = 2
goto label_3_3
label_3_3: if pin3 = 1 then let b2 = 1 'yep b2 this time = 1
goto label_3_4
It is for a grid referance system that will end up with 7 horizontal and 7 vertical. This "dummy code" just has 2 horiz' and 1 vert'.
Horizontal varible is b1 vertical is b2. when these numbers are displayed with a comma between they give a nice grid referance.