Go Down

Topic: Uno is rejecting my uploads, arrg! (Read 8007 times) previous topic - next topic

The Ideanator

Nov 19, 2010, 10:24 pm Last Edit: Nov 19, 2010, 10:29 pm by The_Ideanator Reason: 1
Ok, I recently bought an UNO from Sparkfun, opened it up (yay! stickers!) and got the arduino out, plugged it in, set it up with a virtual serial port (5) and tried uploading some code:
Quote

void setup() {
     Serial.begin(9600);      // opens serial port, sets data rate to 9600 bps
}

void loop() {
  Serial.println("test");
  delay(1000);
}



Obviously it compiles just fine (the IDE says it also), but when it tries to upload it, I get this message:

avrdude: stk500_getsync(): not in sync: resp=0xf9
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x51


I try uploading it with the reset button pressed, and I get this:

avrdude: stk500_getsync(): not in sync: resp=0x00
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x51


I then changed boards to the Duemilanove and it uploads and runs just fine.

I am running the 0021 IDE, since thats the recommended version for the UNO, but I tried this with 0017, 0018, and 0019, and I get the same messages. I went through the /troubleshooting#upload, but to no avail.

extra info:
I'm on a vista (32 bit)
Everything is up to date as far as I know
I am using the 0021 Arduino IDE software

Coding Badly

Quote
set it up with a virtual serial port (5)

Using Device Manager?  Why did you change from the port assigned by the operating system?

The Ideanator

Yea, using the device manager. It seemed to not want to initialize properly when I first plugged it in, it showed up as an unknown device, so port 5 is the one that it was assigned by the system.

Coding Badly

Quote
it showed up as an unknown device

In Device Manager, is it still displayed as an unknown device?

The Ideanator

Quote
is it still displayed as an unknown device


No, I did something to it, don't remember what, I think it _might_ have been right click > update driver, and it went right to COM5.
I tried the driver update with it under COM5, but it already has the latest drivers.

Coding Badly


Anything here help...
http://arduino.cc/en/Guide/Windows

The Ideanator

Nope, no help from that.
I reinstalled it, gave it the location of the drivers and such (which is what I did before) and it says the same exact thing.

Coding Badly

#7
Nov 20, 2010, 08:24 am Last Edit: Nov 20, 2010, 08:25 am by bcook Reason: 1

When you upload, hold down the shift key.  The AVRDUDE command should be displayed in the bottom panel.  Copy and paste that here.

Arduino Malaysia

#8
Nov 20, 2010, 04:39 pm Last Edit: Nov 20, 2010, 04:42 pm by arduino-malaysia Reason: 1
Just to pitch in that I have same problem but with Arduino BT (Bluetooth virtual serial port instead of USB serial port).

It start as my question on how to power up the board. The discussion is here
  http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1288423067/0#12

Let me paste the error message

Quote

Binary sketch size: 1010 bytes (of a 28672 byte maximum)
D:\App\arduino-0021\hardware/tools/avr/bin/avrdude -CD:\App\arduino-0021\hardware/tools/avr/etc/avrdude.conf -v -v -v -v -patmega328p -cstk500v1 -P\\.\COM3 -b19200 -D -Uflash:w:C:\Users\MyName\AppData\Local\Temp\build7010162337971221665.tmp\BTBlink.cpp.hex:i

avrdude: Version 5.4-arduino, compiled on Oct 11 2007 at 19:12:32
        Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/

        System wide configuration file is "D:\App\arduino-0021\hardware/tools/avr/etc/avrdude.conf"

        Using Port            : \\.\COM3
        Using Programmer      : stk500v1
        Overriding Baud Rate  : 19200
avrdude: ser_open(): setting dtr
avrdude: Send: 0 [30]   [20]
avrdude: Send: 0 [30]   [20]
avrdude: Send: 0 [30]   [20]
avrdude: Recv:
avrdude: stk500_getsync(): not in sync: resp=0x00
avrdude: Send: Q [51]   [20]
avrdude: Recv:
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x51

avrdude done.  Thank you.


The weird thing is that baud rate is 19200 even though set upload speed to 115200 or 9600 by setting serial.download_rate in preferences.txt.

