[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Trasients when playing silence with Matlab



Enrique:

I assume that you are talking about playing the _silence_
signal as a separate event, not as part of a larger stream.
The problem then has to do with turn-on transients in the 
sound card. This is likely related to the fact that sound 
cards typically run from a 0-12V supply.  The card has a
"zero" voltage at the middle of this range.  An output 
capacitor blocks the DC value and only allows the AC 
portions of the signal to pass.  But when the outputs
are initially activated, this capacitor passes a transient
until it is charged to the DC value.

In addition to the advice Mathieu has provided, one 
solution would be to have the sound card output *something* 
all the time.  I'm not a Matlab user so I can't advise on
the methods used there, but typically this involves a large
circular buffer (or chain of buffers) that the software 
updates in the background.  The buffer would be filled with 
zeroes (silence) normally, and sound data would be created 
as needed.  (Of course, you still have to control the 
envelope of the sound to prevent onset and offset 
transients.)

Best regards,

Bob Masta

-------------------------------------------
On 7 Feb 2008 at 17:00, Lopez-Poveda, Enrique A. wrote:

> Dear friends,
> 
> Here is a technical question on a problem that is driving us crazy.
> 
> We want to play sounds from Matlab through an RME 
> Fireface 400 sound card. The problem is that when 
> we play a "silence" interval (array of zeros) we 
> can hear (and even record) a clear transient at 
> the onset of the _silence_ signal. We would very 
> much like to get rid of that onset transient. Any 
> cues as to how to get rid of it?
> 
> Thank you so much in advance.
> 
> - Enrique
> 
> Enrique A. Lopez-Poveda, Ph.D.
> Instituto de Neurociencias de Castilla y León
> Universidad de Salamanca
> Av. Alfonso X El Sabio S/N, 37007 Salamanca, Spain.
> Phone: (+34) 923 294 500 ext. 1957
> Fax: (+34) 923 294 750
> E-mail: ealopezpoveda@xxxxxxx
> http://web.usal.es/~ealopezpoveda/ 

-----------------------------------------------------Bob 
Masta
 
            D A Q A R T A
Data AcQuisition And Real-Time Analysis
           www.daqarta.com
Scope, Spectrum, Spectrogram, Signal Generator
    Science with your sound card!