Topics

RTC time: n/a


Mike B
 

First I would like to say, thanks to the documentation and how to videos spread throughout the inter-tubes I have my DRAWS setup mostly working.

A continual problem I have is the GPS...and it might even be associated a bit with RFI...tbd.

However in troubleshooting, I run verify_time.sh (in the n7nix/gps folder)

RTC time always shows n/a.   Is that because the pi doesn't see the RTC?   Is there any way to see if the RTC is working and has the correct time? 


 

The RTC on DRAWS™ is really a backup clock for the GPS. 

It is set by the GPS when the GPS is locked on a sufficient number of satellites. 

It keeps running as long as the HAT has power. If the DRAWS™ looses power, the backup battery can keep the RTC running for a cumulative 40 days (Subtract the time the power is removed), then the battery must be replaced and the GPS  must reset the clock. 

Are you getting GPS lock?  Are you leaving the DRAWS™ powered at all times?  Is your backup battery good?

On Sun, Mar 29, 2020, 07:17 Mike B <kf5dey@...> wrote:
First I would like to say, thanks to the documentation and how to videos spread throughout the inter-tubes I have my DRAWS setup mostly working.

A continual problem I have is the GPS...and it might even be associated a bit with RFI...tbd.

However in troubleshooting, I run verify_time.sh (in the n7nix/gps folder)

RTC time always shows n/a.   Is that because the pi doesn't see the RTC?   Is there any way to see if the RTC is working and has the correct time? 


Basil Gunn
 

The GPS device on the DRAWS hat is an S1216 Family GNSS Module.
http://www.skytraq.com.tw/datasheet/S1216V8_v0.9.pdf

This device is not a traditional RTC so there is no RTC wired up to the
Device Tree Source Files loaded by the Linux kernel. What it does provide is a
battery backed-up time source that operates with chronyd like an RTC
device.
To verify that your time source (GPS) is working, run the verify_time.sh
script which checks the chronyd & gpsd daemons to verify the S1216 GNSS
module is working and providing an accurate time source. For example
from 'chronyc tracking' which is run from the verify_time.sh script.

Ref time (UTC) : Sun Mar 29 14:26:55 2020
System time : 0.000000172 seconds fast of NTP time

I can see my time source is stunningly accurate.

To confirm that your time source is working properly I would need to see
the output of the verify_time.sh script.

/Basil n7nix

Mike B <kf5dey@...> writes:

First I would like to say, thanks to the documentation and how to
videos spread throughout the inter-tubes I have my DRAWS setup mostly
working.

A continual problem I have is the GPS...and it might even be
associated a bit with RFI...tbd.

However in troubleshooting, I run verify_time.sh (in the n7nix/gps folder)

RTC time always shows n/a. Is that because the pi doesn't see the RTC?
Is there any way to see if the RTC is working and has the correct
time?


Mike B
 

Yup on for 24  hours, brand new out of the package battery.

Now I have had GPS lock since last night, so I think I may have solved the reception issue (put gps antenna on an empty altoids tin at same location as before...)  or just got lucky...

Mike
KF5DEY

pi@draws:~/n7nix/gps $ ./verify_time.sh

        timedatectl

               Local time: Sun 2020-03-29 10:50:59 CDT
           Universal time: Sun 2020-03-29 15:50:59 UTC
                 RTC time: n/a
                Time zone: America/Chicago (CDT, -0500)
System clock synchronized: yes
              NTP service: inactive
          RTC in local TZ: no

        chronyc sources

210 Number of sources = 6
MS Name/IP address         Stratum Poll Reach LastRx Last sample
===============================================================================
#? GPS                           0   3     0   979   -337ms[ -337ms] +/-  106ms
#* PPS                           0   3     0   978  +3032ns[+3025ns] +/-   11us
^- clock.sjc.he.net              1  10    37   980  -6892us[-6892us] +/-   32ms
^- tick.srs1.ntfo.org            3  10   377   366  -8714us[-8714us] +/-  134ms
^- ntp1.wiktel.com               1  10   357   23m    -14ms[  -14ms] +/-   35ms
^- linode227395.stevemeacha>     3  10   275   40m  -5000us[-7211ns] +/-   58ms

        chronyc sourcestats

