Linux MP3 CD Burning mini-HOWTO

Greg Wierzchowski

greg.wierzchowski@usa.net

拞扟愮奊 - 擔杮岅東栿

       jeanne@mbox.kyoto-inet.or.jp
      

2001-05-29

Revision History                                                       
Revision 1.5            2001-11-19          Revised by: GW             
Fixed omission in Disc-At-Once burning section.                        
Revision 1.4            2001-11-17          Revised by: GW             
Added Disc-At-Once burning section.                                    
Revision 1.3            2001-09-02          Revised by: GW             
Added another example of decoding MP3 files with lame.                 
Revision 1.2            2001-07-12          Revised by: GW             
Minor layout changes; Added Translations subsection into Credits.      
Revision 1.1            2001-06-12          Revised by: GW             
Minor cleanup; Regexp fix for MP3 to WAV name conversion example.      
Revision 1.0            2001-05-29          Revised by: GW             
Initial Release.                                                       

MP3 僼傽僀儖偐傜僆乕僨傿僆 CD 傪嶌惉偡傞偨傔偺姰慡儗僔僺

劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

Table of Contents
1. 偼偠傔偵
   
    1.1. 挊嶌尃偲儔僀僙儞僗
   
2. 僩儔僢僋傪梡堄偡傞
3. CD 傪從偔
4. DAO(Disc-At-Once) CD 傪從偔
5. 幱帿
   
    5.1. 東栿暥彂
    5.2. 偦偺懠峷專傪捀偄偨曽乆
   
6. 擔杮岅栿偵偮偄偰

1. 偼偠傔偵

僀儞僞乕僱僢僩忋偱偼僒僂儞僪傪昗弨壔偡傞嬶懱揑側忣曬偑傎偲傫偳側偄偺偱
丄壒妝 CD 傪從偄偰偒偨巹偺宱尡傪傆傑偊偰丄偙偺 mini-HOWTO 傪嶌惉偟傑偟
偨丅巹偼偄偮傕偄傠偄傠側偲偙傠偐傜廤傔偰偒偨偝傑偞傑側嬋傪庢傝傑偲傔偰
壒妝 CD 傪從偒傑偡丅嬋偛偲偺儃儕儏乕儉儗儀儖偼偟偽偟偽幚偵偝傑偞傑偱偡
丅偙傟偑嵟弶偵傇偮偐偭偨栤戣偱偟偨丅偝傜偵偼丄僀儞僞乕僱僢僩忋偺懡偔偺
僼傽僀儖偼 CD 屳姺(16 價僢僩丄僗僥儗僆丄44.1 kHz)偱偼側偄偺偱丄曄姺偟偰
傗傜側偗傟偽側傝傑偣傫丅MP3 僼傽僀儖偐傜壒妝 CD 傪從偔僾儘僌儔儉偵偼偄
傠偄傠側傕偺偑偁傝傑偡偑丄傎偲傫偳偺傕偺偼摟夁揑偵曄姺偟傑偡丅偟偐偟丄
偦偺嵺偵儃儕儏乕儉傪昗弨壔偡傞偺傕堦弿偵峴偭偰偔傟傞扨堦僣乕儖偼尒偨偙
偲偑偁傝傑偣傫偺偱丄巹偼帺暘偺 CD 傪從偔儗僔僺傪彂偔偙偲偵偟傑偟偨丅

偙偺暥彂偱偼丄偝傑偞傑側応強偺僜乕僗丄壒幙傕偡傋偰偽傜偽傜偺忬懺偱擖庤
偟偨壒妝嬋偺僐儗僋僔儑儞偐傜 CD 傪從偙偆偲偟偰偄偰丄偟偐傕偱偒傞偩偗嵟
椙偺壒幙偺 CD 傪摼偨偄偲巚偭偰偄傞曽傪懳徾偵偟偰偄傑偡丅偙偺 mini-HOWTO
偼偍栶偵棫偰傞偐傕偟傟側偄曽朄偺偁傜傑偟傪弎傋偰偄傑偡丅

劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

1.1. 挊嶌尃偲儔僀僙儞僗

 This document is copyright 2001 by Greg Wierzchowski and is released
