Readnbit - Omron NY532-5400 Reference Manual

Ny-series
Hide thumbs Also See for NY532-5400:
Table of Contents

Advertisement

2 Instruction Descriptions

ReadNbit_**

The ReadNbit_** instructions read zero or more bits from a bit string.
Instruction
ReadNbit_**
N-bit Read Group
Variables
Name
Meaning
In
Read
source
Pos
Read
position
Size
Read size
Out
Read result Output
Bit strings
In
OK OK OK OK
Pos
Size
Out
Function
A ReadNbit_** instruction reads the values of the upper Size bits from read position Pos in source bit
string In. It assigns the values to read result Out.
The name of the instruction is determined by the data types of In and Out. For example, if In and Out
are the WORD data type, the instruction is ReadNbit_WORD.
2-1366
Name
FB/FUN
FUN
I/O
Description
Bit string to read
Input
Bit position to read
Number of bits to read
Read result
OK
OK
Must be same data type as In
Graphic expression
(@)ReadNbit_**
EN
ENO
In
Out
Pos
Size
"**" must be a bit string data type.
Valid range
Depends on data type.
0 to No. of bits in In −1
0 to No. of bits in In
Depends on data type.
Integers
NY-series Instructions Reference Manual (W560)
ST expression
Out:=ReadNbit_**(In, Pos,
Size);
"**" must be a bit string data
type.
Unit
Default
0
---
1
---
---
Times, durations,
dates, and text strings

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents