MY WEBCAM TEST GUIDE

Download PCM Audio Samples for Testing

How to get PCM audio samples for testing, how WAV and raw PCM files differ, which format settings to match, and how to create your own test files safely.

Quick answer: getting a PCM audio sample

The most reliable PCM audio sample is one you generate or convert yourself, because then you know its exact format. If you download a sample file instead, prefer a WAV file from a source you trust. A WAV file usually holds PCM data plus a header that tells players how to read it. A file with a .pcm or .raw extension usually has no header, so it only plays correctly if you know its sample rate, bit depth, channel count and byte order.

Before downloading anything, decide what you are testing, because that decides which kind of file you need:

  • Playback through an output device such as speakers or headphones: a short stereo WAV file with a test tone or speech.
  • A decoder, parser or streaming pipeline that expects raw data: a headerless PCM file with its parameters documented alongside the download.
  • Voice, recording or video call software: a mono speech file at the sample rate the software documents. Check that documentation rather than guessing; 16 kHz and 48 kHz are common in speech and calling tools.

How PCM audio works

PCM (pulse-code modulation) stores sound as a series of amplitude values measured at fixed intervals. It is uncompressed, so nothing is removed or approximated beyond the original sampling. To read PCM data correctly, a program needs these parameters:

  • Sample rate: how many values are stored per second for each channel, for example 44,100 or 48,000.
  • Bit depth and sample format: how each value is stored, for example 16-bit signed integer, 24-bit integer, 32-bit float or 8-bit unsigned.
  • Channels: mono, stereo or more. Multichannel PCM is normally interleaved, so the values for each channel alternate.
  • Byte order: little-endian or big-endian. WAV files normally store PCM as little-endian, and AIFF files normally use big-endian.

Because PCM is uncompressed, file size is predictable: sample rate multiplied by bytes per sample multiplied by channels gives bytes per second. For 48 kHz, 16-bit stereo audio that is 48,000 × 2 × 2 = 192,000 bytes per second, or about 11.5 MB per minute. For 44.1 kHz, 16-bit stereo it is 176,400 bytes per second. Comparing a downloaded file's size with this calculation is a quick way to spot a truncated or mislabelled file.

Some details depend on the software and its version, not on PCM itself: whether a player opens headerless files at all, which import settings it assumes by default, and which sample formats it supports. Check the documentation of the specific tool you are testing.

Creating and using PCM test files

If you have FFmpeg installed, you can generate a five-second 1 kHz test tone as a 48 kHz, 16-bit mono WAV file with this command: ffmpeg -f lavfi -i "sine=frequency=1000:duration=5" -ar 48000 -ac 1 -c:a pcm_s16le tone.wav

To turn that WAV file into a headerless PCM file with the same parameters, run: ffmpeg -i tone.wav -f s16le -c:a pcm_s16le tone.pcm. When you play or import the raw file later, you must supply the format yourself (signed 16-bit little-endian, 48,000 Hz, one channel). Option names for specifying channels have changed between FFmpeg releases, so check the documentation for your version.

To test with real speech, record a short clip in an audio editor or recorder and export it as uncompressed WAV. Select the correct input device first and set the input level so that loud passages do not clip. Record in a quiet room unless you specifically want background noise to test noise suppression.

Some practical ways to build a test set:

  • Format detection: keep matching pairs of WAV and raw PCM files with identical content, so you can compare how your software handles each.
  • Resampling: keep the same content at 44.1 kHz and 48 kHz and listen for changes in pitch or speed.
  • Channel handling: use a stereo file with sound in only the left channel to confirm that channels are not swapped or merged.
  • Call and recording setups: play a known file through the output device and compare it with what the other side or the recording receives.

Limits and related questions

If a raw PCM file plays as loud static or at the wrong speed, the playback settings do not match the data. A wrong sample rate changes speed and pitch. A wrong bit depth, signedness or byte order usually produces harsh noise. A wrong channel count changes the speed and mixes up the stereo image.

Is every WAV file PCM? No. WAV is a container and can also hold compressed codecs. If your test requires PCM, check the codec field in a media information tool rather than relying on the file extension.

A downloaded test file only exercises playback or processing. It says nothing about your microphone. To test a microphone, record your own sample and listen back to it.

When downloading PCM audio files, check that the extension and size match what was described. Scan downloads with your security software, and never run an executable that claims to be an audio sample. If you plan to include a sample in a test suite or redistribute it, check its license first.

Recordings you make yourself can capture other voices and background sound from the room. If you upload a recording to an online tool, read that tool's own statements about storage and deletion, and verify them rather than assuming files are processed locally or removed afterwards.