High−level Instructions
3 − 305
Outline Converts hour, minute, and second data to seconds data.
For the FP0R/FPΣ/FP−X, the P type high−level instruction “P138
(PHMSS)” is not available.
Program example
Boolean
Ladder Diagram
Address Instruction
10
F138 HMSS , DT 0 , DT10
S
D
Trigger
R0
10
11
ST R 0
F138 (HMSS)
DT 0
DT 10
S Starting 16-bit area for storing hours, minutes, and seconds data (source)
D Starting 16-bit area for storing converted seconds data (destination)
Operands
modifier
S A A A A A A A A A A N/A N/A N/A A
D N/A A A A A A A A A A N/A N/A N/A A
(*1) This cannot be used with the FP0 and FP−e.
(*2) This cannot be used with the FP0, FP−e, FP0R, FPΣ, FP−X.
(*3) With the FP0R, FPΣ,FP−X, FP2, FP2SH, and FP10SH, this is I0 to IC.
Explanation of example
Converts the hour, minute, and second data stored in data registers DT1 and DT0 to seconds data when
trigger R0 turns on. The converted seconds data is stored in data registers DT11 and DT10.
00074530
DT1 DT0
F138 (HMSS) instruction execution
Hours data
7: 45’ 30” [H00074530 (BCD) (DT1 = H7, DT0 = H4530)]
00027930
DT11 DT10
Seconds data
27930” [H00027930 (BCD) (DT11 = H2, DT10 = H7930)]
Minutes data Seconds data
F138
P138
(PHMSS)
(HMSS)
Hours, minutes, and seconds data to seconds data
A: Available
N/A: Not Available