2026-03-28 06:26:29 -06:00
2025-10-29 17:02:44 -06:00
2025-10-30 00:56:31 -06:00
2025-10-29 22:37:31 -06:00
2025-10-29 23:20:32 -06:00
2025-10-30 01:13:17 -06:00
2025-10-29 21:19:40 -06:00
2025-10-30 09:34:06 -06:00
2025-10-30 00:56:31 -06:00
2025-10-30 04:39:18 -06:00
2025-10-30 16:35:02 -06:00
2026-03-28 06:26:29 -06:00
2025-10-30 17:55:09 -06:00
2025-10-29 19:35:32 -06:00
2025-10-30 16:36:00 -06:00
2025-10-30 14:49:28 -06:00
2025-10-30 01:55:00 -06:00
2025-10-30 09:34:06 -06:00

Precision Timekeeping Fuckery

Usage

  • install: bash ~/Precision-Timekeeping-Fuckery/time_fuckery.sh
  • uninstall bash ~/Precision-Timekeeping-Fuckery/time_fuckery.sh u
  • test: bash ~/Precision-Timekeeping-Fuckery/time_fuckery.sh t
  • nuke logs and temp files: bash ~/Precision-Timekeeping-Fuckery/time_fuckery.sh n
  • measure offset (chrony_stats.py) bash ~/Precision-Timekeeping-Fuckery/time_fuckery.sh m
  • service status bash ~/Precision-Timekeeping-Fuckery/time_fuckery.sh s status
  • service restart bash ~/Precision-Timekeeping-Fuckery/time_fuckery.sh s restart

How it works

Services

  • gpsd
  • chrony
  • telegraf
  • influxdb
  • grafana-server
  • syslog-ng

Testing

Status (Everything)

  • bash ~/Precision-Timekeeping-Fuckery/full_status.sh

Status (Services)

  • bash ~/Precision-Timekeeping-Fuckery/status_services.sh

Test PPS

  • sudo ppstest /dev/pps0

Logs Stuff

Chrony Logs

  • sudo tail -f /var/log/chrony/tracking.log
  • sudo tail -f /var/log/chrony/statistics.log
  • sudo tail -f /var/log/chrony/measurements.log

Telegraf Logs

  • sudo tail -f /var/log/telegraf/telegraf.log

Grafana Logs

  • sudo tail -f /var/log/grafana/grafana.log

Influxdb Logs

  • sudo tail -f /var/log/syslog

Root Crontab Logs

  • sudo tail -f /var/log/root-crontab.log

Setup

Hardware

  1. Raspberry Pi 4+
  2. A timekeeping-specific GPS Module U-BLOX LEA-M8T-0-10
  3. High precision RTC Module Adafruit DS3231 Precision RTC Breakout
    1. CR1220 Battery for RTC Module
  4. GPS Antenna
    1. GPS Antenna Cable
    2. GPS Antenna Adaptor
  5. Jumper wire to wire it up

Wiring

Pins and Wiring Guide

OS

  1. Raspberry Pi OS 64 bit lite
    1. Raspberry Pi imager
    2. Configure in imager
      1. hostname: grandmasterclock
      2. enable ssh
      3. ssh key
      4. username
      5. password
      6. locale
      7. keyboard

Install (Auto)

WILL REBOOT IN BETWEEN EACH COMMAND

  1. curl -s https://raw.githubusercontent.com/PrincessPi3/Precision-Timekeeping-Fuckery/refs/heads/main/time_fuckery.sh?nocache=$RANDOM | $SHELL
  2. git -C ~/Precision-Timekeeping-Fuckery pull && bash ~/Precision-Timekeeping-Fuckery/time_fuckery.sh && sudo reboot
    1. each reboot run the above command a total of four (4) times
  3. https://grandfatherclock:3000
    1. default login: admin and admin
      1. set new password
    2. data sources->add new->influx db
      1. name "influxdb1"
      2. query language: influxdb
      3. http
        1. url: http://127.0.0.1:8086
        2. timeout seconds: 3
      4. database: Chrony_Stats
      5. user, pass: blank
      6. save and test
    3. Dashboards->New-Import
      1. Upload Garfana-Visualization.json raspi-config Run raspi-config
  4. Interface Options->Serial Port
    1. Would you like a login shell to be accessible over serial?
    2. Would you like the serial port hardware to be enabled?
  5. Interface Options-I2C
    1. Enable Yes
  6. Advanced Options 1. A1 Expand Filesystem

Clients

Windows

  1. Open the Control Panel and navigate to the Date and Time settings.
  2. Click on "Internet Time" and then "Change settings".
  3. Enable the option to "Synchronize with an Internet time server".
  4. Choose a time server from the available list or enter a custom one.
  5. Click "OK" to save the changes.

Helpful Guide https://austinsnerdythings.com/2025/02/14/revisiting-microsecond-accurate-ntp-for-raspberry-pi-with-gps-pps-in-2025/

Old Module

Current Module

U-Blox Software (U-Center) https://www.u-blox.com/en/product/u-center

S
Description
No description provided
Readme 4.2 MiB
Languages
Shell 90.7%
Python 9.3%