xref: /netbsd/usr.bin/mixerctl/mixerctl.1 (revision c4a72b64)
1.\" $NetBSD: mixerctl.1,v 1.15 2002/09/26 01:23:00 wiz Exp $
2.\"
3.\" Copyright (c) 1997 The NetBSD Foundation, Inc.
4.\" All rights reserved.
5.\"
6.\" Author: Lennart Augustsson
7.\"
8.\" Redistribution and use in source and binary forms, with or without
9.\" modification, are permitted provided that the following conditions
10.\" are met:
11.\" 1. Redistributions of source code must retain the above copyright
12.\"    notice, this list of conditions and the following disclaimer.
13.\" 2. Redistributions in binary form must reproduce the above copyright
14.\"    notice, this list of conditions and the following disclaimer in the
15.\"    documentation and/or other materials provided with the distribution.
16.\" 3. All advertising materials mentioning features or use of this software
17.\"    must display the following acknowledgement:
18.\"        This product includes software developed by the NetBSD
19.\"        Foundation, Inc. and its contributors.
20.\" 4. Neither the name of The NetBSD Foundation nor the names of its
21.\"    contributors may be used to endorse or promote products derived
22.\"    from this software without specific prior written permission.
23.\"
24.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
25.\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
26.\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
27.\" PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
28.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
29.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
30.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
31.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
32.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
33.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
34.\" POSSIBILITY OF SUCH DAMAGE.
35.\"
36.Dd January 27, 2002
37.Dt MIXERCTL 1
38.Os
39.Sh NAME
40.Nm mixerctl
41.Nd control audio mixing
42.Sh SYNOPSIS
43.Nm
44.Op Fl d Ar file
45.Op Fl n
46.Op Fl v
47.Fl a
48.Nm ""
49.Op Fl d Ar file
50.Op Fl n
51.Op Fl v
52.Ar name ...
53.Nm ""
54.Op Fl d Ar file
55.Op Fl n
56.Fl w
57.Ar name=value ...
58.Nm ""
59.Op Fl d Ar file
60.Op Fl n
61.Fl w
62.Ar name++ ...
63.Nm ""
64.Op Fl d Ar file
65.Op Fl n
66.Fl w
67.Ar name-- ...
68.Sh DESCRIPTION
69The
70.Nm
71command displays or sets various audio system mixing variables.
72If a list of variables is present on the command line, then
73.Nm
74prints the current value of those variables for the specified device.
75If the
76.Fl a
77flag is specified, all variables for the device are printed.
78If the
79.Fl w
80flag is specified
81.Nm
82attempts to set the specified variables to the given values.
83.Pp
84The
85.Fl d
86flag can be used to give an alternative mixer device, the default is
87.Pa /dev/mixer0 .
88.Pp
89The
90.Fl n
91flag suppresses printing of the variable name.
92.Pp
93The
94.Fl v
95flag shows the possible values of enumeration and set valued
96variables.
97Enumerated values are shown in [] and set values are shown in {}.
98.Pp
99The exact set of controls that can be manipulated depends on
100the mixer.
101The general format (in both getting and setting a value) is
102.br
103.Va "class.name" = value
104.br
105The
106.Va class
107can have values like
108.Li inputs
109or
110.Li outputs
111indicating that the control affects the input resp. output to the
112mixer.
113The
114.Va name
115indicates what part of the mixer the control affects.
116Continuous mixer values, e.g., volume, have numeric values
117in the range 0-255.
118If value can be set for each channel independently
119the values are printed separated by commas.
120Discrete mixer values, e.g., the recording source, have symbolic names.
121Depending on the mixer it may either be an enumeration or a set.
122.Pp
123The suffixes ++ and -- can be used to step through the values of a
124mixer control.
125For numeric controls these operators may increase (resp. decrease)
126the value by an amount (the delta) suitable to make
127the control assume the next possible value.
128.Sh ENVIRONMENT
129.Bl -tag -width MIXERDEVICE
130.It Pa MIXERDEVICE
131the mixer device to use.
132.El
133.Sh FILES
134.Bl -tag -width /dev/mixer0
135.It Pa /dev/mixer0
136mixer audio device
137.El
138.Sh EXAMPLES
139The command
140.Dl "mixerctl -a -v"
141can produce
142.Bd -literal
143inputs.mic=0,0 volume
144inputs.mic.mute=off  [ off on ]
145inputs.cd=220,220 volume
146inputs.cd.mute=off  [ off on ]
147inputs.dac=220,220 volume
148inputs.dac.mute=off  [ off on ]
149record.record=220,220 volume
150record.record.source=mic  [ mic cd dac ]
151monitor.monitor=0 volume
152.Ed
153.Sh SEE ALSO
154.Xr audioctl 1 ,
155.Xr audio 4 ,
156.Xr sysctl 8
157.Sh HISTORY
158The
159.Nm
160command first appeared in
161.Nx 1.3 .
162.Sh COMPATIBILITY
163The old
164.Fl f
165flag is still supported.
166This support will be removed eventually.
167