Panasonic FP Series Programming Manual page 353

Hide thumbs Also See for FP Series:
Table of Contents

Advertisement

Arithmetic instructions
F41_DBADD
The 8-digit BCD equivalent constant or 8-digit BCD data specified by s and the 8-digit BCD data
Description
specified by d are added together if the trigger EN is in the ON-state. The result is stored in d.
Example value 16#12342000 (BCD)
Bit
31 . . 28 27 . . 24 23 . . 20 19 . . 16
d
16# BCD
Example value 16#00003678 (BCD)
Bit
31 . . 28 27 . . 24 23 . . 20 19 . . 16
s
16# BCD
Result value 16#12345678 (BCD) if trigger is ON
Bit
31 . . 28 27 . . 24 23 . . 20 19 . . 16
d
16# BCD
This instruction also exists as a P instruction (for FP2/2SH, FP3/5, FP10/10SH PLC types), which
is only executed at the rising edge of the EN trigger. Select [Insert P instruction] from the
"Instructions" pane if you require a P instruction. To facilitate reuse, the instruction then appears
under "Recently used" in the pop-up menu. Press <Ctrl>+<Shift>+<v> within the programming
area to open the list of recently used elements.
When this instruction is used, the area for the augend d is overwritten by the
added result. If you want to avoid the overwrite, we recommend using the
instruction F43_DBADD2 (see page 355).
Availability of F41_DBADD (see page 1325)
PLC types
Data types
Variable
Data type
DWORD
s
DWORD
d
352
8-digit BCD addition
0 0 0 1
0 0 1 0
0 0 1 1
0 1 0 0
1
2
3
0 0 0 0
0 0 0 0
0 0 0 0
0 0 0 0
0
0
0
0 0 0 1
0 0 1 0
0 0 1 1
0 1 0 0
1
2
3
Function
addend, 32-bit area for 8-digit BCD data or equivalent
constant
augend and result, 32-bit area for 8-digit BCD data
15 . . 12 10 . . 8 7 . . 4 3 . . 0
0 0 1 0
0 0 0 0
0 0 0 0
4
2
0
32-bit area
15 . . 12 10 . . 8 7 . . 4 3 . . 0
0 0 1 1
0 1 1 0
0 1 1 1
0
3
6
15 . . 12 10 . . 8 7 . . 4 3 . . 0
0 1 0 1
0 1 1 0
0 1 1 1
4
5
6
0 0 0 0
0
0
1 0 0 0
7
8
1 0 0 0
7
8

Advertisement

Table of Contents
loading

Table of Contents