| Store | Cart

ossaudiodev full duplex

From: Greg Ewing <g...@cosc.canterbury.ac.nz>
Thu, 31 Mar 2005 16:19:41 +1200
rjm at si.rr.com wrote:
> fh= ossaudiodev.open("/dev/dsp", "rw")> fh.setparameters(ossaudiodev.AFMT_S16_LE, number_of_channels,> sample_rate)> fh.writeall(frames_out)> frames_in= fh.read(number_of_samples * sample_width)> fh.close()

One problem with this is that you can't use a single file
object for independent reading and writing at the same
time. C stdio implementations tend to get confused if
you try to do that.

You may have other problems as well, but you'll at least
need to open two separate file objects.

Greg Ewing, Computer Science Dept,
University of Canterbury,	
Christchurch, New Zealand

Recent Messages in this Thread
r...@si.rr.com Mar 26, 2005 03:01 pm
Marc BlackJack Rintsch Mar 27, 2005 12:19 am
r...@si.rr.com Mar 27, 2005 02:48 am
Greg Ewing Mar 31, 2005 04:19 am
Messages in this thread