Hello,

I am trying to record sound from a microphone using 'aurecord' from
the audio package. I have been successful using Octave 3.2 (compiled
by myself) on Ubuntu 8.10 (64 bits) with audio-1.1.4. However, on
Fedora 11 (64 bits), using plain fedora packages (octave 3.0.5 and
octave-forge from 20080831) I've been unable to get it to work.

* Using gnome-sound-recorder, I'm able to record and reproduce sound just fine.

* Fedora uses pulseaudio, which means I have no /dev/dsp device.
Executing 'aurecord' segfaults:

    octave:1> aurecord(1,48000,1)
    error: aurecord: can not open device
    panic: Segmentation fault -- stopping myself...
    attempting to save variables to `octave-core'...
    save to `octave-core' complete
    Segmentation fault
    $

* From what I've been able to gather, pulseaudio offers OSS
compatibility through a wrapper called 'padsp'. I am supposed to call
octave with this wrapper:

    $ padsp octave

and then octave sees a (virtual) /dev/dsp device controlled by
pulseaudio behind the scenes. Doing this, 'aurecord' doesn't segfault
anymore, but it doesn't work properly: it captures the correct number
of samples, but it only runs for half the specified time (that is,
aurecord(5,48000,1) returns 240000 samples but I clearly see it
running for 2.5 seconds). Also, he returned samples are not correct:
the captured signal is "choppy", with lots of consecutive zeros
surrounded by peaks (I can provide a plot screenshot if needed).

It looks as if this is a pulseaudio bug, not octave's, but there are
reports of other legacy tools working fine with padsp, so I wanted to
bring this up here first and ask if anybody has any pointers or
workarounds. Also, since it seems Pulseaudio is the future (at least
on Linux), it'd be great to have somebody knowledgeable update the
audio package. I'll try to do this myself, but pulseaudio
documentations seems somewhat sparse, so it may take a while.

-- 
Miguel Bazdresch

------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize  
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Octave-dev mailing list
Octave-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/octave-dev

Reply via email to