What can you do with ipod linux

How to use your iPod Shuffle in Linux

In this article I will describe the probably best way to use your first or second generation iPod Shuffle in Linux. The described method is based on a python script called rebuild_db. The script will allow you to simply copy/paste music files to your iPod like to any other regular MP3-Player. In case you have a different or newer version of the iPod, the described method may not work for you and you should try using gtkPod instead.

Why I wrote this post

I used to utilize gtkPod to put music on my iPod, but I never liked the user interface and workflow of the software. At some point I did the mistake to format the storage of my device and it stopped working, since the directory structure and database file were missing . Although gtkPod has the ability to recreate this files and folders for nearly any type of iPod, it somehow didn’t work out for my device. After trying for hours I finally gave up. It was just recently that I retried to fix my iPod and this time I succeeded. I was able to fix the database file by using rebuild_db, it also made it very convenient to put music on the device and that’s why I want to share this solution with other people.

The solution

rebuild_db is a python script that basically scans the storage of your ipod for any music files and automatically creates the necessary database file.

  • Connect your iPod Shuffle to the PC and download rebuild_db from here
  • Extract the zip-file like this:
$ unzip rebuild_db-1.0-rc1.zip -d rebuild_db
$ cp rebuild_db.py /run/media/myUserName/iPod

Thats it! From now on simply execute the python script whenever you add or remove music to or from your iPod.

Advanced command line parameters

Normally it’s not necessary to apply any parameters when using the script. However some of the following options may be useful e.g. -l to suppress the creation of an log file.

-i, –interactive prompt before browsing each directory
-v, –volume=VOL set playback volume to a value between 0 and 38
-s, –nosmart do not use smart shuffle
-n, –nochdir do not change directory to this scripts directory first
-l, –nolog do not create a log file
-f, –force always rebuild database entries, do not re-use old ones
-L, –logfile set log file name

Legal notice: The picture in this post was taken by the author from his own device.

Источник

iPod

The iPod is a discontinued series of portable media players created by Apple Inc. Officially, you can only add music to iPods using Apple’s iTunes program, but there are several other programs that are able to sync music with an iPod.

Accessing the storage

Traditional iPods are accessed just like a normal USB storage device containing a vfat or hfsplus file system. See the USB storage devices article for detailed instructions on how to access your device.

  • If your iPod is formatted as hfsplus, you will need hfsprogsAUR to access it. You may also restore your iPod using iTunes on Windows in order to format it as vfat.
  • If your iPod is formatted as vfat, you can use dosfslabel (from dosfstools ) to rename your iPod’s volume label:
# dosfslabel /dev/sdXY ArchPod

Library management

These tools use the libgpod library:

  • Clementine — Amarok 1.4 clone, ported to Qt5.
  • Strawberry — Fork of Clementine aimed at audio enthusiasts and music collectors.
  • Rhythmbox — GTK clone of iTunes, formerly GNOME’s default music player.
  • gtkpod — GUI for Apple’s iPod using GTK. It allows you to import your existing iTunes database, add songs, podcasts, videos and cover art, and to edit ID3 tags.
  • Amarok — Mature Qt-based player known for its plethora of features.

The following tool uses their own implementation to communicate with the iPod:

  • jakpod — JakPod is based on Java and allows to copy music and video files to your iPod (does not work for 6th gen nano)

Converting video for devices

Handbrake

Handbrake is a nifty tool with presets for a variety of iPod versions. CLI and GTK versions are available with the handbrake-cli and handbrake packages respectively.

If you do decide to take the CLI way, a good guide is available at https://handbrake.fr/docs/en/latest/cli/command-line-reference.html.

Avidemux

This can convert to mp4 files. If you enforce a hard max of bit rate @ 700ish and keep the video size to 720×480 or 320×240 than it works fine for video file exporting.

Mencoder

Has extremely comprehensive configuration support, which will be able to spit out iPod-compatible video files. Check out mencoder(1) ; a lot of MPlayer opts will also affect encoding.

A basic guide is also available at MEncoder.

An example command to encode iPhone/iPod Touch-compatible video:

$ mencoder INPUT -o output.mp4 \ -vf scale=480:-10,harddup \ -oac faac -faacopts mpeg=4:object=2:raw:br=128 \ -of lavf -lavfopts format=mp4 \ -ovc x264 -x264encopts nocabac:level_idc=30:bframes=0

FFmpeg

Another encoder with comprehensive configuration support. Example command to encode for 5G iPod:

$ ffmpeg -vcodec xvid -b 300 -qmin 3 -qmax 5 -bufsize 4096 \ -g 300 -acodec aac -ab 96 -i INPUT -s 320x240 \ -aspect 4:3 output.mp4

or iPod Touch/iPhone compatible video output:

$ ffmpeg -f mp4 -vcodec mpeg4 -maxrate 1000 -b 700 -qmin 3 -qmax 5\ -bufsize 4096 -g 300 -acodec aac -ab 192 -s 480×320 -aspect 4:3 -i INPUT output.mp4

Device specific

iPhone/iPod Touch

Generating HashInfo file

If you have never synced your device using iTunes, you will get error messages telling you that the HashInfo file is missing. This can be fixed by syncing once with iTunes in order to create it. Alternatively one can create this file using the site http://ihash.marcansoft.com/. Enter the serial number of the iPod on the website. It will generate a file named HashInfo which you will place under the /mnt/ipod/iPod_Control/Device/ directory. Unplug the iPod device and plug it back.

