LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices


Reply
  Search this Thread
Old 09-30-2011, 09:23 AM   #1
sodjas
LQ Newbie
 
Registered: Sep 2011
Posts: 1

Rep: Reputation: Disabled
Usb otg + ft232r


Hi guys,

I'm working with an OTG capable Archos 70 IT Android device. And I'm trying to make it work with an attached FT232R chip to be able to read RFID cards on serial port.

The problem is that the role switching only work if I attach first only the OTG cable and after that the FT232R. So ifa soft reboot occur it won't go to host mode...

I have a self powered FTDI(FT232R) <-> micro USB-A (Nokia OTG CA-157) <-> Archos 70
with custom kernel. It works like a charm BUT
The driver picks the FT232R only if I connect it in the following sequence:
1. First connect the micro USB-A dongle (FT232 not attached)
2. As second connect FT232R to the USB dongle
Then I got the following dmesg:
1.



Code:
usb_switch_print_state: 3 ATTACHED_HOST

usb_switch_print_state: 3 ATTACHED_HOST

twl4030_usb twl4030_usb: regulator_enable twl4030_usb-usb1v5 enabled 0
twl4030_usb twl4030_usb: regulator_enable twl4030_usb-usb1v8 enabled 0
twl4030_usb twl4030_usb: regulator_enable twl4030_usb-usb3v1 enabled 0
musb_hdrc: version 6.0, musb-dma, peripheral, debug=0
twl4030_usb twl4030_usb: regulator_enable twl4030_usb-usb3v1 enabled 1
twl4030_usb twl4030_usb: regulator_enable twl4030_usb-usb1v8 enabled 1
twl4030_usb twl4030_usb: regulator_enable twl4030_usb-usb1v5 enabled 1
musb_hdrc: USB Host mode controller at fa0ab000 using DMA, IRQ 92
musb_hdrc musb_hdrc: MUSB HDRC host driver
/home/archos/kernel/gen8/gen8-gpl-froyo/linux/drivers/usb/core/inode.c: creating file '002'
musb_hdrc musb_hdrc: new USB bus registered, assigned bus number 2
usb usb2: default language 0x0409
usb usb2: New USB device found, idVendor=1d6b, idProduct=0002
usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
usb usb2: Product: MUSB HDRC host driver
usb usb2: Manufacturer: Linux 2.6.29-omap1 musb-hcd
usb usb2: SerialNumber: musb_hdrc
usb usb2: uevent
usb usb2: usb_probe_device
usb usb2: configuration #1 chosen from 1 choice
usb usb2: adding 2-0:1.0 (config #1, interface 0)
usb 2-0:1.0: uevent
hub 2-0:1.0: usb_probe_interface
hub 2-0:1.0: usb_probe_interface - got id
hub 2-0:1.0: USB hub found
hub 2-0:1.0: 1 port detected
hub 2-0:1.0: standalone hub
hub 2-0:1.0: individual port power switching
hub 2-0:1.0: no over-current protection
hub 2-0:1.0: power on to power good time: 10ms
hub 2-0:1.0: 100mA bus power budget for each child
hub 2-0:1.0: local power source is good
hub 2-0:1.0: enabling power on all ports
/home/archos/kernel/gen8/gen8-gpl-froyo/linux/drivers/usb/core/inode.c: creating file '001'
hub 2-0:1.0: state 7 ports 1 chg 0000 evt 0000
hub 2-0:1.0: hub_suspend
usb usb2: bus auto-suspend


2.

Code:
usb usb2: usb resume
hub 2-0:1.0: hub_resume
hub 2-0:1.0: port 1: status 0101 change 0001
hub 2-0:1.0: state 7 ports 1 chg 0002 evt 0000
hub 2-0:1.0: port 1, status 0101, change 0000, 12 Mb/s
usb 2-1: new full speed USB device using musb_hdrc and address 2
usb 2-1: ep0 maxpacket = 8
usb 2-1: default language 0x0409
usb 2-1: New USB device found, idVendor=0403, idProduct=6001
usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 2-1: Product: RFID_EM
usb 2-1: Manufacturer: FTDI
usb 2-1: SerialNumber: A9UMG98I
usb 2-1: uevent
usb 2-1: usb_probe_device
usb 2-1: configuration #1 chosen from 1 choice
usb 2-1: adding 2-1:1.0 (config #1, interface 0)
usb 2-1:1.0: uevent
usbserial_generic 2-1:1.0: usb_probe_interface
usbserial_generic 2-1:1.0: usb_probe_interface - got id
ftdi_sio 2-1:1.0: usb_probe_interface
ftdi_sio 2-1:1.0: usb_probe_interface - got id
ftdi_sio 2-1:1.0: FTDI USB Serial Device converter detected
usb 2-1: Detected FT232RL
usb 2-1: FTDI USB Serial Device converter now attached to ttyUSB0
/home/archos/kernel/gen8/gen8-gpl-froyo/linux/drivers/usb/core/inode.c: creating file '002'
hub 2-0:1.0: 100mA power budget left
hub 2-0:1.0: state 7 ports 1 chg 0000 evt 0002
hub 2-0:1.0: port 1 enable change, status 00000103



This is a very verbose fine dmesg showing ttyUSB0 is created.

My problem is that if I connect the micro-A dongle with FT232R already connected, then just the 1st sequence runs (till bus suspend) the second not. The same thing is with soft reboot, it is not working I need to manually disconnect then connect dongle first then FT232R.

I tried to tune msusb_hdrc config but with no sucess. What is the problem, what causes to stuck at suspend when it is not attached in 2 step??????
Please give some yoda answers

Here is the HW I'm talking about:
http://img687.imageshack.us/img687/7991/photoihm.jpg
By sodjas at 2011-09-30

Thanks, cheers
sodjas
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] What is snpsid in USB OTG ? elonica.pl Linux - Hardware 1 07-05-2011 06:57 AM
Can USB Host stack for OTG and OHCI HCD be same zaks_974 Programming 0 06-10-2011 05:35 AM
USB-OTG device mode - Unable to load g_file_storage.ko Padmasri Linux - Software 2 08-19-2010 12:53 AM
Has someone tried any USB 2.0 OTG throughput optimization? iWeston Linux - Kernel 1 07-24-2008 06:51 AM
USB to serial Convertor FT232R Misbah Naveed Linux - Newbie 0 06-25-2008 10:40 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 12:19 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration