After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 497257 - alsasink fails to play test tone
alsasink fails to play test tone
Status: RESOLVED NOTGNOME
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
0.10.14
Other Linux
: Normal critical
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2007-11-16 00:44 UTC by John Faith
Modified: 2007-11-21 22:10 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description John Faith 2007-11-16 00:44:52 UTC
On a PowerPC embedded Linux board (kernel 2.6.22) alsasink fails to play the audio test tone.

Source used:
- gstreamer-0.10.14.4
- gst-plugins-base-0.10.14.5
Also attempted (same results):
- gstreamer-0.10.12
- gst-plugins-base-0.10.12

# GST_DEBUG=*alsa*:5 gst-launch audiotestsrc ! audioconvert ! audioresample ! alsasink 

0:00:00.411326000   718 0x10016050 DEBUG alsa gstalsaplugin.c:75:plugin_init: binding text domain gst-plugins-base-0.10 to locale dir /usr/share/locale
0:00:00.413399000   718 0x10016050 DEBUG alsa gstalsasink.c:273:gst_alsasink_init:<GstAlsaSink@0x1005c1d0> initializing alsasink
0:00:00.474142000   718 0x10016050 DEBUG alsa gstalsasink.c:303:gst_alsasink_getcaps:<alsasink0> device not open, using template caps
Setting pipeline to PAUSED ...
0:00:00.507308000   718 0x10016050 LOG   alsa gstalsasink.c:640:gst_alsasink_open:<alsasink0> Opened device default
0:00:00.512609000   718 0x10016050 LOG   alsa gstalsa.c:30:gst_alsa_detect_rates:<alsasink0> probing sample rates ...
0:00:00.513033000   718 0x10016050 DEBUG alsa gstalsa.c:49:gst_alsa_detect_rates:<alsasink0> Min. rate = 4000 (4000)
0:00:00.513321000   718 0x10016050 DEBUG alsa gstalsa.c:50:gst_alsa_detect_rates:<alsasink0> Max. rate = 2147483647 (-1)
0:00:00.513738000   718 0x10016050 LOG   alsa gstalsa.c:265:gst_alsa_detect_channels:<alsasink0> probing channels ...
0:00:00.514031000   718 0x10016050 DEBUG alsa gstalsa.c:309:gst_alsa_detect_channels:<alsasink0> Min. channels = 1 (1)
0:00:00.514311000   718 0x10016050 DEBUG alsa gstalsa.c:310:gst_alsa_detect_channels:<alsasink0> Max. channels = 8 (10000)
0:00:00.517409000   718 0x10016050 INFO  alsa gstalsasink.c:323:gst_alsasink_getcaps:<alsasink0> returning caps 0x10047960
Pipeline is PREROLLING ...
0:00:00.597161000   718 0x100848d0 LOG   alsa gstalsasink.c:308:gst_alsasink_getcaps:<alsasink0> Returning cached caps
0:00:00.675925000   718 0x100848d0 LOG   alsa gstalsasink.c:308:gst_alsasink_getcaps:<alsasink0> Returning cached caps
0:00:00.701477000   718 0x100848d0 LOG   alsa gstalsasink.c:308:gst_alsasink_getcaps:<alsasink0> Returning cached caps
0:00:00.733492000   718 0x100848d0 LOG   alsa gstalsasink.c:308:gst_alsasink_getcaps:<alsasink0> Returning cached caps
0:00:00.760054000   718 0x100848d0 LOG   alsa gstalsasink.c:308:gst_alsasink_getcaps:<alsasink0> Returning cached caps
0:00:00.785900000   718 0x100848d0 LOG   alsa gstalsasink.c:308:gst_alsasink_getcaps:<alsasink0> Returning cached caps
0:00:00.800496000   718 0x100848d0 LOG   alsa gstalsasink.c:308:gst_alsasink_getcaps:<alsasink0> Returning cached caps
0:00:00.814736000   718 0x100848d0 DEBUG alsa gstalsasink.c:582:alsasink_parse_spec:<alsasink0> Linear format : depth=32, width=32, sign=1, bigend=1
0:00:00.815234000   718 0x100848d0 DEBUG alsa gstalsasink.c:339:set_hwparams:<alsasink0> Negotiating to 1 channels @ 44100 Hz (format = S32_BE)
0:00:00.817626000   718 0x100848d0 WARN  alsa pcm_plug.c:712:snd_pcm_plug_hw_refine_schange: alsalib error: Unable to find an usable access for 'default'
0:00:00.818100000   718 0x100848d0 WARN  alsa gstalsasink.c:448:set_hwparams:<alsasink0> error: Sample format not available for playback: Invalid argument
0:00:00.820295000   718 0x100848d0 WARN  alsa gstalsasink.c:700:gst_alsasink_prepare:<alsasink0> error: Setting of hwparams failed: Invalid argument
ERROR: from element /pipeline0/alsasink0: Could not get/set settings from/on resource.
Additional debug info:
gstalsasink.c(448): set_hwparams (): /pipeline0/alsasink0:
Sample format not available for playback: Invalid argument
ERROR: pipeline doesn't want to preroll.
Setting pipeline to NULL ...
FREEING pipeline ...


aplay, which shows S16_LE format (vs S32_BE in alsasink), plays audio fine:
aplay -v gloaming.wav
Playing WAVE 'gloaming.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
Plug PCM: Hardware PCM card 0 'LM4550' device 0 subdevice 0

Its setup is:
stream       : PLAYBACK
access       : RW_INTERLEAVED
format       : S16_LE
subformat    : STD
channels     : 2
rate         : 44100
exact rate   : 44100 (44100/1)
msbits       : 16
buffer_size  : 2400
period_size  : 1200
period_time  : 27210
tick_time    : 4000
tstamp_mode  : NONE
period_step  : 1
sleep_min    : 0
avail_min    : 1200
xfer_align   : 1200
start_threshold  : 2400
stop_threshold   : 2400
silence_threshold: 0
silence_size : 0
boundary     : 1258291200
Comment 1 John Faith 2007-11-21 22:10:34 UTC
The failure seems to be in alsalib and not gstreamer since the demo program test/pcm in alsalib-1.0.15 has a similar error when setting audio format to S16_BE.