Mouse not working

Think you found a bug? Report it here.
User avatar
Ultibo
Site Admin
Posts: 2079
Joined: Sat Dec 19, 2015 3:49 am
Location: Australia

Re: Mouse not working

Postby Ultibo » Sun Dec 02, 2018 9:21 am

pfranz wrote:Adding RaspberryPI3 solved the problem.
Mouse description is correct:"PCPlay...".

Excellent, that confirms that you have network functionality.

I'm mindful of expanding the troubleshooting in multiple directions at once because it gets very easy to lose track of the details of the conversation.

For the moment let's focus primarily on the mouse diagnostics and we can follow up further on any additional issues once that is mostly dealt with.

I will just add the following brief thoughts about the other items which might assist.

pfranz wrote:I enabled syslog, sent a test message with LoggingOutput which doesn't appear.

I'm making the assumption that you put this at the start of the example, you might need to allow a little bit of time for the network to initialize (a second or two) otherwise a syslog message can go missing or more correctly simply be discarded because there is no network available to deliver it.

pfranz wrote:I see messages that network is configured, and many "Failed interrupt interrupt request" from the 95xx driver.

The interrupt endpoint in the SMSC95XX device is used for ethernet management functionality like link up/down, negotiation complete etc so a failed interrupt request can result from a number of reasons.

The most interesting initial information would be your definition of "many", is that 3 to 5, 30 to 50, 300 to 500 or more? And what is the status value reported with the failure?

pfranz wrote:The net uses DHCP even though I set a static address in cmdline.txt.

Assuming that you put all of the configuration parameters on one line in the cmdline.txt file then could you post the file you used so we can see if there is anything unusual about it.

pfranz wrote:No mouse messages at all.

Looking at the experimental USBPS2Converter driver there is no code path in the HIDMouseReportWorker function that would not produce at least some message so one possibility is that the driver is failing on the first receipt (and possibly before logging is ready).

Could you try starting the Pi with the PS/2 to USB converter not plugged in, then wait several seconds for the network to be ready and logging messages started before plugging in the PS/2 to USB converter (with mouse attached) and recording the log messages that are generated.

I'm sure that we are only missing some very small detail to get this working for you, if you can supply as much detail as possible that will make it much quicker and easier to resolve.
Ultibo.org | Make something amazing
https://ultibo.org
pfranz
Posts: 13
Joined: Sun Nov 25, 2018 4:38 pm

Re: Mouse not working

Postby pfranz » Sun Dec 02, 2018 11:16 am

Fine, let's stick to the mouse issue. I waited inserting the adapter after network messages were received.
It seems to me that the keyboard is still in boot mode.Maybe the solution could be setting report protocol for everything and receive keyboard,mouse,system control reports all together like in the hid specification example (if I am not mistaken)?
Here is the syslog:

