![YOKOGAWA VZ20X User Manual Download Page 88](http://html1.mh-extra.com/html/yokogawa/vz20x/vz20x_user-manual_3498955088.webp)
7-21
IM 77V01B01-01EN
5th Edition: 2023.03.07-00
Example of writing the time
Set date and time
: 2021/7/20
12:12:12.123
UNIX time default
: 1970/1/1
0:0:0.000
(1) Find the difference between the current time and the UNIX time default (Find the
difference by using the functions for handling time that are available in each
programming environment.)
Day difference
18828
Hour difference
12
Minute difference
12
Second difference
12
Millisecond difference
123
(2) Convert the differences to milliseconds
Before conversion
Conversion formula
Result of conversion calculation
Day difference
18828 18828
×
24×60×60×1000
1626739200000
Hour difference
12
12×60×60×1000
43200000
Minute difference
12
12×60×1000
720000
Second difference
12
12×1000
12000
Millisecond difference
123
123
123
Total millisecond value
1626783132123
(3) Convert the total millisecond value to 64-bit unsigned hexadecimal
1626783132123
→
0000017AC3D4A9DB
(4) Write by Modbus
Send command [PDU]
011000000004080000017AC3D4A9DB
Function code
10
Register start No.
0000
Number of registers
0004
Byte count
08
Write data
0000017AC3D4A9DB
Summary of Contents for VZ20X
Page 16: ...Contents 3 IM 77V01B01 01EN 5th Edition 2023 03 07 00 Revision Information 1...
Page 17: ...Contents 4 IM 77V01B01 01EN 5th Edition 2023 03 07 00 Blank Page...
Page 23: ...2 2 IM 77V01B01 01EN 5th Edition 2023 03 07 00 Blank Page...
Page 29: ...3 6 IM 77V01B01 01EN 5th Edition 2023 03 07 00 Blank Page...
Page 145: ...9 10 IM 77V01B01 01EN 5th Edition 2023 03 07 00 Blank Page...
Page 149: ...App 4 IM 77V01B01 01EN 5th Edition 2023 03 07 00 Blank Page...