Pololu Robotics & Electronics
Menu
My account Comments or questions? About Pololu Contact Ordering information Distributors

Pololu Forum

32U4 uploading never finishes

I’m trying to fire up a balboa robot I purchased a year or so ago on Windows 10. I’m following the User guide section 5.2 on Programming using Arduino IDE. Everything in section 5.1 seemed to go just fine (The COM port shows up in Device Manager as “Pololu A-Star 32U4”).

However, when I go to program balboa (using Arduino 1.8.12), the uploading… message just stays up for a long time until it times out. Everything else seems okay: Arduino/Tools/Board:Pololu A-Star 32U4, Arduino/Tools/Port is set to the Balboa (which says “Pololu A-Star 32U4” next to the port name), the Balboa LED13 goes from fast blinking to slower pulsing, which makes met think it’s dropped into bootloader mode, … but Uploading never finishes.

Any ideas on what to do here? I’ve already tried reinstalling the drivers, updating the drivers, restarting the Arduino IDE, replugging Balboa and restarting the computer. What else to try? Is there a chance my old Balboa board needs a bootloader update or something?

Hello.

I am sorry you are having trouble with the Balboa 32U4 robot. I will need more information to figure out what is happening. In the Arduino IDE, please open the File menu, select Preferences, click the checkbox to show verbose output during upload, and then click OK. Then try uploading to the Balboa 32U4 again. After it times out, please post the entire output from the Arduino IDE.

Also, what is the exact name of the port you have selected in the Port menu?

Could you provide screenshots of the Device Manager so I can see what is happening before and during the upload attempt? This will help me see what COM port your Balboa has been assigned to, and whether the computer is detecting its USB bootloader properly. Please make sure the “Ports (COM & LPT)” section and “Other devices” sections are expanded (if they are present).

–David

Hello David,

Thanks for the reply. The exact port name is “COM11 (Pololu A-Star 32U4)”

Here’s a screen shot of the device manager. All looks well to me:

Here is the output of the programming attempt with verbose output on:

Sketch uses 3980 bytes (13%) of program storage space. Maximum is 28672 bytes.
Global variables use 149 bytes (5%) of dynamic memory, leaving 2411 bytes for local variables. Maximum is 2560 bytes.
Forcing reset using 1200bps open/close on port COM11
PORTS {COM11, } / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {} => {}
PORTS {} / {COM11, } => {COM11, }
Found upload port: COM11
C:\arduino-1.8.12\hardware\tools\avr/bin/avrdude -CC:\arduino-1.8.12\hardware\tools\avr/etc/avrdude.conf -v -patmega32u4 -cavr109 -PCOM11 -b57600 -D -Uflash:w:C:\Users\casey\AppData\Local\Temp\arduino_build_564810/Blink.ino.hex:i

avrdude: Version 6.3-20190619
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2014 Joerg Wunsch

         System wide configuration file is "C:\arduino-1.8.12\hardware\tools\avr/etc/avrdude.conf"

         Using Port                    : COM11
         Using Programmer              : avr109
         Overriding Baud Rate          : 57600
         AVR Part                      : ATmega32U4
         Chip Erase delay              : 9000 us
         PAGEL                         : PD7
         BS2                           : PA0
         RESET disposition             : dedicated
         RETRY pulse                   : SCK
         serial program mode           : yes
         parallel program mode         : yes
         Timeout                       : 200
         StabDelay                     : 100
         CmdexeDelay                   : 25
         SyncLoops                     : 32
         ByteDelay                     : 0
         PollIndex                     : 3
         PollValue                     : 0x53
         Memory Detail                 :

                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           eeprom        65    20     4    0 no       1024    4      0  9000  9000 0x00 0x00
           flash         65     6   128    0 yes     32768  128    256  4500  4500 0x00 0x00
           lfuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
           hfuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
           efuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
           lock           0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00

         Programmer Type : butterfly
         Description     : Atmel AppNote AVR109 Boot Loader

Connecting to programmer: .avrdude: butterfly_recv(): programmer is not responding

avrdude: butterfly_recv(): programmer is not responding
Problem uploading to board.  See http://www.arduino.cc/en/Guide/Troubleshooting#upload for suggestions.

While the Balboa is in bootloader mode, normally there would be a new COM port with a different number representing the bootloader. But the debug output from your Arduino IDE shows us that the COM port for the Balboa’s bootloader never appears. When the bootloader times out and the Balboa goes back to running the sketch, COM11 reappears. (The Arduino IDE then guesses that COM11 might be the bootloader, so it tries to upload your code to it, but the sketch is not designed to respond to any of the commands from AVRDUDE so that does not work.)

Could you look at the Device Manager carefully during the upload attempt, and provide a screenshot of it so I can see what is happening? Please make sure the “Ports (COM & LPT)” section and “Other devices” sections are expanded (if they are present).

–David

Hi David. Your explanation seems to be exactly what is happening. When the upload output is repeating “PORTS {} / {} => {}” the Pololu A-Star 32U4 has dissappeared from the device manager. No other devices show up under Ports or Other devices (both of those categories are missing during this phase). After that the COM11 port returns, Arduino tries to program that port and the upload files. So, the bootloader never appears. Can I update the bootloader somehow?

Here’s the device manager screen shot:

It is possible to re-flash the bootloader with an AVR programmer but I do not recommend doing that yet. Since your robot’s USB connection is working at a basic level, and the bootloader is running (as indicated by the slow pulsing LED), I suspect there is an issue on your computer preventing the bootloader from using its correct driver.

I think we should see if the computer recognizes the bootloader at all. In the Device Manager, please select “Pololu A-Star 32U4”, then open the “View” menu and select “Devices by Connection”. Please take a screenshot so we can see what USB controllers and hubs the Balboa is connected to. Then, during an Arduino IDE upload attempt, please take another screenshot so we can see what kind of device (if any) appears in that same place to represent the bootloader.

–David

Here’s a screen shot of device manager, in Devices By Connection View normally:

During the upload the Balboa entry dissappears and nothing else seems to take it’s place:

The behavior is unchanged: still can’t upload blink (or anything else). Thanks.

Thank you for the screenshots. It looks like there is no device appearing to represent the bootloader. It also looks like your Balboa might be connected to your computer via a chain of two USB hubs, though it is hard to be sure. Can you try connecting the Balboa directly to one of the USB ports of your computer without using any hubs if it is not connected like that already? When the Balboa is connected directly, do you see any device in the Device Manager during the upload attempt that might represent the bootloader? Could you try a few different USB ports to see if that makes a difference?

Were you ever able to upload to the Balboa successfully before? Do you have another computer you could try?

–David