under the terms of the GNU Free Documentation License, which is hereby
incorporated by reference. Send feedback to greg.wierzchowski@usa.net
<mailto:greg.wierzchowski@usa.net>. 偙偺暥彂偼 Greg Wierzchowski 偑挊嶌
尃2001 傪曐帩偟丄GNU Free Documentation License 偺忦崁偺傕偲偵儕儕乕僗
偝傟偰偍傝丄偙傟偵傛偭偰堷梡偵戙偊傑偡丅僼傿乕僪僶僢僋偼丄
greg.wierzchowski@usa.net <mailto:greg.wierzchowski@usa.net> 埗偵憲偭偰
偔偩偝偄丅

擔杮岅栿拲丗乽GNU 僼儕乕暥彂棙梡嫋戻宊栺彂乿偺擔杮岅栿偼偙偪傜 <http://
www.debian.or.jp/~mhatta/fdl.ja.txt>偵偁傝傑偡丅

劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

2. 僩儔僢僋傪梡堄偡傞

    拲堄: 偡傋偰偺僐儅儞僪偼 bash 僔僃儖傪憐掕偟偰偄傑偡丅
   
 1. 偡傋偰偺 MP3 僼傽僀儖傪傂偲偮偺僨傿儗僋僩儕偵廤傔傑偡丅
   
 2. 僼傽僀儖柤偵嬻敀偑偁傞側傜丄嵟弶偵嬻敀傪傾儞僟乕儔僀儞偵曄峏偟偰傗
    傝傑偡
   
         for i in *.mp3; do mv "$i" `echo $i | tr ' ' '_'`; done 
   
 3. 師偵帵偡僐儅儞僪偱 WAV 僼傽僀儖偵曄姺偟傑偡丅
   
         for i in *.mp3; do mpg123 -w `basename $i .mp3`.wav $i; done 
   
     Mpg123 偼偳偺 Linux 僨傿僗僩儕價儏乕僔儑儞偵傕擖偭偰偄傞偼偢偱偡偑
    丄庤傕偲偵側偄側傜丄http://www.mpg123.de/ 偐傜擖庤偱偒傑偡丅
   
    拲堄丗偁傞庬偺 MP3 僼傽僀儖偼丄mpg123 弌椡偵傂偢傒偑偱傞偙偲偑偁傝
    傑偡偺偱拲堄偟偰偔偩偝偄丅嵟弶丄巹偼偦偺僼傽僀儖偑偍偐偟偄偺偩偲峫
    偊偰偄傑偟偨偑丄暿偺僾儗僀儎乕偱挷傋偨偲偙傠栤戣偼偁傝傑偣傫偱偟偨
    丅偦偙偱丄僨傿僗僋偵 WAV 僼傽僀儖傪彂偒弌偣傞暿偺 MP3 僾儗僀儎乕傪
    扵偟偰傒偨偲偙傠丄師偺傛偆側傕偺傪尒偮偗傑偟偨丅 http://
    www.mars.org/home/rob/proj/mpeg/ 偵偁傞 MAD mp3 僨僐乕僟乕偱偡丅師
    偺傛偆側僐儅儞僪傪巊偄傑偡丅
   
    for i in *.mp3; do madplay -o `basename $i .mp3`.wav $i; done 
   
     偝傜偵暿偺曽朄傕偁傝傑偡丅尒偨偲偙傠偄偔偮偐偺 mp3 僼傽僀儖偼 
    mpg123 偲 madplay 偺椉幰偱僨僐乕僪僩儔僽儖傪婲偙偟傑偡丅lame 僄儞僐
    乕僟偵偼僨僐乕僪婡擻偑偁傝丄偦傟傜偺僼傽僀儖偱傕偆傑偔埖偊傞傛偆偱
    偡丅 (lame 偼http://www.mp3dev.org/mp3/ 偵偁傝傑偡)丅
   
         for i in *.mp3; do lame --decode $i `basename $i .mp3`.wav; done 
                                                                          
   
     拲堄丗`basename $i .mp3`.wav 偲偄偆僐儅儞僪偼丄 MP3 奼挘巕傪 WAV
    偱抲偒姺偊傑偡丅偝傑偞傑側幚峴曽朄偑偁傝傑偡偑丄偙偙偱偼堦椺傪帵偟
    偰偍偒傑偡丅 `echo "$1" | sed 's/\.mp3$/.wav/'`
   
 4.   "file *.wav" 傪幚峴偟丄16 價僢僩丄僗僥儗僆 44100 Hz 偲偼堎側傞僼
    傽僀儖偵懳偡傞弌椡傪僠僃僢僋偟傑偡丅 
   
 5. 堘偭偨摿惈傪帩偮僼傽僀儖偑偁傞側傜丄忋弎偟偨曽朄偱偦傟傜僼傽僀儖傪
    曄姺偟傑偡丅偨偲偊偽丄track01.wav 偲偄偆僼傽僀儖傪曄姺偟偰僒儞僾儖
    儗乕僩 44.1 kHz 偵側傞傛偆偵偡傞偵偼師偺傛偆偵偟傑偡丅
   
         sox track01.wav -r 44100 track01-new.wav resample      
   
    Sox 偼偲偰傕堦斒揑側傕偺偱丄偳偺傛偆側 Linux 僨傿僗僩儕價儏乕僔儑儞
    偵傕僨僼僅儖僩偱僀儞僗僩乕儖偝傟偰偄傞偱偟傚偆丅傑偨師偺偲偙傠偱傕
    擖庤偱偒傑偡丅http://www.spies.com/Sox/ 偟偐偟丄巹偺傛偆側偍婥寉儐
    乕僓偵偼僐儅儞僪僆僾僔儑儞偼偪傚偭偲埫崋偺傛偆偵巚偊傑偡丅sox 傪偆
    傑偔巊偆偵偼 http://www.spies.com/Sox/sox.tips.html 傪尒偰偔偩偝偄
    丅
   
 6. 壒検偺嬌抂側堘偄傪旔偗傞偵偼丄WAV 僼傽僀儖傪昗弨壔偟傑偡丅巹偼
    Chris Vaill (<cvaill@cs.columbia.edu>) 偺 normalize偲偄偆僾儘僌儔儉
    傪巊偭偰偄傑偡丅http://www.cs.columbia.edu/~cvaill/normalize/ 偱擖
    庤偱偒傑偡丅
   
    巹偼師偺傛偆側峔暥傪巊偭偰偄傑偡( -m 偼 mix 儌乕僪偱丄偡傋偰偺僼傽
    僀儖偼偱偒傞偩偗戝偒側壒偵側傞偼偢偱偡)
   
         normalize -m *.wav                                     
   
劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

3. CD 傪從偔

WAV 僼傽僀儖偐傜 CD 傪嶌惉偡傞僾儘僌儔儉偼偨偔偝傫偁傝傑偡丅巹偼丄僐儅
儞僪儔僀儞偱偼 cdrecord傪巊偄丄gui 偱偼 XCDROAST傪巊偭偰偄傑偡丅
cdrecord 偱偼丄偍巊偄偺 CD-writer 偑丄偳偺 SCSI 僨僶僀僗傪巊偆偐傪抦傜
側偗傟偽偄偗傑偣傫丅ATAPI 儔僀僞乕傪巊偭偰偄傞側傜丄SCSI 僄儈儏儗乕僔儑
儞(僇乕僱儖儌僕儏乕儖 ide-scsi) 傪巊偄傑偡丅偍巊偄偺 ATAPI cdwriter 偑
擇偮栚偺 IDE 僶僗偵儅僗僞乕偲偟偰愙懕偝傟偰偄傞偲壖掕偟傑偡丅偦偺応崌丄
/dev/hdc僨僶僀僗僼傽僀儖偵側傝傑偡丅偦傟傪 SCSI 僨僶僀僗偲偟偰埖偄偨偄
偲僇乕僱儖偵揱偊傞偵偼丄 /etc/lilo.conf 偵師偺傛偆側峴傪壛偊傑偡丅

     append=" hdc=ide-scsi"                                            

傑偨丄僇乕僱儖偑帺摦揑偵 ide-scsi 儌僕儏乕儖傪儘乕僪偟側偄側傜丄
rc.local (偁傞偄偼娐嫬愝掕僼傽僀儖)偵 insmod ide-scsi傪壛偊傑偡丅堦扷
CD-writer 傪 SCSI 僨僶僀僗偲偟偰擣幆偝偣傜傟偨側傜丄cdrecord 偵梌偊傞
"dev" 僷儔儊乕僞偑壗偐傪尒偮偗傞偨傔偵cdrecord --scanbus傪幚峴偟傑偡丅
巹偺僔僗僥儉偱偼丄師偵帵偡傛偆側傕偺傪弌椡偟傑偡丅

     scsibus1:                                                         
     1,0,0 100) 'IOMEGA ' 'ZIP 250 ' '51.G' Removable Disk             
     1,1,0 101) 'HP ' 'CD-Writer+ 7100 ' '3.01' Removable CD-ROM       

 偦偙偱丄 cdrecord偺僐儅儞僪偼僨僶僀僗傪掕媊偡傞偨傔偺 dev=1,1,0傪娷傓