<30>Dec 30 00:00:13 192.168.1.11 Network: 00000075 - 007B8688:0 - Network: IP: Configuration completed for adapter Network0 192.168.1.11 02/12 11:55:48.250
<30>Dec 30 00:00:13 192.168.1.11 Network: 00000076 - 007B8688:0 - Network: IP: Config = CONFIG_TYPE_DHCP 192.168.1.11 02/12 11:55:48.296
<30>Dec 30 00:00:13 192.168.1.11 Network: 00000077 - 007B8688:0 - Network: IP: Address = 192.168.1.11 192.168.1.11 02/12 11:55:48.296
<30>Dec 30 00:00:13 192.168.1.11 Network: 00000078 - 007B8688:0 - Network: IP: Netmask = 255.255.255.0 192.168.1.11 02/12 11:55:48.296
<30>Dec 30 00:00:13 192.168.1.11 Network: 00000079 - 007B8688:0 - Network: IP: Gateway = 192.168.1.3 192.168.1.11 02/12 11:55:48.296
<30>Dec 30 00:00:13 192.168.1.11 Network: 0000007A - 007B8688:0 - Network: IP: Server = 192.168.1.3 192.168.1.11 02/12 11:55:48.296
<27>Dec 30 00:00:14 192.168.1.11 USB: 0000007B - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:55:49.515
<30>Dec 30 00:00:48 192.168.1.11 Device: 0000007C - 00DBAA6C:3 - Device: Sending device notification (Name=USB3 Class=DEVICE_CLASS_USB Notification=DEVICE_NOTIFICATION_REGISTER) 192.168.1.11 02/12 11:56:23.078
<30>Dec 30 00:00:48 192.168.1.11 Device: 0000007D - 00DBAA6C:3 - Device: Registered device (Handle=00FC614C Class=DEVICE_CLASS_USB Name=USB3) 192.168.1.11 02/12 11:56:23.093
<30>Dec 30 00:00:48 192.168.1.11 USB: 0000007E - 00DBAA6C:3 - USB: Device2: Hub: New low-speed device connected to port 4 192.168.1.11 02/12 11:56:23.093
<30>Dec 30 00:00:48 192.168.1.11 Device: 0000007F - 00DBAA6C:3 - Device: Sending device notification (Name=USB3 Class=DEVICE_CLASS_USB Notification=DEVICE_NOTIFICATION_ATTACHING) 192.168.1.11 02/12 11:56:23.093
<30>Dec 30 00:00:48 192.168.1.11 USB: 00000080 - 00DBAA6C:3 - USB: Device4: Attaching low-speed USB 1.1 HID (Human Interface Device) class device (Generic USB K/B) (idVendor=13BA idProduct=0017) 192.168.1.11 02/12 11:56:23.156
<30>Dec 30 00:00:48 192.168.1.11 Device: 00000081 - 00DBAA6C:3 - Device: Sending device notification (Name=USB3 Class=DEVICE_CLASS_USB Notification=DEVICE_NOTIFICATION_ATTACH) 192.168.1.11 02/12 11:56:23.156
<31>Dec 30 00:00:48 192.168.1.11 USB: 00000082 - 00DBAA6C:3 - [DEBUG] USB: Device4: HID Mouse: Attempting to bind USB device (Manufacturer= Product=Generic USB K/B Address=4) 192.168.1.11 02/12 11:56:23.156
<31>Dec 30 00:00:48 192.168.1.11 USB: 00000083 - 00DBAA6C:3 - [DEBUG] USB: Device4: HID Mouse: Attempting to bind USB device (Manufacturer= Product=Generic USB K/B Address=4) 192.168.1.11 02/12 11:56:23.156
<31>Dec 30 00:00:48 192.168.1.11 USB: 00000084 - 00DBAA6C:3 - [DEBUG] USB: Device4: HID Mouse: Device not found in supported device list 192.168.1.11 02/12 11:56:23.156
<31>Dec 30 00:00:48 192.168.1.11 USB: 00000085 - 00DBAA6C:3 - [DEBUG] USB: Device4: HID Mouse: Attempting to bind USB device (Manufacturer= Product=Generic USB K/B Address=4) 192.168.1.11 02/12 11:56:23.156
<30>Dec 30 00:00:48 192.168.1.11 Device: 00000086 - 00DBAA6C:3 - Device: Sending device notification (Name=Mouse0 Class=DEVICE_CLASS_MOUSE Notification=DEVICE_NOTIFICATION_REGISTER) 192.168.1.11 02/12 11:56:23.156
<30>Dec 30 00:00:48 192.168.1.11 Device: 00000087 - 00DBAA6C:3 - Device: Registered device (Handle=00FCA044 Class=DEVICE_CLASS_MOUSE Name=Mouse0) 192.168.1.11 02/12 11:56:23.156
<31>Dec 30 00:00:48 192.168.1.11 USB: 00000088 - 00DBAA6C:3 - [DEBUG] USB: Device4: HID Mouse: Enabling HID report protocol 192.168.1.11 02/12 11:56:23.156
<31>Dec 30 00:00:48 192.168.1.11 USB: 00000089 - 00DBAA6C:3 - [DEBUG] USB: Device4: HID Mouse: Submitting report request 192.168.1.11 02/12 11:56:23.156
<30>Dec 30 00:00:48 192.168.1.11 Device: 0000008A - 00DBAA6C:3 - Device: Sending device notification (Name=Mouse0 Class=DEVICE_CLASS_MOUSE Notification=DEVICE_NOTIFICATION_ATTACH) 192.168.1.11 02/12 11:56:23.156
<30>Dec 30 00:00:48 192.168.1.11 USB: 0000008B - 00DBAA6C:3 - USB: Bound HID PS/2 to USB Mouse Driver to low-speed USB 1.1 HID (Human Interface Device) class device (Generic USB K/B) (idVendor=13BA idProduct=0017) (Interface=1) 192.168.1.11 02/12 11:56:23.156
<30>Dec 30 00:00:48 192.168.1.11 Device: 0000008C - 00DBAA6C:3 - Device: Sending device notification (Name=Keyboard0 Class=DEVICE_CLASS_KEYBOARD Notification=DEVICE_NOTIFICATION_REGISTER) 192.168.1.11 02/12 11:56:23.156
<30>Dec 30 00:00:48 192.168.1.11 Device: 0000008D - 00DBAA6C:3 - Device: Registered device (Handle=00FCC47C Class=DEVICE_CLASS_KEYBOARD Name=Keyboard0) 192.168.1.11 02/12 11:56:23.156
<30>Dec 30 00:00:48 192.168.1.11 Device: 0000008E - 00DBAA6C:3 - Device: Sending device notification (Name=Keyboard0 Class=DEVICE_CLASS_KEYBOARD Notification=DEVICE_NOTIFICATION_ATTACH) 192.168.1.11 02/12 11:56:23.156
<30>Dec 30 00:00:48 192.168.1.11 USB: 0000008F - 00DBAA6C:3 - USB: Bound USB Keyboard Driver (HID boot protocol) to low-speed USB 1.1 HID (Human Interface Device) class device (Generic USB K/B) (idVendor=13BA idProduct=0017) (Interface=0) 192.168.1.11 02/12 11:56:23.156
<30>Dec 30 00:00:48 192.168.1.11 Device: 00000090 - 00DBAA6C:3 - Device: Sending device notification (Name=USB3 Class=DEVICE_CLASS_USB Notification=DEVICE_NOTIFICATION_BIND) 192.168.1.11 02/12 11:56:23.171
<27>Dec 30 00:01:24 192.168.1.11 USB: 00000091 - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:56:58.937
<27>Dec 30 00:01:34 192.168.1.11 USB: 00000092 - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:57:09.218
<27>Dec 30 00:01:41 192.168.1.11 USB: 00000093 - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:57:16.781
<27>Dec 30 00:01:50 192.168.1.11 USB: 00000094 - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:57:25.140
<27>Dec 30 00:02:17 192.168.1.11 USB: 00000095 - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:57:52.390
<27>Dec 30 00:02:19 192.168.1.11 USB: 00000096 - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:57:54.250
<27>Dec 30 00:02:20 192.168.1.11 USB: 00000097 - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:57:55.140
<27>Dec 30 00:02:25 192.168.1.11 USB: 00000098 - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:57:59.859
<27>Dec 30 00:02:31 192.168.1.11 USB: 00000099 - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:58:06.484
<27>Dec 30 00:02:42 192.168.1.11 USB: 0000009A - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:58:17.687
<27>Dec 30 00:03:00 192.168.1.11 USB: 0000009B - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:58:35.515
<27>Dec 30 00:03:11 192.168.1.11 USB: 0000009C - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:58:46.796
<27>Dec 30 00:03:12 192.168.1.11 USB: 0000009D - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:58:47.703
<27>Dec 30 00:03:20 192.168.1.11 USB: 0000009E - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:58:55.156
<27>Dec 30 00:03:47 192.168.1.11 USB: 0000009F - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:59:22.343
<27>Dec 30 00:03:47 192.168.1.11 USB: 000000A0 - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:59:22.390
<27>Dec 30 00:04:03 192.168.1.11 USB: 000000A1 - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:59:38.328
<27>Dec 30 00:04:12 192.168.1.11 USB: 000000A2 - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 11:59:47.703
<27>Dec 30 00:04:33 192.168.1.11 USB: 000000A3 - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:00:08.390
<27>Dec 30 00:04:37 192.168.1.11 USB: 000000A4 - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:00:12.109
<27>Dec 30 00:04:41 192.168.1.11 USB: 000000A5 - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:00:15.859
<27>Dec 30 00:04:42 192.168.1.11 USB: 000000A6 - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:00:17.718
<27>Dec 30 00:05:02 192.168.1.11 USB: 000000A7 - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:00:37.375
<27>Dec 30 00:05:05 192.168.1.11 USB: 000000A8 - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:00:40.187
<27>Dec 30 00:05:06 192.168.1.11 USB: 000000A9 - 008481CC:2 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:00:41.093
<27>Dec 30 00:05:11 192.168.1.11 USB: 000000AA - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:00:45.890
<27>Dec 30 00:05:22 192.168.1.11 USB: 000000AB - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:00:57.078
<27>Dec 30 00:05:32 192.168.1.11 USB: 000000AC - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:01:07.390
<27>Dec 30 00:05:33 192.168.1.11 USB: 000000AD - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:01:08.296
<27>Dec 30 00:05:45 192.168.1.11 USB: 000000AE - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:01:20.578
<27>Dec 30 00:06:05 192.168.1.11 USB: 000000AF - 008044BC:1 - [ERROR] USB: Device3: SMSC95XX: Failed interrupt request (Status=USB_STATUS_HARDWARE_ERROR) 192.168.1.11 02/12 12:01:40.171
User avatar
Ultibo
Site Admin
Posts: 2079
Joined: Sat Dec 19, 2015 3:49 am
Location: Australia

