1.\" $FreeBSD$ 2.\" 3.Dd May 8, 2002 4.Dt CDCONTROL 1 5.Os 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 15The 16.Nm 17utility is a program to control audio features of a CD drive. 18The device is a name such 19as 20.Pa cd0 21or 22.Pa acd0 . 23.Pp 24If no 25.Ar command 26is given, then 27.Nm 28enters an interactive mode, reading commands from the standard input. 29.Pp 30The following options are available: 31.Bl -tag -width indent 32.It Fl s 33Silent mode. 34Do not print table headers and human readable comments. 35.It Fl v 36Verbose mode. 37Print as much information as possible. 38.It Fl f Ar device 39Specify a device, such as 40.Pa /dev/cd0 41or 42.Pa acd0 . 43Both absolute path and relative to 44.Pa /dev 45filename are possible. 46The 47.Fl f 48option overrides 49.Ev CDROM . 50If neither 51.Ev CDROM 52nor the 53.Fl f 54option is specified, 55.Nm 56tries opening first 57.Pa /dev/cdrom , 58then 59.Pa /dev/cd0 , 60and finally 61.Pa /dev/acd0 . 62.El 63.Pp 64The available commands are listed below. 65Only as many 66characters as are required to uniquely identify a command 67need be specified. 68The word 69.Ic play 70can be omitted or the characters 71.Ic + 72and 73.Ic - 74can be used in the 75place of 76.Ic next 77and 78.Ic prev . 79.Bl -tag -width indent 80.It Ic play Ar first_track Op Ar last_track 81Play from track 82.Ar first_track 83to track 84.Ar last_track . 85The first track has number 1. 86Can be omitted in all cases. 87.It Xo 88.Ic play 89.Ar start_m : Ns Ar start_s . Ns Ar start_f 90.Op Ar end_m : Ns Ar end_s . Ns Ar end_f 91.Xc 92Play from the absolute address 93(MSF) defined by 94.Ar start_m 95in minutes, 96.Ar start_s , 97in seconds and 98.Ar start_f 99(frame number) to the absolute address defined by 100.Ar end_m 101in minutes, 102.Ar end_s , 103in seconds and 104.Ar end_f 105(frame number). 106Minutes are in the range 0-99. 107Seconds are in the range 0-59. 108Frame numbers are in the range 0-74. 109.It Ic play Op # Ns Ar start_block Op Ar length 110Play starting from the logical block 111.Ar start_block 112using 113.Ar length 114logical blocks. 115.It Ic next Op Ar tracks 116Skip forward a number of tracks (default 1). 117.It Ic prev Op Ar tracks 118Skip backward a number of tracks (default 1). 119.It Ic pause 120Stop playing. 121Do not stop the disc. 122.It Ic resume 123Resume playing. 124Used after the 125.Ic pause 126command. 127.It Ic stop 128Stop the disc. 129.It Ic eject 130Eject the disc. 131.It Ic close 132Inject the disc. 133.It Ic volume Ar left_channel right_channel 134Set the volume of left channel to 135.Ar left_channel 136and the volume of right channel to 137.Ar right_channel . 138Allowed values are in the range 0-255. 139.It Ic volume Cm mute 140Turn the sound off. 141.It Ic volume Cm mono 142Set the mono mode. 143.It Ic volume Cm stereo 144Set the stereo mode. 145.It Ic volume Cm left 146Play the left subtrack on both left and right channels. 147.It Ic volume Cm right 148Play the right subtrack on both left and right channels. 149.It Ic info 150Print the table of contents. 151.It Ic status Op Cm audio | media | volume 152Print the information about the disc: 153.Pp 154.Bl -tag -width ".Cm volume" -compact 155.It Cm audio 156the current playing status and position 157.It Cm media 158the current media catalog status 159.It Cm volume 160the current values of the volume for left and right channels. 161.El 162.It Ic cdid 163Display the serial number of the CD using the method used by the 164.Tn CDDB 165project 166.Pq Pa http://www.cddb.org/ . 167.It Ic help 168Print the list of available commands. 169.It Ic debug Cm on 170Enable the debugging mode of the CD device driver. 171.It Ic debug Cm off 172Disable the driver debugging mode. 173.It Ic reset 174Perform the hardware reset of the device. 175.It Ic set Cm msf 176Set minute-second-frame ioctl mode (default). 177.It Ic set Cm lba 178Set LBA ioctl mode. 179.It Ic speed Ar s 180Set the highest speed that the drive should use for reading data. 181The units are multiples of a single speed CDROM (150 KB/s). 182Specify 183.Dq Li max 184to use the drive's fastest speed. 185.It Ic quit 186Quit the program. 187.El 188.Sh ENVIRONMENT 189The following environment variables affect the execution of 190.Nm : 191.Bl -tag -width ".Ev CD_DRIVE" 192.It Ev CDROM 193The CD device to use, if one is not specified with the 194.Fl f 195option. 196.It Ev CDPLAY , CD_DRIVE , DISC , MUSIC_CD 197These variables have been deprecated in favour of 198.Ev CDROM . 199.El 200.Sh FILES 201.Bl -tag -width ".Pa /dev/mcd0" -compact 202.It Pa /dev/cd0 203.It Pa /dev/mcd0 204.It Pa /dev/acd0 205.El 206.Sh HISTORY 207The 208.Nm 209command appeared in 210.Fx 2.1 . 211.Sh AUTHORS 212.An Jean-Marc Zucconi 213.An Andrey A. Chernov 214.An Serge V. Vakulenko 215