Anyway, pardon me if this looks like hijacking the thread. I just want to point out that this is similar problem. Please ignore if the info provided is not relevant.

Searching on the internet seems like lots of people is suffering from this problem more so when the board is Arduino BT.

Forget to add : Using Arduino-0021 on Win7 64 bit. Arduino BT is powered using 4 AA batteries 1.2V each.

The Ideanator

Here is the AVRDUDE output:

Quote
Binary sketch size: 2570 bytes (of a 30720 byte maximum)
D:\Beta\projects\programming\Arduino\arduino-0021\hardware/tools/avr/bin/avrdude -CD:\Beta\projects\programming\Arduino\arduino-0021\hardware/tools/avr/etc/avrdude.conf -v -v -v -v -patmega328p -cstk500v1 -P\\.\COM5 -b57600 -D -Uflash:w:C:\Users\THEENG~1\AppData\Local\Temp\build7970296644683139626.tmp\sketch_nov20a.cpp.hex:i

avrdude: Version 5.4-arduino, compiled on Oct 11 2007 at 19:12:32
        Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/

        System wide configuration file is "D:\Beta\projects\programming\Arduino\arduino-0021\hardware/tools/avr/etc/avrdude.conf"

        Using Port            : \\.\COM5
        Using Programmer      : stk500v1
        Overriding Baud Rate  : 57600
avrdude: ser_open(): setting dtr
avrdude: Send: 0 [30]   [20]
avrdude: Send: 0 [30]   [20]
avrdude: Send: 0 [30]   [20]
avrdude: Recv:
avrdude: stk500_getsync(): not in sync: resp=0xf9
avrdude: Send: Q [51]   [20]
avrdude: Recv:
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x51

avrdude done.  Thank you.


Coding Badly

#10
Nov 21, 2010, 09:45 am Last Edit: Nov 21, 2010, 09:47 am by bcook Reason: 1
@The Ideanator:
I can't see anything suspicious.  I'm stumped.

@Arduino Malaysia:
Someone else will have to help.  The only thing BlueTooth here is an HP printer (and it's headed to the landfill if it doesn't start behaving).

Georg_Fischer

I have the similar problem. Using UBUNTU 8.10, Arduino-UNO,
Ide Arduino-0021.

Problem is Serial.print. All programs, that make output with Serial.print, make
problems with Arduino-UNO. I cant upload the programs. Same programs dont
make problems with Arduino-Duemilanove.

I think Serial.print blocks the communication between PC and Arduino, so
that Upload on Arduino-Uno makes problems.

I solved it for me in this way:
o i start the Arduino-Uno
o i look at /dev for ttyAC*.
o i start kermit -l /dev/ttyAC... -b 9600
  set carrier-watch off
 connect
o if this fails, i have to reset the arduino-uno, start kermit again ...
 up to the moment, where kermit receives correct output.

then i finish kermit, start the arduino-ide, and OFTEN i am then able to
upload scripts.

Sometimes i only have to push the RESET-Button on the Arduino-Uno and try
again upload. OFTEN then it works. If not, i have to start from beginning with
kermit ... Arduino power off / on .. exit kermit, start Arduino-Ide ....

Kermit ist a terminal-program.

I think the problem is the change of the chip on the Arduino from the
good USB-Chip to another chip, this chip makes problems.

Arduino-Uno: i bought two of this at bausteln.de, same problem with both
arduinos.

mellis

Guys, not all upload problems are the same, it's confusing to pile them all onto the same thread.  Ideanator, did you select Arduino Uno from the Tools > Board menu?  It looks like the upload settings being used are for the Duemilanove.

pluggy

Quote
I then changed boards to the Duemilanove and it uploads and runs just fine.


You mean it works OK set as a Duemilanove ?
http://pluggy.is-a-geek.com/index.html

The Ideanator

Quote
You mean it works OK set as a Duemilanove ?

Yep.
Quote
Guys, not all upload problems are the same, it's confusing to pile them all onto the same thread.  Ideanator, did you select Arduino Uno from the Tools > Board menu?  It looks like the upload settings being used are for the Duemilanove.

Facepalm. That fixed it, thank you dude!

Go Up