About a year ago I ordered a few very cheap arduino nanos with ATmega 328 on ebay. Back then I used one of them for a project and it worked fine.
Now I started a new project but I cant copy it to the arduino. I tried 3 different ones...
The arduino seems to work. The led, which is connected to pin 13, is blinking. The driver is installed on my PC and it whows up as "USB-SERIAL CH340(COM4)" in the device manager. It alsso shows up in the IDE as "COM4". I have set it to Arduino nano whith ATmega 328.
The project compiles and on that orange bar ist says "Uploading..." for a while (over 1 minute). Then the console outputs:
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x5e
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x5e
.
.
.
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x5e
I tried it on my MacBook and on my windows 10 PC. Both with the same result.
I followed steps 1 - 3. Same result with a different cable.
Here is the verbose output of the IDE:
Build options changed, rebuilding all
Sketch uses 1,066 bytes (3%) of program storage space. Maximum is 30,720 bytes.
Global variables use 9 bytes (0%) of dynamic memory, leaving 2,039 bytes for local variables. Maximum is 2,048 bytes.
C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avrdude -CC:\Program Files (x86)\Arduino\hardware\tools\avr/etc/avrdude.conf -v -patmega328p -carduino -PCOM4 -b57600 -D -Uflash:w:C:\Users\gyano\AppData\Local\Temp\build9c9ef3bdfe2fccb480bc6e4bac749e41.tmp/Blink.ino.hex:i
avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "C:\Program Files (x86)\Arduino\hardware\tools\avr/etc/avrdude.conf"
Using Port : COM4
Using Programmer : arduino
Overriding Baud Rate : 57600
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0xd8
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0xd8
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0xd8
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0xd8
.
.
.
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0xd8
avrdude done. Thank you.
Problem uploading to board. See http://www.arduino.cc/en/Guide/Troubleshooting#upload for suggestions.
This was the output for a different arduino:
Build options changed, rebuilding all
Sketch uses 1,066 bytes (3%) of program storage space. Maximum is 30,720 bytes.
Global variables use 9 bytes (0%) of dynamic memory, leaving 2,039 bytes for local variables. Maximum is 2,048 bytes.
C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avrdude -CC:\Program Files (x86)\Arduino\hardware\tools\avr/etc/avrdude.conf -v -patmega328p -carduino -PCOM4 -b57600 -D -Uflash:w:C:\Users\gyano\AppData\Local\Temp\build9c9ef3bdfe2fccb480bc6e4bac749e41.tmp/Blink.ino.hex:i
avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "C:\Program Files (x86)\Arduino\hardware\tools\avr/etc/avrdude.conf"
Using Port : COM4
Using Programmer : arduino
Overriding Baud Rate : 57600
AVR Part : ATmega328P
Chip Erase delay : 9000 us
PAGEL : PD7
BS2 : PC2
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 3600 3600 0xff 0xff
flash 65 6 128 0 yes 32768 128 256 4500 4500 0xff 0xff
lfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
efuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
lock 0 0 0 0 no 1 0 0 4500 4500 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 : Arduino
Description : Arduino
Hardware Version: 2
Firmware Version: 1.16
Vtarget : 0.0 V
Varef : 0.0 V
Oscillator : Off
SCK period : 0.1 us
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.00s
avrdude: Device signature = 0x1e950f
avrdude: reading input file "C:\Users\gyano\AppData\Local\Temp\build9c9ef3bdfe2fccb480bc6e4bac749e41.tmp/Blink.ino.hex"
avrdude: writing flash (1066 bytes):
Writing | ################################################## | 100% 0.32s
avrdude: 1066 bytes of flash written
avrdude: verifying flash memory against C:\Users\gyano\AppData\Local\Temp\build9c9ef3bdfe2fccb480bc6e4bac749e41.tmp/Blink.ino.hex:
avrdude: load data flash data from input file C:\Users\gyano\AppData\Local\Temp\build9c9ef3bdfe2fccb480bc6e4bac749e41.tmp/Blink.ino.hex:
avrdude: input file C:\Users\gyano\AppData\Local\Temp\build9c9ef3bdfe2fccb480bc6e4bac749e41.tmp/Blink.ino.hex contains 1066 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 0.24s
avrdude: verifying ...
avrdude: verification error, first mismatch at byte 0x0000
0xff != 0x0c
avrdude: verification error; content mismatch
avrdude done. Thank you.
The loop back test does not work. When I send something to the arduino the tx and rx leds are blinking, but nothing gets echoed back ;(
I have only one working arduino. But there is a project loaded on it, which I dont have on my PC anymore, so I can't delete it.
NuclearVirus:
The loop back test does not work. When I send something to the arduino the tx and rx leds are blinking, but nothing gets echoed back ;(
Then the problem is likely to be there... If you don't get a loopback then there is no need to reburn/mess with the bootloader etc. Did you indeed connect a wire between GND and RST to keep the Arduino in reset while testing?
In the device manager, does it show up without a ! ?
And are you 100% sure it's com4?
Yes. There was a wire between gnd and rst and one between tx and rx.
I added a screenshot from the device manager and the IDE as attachment
Is there nothing else I can do? I can't believe that 3 arduinos dont work...
You need to have a working loop back test for the serial programming to work.
Since 2 computers with 2 different OS's and 2 different cables and 3 different Nano's and nothing works, I don't know. This is pretty hard to figure out.
I suppose you could delete the CG340G drivers and download and re-install them.
Try a Linux computer, or set up one of your existing computers to dual boot so you can try Linux.
See if you can find somebody in your area, such as a club or a meet-up, there is a section of the forums for that. Running out of ideas here...
It's indeed pretty weird the CH340 seems to be installed correct but you have no loopback. Loopback is the most basic thing that should work...
It could be the cables. They are both pretty cheap looking. But they both work with other stuff.
What about the other error I got?:
avrdude: verification error, first mismatch at byte 0x0000
0xff != 0x0c
On of the 3 arduinos gives me that output.
The connection seems to work in one direction, because the tx and rx lights both light up, when doing the loop back test.