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