MTP on linux (Ubuntu) - LG Optimus G (International)

Hi guys...
I'm trying to mount my LGOG (E971) to use as MTP on my Ubuntu Linux (12.10) and i'm not being able to do.
Is anybody having problem with that?
here are the terminal log:
$ sudo mtpfs
Listing raw device(s)
Device 0 (VID=1004 and PID=61f9) is a LG Electronics Inc. V909 G-Slate.
Found 1 device(s):
LG Electronics Inc.: V909 G-Slate (1004:61f9) @ bus 1, dev 18
Attempting to connect device
PTP_ERROR_IO: failed to open session, trying again after resetting USB interface
LIBMTP libusb: Attempt to reset device
inep: usb_get_endpoint_status(): No such device
outep: usb_get_endpoint_status(): No such device
usb_clear_halt() on IN endpoint: No such device
usb_clear_halt() on OUT endpoint: No such device
usb_clear_halt() on INTERRUPT endpoint: No such device
usb_open(): No such file or directory
LIBMTP PANIC: Could not init USB on second attempt
Unable to open raw device 0
Click to expand...
Click to collapse
as we can see, it is recognized, but unable to connect.
any help?
cheers

Related

Bootloader never attach /ttyUSB0

hi
I'm in Ubuntu 8.04 hardy and my device is an HTC Blackstone that in ActiveSync and "HDD" mode everything works fine. Just plug and sync automatic with evolution.
$ lsusb
Code:
...
Bus 004 Device 013: ID 0bb4:0a25 High Tech Computer Corp.
$ dmesg
Code:
...
[ 8767.531274] usb 4-6: new high speed USB device using ehci_hcd and address 13
[ 8772.667688] usb 4-6: configuration #1 chosen from 1 choice
[ 8772.674321] ipaq 4-6:1.0: PocketPC PDA converter detected
[ 8772.678548] usb 4-6: PocketPC PDA converter now attached to ttyUSB0
The trouble is that I can't connect my device in bootloader mode because my device never gets attached to ttyUSB0:
$ lsusb
Code:
...
Bus 003 Device 003: ID 0bb4:00ce High Tech Computer Corp. mmO2 XDA GSM/GPRS Pocket Pc
$ dmesg
Code:
...
[11992.194622] usb 3-1: new full speed USB device using ohci_hcd and address 4
[11992.406668] usb 3-1: configuration #1 chosen from 1 choice
[11992.414547] ipaq 3-1:1.0: PocketPC PDA converter detected
[11998.195550] ipaq: probe of 3-1:1.0 failed with error -5
Someone can help me in this trick?? I would like connect my device in bootloader mode working on /dev/ttyUSB0.
Thanks
up pls
I am having the exact same problem, everything works fine with windows and mtty, however I am unable to get this to work on ubuntu (9.04).
I have also tried
Code:
sudo modprobe ipaq
even specifying the vendor and product does not appear to have any luck
no news on this? i have the same problem.
Same here, any news?

How to mount HOX(Jb) external storage in ubuntu?

