Experiment: Acoustic Stopwatch

From phyphox
Jump to: navigation, search
Acoustic Stopwatch
Experiment Acoustic Stopwatch
Category Timers
Used sensors Microphone

The experiment "Acoustic Stopwatch" is more a tool than an independent experiment. It listens for a noise to trigger a counter, which will stop again on the second noise. As the audio is sampled at 48kHz, this method is extremely precise (1ms resolution should be no problem) in theory, but the noises triggering the watch have to be short, precise and well synchronized to the event you want to measure. Often, the latter is a problem (see Problems and Solutions below).

Any sound is used as a trigger if its amplitude is above a threshold (as fraction of maximum amplitude, ranging from 0 to 1). You can set the threshold in the experiment.


The microphone is used to measure any sound. However, depending on your requirements you might want to attach an external microphone to your device to capture the trigger at its source.

Also note, that the watch will count too slowly if your phone is not fast enough to analyze the recording as fast as it is recorded. You can easily check if you are affected by this, by comparing the measurement to a regular clock. Do not worry: The watch will not go too fast on a fast device. If the device has a sufficient performance, the watch will be accurate.


There is no specific setup. Depending on what audio source you want to measure, you might want to aim the microphone at the sound source and try to damp the sound from the environment.

However, here are some examples:

Free fall with a ruler

You can measure the time it takes for a small object to drop. Place the object on a ruler extruding beyond the edge of a table and set up the acoustic stopwatch. Hit the ruler from the side to move it away below the object and simultaneously generate the first noise. The second noise is generated when the object hits the floor.

(Short example on Twitter. A full video will follow soon.)

Free fall with a balloon

A larger scale variation of the free fall experiment (for lecture hall scale and louder noises) can be achieved by attaching a small object (small steel ball) to the mouth piece of an inflated balloon. Place the balloon in a small hoop, so the object goes through the hoop and only the balloon holds both up at the edge of the hoop.

When you pop the balloon (first noise), the object starts to fall and will generate the second sound when hitting the floor. A metal plate at the bottom will amplify the second sound if it is too weak.

Note that there may be a small delay between the pop (when the balloon skin rips) and the actual beginning of the free fall (when the balloon skin has collapsed below the hoop's radius) and also, the collapsing balloon skin might add a little momentum to the dropping object. Therefore some error is to be expected.


The analysis is not too complicated, but uses a few if-modules to decide how many events have been detected so far. Otherwise, chunks of audio are analysed for their maxima and compared to the threshold. If the threshold is exceeded, we calculate the sample number of the maximum and transform it into a time.

If the analysis takes longer than filling the audio buffer, samples are missed, so the watch won't work reliably in this case.

Problems and resolutions

  • The stopwatch counts too slow. Unfortunately, this may happen if your phone cannot analyse the data as fast as it is recorded. At the moment, there is no solution to this except for using a faster phone.
  • The measured time does not match the theory of the experiment. Obviously, there can be many reasons for this, but the most common one is that the triggering noise does not precisely match the start or stop of the experiment. For very precise large-scale measurements you should consider the speed of sound. Also consider how the noise is generated (for example read about the timing problem of the balloon experiment above).
  • The stopwatch stops immediately after being triggered. In this case the duration of your start noise is too long. The experiment waits at least 100ms before accepting a second trigger, but if there is an echo or a ringing to the noise, this can be sufficient to stop the clock again. Try to dampen the noise or echo, increase the threshold or increase the minimum delay.
  • Trigger events are missed. In this case you probably need to decrease the threshold, so all your noises are above the threshold. You can use the audio oscilloscope experiment to check amplitudes.
  • The watch triggers without a noise. In this case you probably need to increase the threshold, so it is not triggered by the background noise. You can use the audio oscilloscope experiment to check amplitudes.

Demonstration video

Example of using this experiment to determine the speed of sound:

Example of using this experiment measure the duration of a free fall: