6 ms·
I used pulsar detection techniques to turn a phone into a watch timegrapher
- tylerjaywood 7mo agoI built an audio timegrapher feature for my watch accuracy app, ChronoLog. Professional timegraphers use a piezo contact sensor and can cost upwards of $1,000. I wanted to do it with a phone mic. The problem: an iPhone's built-in microphone picks up a mechanical watch's tick at about 1.5 dB SNR. The solution turned out to be epoch folding — the same technique radio astronomers use to find pulsars. Stack 100+ tick periods together and you get +20 dB of effective gain, enough to reliably measure rate and beat error. The post covers the full DSP pipeline — bandpass filtering, epoch folding, autocorrelation (and why it finds harmonics before fundamentals at low SNR), Kalman filtering for convergence — and what I learned from five rounds of device testing.
- TApplencourt 7mo agoHow does it compare to other apps ("watch accuracy meter" for example) on android?
- tylerjaywood 7mo agoI have this in open beta on Android right now so you're welcome to give it a shot and let me know :) One difference is cost. I know that mine is lower cost, and is a one time unlock -- no subscription. So there's that. I'm also therefore positioned a little bit more towards the casual user, I prioritize speed of completion which means I need high confidence in a good signal quickly and don't hesitate to cancel mid-flow. I think one thing alternatives offer is the ability to run for longer -- like a 10 minute check for instance. There are marginal gains in precision for every additional second, but they seem to diminish pretty quickly past 30 secs or so. But that's one difference I'm aware of.
- TApplencourt 7mo ago>One difference is cost. I know that mine is lower cost, and is a one time unlock The one I'm talking about is free, so not sure about that. Not sure if I will pay for beta testing : )
- TheJoeMan 7mo agoDid you consider trying the iPhone accelerometer? Perhaps lay the phone face down on the table and then lay the watch on the back? Wondering if this would have higher or lower SNR.
- staplung 7mo agoI don't think it would work because the accelerometer updates are at too low a frequency. Apple's developer info says: ``` Before you start the delivery of accelerometer updates, specify an update frequency by assigning a value to the accelerometerUpdateInterval property. The maximum frequency at which you can request updates is hardware-dependent but is usually at least 100 Hz. ``` 100Hz is way too slow. Presumably some devices go higher but according to the article the peak signal is in the 3kHz to 15kHz range.
- CamelCaseCondo 7mo agoIf you know the structure of the “tick”, you can apply the technique of a correlation receiver. It can dig up signals below the noise floor and is used in GPS reception.
- tylerjaywood 7mo agoI'll do some research on this! I have a nagging feeling that there is more I can do to get the most out of this, but struggle with knowing where to look since this is not my background. I'm learning a lot as I go!
- mkesper 7mo agoAwesome writeup! I wonder whether with a real contact mic (Korg offers one for about 20 bucks) you could get much better results. Due to no 3,5mm on phones anymore it might be easier to use a sound-enabled SBC though.
- tylerjaywood 7mo agoThis is definitely the way. Even the old wired mics Apple phones used to ship with that had the little rectangle mic works better because you can press it right up against the case back.
- fecal_henge 7mo ago10 seconds per day is a little over 115 ppm. What is the frequency error of the reference clock that ultimately drives the ADC connected to the microphone?
- silisili 7mo agoI've tried these as apps before, and they never worked that well unfortunately. Perhaps the ticks aren't loud enough, or phone mics aren't that great, or background noise gets picked up as ticks, who knows. I bought and use the item linked below. It's big, and feels like tech straight out of the cold war era, but works great. https://www.amazon.com/gp/aw/d/B0081SSJZG https://www.amazon.com/gp/aw/d/B0081SSJZG
- tylerjaywood 7mo agoThis is the way. I got one as well to validate my results. Cost is the difference. If you're okay with close-enough and saving $145, I think the apps fit in a nice place. I will say, this flow is not the primary concept for the app. My intended design, and what it's been for 2+ years, is a tool that provides structured flows for inputting the time on your device and comparing it to atomic time (provided in my app). If you stagger these measurements over 6 or so hours for a day or two, you get a very precise reading and I still recommend this approach as being better.
- aanet 7mo agoFantastic post. As a mechanical watch collector / enthusiast, I enjoyed reading this. When you say "phone mic" do you mean the embedded one, or an external one?
- staplung 7mo agoIt uses the built-in one. But as discussed in the article they ran into the problem where even when you try to force using the internal mic, iOS will silently switch to the mic on a pair of AirPods if there's a pair connected.
- tylerjaywood 7mo agoThis is designed to be used by the internal device microphone. And this is in my write up, but if you have Airpods in all the time (like me), it will try to use that microphone and it will not work, and it will cause you to lose a day in frustration if you are working on something similar
- fred_is_fred 7mo agoThis is a fascinating read but what do you do with this information? Is there a threshold at which you need to take the watch apart and fix something or is this just useful info to know about your watch?
- matheusmoreira 7mo agoIt tells you for how long the time displayed by the watch is valid. If a watch loses ten seconds per day, in a month it will be about five minutes off. The objective is to minimize this number as much as possible. The open source sensor watch has a temperature sensor and software which turns it into a temperature compensated quartz watch. Mine loses time every year instead of every day or every month.
- coredog64 7mo agoPractically speaking, unless you only own a single mechanical watch you really only care about the per day loss.
- myself248 7mo agoYou know what they say. Man with one clock, always knows what time it is. Man with two clocks, never quite sure...
- tylerjaywood 7mo agoThis is my motto (data engineer frequently dealing with "but this source says...")
- matheusmoreira 7mo agoAre there reasons to worry about the accuracy of a watch one is not actively using?
- pastescreenshot 7mo agoIt is actually pretty useful if you own a few mechanical watches. Daily rate tells you how annoying the drift will be, beat error can hint that regulation or service is due, and measuring in different positions gives you a decent sanity check on movement health. Even if you never open the watch yourself, it is a much better baseline before taking it to a watchmaker.
- encom 7mo agoNeat, but I wish this wasn't a phone app (and Apple exclusive at that). My computer already has a high quality microphone that I assume would be more suitable for this purpose.
- tylerjaywood 7mo agoI used flutter so maybe some day! It's in open beta testing on the Play Store for Android. You can also find low cost external mics for your devices that work well.
- mysteria 7mo agoPiezo mics are pretty cheap, and if wired up to the microphone input of a computer or phone you could probably get better accuracy as well if you used the same signal processing techniques. Seems some people have done this already with a PC app: https://timeandtidewatches.com/how-to-make-your-own-timegrapher-watch-education/ https://timeandtidewatches.com/how-to-make-your-own-timegrap...
- darig 7mo ago[dead]
- ThroneCreator 7mo agoIf the signal is periodic and the tick structure is stable, you might also be able to improve SNR further by aligning the detected peaks and averaging them rather than just stacking raw samples. That sometimes helps suppress random noise even more when the waveform shape is consistent. Not sure how stable the waveform is across ticks in a mechanical watch though.
- zokier 7mo agoHow accurate are the clocks driving the DACs? Presumably the algorithm assumes that the audio is sampled at 48khz (or something) but that sample rate is unlikely to be perfectly exact?
- dune-aspen 7mo ago[flagged]
- syntaxing 7mo agoWow I’m a watch guy and this was a fun read. I used a couple of similar apps and they work ok. I wonder how yours stack up. You can get these cheap piezo ones for $150 but unsure how those perform either.