537
FX
3G
/FX
3U
/FX
3UC
Series Programmable Controllers
Programming Manual - Basic & Applied Instruction Edition
19 Data Operation 2 – FNC140 to FNC149
19.3 FNC142 – BTOW / BYTE to WORD
11
FN
C30
-FN
C3
9
R
ota
tion and
Shi
ft
12
FN
C40-FN
C49
D
ata O
perati
on
13
FNC
50-FNC
59
High-Speed
Proc
essing
14
FM
C60-FN
C69
H
andy
In
struction
15
FN
C70-FN
C79
E
xternal
F
X
I/O
De
vice
16
FNC
80-FNC
89
External
FX
Dev
ice
17
FNC1
00-
FNC10
9
Dat
a
Transfer 2
18
FNC1
10-
FNC139
Fl
oa
ting Poi
nt
19
FNC14
0-F
N
C
149
Da
ta
Operation 2
20
FNC1
50-
FNC159
Pos
itioning
Control
19.3
FNC142 – BTOW / BYTE to WORD
Outline
This instruction combines the low-order 8 bits (low-order byte) of consecutive 16-bit data.
1. Instruction format
2. Set data
3. Applicable devices
Explanation of function and operation
1. 16-bit operation (BTOW and BTOWP)
1) The low-order byte (8 bits) of "n" 16-bit data starting from
is combined, and stored in "n/2" devices starting
from
as shown below.
2) The high-order byte (8 bits) of each combination source 16-bit data (
and later) is ignored.
3) When "n" is an odd number, "00H" is stored in the high-order byte (8 bits) of the final one among the combination
result destination devices as shown below.
For example, when "n" is "5", the low-order byte (8 bits) of
to
+4 is stored in
to
+2, and
"00H" is stored in the high-order byte (8 bits) of
+2.
4) When "n" is "0", the BTOW instruction is not executed.
Operand type
Description
Data type
Head device number storing data to be combined in byte units
16-bit binary
Head device number storing data acquired by combination in byte units
n
Number of byte data to be combined (0
≤
n)
Oper-
and
Type
Bit Devices
Word Devices
Others
System User
Digit Specification
System User
Special
Unit
Index
Con-
stant
Real
Number
Charac-
ter String
Pointer
X Y M T C S D
.b KnX KnY KnM KnS T C D R U
\G
V Z Modify K H
E
"
"
P
3 3 3 3
3
3 3 3 3
3
n
3 3
3 3
P
FNC 142
BTOW
−
−
Mnemonic
Operation Condition
16-bit Instruction
7 steps BTOW
BTOWP
Mnemonic
Operation Condition
Continuous
Operation
Pulse (Single)
Operation
32-bit Instruction
S
D
S
D
S
D
Command
input
FNC142
BTOWP
S
D
n
b15
b8 b7
b0
S
+0
+1
...
The high-order byte is ignored.
+2
+n-1
"n"
bytes
1st byte data
2nd byte data
3rd byte data
"n"th byte data
D
+0
+1
+n/2
*
...
2nd byte
4th byte
"n"th byte
1st byte
3rd byte
"n-1"th byte
...
...
b15
b8 b7
b0
* When "n" is an odd number,
refer to "3)" below
S
S
S
D
D
D
00H
b15
b8 b7
b0
S
+0
+1
The high-order bytes is ignored.
+2
When
"n" is
"5"
D
+0
+1
+2
34H
78H
12H
56H
9AH
ABH
CDH
ABH
12H
34H
78H
EFH
56H
CDH
9AH
+3
+4
When "n" is "5",
"00H" is stored.
b15
b8 b7
b0
Содержание FX3G SERIES
Страница 1: ...FX3G FX3U FX3UC SERIES PROGRAMMABLE CONTROLLERS PROGRAMMING MANUAL Basic Applied Instructions Edition ...
Страница 2: ......
Страница 947: ......