Unobfuscating the Database

This article or section is out of date.

Reason: iOS version 2.0 is from 2008, and libgpod is already able to read the database without jailbreaking the device and editing system files. (Discuss in Talk:IPod)

Since firmware version 2.0, Apple has obfuscated the music database. If you are using recent firmware, the file /System/Library/Lockdown/Checkpoint.xml can be modified to enable use of the older, non-obfuscated database. If that file does not exist then try to copy from /System/Library/CoreServices/Checkpoint.xml to /System/Library/Lockdown/Checkpoint.xml then replace:

If syncing fails with ERROR: Unsupported checksum type ‘0’ in cbk file generation! , you may need to leave this at 4. libgpod seems to expect a hashed database [dead link 2023-04-23 ⓘ] .

iPod Classic/Nano (3rd generation)

You need to set up the iPod to make libgpod able to find its Firewire ID. For this, you will need to get your FireWire ID manually

1) Mount the iPod as a rw mount point. In the following example, use /mnt/ipod .

2 ) Find the serial number by typing

this should print a 16 character long string like 00A1234567891231 (it will have no colons or hyphens)

3) Once you have that number, create or edit /mnt/ipod/iPod_Control/Device/SysInfo . Add to that file the line below:

FirewireGuid: 0xffffffffffffffff

(replace ffffffffffffffff with the 16 digit string you obtained at the previous step and do not forget the leading 0x before the string)

Your iPod can now be managed with Amarok or gtkpod.

iPod Nano 5th generation

Follow the instructions above #Generating HashInfo file in order to set up the hash file, it is needed to write into the device music library. To be able to use the iPod Nano 5th gen with libgpod , a SysInfoExtended file is also needed to be placed in the directory /mnt/ipod/iPod_Control/Device/ . It can be generated using:

# ipod-read-sysinfo-extended bus device mountpoint 
# ipod-read-sysinfo-extended 001 011 /mnt/ipod/

iPod Nano 6th generation

By default libgpod does not seem to be able to synchronize on a iPod Nano 6th generation. It copies data, but as soon as USB is disconnected, everything is as before. The package libhashab-git AUR fixes this. Additionally, the SysInfoExtended file is also required, and can be generated in the same fashion as in #iPod Nano 5th generation, however a HashInfo file is unnecessary on this model.

iPod Shuffle 1st and 2nd generation

rebuild_db is a Python 2 script that makes it possible to use the iPod Shuffle almost like any other USB flash MP3 player. Download the script from the website, then place it in the iPod’s root directory. Copy your MP3 files onto the iPod Shuffle (sub-folders are allowed too) and then run the script:

$ python2 /mnt/iPod/rebuild_db.py

iPod Shuffle 4th generation

In order to use this version of the iPod Shuffle under linux, you can use the python based command line tool ipod-shuffle-4g AUR . It also provides advanced voiceover and (auto)playlist generation support.

iPod Video (5th and 5.5th generation)

iPods in the mainline series up to and including this model do not support the AAC PNS feature, and will display audible artifacts when encountering it. Disable the feature in ffmpeg when encoding AAC files for these devices.

$ ffmpeg -i input.ogg -c:a aac -b:a 256k -aac_pns 0 -movflags +faststart -vn output.m4a

The -movflags +faststart options place the moov atom at the start of the file, which helps the iPod parse the file faster.

Источник

работа с ipod в linux

сменив в свое время основную ось с винды на убунту, я столкнулась с такой проблемой, что компания apple не выпускает версию itunes для линуксов.

не хочет — и бог с ней, подумала я и решила искать софт от сторонних разработчиков.
и, кстати, совершенно не жалею, ибо многие программы оказались куда приятнее в общении, чем itunes.

собственно, с ними и хочу вас познакомить.

1. Floola. www.floola.com
маленькая, но очень толковая софтинка, весит 16 метров и прекрасно запускается с флешки или с самого айпода, посему незаменима для походов в гости. с музыкальной библиотекой работать не умеет, да ей и это и не надо, зато умеет перекидывать файлы прямо из папки drag&drop’ом, проигрывать треки с айпода и делать repair.
бесплатна, хотя постоянно просит сделать ей donate.
доступны версии для linux, windows и macos.
из недостатков — раньше путала треки, иногда после ее работы не хотел запускаться режим шаффл.
сейчас вроде все ок.

2. GTK Pod www.gtkpod.org
тоже очень приятная в обращении вещица, чуть серьезнее чем floola, умеет добавлять плейлисты, но не умеет делать repair. пару раз криво заливала музыку в мой шаффл, но в целом работала вполне себе исправно.
доступны версии для FreeBSD и Linux.

3. Amarok. amarok.kde.org/wiki/Main_Page
замечательный, почти легендарный, кдешный плейер для целого зоопарка всяких линуксов и фрибсд, умеющий работать с айподами. удобная и функциональная вещь, которая, увы, нещадно тормозит на моей старенькой машинке.

буду рада дополнениям и комментариям 🙂

upd 1: идущий в штатной поставке с той же убунтой плеер rythmbox тоже умеет работать с айподом
upd 2: информация для пользователей дистрибутива убунту и обладателей ipod touch — help.ubuntu.com/community/PortableDevices/iPhone

Источник

Читайте также:  Linux get group uid
Оцените статью
Adblock
detector