偙偲偵側傝傑偡丅巹偺僔僗僥儉偱偺姰慡側僐儅儞僪傪帵偟傑偡丅

     cdrecord dev=1,1,0 -eject speed=2 -pad -audio *.wav               

    拲堄丗: -pad 堷悢偼昁梫偱偡丅側偤側傜 CD 忋偺僆乕僨傿僆僩儔僢僋偼偡
    傋偰揔愗側僨乕僞挿偵挷惍偝傟傞昁梫偑偁傞偐傜偱偡丅mp3僼傽僀儖偱偼昁
    偢偟傕偙偆偼側偭偰偄傑偣傫丅
   
劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

4. DAO(Disc-At-Once) CD 傪從偔

DAO 偲偼 Disc-At-Once 偺棯偱偡偑丄偙傟偼丄尰嵼丄僩儔僢僋娫偱 2 昩偺媥巭
傪擖傟偢偵 CD 傪從偔桞堦偺曽朄偱偡丅僷乕僥傿梡偺 CD 傪從偔偵偼椙偄曽朄
偱偡丅DAO 儌乕僪偱 CD 傪從偔僾儘僌儔儉偼 cdrdao偱丄 SourceForge 偐傜擖
庤偱偒傑偡丅http://sourceforge.net/projects/cdrdao/

  cdrdao僾儘僌儔儉偼 TOC(傕偪傠傫栚師(Table Of Contents))偲屇偽傟傞愝掕
