Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,808,781 Members 48,616 Now Online
XDA Developers Android and Mobile Development Forum

[MODULES][ARC][NEO][FW:4.0.A.2.368] USB-OTG {Storage, Keyboard & Mouse}

Tip us?
 
DooMLoRD
Old
(Last edited by DooMLoRD; 22nd August 2011 at 11:58 AM.)
#1  
DooMLoRD's Avatar
Recognized Developer - OP
Thanks Meter 38,373
Posts: 13,058
Join Date: Jul 2010
Location: Noida
Angry [MODULES][ARC][NEO][FW:4.0.A.2.368] USB-OTG {Storage, Keyboard & Mouse}

GUYS I BRING GREAT NEWS!

WE NOW HAVE FUNCTIONAL USB-OTG SUPPORT!



[ screenshots ]







[ WARNING ]

do not use the connected device for a LONG time period... u may risk burning the device chip/motherboard due to the voltage supply in host mode...

u have been warned!




[ requirements ]
  1. Xperia Arc (Neo?/Play?) on FW: 4.0.A.2.368
  2. preferably rooted + busybox installed
  3. USB-OTG hardware cable
  4. Terminal Emulator app
  5. [OPTIONAL] adb Wireless app


[ tested on ]

Xperia Arc Stock FW: 4.0.A.2.368 with DooMKernel v08




[ how to ] (general instructions for modules) [u can use this app to auto-load module]
  1. download the modules and push the modules to /system/lib/modules/

  2. use adb shell or terminal emulator to enter following code/commands

  3. Code:
    su
    cd/system/lib/modules/
    busybox insmod usbhid.ko
    busybox insmod usbmouse.ko
    busybox insmod usbkbd.ko
    busybox insmod usb-storage.ko
  4. check if all modules are live are not:
    Code:
    lsmod


  5. done the modules are LIVE!
  6. [IMP] u will have to manually reload the modules on EVERY boot... unless u use start-up scripts which will take care of this!


[ how to ] (instructions for usb-storage) [simpler way]
  1. download app: http://android.gval.biz/download/Q5_...ry_Manager.apk
  2. follow instructions: http://android.gval.biz/Q5_USB_Menory_Manager.php
  3. the usb storage device should now be mounted to /usb_storage/
  4. u will need to use RootExplorer for this to work



[ how to ] (instructions for usb-storage) [manual way]
  • before u begin/connect device there are few things which need to be done

  • creating necessary directory structure
    Code:
    su
    cd /sdcard/
    mkdir usbStorage
    chmod 777 usbStorage
  • now connect the usb storage device via usb-otg cable to phone
  • now enter the following command:
    Code:
    dmesg
  • at the last part u will see some info of connected device (an if it was rejected due to power issues)


  • now enter
    Code:
    ls -l /dev/block/sd*
  • u will get output similar to the one posted below

    note if the last part: /dev/block/sda1

  • finally mount this device (following is generic command... for NTFS specific command read this post)

    Code:
    mount /dev/block/sda1 /sdcard/usbStorage
  • if u get no error then enjoy usb storage is now mounted

  • to unmount usbstorage (following is generic command)
    Code:
    umount /dev/block/sda1
    if that doesnt work try the following command: (this will try to force unmount)

    Code:
    umount -f /dev/block/sda1
    if that doesnt work try the following commandthis will try to force unmount and remove loop) [use this as LAST resort]

    Code:
    umount -f -l /dev/block/sda1


[ donations ]

if u feel that this work has helped u OR u think that the work i put into making this is worthy of donations, then click on the following link for buying me some coffee/beer/etc

PAYPAL DONATION LINK


[ download links ]
  1. USB-STORAGE
  2. USB-HID
  3. USB-KEYBOARD
  4. USB-MOUSE



[ known issues ]
  1. usb mouse works but there is no cursor... but u can move around and select (left click on stuff)
  2. when using usb-storage mode some devices will not be mountable if:
    • they require more power (u can check this in dmesg)
    • they have filesystem not supported by ur current kernel
  3. sometimes the mounted usb-storage files wont appear using some apps... i have tested it to be wrking using RootExplorer... though it will work in adb shell/terminal emulator also...


