Pimoroni Pico RGB Keypad Base disappearing

CircuitPython on hardware including Adafruit's boards, and CircuitPython libraries using Blinka on host computers.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
savt22
 
Posts: 4
Joined: Mon Nov 29, 2021 1:02 pm

Pimoroni Pico RGB Keypad Base disappearing

Post by savt22 »

Hi,

I have been working on creating a pico-powered MIDI chord player using the Pimoroni RGB Keypad Base. I've got the code working, and when I initially set it up it does exactly what I want it to.

However, if I restart my Mac, or unmount/remount the Pico, the Pico powers on and the keypad lights up as expected, but my mac no longer recognises it. It doesn't show up as a CIRCUITPY removable drive anymore, it's no longer available as a MIDI device, and the MIDI signals aren't received.

The process I've been doing is:

BOOTSEL -> flash Pico with the CircuitPython 7.0.0 build for the Pico.
Pico reboots and CIRCUITPY.
I drag and drop Keybow 2040, dotstar, and Adafruit_midi lib files into CIRCUITPY lib.
I sudo nano into code.py, and paste in my code (https://github.com/savt22/2040_midi_cho ... in/code.py). cntrl + x, save code.py changes.

At this point, everything works fine. My mac sees it as a midi device, it lights up, and I can use it. It works perfectly.

However...

If I restart my mac, or eject and restart the pico, the pico comes on and the base lights up with the right keypad lighting and the lights respond to key presses as it's coded to do, suggesting the code is running, but my mac (M1 mini, Mac OS Monterey) can no longer see it. It's not mounted on the desktop, isn't in system information, and none of the midi keys are detected.

Am I missing an important step here? It seems like there's a step I need to take or a piece of code I'm missing to get it seen by whatever device I'm plugging it in to.

User avatar
tannewt
 
Posts: 3314
Joined: Thu Oct 06, 2016 8:48 pm

Re: Pimoroni Pico RGB Keypad Base disappearing

Post by tannewt »

This sounds like a USB bug in CircuitPython. Please try 7.1.0-beta.0. It has a newer version of TinyUSB that may have fixed the issue. (Also try the absolute latest if the beta doesn't work.)

User avatar
savt22
 
Posts: 4
Joined: Mon Nov 29, 2021 1:02 pm

Re: Pimoroni Pico RGB Keypad Base disappearing

Post by savt22 »

Thank you for the quick reply and suggestions.

I tried both 7.1 and 6.2, but both had the same issue.

However... I got the opportunity to try it on a Windows computer this morning, and it works as excepted. It seems like there might be something stopping it from connecting to my mac properly... I'm using an M1 Mac mini with Monterey. I'll have a look around to see if anyone has had similar issues. It's weird that going through the initial setup and flashing the pico lets it read it as CIRCUITPY usb device without issue, but not after a hard reset.

The mac definitely notices it, as it pauses audio for a second when I plug it in. On Windows it comes up as D:, but nothing on mac. No indication that anything at all is plugged in.

I tried adding in a boot.py file that disables USB HID, enables USB MIDI, and enables USB storage. I also added a time delay to boot. Still working on Windows, but not Mac.

User avatar
savt22
 
Posts: 4
Joined: Mon Nov 29, 2021 1:02 pm

Re: Pimoroni Pico RGB Keypad Base disappearing

Post by savt22 »

Hi - on the console, I get 6 errors when plugging in the USB.

130345.648474 IOUSBHostDevice@02241000: IOUSBHostDevice::start_block_invoke: device descriptor fragment is invalid
130345.651657 IOUSBHostFamily::validateEndpointMaxPacketSize: USB 2.0 5.[5-8].3: endpoint 0x00 invalid wMaxPacketSize 0x0000
130345.651866 AppleUSB20HubPort@02241000: AppleUSBHostPort::enumerateDeviceComplete_block_invoke: enumeration failed
130345.651890 AppleUSB20HubPort@02241000: AppleUSBHostPort::terminateDevice: destroying 0x0000/0000/0000 (IOUSBHostDevice): enumeration failure
130345.651963 AppleUSB20HubPort@02241000: AppleUSBHostPort::disconnect: persistent enumeration failures
130345.651990 IOUSBHostDevice@02241000: IOUSBHostDevice::start_block_invoke: device will not be registered for matching

Any ideas of things I could try would be greatly appreciated!

User avatar
tannewt
 
Posts: 3314
Joined: Thu Oct 06, 2016 8:48 pm

Re: Pimoroni Pico RGB Keypad Base disappearing

Post by tannewt »

Please file an issue here: https://github.com/adafruit/circuitpyth ... report.yml

I think we have other folks in our community with M1 macs that can try it.

User avatar
savt22
 
Posts: 4
Joined: Mon Nov 29, 2021 1:02 pm

Re: Pimoroni Pico RGB Keypad Base disappearing

Post by savt22 »

Great, I'll post there now. Thank you!

EDIT - I have since tried mounting it on an older Intel iMac running El Capitan, and it presents the same issue. I've added this info into the bug I submitted.

Locked
Please be positive and constructive with your questions and comments.

Return to “Adafruit CircuitPython”