Related YoLinux Tutorials:
°Burn DVD on Linux
°Real Video Streaming
°Public Domain Music
°Integrate Linux into MS/Windows environment
°YoLinux Tutorials Index
Free Information Technology Magazines and Document Downloads
|Digital audio (MP3) Players:
|Description:||Feature rich KDE audio player. Available plugins include an automatic scrolling of Lyrics. Supports M3U playlists.
From the GNOME toolbar: Applications -> Sound & Video -> Amarok
|Formats:||MP3, WMA, Real, Ogg, AAC, FLAC, ALAC (Apple), SHN, WAV. Also optical audio CD.|
|Installation:||Debian/Ubuntu: sudo apt-get install amarok|
If KDE is not yet installed, it will be when as this application is dependent upon Qt and KDE.
|Description:||Feature rich audio player. A Gtk2 fork and super-set of beep and xmmx players. Supports M3U, PLS and XSPF playlists
From the GNOME toolbar: Applications -> Sound & Video -> Audacious
|Formats:||MP3, AAC, AC3, APE, ALAC (Apple), FLAC, Ogg Vorbis, WAV, Musepack, TTA, WMA, several chiptune formats, MIDI, Playstation Audio, etc. Also optical audio CD.|
|Installation:||Debian/Ubuntu: apt-get install audacious|
Red Hat EL5/Fedora 4-6 RPMs: audacious, audacious-plugins
|Description:||Default Gnome player and jukebox. Supports PLS playlists. Based on Gnome gStreamer plugin framework.
From the GNOME toolbar: Applications -> Sound & Video -> Rhythmbox
|Formats:||MP3, AAC, AC3, APE, ALAC (Apple), FLAC, Ogg Vorbis, WAV, Musepack, WMA, Real. (very complete!) Also optical audio CD.|
|Installation:||Debian/Ubuntu: apt-get install rhythmbox|
Fedora/Red Hat: Included on installation media. RPM package: rhythmbox
|Description:||KDE player and jukebox. Integrates well with toolbar.
From the GNOME toolbar: Applications -> Sound & Video -> JuK
|Formats:||MP3, APE, FLAC, Ogg Vorbis, Musepack. Optical CD not natively supported. Audio CD only with helper application.|
|Installation:||Debian/Ubuntu: apt-get install juk|
Fedora/Red Hat (RHEL6): Included on installation media. RPM package: kdemultimedia
|Description:||Console/command line MP3 player
From the command line: mpg123 file-name.mp3
|Installation:||Debian/Ubuntu: apt-get install mpg123|
user1@localhost:~/MP3$ mpg123 01_02_Tres_Brujas.mp3
High Performance MPEG 1.0/2.0/2.5 Audio Player for Layers 1, 2 and 3
version 1.12.1; written and copyright by Michael Hipp and others
free software (LGPL/GPL) without any warranty but with best wishes
Playing MPEG stream 1 of 1: 01_02_Tres_Brujas.mp3 ...
Title: Tres Brujas Artist: The Sword
Album: Warp Riders
Year: 2010 Genre: Metal
MPEG 1.0 layer III, VBR, 44100 Hz joint-stereo
[4:09] Decoding of 01_02_Tres_Brujas.mp3 finished.
|Description:||Console/command line MP3 player
From the command line: mpg321 file-name.mp3
|Installation:||Debian/Ubuntu: apt-get install mpg321|
user1@localhost:~/MP3$ mpg321 Slacktone_-_The_Bells_of_St_Kahuna_Live__KEXP.mp3
High Performance MPEG 1.0/2.0/2.5 Audio Player for Layer 1, 2, and 3.
Version 0.2.12-1 (2010/07/01). Written and copyrights by Joe Drew,
now maintained by Nanakos Chrysostomos and others.
Uses code from various people. See 'README' for more!
THIS SOFTWARE COMES WITH ABSOLUTELY NO WARRANTY! USE AT YOUR OWN RISK!
Title : The Bells of St. Kahuna (Live Artist : Slacktone
Album : Slacktone - Live @ KEXP 9/23/2 Year : 2011
Comment : URL: http://freemusicarchive.o Genre : rock
Playing MPEG stream from Slacktone_-_The_Bells_of_St_Kahuna_Live__KEXP.mp3 ...
MPEG 1.0 layer III, 320 kbit/s, 44100 Hz joint-stereo
[4:30] Decoding of Slacktone_-_The_Bells_of_St_Kahuna_Live__KEXP.mp3 finished.
Additional Digital Audio Players:
- Banshee - Gnome media player (CDs, audio books, Podcasts, Radio, Videos, ...)
- Exaile - Python/Gtk+ full featured player
- Muine Gnome
- MPlayer - (not just a video player)
- XMMS.org - 4Front Multimedia
Note: Typing the letter 'l' will open a dialog box which will allow you to select a new file.
Use as GUI or command line: xmms file-name.mp3
[Potential Pitfall]: Many of the audio players require an internet connection to connect to music information repositories on the internet. Gnome based applications will require one to set the GNOME proxy configuration if your LAN is behind a corporate proxy. See GNOME proxy configuration to set this configuration for the GNOME desktop and GNOME applications.
|Linux MP3 ripping and encoding tools:
|Sound Juicer||Current Gnome CD ripper|
Connects to MusicBrainz.com for CD and track information.
|Grip||deprecated Gnome CD ripper||Y||N||Y||Y||Y||Y|
|Asunder||GUI MP3 ripping program. Build from source.||Y||Y||Y||Y||Y||Y|
|KaudioCreator||KDE desktop ripper/encoder. Configure with KDE Control Center (kcontrol) |
System Settings -> Sound and Multimedia -> Audio CD
|CD Paranoia||Command line CD to WAV,AIFF,AIFF-C||N||N||N||N||N||Y|
|RipperX||Supports CDDB lookups.|
apt-get install ripperx
|Ruby Ripper||Uses CDDB-info.|
Install: apt-get install rubyripper rubyripper-gtk
Dependencies: cd-discid cdparanoia flac lame mp3gain normalize-audio ruby-gnome2 ruby vorbisgain
|MP3c||MP3 creator - X-11 and console program - connects to the CDDB database||Y||N||Y||Y||N||N|
|abcde||Command line MP3 ripping console program||N||N||Y||Y||Y||N|
- MP3: patented format. Lossy data compression.
- Ogg Vorbis: lossy open audio format
- FLAC: Free Lossless Audio Codec. Non-proprietary, unencumbered by patents
- AAC: Advanced Audio Coding. Apple iPod format. Patented.
A patent license is required for all manufacturers or developers of AAC codecs. Thus FOSS implementations such as FFmpeg and FAAC may be distributed in source form only, in order to avoid patent infringement.
- CDDA: Compact Disk Digital Audio. Raw compact disc format.
Wikipedia comparison of audio formats
Digital Audio Encoders:
The encoder takes the raw digital music representation and converts it to the compressed format desired.
|LAME||LAME is a high quality MPEG Audio Layer III (MP3) encoder licensed under the LGPL. ||MP3|
|Fraunhofer technology licensed by Technicolor|
|Commercially available mp3HD command line encoder for Linux.||MP3|
|BladeEnc||BladeEnc is a fast freeware MP3 encoder. Homepage no longer available. ||MP3|
|MP+||Designed to maintain the same level of quality as the original WAV file. ||MP3|
|Ogg Vorbis||Open, non-proprietary, patent-and-royalty-free, general-purpose compressed audio format for high quality (44.1-48.0kHz, 16+ bit, polyphonic) audio. ||ogg|
|FAAC||Advanced Audio Coder (MPEG2-AAC, MPEG4-AAC).. ||AAC|
|FLAC||command line encoder: source|
|Sound Juicer: Creating MP3, OGG, FLAC files from an audio CD
Sound Juicer is the current (Fedora 4+) Linux Gnome desktop audio CD ripping and encoding tool.
Due to licensing issues, MP3 encoding is not installed by default.
Encoding available with the base Linux distributions include Ogg Vorbis and WAV.
See instructions below to add MP3 encoding capability.
Launch application: Applications + Sound and Video... + Audio CD Extractor
- Red Hat/Fedora/CentOS:
- The sound-juicer RPM is included in the DVD ISO images and can be installed during installation or afterwards from the DVD.
- yum install sound-juicer
- Ubuntu: apt-get install sound-juicer
Sound Juicer configuration:
The digital encoders used by Sound Juicer are configured using the "Gnome Audio Profiles" tool.
(RPM package: gnome-media)
(Ubuntu install: sudo apt-get install gnome-media-profiles)
Be sure to check "Active" to make this available.
Select "New" and enter "Profile name".
EnterGstreamer encoding parameters. See below.
MP3 encoding parameters:
|Profile Name||Gstreamer pipeline||File extension
|Mp3 - Lossy||audio/x-raw-int,rate=44100,channels=2 ! lame name=enc||mp3|
|Mp3 - High Quality (Lame)||audio/x-raw-int,rate=44100,channels=2 ! lame name=enc vbr=4 vbr-quality=2||mp3|
|Mp3 - Portable||audio/x-raw-int,rate=44100,channels=2 ! lame name=enc vbr=4 vbr-quality=6||mp3|
|Ogg Quality, Lossy||audio/x-raw-float,rate=44100,channels=2 ! vorbisenc name=enc quality=0.5 ! oggmux||ogg|
|WAV Voice, Lossless||audio/x-raw-int,rate=22050,channels=1 ! wavenc name=enc||wav|
Ripping and encoding:
Once encoder profiles have been configured, start Sound Juicer: Applications + Sound and Video... + Audio CD Extractor
Sound Juicer main panel:
Options for file naming can be selected under "Edit" + "Preferences":
Folder Hierarchy generated by Sound Juicer:
Set destination "Folder".
Set preferences by selecting encoder.
MP3 File Name generated by Sound Juicer:
- Album Artist,Album Title
- Track Artist,Album Title (I use this)
- Album Title
- Album Artist
- Album Artist - Album Title
- Track Number - Title
- Track Title
- Track Artist - Album Title
(Select this option if the CD has a collection of various artists)
- Track Number. Track Artist - Track Title
(This option provides a name which is more identifiable when copied outside of the directory structure)
- "Sortable" refers to listing the last name first for alphabetical sorting.
Example: "Joe Satriani" becomes "Satriani, Joe"
- A comma refers to a "/" directory separator. "Track Artist,Album Title" becomes "Track Artist/Album Title/"
- If "Strip special characters" is selected then blanks, "?", etc become "_".
- Sound Juicer configuration file: ~/.gconf/apps/sound-juicer/%gconf.xml
Put CD in tray. Sound Juicer will attempt to identify the Title, Artist, Tracks, etc from MusicBrainz.com.
If not you get this display.
[Potential Pitfall]: This feature requires an internet connection to connect to the music information repository at MusicBrainz.com. One must set the GNOME proxy configuration if your LAN is behind a corporate proxy. See GNOME proxy configuration to set this configuration for the GNOME desktop and GNOME applications.
Once the CD and contents have been identified and all settings have been configured, select "Extract" to "Rip" and encode! Sound Juicer rings a bell when done.
Sound Juicer can also duplicate audio CDs.
|Adding MP3 encoding capability to Sound Juicer:
Red Hat, Fedora, CentOS, Suse and Mandrake RPM based Linux distributions:
In order to encode to MP3 one must install the MP3 encoder which is not available with either the default Ubuntu or Red Hat distributions.
Red Hat, Fedora, CentOS, Suse and Mandrake RPM based Linux distributions will require the installation of the gstreamer-plugins-ugly RPM package.
The available encoder configurations can be seen or modified with gnome-audio-profiles-properties.
The gstreamer-plugins-ugly RPM and dependencies can be found at
Example: The installation of MP3 supplemental packages on my Red Hat 6 Enterprise Linux (64 bit) Workstation:
- Package: gstreamer-plugins-ugly
- Package: libmp3lame
- Package: libmpeg2
- Package: liba52
- Package: twolame
- Package: libid3tag
- Package: libopencore-amrwb
- Package: libopencore-amrnb
- Package: libsidplay
- Package: libmad
- Package: libx264_112
rpm -ivh gstreamer-plugins-ugly-0.10.17-13.el6.x86_64.rpm libmp3lame0-3.98.4-22.el6.x86_64.rpm libmpeg2_0-0.5.1-5.el6.x86_64.rpm liba52_0-0.7.4-7.0.1.el6.x86_64.rpm twolame-0.3.12-2.el6.x86_64.rpm libid3tag-0.15.1b-7.el6.x86_64.rpm libopencore-amrwb0-0.1.2-2.el6.x86_64.rpm libsidplay-1.36.59-1.2.fc6.rf.x86_64.rpm libmad0-0.15.1b-4.el6.x86_64.rpm libopencore-amrnb0-0.1.2-2.el6.x86_64.rpm libx264_112-0.112-14_20110114.2245.el6.x86_64.rpm
Encode (record) Options:
- Lame: (note that gstreamer is used as an interface to lame)
- Ubuntu install: sudo apt-get install lame lame-doc libmp3lame0
See gstreamer config file (default contents shown): /usr/share/gstreamer-0.10/presets/GstLameMP3Enc.prs
Ubuntu package: rhythmbox-data
Also see Gstreamer lamemp3enc encoder settings
For high quality MP3 encoding at a 320 kbps bitrate try the following settings:
Gstream pipeline setting: audio/x-raw-int,rate=44100,channels=2 ! lame name=enc mode=0 quality=0 bitrate=320 ! id3v2mux
Decode (play) Options:
Choose only one of the above two options. The two can not co-exist.
- Open Source Solution: Installation: apt-get install gstreamer0.10-plugins-ugly gstreamer0.10-plugins-ugly-multiverse
- Commercial Solution: Fluendo (Fluendo is a company specialized in delivering licensed products for Unix and Linux multimedia.)
Use the "Ubuntu Software Center" to download and install the Fluendo MP3 codecs.
This installs package: gstreamer0.10-fluendo-mp3
Selection of encoders for Sound Juicer.
|GRIP: Creating MP3 files from a CD
Note that Grip is no longer the default Gnome CD ripper.
Grip has been replaced by Sound Juicer.
Grip is available in RPM form with Fedora Core (1,2,3) and Red Hat distributions.
On older Red Hat 7 releases, it was available on the Red Hat Powertools CD
The source is still available from the
Grip home page.
This GUI is a front-end to Linux command line tools.
It utilizes cdparanoia (cdparanoia is actually built into Grip or you can use
the external cdparanoia command)
or cdda2wav (my choice) for CD "ripping" and lame (best choice),
bladeenc, mp3encode, gogo, xingmp3enc or l3enc to encode the MP3 file.
Set the appropriate options under the "Config" tab.
Grip also has a built-in CD player (GCD) and connects to
CDDB (freedb.freedb.org) to obtain track titles where available.
- Red Hat/Fedora/CentOS: yum install grip
- Ubuntu: apt-get install grip
Note: Grip will also generate a playlist (.m3u file) of the tracks converted
and put it in your $HOME/mp3/ directory.
- # Install MP3 encoder (detailed below): # Download lame source and compile (detailed below). (or bladeenc)
- Start Grip: /usr/bin/grip
- Configure Grip:
- Select "Config" + "MP3" (or "Encode") + "Encoder" tabs.
- Set the "Encoder" pull down menu to "lame" or "bladeenc"
- Set the MP3 encoder: /opt/bin/lame or /opt/bin/bladeenc
(Note: Fedora Core comes with lame and Grip is pre-configured.)
- Default file format: ~/mp3/%a/%d/%n.mp3
This will put the ripped and encoded MP3 files into the
- Select tracks to convert. Select the "Tracks" tab and select the
tracks with the middle mouse button (three button mouse or two at once
for a two button mouse).
- Select the "Rip" tab + "Rip+Encode" button to begin.
|Creating MP3 files from a CD: - Using the command line -
It is easiest to use the GUI tool Grip as described above.
You may choose to use the command line interface as detailed here:
Dump tracks on an audio CD to wav files on your hard drive:
cdda2wav -D 0,4,0 -B /tmp/prefix-of-music-file
The files will be written out as /tmp/prefix-of-music-file_01.inf /tmp/prefix-of-music-file_01.wav /tmp/prefix-of-music-file_02.inf ...
You may have to be root. See YoLinux managing groups tutorial to configure system for regular users with CD-ROM access.
Encode MP3: Convert WAV to MP3
Use one of the following encoders:
lame prefix-of-music-file_01.wav song.mp3 - Fixed 128kbs stereo encoding
lame -h prefix-of-music-file_01.wav song.mp3 - High quality
lame -f prefix-of-music-file_01.wav song.mp3 - Fast and low quality
lame -b 112 prefix-of-music-file_01.wav song.mp3 - Encode at a bit rate of 112 kbs
Type lame --help to see file "USAGE" and get list of command line options.
- Ubuntu: sudo apt-get install lame
Use mlame script to convert multiple wav files.
./mlame -r -o "-v -V 0 -b 112" a*.wav
- -h: help text
- -r: remove files after encoding
- -o: "<lame options>" overrides script default options "-h -d -m j -b 128"
bladeenc prefix-of-music-file_01.wav song.mp3
Note: The size of the MP3 file will be approximately 10% the size of the wav file.
I was e-mailed the following tip: "Found that the BladeEnc MP3 encoder works
better (for my ears) encoding NewAge/Classical/etc and that lame is better for
harder music genres." Judge for yourself.
One may notice that the MP3 encoders are often missing from
The reason is that since 1998, the German research lab that holds the
MP3 patent, Fraunhofer, imposes fees to license and distribute the encoder.
This may lead to the eventual rise of Ogg Vorbis as a standard format although the recording industry rejects it due to the lack of anti-piracy
|Building Lame from source: (MP3 encoder)
The "lame" command line MP3 encoder is used in the conversion of wav files
(and other formats) to the MP3 file format.
The "lame" encoder RPMs currently ships with the Fedora Core.
If you wish to build the latest:
- The Lame home page: http://lame.sourceforge.net/
- tar -xzf lame3.70.tar.gz
- cd lame-3.70
- mv lame /opt/bin
- mv mlame /opt/bin (Script to handle multiple files)
- mv auenc /opt/bin (Script to handle multiple files)
- mv doc/man/lame.1 /opt/man/man1
- mv doc/html /usr/share/doc/lame/ (or on older systems: /usr/doc/lame) - Linux doc location
|Building BladeEnc from source: (MP3 encoder)
The "bladeenc" command line MP3 encoder is used in the conversion of wav files
to the MP3 file format.
- Download source from the BladeEnc home page: http://home8.swipnet.se/~w-82625/default.htm
- Click on "Sourcecode" (left frame)
- tar -xzf bladeenc-0.9x.x-src-stable.tar.gz
- cd bladeenc-0.9x.x
- ./configure --prefix=/opt
- make install
|Determine the MP3 File Encoding Specs:
The Linux "file" command can list the MP3 file specs.
Note that the same CD ripped in a sinlge session can have two different bitrates.
The lame bitrate settings are generally reflective of the highest level quality available for the originating material.
The above were ripped using Sound Juicer with gstreamer and lame with a bitrate set to 320kbps and frequency set to 44100 Hz.
[prompt]$ file ~/Music/Matchbox_Twenty/More_Than_You_Think_You_Are/d1t11._Matchbox_Twenty_-_You_re_So_Real.mp3
d1t11._Matchbox_Twenty_-_You_re_So_Real.mp3: Audio file with ID3 version 2.3.0, contains: MPEG ADTS, layer III, v1, 320 kbps, 44.1 kHz, JntStereo
[prompt]$ file ~/Music/Matchbox_Twenty/More_Than_You_Think_You_Are/d1t01._Matchbox_Twenty_-_Feel.mp3
d1t01._Matchbox_Twenty_-_Feel.mp3: Audio file with ID3 version 2.3.0, contains: MPEG ADTS, layer III, v1, 160 kbps, 44.1 kHz, JntStereo
ID3 tags are present in the MP3 (and FLAC, Ogg-Vorbis) file format and hold
title, artist, genre, album, track, year, album cover image and other relevant information.
Linux tagging tools:
|Description:||Feature rich commercial product (free for 30 days), cross platform Java. My favorite for auto-tagging my whole music collection at once or incrementally. It works! Successfully added tags (artist, album, song (title), genre, year) and album cover image which were all properly displayed in Rhythmbox. Uses online databases including MusicBrainz.
|Formats:||Mp4, M4a, M4p, Mp3, Wma, Flac and OggVorbis|
|Installation:||Java required. Java installer. Java program started with a shell script.|
|Description:||Gnome based tagging GUI tool.
|Formats:|| MP3, MP2, MP4/AAC, FLAC, Ogg Opus, Ogg Speex, Ogg Vorbis, MusePack, Monkey's Audio, and WavPack files|
|Installation:|| Ubuntu: sudo apt-get install easytag|
Red Hat el6: rpm -ivh easytag-2.1-2.el6.rf.x86_64.rpm
Fill tag scanner formats:
I used: %b/%n. %a - %t
- %a : Artist
- %b : Album
- %c : Comment
- %p : Composer
- %r : Copyright
- %e : Encoded by
- %g : Genre
- %i : Ignore
- %l : Number of tracks
- %o : Original artist
- %n : Track
- %t : Title
- %u : URL
- %y : Year
Pitfalls: Easytag did not automatically tag all music selected in bulk (select all). It seemed to only tag the first 10% of my music collection.
Further investigation showed me that it added a second and almost identical tag. Hmmm. I only want one set of tags.
While there were settings for CD databases, no new tag information was imported (eg. year, genre, album cover image, ...).
This application needs work although it does add basic tags to a reasonable selection like a single album or an artist's collection of albums.
If you get this error: AttributeError: 'QNetworkAccessManager' object has no attribute 'deleteResource'
|Description:||Python (cross platform). Uses weird kingo.
|Formats:|| MP3, Ogg Vorbis, FLAC, MP4 (AAC), Musepack, WavPack, Speex, The True Audio and Windows Media Audio. |
|Installation:|| Download tar file from http://musicbrainz.org/doc/MusicBrainz_Picard
tar xzf picard-1.2.tar.gz
sudo python setup.py install
Green box = Ok. Any red indicates a problem identifying the music file.
The "CD Lookup" button is way off and returns nonsense.
RHEL6 uses PyQt4 (PyQt4-4.6.2-8.el6.x86_64.rpm, PyQt4-devel-4.6.2-8.el6.x86_64.rpm)
Fix requires an upgrade: rpm -Uvh PyQt4-4.6.2-9.el6.x86_64.rpm PyQt4-devel-4.6.2-9.el6.x86_64.rpm
Then you must remove source, re-extract the tar file and rebuild picard: rm -Rf picard-1.2, ...
otherwise you will get the following error when trying to run picard:
ImportError: No module named astrcmp
|Description:||KDE/Qt tagger. Seems to be specifically targeted to editing/changing tags rather than auto-tagging
|Formats:|| MP3, Ogg/Vorbis, FLAC, MPC, MP4/AAC, MP2, Opus, Speex, TrueAudio, WavPack, WMA, WAV, AIFF files and tracker modules (MOD, S3M, IT, XM)|
|Installation:|| Ubuntu Install: sudo apt-get install kid3
Red Hat el6: build from source RPM: rpmbuild --rebuild kid3-3.0.2-1.src.rpm
Must have cmake28 (/usr/bin/cmake28) installed and soft linked to /usr/bin/cmake
RPM did not build but code did so I could install build from /home/user/rpmbuild/BUILDROOT/kid3-3.0.2-1.x86_64/
|Run:||I must admit I just didn't get this tool. I was not able to successfully tag anything.
Command Line Tagging tools:
In addition, many players (JuK, Banshee, Rhythmbox, Amarok) can also tag MP3 files.
- mid3v2: command line tagging tool
Ubuntu install: sudo apt-get install python-pip;sudo pip install mutagen
- id3tool: command line tagging tool
Ubuntu install: sudo apt-get install id3tool
Example: id3tool -t "song title" -a "album name" -r "artist name" -y "year" -c track number, no quotes, just the number, like 1 filename.mp3
- lltag: command line tagging tool. Optional automated batch processing.
- id3v2: based on id3lib
- eyeD3: command line or python program
|Description:||KDE player/Jukebox with limited tagging capability. One can view tags and change/edit tags. I could not find a way to auto tag mass quantities of MP3s. Seems limited to tagging one file at a time.
Not a bad feature if this is your media player anyway and you want to clean up an error you stumble upon.
It's a better Juke box player than tagger.
JuK tag editor
|Description:||Default Gnome player and jukebox with limited tagging capability. One can view tags and change/edit tags. Does not auto tag mass quantities of MP3s. Seems limited to tagging one file at a time.
Rhythmbox tag editor: select song -> Music + Properties
or right click on song -> Properties
Most digital music players (Audacious, Rhythmbox, Totem, Windows Media Player, iTunes, Winamp, ...) can play a "playlist" in M3U format.
Many MP3 digital audio players can generate playlists. This is also true for many of the ID3 tagging applications.
The playlist will list the file names (absolute or relative path) or URLs to play.
There are only two directives in a playlist:
This is the header and first line of the file.
- #EXTINF:length,Artist Name - Track Title
Where length is given in seconds. A length of "-1" tells the player to ignore the length.
This directive is then followed by the file name (using absolute or relative path) or URL (of type: audio/x-mpegurl) of the digital audio file.
Any format (mp3, ogg, ...) which can be decoded by the player will be valid.
Also see: IETF streaming multi-media data file format M3U standard
In this example the playlist is ~/Music/Rocklist_1.m3u and the MP3 files are ~/Music/The_Offspring/Americana/03._The_Offspring_-_Staring_at_the_Sun.mp3 and ~/Music/AFI/DecemberUnderground/05._AFI_-_The_Interview.mp3
#EXTINF:133,The Offspring - Staring at the Sun
#EXTINF:256,AFI - The Interview
Tip: Directory and file names can be listed using the shell command: find ./
When using MP3s in automotive entertainment systems and with other commercial
stereos it becomes apparent that there are limitations for the equipment of
Incompatible file name lengths, directory name lengths, USB and flash card
formats, etc, can all potentially prevent one from using an MP3 effectively.
The first and most obvious error I noticed was the image error when I used album cover images which were too large.
MP3 tips and best practices:
- Max folder depth: 8
- Max folders: 500
- Limit file/folder names to 40 char
- Max files per folder: 4,096
- Image file size limit: 512 Kb
- Image size limit: 8192 W x 7680 H pixels
Progressive format image size limit: 1600 W x 1000 H pixels
I have found that not all USB memory sticks were acceptible to my Kenwood automotive stereo. If you find that a USB stick is not read by the system, it may have an incompatible file system format.
USB tips and best practices:
- Format USB stick: sudo mkdosfs -F 32 -I /dev/sdg1
Sometimes the default vfat format is not right FAT format. This works on my Kenwood.
Ubuntu 14.04 installation: sudo apt-get install -y dosfstools
Man page: mkdosfs
- Add a volume label: sudo mlabel -i /dev/sdg1 ::MUSIC-A-G
Ubuntu 14.04 installation: sudo apt-get install -y mtools
Man page: mlabel
- Use an 8Gb USB drive. Larger 16Gb and 32Gb USB thumb drives would mount but my stereo would not read past the first 8Gb. The list of folders and files would be greyed out by the system and be unaccessible.