Subject: OK, I give up. How do I use USB devices under NetBSD?
To: None <port-macppc@netbsd.org>
From: Michael Wolfson <mw@blobulent.com>
List: port-macppc
Date: 04/16/2001 23:47:41
I can't manage to get any of the USB devices I own to work with my system.

No FAQs, HOW-TOs, or anything on the topic.  So I guess I have to write my o=
wn.

Help me get it started (and using the USB devices I've got):
Keyspan USA-28X dual serial port adapter (it has two RS422 mac-like ports)
Microsoft IntelliMouse Explorer USB (an optical doodad with scroll wheel)
Griffin iMate ADB to USB adapter (lets you use ADB keyboard/mouse on USB)
Metricom Ricochet GS Modem (wireless microwave modem)


=46irst topic:  USB keyboards and mice.

OK, so how do I use an USB keyboard or mouse instead of the built-in
devices in my laptop?  Additionally, how do I use them *without* giving up
the internal keyboard in case I go somewhere and unplug the USB keyboard?

How do I get Xmacppc *and* Xfree86 to recognize the USB keyboard/mouse?

Yes, I've read the wscons FAQ, and the man pages and I can't figure it out.
I think I should be using wsmux, but ISTR Charles said that it was broken.

I'm also rather frustrated at having to reboot every time I boot with my
Griffin iMate ADB to USB adapter plugged in, since that disables both the
built-in ADB keyboard, and doesn't allow the ADB keyboard to work.

And, once I've got X recognizing my Microsoft Intellimouse Explorer, how do
I set up the scroll wheel and additional buttons?


Next topic:  USB serial devices.

I've got two of 'em, and can't get even 'cu' to talk with either device.  I
think the Keyspan isn't supported (i.e. it's not recognized as a
communication device), but the Ricochet modem is recognized.

Of course, I'm not entirely sure what device name to use.  The device
listed in the dmesg output seems to have absolutely no correspondence with
the /dev name.  Why is this?

I've tried using both /dev/ttyU0 and /dev/ttyU1, but neither responds for
either USB serial device (usually an error message like "cu: No matching
ports").


Last topic: hot pluggability.

I must be a dumkopf or something, because I can't get my system to
recognize when I (un)plug a device after it's booted.  What am I missing?


Here's how they're probed by dmesg
Keyspan:
ugen0 at uhub1 port 1
ugen0: vendor 0x06cd product 0x0102, rev 1.00/80.01, addr 2

M$:
ums0 at uhub2 port 1 configuration 1 interface 0
ums0: Microsoft Microsoft IntelliMouse\M-. Explorer, rev 1.10/1.14, addr 3,
iclass 3/1
ums0: 5 buttons and Z dir.
wsmouse1 at ums0

Griffin:
ukbd0 at uhub2 port 2 configuration 1 interface 0
ukbd0: Griffin Technology, Inc. iMate, USB To ADB Adaptor, rev 1.00/3.30,
addr 4, iclass 3/1
wskbd1 at ukbd0: console keyboard, using wsdisplay0
ums1 at uhub2 port 2 configuration 1 interface 1
ums1: Griffin Technology, Inc. iMate, USB To ADB Adaptor, rev 1.00/3.30,
addr 4, iclass 3/1
ums1: 3 buttons
wsmouse2 at ums1

Metricom:
umodem0 at uhub0 port 1 configuration 1 interface 0
umodem0: Metricom Ricochet GS, rev 1.10/1.00, addr 2, iclass 2/2
umodem0: data interface 1, has CM over data, has break
umodem0: status change notification available
ucom0 at umodem0     [see, it says 'ucom0']


Here's what usbdevs -v says
Keyspan:
  port 4 addr 5: power 100 mA, config 1, product 0x0102(0x0102), vendor
0x06cd(0x06cd), rev 80.01

M$:
  port 1 addr 3: low speed, power 100 mA, config 1, Microsoft IntelliMouse=
=AE
Explorer(0x001e), Microsoft(0x045e), rev 1.14

Griffin:
  port 2 addr 4: low speed, power 100 mA, config 1, iMate, USB To ADB
Adaptor(0x0405), Griffin Technology, Inc.(0x077d), rev 3.30

Metricom:
 port 1 addr 2: self powered, config 1, Ricochet GS(0x0001),
Metricom(0x0870), rev 1.00

I'd appreciate any help on the topic.

Thanks,
  -- MW