I am an Ubuntu Linux user. I am now using ubuntu 12.10.
Just upgraded my HOX to JellyBean via OTA.
When I connect HOX to computer via USB cable,
'Mount USB Mass Storea' option is not appeared and I can't find it in system settings.
After google search, I know that USB Mass Storge mode is replaced by MTP/PTP mode.
I found a post and followed it to mount my HOX.
But aways fail.
I can't post URL here.
HTML:
sudo mtp-detect
libmtp version: 1.1.5
Listing raw device(s)
Device 0 (VID=0bb4 and PID=0df6) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team
Found 1 device(s):
0bb4:0df6 @ bus 1, dev 57
Attempting to connect device(s)
PTP_ERROR_IO: failed to open session, trying again after resetting USB interface
LIBMTP libusb: Attempt to reset device
LIBMTP PANIC: failed to open session on second attempt
Unable to open raw device 0
OK.
Does anyone successfully mount HOX external store under ubuntu linux after update to JellyBean?
You should ask ubuntu to make drivers for hox in MTP mode, or mount the usb in a custom recovery
I didn't use linux for a long time,
trulyliu said:
I am an Ubuntu Linux user. I am now using ubuntu 12.10.
Just upgraded my HOX to JellyBean via OTA.
When I connect HOX to computer via USB cable,
'Mount USB Mass Storea' option is not appeared and I can't find it in system settings.
After google search, I know that USB Mass Storge mode is replaced by MTP/PTP mode.
I found a post and followed it to mount my HOX.
But aways fail.
I can't post URL here.
HTML:
sudo mtp-detect
libmtp version: 1.1.5
Listing raw device(s)
Device 0 (VID=0bb4 and PID=0df6) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team
Found 1 device(s):
0bb4:0df6 @ bus 1, dev 57
Attempting to connect device(s)
PTP_ERROR_IO: failed to open session, trying again after resetting USB interface
LIBMTP libusb: Attempt to reset device
LIBMTP PANIC: failed to open session on second attempt
Unable to open raw device 0
OK.
Does anyone successfully mount HOX external store under ubuntu linux after update to JellyBean?
Click to expand...
Click to collapse
I have the same probem, i find this 2 posts, i didn't try it yet....
http://sourceforge.net/p/libmtp/bugs/663/
In the last post the people of libmtp add HOX to the mtp devices and the put it in the GIT, so you will have to compile it from the source
https://gist.github.com/3884439
in this one, they offer a solution to connect it, albeit, probably you have to compile it anyway.
If you make it, post it here, i will do the same...
in this one, they offer a solution to connect it, albeit, probably you have to compile it anyway.
If you make it, post it here, i will do the same...[/QUOTE]
I compiled libmtp and go-mtpfs.
Still doesn't work.
Hi mates,
Kubuntu 12.10 here. Attaching HOX (JB 3.14.401.27) to my PC works out of the box.
It appears (and gets automatically mounted) as "portable media player", and I can open it with any file explorer (i use dolphin).
Strange that you can't make it work on ubuntu. Finally, I don't know whether it is relevant or not, but I have a simple udev rule for allowing HTC devices (0bb4, it was necessary for using adb).
trulyliu said:
I am an Ubuntu Linux user. I am now using ubuntu 12.10.
Just upgraded my HOX to JellyBean via OTA.
When I connect HOX to computer via USB cable,
'Mount USB Mass Storea' option is not appeared and I can't find it in system settings.
After google search, I know that USB Mass Storge mode is replaced by MTP/PTP mode.
I found a post and followed it to mount my HOX.
But aways fail.
I can't post URL here.
HTML:
sudo mtp-detect
libmtp version: 1.1.5
Listing raw device(s)
Device 0 (VID=0bb4 and PID=0df6) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team
Found 1 device(s):
0bb4:0df6 @ bus 1, dev 57
Attempting to connect device(s)
PTP_ERROR_IO: failed to open session, trying again after resetting USB interface
LIBMTP libusb: Attempt to reset device
LIBMTP PANIC: failed to open session on second attempt
Unable to open raw device 0
OK.
Does anyone successfully mount HOX external store under ubuntu linux after update to JellyBean?
Click to expand...
Click to collapse
If you're on custom recovery
Have you tried:
1. Boot into recovery
2. Connect USB
3. Mount Storage under mount section
Work'd for me and it saved my phone from brick.
poisonwell said:
If you're on custom recovery
Have you tried:
1. Boot into recovery
2. Connect USB
3. Mount Storage under mount section
Work'd for me and it saved my phone from brick.
Click to expand...
Click to collapse
This also did work for me.

[Q] Data transfer via MTP on ubuntu

