hid-remapper icon indicating copy to clipboard operation
hid-remapper copied to clipboard

Elecom Huge Wired does not function with 2 Pico variant

Open ww123td opened this issue 2 years ago • 14 comments

It seems that the Elecom Huge wired version is not working with the device. I had only tested it with the 2 Pico variant. Upon connection, the LED on the mouse would sometimes blink (when connected directly to a device it would blink twice) and no input could be read. The status LED on neither Pico would blink.

I would like to assist in debugging the device, but since I only have limited hardware knowledge I would need instructions on where and what information I can provide to help.

I tried using win-hid-dump to get the HID descriptors but it seems to always crash. But I did see 4 entries created by this mouse so it could still be related to #18

ww123td avatar Apr 05 '23 05:04 ww123td

Can you try dumping the report descriptor using Wireshark? From what I remember the trick is to unplug and re-plug the device once the capture is running.

jfedor2 avatar Apr 05 '23 13:04 jfedor2

Hello, here is the dump file from Wireshark. I tried to filter out the useful entries and saved in a separate file, but in case I had omitted important info I have attached the full dump from my session as well. Elecom Huge dump.pcapng.gz Elecom Huge dump full.pcapng.gz

ww123td avatar Apr 05 '23 20:04 ww123td

Thanks. It doesn't seem that the descriptor is the issue in this case. Might be something lower level. We could probably increase TinyUSB debug level and see if it outputs anything relevant. That would require a USB-to-TTL adapter to read debug output from the Picos.

jfedor2 avatar Apr 05 '23 22:04 jfedor2

Hi, thanks for your reply. I would like to help but it would be great if you could point me to a step by step guide on how to set up the debug environment, as I'm very inexperienced with hardware debugging. Would I need to modify and compile the Pico firmware too? Thanks for the help.

ww123td avatar Apr 05 '23 23:04 ww123td

I can provide you with some test firmware if you have the hardware to read the serial output from the Picos.

jfedor2 avatar Apr 05 '23 23:04 jfedor2

I have ordered the USB to TTL adapter and it'll show up in a couple of days.

ww123td avatar Apr 05 '23 23:04 ww123td

I have set up my serial adapter, please let me know what steps to follow next.

ww123td avatar Apr 07 '23 10:04 ww123td

OK, connect pin 0 on the "B" Pico to RX on the serial adapter and one of the Pico GND pins to GND on the adapter.

And try this firmware (included both A and B, but it's really the B side that's of interest to us right now.)

debug_firmware.zip

Get some serial terminal software on the PC and set the baud rate to 921600. Then plug the trackball in. You should be seeing some output similar to this (and a lot more):

[0:] USBH DEVICE ATTACH
hcd_port_reset
hcd_port_connect_status
Full Speed

No guarantee this will help us make it work, but who knows.

jfedor2 avatar Apr 07 '23 11:04 jfedor2

Here's the debug output Huge Debug Output.txt

I noticed that if I press the buttons on the mouse, sometimes I would see this: [0:0:0] USBH DEVICE REMOVED Address = 1 HID close tuh_hid_umount_cb 1 0 HUB close hcd_device_close 1 and then the same initialization sequence recorded in the file would commence.

ww123td avatar Apr 07 '23 12:04 ww123td

I was maybe expecting some errors during enumeration, but that seems to go through OK.

Is there any further output when you move the ball or press the buttons (when it doesn't cause a disconnect)?

jfedor2 avatar Apr 07 '23 15:04 jfedor2

No, I could not get any output when I interact with the mouse.

I did manage to replicate a separate issue where the Pico would sometimes not recognize any HID device after plugging in the Huge trackball, here are the debug outputs:

Huge Debug Output 1.txt In this one I started by removing the [already attached] Huge trackball, then tried to reattach the device twice, then plugged in my known good mouse for the last time.

Huge Debug Output 2.txt This one might be user error, I started by attaching the known good mouse, removing it then reattaching causing a panic.

Hope some of these can aid in pinning down the issue.

ww123td avatar Apr 07 '23 21:04 ww123td

Yeah, you can see some errors in those. But it would be good to catch the moment when it first goes wrong. Because the first log looks normal. Does it send nothing on the serial port after that when you interact with the trackball?

One things that's perhaps unusual is that wMaxPacketSize is 8 bytes even though it's a Full Speed device so one could expect it to be 64, but I think that's legal and I don't see any obvious place where it would cause issues.

jfedor2 avatar Apr 08 '23 13:04 jfedor2

Yeah, it didn't send anything after that, I had to power cycle the Pico to get it to send any input to the computer.

I had been unable to recreate the issue since, so there's nothing new to look at from my end.

On Sat, Apr 8, 2023 at 6:02 AM Jacek Fedoryński @.***> wrote:

Yeah, you can see some errors in those. But it would be good to catch the moment when it first goes wrong. Because the first log looks normal. Does it send nothing on the serial port after that when you interact with the trackball?

One things that's perhaps unusual is that wMaxPacketSize is 8 bytes even though it's a Full Speed device so one could expect it to be 64, but I think that's legal and I don't see any obvious place where it would cause issues.

— Reply to this email directly, view it on GitHub https://github.com/jfedor2/hid-remapper/issues/54#issuecomment-1500887470, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKANG7UIT4WTFE6WUDM6LDDXAFOXPANCNFSM6AAAAAAWTTMC3I . You are receiving this because you modified the open/close state.Message ID: @.***>

ww123td avatar Apr 09 '23 06:04 ww123td