1 .TH ALSALOOP 1 "5 Aug 2010"
3 alsaloop \- command\-line PCM loopback
5 \fBalsaloop\fP [\fI\-option\fP] [\fIcmd\fP]
8 \fBalsaloop\fP allows create a PCM loopback between a PCM capture device
9 and a PCM playback device.
11 \fBalsaloop\fP supports multiple soundcards, adaptive clock synchronization,
12 adaptive rate resampling using the samplerate library (if available in
13 the system). Also, mixer controls can be redirected from one card to
14 another (for example Master and PCM).
19 \fI\-h\fP | \fI\-\-help\fP
21 Prints the help information.
24 \fI\-g <file>\fP | \fI\-\-config=<file>\fP
26 Use given configuration file. The syntax of this file is simple: one line
27 contains the command line options for one job. The '#' means comment and
28 rest of line is ignored. Example:
30 # First line \- comment, second line \- first job
31 \-C hw:1,0 \-P hw:0,0 \-t 50000 \-T 1
32 # Third line \- comment, fourth line \- second job
33 \-C hw:1,1 \-P hw:0,1 \-t 40000 \-T 2
36 \fI\-d\fP | \fI\-\-daemonize\fP
38 Daemonize the main process and use syslog for messages.
41 \fI\-P <device>\fP | \fI\-\-pdevice=<device>\fP
43 Use given playback device.
46 \fI\-C <device>\fP | \fI\-\-cdevice=<device>\fP
48 Use given capture device.
51 \fI\-X <device>\fP | \fI\-\-pctl=<device>\fP
53 Use given CTL device for playback.
56 \fI\-Y <device>\fP | \fI\-\-cctl=<device>\fP
58 Use given CTL device for capture.
61 \fI\-l <latency>\fP | \fI\-\-latency=<frames>\fP
63 Requested latency in frames.
66 \fI\-t <usec>\fP | \fI\-\-tlatency=<usec>\fP
68 Requested latency in usec (1/1000000sec).
71 \fI\-f <format>\fP | \fI\-\-format=<format>\fP
73 Format specification (usually S16_LE S32_LE). Use \-h to list all formats.
74 Default format is S16_LE.
77 \fI\-c <channels>\fP | \fI\-\-channels=<channels>\fP
79 Channel count specification. Default value is 2.
82 \fI\-c <rate>\fP | \fI\-\-rate=<rate>\fP
84 Rate specification. Default value is 48000 (Hz).
87 \fI\-n\fP | \fI\-\-resample\fP
89 Allow rate resampling using alsa\-lib.
92 \fI\-A <converter>\fP | \fI\-\-samplerate=<converter>\fP
94 Use libsamplerate and choose a converter:
96 0 or sincbest \- best quality
97 1 or sincmedium \- medium quality
98 2 or sincfastest \- lowest quality
99 3 or zerohold \- hold zero samples
100 4 or linear \- worst quality - linear resampling
101 5 or auto \- choose best method
104 \fI\-B <size>\fP | \fI\-\-buffer=<size>\fP
106 Buffer size in frames.
109 \fI\-E <size>\fP | \fI\-\-period=<size>\fP
111 Period size in frames.
114 \fI\-s <secs>\fP | \fI\-\-seconds=<secs>\fP
116 Duration of loop in seconds.
119 \fI\-b\fP | \fI\-\-nblock\fP
121 Non\-block mode (very early process wakeup). Eats more CPU.
124 \fI\-S <mode>\fP | \fI\-\-sync=<mode>\fP
126 Sync mode specification for capture to playback stream:
127 0 or none \- do not touch the stream
128 1 or simple \- add or remove samples to keep
129 both streams synchronized
130 2 or captshift \- use driver for the capture device
131 (if supported) to compensate
133 3 or playshift \- use driver for the playback device
134 (if supported) to compensate
136 4 or samplerate \- use samplerate library to do rate resampling
137 5 or auto \- automatically selects the best method
138 in this order: captshift, playshift,
142 \fI\-T <num>\fP | \fI\-\-thread=<num>\fP
144 Thread number (\-1 means create a unique thread). All jobs with same
145 thread numbers are run within one thread.
148 \fI\-m <mixid>\fP | \fI\-\-mixer=<midid>\fP
150 Redirect mixer control from the playback card to the capture card. Format of
151 \fImixid\fP is SRCID(PLAYBACK)[@DSTID(PLAYBACK)]:
153 "name='Master Playback Switch'@name='Another Switch'"
154 "name='PCM Playback Volume'"
158 name \- control ID name
159 index \- control ID index
160 device \- control ID device
161 subdevice \- control ID subdevice
162 iface \- control ID interface
163 numid \- control ID numid
166 \fI\-O <ossmixid>\fP | \fI\-\-ossmixer=<midid>\fP
168 Redirect mixer control from the OSS Mixer emulation layer (capture card)
169 to the ALSA layer (capture card). Format of \fIossmixid\fP is
170 ALSAID[,INDEX]@OSSID:
175 Known OSS attributes:
177 VOLUME, BASS, TREBLE, SYNTH, PCM, SPEAKER, LINE, MIC, CD, IMIX, ALTPCM,
178 RECLEV, IGAIN, OGAIN, LINE1, LINE2, LINE3, DIGITAL1, DIGITAL2, DIGITAL3,
179 PHONEIN, PHONEOUT, VIDEO, RADIO, MONITOR
182 \fI\-v\fP | \fI\-\-verbose\fP
184 Verbose mode. Use multiple times to increase verbosity.
188 \fI\-U\fP | \fI\-\-xrun\fP
190 Verbose xrun profiling.
193 \fI\-W <timeout>\fP | \fI\-\-wake=<timeout>\fP
195 Set process wake timeout.
200 \fBalsaloop \-C hw:0,0 \-P hw:1,0 \-t 50000\fR
205 \fBalsaloop\fP is by Jaroslav Kysela <perex@perex.cz>.
206 This document is by Jaroslav Kysela <perex@perex.cz>.