> Date: Sun, 16 Feb 2014 14:56:08 -0800 (PST)
> From: Bill Unruh <un...@physics.ubc.ca>
> To: Samuele Carcagno <sam.carca...@gmail.com>
> Cc: alsa-user@lists.sourceforge.net
>
> On Sun, 16 Feb 2014, Samuele Carcagno wrote:
>
> > On Sunday 16 Feb 2014 20:47:44 you wrote:
> >> I have never seen that in any of the files I have played. That hints that 
> >> that
> >> is your input stream, rather than some problem with the soundcard itself,
> >> although I have also never used your sound card.
> >>
> >> So to be clear, you recorded onto a .wav file that sound. That .wav file 
> >> did
> >> not have those transients. You then played that file with aplay, and 
> >> recorded
> >> the output, starting the input before the file started playing and ending
> >> after it stopped.
> >
> > yes, that's correct. Because aplay does play the wav file well after it is 
> > "primed"
> > by playing some sounds with PyAudio, I wonder what PyAudio is doing and 
> > whether
> > I could instruct aplay to do the same through some command-line option.
> >
> > Just for completeness I should add that I observed this behaviour with the 
> > soundcard
> > plugged on different computers, as well as with the Debian testing branch 
> > and the current
> > Ubuntu development branch. I removed pulseaudio before running any of these 
> > tests as it has other
> > problems for me:
> >
> > http://lists.freedesktop.org/archives/pulseaudio-discuss/2012-October/014756.html
> >
> > Probably I can circumvent the onset/offset transient issue with a function 
> > that automatically
> > plays some sounds with pulseaudio each time my pyqt4 program starts. I will 
> > also have to check
> > that the soundcard plays sounds with 24-bit depth.
>
> It definitely sounds like a problem with your soundcard. 
> What happens if you put in say 1 sec of silence before the sound starts
> playing. 
> Mind you that trailing DC really looks suspicious, as if your file has a DC
> component, rather than the soundcard, but is belied by the fact that if you
> play it later, it is fine. The DC looks like it is dying away at the
> beginning, but then it sure should not be there at the end.

I agree there's something very odd about the DC segments before
and after the tone burst.  I think I can just barely see the
10ms fade-in/out.  It's a little more apparent when zoomed in.
The DC segments look like maybe switching transients while the
card is being initialized.  Perhaps playing a short piece of
silence via PyAudio before playing your real content via AlsaAudio
would be the most practical solution for that situation.

One other thing I remembered about PyAudio with my program is I
see a lot of whining about 'Unable to find definition ...',
'No such file or directory', 'Unknown PCM rear', 'Failed to create
secure directory: Permission denied', and so forth with PyAudio
during program initialization.  With AlsaAudio, there is no such
complaining.

HTH

Robert

------------------------------------------------------------------------------
Android apps run on BlackBerry 10
Introducing the new BlackBerry 10.2.1 Runtime for Android apps.
Now with support for Jelly Bean, Bluetooth, Mapview and more.
Get your Android app in front of a whole new audience.  Start now.
http://pubads.g.doubleclick.net/gampad/clk?id=124407151&iu=/4140/ostg.clktrk
_______________________________________________
Alsa-user mailing list
Alsa-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/alsa-user

Reply via email to