Hi, after tracing the wavparse code, the error is caused by gst_wavparse_stream_data (GstWavParse * wav) about line 1997, gst_pad_push get error, if ((res = gst_pad_push (wav->srcpad, buf)) != GST_FLOW_OK) goto push_error; Does anyone have idea about how to debug this kind of error? Why USB Audio device cause this kind of error? Because When I test the same audio file via I2S device, it is OK, It is fail when I change to USB Audio device. Anyone have idea? 2012/7/30 Soho Soho123 <soho123.2012 at gmail.com>: > Hi All, > > > Does anyone have idea about the log ? > that gstreamer can not play wav file to usb audio alsa device. > > I use the command to play audio to usb alsa audio device. > gst-launch-0.10 -v filesrc location=/bin/audio_src_48k_le.wav ! > wavparse ! audioconvert ! alsasink device="hw:0,0" > > It is OK by "aplay" utility, but it is fail by gstreamer launch > ============================================================== > > 0:00:00.670000000 936 0x477720 DEBUG alsa > gstalsasink.c:277:gst_alsasink_init:<GstAl > saSink at 0x478c50> initializing alsasink > 0:00:00.670000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x477960 > 0:00:00.670000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x477960 > 0:00:00.680000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47c120 > 0:00:00.680000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47c120 > 0:00:00.680000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47c280 > 0:00:00.680000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47c280 > 0:00:00.680000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47c420 > 0:00:00.680000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47c420 > 0:00:00.680000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47c4a0 > 0:00:00.680000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47c4a0 > 0:00:00.680000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47c200 > 0:00:00.690000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47c200 > 0:00:00.690000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47c1a0 > 0:00:00.690000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47c1a0 > 0:00:00.690000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47dfc0 > 0:00:00.690000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47dfc0 > 0:00:00.690000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47c540 > 0:00:00.700000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47c540 > 0:00:00.700000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47e080 > 0:00:00.700000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47e080 > 0:00:00.700000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47dd60 > 0:00:01.800000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47dd60 > 0:00:01.810000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47c580 > 0:00:01.810000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47c580 > 0:00:01.810000000 936 0x477720 DEBUG alsa > gstalsasink.c:307:gst_alsasink_getcaps:<al > sasink0> device not open, using template caps > 0:00:01.810000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x477740 > 0:00:01.810000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x477740 > 0:00:01.810000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47ddc0 > 0:00:01.810000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47ddc0 > 0:00:01.820000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47c1c0 > 0:00:01.820000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47c1c0 > 0:00:01.820000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47dc80 > 0:00:01.820000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47dc80 > 0:00:01.820000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47dd20 > 0:00:01.820000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47dd20 > 0:00:01.820000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:611:gst_audio_convert_tr > ansform_caps:<audioconvert0> step1: (2) 0x47c060 > 0:00:01.820000000 936 0x477720 DEBUG audioconvert > gstaudioconvert.c:705:gst_audio_convert_tr > ansform_caps:<audioconvert0> Caps transformed to 0x47c060 > 0:00:01.820000000 936 0x477720 DEBUG alsa > gstalsasink.c:307:gst_alsasink_getcaps:<al > sasink0> device not open, using template caps > Setting pipeline to PAUSED ... > 0:00:01.840000000 936 0x477720 LOG alsa > gstalsasink.c:678:gst_alsasink_open:<alsas > ink0> Opened device hw:0,0 > 0:00:01.840000000 936 0x477720 DEBUG wavparse > gstwavparse.c:2607:gst_wavparse_sink_activ > ate: going to pull mode > 0:00:01.840000000 940 0x4230f0 LOG wavparse > gstwavparse.c:2050:gst_wavparse_loop:<wavp > arse0> process data > 0:00:01.840000000 940 0x4230f0 INFO wavparse > gstwavparse.c:2054:gst_wavparse_loop:<wavp > arse0> GST_WAVPARSE_START > 0:00:02.950000000 940 0x4230f0 INFO wavparse > gstwavparse.c:2063:gst_wavparse_loop:<wavp > arse0> GST_WAVPARSE_HEADER > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1232:gst_wavparse_stream_hea > ders:<wavparse0> creating the caps > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1288:gst_wavparse_stream_hea > ders:<wavparse0> blockalign = 4 > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1289:gst_wavparse_stream_hea > ders:<wavparse0> width = 16 > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1290:gst_wavparse_stream_hea > ders:<wavparse0> depth = 16 > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1291:gst_wavparse_stream_hea > ders:<wavparse0> av_bps = 192000 > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1292:gst_wavparse_stream_hea > ders:<wavparse0> frequency = 48000 > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1293:gst_wavparse_stream_hea > ders:<wavparse0> channels = 2 > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1294:gst_wavparse_stream_hea > ders:<wavparse0> bytes_per_sample = 4 > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1300:gst_wavparse_stream_hea > ders:<wavparse0> bps = 192000 > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1302:gst_wavparse_stream_hea > ders:<wavparse0> caps = 0x47c080 > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1325:gst_wavparse_stream_hea > ders:<wavparse0> upstream size 982538 > 0:00:02.950000000 940 0x4230f0 INFO wavparse > gstwavparse.c:1343:gst_wavparse_stream_hea > ders:<wavparse0> Got TAG: data, offset 36 > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1350:gst_wavparse_stream_hea > ders:<wavparse0> Got 'data' TAG, size : 960000 > 0:00:02.950000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1375:gst_wavparse_stream_hea > ders:<wavparse0> datasize = 960000 > Pipeline is PREROLLING ... > 0:00:02.950000000 940 0x4230f0 INFO wavparse > gstwavparse.c:1343:gst_wavparse_stream_hea > ders:<wavparse0> Got TAG: ID3x, offset 960044 > 0:00:02.960000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1152:gst_waveparse_ignore_ch > unk:<wavparse0> Ignoring tag ID3x > 0:00:02.960000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1554:gst_wavparse_stream_hea > ders:<wavparse0> Finished parsing headers > 0:00:02.960000000 940 0x4230f0 INFO wavparse > gstwavparse.c:1126:gst_wavparse_calculate_ > duration:<wavparse0> Got datasize 960000 > 0:00:02.960000000 940 0x4230f0 INFO wavparse > gstwavparse.c:1130:gst_wavparse_calculate_ > duration:<wavparse0> Got duration (bps) 0:00:05.000000000 > 0:00:02.960000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:823:gst_wavparse_perform_see > k:<wavparse0> doing seek without event > 0:00:02.960000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:897:gst_wavparse_perform_see > k:<wavparse0> stopped streaming at 0 > 0:00:04.060000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:916:gst_wavparse_perform_see > k:<wavparse0> cur_type =2 > 0:00:04.060000000 940 0x4230f0 LOG wavparse > gstwavparse.c:924:gst_wavparse_perform_see > k:<wavparse0> offset=0 > 0:00:04.060000000 940 0x4230f0 LOG wavparse > gstwavparse.c:926:gst_wavparse_perform_see > k:<wavparse0> offset=0 > 0:00:04.060000000 940 0x4230f0 LOG wavparse > gstwavparse.c:928:gst_wavparse_perform_see > k:<wavparse0> offset=44 > 0:00:04.060000000 940 0x4230f0 LOG wavparse > gstwavparse.c:937:gst_wavparse_perform_see > k:<wavparse0> end_offset=960000 > 0:00:04.060000000 940 0x4230f0 LOG wavparse > gstwavparse.c:939:gst_wavparse_perform_see > k:<wavparse0> end_offset=960000 > 0:00:04.060000000 940 0x4230f0 LOG wavparse > gstwavparse.c:941:gst_wavparse_perform_see > k:<wavparse0> end_offset=960044 > 0:00:04.060000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:960:gst_wavparse_perform_see > k:<wavparse0> seek: rate 1.000000, offset 44, end 960044, segment > 0:00:00.000000000 -- 0:00:05.000000000 > 0:00:04.070000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:995:gst_wavparse_perform_see > k:<wavparse0> Creating newsegment from 0 to 5000000000 > 0:00:04.070000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1600:gst_wavparse_stream_hea > ders:<wavparse0> max buffer size 7680 > 0:00:04.070000000 940 0x4230f0 INFO wavparse > gstwavparse.c:2069:gst_wavparse_loop:<wavp > arse0> GST_WAVPARSE_DATA > > 0:00:04.070000000 940 0x4230f0 LOG wavparse > gstwavparse.c:1840:gst_wavparse_stream_dat > a:<wavparse0> offset: 44 , end: 960044 , dataleft: 960000 > > 0:00:04.070000000 940 0x4230f0 LOG wavparse > gstwavparse.c:1859:gst_wavparse_stream_dat > a:<wavparse0> Fetching 7680 bytes of data from the sinkpad > > 0:00:04.070000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1773:gst_wavparse_add_src_pa > d:<wavparse0> adding src pad > 0:00:04.160000000 940 0x4230f0 LOG wavparse > gstwavparse.c:1783:gst_wavparse_add_src_pa > d: typefind caps = 0x499ee0, P=86 > 0:00:04.160000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1793:gst_wavparse_add_src_pa > d:<wavparse0> found caps 0x499ee0 for stream marked as raw PCM audio, > but ignoring for now > 0:00:04.160000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:247:gst_wavparse_create_sour > cepad:<wavparse0> srcpad created > 0:00:04.160000000 940 0x4230f0 WARN alsa > gstalsa.c:124:gst_alsa_detect_formats:<als > asink0> skipping non-int format > 0:00:04.160000000 940 0x4230f0 LOG alsa > gstalsa.c:30:gst_alsa_detect_rates:<alsasi > nk0> probing sample rates ... > 0:00:04.160000000 940 0x4230f0 DEBUG alsa > gstalsa.c:49:gst_alsa_detect_rates:<alsasi > nk0> Min. rate = 48000 (48000) > 0:00:04.160000000 940 0x4230f0 DEBUG alsa > gstalsa.c:50:gst_alsa_detect_rates:<alsasi > nk0> Max. rate = 48000 (48000) > 0:00:04.160000000 940 0x4230f0 LOG alsa > gstalsa.c:265:gst_alsa_detect_channels:<al > sasink0> probing channels ... > 0:00:05.270000000 940 0x4230f0 DEBUG alsa > gstalsa.c:309:gst_alsa_detect_channels:<al > sasink0> Min. channels = 2 (2) > 0:00:05.270000000 940 0x4230f0 DEBUG alsa > gstalsa.c:310:gst_alsa_detect_channels:<al > sasink0> Max. channels = 2 (2) > 0:00:05.270000000 940 0x4230f0 DEBUG alsa > gstalsa.c:388:gst_alsa_open_iec958_pcm:<al > sasink0> Generated device string "iec958:{AES0 0x02 AES1 0x82 AES2 > 0x00 AES3 0x02}" > conf.c:snd_config_update_r:3661, configs=/usr/share/alsa/alsa.conf > conf.c:snd_config_update_r:3661, configs=/usr/share/alsa/alsa.conf > 0:00:05.280000000 940 0x4230f0 WARN alsa > conf.c:4692:snd_config_expand: alsalib err > or: Unknown parameters {AES0 0x02 AES1 0x82 AES2 0x00 AES3 0x02} > 0:00:05.280000000 940 0x4230f0 WARN alsa > pcm.c:2217:snd_pcm_open_noupdate: alsalib > error: Unknown PCM iec958:{AES0 0x02 AES1 0x82 AES2 0x00 AES3 0x02} > 0:00:05.280000000 940 0x4230f0 DEBUG alsa > gstalsa.c:394:gst_alsa_open_iec958_pcm:<al > sasink0> failed opening IEC958 device: Invalid argument > 0:00:05.280000000 940 0x4230f0 INFO alsa > gstalsasink.c:327:gst_alsasink_getcaps:<al > sasink0> returning caps 0x49a160 > 0:00:05.280000000 940 0x4230f0 LOG alsa > gstalsasink.c:312:gst_alsasink_getcaps:<al > sasink0> Returning cached caps > 0:00:05.280000000 940 0x4230f0 LOG alsa > gstalsasink.c:312:gst_alsasink_getcaps:<al > sasink0> Returning cached caps > 0:00:05.280000000 940 0x4230f0 LOG alsa > gstalsasink.c:312:gst_alsasink_getcaps:<al > sasink0> Returning cached caps > 0:00:05.280000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1814:gst_wavparse_add_src_pa > d:<wavparse0> Send start segment event on newpad > 0:00:05.280000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:1981:gst_wavparse_stream_dat > a:<wavparse0> marking DISCONT > 0:00:05.280000000 940 0x4230f0 LOG wavparse > gstwavparse.c:1995:gst_wavparse_stream_dat > a:<wavparse0> Got buffer. timestamp:0:00:00.000000000 , > duration:0:00:00.040000000, size:7680 > 0:00:05.280000000 940 0x4230f0 INFO wavparse > gstwavparse.c:2039:gst_wavparse_stream_dat > a:<wavparse0> Error pushing on srcpad wavparse0:src, reason > not-linked, is linked? = 0 > > 0:00:05.280000000 940 0x4230f0 DEBUG wavparse > gstwavparse.c:2088:gst_wavparse_loop:<wavp > arse0> pausing task, reason not-linked > 0:00:05.280000000 940 0x4230f0 WARN wavparse > gstwavparse.c:2122:gst_wavparse_loop:<wavp > arse0> error: Internal data flow error. > 0:00:05.280000000 940 0x4230f0 WARN wavparse > gstwavparse.c:2122:gst_wavparse_loop:<wavp > arse0> error: streaming task paused, reason not-linked (-1) > ERROR: from element /GstPipeline:pipeline0/GstWavParse:wavparse0: > Internal data flow error. > Additional debug info: > gstwavparse.c(2122): gst_wavparse_loop (): > /GstPipeline:pipeline0/GstWavParse:wavparse0: > streaming task paused, reason not-linked (-1) > ERROR: pipeline doesn't want to preroll. > Setting pipeline to NULL ... > /GstPipeline:pipeline0/GstWavParse:wavparse0.GstPad:src: caps = NULL > Freeing pipeline ... > 0:00:06.400000000 936 0x477720 DEBUG wavparse > gstwavparse.c:190:gst_wavparse_dispose:<wa > vparse0> WAV: Dispose > # > ============================================================================