Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 15 Apr 2013 13:40:43 +0200
From:      Polytropon <freebsd@edvax.de>
To:        Beeblebrox <zaphod@berentweb.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: dvd recorder & audio cd problems
Message-ID:  <20130415134043.d7f0eb1f.freebsd@edvax.de>
In-Reply-To: <1366004782540-5803899.post@n5.nabble.com>
References:  <1366004782540-5803899.post@n5.nabble.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 14 Apr 2013 22:46:22 -0700 (PDT), Beeblebrox wrote:
> I have an audio CD I want to rip/copy but I have some problems:
> 
> % cdcontrol -f /dev/cd0 info
> Starting track = 1, ending track = 17, TOC size = 146 bytes
> track     start  duration   block  length   type
> -------------------------------------------------
>     1   0:02.00   4:02.31       0   18181  audio
>     2   4:04.31   5:08.45   18181   23145  audio   etc...
> 
> But when I do #-or-% cdcontrol -f /dev/cd0
> > play => starts playing (confirmed with 'status audio')
> But there is no sound. 'status volume' shows 255 for both channels.

This is a known problem of the transition from acd to cd driver
subsystem. I'm not sure in how far cdcontrol has made the
transition from ATAPI to SCSI/CAM successfully...

In order to copy an audio CD, try "CD Paranoia" (in ports:
audio/cdparanoia). If you want to really just copy a CD, try
something like this:

	% cdrdao read-cd --device 0,0,0 --driver generic-mmc-raw --eject --read-raw --datafile music.bin music.toc

	% cdrdao write --device 0,0,0 --driver generic-mmc-raw --speed 8 --eject music.toc

Note that this might be problematic on damaged CDs; in this
case, cdparanoia works better. Check "camcontrol devlist" for
the correct LUN of your device.

Regarding audio playback via cdcontrol: If I remember correctly,
this requires a seperate internal wiring (CD audio wire) from
the drive to the sound card. If your drive has a front connector
for headphones, check if it's actually playing. Considering this
wiring deprecated, audio data should be transmitted with the
PATA or SATA cable somehow...



> cam.ko is built-in to my custom kernel. From what I have read, shouldn't the
> DVD show up as /dev/acd0? In which case each song on the cd should be
> visible as /dev/acd0t__? Not happening though, since the dvd is registered
> as plain cd0 in /dev.

No. Those infrastructures have to be considered deprecated. The
track device files (acdXtYY) correspond to the ATAPI device driver
which also controls the acdX devices.

For example, on FreeBSD 8 you would have something like this in
your kernel configuration:

	# ATA and ATAPI devices
	device          ata
	device          atadisk         # ATA disk drives
	device          ataraid         # ATA RAID drives
	device          atapicd         # ATAPI CDROM drives
	device          atapifd         # ATAPI floppy drives
	device          atapist         # ATAPI tape drives
	options         ATA_STATIC_ID   # Static device numbering
	device          atapicam

This enables you both the acd (device atapicd) and the cd (device
atapicam) driver subsystems. Both the traditional ATAPI _and_ the
"SCSI over ATA" can be used this way.



> # camcontrol devlist =>
> <HL-DT-ST DVDRAM GSA-4165B DL05>   at scbus6 target 0 lun 0 (cd0,pass3)

Correct. This is the cd driver reporting. If you wanted to check
if you're able to access ATAPI devices, try the "atacontrol" command.

Examples (trimmed):

# atacontrol list
ATA channel 1:
    Master: acd0 <HL-DT-ST DVDRAM GSA-H42N/RL00> ATA/ATAPI revision 7
    Slave:  acd1 <HL-DT-STDVD-ROM GDR8163B/0L30> ATA/ATAPI revision 6

# camcontrol devlist
<HL-DT-ST DVDRAM GSA-H42N RL00>    at scbus0 target 0 lun 0 (pass0,cd0)
<HL-DT-ST DVD-ROM GDR8163B 0L30>   at scbus0 target 1 lun 0 (pass1,cd1)

You can see two drives in this example:

HL-DT-ST DVDRAM GSA-H42N RL00 = 0,0,0 = cd0 = acd0
HL-DT-ST DVD-ROM GDR8163B 0L30 = 0,1,0 = cd1 = acd1







-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130415134043.d7f0eb1f.freebsd>