Live data from Hacker News

Guitar tuner that uses phone accelerometer

tautme.github.io

61–70 of 105 posts

Re: Guitar tuner that uses phone accelerometer

#61
post #58

The more reliable guitar tuners do something like this. You clip them on the neck, and they detect vibrations in the wood rather than from sound in the air.

oddly, this is how I learned to tune my guitar. I'm pretty tone deaf, but can feel the difference between the reference string and the string I'm trying to tune through the guitar.

This is fascinating.

Thanks for sharing.

Re: Guitar tuner that uses phone accelerometer

#62

This sounds neat, but I think I owned a tuner for about 6 weeks before I could do it by ear... EADGBe isn't that hard.

So what do you do when the lead singer is engaging in some stage banter and you need to tune between songs? IEMs? With what reference pitch?

Re: Guitar tuner that uses phone accelerometer

#63
post #61
post #58

Earlier quoted context omitted.

oddly, this is how I learned to tune my guitar. I'm pretty tone deaf, but can feel the difference between the reference string and the string I'm trying to tune through the guitar.

This is fascinating. Thanks for sharing.

The beat frequencies are pretty noticable, just tune until they go away

Re: Guitar tuner that uses phone accelerometer

#64
post #49

Earlier quoted context omitted.

The CIA…plug a set of regular headphones into a microphone jack, open a recording application and speak into the headphone speaker, you don’t need a 3 letter agency for that physics open secret.

I am crap with physics but was going to say I think the last 50+ years of speaker development has been about making them less a microphone than they inherently are.

They transmit sound. Anything able to detect the vibrations make it a microphone. Not sure how a speaker gets around that because it’s job is to vibrate.

Re: Guitar tuner that uses phone accelerometer

#65
post #42
post #24

This has some very interesting privacy and security risks. If the tech can do more complex frequency analysis, then couldn't it essentially be used as a microphone for a device that doesn't need permission.

It's a pretty well-known exploit that the CIA is capable of turning a lot of electronics with speakers into microphones. I imagine there is an entire classified backlog of things they can turn into microphones without the target's knowledge.

Tangent but the hidden no-electronics bug "The Thing / Great Seal Bug" really crazy

Re: Guitar tuner that uses phone accelerometer

#66
post #42
post #24

This has some very interesting privacy and security risks. If the tech can do more complex frequency analysis, then couldn't it essentially be used as a microphone for a device that doesn't need permission.

It's a pretty well-known exploit that the CIA is capable of turning a lot of electronics with speakers into microphones. I imagine there is an entire classified backlog of things they can turn into microphones without the target's knowledge.

I mean at this point I'm going to assume that any semiconductor device with more than a few pins has an embedded mems microphone.

Re: Guitar tuner that uses phone accelerometer

#67
post #49

Earlier quoted context omitted.

The CIA…plug a set of regular headphones into a microphone jack, open a recording application and speak into the headphone speaker, you don’t need a 3 letter agency for that physics open secret.

I am crap with physics but was going to say I think the last 50+ years of speaker development has been about making them less a microphone than they inherently are.

No, not really.

Dynamic loudspeakers and dynamic microphones are the same thing. They always have been the same.

They've got the knobs for the design variables turned in different directions, but they're still the same.

They even have the same frequency response whether they're being used as speakers or microphones at the moment.

Which brings up a valid way to measure the response of a microphone's design:

Use two of them. One as a speaker, and the other as a microphone. Play measurement-sounds out of one, and record the results on the other. Plot it out.

The deviations are magnified, but eliminating that magnification is just a math problem -- not an instrumentation problem. :)

Re: Guitar tuner that uses phone accelerometer

#68

Earlier quoted context omitted.

The accelerometers that protect the average hard drive are easily subverted for this purpose.

There is something better. The little sensor that maintains the distance between the spinning platter and the armature is sensitive enough to be a reasonable microphone. But it is inside a heavy metal box (the HDD) so you do need to shout at it. https://physics.aps.org/articles/v12/24 >> They tapped into the feedback system that helps control the position of the read head above the magnetic disk. When the head is buf…

Good old video of a guy shouting in a data center https://youtu.be/tDacjrSCeq4?si=ebFDFYufOdNIU9av

Re: Guitar tuner that uses phone accelerometer

#69

Earlier quoted context omitted.

Don't have a handle on it, unfortunately. But the algorithm is in here: https://github.com/tautme/phone-sensors/blob/main/guitar-tun... . Esp. lines 221–257 and 373–417.

The code mentions "autocorrelation" method: this is a method where you multiply the signal with delayed version of itself: result = sum(x[i] * x[i - delay] for i in some range). You vary the "delay" and pick the value that maximizes the result. This is based on the idea, that the sequential periods of the signal should be similar to each other. Not a very good method, prone to octave errors (showing pitch one octave…

I implemented the McLeod NSDF pitch method, which normalizes the autocorrelation to get a pretty reliable estimate with fewer octave jumps. For precise tuning I used phase tracking between successive single-bin DFTs tuned to the target frequency.

https://github.com/dsego/strobe-tuner/

Re: Guitar tuner that uses phone accelerometer

#70
post #50

Earlier quoted context omitted.

heh, a subacoustic G#?

I think the tuner is off by an octave - it has a lot of harmonics and sounded like a G on a bass guitar.

It seems odd that it would be an octave too low. If it detected any harmonics it would be too high.

Unless it didn't function like a string at all, then the harmonics would be all wrong.

Post reply on HN