xref: /freebsd/usr.sbin/cdcontrol/cdcontrol.1 (revision 77a0943ded95b9e6438f7db70c4a28e4d93946d4)
1.\" $FreeBSD$
2.\"
3.Dd July 3, 1995
4.Dt CDCONTROL 1
5.Os FreeBSD
6.Sh NAME
7.Nm cdcontrol
8.Nd compact disc control utility
9.Sh SYNOPSIS
10.Nm
11.Op Fl sv
12.Op Fl f Ar device
13.Op Ar command ...
14.Sh DESCRIPTION
15.Nm Cdcontrol
16is a program to control audio features of a CD drive.
17The device is a name such
18as
19.Pa cd0
20or
21.Pa mcd0 .
22.Pp
23If the device not specified, the environment variables
24.Ev MUSIC_CD ,
25.Ev CD_DRIVE ,
26.Ev DISC
27and
28.Ev CDPLAY
29will be used (in this order) to find the cd device.
30.Pp
31If no command is given, then
32.Nm
33enters an interactive mode, reading commands from the standard input.
34.Pp
35The following options are available:
36.Bl -tag -width indent
37.It Fl s
38Silent mode - do not print table headers and human readable comments.
39.It Fl v
40Verbose mode - print as much information as possible.
41.It Fl f Ar device
42Specify a device, such as
43.Pa /dev/cd0c
44or
45.Pa mcd0 .
46Both absolute path and relative to
47.Pa /dev
48filename are possible.
49Suffix `c' is added to the device name if needed.
50.El
51.Pp
52The available commands are listed below.  Only as many
53characters as are required to uniquely identify a command
54need be specified.
55Word
56.Em play
57can be omitted.
58.Bl -tag -width Cm
59
60.It Cm play Ar first_track Op Ar last_track
61Play from track
62.Ar first_track
63to track
64.Ar last_track .
65The first track has number 1.
66Can be omitted in all cases.
67
68.It Cm play Ar start_m:start_s.start_f Op Ar end_m:end_s.end_f
69Play from the absolute address
70(MSF) defined by
71.Ar start_m
72in minutes,
73.Ar start_s ,
74in seconds and
75.Ar start_f
76(frame number) to the absolute address defined by
77.Ar end_m
78in minutes,
79.Ar end_s ,
80in seconds and
81.Ar end_f
82(frame number). Minutes are in the range 0-99.
83Seconds are in the range 0-59.
84Frame numbers are in the range 0-74.
85
86.It Cm play Op Ar #start_block Op length
87Play starting from the logical block
88.Ar start_block
89using
90.Ar length
91logical blocks.
92
93.It Cm pause
94Stop playing.
95Do not stop the disc.
96
97.It Cm resume
98Resume playing.
99Used after the
100.Em pause
101command.
102
103.It Cm stop
104Stop the disc.
105
106.It Cm eject
107Eject the disc.
108
109.It Cm close
110Inject the disc.
111
112.It Cm volume Ar left_channel Ar right_channel
113Set the volume of left channel to
114.Ar left_channel
115and the volume of right channel to
116.Ar right_channel .
117Allowed values are in the range 0-255.
118
119.It Cm volume Ar mute
120Turn the sound off.
121
122.It Cm volume Ar mono
123Set the mono mode.
124
125.It Cm volume Ar stereo
126Set the stereo mode.
127
128.It Cm volume Ar left
129Play the left subtrack on both left and right channels.
130
131.It Cm volume Ar right
132Play the right subtrack on both left and right channels.
133
134.It Cm info
135Print the table of contents.
136
137.It Cm status
138.Op Ar audio | media | volume
139
140Print the information about the disc:
141
142.Nm audio
143the current playing status and position,
144
145.Nm media
146the current media catalog status,
147
148.Nm volume
149the current values of the volume for left and right channels.
150
151.It Cm cdid
152Display the serial number of the cd using the method used by the
153cddb (http://www.cddb.org/) project.
154
155.It Cm help
156Print the list of available commands.
157
158.It Cm debug Ar on
159Enable the debugging mode of the CD device driver.
160
161.It Cm debug Ar off
162Disable the driver debugging mode.
163
164.It Cm reset
165Perform the hardware reset of the device.
166
167.It Cm set Ar msf
168Set minute-second-frame ioctl mode (default).
169
170.It Cm set Ar lba
171Set LBA ioctl mode.
172
173.It Cm quit
174Quit the program.
175
176.Sh FILES
177.Bl -tag -width /dev/mcd0c -compact
178.It Pa /dev/cd0c
179.It Pa /dev/mcd0c
180.It Pa /dev/acd0c
181.El
182.Sh AUTHORS
183.An Jean-Marc Zucconi ,
184.An Andrey A.\ Chernov ,
185.An Serge V.\ Vakulenko
186.Sh HISTORY
187The
188.Nm
189command appeared in
190.Fx 2.1 .
191