Hi list

I've asked help before about file plugin, and it does work fine.

But I need something more. The raw file from which I'm reading audio is:
Signed 16 bit Little Endian, 44100 hz, 2 channels.

I've configured asound.conf this way:

pcm.plugfile{
        type plug
        slave {
                pcm infile
        }
}

pcm.infile {
         type file
         slave {
                 pcm null
         }
         file /dev/null
         infile /home/carlos/sting.raw
        
}

The input file is "sting.raw" (without header).

with arecord:

$ arecord -D plugfile out.wav -f S16_LE -r 44100 -c 2
Recording WAVE 'out.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
..
then aplay:
$ aplay out.wav

The sound is correctly played...

But I need to read the audio from another application rather than
arecord. And that application cant receive the format parameter.

So, I've tried doing this:

pcm.plugfile{
        type plug
        slave {
                pcm infile
                format S16_LE
                channels 2
                rate 44100
        }
}

pcm.infile {
         type file
         slave {
                 pcm null
         }
         file /dev/null
         infile /home/carlos/sting.raw
        
}


Here the "format", "rate" and "channels" are set up, and these are the
same as the original audio file.  Then I suppose I would not have to
specify these parameters with arecord.
running arecord:

[EMAIL PROTECTED]:~$ arecord -D plugfile out.wav
Recording WAVE 'out.wav' : Unsigned 8 bit, Rate 8000 Hz, Mono

it says Unsigned 8 bit, rate 8000 and Mono. And obviously this is wrong.

When I play with aplay no sound is played.

If I record again using "format", "rate" and "channels", the audio is
correctly recorded and played.

Any idea?...

thanks a lot




-- 
--------------------------------------
Universidad de Talca
Facultad de Ingeniería
Ingeniería Civil en Computación
--------------------------------------
Movil   +56 9 92624541
Skype  dspcarlos

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Alsa-user mailing list
Alsa-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/alsa-user

Reply via email to