10855 questions

12932 answers

20157 comments

25364 members

0 votes
283 views 1 comments
by

Hello;

First, let me say again how happy we are with RUT240 and RUT955.

Now we want to supplement our onboard GPS with the RUT955's GPS. We've set the smallest sync interval, 5 min, and will now attempt to add RUT955 to chronyd's list of sources. We open this ticket to document how we make it work, and also to ask a few questions.

1) What is the accuracy we can expect? Does RUT955 use the 1 PPS signal?

2) I assume we will be using an API CLI call to get lat/lon?

3) Not really a Teltonika question per se, but we're both using chrony, I wonder if these can talk somehow?

Wish us luck, project is on. Success! See below:

by

Easily accomplished!

Add RUT955 GPS to list of time servers chronyd will use.

  1. Login to RUT955, enable GPS
  2. Set GPS clock sync interval to 5 minutes (minimum available)
  3. Enable NTP server
  4. Test ntpdate 192.168.1.1
  5. Add Teltonika to /etc/chrony.conf
  6. Restart chronyd
  7. Verify chronic added to sources
  8. Test
  9. Now for details. 

A) Here is GPS page configured:

B) Here's NTP config:

  1. Confirm time zone

  2. Enable ntp

  3. Enable NTP server

  4. Select GPS synchronization

  5. Set GPS time update interval to “Every 5 minutes”

Click Save

C) Now login on sensor and test whether time server on Teltonika is working:

Sensor (eMMC:1p2):~ $ ntpdate 192.168.1.1 

7 Oct 23:37:30 ntpdate[26265]: adjust time server 192.168.1.1 offset -0.153500 sec
It is. 

D) Now edit /etc/chrony.conf and add the Teltonika:
Sensor (eMMC:1p2):~ $ head -2 /etc/chrony.conf 

server 192.168.1.1 

server 10.111.0.61

Note that I put it first, before any of the internet ones. That is because it is on the local LAN and can be reached regardless of internet connection state. Also, it reports itself as a stratum 0 server.

E) Next restart chronyd so it will read /etc/chrony.conf and apply the changes:

Sensor (eMMC:1p2):~ $ /etc/init.d/chronyd restart


F) And confirm that chronyc reports it:

Sensor (eMMC:1p2):~ $ chronyc sources 

210 Number of sources = 4 MS Name/IP address Stratum Poll Reach LastRx Last sample =============================================================================== 

#- GPSD 0 4 377 15 +36ms[ +36ms] +/- 100ms 

#* KPPS 0 4 341 17 -6992ns[-9743ns] +/- 944ns 

^x Teltonika-RUT955.com.lan 1 7 377 125 +191ms[ +191ms] +/- 2931us 

^? 10.111.0.61 0 8 0 10y +0ns[ +0ns] +/- 0ns

1 Answer

0 votes
by

Thank you Clarkman for your help.

I'll paste your answer here to close the ticket.

Easily accomplished!

Add RUT955 GPS to list of time servers chronyd will use.

  1. Login to RUT955, enable GPS
  2. Set GPS clock sync interval to 5 minutes (minimum available)
  3. Enable NTP server
  4. Test ntpdate 192.168.1.1
  5. Add Teltonika to /etc/chrony.conf
  6. Restart chronyd
  7. Verify chronic added to sources
  8. Test
  9. Now for details. 

A) Here is GPS page configured:

B) Here's NTP config:

  1. Confirm time zone

  2. Enable ntp

  3. Enable NTP server

  4. Select GPS synchronization

  5. Set GPS time update interval to “Every 5 minutes”

Click Save

C) Now login on sensor and test whether time server on Teltonika is working:

Sensor (eMMC:1p2):~ $ ntpdate 192.168.1.1 

7 Oct 23:37:30 ntpdate[26265]: adjust time server 192.168.1.1 offset -0.153500 sec
It is. 

D) Now edit /etc/chrony.conf and add the Teltonika:
Sensor (eMMC:1p2):~ $ head -2 /etc/chrony.conf 

server 192.168.1.1 

server 10.111.0.61

Note that I put it first, before any of the internet ones. That is because it is on the local LAN and can be reached regardless of internet connection state. Also, it reports itself as a stratum 0 server.

E) Next restart chronyd so it will read /etc/chrony.conf and apply the changes:

Sensor (eMMC:1p2):~ $ /etc/init.d/chronyd restart


F) And confirm that chronyc reports it:

Sensor (eMMC:1p2):~ $ chronyc sources 

210 Number of sources = 4 MS Name/IP address Stratum Poll Reach LastRx Last sample =============================================================================== 

#- GPSD 0 4 377 15 +36ms[ +36ms] +/- 100ms 

#* KPPS 0 4 341 17 -6992ns[-9743ns] +/- 944ns 

^x Teltonika-RUT955.com.lan 1 7 377 125 +191ms[ +191ms] +/- 2931us 

^? 10.111.0.61 0 8 0 10y +0ns[ +0ns] +/- 0ns