6 Motion Control Programming
6-22
NJ/NX-series CPU Unit Motion Control Userās Manual (W507)
System-defined variables for motion control use both basic data types and derivative data types.
ļ¬ Basic Data Types
* BOOL data is only 1 bit in size but it takes up 2 bytes of memory.
Data Types Used for System-defined Variables for Motion Control
Category Data type Size Range of values Notation
Boolean BOOL
2
*
TRUE or FALSE TRUE or FALSE
Integer UINT 2 0 to +65,535 Binary expression: "2#" is added to the
front of the number
Octal expression: "8#" is added to the
front of the number
Decimal expression: "10#" is added to
the front of the number
Hexadecimal expression: "16#" is added
to the front of the number
If you do not add any notation to the
beginning of a number, that number is
treated as a decimal number.
Example:
Binary Notation
2#1111_1111
2#1110_0000
Octal Notation
8#377
8#340
Decimal Notation
ā12 0 123_456 +986
10#1234
Hexadecimal Notation
16#FF 16#ff
16#E0 16#e0
UDINT 4 0 to +4,294,967,295
Floating-
point
numbers
LREAL 8 ā1.79769313486231e+308 to
ā2.22507385850721eā308,
0,
2.22507385850721eā308 to
1.79769313486231e+308,
positive infinity, or negative
infinity
Written as (sign) + integer_part + (deci-
mal_point) + (decimal_part) + (exponent).
You can omit items in parentheses.
Example:
2
ā12.0
0.0
0.4560
3.14159_26
ā1.34E-12
ā1.34e-12
1.0E+6
1.0e+6
1.234E6
1.234e6