docs/51203: Improvements to burncd section of Handbook (12.5.3)

murray at FreeBSD.org murray at FreeBSD.org
Mon Apr 21 02:00:24 UTC 2003


>Number:         51203
>Category:       docs
>Synopsis:       Improvements to burncd section of Handbook (12.5.3)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-doc
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          doc-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Apr 20 19:00:22 PDT 2003
>Closed-Date:
>Last-Modified:
>Originator:     
>Release:        FreeBSD 5.0-RC i386
>Organization:
FreeBSD Mall, Inc.
>Environment:
System: FreeBSD builder.freebsdmall.com 5.0-RC FreeBSD 5.0-RC #21: Sat Dec 7 19:41:45 PST 2002 murray at builder.freebsdmall.com:/usr/obj/usr/src/sys/BUILDER i386

>Description:

Additions to this section ..

>How-To-Repeat:

>Fix:

This should be proofread and sgmlified.  This was submitted to me by
Benoit Mussche <benoit.mussche at pandora.be> so he should be credited
when it is committed.  I don't have the time now so maybe someone else
can get to this before me.

	- Murray

----
12.5.3 burncd

If you have an ATAPI CD burner, you can use the burncd command to burn
an ISO image, various data files, or audio tracks onto a CD. burncd is
part of the base system, installed as /usr/sbin/burncd. Usage is very
simple, as it has few options:

    # burncd -f cddevice -s 20 data imagefile.iso fixate

will burn a copy of imagefile.iso on cddevice at speed 20. The default
device is /dev/acd0c. See burncd(8) for options to eject the CD after
burning, write audio data without gaps between tracks, etc.

Follows a series of example command lines and tricks.

To create a data CD from files, just cook up an ISO file from their
directory, such as /tmp/kitchen, and burn it:

    # rm /tmp/cd.iso ; mkisofs -d -N -D -R -L -l -J -T -o /tmp/cd.iso /tmp/kitchen && burncd -f /dev/acd0c -s 20 data /tmp/cd.iso fixate
    
Note: mkisofs "i won't read that man page" parameters-stuffed command
line courtesy of http://www.mostgraveconcern.com/freebsd. Don't forget
not to exceed your maximum CD size indicated in Megabytes. Use "du -h"
in the temporary directory for that purpose.

If you would like to let the full directory appear upfront on the CD,
move that directory into wherever you store your files to be burnt
from.

To make "backups" of your audio CD's for your *cough* personal use,
you need to grab the audio tracks first. Install dagrab and sox from
ports and create a script going on like this:

    echo "removing old junk"
    rm /tmp/juke/*
    dagrab -d /dev/acd0c -a -f /tmp/juke/track%02d && cd /tmp/juke/
    echo "starting convertion into raws"
    sox -V -t wav -r 44100 -w -s -c 2 track01 track01.raw
    sox -V -t wav -r 44100 -w -s -c 2 track02 track02.raw
    sox -V -t wav -r 44100 -w -s -c 2 track03 track03.raw
    ...
    sox -V -t wav -r 44100 -w -s -c 2 trackXX trackXX.raw
    echo "insert new disc in drive and burn"

Feel free to replace the repeated lines with an automatic
incrementation in some neat code. Using sox to convert the ripped
audio tracks from .wav to .raw format is necessary to avoid an awful
scratch at the beginning of each track. The .raw files are .wav files
stripped from their data header, which produce the forementionned
scratch when burned as audio tracks.

To burn audio tracks ripped into /tmp/juke at writing speed 20, hit:

    # burncd -f /dev/acd0c -s 20 audio /tmp/juke/*.raw fixate

To create audio CD's from midi files, first install timidity++ from
ports then install manually the GUS patches set by Eric A. Welsh,
available at
http://www.stardate.bc.ca/eawpatches/html/default.htm. After you set
up timidity++ to use the patches correctly, create wav's from the midi
files using this command line:

    timidity -Ow -s 44100 -o /tmp/juke/01.wav 01.mid

Repeated as many times as necessary. Then convert the wav's into raw's
as previously described and burn the cd the usual way.

To burn mp3's as audio tracks, install mpg321 from ports and convert
them to the raw format using this command line:

    mpg321 --stdout track01.mp3 > track01.raw

You may also use xmms with the disk writer plugin, but xmms will
produce wav files, which you need to convert to raw before you burn
them.  However, xmms is the only player that can convert .exo module
files, and various other special audio formats working under its
plugins, to wav.

Remember not to burn anything else than raw files as audio tracks, if
necessary converted to 44 kHz stereo from whatever data form they come
from. For example, if you convert a 22 kHz mono mp3 to wav, roll a wav
editor such as mhwaveedit, split the mono file into fake stereo and
convert it to 44 kHz before you convert it to raw. If you don't, you
will experience listening to painful screwed up CD's that will end up
into the trashbin.


>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-doc mailing list