speaker-Test

command-line speaker test tone generator for ALSA

speaker-test [-options]

From Rpi Zero 01/12/23 JEBH condensed

       aplay -L

null                Discard all samples (playback) or generate zero samples (capture)
default             Playback/recording through the PulseAudio sound server
sysdefault          Default Audio Device
lavrate             Rate Converter Plugin Using Libav/FFmpeg Library
samplerate          Rate Converter Plugin Using Samplerate Library
speexrate           Rate Converter Plugin Using Speex Resampler
jack                JACK Audio Connection Kit
oss                 Open Sound System
pulse               PulseAudio Sound Server
upmix               Plugin for channel upmix (4,6,8)
vdownmix            Plugin for channel downmix (stereo) with a simple spacialization
hw:CARD=vc4hdmi,DEV=0     vc4-hdmi, MAI PCM i2s-hifi-0 Direct hardware device without any conversions
plughw:CARD=vc4hdmi,DEV=0 vc4-hdmi, MAI PCM i2s-hifi-0 Hardware device with all software conversions
sysdefault:CARD=vc4hdmi   vc4-hdmi, MAI PCM i2s-hifi-0 Default Audio Device
hdmi:CARD=vc4hdmi,DEV=0   vc4-hdmi, MAI PCM i2s-hifi-0 HDMI Audio Output
dmix:CARD=vc4hdmi,DEV=0   vc4-hdmi, MAI PCM i2s-hifi-0 Direct sample mixing device
usbstream:CARD=vc4hdmi    vc4-hdmi USB Stream Output 

       surround40:CARD=ICH5,DEV=0
           Intel ICH5, Intel ICH5
           4.0 Surround output to Front and Rear speakers
       

       speaker-test -Dsurround40:ICH5 -c 6. # six audio channels 
-c
--channels NUM
NUM channels in stream
-D
--device NAME
PCM device name NAME
-f
--frequency FREQ
sine wave of FREQ Hz --help Print usage help
-b
--buffer ms
0 (default)use the maximal buffer size.
-p
--period ms
0 (default) the period given by -PM
-P
--nperiods PERIODS
Use number of periods. default 4.
-r
--rate hz
stream
-t
--test {pink|sine|wav}
Pink noise is perceptually uniform noise that is, it sounds like every frequency at once.
If you can hear any tone it may indicate resonances in your speaker system or room.
-twav play WAV files, either pre-defined files or given via -w
-l
--nloops COUNT
number of loops. 0 run infinitely.
WIth -s performs a single-shot without looping.
-s
--speaker CHANNEL
single-shot speaker test for channel . 1:left, 2:right, 3:rear-left, 4:rear-right, 5:center, 6:LFE, 7:side-left, 8:side-right,…
-w
--wavfile FILE
for the playback instead of pre-defined WAV files.
-W
--wavdir DIRECTORY
default /usr/share/sounds/alsa.
-m
--chmap MAP
Channel map to override. If the playback in a specific channel order or channel positions is required, use the channel position strings
-X
--force-frequency
Allow supplied FREQ to be outside the default range of 30-8000Hz. A minimum of 1Hz is still enforced.

USAGE EXAMPLES

Produce stereo sound from one stereo jack: speaker-test -Dplug:front -c2

Produce 4 speaker sound from two stereo jacks: speaker-test -Dplug:surround40 -c4

Produce 5.1 speaker sound from three stereo jacks: speaker-test -Dplug:surround51 -c6

To send a nice low 75Hz tone to the Woofer only and then exit: speaker-test -Dplug:surround51 -c6 -s1 -f75

To do a 2-speaker test using the spdif (coax or optical) output: speaker-test -Dplug:spdif -c2

Play in the order of front-right and front-left from the front PCM: speaker-test -Dplug:front -c2 -mFR,FL

SEE ALSO aplay(1)


1/12/23 Rpi zero jebh
speaker-test -D hw:3,3

speaker-test 1.2.4

Playback device is hw:3,3
Stream parameters are 48000Hz, S16_LE, 1 channels
Using 16 octaves of pink noise
ALSA lib pcm_hw.c:1829:(_snd_pcm_hw_open) Invalid value for card
Playback open error: -2,No such file or directory