#include <sent/stddefs.h>
#include <sent/adin.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <errno.h>
#include <sys/stropts.h>
#include <sys/audioio.h>
Include dependency graph for adin_mic_sol2.c:
Go to the source code of this file.
Defines | |
#define | DEFAULT_DEVICE "/dev/audio" |
Default device name, can be overridden by AUDIODEV environment variable. | |
Functions | |
boolean | adin_mic_standby (int sfreq, void *arg) |
boolean | adin_mic_start () |
boolean | adin_mic_stop () |
int | adin_mic_read (SP16 *buf, int sampnum) |
Read samples from the daemon. | |
Variables | |
static int | afd |
Audio file descriptor. | |
static struct audio_info | ainfo |
Audio format information. |
Tested on Sun Solaris 2.5.1 and 2.6. Also works on later versions. Please note that this will not work on Solaris x86, since machine byte order is fixed to big endian.
The microphone input device will be automatically selected by Julius on startup. Please note that the recoding volue will not be altered by Julius, and appropriate value should be set by another tool such as gaintool.
The default device name is "/dev/audio", which can be changed by setting environment variable AUDIODEV.
Definition in file adin_mic_sol2.c.
|
Device initialization: check device capability and open for recording.
Definition at line 76 of file adin_mic_sol2.c. |
|
Start recording.
Definition at line 148 of file adin_mic_sol2.c. |
|
Stop recording.
Definition at line 169 of file adin_mic_sol2.c. |
|
Read samples from the daemon. Try to read sampnum samples and returns actual number of recorded samples currently available. This function will block until at least some samples are obtained.
Definition at line 196 of file adin_mic_sol2.c. |