My first post and already I'm in need of a dose of the Forum's help.
My problem: I see in the latest manual that with my picaxe-20X2 I should be able to use the following if statement:
IF variable BIT value SET THEN
{code}
ELSEIF variable BIT value CLEAR THEN
{code}
ENDIF
I've defined a symbol SCPRegVal = b0 and written the above like:
IF SCPRegVal BIT 5 SET THEN
goto data_ready
ELSEIF SCPRegVal BIT 5 CLEAR THEN
goto data_not_ready
ENDIF
The two labels "data_ready:" and "data_not_ready:" have been defined elsewhere in the program. A syntax check gives me an error on the first line (IF variable BIT value SET THEN).
I'm nuts, right?
My problem: I see in the latest manual that with my picaxe-20X2 I should be able to use the following if statement:
IF variable BIT value SET THEN
{code}
ELSEIF variable BIT value CLEAR THEN
{code}
ENDIF
I've defined a symbol SCPRegVal = b0 and written the above like:
IF SCPRegVal BIT 5 SET THEN
goto data_ready
ELSEIF SCPRegVal BIT 5 CLEAR THEN
goto data_not_ready
ENDIF
The two labels "data_ready:" and "data_not_ready:" have been defined elsewhere in the program. A syntax check gives me an error on the first line (IF variable BIT value SET THEN).
I'm nuts, right?