23-10 XL-BASIC Programming Guide
XL™ SERIES
Example:
goto 1000
end
1000
print "code execution continues here"
FOR / TO / NEXT
This is a “For To” loop with the following form:
FOR var = start value TO end value
Command(s)
NEXT
Example:
for x = 1 to 10
Print x
Next
The start value and end value must be whole numbers with the start value less than
the end value. There can be 5 nested FOR / TO / NEXT sections.
IF / THEN
IF condition THEN action. Condition is a logical expression that
evaluates to true or false. If the condition is true then the
desired action is executed. Valid conditional operators are:
Operator Example
<
a < b
a less than b
>
a > b
a greater than b
<=
a <= b
a less than or equal to b
>=
a >= b
a greater than or equal to b
= =
a = = b
a equal to b
!=
a != b
a not equal to b
Example:
if stage>10 then print "stage is greater than 10"
Most commands can be used after the THEN statement. A few possibilities are
listed below:
Then goto ####
Then gosub ####
Then measure(x)
Then delay(#)
END
All programs should end with this statement.
Summary of Contents for H-350XL
Page 1: ...XL Series Models H 350XL H 500XL H 510XL H 522 H 522 Plus Owner s Manual ...
Page 30: ...2 16 Hardware Options and Installation XL Series ...
Page 42: ...3 12 Using The Built In Keypad Display XL Series ...
Page 46: ...4 4 PC Menu Interface Operation XL Series ...
Page 58: ...5 12 Miscellaneous System Setup XL Series ...
Page 66: ...6 8 Serial Port Options XL Series ...
Page 74: ...7 8 System Configuration Files XL Series ...
Page 84: ...8 10 System Status Menus Options XL Series ...
Page 88: ...9 4 Scanning Options XL Series ...
Page 156: ...15 12 Logging Options XL Series ...
Page 198: ...16 42 Operation with the GOES Radio XL Series ...
Page 216: ...19 6 Alarm Call Out XL Series ...
Page 234: ...21 8 Operation with the H 355 Smart Gas System XL Series ...
Page 246: ...22 12 Functions XL Series ...