MavEtJu's Distorted View of the World - iPod

iPod A1285 and FreeBSD happiness

Back to index

iPod A1285 and FreeBSD happiness

Posted on 2008-12-16 19:00:00
Tags: FreeBSD, iPod, Apple

Earlier this year Naomi got her hands on a blue iPod. It is the first time that an iPod thing invaded our life and now that I spend about a good two hours per day on the train, I think it is the right time. Only, what to put on it?

Music! Everywhere I see people with the white earplugs I hear their music, I see them chosing the next track and I wonder "Which music can be so good that you can listen to it every day?". So music is a no-no.

Podcasts! I have several of them and up to now I always managed to listen to them while I was working from home. Right now I don't have the luxery of working from home, or listening to them on the weekend because I spend all my time entertaining the kids. So for the last weeks these things have been piling up:

[~/.penguintv] edwin@k7>du -skh media/
4.2G    media/
[~/.penguintv] edwin@k7>find media/ -type f | wc
     250     250    9917

So, the port audio/gtkpod to the rescue!

Well, except for one thing: The last step, at the the creation of the database on the iPod the program complains: The following has occurred: Couldn't find the iPod firewire ID. And the result is that all the physical files are on it, but that the iPod doesn't index them. Brilliant piece of crap! (The iPod that is)

Google to the rescue. Use Linux they say, run lsusb(8) they say. I didn't but it didn't give me the right string (WTF??!?!??!). Project iPod got stalled until today. Again Google to the rescue. Use Linux they say, run lsusb(8) they say. For FreeBSD they say, there is a tool for this they say, since usbdevs(8) does not provide enough output they say: they say.

It didn't do much, but then it's only 152 lines. That it didn't do much was more related to this line:

if(di.udi_vendorNo != 0x05ac) // dunno if udi_productNo changes depending on the ipod model, so vendor check should suffice

This is because my iPod shows up with vendor ID 0x05ac.

[~] root@k7>usbdevs -v
Controller /dev/usb4:
addr 1: high speed, self powered, config 1, EHCI root hub(0x0000), Intel(0x0000), rev 1.00
 port 1 powered
 port 2 powered
 port 3 addr 2: high speed, power 500 mA, config 1, iPod(0x1263), Apple Inc.(0x05ac), rev 0.01
 port 4 powered

A quick patch later and:

[~] root@k7>./getserial /dev/usb4
[4:2] Apple Inc. - iPod
iSerialNumber: 000A27001D1A3886

Add it to the iPod_Control/Device/SysInfo file on your iPod:

[~] root@k7>cat /mnt/ipod/iPod_Control/Device/SysInfo
ModelNumStr: xB249
FirewireGuid: 0x000A27001D1A3886

And gtkpod will work like a charm!

Show comment | Share on Facebook | Share on Twitter