Technical data
audio(7I) Ioctl Requests SunOS 5.5
record.buffer_size field may be modified only on the /dev/audio device by processes that
have it opened for reading. The play.buffer_size field is currently not supported.
The audio data format is indicated by the sample_rate, channels, precision, and encoding
fields. The values of these fields correspond to the descriptions in the AUDIO FORMATS
section above. Refer to the audio device-specific manual pages for a list of supported
data format combinations.
The data format fields may be modified only on the /dev/audio device. The audio
hardware will often constrain the input and output data formats to be identical. If this is
the case, then the data format may not be changed if multiple processes have opened the
audio device.
If the parameter changes requested by an AUDIO_SETINFO ioctl cannot all be accommo-
dated, ioctl() will return with errno set to EINVAL and no changeswill be made to the
device state.
Streamio IOCTLS All of the streamio(7I) ioctl commands may be issued for the /dev/audio device. Because
the /dev/audioctl device has its own STREAMS queues, most of these commands neither
modify nor report the state of /dev/audio if issued for the /dev/audioctl device. The
I_SETSIG ioctl may be issued for /dev/audioctl to enable the notification of audio status
changes, as described above.
Audio IOCTLS The audio device additionallysupports the following ioctl commands:
AUDIO_DRAIN
The argument is ignored. This command suspends the callingprocess until the
output STREAMS queue is empty, or until a signal is delivered to the calling pro-
cess. It may not be issued for the /dev/audioctl device. An implicit
AUDIO_DRAIN is performed on the final close() of /dev/audio.
AUDIO_GETDEV
The argument is a pointer to an audio_device structure. This command may be
issued for either /dev/audio or /dev/audioctl. The returned value in the name
field will be a string that will identify the current /dev/audio hardware device,
the value in version will be a string indicatingthe current version of the
hardware, and config will be a device-specific string identifying the properties of
the audio stream associated with that file descriptor. Refer to the audio device-
specific manual pages to determine the actual strings returned by the device
driver.
AUDIO_GETINFO
The argument is a pointer to an audio_info structure. This command may be
issued for either /dev/audio or /dev/audioctl. The current state of the /dev/audio
device is returned in the structure.
7I-30 modified 21 Mar 1995










