Re: USB Mouse not working

2005-03-23 Thread Marius Nnnerich
On Tue, 22 Mar 2005 01:46:19 +
Ian Dowse [EMAIL PROTECTED] wrote:
 
 I'm not sure I do either :-) On a mouse I tried here I got very
 different information than that:
 
 Report descriptor:
 Collection page=Generic_Desktop usage=Mouse
 Collection page=Generic_Desktop usage=Pointer
 Input   size=1 count=1 page=Button usage=Button_1, logical range 0..1
 Input   size=1 count=1 page=Button usage=Button_2, logical range 0..1
 Input   size=1 count=1 page=Button usage=Button_3, logical range 0..1
 Input   size=8 count=1 page=Generic_Desktop usage=X, logical range
-127..127
 Input   size=8 count=1 page=Generic_Desktop usage=Y, logical range
-127..127
 Input   size=8 count=1 page=Generic_Desktop usage=Wheel, logical range
-127..127
 End collection
 Feature size=1 count=1 page=Generic_Desktop usage=Motion_Wakeup,
logical range 0..1
 End collection
 Total   input size 4 bytes
 Total  output size 0 bytes
 Total feature size 0 bytes
 
 But I don't know enough about how this is supposed to work to make
 sense of the difference.

I got similar output, when I plug in that mouse with
hw.usb.ums.debug=99:
ums0: Device USB Device, rev 1.10/0.01, addr 2, iclass 3/1
ums_attach: bLength=7 bDescriptorType=5 bEndpointAddress=2-in
bmAttributes=3 wMa xPacketSize=5 bInterval=10
ums0: 5 buttons and Z dir and a TILT dir.
ums_attach: sc=0xc1a14000
ums_attach: X   8/8
ums_attach: Y   16/8
ums_attach: Z   24/8
ums_attach: B1  0/1
ums_attach: B2  1/1
ums_attach: B3  2/1
ums_attach: B4  3/1
ums_attach: B5  4/1
ums_attach: size=9, id=3

The TILT dir is caused by the hardcoded 
sc-flags |= UMS_T;

Has anyone an idea what to do next?
I suppose I can't do anything in ums.c, as it gets the (to few) data
from another file.

thanks
Marius


pgp35SOojs6cE.pgp
Description: PGP signature


Re: USB Mouse not working

2005-03-21 Thread Marius Nnnerich
On Mon, 21 Mar 2005 00:33:00 +
Ian Dowse [EMAIL PROTECTED] wrote:

 I think page 61 is just an example of one possible report descriptor
 for a mouse. Could you follow the instructions below to get the
 report descriptor for your mouse and post it to the list?
 
  o Remove the `ums' device from your kernel config, but leave in
the `uhid' device (if you're using modules, just unload ums and
make sure uhid is loaded).
 
  o Plug in the mouse
 
  o Check dmesg for the correct uhid device, e.g. you should see
something like:
 
   uhid0: Logitech USB Mouse, rev 1.10/4.10, addr 2, iclass 3/1
 
  o Run this command
 
   usbhidctl -f /dev/uhid0 -ra
 

# dmesg|grep uhid
uhid0: Device USB Device, rev 1.10/0.01, addr 2, iclass 3/1

Thats the mouse, because it's the only USB device plugged-in at the
moment (with ukbd0).

# usbhidctl -f /dev/uhid0 -ra
Report descriptor:
Total   input size 0 bytes
Total  output size 4 bytes
Total feature size 1 bytes
usbhidctl: device does not support immediate mode, only changes
reported.

Hmm, don't know what to do with this information :)

Thanks,
Marius


pgpaYSeGs5EG5.pgp
Description: PGP signature


Re: USB Mouse not working

2005-03-21 Thread Ian Dowse
In message [EMAIL PROTECTED], Marius =?ISO-
8859-1?Q?N=FCnnerich?= writes:
# usbhidctl -f /dev/uhid0 -ra
Report descriptor:
Total   input size 0 bytes
Total  output size 4 bytes
Total feature size 1 bytes
usbhidctl: device does not support immediate mode, only changes
reported.

Hmm, don't know what to do with this information :)

