Decoding From 8 To 256 Bits - Mitsubishi Electric MELSEC-Q/L Programming Manual

Hide thumbs Also See for MELSEC-Q/L:
Table of Contents

Advertisement

Decoding from 8 to 256 bits

DECO(P)
High
Basic
Process
Redundant Universal
performance
DECO
DECOP
(S): Data to be decoded or the number of the device where the data to be decoded is stored (BIN 16 bits)
(D): Head number of the devices where the decoding result will be stored (Device name)
n:
Valid bit length (1 to 8), 0: No processing (BIN 16 bits)
Setting
Internal device
data
Bit
Word
(S)
(D)
n
Processing details
• Turns ON the bit position of (D), which corresponds to the binary value designated by the lower n bits at (S).
n = 3
S
1 1 0
(Binary value = 6)
7
6 5 4 3 2 1 0
D
0 1
ON
• The value of n can be designated between 1 and 8.
• No processing is conducted if n = 0, and there are no changes in the details of the device designated at (D).
• Bit devices are treated as 1 bit, and word devices as 16 bits.
Operation error
• In any of the following cases, an operation error occurs, the error flag (SM0) turns ON, and an error code is stored into SD0.
Error
Error details
code
4100
The value of n is other than 0 to 8.
n
4101
The range 2
bits from (D) exceeds the range of the corresponding device.
The range n bits from (S) exceeds each setting area of the corresponding
device.
LCPU
Command
Command
R, ZR
J\
Bit
0 0 0 0 0 0
DECO
S
D
DECOP
S
D
U\G
Zn
Word
Q00J/
QnH
QnPH
Q00/
Q01
7 APPLICATION INSTRUCTIONS
7.5 Data Processing Instructions
n
n
Constant
Others
K, H
QnPRH
QnU
LCPU
423
7

Advertisement

Table of Contents
loading

Table of Contents