I am trying to upload some code to an Arduino Nano that I bought from Amazon a while ago, but nothing is uploading. Here is the error that I am getting:
An error occurred while uploading the sketch
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x51
An error occurred while uploading the sketch
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x51
Can someone please help me find a solution to this?
Yes everything is selected correctly, I chose Arduino nano, and I have also tried using the old bootloader as suggested in the amazon reviews. I have also installed the CH340 driver as suggested in the reviews as well.
Hi @gangsta_gaming. In order to gather more information that might help us to troubleshoot your problem, I'm going to ask you to post the full output from an upload attempt when in verbose mode.
Please do this:
Select File > Preferences from the Arduino IDE menus.
Uncheck the checkbox next to Show verbose output during: 🗹 compilation
Check the checkbox next to Show verbose output during: ☐ upload.
Click the OK button.
Attempt an upload to the non-functional board, as you did before.
After the upload fails, you'll see a button on the right side of the orange bar in the Arduino IDE: Copy error messages. Click that button.
This copies the full output to the clipboard.
Open a forum reply here by clicking the Reply button.
Click the </> icon on the post composer toolbar.
This will add the forum's code block markup (```) to your reply to make sure the error messages are correctly formatted.
Press Ctrl+V.
This will paste the error output from the upload into the code block.
Move the cursor outside of the code tags before you add any additional text to your reply.
Arduino: 1.8.19 (Windows Store 1.8.57.0) (Windows 10), Board: "Arduino Nano, ATmega328P"
Sketch uses 20784 bytes (67%) of program storage space. Maximum is 30720 bytes.
Global variables use 523 bytes (25%) of dynamic memory, leaving 1525 bytes for local variables. Maximum is 2048 bytes.
C:\Users\mineb\OneDrive\Documents\ArduinoData\packages\arduino\tools\avrdude\6.3.0-arduino17/bin/avrdude -CC:\Users\mineb\OneDrive\Documents\ArduinoData\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf -v -patmega328p -carduino -PCOM5 -b115200 -D -Uflash:w:C:\Users\mineb\AppData\Local\Temp\arduino_build_583087/Parola_Scrolling.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:\Users\mineb\OneDrive\Documents\ArduinoData\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf"
Using Port : COM5
Using Programmer : arduino
Overriding Baud Rate : 115200
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0xca
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0xca
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0xca
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0xca
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0xca
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0xca
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0xca
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0xca
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0xca
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0xca
avrdude done. Thank you.
Problem uploading to board. See https://support.arduino.cc/hc/en-us/sections/360003198300 for suggestions.
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
A loopback test doesn't require any bootloader. It doesn't even require a working CPU. What is "the loopback test" anyway? For me, it suggests putting the CPU in reset and tying RX and TX together. Did you do that?
Please don't get sidetracked by the loopback test results. As I explained already, the test is expected to fail on any Arduino board that uses a CH340 USB to serial adapter chip, including the ELEGOO Nano.
Prepare ISP programmer
You will need an ISP programmer. If you don't have a programmer, you can use a spare Arduino board (including one of your other Nanos) as an "Arduino as ISP" programmer. Although the "Arduino as ISP" only works for programming targets of the AVR architecture, you can use boards of any architecture as an "Arduino as ISP" programmer.
I will refer to the board which will used as an "Arduino as ISP" as the "programmer board" from here on. The board you are burning the bootloader to will be referred to as the "target board".
Disconnect both Arduino boards from your computer.
Make the following connections between the programmer board and the target board.
Programmer
Target
10
RESET
11
11
12
12
13
13
5V
5V
GND
GND
Connect the programmer board to your computer with a USB cable.
Select File > Examples > 11.ArduinoISP > Arduino ISP from the Arduino IDE menus.
Select your programmer board from the Arduino IDE's Tools > Board menu.
Select the appropriate option from the Tools > Processor menu if using a Nano as a programmer.
Select the port of your programmer board from the Arduino IDE's Tools > Port menu.
Select Sketch > Upload from the Arduino IDE menus.
Wait for the upload to finish.
You are now ready to burn the bootloader using your "Arduino as ISP" programmer.
Burn Bootloader
Instructions for burning the bootloader:
Select the target board from the Tools > Board menu and any other custom Tools menus (e.g., Tools > Processor).
Select Tools > Programmer > Arduino as ISP from the Arduino IDE menus.
Select Tools > Burn Bootloader from the Arduino IDE menus.
Wait for the process to finish successfully.
Unplug the USB cable of the programmer board from the computer.
Disconnect the programmer from the target board.
Now connect the USB cable of the target board to your computer, select its port from the Tools > Port menu, and try uploading a sketch as usual.