Go Down

Topic: Can't upload sketch! (Read 11312 times) previous topic - next topic

ndeboar

Yeah, i tried resetting my arduino manually pretty soon after this prob came up, with no avail. I think the Arduino head honchos need to admit this is a bug and look into it.

youngrobot

Hi All,

my son & I just got an Arduino and everything worked fine till now when I tried to send something out of the serial port. Now I can no longer  upload - even though my old program on the Arduino still works. Basically its identical to what the others are reporting here! The message on the console is:

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

I've tried playing with pressing reset and immediately hitting upload to get it in those 2 secs - but nothing works - HELP !

ndeboar

I feel your frustration ;)

flyboy

I got my arduino duemilanove today and had the same error message today.  I had to change to com 5 in order to get it to work.  Apparently, it does not automatically detect and configure all of the correct settings.  Once I did this, it has worked fine.

Now, it's time to start learning and having fun.  Best of luck to you.

youngrobot

Good One Flyboy!
I changed USB ports and it works!!! I was waiting for some components I ordered to build my own parallel programmer to reload the bootloader - Sooo glad I didn't do that!

However, it now works but when I open the Serial Monitor the Arduino starts sending gibberish data even though I have no Serial.X code - need to look into this...

FYI, I am using Vista on the PC

youngrobot

All OK,

it all works fine now - we actually were using Pin1 without realizing that was also the Tx pin hence all the gibberish we were seeing.

Thanks

The Bark Petition

I had this problem too.  Checked Ports in Device Manager, and saw that two out of three that software allowed me to pick were in use.  Picked the one labeled USB Serial Port (which happened to be COM7), and thereafter everything worked properly.

MiG

Hi All

I recently got my hands on two arduino boards, one is the 'official' Arduino duemilanove (Decimilia), on is the Seeeduino (decimila with SMD components).

Having started using the Seeeduino, I had the same problem as others on this thread, namely:

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

However, when flipping over to the Duemilanove, the board worked first time.

The Seeeduino was billed as beign totally compatible to the original Decimilia... so just putting this out there in case there is a bug in that particular version of the board.....

lwhi

I had a similar problem - and thought it was caused by sending out too much info on the serial port.

I ended up editing ~/.arduino/preferences.txt:

Code: [Select]
serial.debug_rate=9600

And this did the  trick.

red_red

Same problem. But somewhere accidentaly it just uploaded once...

Then I found that the Arduino exe was very slow with prompting ''binary sketch size ...". When you reset the board at this moment (seconds later in my case) it works!

:-?

wademealing

This is a possible solution to a problem.

I came across a similar problem.  My environment is a serial arduino with a USB -> RS232 converter.

The sketch that I uploaded wrote heavily to the serial port.  I found two possible work arounds.

On Linux/OSX there was data buffered by the serial port driver, this somehow stopped the sketch from being uploaded.  If you flush the serial buffer from either the OS or the USB converter.

Run the commands while the arduino is unplugged from the serial / usb connection.

cat /dev/ttyUSB0 >> /dev/null (If your connection is usb)
cat /dev/ttyS0 >> /dev/null  (if your connection is

Your OSX serial device will also exist in /dev/ but I have no idea what the standard naming scheme is for it.

The cat should terminate, if not just ctrl + c to end the command when the data has finished spewing to the terminal or /dev/null.

When you plug the arduino in, upload it before the arduino does its initial program run. (Precompile it if its a long compile) and it should upload and run correctly.


RoyK

Are the settings in preferences.txt documented somewhere or do we need to guess at what they mean/which ones actually do something?

Quote
I had a similar problem - and thought it was caused by sending out too much info on the serial port.

I ended up editing ~/.arduino/preferences.txt:

Code:

serial.debug_rate=9600




And this did the  trick.

FelixFelicis

AM getting the same Error again and again. I tried reseting and uploading within 2 seconds. I even tried unpluging my USB and Pluging it and then giving the upload.Still it didnt work..Also, My serial.debug_rate=9600 is also set in preference.txt..Still no use..What should I do?? :(

FelixFelicis

Or..Does this have to do anything with the software??

My controller is Arduino Duemilanove Atmega328.

ANd the software am using is sketch_feb09a | Arduino 0018. ::)

bioncleboy

:) :) :) :) :) update your drivers to the newest version worked for me

using delimonov

Go Up