🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.dsp
Article #1810

Sun audio device buffering

#1810
From: Dan Frankowski
Date: Thu, 19 Nov 1992 19:16
25 lines
1492 bytes
Sorry to waste bandwidth, but I don't know the proper place to post
this question.

We are using the Sun audio device by opening it (sometimes blocking,
sometimes nonblocking-- it's irrelevant for the question).  We use a
read call:

count = read(record_fd, sound_bytes_ptr, sound_bytes_left);

where record_fd is the file descriptor of the sound device opened
for recording, sound_bytes_ptr is a pointer to the 0th element of
an array of chars, and sound_bytes_left is usually 800.

The very first call seems to return a small number of bytes (5 or 6).
After that, it always returns data in multiples of 1K.  I read the
audio man pages, looked in Sun documentation, tried fstat(), and I
just cannot seem to find why the device returns chunks in multiples of
1K.  It is important to us to be able to get smaller chunks.  Does
anyone know how to do this?

Thanks for your time.

Dan
--
Dan Frankowski                dfrankow@cs.umn.edu
Technical Details
Message-ID: <dfrankow.722200575@peca>
Path: arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!uwm.edu!src.honeywell.com!The-Star.honeywell.com!umn.edu!peca!dfrankow

Show Full Headers
Complete Article Headers
Newsgroups: comp.dsp,comp.multimedia,comp.speech
Path: arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!uwm.edu!src.honeywell.com!The-Star.honeywell.com!umn.edu!peca!dfrankow
From: dfrankow@peca.cs.umn.edu (Dan Frankowski)
Subject: Sun audio device buffering
Message-ID: <dfrankow.722200575@peca>
Summary: How do you read small chunks from the Sun audio device?
Sender: news@news2.cis.umn.edu (Usenet News Administration)
Nntp-Posting-Host: peca.cs.umn.edu
Organization: University of Minnesota
Date: Thu, 19 Nov 1992 19:16:15 GMT
Lines: 25