Feather 32u4 Can not upload - DOA?

For other supported Arduino products from Adafruit: Shields, accessories, etc.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
User avatar
adafruit2
 
Posts: 22200
Joined: Fri Mar 11, 2005 7:36 pm

Re: Feather 32u4 Can not upload - DOA?

Post by adafruit2 »

hey it turns out this isnt probably a hardware problem after all - if you already got your replacement you can keep it but the real solution is here

viewtopic.php?f=58&t=136982&p=678493#p678493

User avatar
xris
 
Posts: 12
Joined: Mon Mar 07, 2016 6:04 am

Re: Feather 32u4 Can not upload - DOA?

Post by xris »

I am having the exact same issue. I get a USB disconnect within a few seconds despite changing ports (USB 3 or 2), changing USB cables, trying with a lipo, and trying on two different systems. I am very skeptical this is related to the arduino site call as last posted - just to entertain the notion I tried blocking the domain via the linked /etc/hosts recommendation which did nothing.

As with OP I get brief enumeration and then disconnect - via dmesg -Tw
[Thu Aug 9 11:01:54 2018] usb 1-9: new full-speed USB device number 41 using xhci_hcd
[Thu Aug 9 11:01:54 2018] usb 1-9: New USB device found, idVendor=239a, idProduct=000c, bcdDevice= 0.01
[Thu Aug 9 11:01:54 2018] usb 1-9: New USB device strings: Mfr=2, Product=1, SerialNumber=0
[Thu Aug 9 11:01:54 2018] usb 1-9: Product: Adafruit Feather
[Thu Aug 9 11:01:54 2018] usb 1-9: Manufacturer: Adafruit In
[Thu Aug 9 11:01:54 2018] cdc_acm 1-9:1.0: ttyACM0: USB ACM device
[Thu Aug 9 11:02:04 2018] usb 1-9: USB disconnect, device number 41

In the IDE port is briefly not grey - not enough time to seemingly get any useful information. verbose info as follows
Forcing reset using 1200bps open/close on port /dev/ttyACM0
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
[last line repeats likely until disconnect then]
PORTS {/dev/ttyACM0, } / {} => {}
PORTS {} / {} => {}
[last line repeats then]
Couldn't find a Board on the selected port. Check that you have the correct port selected. If it is correct, try pressing the board's reset button after initiating the upload.

As OP did I am added to the owner group for tty's, and followed adafruit instructions for board setup.

I tested another arduino board (metro mini with a position sensor) to verify that something more global wasn't going on - but this board upload and serial monitoring works just fine.

Main testing on an up to date Arch Linux system. Also tested on Fedora.

Board was purchased via amazon: https://www.amazon.com/gp/product/B018U4PPYS

This is super frustrating as was about to use this as a core testing sensor device for a medical research project.

Please advise.

User avatar
adafruit_support_carter
 
Posts: 29483
Joined: Tue Nov 29, 2016 2:45 pm

Re: Feather 32u4 Can not upload - DOA?

Post by adafruit_support_carter »

As OP did I am added to the owner group for tty's, and followed adafruit instructions for board setup.
Did that include the udev rules setup?
https://learn.adafruit.com/adafruit-ard ... udev-rules

User avatar
xris
 
Posts: 12
Joined: Mon Mar 07, 2016 6:04 am

Re: Feather 32u4 Can not upload - DOA?

Post by xris »

I had not done explicitly those udev rules, but using them made no difference. Those rules should not be applied without scrutiny...

Ownership of my /dev/ttyACM0 is as follows by default (e.g. via ls -al)
crw-rw---- 1 root uucp 166, 0 Aug 9 13:40 ttyACM0

I put the following modified rules from the adafruit template in /etc/udev/rules.d/nano 99-adafruit-boards.rules
# udev rules for Adafruit's boards like Trinket, Gemm/a, Flora, Bluefruit Micro, etc.
#
# note for arch need to run the following for reloading rules manually:
# sudo udevadm control --reload
# see https://wiki.archlinux.org/index.php/udev

# Rule to make Trinket/Pro Trinket/Gemma/Flora programmable without running Arduino as root.
# Tested with Ubuntu 14.04 and 12.04. Other distributions might need to update GROUP="dialout"
# to another group value like "users".

# **x: note for my system as above using uucp, not dialout (and yes my user is a member)
#SUBSYSTEM=="usb", ATTRS{idProduct}=="0c9f", ATTRS{idVendor}=="1781", MODE="0660", GROUP="dialout"
SUBSYSTEM=="usb", ATTRS{idProduct}=="0c9f", ATTRS{idVendor}=="1781", MODE="0660", GROUP="uucp"

# Rule to blacklist Adafruit USB CDC boards from being manipulated by ModemManager.
# Fixes issue with hanging references to /dev/ttyACM* devices on Ubuntu 15.04.
# **x: following line is the default
ATTRS{idVendor}=="239a", ENV{ID_MM_DEVICE_IGNORE}="1"

# Circuit Playground
# General rule (actually covers all Adafruit boards with same USB VID):
# **x: when this is uncommented /dev/ttyACM0 has default group ownership switched from uucp to that listed here (default: adm)
# tried both default GROUP (adm) & setting group to uucp to match above - did not resolve usb disconnect
#ATTRS{idVendor}=="239a", MODE="0660", GROUP="adm"
ATTRS{idVendor}=="239a", MODE="0660", GROUP="uucp"