[ troubleshooting ]

when u post any error/issue please include the full output of dmesg command (adb shell dmesg > dmesg_log.txt) OR (dmesg > /sdcard/dmesg_log.txt)


P.S.: all these features will be included in next version of DooMKernel for all supported Xperia 2011 devices




enjoy!
The Following 33 Users Say Thank You to DooMLoRD For This Useful Post: [ Click to Expand ]
 
DooMLoRD
Old
#2  
DooMLoRD's Avatar
Recognized Developer - OP
Thanks Meter 38,373
Posts: 13,058
Join Date: Jul 2010
Location: Noida
reserved reserved
The Following 3 Users Say Thank You to DooMLoRD For This Useful Post: [ Click to Expand ]
 
sahha
Old
#3  
Senior Member
Thanks Meter 51
Posts: 139
Join Date: Jul 2009
Location: medina
Good

can u add more

Example

 
Soheil_rf
Old
#4  
Soheil_rf's Avatar
Senior Member
Thanks Meter 878
Posts: 431
Join Date: Jul 2009
Location: Tehran
Thank you very much DooMLoRD
The Following User Says Thank You to Soheil_rf For This Useful Post: [ Click to Expand ]
 
Ambroos
Old
#5  
Senior Member
Thanks Meter 905
Posts: 1,388
Join Date: Aug 2010
Location: Leuven / Sint-Truiden
Oh my god, it actually works Tried with my Microsoft Wireless Desktop thing with a wireless receiver. Couldn't get the keyboard to work, but the mouse works perfectly!
Sony Xperia Z2 - D6503, black
Sony Xperia Tablet Z LTE - SGP321, black
Sony Xperia Z1 - C6903, black, backup

Huge Sony (Ericsson) fan.
J210i, K320i, G705, Arc, Elm, Neo, Arc S, Xperia S, Xperia T, Xperia Z, Xperia Z1, Xperia Tablet Z, Xperia Z2
 
inteks
Old
#6  
inteks's Avatar
Senior Member
Thanks Meter 730
Posts: 1,083
Join Date: Oct 2006

 
DONATE TO ME
<3>[39396.128906] NTFS-fs error (device sda1): parse_options(): Unrecognized mount option shortname.
<3>[39396.128906] NTFS-fs warning (device sda1): parse_options(): Option utf8 is no longer supported, using option nls=utf8. Please use option nls=utf8 in the future and make sure utf8 is compiled either as a module or into the kernel.
<3>[39396.129943] NTFS-fs error (device sda1): parse_options(): NLS character set utf8 not found.
#

cant mount usbstick on neo :(

Sent from my MT15i using Tapatalk
 
DooMLoRD
Old
#7  
DooMLoRD's Avatar
Recognized Developer - OP
Thanks Meter 38,373
Posts: 13,058
Join Date: Jul 2010
Location: Noida
Quote:
Originally Posted by inteks View Post
<3>[39396.128906] NTFS-fs error (device sda1): parse_options(): Unrecognized mount option shortname.
<3>[39396.128906] NTFS-fs warning (device sda1): parse_options(): Option utf8 is no longer supported, using option nls=utf8. Please use option nls=utf8 in the future and make sure utf8 is compiled either as a module or into the kernel.
<3>[39396.129943] NTFS-fs error (device sda1): parse_options(): NLS character set utf8 not found.
#

cant mount usbstick on neo :(

Sent from my MT15i using Tapatalk
but are the modules getting inserted properly?

wht does lsmod say?

also which kernel are u using?
 
inteks
Old
#8  
inteks's Avatar
Senior Member
Thanks Meter 730
Posts: 1,083
Join Date: Oct 2006

 
DONATE TO ME
Im using your latest kernel for neo. Lsmod is ok all modules are loaded. I think it because of missing utf8 in kernel.

Btw im tzping this on an connect usb keyboard , that works so far ;o) (but kezmapping...)

Btw. My usbgamepad does NOT work with FPSE ;)
Here the dmesg output

