Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses

Re^2: Fixing mp3 tags for Android 2.0

by hawtin (Prior)
on Jun 03, 2010 at 09:54 UTC ( #842891=note: print w/replies, xml ) Need Help??

in reply to Re: Fixing mp3 tags for Android 2.0
in thread Fixing mp3 tags for Android 2.0

It's fairly simple. The idea is that you do three steps:

  1. Copy all the mp3 files to a location on your PC
  2. Use this script to fill out the suitable tags
  3. Copy the fixed files to your Droid

So lets go through those steps, I'm going to assume that you *really* don't know what you are doing, I apologise if I'm stating the obvious here.

Copy MP3 files

Pick a temporary directory that will mirror what you want on your Droid. Personally I have a directory on the SD card called "Albums" with a subdir for each album. So maybe, on Windows, you create a directory called "D:\temp\Albums". Then within that directory create directories called, for example, "The Beatles 1967_1970" and "American Idiot". Then copy the mp3 files you want from wherever you have them into the suitable album directories.

If you are copying all your music that step should be quite simple, if you are selecting songs (for example from a play list) you can do that by hand, but you may find it easier to write a Perl script to do it for you.

Use the script

You will need to have Perl installed with all the necessary CPAN modules. Perl you can get from all sorts of places, on Windows you probably want Strawberry Perl or ActiveState. The modules can be more interesting, under ActiveState the PPM program will show you which modules you have installed, you need to make sure that "MP3::Tag" is present, if not install it. Under most other versions of Perl you will need to run a CPAN shell and install the module, there are plenty of places that tell you how to do that.

Now lets assume that you have copied this script to "D:\bin\". You need to run up a shell (on Windows select "Run" on the Start menu and type in "command" or "cmd").

> cd D:\temp\Albums > perl D:\bin\

At this point three things could happen. You could get a message to the effect "Don't understand the command" in which case you didn't install Perl properly, maybe you need to set your PATH for example. Alternately you could get a message "Can't find the module MP3::Tag" in which case go back and install the module.

In the best of worlds there is some activity, every mp3 file has its modification time changed and we get a files called "AlbumArt.jpg" added to each album directory. This means that the script has done its work

Copy to your Droid

So we now have a set of mp3 files that are ready to put on the Android device. There are a number of ways to get them there, I find the easiest is to use USB.

Plug the USB cable into the Droid and the computer. This will cause various noises and a USB icon will appear in the top left corner of your phone.

Open the notification bar by dragging this top line down with your finger, you will see an item "USB Connection". Select that and you will have four options, the bottom one will be something like "Charge Only" and will be selected, above that there will be "Memory Card Access", select that one.

Now you have told the Droid to let the PC manage its SD card. If you use "Windows Explorer" on the PC you should be able to find the Droid's SD card (it will be listed as "Removable Disk E:" or something like that.

Copy the directory "Albums" from your scratch area to the Droid's SD card. Once the copy is complete go back to the Droid and set its USB connection back to "Charge Only"

Listen to music

Now your music should be listed under the correct Artists, Albums and Song Titles, with the right artwork

As I said this description is long winded, I don't know what it is you don't know. But the process takes a lot less time to do than it does to explain.

Hope that works for you

Replies are listed 'Best First'.
Re^3: Fixing mp3 tags for Android 2.0
by WoogieNoogie (Initiate) on Jul 04, 2010 at 18:59 UTC
    Alright, after much deliberation, I've finally got Perl installed (Strawberry), and I got the MP3::Tag Module installed. Last step seems to be...fixing this error message I'm getting.
    Global symbol "$count" requires explicit package name at [file] Execution of [file] aborted due to complication errors.

      Ah you're right that line comes from my personal version of the script that does a whole load of other things (which you don't want). Just delete the line with the "$count++" on it.

      If you get any other issues please post them

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://842891]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (2)
As of 2022-08-09 22:31 GMT
Find Nodes?
    Voting Booth?

    No recent polls found