This made no difference on the rapid USB disconnect. As per above, I tried with subsystem uucp group, and tried both adm & uucp groups for the general ATTRS rule to no avail. I tried a restart for good measure which did not help (just in cause udev rules were not reloaded by the above command in comments - they seemed to be given group ownership switch on USB connect).

User avatar
adafruit2
 
Posts: 22200
Joined: Fri Mar 11, 2005 7:36 pm

Re: Feather 32u4 Can not upload - DOA?

Post by adafruit2 »

when you double click the reset button do you get a pulsing red led and a USB device (check lsusb or dmesg)

see https://learn.adafruit.com/adafruit-fea ... help#faq-4 as well

User avatar
xris
 
Posts: 12
Joined: Mon Mar 07, 2016 6:04 am

Re: Feather 32u4 Can not upload - DOA?

Post by xris »

Re-inserting the device, pushing the reset once, or pushing the reset twice yields the following.

dmesg -Tw
[Thu Aug 9 14:01:36 2018] usb 1-3: new full-speed USB device number 19 using xhci_hcd
[Thu Aug 9 14:01:36 2018] usb 1-3: New USB device found, idVendor=239a, idProduct=000c, bcdDevice= 0.01
[Thu Aug 9 14:01:36 2018] usb 1-3: New USB device strings: Mfr=2, Product=1, SerialNumber=0
[Thu Aug 9 14:01:36 2018] usb 1-3: Product: Adafruit Feather
[Thu Aug 9 14:01:36 2018] usb 1-3: Manufacturer: Adafruit In
[Thu Aug 9 14:01:36 2018] cdc_acm 1-3:1.0: ttyACM0: USB ACM device
[Thu Aug 9 14:01:46 2018] usb 1-3: USB disconnect, device number 19

The red LED close to USB input on device blinks/pulses about 8 times.

lsusb [note the device matches the dmesg, following was a separate trial]
Bus 001 Device 022: ID 239a:000c

Thanks for any recs on getting this working.

User avatar
adafruit2
 
Posts: 22200
Joined: Fri Mar 11, 2005 7:36 pm

Re: Feather 32u4 Can not upload - DOA?

Post by adafruit2 »

follow that faq above, your feather is fine, the bootloader is there, you just have to upload a fresh Blink sketch or something

User avatar
adafruit_support_carter
 
Posts: 29483
Joined: Tue Nov 29, 2016 2:45 pm

Re: Feather 32u4 Can not upload - DOA?

Post by adafruit_support_carter »

Main testing on an up to date Arch Linux system. Also tested on Fedora.
Do you have any other OS's you can test against?

User avatar
xris
 
Posts: 12
Joined: Mon Mar 07, 2016 6:04 am

Re: Feather 32u4 Can not upload - DOA?

Post by xris »

As stated the device disconnects rapidly within a few seconds, precluding uploading of any sketches.

E.g. if I hit the reset button and immediately hit upload for the blink test with addition of a serial print line - it yields the following output. After a few seconds the port gets greyed out, preceding this, the appropriate port is mapped before the timeout.

Global variables use 163 bytes of dynamic memory.
Forcing reset using 1200bps open/close on port /dev/ttyACM0
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
PORTS {/dev/ttyACM0, } / {/dev/ttyACM0, } => {}
Uploading using selected port: /dev/ttyACM0
/home/MYUSERNAME/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino9/bin/avrdude -C/home/MYUSERNAME/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino9/etc/avrdude.conf -v -patmega32u4 -cavr109 -P/dev/ttyACM0 -b57600 -D -Uflash:w:/tmp/arduino_build_392884/Blinkprint.ino.hex:i

avrdude: Version 6.3, compiled on Jan 17 2017 at 11:00:16
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2014 Joerg Wunsch

System wide configuration file is "/home/MYUSERNAME/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino9/etc/avrdude.conf"
User configuration file is "/home/MYUSERNAME/.avrduderc"
User configuration file does not exist or is not a regular file, skipping

Using Port : /dev/ttyACM0
Using Programmer : avr109
Overriding Baud Rate : 57600
avrdude: ser_open(): can't open device "/dev/ttyACM0": No such file or directory

avrdude done. Thank you.

Problem uploading to board. See http://www.arduino.cc/en/Guide/Troubleshooting#upload for suggestions.

User avatar
xris
 
Posts: 12
Joined: Mon Mar 07, 2016 6:04 am

Re: Feather 32u4 Can not upload - DOA?

Post by xris »

So I think I finally got it to work. I hit upload sketch a millisecond or so after hitting the reset button and after ~5 trials it was able to complete the upload before the disconnect. Once the sketch is uploaded the disconnect does not occur, port stays active in and outside of the IDE, and the serial monitor can be followed.

Is there a reason the device can get into the rapid auto-disconnect state? If this happens again any recommendations for avoiding the speed upload olympics? Given this has not happened with other arduino/adafruit devices I wonder if something is still wrong with the device...

User avatar
adafruit_support_carter
 
Posts: 29483
Joined: Tue Nov 29, 2016 2:45 pm

Re: Feather 32u4 Can not upload - DOA?

Post by adafruit_support_carter »


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

Return to “Other Arduino products from Adafruit”