僼傽僀儖傪巊偄傑偡丅偙偺傛偆側僼傽僀儖傪嶌傞偵偼傆偨偮偺曽朄偑偁傝傑偡
丅戞堦偼丄cdrdao 僜乕僗(contrib偲偄偆僨傿儗僋僩儕偵丄 generate_toc.sh偲
偄偆僼傽僀儖偑偁傝傑偡)偵娷傑傟偰攝晅偝傟偰偄傞僔僃儖僗僋儕僾僩傪巊偆曽
朄偱偡丅曄悢偲偟偰 .wav僼傽僀儖偺儕僗僩傪巊偄丄 cd.toc傪惗惉偟傑偡丅傕
偆傂偲偮偺曽朄偼丄偍岲傒偺僥僉僗僩僄僨傿僞偱帺暘偱偦偺傛偆側僼傽僀儖傪
嶌傞曽朄偱偡丅巹偑巊偭偰偄傞傕偺傪帵偟偰偍偒傑偡丅 

CD_DA                                                                  
                                                                       
TRACK AUDIO                                                            
AUDIOFILE "mix-01.wav" 0                                               
                                                                       
TRACK AUDIO                                                            
AUDIOFILE "mix-02.wav" 0                                               
                                                                       
TRACK AUDIO                                                            
AUDIOFILE "mix-03.wav" 0                                               
                                                                       
TRACK AUDIO                                                            
AUDIOFILE "mix-04.wav" 0                                               
                                                                       
TRACK AUDIO                                                            
AUDIOFILE "mix-05.wav" 0                                               

