Trinket M0 Upload Problem - USB Device Not Recognized

For Adafruit customers who seek help with microcontrollers

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
cgiverin
 
Posts: 2
Joined: Tue May 15, 2018 12:23 pm

Trinket M0 Upload Problem - USB Device Not Recognized

Post by cgiverin »

Hello,

I have four Trinket M0 microcontrollers and have run into an upload issue on my Arduino IDE 1.8.5 software for all four boards. I was first able to upload to one board and have been working happily with that board (with minor confusion when the ports would keep changing), then suddenly I received a windows notification "USB Device Not Recognized". Now nothing works, even when switching to one of the other unused boards.

I tried double pressing the reset button at various times during uploading and without uploading and can get into "Bootloader Mode" with the pulsing red light but whenever I get it to show up on the com port without being an "Unknown Device" I try to upload and receive the "USB Device Not Recognized" message.

I tried uninstalling the board drivers and reinstalling them without any luck as well as trying three different USB cables.

I read through and followed all of the Windows driver installation and Arduino IDE Setup pages. Is there something I am doing wrong? I am using Windows 7 Enterprise.

User avatar
adafruit_support_mike
 
Posts: 67485
Joined: Thu Feb 11, 2010 2:51 pm

Re: Trinket M0 Upload Problem - USB Device Not Recognized

Post by adafruit_support_mike »

First, verify the USB cables by using them to connect some other, known-working device to the computer. There’s a plague of charge-only cables out there with USB connectors at both ends, but no wires for the data signals. We see people get caught by them every day, and it’s normal for people to say they had to try three or four cables before finding one that actually worked.

User avatar
cgiverin
 
Posts: 2
Joined: Tue May 15, 2018 12:23 pm

Re: Trinket M0 Upload Problem - USB Device Not Recognized

Post by cgiverin »

Thank you for getting back to me so quickly! I solved the issue in a very odd way. I just fixed a single typo for while(start = 0) instead of while(start == 0) and it uploaded no problem. I then put the typo back and I get the Windows "USB Device Not Recognized" error all over again. Very weird.

User avatar
adafruit_support_mike
 
Posts: 67485
Joined: Thu Feb 11, 2010 2:51 pm

Re: Trinket M0 Upload Problem - USB Device Not Recognized

Post by adafruit_support_mike »

Hmm.. interesting.

The assignment-instead-of-equality typo is a common one, but that particular error should reduce to while(0) which will never execute the block it controls. I’d imagine the optimizer would simply remove that whole block of code from the executable.

How that translates to an upload problem I can’t say. Glad to hear you got things working though. Happy hacking!

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

Return to “Microcontrollers”