11 Applied Instructions (Data Operation)
11.2 DECO / Decode
232
FXCPU Structured Programming Manual
[Basic & Applied Instruction]
2. Turning ON the bit out of word devices according to the contents of bit devices
The value expressed by X000 to X002 is decoded to D0 (X000 and X001 are ON, and X002 is OFF in this
example).
• When the values expressed by X000 to X002 are "3 (=1+2+0)", b3 (which is the 4th from b0) becomes "1"
(turns ON).
• When all of X000 to X002 are "0" (OFF), b0 becomes "1" (turns ON).
M8000
K3
X000
DECO
EN
s
n
ENO
d
D0
[Structured ladder/FBD]
[ ST ]
DECO(M8000, X000, K3, D0);
All of these bits are "0" (OFF).
0001000000000000
Turns ON when all bits of are OFF.
K1K2K3
0 1 1
1
2
4
X0X1X2
2
n
s
b0b1b2b3b4b5b6b7b8b9b10b11b12b13b14b15
=D0
n
s
d