STATUS: V0.7.0 MVP · PURE NUMPY DSP · ZERO-SCIPY RUNTIME

Advanced Timegrapher

Modern Watch Escape Analyzer

Non-invasive acoustic analyzer and modern software timegrapher for mechanical and quartz watches. Measures Rate (s/d), Beat Error (ms), and Amplitude (°) in real time through decoupled digital signal processing (DSP), with dynamic sound card clock drift calibration.

OS: macOS · Windows · Linux
Python: ≥ 3.12 (Pure NumPy)
License: GPL-3.0-or-later
Audio: SPSC Lock-Free Ring Buffer
Precision: Theil-Sen Robust Fit
Resolution: Sub-sample P1 / P3
Advanced Timegrapher — Horological DSP Test Bench
Caliber:
BPH: 28800 Lift: 51.0° Fs: 48000 Hz
MOCK
RATE s/d
+1.2
Trend: stable (±0.2 s/d)
BEAT ERROR ms
0.1
at the drop (P3): 0.20 ms
AMPLITUDE deg (°)
295°
tic: 294° · tac: 296°
SIGNAL QUALITY / SNR 34.8 dB
TELEMETRY STATISTICS
Max: +1.8 s/d Min: +0.6 s/d Delta: 1.2 s/d Mean: +1.2 s/d Elapsed: 00:42 Clock Drift: +0.00 ppm
Paper Tape (timing of every tic and tac; slope = rate)
28,800 bph (0.0%) COSC [-4 / +6 s/d]
Real-Time Escapement Oscilloscope (P1 / P2 / P3)
■ P1 (Unlock)   ■ P2 (Impulse)   ■ P3 (Drop)
Layered Architecture · Metrology Core

High-Fidelity Horological Engineering

Engineered from first principles with strict separation of concerns: lock-free audio capture, pure NumPy mathematical core, and total algorithmic transparency without black boxes.

Layer 1 & 2 · Audio & DSP

Pure NumPy Acoustic DSP Core

Digital signal processing 100% written in Python/NumPy without runtime dependencies on SciPy or C++ extensions. Lock-free SPSC (Single-Producer Single-Consumer) ring buffer with absolute sample indexing synchronized to the ADC hardware clock.

// SPSC Ring Buffer: Zero Audio Loss
index_abs = total_samples + write_head
residuals = t_host - (n / f_s)
  • Dedicated child process for audio capture (native PortAudio).
  • GUI operations never delay or block audio sample ingestion.
  • Automated buffer overwrite detection (`SamplesOverwritten`).
Layer 2 · Beat Detector

Swiss Lever Tri-Pulse Analysis

Precise acoustic identification of the three discrete physical events produced during each alternation by the balance wheel, pallet fork, and escape wheel. Sub-sample temporal resolution with automatic noise floor rejection.

t_lift = P3 - P1 (Lift Duration)
A = LA / (2 · sin(π · f · t_lift))
  • P1 (Unlocking): Impulse pin enters the fork notch.
  • P2 (Impulse): Escape tooth slides over pallet impulse face.
  • P3 (Drop & Lock): Tooth hits locking face and fork hits banking pin.
Layer 3 · Metrics Engine

Weighted Parity Regression

Rate and beat error calculation using robust linear regression weighted by tic/tac parity with 5σ trimming (MAD outlier filter), eliminating false deviations from external ambient shocks.

t_k = a + P·k + c·(-1)^k
Rate = (P_nom / P - 1) · 86400 [s/d]
Beat Error = 2·|c| [strictly evaluated at P1]
  • Beat error measured at P1 for pure balance symmetry isolation.
  • Independent tracking of mean amplitude, tic amplitude, and tac amplitude.
  • Sliding measurement windows from 10 s to 60 s with 4 Hz telemetry refresh.
Layer 4 · Hardware Clock

ADC Clock Drift Compensation

Consumer USB sound card crystal oscillators carry tolerances of ±30 to ±100 ppm (where 1 ppm = 0.0864 s/d). Advanced Timegrapher measures and eliminates this systematic hardware bias.

1 ppm = 0.0864 s/d
+35 ppm uncorrected = +3.02 s/d false reading
Theil-Sen lower envelope estimator (Confidence 0-3)
  • Support for external GPS PPS reference (NEO-6M at 4 kHz).
  • Automatic device-specific calibration persistence.
  • Zero systematic drift distortion in reported watch daily rate.
Layer 5 · Visualization

Continuous Virtual Paper Tape

Faithful digital recreation of legendary laboratory timegrapher tape rolls. Individual dots for every beat categorized by parity (tic/tac), where trace slope translates visually to rate in ms.

