EasyManuals Logo

Omron NJ501-1500 User Manual

Omron NJ501-1500
990 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 #327 background imageLoading...
Page #327 background image
2-279
2 Instruction Descriptions
NJ-series Instructions Reference Manual (W502)
Data Type Conversion Instructions
2
TO_** (Bit String Conversion Group)
TO_** (Bit String Conversion
Group)
These instructions convert integers, bit strings, real numbers, and text strings to bit strings.
*1 The valid ranges depend on the data types of In and Out.
*2 If you omit the input parameter, the default value is not applied. A building error will occur.
These instructions convert the integer, bit string, real number, or text string in In to a bit string.
The name of the instruction is determined by the data type of conversion result Out. For example, if Out
is the WORD data type, the instruction is TO_WORD.
The following example for the TO_WORD instruction is for when In is INT#−1234.
Instruction Name FB/FUN Graphic expression ST expression
TO_** Bit String Conver-
sion Group
FUN Out:=TO_**(In);
"**" must be a bit string data
type.
Variables
Name Meaning I/O Description Valid range Unit Default
In Data to
convert
Input Data to convert
*1
---
*2
Out Conver-
sion result
Output Conversion result
*1
--- ---
Boolean
Bit strings Integers
Real
numbers
Times, durations,
dates, and text strings
BOOL
BYTE
WORD
DWORD
LWORD
USINT
UINT
UDINT
ULINT
SINT
INT
DINT
LINT
REAL
LREAL
TIME
DATE
TOD
DT
STRING
In OK OK OK OK OK OK OK OK OK OK OK OK OK OK OK
Out OKOKOKOK
Function
"**" must be a bit string data type.
(@)TO_**
EN ENO
In Out
abc:=TO_WORD(INT#-1234);
LD ST
abc
INT#-1234
TO_WORD
EN ENO
In
INT data
WORD data
In
Out=abc
INT#-1234
16#FB2E

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Omron NJ501-1500 and is the answer not in the manual?

Omron NJ501-1500 Specifications

General IconGeneral
BrandOmron
ModelNJ501-1500
CategoryController
LanguageEnglish

Related product manuals