Symbol Data Types - Omron CJ2 CPU - REV 10-2010 User Manual

Cj2 cpu unit software
Table of Contents

Advertisement

5 Understanding Programming
5-5-7

Symbol Data Types

It is possible to specify the data type for addresses allocated for symbols.
Data Types That Can Be Set for Symbols
The data types that can be specified inside function blocks may be different from the types that be spec-
ified outside function blocks. The data types that can be used for each are specified in the following
table.
BOOL (bit)
UINT (one-word unsigned binary)
UDINT (two-word unsigned binary)
ULINT (four-word unsigned binary)
INT (one-word signed binary)
DINT (two-word signed binary)
LINT (four-word signed binary)
UINT BCD (one-word unsigned binary)
UDINT BCD (two-word signed binary)
ULINT BCD (four-word signed binary)
REAL (two-word floating point)
LREAL (four-word floating point)
*1
CHANNEL (word)
NUMBER (constant or number)
WORD (one-word hexadecimal)
WORD (two-word hexadecimal)
LWORD (four-word hexadecimal)
STRING (character string: 1 to 255 ASCII characters)
TIMER
COUNTER
User-defined data types (data structures)
*1 Data types will be converted as follows in ST programming.
• UINT BCD: WORD
• UDINT BCD: DWORD
• ULINT BCD: LWORD
• CHANNEL: WORD
*2 These data types cannot be used in ST programming. A program error will occur.
*3 Only internal symbols in function blocks written with ladder diagrams.
5-56
Data type
*1
*1
*1
*2
Symbols in programming Variable in function blocks
OK
OK
OK
OK
OK
OK
OK
OK
OK
OK
OK
OK
OK
OK
OK
No
OK
No
OK
No
OK
OK
OK
OK
OK
No
OK
No
OK
OK
OK
OK
OK
OK
OK
OK
No
OK
No
OK
OK
OK
CJ2 CPU Unit Software User's Manual
*3

Advertisement

Table of Contents
loading

Table of Contents