EasyManuals Logo

Omron CX-PROGRAMMER 5.0-FUNCTION BLOCK OPERATION User Manual

Omron CX-PROGRAMMER 5.0-FUNCTION BLOCK OPERATION
183 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #159 background imageLoading...
Page #159 background image
144
Structured Text (ST Language) Specifications Appendix B
Data Type Conversion Functions
The following data type conversion functions can be used in structured text.
Syntax
Source data type_TO_New data type (Variable name)
Example: REAL_TO_INT (C)
In this example, the data type for variable C will be changed from REAL to INT.
Data Type Combinations
The combinations of data types that can be converted are given in the following table.
(YES = Conversion possible, No = Conversion not possible)
Statement Details
Assignment
Summary
The left side of the statement (variable) is substituted with the right side of the statement (equation, variable, or
constant).
Reserved Words
:=
Combination of colon (:) and equals sign (=).
Statement Syntax
Variable: = Equation, variable, or constant;
Usage
Use assignment statements for inputting values in variables. This is a basic statement for use before or within
control statements. This statement can be used for setting initial values, storing calculation results, and incre-
menting or decrementing variables.
Description
Substitutes (stores) an equation, variable, or constant for the variable.
Examples
Example 1: Substitute variable A with the result of the equation X+1.
A:=X+1;
Example 2: Substitute variable A with the value of variable B.
A:=B;
FROM TO
BOOL INT DINT LINT UINT UDINT ULINT WORD DWORD LWORD REAL LREAL
BOOL
No No No No No No No No No No No No
INT
No No YES YES YES YES YES YES YES YES YES YES
DINT
No YES No YES YES YES YES YES YES YES YES YES
LINT
No YES YES No YES YES YES YES YES YES YES YES
UINT
No YES YES YES No YES YES YES YES YES YES YES
UDINT
No YES YES YES YES No YES YES YES YES YES YES
ULINT
No YES YES YES YES YES No YES YES YES YES YES
WORD
No YES YES YES YES YES YES No YES YES No No
DWORD
No YES YES YES YES YES YES YES No YES No No
LWORD
No YES YES YES YES YES YES YES YES No No No
REAL
No YES YES YES YES YES YES No No No No YES
LREAL
No YES YES YES YES YES YES No No No YES No

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Omron CX-PROGRAMMER 5.0-FUNCTION BLOCK OPERATION and is the answer not in the manual?

Omron CX-PROGRAMMER 5.0-FUNCTION BLOCK OPERATION Specifications

General IconGeneral
BrandOmron
ModelCX-PROGRAMMER 5.0-FUNCTION BLOCK OPERATION
CategorySoftware
LanguageEnglish

Related product manuals