Re: Mouse not working

Postby Ultibo » Mon Dec 03, 2018 8:49 am

pfranz wrote:It seems to me that the keyboard is still in boot mode.Maybe the solution could be setting report protocol for everything and receive keyboard,mouse,system control reports all together like in the hid specification example (if I am not mistaken)?

It's possible that the device is somehow broken enough to need all three devices set to report mode in order to work, we'll think about it if nothing else leads to anything useful.

pfranz wrote:Here is the syslog:
...

The fact that no packets seem to ever be received from the mouse is very strange, can you possibly try repeating this test with a few more combinations and provide the log for anything that gives a different result.

Out of interest if you unplug the device after a minute or so what log entries are generated for that? It should show the device being deregistered but I'd also expect to see the interrupt request being reported as a failure immediately after the device is unplugged.

If you don't plug in the PS/2 keyboard and only connect the mouse does that produce anything different?

If you plug in a USB mouse as well (in one of the spare USB ports) before connecting the PS/2 to USB converter does that change anything?

If you connect the converter to a hub (preferably a powered hub) is the result any different?

Any other combinations that you can think to test would be helpful especially if any of them produce different results in the logging.

For completeness is your device like any of the ones shown in these links (and if so which one):

https://www.ebay.com/bhp/ps2-to-usb-adapter
https://core-electronics.com.au/ps-2-ke ... apter.html

