Making Motorola playlists (.pla files), part 2

Oct 06, 2009 16:32


(See part 1.)
As long as .pla file is binary, we will view it in hex. Here's a hex dump of a playlist containing first three tracks of Led Zeppelin IV:
$ hd lz4.pla 00000000 00 03 00 01 00 00 00 00 01 40 00 04 00 00 3d 60 |.........@....=`| 00000010 01 40 00 0e 00 00 3d 60 01 40 00 02 00 00 3d 5f |.@....=`.@....=_| 00000020
This playlist is named `lz4.pla'. We will refer to it below. Header

I've created several playlists "manually" and noticed that the second byte is always equal to the number of tracks in playlist (`03' in lz4.pla). Bytes with offsets 0 and 2-7 are the same for all playlists I've seen. Thus we can guess the format of .pla file header:
00 00 01 00 00 00 00,
where is number of tracks in playlist. Entry

Playlist header is followed by entries - 8-byte-long track specifications. There are as many entries as there are tracks in a playlist (lz4.pla file has three: address ranges 0x8-0xf, 0x10-0x17, and 0x18-0x1f).
When we open playlist in Motorola, we see the names of tracks included. But there is no chance for 8 bytes of .pla entry to contain the name of track: the third track is displayed as `03 - The Battle of Evermore' making a string of 27 characters.
Thus, we can assume that .pla entry encodes position of .mp3 file within the underlying filesystem.
Continued...

hacking, english, motorola

Previous post Next post
Up