Hi there,
has anyone tried to use the MTP file transfer option of the Fairphone with Ubuntu (I'm using 13.04 at the moment). It seems that the phone is recognized by my system:
Code:
[49875.145923] usb 1-1.2: new high-speed USB device number 12 using ehci-pci
[49875.240046] usb 1-1.2: New USB device found, idVendor=0bb4, idProduct=0c02
[49875.240057] usb 1-1.2: New USB device strings: Mfr=2, Product=3, SerialNumber=4
[49875.240063] usb 1-1.2: Product: MT65xx Android Phone
[49875.240068] usb 1-1.2: Manufacturer: MediaTek
[49875.240072] usb 1-1.2: SerialNumber: ...
but the device is not shown in Nautilus.
Who knows how to fix that?
Thanks,
Tobi
prinz.z said:
Hi there,
has anyone tried to use the MTP file transfer option of the Fairphone with Ubuntu (I'm using 13.04 at the moment). It seems that the phone is recognized by my system. but the device is not shown in Nautilus.
Who knows how to fix that?
Thanks,
Tobi
Click to expand...
Click to collapse
I guess this is more an Ubuntu issue/question than Fairphone's..
You can follow instructions here
Code:
$ sudo mtpfs -o allow_other /media/MTPdevice
Unable to open ~/.mtpz-data for reading, MTPZ disabled.Listing raw device(s)
Device 0 (VID=0bb4 and PID=2008) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team
Found 1 device(s):
0bb4:2008 @ bus 2, dev 20
Attempting to connect device
Android device detected, assigning default bug flags
Listing File Information on Device with name: FP1
Nautilus gave me read-only access to content under the custom mount point /media/MTPdevice. dmesg gave me the same log as yours when recognizing the device...
It doesn't work for me either. But this is an issue that is usual in Ubuntu. Even though it is not an issue in Ubuntu.
* libMTP with a detailed description
* gvfs-mtp
* go-mtpfs
I use either the USB storage or PTP.
(MTP is buggy.)
Okay, I see.. With my former phone (LG O4x, cm-11) it was working flawlessly with mtp on Ubuntu, that's the rason I asked.. With the fairphone, I'm simply using adb for the moment to copy single files..
elchi1234 said:
It doesn't work for me either. But this is an issue that is usual in Ubuntu. Even though it is not an issue in Ubuntu.
* libMTP with a detailed description
* gvfs-mtp
* go-mtpfs
I use either the USB storage or PTP.
(MTP is buggy.)
Click to expand...
Click to collapse

VK815 rooting help

I've seen reports of the VK815 being rooted and would like to root mine. Is there someone who has a VK815 and has rooted it who is willing to share how they accomplished it?
I have 'adb' available and working, the developer mode enabled, and can talk to the phone. Trying to attain superuser from the 'adb shell' doesn't work because the 'su binary' is missing. 'adb reboot recovery' gives the ''dead android' and the 'power/volume -' key combination results in a normal boot.
Thanks,
Jim
I rooted my vk815 with one click root from the g3 section. Not sure yet how to post links I'm new to xda...
---------- Post added at 12:56 AM ---------- Previous post was at 12:49 AM ----------
http://forum.xda-developers.com/showthread.php?t=3056951
That looks like a solution for those who have Windows PC's connected to their tablets. I'm a linux only and should have put that in my original post.
I guess I could look at the script and see if there's any clues inside it.
Thanks,
Jim
There is a python script for using the send command with the files. On my phone and at work, so difficult for me to look up, but I'm sure googling send command LG python will turn it up (probably under g3 or g4 forums...)
danaff37 said:
There is a python script for using the send command with the files. On my phone and at work, so difficult for me to look up, but I'm sure googling send command LG python will turn it up (probably under g3 or g4 forums...)
Click to expand...
Click to collapse
I've seen it and given it a try. The writer and everyone else in the thread look like they aren't working with a VK815. The VK815 doesn't trigger loading of the 'serial' module. I don't have one on my system so that looks like a problem. I keep getting this error message:
[email protected]:/root# qcdlcomm.py /dev/ttyUSB0
Traceback (most recent call last):
File "/home/jim/Desktop/qcdlcomm.py", line 13, in <module>
import serial
ImportError: No module named serial
For anyone who's interested; the python script is here about a quarter of the way down the page. hxxp://forum.xda-developers.com/android/development/guide-root-method-lg-devices-t3049772/page46 (Change the x's to t's)
Jim
Seems like the kernel can't figure out what chip is handling the serial I/O for the tablet so it only loads 'usbserial_generic'. That module can't change any of the comm parameters. The error messages now want a more specific module loaded before running the python script.
[1655862.790132] usb 1-9: new high-speed USB device number 9 using ehci-pci
[1655862.905356] usb 1-9: New USB device found, idVendor=1004, idProduct=6293
[1655862.905359] usb 1-9: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[1655862.905361] usb 1-9: Product: LGE Android Phone
[1655862.905363] usb 1-9: Manufacturer: LG Electronics Inc.
[1655862.905365] usb 1-9: SerialNumber: VK815275a2846
[1655862.905753] usbserial_generic 1-9:1.0: The "generic" usb-serial driver is only for testing and one-off prototypes.
[1655862.905755] usbserial_generic 1-9:1.0: Tell [email protected] to add your device to a proper driver.
[1655862.905757] usbserial_generic 1-9:1.0: generic converter detected
[1655862.905816] usb 1-9: generic converter now attached to ttyUSB0
[1655862.946215] usb 1-9: usbfs: process 29489 (pool) did not claim interface 0 before use
[1655862.946343] generic ttyUSB0: generic converter now disconnected from ttyUSB0
[1655862.946356] usbserial_generic 1-9:1.0: device disconnected
[1655863.049404] usb 1-9: reset high-speed USB device number 9 using ehci-pci
[1655863.164195] usbserial_generic 1-9:1.0: The "generic" usb-serial driver is only for testing and one-off prototypes.
[1655863.164201] usbserial_generic 1-9:1.0: Tell [email protected] to add your device to a proper driver.
[1655863.164203] usbserial_generic 1-9:1.0: generic converter detected
[1655863.164288] usb 1-9: generic converter now attached to ttyUSB0
[1655863.164329] usb 1-9: usbfs: process 29489 (pool) did not claim interface 0 before use
Jim
jowski said:
Seems like the kernel can't figure out what chip is handling the serial I/O for the tablet so it only loads 'usbserial_generic'. That module can't change any of the comm parameters. The error messages now want a more specific module loaded before running the python script.
[1655862.790132] usb 1-9: new high-speed USB device number 9 using ehci-pci
[1655862.905356] usb 1-9: New USB device found, idVendor=1004, idProduct=6293
[1655862.905359] usb 1-9: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[1655862.905361] usb 1-9: Product: LGE Android Phone
[1655862.905363] usb 1-9: Manufacturer: LG Electronics Inc.
[1655862.905365] usb 1-9: SerialNumber: VK815275a2846
[1655862.905753] usbserial_generic 1-9:1.0: The "generic" usb-serial driver is only for testing and one-off prototypes.
[1655862.905755] usbserial_generic 1-9:1.0: Tell [email protected] to add your device to a proper driver.
[1655862.905757] usbserial_generic 1-9:1.0: generic converter detected
[1655862.905816] usb 1-9: generic converter now attached to ttyUSB0
[1655862.946215] usb 1-9: usbfs: process 29489 (pool) did not claim interface 0 before use
[1655862.946343] generic ttyUSB0: generic converter now disconnected from ttyUSB0
[1655862.946356] usbserial_generic 1-9:1.0: device disconnected
[1655863.049404] usb 1-9: reset high-speed USB device number 9 using ehci-pci
[1655863.164195] usbserial_generic 1-9:1.0: The "generic" usb-serial driver is only for testing and one-off prototypes.
[1655863.164201] usbserial_generic 1-9:1.0: Tell [email protected] to add your device to a proper driver.
[1655863.164203] usbserial_generic 1-9:1.0: generic converter detected
[1655863.164288] usb 1-9: generic converter now attached to ttyUSB0
[1655863.164329] usb 1-9: usbfs: process 29489 (pool) did not claim interface 0 before use
Jim
Click to expand...
Click to collapse
I doubt there are drivers for linux for a g4 in Linux, and I know people used the script for that. You are doing this in download mode? I can't remember since it's been a while for me setting it up, but does the Android sdk install the generic android USB drivers in Linux?
danaff37 said:
I doubt there are drivers for linux for a g4 in Linux, and I know people used the script for that. You are doing this in download mode? I can't remember since it's been a while for me setting it up, but does the Android sdk install the generic android USB drivers in Linux?
Click to expand...
Click to collapse
The kernel modules handle what drivers would do in Windows.
I'm in the download mode and if I boot normally instead of into download; I can talk to the tablet with adb. I'm thinking that maybe if I comment out the serial port settings code, the script might work. I'll try that later.
Jim
jowski said:
The kernel modules handle what drivers would do in Windows.
I'm in the download mode and if I boot normally instead of into download; I can talk to the tablet with adb. I'm thinking that maybe if I comment out the serial port settings code, the script might work. I'll try that later.
Jim
Click to expand...
Click to collapse
I just know in the past for fast boot mode on other devices, I had to run the Android sdk tools and add some udev rules. But I can't remember if the sdk tools was simply for executables, or for modules/drivers
danaff37 said:
I just know in the past for fast boot mode on other devices, I had to run the Android sdk tools and add some udev rules. But I can't remember if the sdk tools was simply for executables, or for modules/drivers
Click to expand...
Click to collapse
When I can talk to the tablet; adb works but fastboot doesn't. 'adb reboot recovery' gives the dead android. This is turning into a real adventure.
There has to be something after 'modprobe usbserial' to load a specific module on the PC so it can talk to the VK815. Would the Windows ddl's give a clue?
Jim
Well, I'll be go to ....
Commenting the block of code that sets the serial port settings worked! I went into the download mode with the key press (power off, volume +, connect the usb cable, wait for Firmware Update screen, release volume +) and ran the script and was talking to the tablet. Looks like the next step is to load the goodies first and then try the manual commands to install root.
Whatcha think gang? I'm thinking we're almost there and how cool is that!!!
Jim
edit: [email protected]:/# ./qcdlcomm.py /dev/ttyUSB0
Traceback (most recent call last):
File "qcdlcomm.py", line 47, in <module>
port=sys.argv[-1]
File "/usr/lib64/python2.7/site-packages/serial/serialutil.py", line 282, in __init__
self.open()
File "/usr/lib64/python2.7/site-packages/serial/serialposix.py", line 296, in open
self._reconfigurePort()
File "/usr/lib64/python2.7/site-packages/serial/serialposix.py", line 325, in _reconfigurePort
raise SerialException("Could not configure port: %s" % msg)
serial.serialutil.SerialException: Could not configure port: (25, 'Inappropriate ioctl for device')
Any ideas??? I changed the 'ser' block to
ser = serial.Serial(
port=sys.argv[-1]
)
I'm back to thinking it's a module that needs to be loaded.
Previous post errors were due to 'cdc_acm' being reloaded and me not checking that before running the script. Fixed that and reloaded usbserial. Now the errors are:
[email protected]:# qcdlcomm.py /dev/ttyUSB0
Special commands: ENTER, LEAVE, exit
# ENTER
Traceback (most recent call last):
File "/home/jim/Desktop/qcdlcomm.py", line 100, in <module>
cmd(input)
File "/home/jim/Desktop/qcdlcomm.py", line 87, in cmd
rawcmd(commands[input])
File "/home/jim/Desktop/qcdlcomm.py", line 63, in rawcmd
ser.write(input)
File "/usr/lib64/python2.7/site-packages/serial/serialposix.py", line 490, in write
if not self._isOpen: raise portNotOpenError
serial.serialutil.SerialException: Attempting to use a port that is not open
So much for talking to the tablet.
Jim
I tried usb_modeswitch and got something that may be encouraging. I'll post the command and output so someone who knows a bit about usb_modeswitch can shed some light.
[email protected]:/home/jim/Desktop# usb_modeswitch -p 0x6293 -v 0x1004 -M a1
Look for default devices ...
product ID matched
Found devices in default mode (1)
Access device 067 on bus 001
Get the current device configuration ...
OK, got current device configuration (1)
Use interface number 0
Use endpoints 0x01 (out) and 0x81 (in)
Not a storage device, skip SCSI inquiry
USB description data (for identification)
-------------------------
Manufacturer: LG Electronics Inc.
Product: LGE Android Phone
Serial No.: VK815275a2846
-------------------------
Looking for active driver ...
OK, driver detached
Set up interface 0
Use endpoint 0x01 for message sending ...
Trying to send message 1 to endpoint 0x01 ...
Sending the message returned error -1. Try to continue
Reset response endpoint 0x81
Reset message endpoint 0x01
Could not reset endpoint (probably harmless): -99
-> Run lsusb to note any changes. Bye!
There are other messages that can be sent as part of the command. I'm wondering if this is how we can gain access to the device using linux.
Jim
Tried the windows method from an XP machine. Keep getting a "Device cannot start. (Code 10)" error. Tried uninstalling and reinstalling the LG drivers along with the VZW drivers. Also tried using only the VZW drivers. Same results. The device manager says the DIAG port is COM16 but Send_Command.exe can't open port 16.
Anyone had success rooting from XP or do I need to try Windows 7?
Jim
jowski said:
Tried the windows method from an XP machine. Keep getting a "Device cannot start. (Code 10)" error. Tried uninstalling and reinstalling the LG drivers along with the VZW drivers. Also tried using only the VZW drivers. Same results. The device manager says the DIAG port is COM16 but Send_Command.exe can't open port 16.
Anyone had success rooting from XP or do I need to try Windows 7?
Jim
Click to expand...
Click to collapse
I tried XP but the device drivers wouldn't install. 7 worked great for me tho. But I'm not real good with Windows possibly some others would know better??
So my tablet today prompted me to update to 11A. But since it's rooted, so it didn't go thru. Does anyone know what we can do with that info? Like to keep root and update?
I gave up on finding a linux solution and did it with WinDoze 8. A root canal has to be less painful. At least it's rooted now.
I'm holding off on the update until after I get a few apps loaded that require root access. I wish there was a way to turn off the updates and nags.
Jim
I think the linux answer to talking to the VK815 involves the BCM2079x on the tablet. Could that mean the linux box trying to load a serial driver would need to do something like 'modprobe bcm2079x'? If so, where to we find the config for it in the kernel .config?
Jim
I know this is an old thread, but maybe someone can send me in the right direction. My non-rooted VK815 updated to 6.0 and ruined the battery life. So, I'd like to root it. I can only find threads on rooting the previous version - has anyone rooted the 6.0 version?

MTP is not work properly in Ubuntu

I connect Google Pixel with my PC (Ubuntu 14.04), and select MTP mode. I can browser the files in Google Pixel via file manager nautilusk, but I got the error message "libmtp error could not get file from device." when trying to copy files from Pixel to PC. I research in web, someone say is old libmtp bug, so I update libmtp to 1.1.13.
then I execute mtp-connect command, got the following message.
$ mtp-connect
Unable to open ~/.mtpz-data for reading, MTPZ disabled.libmtp version: 1.1.13
Device 0 (VID=18d1 and PID=4ee1) is a Google Inc (for LG Electronics/Samsung) Nexus 4/5/7/10 (MTP).
ignoring libusb_claim_interface() = -6PTP_ERROR_IO: failed to open session, trying again after resetting USB interface
LIBMTP libusb: Attempt to reset device
LIBMTP PANIC: failed to open session on second attempt
No devices.​
I remember I ever copy files between My PC and Pixel successfully before. Do anyone ever encounter this problem?

Categories

Resources