[alsa-devel] snd_pcm_writei() -last value sustained

Alan Horstmann gineera at aspect135.co.uk
Wed Jul 16 14:01:08 CEST 2008

On Wednesday 16 July 2008 12:22, Alan Horstmann wrote:
> On Wednesday 16 July 2008 00:15, you wrote:
> > At Mon, 7 Jul 2008 14:53:35 +0100,


> > Well, I'd call it's a hardware "feature".  No other hardwares do like
> > that.
> >
> > As a workaround, we'll need to put zero'ed short samples before
> > actually stopping the stream.
> >
> > I wonder whether this also occurs to pause operation, too.  In the
> > case of pause, it's a tougher problem...
> Thanks for the response on this one.  I'm not sure how to test pause,
> unless xmms uses that for 'PAUSE' button action, when the same effect is
> seen.
> I did try setting various values for silence threshold and size, and when
> (as per the original test) writing 1 period of sine followed by a 2nd
> writei of experimental data, silence values could be found that would
> eliminate the 'sustain effect'.  However, when only the single period
> writei occured I could not find any effective values.
> Unsurprisingly, my other ice1712 card, ST Audio /Hoontech DSP2000 shows the
> same effect, so if it is a 'hardware feature' it presumably relates to the
> way the envy24 chip operates?
> How would I go about experimenting with zeroing the stream just before
> stopping?  Do you mean in _pro_trigger()?

Further info, I noticed in the envy24 datasheet, (rev 2.2 1.03.00) p 4-24 
states (near bottom of page)

'... when DMAs are stopped, the last latched value is retained.  This "DC" 
value ...'

so you were right about 'hardware feature'!


More information about the Alsa-devel mailing list