> However on android the sampling rate of the acceleration sensor is limited to 50/s. At least if you install through the official app store.
My understanding is that it’s the same even on iOS (or at least on my iPhone SE 2020). More specifically, the output only measures till 50hz (but the sensor sampling rate is actually 100hz - Nquist, you need double the measured frequency as sampling frequency, yada yada.)
By the way, it’s important to note that measuring vibrating things can permanently damage the OIS VCs in the camera. (See: Apple’s warning against motorcycle mounts.) my iPhone already had a broken OIS so I didn’t mind as much.
I get 100/s on an iPhone SE2. 50/s on a Samsung Galaxy A16 which was released in 2024 or 2025, but that is due to an API restriction. You can export from phyphox (.xslx or .cvs). You get timestamps in the first column. Phyphox refers to the raw data rate, not Nyquist freq.
The sensors have analog lowpass filters that can be adjusted in order to avoid aliasing.
In general, with more bandwidth you can do more intrusive things. But if you want to tell wether two people ride in the same car, 50 Hz should be sufficient anyways.
Huh? I get 500 Hz here on a Samsung from 2019 and make use of it regularly. Sensor frequency is one of the things I check before buying a new phone, surely newer Android versions haven't killed that with new api restrictions?!
Edit: no, it can't have. Then the phone sensor database would show that since it is built from submissions within Phyphox: https://phyphox.org/sensordb/
I'm not sure what problem you're running into (perhaps a very unusual phone that has only a 50 Hz accelerometer) but Android/Phyphox can do way more than 50 Hz
It is a Samsung a16 and it is just an observation I made, not a problem at all. If it was, I would try another installation source or even switch to a degoogled OS first to get more control over the hardware. Only thing I tried to get more samples was fiddling with the App restrictions. But it really doesn’t matter at all.
The coolest thing I ever did with that was finding wires in a friends wall - we needed to drill a hole and it was unclear whether the wires went up (problem) or right from the outlet. I didn't have a cable finder on hand but did have the epiphany to put a large load on the outlet (we used a kettle, a hairdryer would also work, just needs a lot of watts) and use the Fourier transform magnet spectrum to find the 50 Hz grid frequency in the wall. Worked beautifully.
Sadly, since most smartphone magnetometers seem to have a sample rate of 100/s, this will not be applicable to Americans and everyone else with a 60 Hz grid frequency, the 50 Hz were already at the Nyquist–Shannon limit.
> this will not be applicable to Americans and everyone else with a 60 Hz grid frequency, the 50 Hz were already at the Nyquist–Shannon limit.
The trick should work fine, but you may confuse the 60Hz signal with a 40Hz signal [1] [2].
This should work for higher frequencies too, but if the frequency is toooo high the problem is that the magnetometers averages a short period of time (or use a window) instead of being an actual an instant measurement.
[1] Calculated using my fingers moving in the air. 60=50+10 -> 50-10=40. I think it's 40Hz, but I would need a pencil and paper to be sure.
The hack you can do is to additionally sample at, say, 97Hz as well as 100Hz. A 97Hz sampling rate will then see a 60 Hz aliased to 40Hz signal go from 40Hz to 37Hz, showing that your signal is probably actually really 60Hz and not 40Hz. If it was 40Hz at 100 and 97Hz sampling frequency, then it's probably actually 40Hz.
(It's been a looong time since signals class though.)
If your sample rate is 100 Hz you would usually apply analog lowpass filtering at around 40 Hz, well below Nyquist. But with enough load on the line, since no filter has perfect attenuation in the stop band…
One of my kids has science project due each quarter in school, and this is our go-to app. We’ve measured acceleration in an elevator, sound attenuation of an audio source in a small vacuum chamber, and the Doppler effect. The app makes it easy to capture and export the data points to make graphs. I highly recommend this even just to play around with.
I think there's loads of scope to use phone cameras as dataloggers too, especially for older equipment that doesn't have an easy way to connect/export the data.
(I've been meaning for ages to write a piece of software that's able to extract change over time data from a video of a 7 segment display, like on a balance or a digital thermometer or something)
I've had great fun using Phyphox to visualise my hand getting closer/farther from my phone based on the presence of my magnet implant. So many cool little things the app can visualise and measure, especially when used it creative ways.
My parents have a sound bowl, and I wanted to know the resonance frequency. Took an audio spectrum, zoomed in on the first peak, read the frequency (iirc it was around 208 Hz).
Good toolkit to have around. Recently used it to verify the true RPM of a system (using the accelerometer spectrum tool) against its control loop implementation.
Indeed. I always keep it installed on my devices, as it turns the phone into a poor man's tricorder, and that's handy sometimes.
Most recently I used it to check light levels at home in different rooms, to determine where we need to boost or replace LED strips. Sure, there's million Lux meter apps, but Phyphox is better than all of them and demonstrates why these things shouldn't be dedicated apps in the first place. In the past I also made use of EM and vibration frequency displays to troubleshoot hardware.
A complement to that is https://play.google.com/store/apps/details?id=org.intoorbit.... which, once upon a time, helped me track down a source of rage-inducing, late-night high-frequency beeping that was driving us insane - down to specific apartment in a block on the other side of the street. I ended up friends with those neighbors, after teaching them how to disable the alarm clock on their Bluetooth radio when they go away for a weekend.
There is a paper you can cite if you use phyphox professionally.[1]
In Germany phyphox is quite popular in physics education.
However on android the sampling rate of the acceleration sensor is limited to 50/s. At least if you install through the official app store.
[1] https://iopscience.iop.org/article/10.1088/1361-6552/aac05e
> However on android the sampling rate of the acceleration sensor is limited to 50/s. At least if you install through the official app store.
My understanding is that it’s the same even on iOS (or at least on my iPhone SE 2020). More specifically, the output only measures till 50hz (but the sensor sampling rate is actually 100hz - Nquist, you need double the measured frequency as sampling frequency, yada yada.)
By the way, it’s important to note that measuring vibrating things can permanently damage the OIS VCs in the camera. (See: Apple’s warning against motorcycle mounts.) my iPhone already had a broken OIS so I didn’t mind as much.
I get 100/s on an iPhone SE2. 50/s on a Samsung Galaxy A16 which was released in 2024 or 2025, but that is due to an API restriction. You can export from phyphox (.xslx or .cvs). You get timestamps in the first column. Phyphox refers to the raw data rate, not Nyquist freq.
The sensors have analog lowpass filters that can be adjusted in order to avoid aliasing.
In general, with more bandwidth you can do more intrusive things. But if you want to tell wether two people ride in the same car, 50 Hz should be sufficient anyways.
Phyphox has a smartphone sensor database:
https://phyphox.org/sensordb/
Huh? I get 500 Hz here on a Samsung from 2019 and make use of it regularly. Sensor frequency is one of the things I check before buying a new phone, surely newer Android versions haven't killed that with new api restrictions?!
Edit: no, it can't have. Then the phone sensor database would show that since it is built from submissions within Phyphox: https://phyphox.org/sensordb/
I'm not sure what problem you're running into (perhaps a very unusual phone that has only a 50 Hz accelerometer) but Android/Phyphox can do way more than 50 Hz
It is a Samsung a16 and it is just an observation I made, not a problem at all. If it was, I would try another installation source or even switch to a degoogled OS first to get more control over the hardware. Only thing I tried to get more samples was fiddling with the App restrictions. But it really doesn’t matter at all.
Does the version on f-droid not have that limitation?
That is a possibility, didn’t check
The coolest thing I ever did with that was finding wires in a friends wall - we needed to drill a hole and it was unclear whether the wires went up (problem) or right from the outlet. I didn't have a cable finder on hand but did have the epiphany to put a large load on the outlet (we used a kettle, a hairdryer would also work, just needs a lot of watts) and use the Fourier transform magnet spectrum to find the 50 Hz grid frequency in the wall. Worked beautifully.
Sadly, since most smartphone magnetometers seem to have a sample rate of 100/s, this will not be applicable to Americans and everyone else with a 60 Hz grid frequency, the 50 Hz were already at the Nyquist–Shannon limit.
> this will not be applicable to Americans and everyone else with a 60 Hz grid frequency, the 50 Hz were already at the Nyquist–Shannon limit.
The trick should work fine, but you may confuse the 60Hz signal with a 40Hz signal [1] [2].
This should work for higher frequencies too, but if the frequency is toooo high the problem is that the magnetometers averages a short period of time (or use a window) instead of being an actual an instant measurement.
[1] Calculated using my fingers moving in the air. 60=50+10 -> 50-10=40. I think it's 40Hz, but I would need a pencil and paper to be sure.
[2] https://en.wikipedia.org/wiki/Aliasing
(40Hz's right)
The hack you can do is to additionally sample at, say, 97Hz as well as 100Hz. A 97Hz sampling rate will then see a 60 Hz aliased to 40Hz signal go from 40Hz to 37Hz, showing that your signal is probably actually really 60Hz and not 40Hz. If it was 40Hz at 100 and 97Hz sampling frequency, then it's probably actually 40Hz.
(It's been a looong time since signals class though.)
If your sample rate is 100 Hz you would usually apply analog lowpass filtering at around 40 Hz, well below Nyquist. But with enough load on the line, since no filter has perfect attenuation in the stop band…
One of my kids has science project due each quarter in school, and this is our go-to app. We’ve measured acceleration in an elevator, sound attenuation of an audio source in a small vacuum chamber, and the Doppler effect. The app makes it easy to capture and export the data points to make graphs. I highly recommend this even just to play around with.
I think there's loads of scope to use phone cameras as dataloggers too, especially for older equipment that doesn't have an easy way to connect/export the data.
(I've been meaning for ages to write a piece of software that's able to extract change over time data from a video of a 7 segment display, like on a balance or a digital thermometer or something)
also on https://f-droid.org/en/packages/de.rwth_aachen.phyphox/
Seems like a more advanced version of Arduino Science Journal https://www.arduino.cc/education/science-journal/
I've had great fun using Phyphox to visualise my hand getting closer/farther from my phone based on the presence of my magnet implant. So many cool little things the app can visualise and measure, especially when used it creative ways.
I used it just the other day.
My parents have a sound bowl, and I wanted to know the resonance frequency. Took an audio spectrum, zoomed in on the first peak, read the frequency (iirc it was around 208 Hz).
Compare https://play.google.com/store/apps/details?id=cc.arduino.sci...
cc.arduino.sciencejournal for anyone else who is wondering what's behind HN's ellipsis
It’s the GOAT - I showed the app to a bunch of secondary school physics teachers and they were thrilled.
If you prefer not to deal with an app store: https://www.apkmirror.com/apk/rwth-aachen-university/phyphox...
The title was slightly editorialized for clarity.
I've been using Trail Sense [0] for sensor-related information after learning about it from a friend.
The interface is more polished, but the information is less technical than Phyphox (as the app is geared towards being a survival toolkit).
[0] https://github.com/kylecorry31/Trail-Sense
Good toolkit to have around. Recently used it to verify the true RPM of a system (using the accelerometer spectrum tool) against its control loop implementation.
Indeed. I always keep it installed on my devices, as it turns the phone into a poor man's tricorder, and that's handy sometimes.
Most recently I used it to check light levels at home in different rooms, to determine where we need to boost or replace LED strips. Sure, there's million Lux meter apps, but Phyphox is better than all of them and demonstrates why these things shouldn't be dedicated apps in the first place. In the past I also made use of EM and vibration frequency displays to troubleshoot hardware.
A complement to that is https://play.google.com/store/apps/details?id=org.intoorbit.... which, once upon a time, helped me track down a source of rage-inducing, late-night high-frequency beeping that was driving us insane - down to specific apartment in a block on the other side of the street. I ended up friends with those neighbors, after teaching them how to disable the alarm clock on their Bluetooth radio when they go away for a weekend.
Cool app dude