I'm not sure I do either :-) On a mouse I tried here I got very
different information than that:

Report descriptor:
Collection page=Generic_Desktop usage=Mouse
Collection page=Generic_Desktop usage=Pointer
Input   size=1 count=1 page=Button usage=Button_1, logical range 0..1
Input   size=1 count=1 page=Button usage=Button_2, logical range 0..1
Input   size=1 count=1 page=Button usage=Button_3, logical range 0..1
Input   size=8 count=1 page=Generic_Desktop usage=X, logical range -127..127
Input   size=8 count=1 page=Generic_Desktop usage=Y, logical range -127..127
Input   size=8 count=1 page=Generic_Desktop usage=Wheel, logical range -127..127
End collection
Feature size=1 count=1 page=Generic_Desktop usage=Motion_Wakeup, logical range 
0..1
End collection
Total   input size 4 bytes
Total  output size 0 bytes
Total feature size 0 bytes

But I don't know enough about how this is supposed to work to make
sense of the difference.

Ian
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


USB Mouse not working

2005-03-20 Thread Marius Nnnerich
Hi,

I recently purchased a cheap USB mouse/keyboard combination. If I plug
it in /dev/ums0 is created, I also can run moused -p /dev/ums0, but the
mouse will not move.

I upgraded to a recent -STABLE, so ums.c is version 1.70.2.2.
I compiled a kernel with options USB_DEBUG and set
hw.usb.ums.debug=.
With cat /dev/ums0  /dev/null I can see the Debug Info on the console:
ums_intr: sc=0x19d5c00 status=13
ums_intr: data = 01 00 00 00 00 01
ums_intr: status=13

It seems that this mouse sends 1 extra byte before the usual data, just
like the MS Wireless Intellimouse 2.0, because data is like:
01 BUTTON X Y Z 01

But seems like ums_intr() returns on line 467, so I tried this:
--- /sys/dev/usb/ums.c  Sun Mar 20 14:54:14 2005
+++ /root/ums.c Sun Mar 20 14:54:04 2005
@@ -456,7 +456,7 @@
 * Currently it's the only user of UMS_T so use it as an identifier.
 * We probably should switch to some more official quirk.
 */
