86
•
Board Support Package (BSP)
Ethernet Interface Services
WAGO-I/O-SYSTEM
750
Linux Fieldbus Coupler
In order to provide for cyclic time monitoring via SNTP, MSNTP can also be
started as a daemon. Additionally, MSNTP should be registered as respawn
process in the
/etc/inittab
file in order to automatically activate time
monitoring when starting the Linux fieldbus coupler and to restart the process
automatically if the program crashes. The entry in the file
/etc/inittab
looks as
follows:
/etc/inittab:
::respawn:/bin/msntp –r –P no –x <minutes> <IP/Hostname>
Example: ::
respawn:/bin/msntp –r –P no –x 10 192.168.1.11
This would mean that the time would be checked every 10 minutes. The entry
•
r
means that the process sets the time via
settimeofday()
.
•
P no
means that any time error is corrected
•
x 10
means that the process is a daemon and that it will take at least 10
minutes before it repeats its query.
Further information on the parameters can be found on the msntp main page
(e.g. under: http://pigtail.net/LRP/msntp.html).