wave 僼傽僀儖偺柤慜偺屻傠偵偁傞0(僛儘)偼僼傽僀儖偺弶傔偐傜巒傔傞偙偲傪
堄枴偟偰偄傑偡丅僼傽僀儖偺挿偝(僞僀儉)傪巜掕偡傞偨傔偺戞擇偺悢帤傪抲偔
偙偲偑偱偒傑偡丅xcdroast傕摨偠傛偆側TOC僼傽僀儖傪嶌傝傑偡偟丄 cdrdao僜
乕僗偺 testtocs 僨傿儗僋僩儕偵傕椺偑偁傝傑偡丅

cdrdao偼僨僼僅儖僩偱僨僶僀僗 /dev/cdrecorder 傪巊偄傑偡偑丄偙傟偼
cdwriter 僨僶僀僗偵儕儞僋偟偰偄側偗傟偽側傝傑偣傫丅偍巊偄偺 cd recorder
僨僶僀僗偑 /dev/scd0側傜丄師偺傛偆偵( root 偱)儕儞僋傪嶌惉偟傑偡丅

ln -s /dev/scd0 /dev/cdrecorder                                        

TOC 僼傽僀儖偑 cd.toc 偲偄偆柤慜偩偲偡傟偽丄cd 傪從偔僐儅儞僪偼娙扨側傕
偺偱偡丅

cdrdao write cd.toc                                                    

劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

5. 幱帿

Linux 僐儈儏僯僥傿偵峷專偡傞偡傋偰偺恖偲偙偺 HOWTO 傪姰惉偝偣偰偔傟偨偡
傋偰偺恖偵姶幱偄偨偟傑偡丅

劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

5.1. 東栿暥彂

 丒 Im Eunjea - 偙偺暥彂傪娯崙岅偵東栿丅師偺偲偙傠偵偁傝傑偡丅 http://
    kltp.kldp.org/eunjea/mp3_burning/
   
 丒 Mendel L Chan - 偙偺暥彂傪拞崙岅偵東栿丅師偺偲偙傠偵偁傝傑偡丅 
    http://www.linux.org.tw/CLDP/mini/MP3-CD-Burning/
   
劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

5.2. 偦偺懠峷專傪捀偄偨曽乆

 丒 Greg Ferguson - 嵟弶偵偙偺暥彂傪 HTML 偐傜 SGML 偵曄姺丅
   
 丒 Rob Russell - 巹偺柤慜偺曄姺椺傪廋惓
   
 丒 Terry Davis - 偺 HOWTO 傪 linuxdoc 偵採弌偡傞偺傪採埬
   
 丒 Chris Vaill - normalize僾儘僌儔儉傪嶌惉
   
 丒 Jamie Kellogg - 傔傫偳偆側僼傽僀儖偵 lame 偱僨僐乕僪偡傞夝寛曽朄傪
    採埬
   
劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒劒

6. 擔杮岅栿偵偮偄偰

東栿偵娭偡傞偛堄尒偼 JF 僾儘僕僃僋僩 <JF@linux.or.jp> 埗偵楢棈偟偰偔偩
偝偄丅

峑惓偍傛傃偛堄尒傪捀偄偨曽乆::
   
    擔杮岅栿 Mar.16 2002
   
     仩 Takahiko_Kawasaki < Takahiko_Kawasaki@cii.csk.co.jp>
       
     仩 Nomoto Hirokazu <nomoto_hirokazu@bud-international.co.jp>
       
     仩 Masanori Kobayasi 偝傫<zap03216@nifty.ne.jp>
       
     仩 KIMURA Tomoaki 偝傫<t-kimura@po.shiojiri.ne.jp>
       
     仩 YOSHIMURA Keitaro 偝傫<ramsy@linux.or.jp>
       
     仩 OBATA Noboru偝傫<noboru@ylug.org>
       
     仩 Konkiti 偝傫<konkiti@lares.dti.ne.jp>
       
     仩 Seiji Kaneko 偝傫丗<skaneko@a2.mbn.or.jp>
       
     仩 Yuji Senda 偝傫<ysenda@pop01.odn.ne.jp> (擔杮岅栿 sgml 偺僠僃僢
        僋)
       
