Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Vinculum not "seeing" through USB hub

Status
Not open for further replies.

jgharston

New Member
I'm using a FTDI Vinculum VDPS (disk, PC, slave) USB controller.
I can access and control devices plugged directly into the Vinculum USB port. When enumerated with QueryDevice they appear as device 0. I select them with SelectDevice 0 and everything works as expected.
When I try with devices plugged in through a hub, the hub appears as device 0 and the other devices appear as devices 1+. However, trying to communicate with them fails. I select them with SelectDevice n, which succeeds, but then, eg, DeviceReadData gives Command Failed.
Is this something people have come across? Am I missing something? I've tested the devices and hub plugged into my Windows PC and everything works as expected.

Some details:
Keyboard plugged directly into USB port.
Send SCS,13,IPH,13,QP2,13,SC,32,0,13 ; ShortCommandSet, IOHex, QueryPort2, SelectCurrent 0
'Ok' replies to all
Send DRD,13 ; DeviceReadData
8-byte keyboard packet returned.

Keyboard plugged into hub plugged into USB port.
Send QD,32,1,13
Returns 32-byte packet saying 'keyboard' and 'device 1'
Send SCS,13,IPH,13,QP2,13,SC,32,1,13 ; SelectCurrent 1
'Ok' replies to all
Send DRD,13 ; DeviceReadData
Responds 'Command failed'
 
Some speculative purchases and more testing reveals a few things.

I bought a second-hand Dell keyboard which had a card reader on it. This shows up in my USBDevices program as HID (Keyboard) and UKN (Other). It works directly, and works through a hub.
On a hunch I plugged my first two keyboards into a USB-PS2 plug, and they worked plugged into a PS2 keyboard socket on my PC. The Dell did not. This rang a bell.

Those keyboards that have a USB plug but can be plugged via an adaptor into a PS2 socket are actually PS2 keyboards that detect if thay are plugged into a USB socket and masquarade a stripped-down USB protocol. A faint memory prompts that they only work as USB keyboards if plugged directly into the USB master as they aren't actually USB keyboards, they are PS2 keyboards with a USB plug.

The Dell keyboard is a USB keyboard as it has a card reader, and only USB devices can provide more than one input device.

So, the solution to the problem is: ensure the USB device is actually a USB device and not a non-USB device with a USB plug.
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top