-   if (sc-flags  UMS_T) {
+/* if (sc-flags  UMS_T) {
if (sc-sc_iid) {
if (*ibuf++ == 0x02)
return;
@@ -468,9 +468,11 @@
}
}
 
+*/ *ibuf++;



It sort of works. If I run moused -p /dev/ums0 I can actually use that
mouse, BUT it moves jerky, I have to move the wheel two positions
to get one and when a button is pressed when the mouse stands still it
is not recognized. The mouse _must_ move for the button to get noticed.

Has anyone an idea what to try next?
Any help would be greatly appreciated!

Marius


pgpSeUZfsyEt5.pgp
Description: PGP signature


Re: USB Mouse not working

2005-03-20 Thread Anish Mistry
On Sunday 20 March 2005 09:46 am, Marius Nünnerich wrote:
 Hi,

 I recently purchased a cheap USB mouse/keyboard combination. If I
 plug it in /dev/ums0 is created, I also can run moused -p
 /dev/ums0, but the mouse will not move.

 I upgraded to a recent -STABLE, so ums.c is version 1.70.2.2.
 I compiled a kernel with options USB_DEBUG and set
 hw.usb.ums.debug=.
 With cat /dev/ums0  /dev/null I can see the Debug Info on the
 console: ums_intr: sc=0x19d5c00 status=13
 ums_intr: data = 01 00 00 00 00 01
 ums_intr: status=13

 It seems that this mouse sends 1 extra byte before the usual data,
 just like the MS Wireless Intellimouse 2.0, because data is like:
 01 BUTTON X Y Z 01

 But seems like ums_intr() returns on line 467, so I tried this:
 --- /sys/dev/usb/ums.c  Sun Mar 20 14:54:14 2005
 +++ /root/ums.c Sun Mar 20 14:54:04 2005
 @@ -456,7 +456,7 @@
  * Currently it's the only user of UMS_T so use it as an
 identifier. * We probably should switch to some more official
 quirk. */
 -   if (sc-flags  UMS_T) {
 +/* if (sc-flags  UMS_T) {
 if (sc-sc_iid) {
 if (*ibuf++ == 0x02)
 return;
 @@ -468,9 +468,11 @@
 }
 }

 +*/ *ibuf++;



 It sort of works. If I run moused -p /dev/ums0 I can actually use
 that mouse, BUT it moves jerky, I have to move the wheel two
 positions to get one and when a button is pressed when the mouse
 stands still it is not recognized. The mouse _must_ move for the
 button to get noticed.

 Has anyone an idea what to try next?
 Any help would be greatly appreciated!

Is the code setting the UMS_T flags?  If not, then force it in after 
the detection routine section:
/* The Microsoft Wireless Intellimouse 2.0 reports it's wheel
 * using 0x0048 (i've called it HUG_TWHEEL) and seems to expect
 * you to know that the byte after the wheel is the tilt axis.
 * There are no other HID axis descriptors other than X,Y and 
 * TWHEEL */
if (hid_locate(desc, size, HID_USAGE2(HUP_GENERIC_DESKTOP, 
HUG_TWHEEL),
hid_input, sc-sc_loc_t, flags)) {
sc-sc_loc_t.pos = sc-sc_loc_t.pos + 8;
sc-flags |= UMS_T;
}
sc-flags |= UMS_T; /* ---  Add this to force MS Intellimouse Mode */
If that make is work we'll have to figure out a way to auto detect 
this since it uses the same byte order, but doesn't have the tilt 
wheel to facilitate detection.

-- 
Anish Mistry


pgp3XQbPy9BpQ.pgp
Description: PGP signature


Re: USB Mouse not working

2005-03-20 Thread Ian Dowse
In message [EMAIL PROTECTED], Anish Mistry writes:
sc-flags |= UMS_T; /* ---  Add this to force MS Intellimouse Mode */
If that make is work we'll have to figure out a way to auto detect 
this since it uses the same byte order, but doesn't have the tilt 
wheel to facilitate detection.

BTW, before adding more workarounds here it would be worth reading:

http://www.usb.org/developers/devclass_docs/HID1_11.pdf

I don't know if this is true, but I suspect the main problem is
that we are simply ignoring the information in the report descriptor
that says how to interpret the data coming from the mouse. Can
somebody check if this is the case, or if these mice really need
special case workarounds?

Ian
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: USB Mouse not working

2005-03-20 Thread Marius Nnnerich
On Sun, 20 Mar 2005 13:39:59 -0500
Anish Mistry [EMAIL PROTECTED] wrote:
 Is the code setting the UMS_T flags?  If not, then force it in after 
 the detection routine section:
   /* The Microsoft Wireless Intellimouse 2.0 reports it's wheel
* using 0x0048 (i've called it HUG_TWHEEL) and seems to expect
* you to know that the byte after the wheel is the tilt axis.
* There are no other HID axis descriptors other than X,Y and 
* TWHEEL */
   if (hid_locate(desc, size, HID_USAGE2(HUP_GENERIC_DESKTOP, 
 HUG_TWHEEL),
   hid_input, sc-sc_loc_t, flags)) {
   sc-sc_loc_t.pos = sc-sc_loc_t.pos + 8;
   sc-flags |= UMS_T;
   }
 sc-flags |= UMS_T; /* ---  Add this to force MS Intellimouse Mode */

No, it isn't set by the code itself. I tried what you suggested, I get
the same results as before:
 - jerky movement
 - need to scroll the mousewheel two positions to get one event
 - button pressing isn't recognized if the mouse isn't moving

If I plug the mouse into the PS/2 connector it works as I
expect. But thats not an option :(

Anyhow, thank you very much for your suggestions.
Marius


pgpBNxDjcXTQZ.pgp
Description: PGP signature


Re: USB Mouse not working

2005-03-20 Thread Marius Nnnerich
On Sun, 20 Mar 2005 19:29:18 +
Ian Dowse [EMAIL PROTECTED] wrote:

 BTW, before adding more workarounds here it would be worth reading:
 
   http://www.usb.org/developers/devclass_docs/HID1_11.pdf
 
 I don't know if this is true, but I suspect the main problem is
 that we are simply ignoring the information in the report descriptor
 that says how to interpret the data coming from the mouse. Can
 somebody check if this is the case, or if these mice really need
 special case workarounds?

I didn't read the whole document, but as far as I understand the table
on the bottom of page 61 (of the document, not the pdf-file) it is clear
how the data should be interpreted, and that my mouse (like the
intellimouse) is not conforming to this standard.

But the interpretation of the data isn't really the problem, the problem
are the three points described in my last two mails.

Anyway, thanks for your time.
Marius


pgpvNAYXd2033.pgp
Description: PGP signature


Re: USB Mouse not working

2005-03-20 Thread Ian Dowse
In message [EMAIL PROTECTED], Marius =?ISO-
8859-1?Q?N=FCnnerich?= writes:
On Sun, 20 Mar 2005 19:29:18 +
Ian Dowse [EMAIL PROTECTED] wrote:

 BTW, before adding more workarounds here it would be worth reading:
 
  http://www.usb.org/developers/devclass_docs/HID1_11.pdf
 
 I don't know if this is true, but I suspect the main problem is
 that we are simply ignoring the information in the report descriptor
 that says how to interpret the data coming from the mouse. Can
 somebody check if this is the case, or if these mice really need
 special case workarounds?

I didn't read the whole document, but as far as I understand the table
on the bottom of page 61 (of the document, not the pdf-file) it is clear
how the data should be interpreted, and that my mouse (like the
intellimouse) is not conforming to this standard.

I think page 61 is just an example of one possible report descriptor
for a mouse. Could you follow the instructions below to get the
report descriptor for your mouse and post it to the list?

 o Remove the `ums' device from your kernel config, but leave in
   the `uhid' device (if you're using modules, just unload ums and
   make sure uhid is loaded).

 o Plug in the mouse

 o Check dmesg for the correct uhid device, e.g. you should see
   something like:

uhid0: Logitech USB Mouse, rev 1.10/4.10, addr 2, iclass 3/1

 o Run this command

usbhidctl -f /dev/uhid0 -ra

   replacing the uhid0 name with the correct device for your mouse.

Thanks,

Ian
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: USB mouse not working

2005-01-16 Thread Imobach González Sosa
On Sunday 16 January 2005 03:47, Robert William Vesterman wrote:
 I found that my USB mouse works if and only if I boot without APCI support.

Ok, it didn't work to me. I added

hint.acpi.0.disabled=1
(and also tried adding hint.apm.0.disabled=0 too)

'dmesg | grep acpi' returns no results, same as 'devinfo | grep acpi'. So I 
suppose acpi is disabled at boot time. I also noticed that when moused start 
while booting the machine, it throws me this error: 'unable to 
open /dev/ums0: Device busy'.

Any idea?

 However, I can't figure out how to configure moused with my mouse: I have
  this settings in /etc/rc.conf:
 
 usbd_enable=YES
 usbd_flags=
 moused_enable=YES
 moused_type=auto
 moused_flags=
 moused_port=/dev/ums0
 

-- 
Imobach González Sosa
imobachgs en banot punto net
osoh en jabber.org
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: USB mouse not working

2005-01-16 Thread Jason Morgan
On Sun, Jan 16, 2005 at 10:33:46AM +, Imobach Gonz?lez Sosa wrote:
 On Sunday 16 January 2005 03:47, Robert William Vesterman wrote:
  I found that my USB mouse works if and only if I boot without APCI support.
 
 Ok, it didn't work to me. I added
 
 hint.acpi.0.disabled=1
 (and also tried adding hint.apm.0.disabled=0 too)
 
 'dmesg | grep acpi' returns no results, same as 'devinfo | grep acpi'. So I 
 suppose acpi is disabled at boot time. I also noticed that when moused start 
 while booting the machine, it throws me this error: 'unable to 
 open /dev/ums0: Device busy'.
 
 Any idea?
 
  However, I can't figure out how to configure moused with my mouse: I have
   this settings in /etc/rc.conf:
  
  usbd_enable=YES
  usbd_flags=
  moused_enable=YES
  moused_type=auto
  moused_flags=
  moused_port=/dev/ums0
  

What brand of mouse you using?  I have 2 IBM optical mice that need 
disconnected and reconnected about 1/2 the time 
before they will work.  This happens to me in Linux, FreeBSD, and Windows so 
seems to be a mouse issue.  Happens to my 
brother as well - he has the same mouse.  Even when the mouse works at bootup, 
I get a /dev/ums0: Device busy error.  
Only thing I can see that is different in my setup compared to yours is that I 
have:

usbd_flags=-vv

in rc.conf.  I can't for the life of me remember why (scrolling maybe?).

Cheers.
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: USB mouse not working

2005-01-16 Thread Imobach González Sosa
On Sunday 16 January 2005 18:10, Jason Morgan wrote:

 What brand of mouse you using?  I have 2 IBM optical mice that need
 disconnected and reconnected about 1/2 the time before they will work. 
 This happens to me in Linux, FreeBSD, and Windows so seems to be a mouse
 issue.  Happens to my brother as well - he has the same mouse.  Even when
 the mouse works at bootup, I get a /dev/ums0: Device busy error. Only thing
 I can see that is different in my setup compared to yours is that I have:

I have a Logitech Coordless Desktop Comfort; it's a receiver with 
keyboard+optical mouse.

 usbd_flags=-vv

This make no sense for me.

 in rc.conf.  I can't for the life of me remember why (scrolling maybe?).

Ok, so now the good news: I've installed a 'macally mice' (a simple usb mouse) 
and it seems to work just fine. Anyway, I still wanna use my Logitech mice, 
so I suppose I'll continue trying with it.

Thank you all for your responses.

Anybody on this list have a Logitech mice as mine?

-- 
Imobach González Sosa
imobachgs en banot punto net
osoh en jabber.org
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


USB mouse not working

2005-01-15 Thread Imobach González Sosa
Hi all,

Probably is my fault, but I can't get the mouse working on 5.3 STABLE. I've 
installed FreeBSD 5.3 RELEASE last night, and today I updated my sources and 
rebuilt 'world'. I've googled for a while and I can't fix the problem, so I'm 
posting the trouble to this list. I hope it's the correct list. Let me know 
if I'm wrong.

Ok, when I start FreeBSD the mouse seems to be detected (usb mouse):

ums0: Logitech USB Receiver, rev 1.10/17.00, addr 2, iclass 3/1
ums0: 7 buttons and Z dir.

However, I can't figure out how to configure moused with my mouse: I have this 
settings in /etc/rc.conf:

usbd_enable=YES
usbd_flags=
moused_enable=YES
moused_type=auto
moused_flags=
moused_port=/dev/ums0

But the mouse doesn't move on the console. And, when I fire up X.org, 
everything goes right except the mouse stays in the center of the screen.

Any tips about it?

Thank you in advance and sorry if it's not the proper list.

-- 
Imobach González Sosa
imobachgs at banot dot net
osoh en jabber.org
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: USB mouse not working

2005-01-15 Thread Robert William Vesterman
I found that my USB mouse works if and only if I boot without APCI support.
Imobach González Sosa wrote:
Hi all,
Probably is my fault, but I can't get the mouse working on 5.3 STABLE. I've 
installed FreeBSD 5.3 RELEASE last night, and today I updated my sources and 
rebuilt 'world'. I've googled for a while and I can't fix the problem, so I'm 
posting the trouble to this list. I hope it's the correct list. Let me know 
if I'm wrong.

Ok, when I start FreeBSD the mouse seems to be detected (usb mouse):
ums0: Logitech USB Receiver, rev 1.10/17.00, addr 2, iclass 3/1
ums0: 7 buttons and Z dir.
However, I can't figure out how to configure moused with my mouse: I have this 
settings in /etc/rc.conf:

usbd_enable=YES
usbd_flags=
moused_enable=YES
moused_type=auto
moused_flags=
moused_port=/dev/ums0
But the mouse doesn't move on the console. And, when I fire up X.org, 
everything goes right except the mouse stays in the center of the screen.

Any tips about it?
Thank you in advance and sorry if it's not the proper list.
 

___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]