or do you have a link for your specific device?
Ultibo.org | Make something amazing
https://ultibo.org
pfranz
Posts: 13
Joined: Sun Nov 25, 2018 4:38 pm

Re: Mouse not working

Postby pfranz » Mon Dec 03, 2018 9:39 am

the adapter is like
https://www.ebay.com/p/USB-Male-to-Dual ... 1373560863

I can try different combinations, but I do not think that is the way.
On Linux and Windows it works straight away. And not only it is hotpluggable on the usb port, but some mice are hotpluggable also on the ps2 port.
Do you know any good usb sniffers to see how linux and windows configure it?
User avatar
Ultibo
Site Admin
Posts: 2079
Joined: Sat Dec 19, 2015 3:49 am
Location: Australia

Re: Mouse not working

Postby Ultibo » Mon Dec 03, 2018 9:52 am

pfranz wrote:I can try different combinations, but I do not think that is the way.

You're welcome to tackle it differently if you like but if we had one of these devices, and I'm not sure if we can actually get one even though they are shown on eBay, then we would try testing all sorts of combinations first and observing the results to see what happened. That's a lot quicker than rewriting drivers but I'll leave it up to you to decide.
Ultibo.org | Make something amazing
https://ultibo.org
pfranz
Posts: 13
Joined: Sun Nov 25, 2018 4:38 pm

Re: Mouse not working

Postby pfranz » Sun Dec 09, 2018 10:07 am

Problem solved: I have to request hid report descriptor even when in boot mode.Makes sense, as the mouse boot report has optional fields and its length is not fixed (mine is 4 bytes as you know)
User avatar
Ultibo
Site Admin
Posts: 2079
Joined: Sat Dec 19, 2015 3:49 am
Location: Australia

Re: Mouse not working

Postby Ultibo » Mon Dec 10, 2018 8:55 am

pfranz wrote:Problem solved: I have to request hid report descriptor even when in boot mode.Makes sense, as the mouse boot report has optional fields and its length is not fixed (mine is 4 bytes as you know)

Excellent, so if the driver simply sends a get descriptor request for the HID report descriptor then the device is completely happy and works normally?

That will be an easy answer given that the generic HID driver will always need to ask for the descriptor so it can parse and decode it.

Out of interest does the request have to be performed at a certain point during initialization or just anytime before trying to receive reports from it?
Ultibo.org | Make something amazing
https://ultibo.org
pfranz
Posts: 13
Joined: Sun Nov 25, 2018 4:38 pm

Re: Mouse not working

Postby pfranz » Mon Dec 10, 2018 10:27 am

Yes, the device is happy like that. Then with boot protocol you can even ignore the descriptor.
It doesn't seem to need to be done at a particular point during initialization. I have tried before and after setting the boot protocol, worked in both cases.
By the way, I solved the problem of static ip configuration in cmdline.txt by putting all the configuration in the first line. I had understood that in one line I'd put the syslog part, in another the IP part.

Return to “Bug reports”

Who is online

Users browsing this forum: No registered users and 2 guests