DA-681 Linux
Software Configuration
2-5
# date MMDDhhmmYYYY
MM:
Month
DD:
Date
hhmm: Hour and Minute
YYYY:
Year
Use the following command to write the current system time to the RTC.
# hwclock –w
Moxa:~# date
Fri Jun 23 23:30:31 CST 2000
Moxa:~# hwclock
Fri Jun 23 23:30:35 2000 -0.557748 seconds
Moxa:~# date 120910002004
Thu Dec 9 10:00:00 CST 2004
Moxa:~# hwclock –w
Moxa:~# date ; hwclock
Thu Dec 9 10:01:07 CST 2004
Thu Dec 9 10:01:08 2004 -0.933547 seconds
Moxa:~#
NTP Client
The DA-681-LX has a built-in NTP (Network Time Protocol) client that is used to initialize a time request to a
remote NTP server. Use
ntpdate
to update the system time.
#ntpdate time.stdtime.gov.tw
#hwclock –w
Visit http://www.ntp.org for more information about NTP and NTP server addresses.
Moxa:~# date ; hwclock
Sat Jan 1 00:00:36 CST 2000
Sat Jan 1 00:00:37 2000 -0.772941 seconds
Moxa:~#
Moxa:~# ntpdate time.stdtime.gov.tw
9 Dec 10:58:53 ntpdate[207]: step time server 220.130.158.52 offset 155905087.9
84256 sec
Moxa:~#
Moxa:~# hwclock -w
Moxa:~# date ; hwclock
Thu Dec 9 10:59:11 CST 2004
Thu Dec 9 10:59:12 2004 -0.844076 seconds
Moxa:~#
ATTENTION
Before using the NTP client utility, check your IP address and network settings to make sure an Internet
connection is available.