210 Number of sources = 6
Name/IP Address            NP  NR  Span  Frequency  Freq Skew  Offset  Std Dev
==============================================================================
GPS                         6   3   151   -408.037   3835.704   -709ms    22ms
PPS                        10   4   526     +0.000      0.055   +120ns  7808ns
clock.sjc.he.net           27  17   84m     -0.263      1.181  -6134us  1752us
tick.srs1.ntfo.org         60  33   10h     +0.003      0.097  -6130us  2668us
ntp1.wiktel.com            24  10  500m     -0.094      0.201  -9183us  2122us
linode227395.stevemeacha>  44  24  589m     -0.060      0.089  -8188us  1766us

        chronyc tracking

Reference ID    : 50505300 (PPS)
Stratum         : 1
Ref time (UTC)  : Sun Mar 29 15:34:40 2020
System time     : 0.000000002 seconds fast of NTP time
Last offset     : -0.000000004 seconds
RMS offset      : 0.000075341 seconds
Frequency       : 5.940 ppm fast
Residual freq   : +0.000 ppm
Skew            : 0.058 ppm
Root delay      : 0.000000001 seconds
Root dispersion : 0.001043428 seconds
Update interval : 8.0 seconds
Leap status     : Normal

        chronyc activity

200 OK
4 sources online
0 sources offline
0 sources doing burst (return to online)
0 sources doing burst (return to offline)
0 sources with unknown address

        chronyd systemctl status

● chrony.service - chrony, an NTP client/server
   Loaded: loaded (/lib/systemd/system/chrony.service; enabled; vendor preset: enabled)
   Active: active (running) since Sun 2020-03-29 00:21:08 CDT; 10h ago
     Docs: man:chronyd(8)
           man:chronyc(1)
           man:chrony.conf(5)
  Process: 478 ExecStart=/usr/sbin/chronyd $DAEMON_OPTS (code=exited, status=0/SUCCESS)
  Process: 499 ExecStartPost=/usr/lib/chrony/chrony-helper update-daemon (code=exited, status=0/SUCCESS)
 Main PID: 494 (chronyd)
    Tasks: 2 (limit: 2200)
   Memory: 3.4M
   CGroup: /system.slice/chrony.service
           ├─494 /usr/sbin/chronyd -F -1
           └─497 /usr/sbin/chronyd -F -1

Mar 29 00:21:31 draws chronyd[494]: Selected source GPS
Mar 29 00:21:31 draws chronyd[494]: System clock wrong by 9.604035 seconds,…rted
Mar 29 00:21:41 draws chronyd[494]: System clock was stepped by 9.604035 seconds
Mar 29 00:21:51 draws chronyd[494]: Selected source 69.89.207.99
Mar 29 00:21:53 draws chronyd[494]: Selected source 208.79.89.249
Mar 29 00:21:53 draws chronyd[494]: Selected source 69.89.207.99
Mar 29 00:25:33 draws chronyd[494]: Selected source GPS
Mar 29 00:26:11 draws chronyd[494]: Source 208.79.89.249 replaced with 148.…3.91
Mar 29 00:26:21 draws chronyd[494]: Selected source PPS
Mar 29 09:09:25 draws chronyd[494]: Source 148.251.183.91 replaced with 216….202
Hint: Some lines were ellipsized, use -l to show in full.

        gpsd systemctl status

● gpsd.service - GPS (Global Positioning System) Daemon
   Loaded: loaded (/lib/systemd/system/gpsd.service; enabled; vendor preset: enabled)
   Active: active (running) since Sun 2020-03-29 00:21:08 CDT; 10h ago
  Process: 513 ExecStart=/usr/local/sbin/gpsd $GPSD_OPTIONS $OPTIONS $DEVICES (code=exited, status=0/SUCCESS)
 Main PID: 516 (gpsd)
    Tasks: 3 (limit: 2200)
   Memory: 1.4M
   CGroup: /system.slice/gpsd.service
           └─516 /usr/local/sbin/gpsd -n /dev/ttySC0 /dev/pps0

Mar 29 00:21:08 draws systemd[1]: Starting GPS (Global Positioning System) …n...
Mar 29 00:21:08 draws systemd[1]: Started GPS (Global Positioning System) D…mon.
Hint: Some lines were ellipsized, use -l to show in full.
gpsd: 3.20 (revision 3.20)
pi@draws:~/n7nix/gps $