Rockbox treats everything it's playing as part of a playlist. If you put a bunch of songs into a folder, then start to play one of them, Rockbox automatically puts all of the songs in that folder into a playlist. You won't necessarily know it unless you decide to save it as a playlist.
This post is about creating playlists using your computer. You can also create playlists using just your player and Rockbox, but that's a separate discussion.
What's a playlist?
A playlist is really just a list of songs. What makes it into a playlist is that there's a file path connected with each song on the list. When Rockbox reads the next song on the playlist, it uses the file path to find the song. Rockbox knows it's a playlist because of the file name extension: .m3u or .m3u8.
Incidentally, Rockbox creates playlists using .m3u8 as the extension. Most computer-based music managers seem to use .m3u. Rockbox recognizes either one.
A playlist file will look like:
playlist.m3uor
playlist.m3u8.The keys to making your playlists work are:
- getting the file paths right so Rockbox can find the songs
- getting the file extension right so Rockbox knows they're playlists
- getting your playlists in the right folder so they show up in the Playlist Catalog
File Paths
First the file paths. The file system Rockbox uses is just like the one on your computer. It's identical if you use Linux. If you use Windows, there's one significant difference: the Rockbox root directory (the base directly that every other folder and file is a part of) is called "/". That a forward slash without the quotation marks.
In Windows, the root directly is probably something like C:\ or G:\. In Rockbox, it's /. Rockbox, like Linux, uses a forward slash instead of a backslash, but I've read that it understands both. Haven't tested that though -- I always use a forward slash.
Rockbox Folders
On my Sansa Fuze, with a micro SD card in it, I have two root folders:
- /
- /
<microSD>/
- /
<microSD>/MUSIC/ - /MUSIC/
- 01 - Suzie Q.mp3
- 01 - Sympathy For the Devil.mp3
/Music/"Band"/"Album"/"Track Number" - "Title".mp3This isn't significant; you can name your songs anything you want. If I'd designed it with the portable player in mind, I might have left off the track number for simplicity.
A playlist looks like this:
/<microSD>/MUSIC/01 - Suzie Q.mp3
/<microSD>/MUSIC/01 - Sympathy For the Devil.mp3
/<microSD>/MUSIC/01 - The Red Rooster.mp3
/MUSIC/1 - I Can't Be Satisfied.mp3
/MUSIC/01 - I'm A Man.mp3The songs that begin with "/MUSIC/" are on the players' internal storage in the "MUSIC" folder. The songs that begin with "/
To show up in the Rockbox Playlist Catalog, playlists have to be in the playlist folder:
/Playlists/So the name for the example playlist could be:
Blues.m3uand the complete file name (the one you'd use as the file path in a playlist) would be
/Playlists/Blues.m3uCreating a Playlist
To create a playlist on your computer, you can use a text editor. Just a simple text editor is easiest. You can use a word processor like OpenOffice Writer or Microsoft Word, but you have to save it as a text file. If you save it as the regular .odt or .doc file it will have a lot of formatting information that will confuse Rockbox.
For me, it's easiest to make a list of the songs first, then add the file paths. So I start by typing just the file names:
01 - Suzie Q.mp3
01 - Sympathy For the Devil.mp3
01 - The Red Rooster.mp3
1 - I Can't Be Satisfied.mp3
01 - I'm A Man.mp3
Once that's done I add the paths using copy and paste. If the first song is in /
Then I do the same for the songs /MUSIC/.
Then I save the playlist as playlistname.m3u8 into the /Playlists folder.
Incidentally, for some reason when I create a playlist using Rockbox itself, the default is for Rockbox to save it in the root directory. That means it doesn't show up in the Playlist Catalog. To create it in the /Playlist folder, you have to add /Playlist to the beginning of the name. That's a real pain when you're using Rockbox's internal keypad.
It's probably just a setting I have to adjust somewhere, but I haven't figured it out yet.
Absolute and Relative File Paths
You can use two different kinds of file paths in Rockbox: Absolute and Relative.
File paths are just like directions. If you ask someone where the nearest coffee shop is, he can give you directions two ways. One is relative: "go two blocks ahead, then turn left." The other is absolute: "it's on the corner of 3rd and Pine St."
For the relative directions, you obviously have to know where you are. The wouldn't work in a newspaper ad, for instance.
File paths in playlists are the same way. The file path for a song can be absolute, meaning it starts with a root directory, or it can be relative, meaning it starts from the directory where the playlist is stored.
Since the Rockbox Playlist Catalog only lists playlists in the /Playlists directory, it's fairly easy to use either kind of file path. I find it easier to stick with absolute.
I've read that Rockbox tries to make file paths work even if there missed up. If it doesn't find the song using the filepath on the playlist, it will lop off directories until it finds it. So, for instance, if you the song is in /MUSIC/song.mp3, but you wrote the file path as /NEW/MUSIC/song.mp3, Rockbox would discover that there's no /NEW/ and move on to /MUSIC/.
I haven't actually tested that, but Rockbox has played a few songs from file paths I messed up.
2 comments:
Thanks for the instructions, just what I needed.
The procedure can be made a bit quicker using the shell tools: mount the player, cd to the root directory and issue (in a terminal) the find command piping the output directly into a playlist file. E.g. in my iPod:
user@pc:$ find Storage/ROCK/xxx >> Playlists/rockie.m3u
After that you have to convert all the 'Storage' strings in the start of the lines to '/Storage', which is probably easiest to do with a simple ed command:
user@pc:$ ed Playlists/rockie.m3u
7823
%s/Storage/\/Storage/g
%w
7907
q
Note: the numbers displyed reflect the number of characters in the playlist file before and after, they are of course different.
I'm sure Rockbox versions have changed since this very helpful post. After a few minutes of fiddling with playlists created in foobar2000 and exported as m3u8 files, I googled to find this. I tried the method outlined, especially with the forward slash but I kept getting errors on my iPod. I finally figured out that the root folder for Rockbox, at least for the version on my iPod which I believe is 3.13, is //, or two forward slashes instead of one. After I did that (and all my audio files are in the root folder), my playlists worked. Thought I'd post in case someone else came upon this post and had a similar issue. Thanks!
Post a Comment