Skip to the content
2 layers82 × 52 mmMain v1, the printed circuit board in 3D

Source code and circuit design for the Remarkably Accurate Quartz Clock, a timepiece with ±10 sec annual accuracy

Size
82 × 52 mm
Copper layers
2
Thickness
1.6 mm
Parts
15
Nets
16
Pads
66
Tracks, vias
104, 5
Pours
2
Routed
Yes
KiCad
KiCad 5 (file 20171130)
Created
26 Feb 2023
Updated
21 Mar 2023

Overview

Main v1 is an open-source printed circuit board by gugray, from the gugray/Shizhong repository on GitHub, published under the MIT licence. It is a 2-layer board of 82 × 52 mm with 15 parts on 16 nets, routed with 104 tracks and 5 vias.

It is built around the ATMEGA88V-10PU and DS18B20. Its parts include 3 resistors, 3 switches, 2 capacitors, 2 ICs and 1 diode. It belongs with the lEDs and displays boards and the AVR (ATmega, ATtiny) boards of this library.

Main components

2

README

README.md

Remarkably Accurate Quartz Clock

This repository has all the code and design files for the Remarkably Accurate Quartz Clock documented on Hackaday.

The clock's circuit board, with a matchbox for scale The built-up clock in its laser-cut acrylic case

Can I use cheap, everyday components and build a quartz clock that beats specialized RTCs and matches the best commercial timepieces? Let's find out!

32kHz quartz crystals typically have a ±20ppm (parts per million) frequency tolerance, which translates to drift potentially in excess of 10 minutes per year. Specialized RTCs like DS3231 promise ±2ppm, or about ±1 minute per year.

RAQC aims for drift below 10 seconds per year. To achieve this, it implements fine-grained frequency correction in software. It has a screen to adjust time with subsecond precision, and it measures the temperature at 10-minute intervals to compensate for dynamic drift. After calibrating repeatedly at incresingly long intervals, RAQC knows the crystal's static error with a 0.01ppm precision.

Energy-saving programming techniques and a low-power LCD display keep the clock's current draw under 15μA, promising 1.5 years of uptime on a CR2032 coin cell.

Electronics

The KiCad 5.1.9 schematic and PCB are in /electronics. The ZIP file there is the Gerber export that I submitted to the PCB fab.

Laser-cut frame

The frame is laser-cut from 3mm acryclic; the top and bottom covers are 1mm transparent acrylic. The front panel with the engraved overview of the clock's menu is laser-cut from 2mm birch. The vector files for this are in /design. The .ai file is the original, but I included a version re-saved as Inkscape .svg as well.

Source code

The source code is in /code/board. I developed it using the PlatformIO extension for Visual Studio Code, so if you want to explore the code and build it yourself, that might be the easiest way to get started. The code uses the Arduino framework. It has only one dependency, the Wire library for I2C communication.

Parts

15
QtyValueFootprintReferences
3SW_PushConnector:PushButton5mmSW1, SW2, SW3
26pFResistor_THT:R_Axial_DIN0204_L3.6mm_D1.6mm_P2.54mm_VerticalC1, C2
110kResistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P10.16mm_HorizontalR1
11kResistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P10.16mm_HorizontalR3
132kHzCrystal:Crystal_C38-LF_D3.0mm_L8.0mm_HorizontalXTAL
13V CoinBattery:BatteryHolder_Keystone_3002_1x2032BT1
15kResistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P10.16mm_HorizontalR2
1ATmega88V-10PUPackage_DIP:DIP-28_W7.62mmU1
1DS18B20Package_TO_SOT_THT:TO-92_Inline_WideU2
1LCD_FeatherConnector:LCD_FeatherLCD
1LEDLED_THT:LED_D2.0mm_W4.0mm_H2.8mm_FlatTopD1
1PortConnector_PinHeader_2.54mm:PinHeader_1x06_P2.54mm_VerticalJ1

Similar boards

  • 2 layers33.7 × 97.8 mmHAN ESP TSS721, the printed circuit board in 3D

    HAN ESP TSS721

    UtilitechAS/amsreader-firmware

    ESP8266 and ESP32 compatible firmware to read, interpret and publish data to MQTT from smart electrical meters, both DLMS and DSMR is supported

    29 parts470
  • 2 layers121 × 68 mmFreeds sanchez, the printed circuit board in 3D

    Freeds sanchez

    pablozg/freeds

    Derivador de energía solar excedente creado por Pablo Zerón, Diseño PCB por Amcalo, Tester original por Aeizoon, Wiki por Zoilo Mora

    42 parts108
  • 2 layers80 × 54.9 mmESP32WifiAisTempVolt2, the printed circuit board in 3D

    ESP32WifiAisTempVolt2

    AK-Homberger/NMEA2000WifiGateway-with-ESP32

    This repository shows how to build a NMEA2000 WiFi Gateway with voltage and temperature alarms.

    18 parts94GPL-3.0
  • 2 layers52 × 61 mmArduino motorfocus, the printed circuit board in 3D

    Arduino motorfocus

    fehlfarbe/arduino-motorfocus

    Arduino motorfocus with moonlite protocol for telescopes

    23 parts58MIT
  • 2 layers69 × 57 mmBuoy4, the printed circuit board in 3D

    Buoy4

    wjpavalko/Maker-Buoy

    Repository of Open Source Maker Buoy Files

    46 parts39
  • 2 layers26 × 34.8 mmWemosD1Mini, the printed circuit board in 3D

    WemosD1Mini

    RuiSantosdotme/ESP8266-Multisensor-Shield

    Complete step-by-step instructions »

    10 parts29
  • 2 layers162 × 60 mmEsp shield, the printed circuit board in 3D

    Esp shield

    felixwittwer/homeassistant_automaic_greenhouse

    A cool Project to make your greenhouse smart. What about automaic irrigation and collecting enviromental data right from your garden.

    20 parts27
  • 2 layers123 × 87.5 mmFastLOGIC, the printed circuit board in 3D

    FastLOGIC

    Neumi/fastLOGIC

    An affordable Arduino-based board designed for straightforward (industrial) logic control, ideal for building small-scale automation and control solutions.

    180 parts23MIT

Questions

How big is the Main v1 PCB?

It measures 82 × 52 mm and has 2 copper layers, 1.6 mm thick.

What parts does the Main v1 use?

15 parts, built around the ATMEGA88V-10PU and DS18B20. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.

Where can I download the Main v1 KiCad files?

From the gugray/Shizhong repository on GitHub, at the commit this page was made from: the board is electronics/main-v1/main.kicad_pcb. PCBKit opens the board in the browser, with nothing to install.

Can I use the Main v1 design in my own project?

Its repository publishes it under the MIT licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).