PyQt6 / pyqtgraph rendering core
1-px non-antialiased peak downsampled paths
0 GUI stutters (GUI latency < 33 ms @ 30 FPS)
  • Dynamic oscilloscope focused on P1 / P2 / P3 acoustic gates.
  • Paper tape history with auto-scale and 1×, 2×, 4× zoom levels.
  • Capture health indicator and real-time clipping detection.
Extensibility · Caliber DB

Quartz Mode & Caliber Presets

Dedicated diagnostic mode for stepper quartz watches (1 to 16 pulses per second). Integrated watch movement database (`watch_db.csv`) with verified factory parameters.

ETA C07 (Powermatic 80): LA 51° · 21.6k
Miyota 9015: LA 51° · 28.8k · Seiko 4R36: LA 53°
Seagull ST1901: LA 47° (Verified Weishi 1900 benchmark)
  • 24-bit FLAC audio recording with Vorbis / ICMT metadata.
  • Export sessions to CSV for positional delta diagnostics (DU, DD, etc.).
  • Universal support for USB piezo clamp mics (CM18) and studio mics.
Swiss Lever Escapement Physics

The Three Acoustic Impulses (P1, P2, P3)

Amplitude: A = LA / [2 · sin(π · f · t_lift)]

In every half-oscillation, the escapement produces three sequential acoustic transients. Measuring the sub-millisecond interval between P1 and P3 is the physical foundation required to calculate the balance wheel amplitude without invasive optical teardowns.

P1 · Unlocking
Impulse Pin Fork Entry

The balance wheel impulse pin strikes the fork notch and moves the pallet to release the locked escape tooth. This is the only sound directly produced by balance wheel inertia. For this reason, true horological Beat Error is measured strictly at P1.

P2 · Impulse
Energy Transfer Phase

The escape tooth slides along the impulse face of the pallet jewel, transferring energy to maintain oscillation. It is an irregular acoustic glide that laboratory Witschi meters omit when computing the lift angle window.

P3 · Drop & Lock
Impact on Pallet & Banking Pin

The escape wheel tooth drops onto the opposing pallet stone and the pallet fork hits the banking pin. This is acoustically the most energetic impact shock wave, serving as the timing anchor in detection.

HOROLOGICAL DEVELOPMENT ROADMAP

Project Roadmap & Future Capabilities

Current Phase: Phase 6 Validation

Strategic milestones driving Advanced Timegrapher from initial community validation into a professional-grade laboratory horological diagnostic instrument.

Phase 6 · In Progress

Acoustic Benchmark & Normalization

Cross-validation against physical Witschi Chronoscope and Weishi 1900 reference hardware. Normalized cross-correlation on live templates to prevent lobe jumps in noisy calibers (e.g. Seiko 4R36).

Hardware Clock

GPS PPS & Hardware PLL/FLL

Sub-microsecond synchronization using NEO-6M GPS 1-PPS pulses with a 4 kHz acoustic buzzer. Proportional-Integral (PI) NTP-style PLL/FLL loop to correct sound card crystal drift block-by-block.

Diagnostics

Long-Term Spectral Analysis

Teager-Kaiser nonlinear energy operator combined with FFT and Lomb-Scargle periodograms to diagnose cyclical gear train defects (escape wheel eccentricity @ 7.5 s, fourth wheel @ 60 s).

Watchmaking Tools

Live Regulation Assistant

Real-time interactive guidance for watchmakers adjusting the regulator curb pins and balance spring stud holder, providing directional visual cues for instantaneous beat error and rate centering.

Multiplatform Distribution

Quick Installation

Native standalone installers for desktop operating systems or direct pure Python pip deployment.

macOS 11+ (Apple Silicon & Intel)

Universal `.dmg` Bundle

Native macOS bundle packaged with PyInstaller, bundled PortAudio, and Retina display support.

macOS Terminal
# 1. Download .dmg from Releases # 2. Drag Advanced Timegrapher to /Applications # 3. For unsigned beta Gatekeeper notice: xattr -cr /Applications/Advanced\ Timegrapher.app
Download .dmg
Windows 10 / 11 (64-bit)

Installer `.exe` / Inno Setup

Setup wizard or portable `.zip` binary with WASAPI / MME PortAudio low-latency drivers.

PowerShell
# Extract .zip or run adv-tg-setup.exe # On Windows SmartScreen warning: "More info" -> "Run anyway" .\adv-tg.exe
Download Windows .exe
Linux & Pure Python Pip

Pip or RPM Package

Standard install on any modern distribution (Debian, Ubuntu, Fedora, Arch) with Python ≥ 3.12.

Bash
# Install native PortAudio dependency sudo apt install libportaudio2 # Pure Python installation via pip pip install advanced-timegrapher adv-tg
View Linux Packages