0

I followed this guide to setup my Pi Zero W as a keyboard HID. Connected it to a laptop (via the data USB, not the power) to see no effect. When I started investigating, I saw that dmesg is showing the following errors when I connect the Pi Zero to my Linux laptop:

[5438430.923017] usb 1-1: new high-speed USB device number 66 using xhci_hcd
[5438436.307148] usb 1-1: device descriptor read/64, error -110
[5438451.923484] usb 1-1: device descriptor read/64, error -110
[5438452.163467] usb 1-1: new high-speed USB device number 67 using xhci_hcd
[5438457.299567] usb 1-1: device descriptor read/64, error -110
[5438472.919856] usb 1-1: device descriptor read/64, error -110
[5438473.027879] usb usb1-port1: attempt power cycle
[5438473.679853] usb 1-1: new high-speed USB device number 68 using xhci_hcd
[5438479.059979] usb 1-1: device descriptor read/64, error -110
[5438494.676268] usb 1-1: device descriptor read/64, error -110
[5438494.912270] usb 1-1: new high-speed USB device number 69 using xhci_hcd
[5438500.052383] usb 1-1: device descriptor read/64, error -110
[5438515.668687] usb 1-1: device descriptor read/64, error -110
[5438515.776709] usb usb1-port1: unable to enumerate USB device

A quick search for that error seemed to imply that it's something power-related, but I couldn't figure out what. It seems like Pi Zero does get enough power from the USB to fully boot up, I can easily SSH into it while it's connected to the computer, just the the computer it's connected to seems to think something is wrong. I tried several OTG cables, which work fine for connecting phone to PC. My kernel and GPU firmware are both from Mar 2018 (much newer than the pre-2016 versions that gave issues to some). Has anyone run into this?

EDIT Other observations:

  • gadget does not seem to be recognized in either Linux, OSX, or Windows (on Linux, I can tell that dmesg is reacting to it, but showing -110 error)
  • Seems like the gadget is now being recognized as "full-speed" instead of "high-speed" when plugged in, I'm not sure if the issue is the cable or something else, it was the same cables I was using yesterday, so I'm not sure
  • Plugging Pi Zero into laptop's own USB port results in it failing to configure itself as a gadget but remaining on otherwise (so I can ssh in), plugging the same Pi Zero (with the same cable) into the docking station USB of the same laptop results in a bootloop, with a forced reboot after dmesg fails to mount the device.
3
  • My kernel and GPU firmware are both from Mar 2018 - have you tried a more recent image, Feb 2020 - also, is that dmesg log on the laptop? Commented Apr 29, 2020 at 3:12
  • Ran rpi-update, the kernel is now from Apr 27 2020, issue persists. And yes, the dmesg is on the laptop the pi is being connected to, so it sees that something is there but fails to initialize it. Commented Apr 29, 2020 at 4:01
  • try a base raspbian install without doing rpi-update - you should only use rpi-update if you know what you're doing Commented Apr 29, 2020 at 4:08

1 Answer 1

0

I found the issue, it was in fact the SD card. Pi Zero had no problems recognizing it, but it wasn't good enough for the laptop I was eventually plugging Pi Zero in. Figured out this might be the issue when dmesg was still complaining about the card when I connected it to the laptop directly. Once I tried a different SD Card, Pi HID config came through.

1
  • i find it interesting it was the SD card. why would the PC care when the SD card is in the pi? power draw? I'm having similar issues with a pizero and sandisk SD card.
    – roocell
    Commented Feb 7, 2021 at 0:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.