Page 1 of 5 123 ... LastLast
Results 1 to 10 of 41

Thread: HOW-TO: Use your MTP mp3 Players with Ubuntu!

  1. #1
    Join Date
    Feb 2006
    Beans
    11

    HOW-TO: Use your MTP mp3 Players with Ubuntu!

    Recently, a few mp3 players have gone the route of Microsoft's new Media Transfer Protocol (MTP) which is based off Picture Transfer Protocol (PTP). Linux has a PTP transfer client, which has had some limited success in transferring files to and from the players, mainly I-Rivers. But for owners of many Creative Players with Firmware 2.* and higher, and some Dell players, use of these devices has been impossible. Until the release of libmtp, which allows us to list the tracks on the player, detect players plugged into the machine, send, get, and delete tracks from the player. Libmtp can be found at http://libmtp.sourceforge.net.

    The first step is to download the newest version from libmtp's CVS.

    Code:
    $cvs -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/libmtp login
    hit enter when prompted for a password.
    $cvs -z3 -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/libmtp co -P libmtp
    What I reccomend to do now, is to find if your player is currently supported by libmtp, connect the player via USB, and run
    Code:
    $lsusb
    Find your player in the output, and note the part of the output that is in this format "XXXX:XXXX", for my Creative Zen Sleek, the output was "041e:4137"

    Then, look in libmtp's usermap to see if it is supported yet.
    cd into where you downloaded libmtp into, and view the file "libmtp.usermap"

    Try to find your player in the list. If it is unsupported, you can try to add it to the usermap by copying the lines from a player, but changing the second and third phrases of the line with the two numbers you got from lsusb. If you do this, you must do the same to the two numbers in the file libmtp.rules.

    Now to install the file. Make sure you have libtool, automake, and autoconf installed.

    Code:
    $sudo apt-get install autoconf automake1.9 libtool
    Then, run the preconfigured autogen.sh script from CVS

    Code:
    $./autogen.sh
    If no errors are output, we can now go on to configuring the program. There are some errors with using gcc 4 currently, so we must change that. The readme says to use gcc-3.2, but that isnt on any of the newer repos for Ubuntu, and I had no trouble with gcc-3.3

    Code:
     
    $sudo apt-get install gcc-3.3
    $CC=gcc-3.3
    $export CC
    $./configure
    $make
    $sudo make install
    If no errors come up, you have now installed libmtp successfully!

    To use the player, you can use their example client in the examples directory you downloaded libmtp to.

    Code:
    $cd examples/
    Currently, there are 5 scripts, tracks, sendtr, gettr, deltr, and detect.

    To test if the player is detected, connect the player, turn it on, and run

    Code:
    $sudo ./detect
    If it can't find the player, try disconnecting and reconnecting the player to a different USB port.

    To upload songs to your player use sendtr, run

    Code:
    $sudo ./sendtr [filename]
    enter the right codec when it prompts you to, either MP3 WAV or WMA, this is required, then enter the rest of the information at the prompts, the rest are optional.

    To download songs from your computer, use gettr.

    First you need to find the track ID and filename of the songs name on the player, run

    Code:
     
    $sudo ./tracks
    This will list all the songs and their IDs in it's output. Find the song you wish to get, not it's Track ID and Origfilename and then run

    Code:
    $sudo ./gettr [Track ID] [Origfilename]
    To delete tracks from the player, use deltr. You will need the Track ID from the output of tracks, then run

    Code:
    $sudo ./deltr [Track ID]

  2. #2
    Join Date
    Jan 2006
    Beans
    132

    Re: HOW-TO: Use your MTP mp3 Players with Ubuntu!

    Gnomad2 (http://gnomad2.sourceforge.net/) now has some support for libmtp. I havn't been able to try it out yet, but I'm eager to use my Nomad Zen in Linux....

    Didijt

  3. #3
    Join Date
    Apr 2006
    Location
    Odense, Denmark , scandinavia, Europe, Earth, Milkyway, Universe.... where was i...?!?
    Beans
    73
    Distro
    Ubuntu 6.06

    Re: HOW-TO: Use your MTP mp3 Players with Ubuntu!

    Running the first line gets me a "not such file or file directory" error - any ideas?
    Open minded - No boundaries - Open source
    Homepage: www.evolver.dk

  4. #4
    Join Date
    Jul 2005
    Location
    trieste - italy
    Beans
    Hidden!
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: HOW-TO: Use your MTP mp3 Players with Ubuntu!

    Quote Originally Posted by stengah
    Running the first line gets me a "not such file or file directory" error - any ideas?

    sudo apt-get install cvs should be fine
    check my wonderful blog -> www.suppah.eu
    i am NOT this guy -> http://pekwm.org

  5. #5
    Join Date
    Feb 2006
    Location
    USA
    Beans
    214
    Distro
    Ubuntu 6.06

    Re: HOW-TO: Use your MTP mp3 Players with Ubuntu!

    h4x0r@ubuntu:~/libmtp$ configure
    bash: configure: command not found
    h4x0r@ubuntu:~/libmtp$ sh ./configure
    sh: ./configure: No such file or directory
    h4x0r@ubuntu:~/libmtp$ ./configure
    bash: ./configure: No such file or directory
    h4x0r@ubuntu:~/libmtp$ cd
    h4x0r@ubuntu:~$ ./configure
    bash: ./configure: No such file or directory
    h4x0r@ubuntu:~$ whereis configure
    configure:
    h4x0r@ubuntu:~$ cd configure
    bash: cd: configure: No such file or directory
    h4x0r@ubuntu:~$ cd ,/configure
    bash: cd: ,/configure: No such file or directory
    h4x0r@ubuntu:~$
    h4x0r@ubuntu:~$ cd ./configure
    bash: cd: ./configure: No such file or directory
    h4x0r@ubuntu:~$

    didnt detect for me so i tried the gcc downgrade thing and this was my output
    "This bed is evil, it's draining your soul!"

  6. #6
    Join Date
    Apr 2006
    Location
    United Kingdom
    Beans
    89

    Re: HOW-TO: Use your MTP mp3 Players with Ubuntu!

    upon running
    ./configure

    I get:

    checking for a BSD-compatible install... /usr/bin/install -c
    checking whether build environment is sane... yes
    checking for gawk... gawk
    checking whether make sets $(MAKE)... yes
    checking for gcc... gcc-3.3
    checking for C compiler default output file name... configure: error: C compiler cannot create executablesSee `config.log' for more details.

    I have build-essential etc installed and I've compiled from source before. I'm using dapper. (Maybe I shouldn't be!)

    Any ideas?

  7. #7
    Join Date
    Feb 2006
    Beans
    11

    Re: HOW-TO: Use your MTP mp3 Players with Ubuntu!

    Quote Originally Posted by thunderduck3141
    h4x0r@ubuntu:~/libmtp$ configure
    bash: configure: command not found
    h4x0r@ubuntu:~/libmtp$ sh ./configure
    sh: ./configure: No such file or directory
    h4x0r@ubuntu:~/libmtp$ ./configure
    bash: ./configure: No such file or directory
    h4x0r@ubuntu:~/libmtp$ cd
    h4x0r@ubuntu:~$ ./configure
    bash: ./configure: No such file or directory
    h4x0r@ubuntu:~$ whereis configure
    configure:
    h4x0r@ubuntu:~$ cd configure
    bash: cd: configure: No such file or directory
    h4x0r@ubuntu:~$ cd ,/configure
    bash: cd: ,/configure: No such file or directory
    h4x0r@ubuntu:~$
    h4x0r@ubuntu:~$ cd ./configure
    bash: cd: ./configure: No such file or directory
    h4x0r@ubuntu:~$

    didnt detect for me so i tried the gcc downgrade thing and this was my output

    Are you sure you ran the autogen script that comes with libmtp previous to trying to run configure?


    Quote Originally Posted by paulyche
    upon running
    ./configure

    I get:

    checking for a BSD-compatible install... /usr/bin/install -c
    checking whether build environment is sane... yes
    checking for gawk... gawk
    checking whether make sets $(MAKE)... yes
    checking for gcc... gcc-3.3
    checking for C compiler default output file name... configure: error: C compiler cannot create executablesSee `config.log' for more details.

    I have build-essential etc installed and I've compiled from source before. I'm using dapper. (Maybe I shouldn't be!)

    Any ideas?
    I've never encountered that error before, and a quick google search only came up with one result, in italian. The only thing I can think of is make sure g++ is installed, maybe even g++-3.3.
    Last edited by jpeirce; April 25th, 2006 at 01:13 AM.

  8. #8
    Join Date
    Apr 2006
    Location
    United Kingdom
    Beans
    89

    Re: HOW-TO: Use your MTP mp3 Players with Ubuntu!

    Thanks jpeirce,

    No progress with g++ installed though. I've tried using gcc4.0, gcc3.3, gcc3.4 and even gcc2.95 (with apporpriate g++'s) and the same error occurs. So I think my problem isn't to do with the compiler.

    Thanks anyway for your suggestion.

  9. #9
    Join Date
    Feb 2006
    Beans
    11

    Re: HOW-TO: Use your MTP mp3 Players with Ubuntu!

    Can you post your config.log after you try to configure it? Perhaps that will shed some light on the situation.

  10. #10
    Join Date
    Apr 2006
    Location
    United Kingdom
    Beans
    89

    Re: HOW-TO: Use your MTP mp3 Players with Ubuntu!

    Actually I've been a bit naughty and cross-posted....


    my config.log file is here here

Page 1 of 5 123 ... LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •