2
oss_audioloop - Loopback audio driver.
5
The loopback audio driver makes it possible to create special purpose
6
virtual audio devices based on user land server processes.
8
Loopback devices are driven by a timer interrupt and no real audio
12
Audio loopback devices are like named pipes or pseudo terminals. They are
13
grouped in client and server device pairs. The server side device must be open
14
before the client side device can be opened.
16
Loopback devices are typically used to implement server based special purpose
17
audio devices. This kind of server can for example transfer the audio data
18
played by the client application to some remote system using some VoIP
19
protocol. However the server application doesn't need to be any dedicated
20
server. Practically any audio application can be used as the server.
23
The server side applications sets up the native sampling rate and sample format
24
(number of bits and channels). The server side device can be opened for input
25
(O_RDONLY) pr output (O_WRONLY). Opening for simultaneous input and output
26
(O_RDWR) is not permitted.
28
The server application will automatically be paused at the moment it tries to
29
read or write audio data for the first time. It will be kept in sleep until the
30
client side application starts writing or reading data. This sleep period may
31
last forever and in some cases the first write/read call never returns. For
32
this reason it's not recommended to use GUI based audio applications as the
33
server. Note that this wait will occur even in the non-blocking
34
(O_NONBLOCK) mode (this is intentional feature and not a bug).
37
The client side device is typically used by any ordinary audio application.
38
There is nothing special in loopback devices.
40
Since the loop is unidirectional the client side will be forced to be write
41
only if the server side device is open for recording and vice versa.
43
The loop will use the sample rate and sample format (number of bits and
44
channels) set by the server side application. If the client uses different
45
settings then OSS will perform the required sampling rate and format conversions
49
Audio loopback devices differ from "normal" audio devices because an
50
application is needed at the both ends of the loop. The loop device
51
will return a "Connection reset by peer" error (ECONNRESET) error. Applications
52
designed to be used as loopback based server applications can/should use this
53
error (returned by read or write) as an end-of-stream indication.
57
o audioloop_instances: Specifies how many loopback client/server audio device
59
Values: 1-16 Default: 1
62
o There is no mixer (volume control) related with loopback audio devices. This
63
may prevent poorly designed audio applications (that expect/require a mixer)
64
from working. There is no workaround available.
66
o The server side application will wait until the client side application
67
starts using it. This wait may last forever which in turn may cause
68
unrecoverable (network) problems with some applications.
70
o Loopback devices may return "Connection reset by peer" error when the
71
reote side of the loop disconnects the device. Some recording applications
72
may fail to save the recorded data properly because of this. Use some
73
other application (such as ossrecord) if this happens.
76
CONFIGFILEPATH/oss_audioloop.conf Device configuration file