<6>[40873.999359] hub 1-0:1.0: USB hub found
<6>[40873.999420] hub 1-0:1.0: 1 port detected
<6>[40874.316741] usb 1-1: new low speed USB device using msm_hsusb_host and address 2
<3>[40874.475799] usb 1-1: device v0583 p2060 is not supported
<6>[40874.475921] usb 1-1: New USB device found, idVendor=0583, idProduct=2060
<6>[40874.476013] usb 1-1: New USB device strings: Mfr=0, Product=2, SerialNumber=0
<6>[40874.476104] usb 1-1: Product: USB,2-axis 8-button gamepad
<6>[40874.488586] usb 1-1: configuration #1 chosen from 1 choice
<6>[40874.501922] input: USB,2-axis 8-button gamepad as /devices/platform/msm_hsusb_host.0/usb1/1-1/1-1:1.0/input/input9
<6>[40874.502075] generic-usb 0003:0583:2060.0001: input: USB HID v1.10 Joystick [USB,2-axis 8-button gamepad ] on usb-msm_hsusb_host.0-1/input0
#
#

Sent from my MT15i using Tapatalk
 
DooMLoRD
Old
#9  
DooMLoRD's Avatar
Recognized Developer - OP
Thanks Meter 38,373
Posts: 13,058
Join Date: Jul 2010
Location: Noida
Quote:
Originally Posted by sahha View Post
Good

can u add more
i think that device will require a lot of power (to transmit/receive)... so it might not work...


Quote:
Originally Posted by Ambroos View Post
Oh my god, it actually works Tried with my Microsoft Wireless Desktop thing with a wireless receiver. Couldn't get the keyboard to work, but the mouse works perfectly!
only low-power devices are supported... try using a power USB hub...


Quote:
Originally Posted by inteks View Post
Im using your latest kernel for neo. Lsmod is ok all modules are loaded. I think it because of missing utf8 in kernel.

Btw im tzping this on an connect usb keyboard , that works so far ;o) (but kezmapping...)

Btw. My usbgamepad does NOT work with FPSE ;)
Here the dmesg output

<6>[40873.999359] hub 1-0:1.0: USB hub found
<6>[40873.999420] hub 1-0:1.0: 1 port detected
<6>[40874.316741] usb 1-1: new low speed USB device using msm_hsusb_host and address 2
<3>[40874.475799] usb 1-1: device v0583 p2060 is not supported
<6>[40874.475921] usb 1-1: New USB device found, idVendor=0583, idProduct=2060
<6>[40874.476013] usb 1-1: New USB device strings: Mfr=0, Product=2, SerialNumber=0
<6>[40874.476104] usb 1-1: Product: USB,2-axis 8-button gamepad
<6>[40874.488586] usb 1-1: configuration #1 chosen from 1 choice
<6>[40874.501922] input: USB,2-axis 8-button gamepad as /devices/platform/msm_hsusb_host.0/usb1/1-1/1-1:1.0/input/input9
<6>[40874.502075] generic-usb 0003:0583:2060.0001: input: USB HID v1.10 Joystick [USB,2-axis 8-button gamepad ] on usb-msm_hsusb_host.0-1/input0
#
#

Sent from my MT15i using Tapatalk
have u tried v6?
http://forum.xda-developers.com/show...l#post16651299

it has NLS-UTF8 support

about gamepads i dont know... will have to look into it... but neither do i have the xperia neo nor the usb gamepad
The Following 2 Users Say Thank You to DooMLoRD For This Useful Post: [ Click to Expand ]
 
inteks
Old
#10  
inteks's Avatar
Senior Member
Thanks Meter 730
Posts: 1,083
Join Date: Oct 2006

 
DONATE TO ME
Quote:
Originally Posted by DooMLoRD View Post
i think that device will require a lot of power (to transmit/receive)... so it might not work...




only low-power devices are supported... try using a power USB hub...




have u tried v6?
http://forum.xda-developers.com/show...l#post16651299

it has NLS-UTF8 support

about gamepads i dont know... will have to look into it... but neither do i have the xperia neo nor the usb gamepad

flashed the new kernel (v6) but still cant mount ntfs ubsstick. (i dont have a fat32 stick here to test)

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes