My NIXIE clocks have an on-board GPS receiver and I set the DS3232 to generate a 1 PPS output. On power-up I sanity check the internal registers and if it looks good I transfer the date and time to the uP memory. I pre-increment the internal time and at the PPS IRQ I update the display RAM from the internal register.
For GPS, I monitor the serial stream until I confirm a good lock and checksums. I then wait 20 seconds with no errors in the stream and then transfer the GPS time to the internal RAM and switch the PPS interrupt from the RTC to GPS. I assume the GPS PPS is good and use my internal counters, monitor the GPS for bad packets only. If there are too many bad packets, I revert to the RTC PPS. When I determine that GPS time is valid, I write the GPS time to the RTC. Also twice a day I update the RTC from the GPS at the GPS PPS (sort of disciplined). -Bill- On Wednesday, September 29, 2021 at 9:34:27 AM UTC-7 nixiebunny wrote: > My latest scope clock uses a DS3232 RTC chip for general timekeeping. This > chip only keeps time to the nearest second, as far as the user-readable > registers are concerned. > I also have a USB port that can read the time from a GlobalSat GPS puck. > This reports the time once a second through the Arduino TinyGPS library, > with the age of the time in milliseconds (typically 250). This should let > me compensate for the read delay by setting the tick (50/60Hz) counter in > my local time variables. > What do any of you time nuts do about displaying the time accurately, and > making the RTC be reasonably accurate compared to the GPS? > Do you discipline the RTC with GPS? Do you just ignore the RTC when GPS is > available? Set the RTC occasionally? > > -- You received this message because you are subscribed to the Google Groups "neonixie-l" group. To unsubscribe from this group and stop receiving emails from it, send an email to neonixie-l+unsubscr...@googlegroups.com. To view this discussion on the web, visit https://groups.google.com/d/msgid/neonixie-l/47245b8c-2baf-4271-ae33-c494350a4f15n%40googlegroups.com.