P
ar
t
2: C
omman
d
s
Moog Animatics SmartMotor™ Developer's Guide, Rev. L
Page 272 of 909
al[index]=formula
Array Long [index]
APPLICATION:
Variables
DESCRIPTION:
User signed 32-bit variables
EXECUTION:
Immediate
CONDITIONAL TO:
Index values range 0 to 50
LIMITATIONS:
An expression used as an index within the [] brackets is limited
to no more than one operator (two values).
No Combitronic requests or functions with parenthesis are
supported within the [] brackets.
This data space is shared with Cam motion (MC) if a RAM table
location is selected. However, the aw command must not be
used to access this space during that time.
READ/REPORT:
Ral[index]
WRITE:
Read/write
LANGUAGE ACCESS:
Assignment, formulas and conditional testing
UNITS:
Signed 32-bit number
RANGE OF VALUES:
-2147483648 to 2147483647
TYPICAL VALUES:
-2147483648 to 2147483647
DEFAULT VALUE:
0
FIRMWARE VERSION:
5.x and later
COMBITRONIC:
al[0]:3=1234
where ":3" is the motor address — use the actual address or a
variable
DETAILED DESCRIPTION:
The SmartMotor™ has 8, 16 and 32-bit arrays. The 32-bit array takes the form of the
variables al[index]. These are general-purpose, 32-bit signed integer variables that can be
reported, used on either side of an equation, and can be mixed in an expression with variables
other than 32-bit. Like all user variables, they are always lowercase, and they are
automatically initialized to zero at power up or reset.
The syntax of the 32-bit array is al[index] which stands for array long and accepts an index
value between 0 and 50. This index can be specified explicitly or through another variable. For
example, al[4] refers to the fifth element in the 32-bit array, while aw[n] refers to an element
of the array, where the variable "n" must be between 0 and 50.
The value of any array variable is reported with the R, PRINT( ) or PRINT1( ) functions.
Part 2: Commands: al[index]=formula