Go Down

Topic: Arduino UNO upload problem: "stk500_getsync" error (Read 1 time) previous topic - next topic

jim_hahn

I recently got my SparkFun Inventor's Kit and cannot make it work. The software loaded OK from the Arduino web site and the hardware shows signs of working - lights blink. I am trying to load the Blink program. I get the error message "stk500_getsync". Upon looking in SparkFun and Arduino forums, I see this is a problem shared by many.

I have two Mac computers.  One I call Jim's in this note, and the other Randy's. Both fail to upload my program.

I select the Uno board. I get different error messages based on which Serial Port I select. I surmise the Arduino app is looking at the hardware in the computer it is running on to determine which options to present to the user for "Serial Port".

The information below shows the verbose output describing the problem when I run on Jim's computer and select /dev/tty.modem for the Serial port.

How can I fix this so I can get on with my real project??!!
  --jim hahn

email: hahn_02493@yahoo.com

Jim's computer:

iBook G4 Power Pc processor
Mac OS 10.4.11
There is only one device plugged into the USB port: The Arduino board.

Jim's computer, Arduino application, Tools->Serial Port

Eight options are presented for the Serial Port:

/dev/tty.modem      stk500_getsync error
/dev/cu.modem
/dev/tty.usbmodem1B11   stk500_getsync error
/dev/cu.usbmodem1B11
/dev/tty.Bluetooth-PDA-Sync
/dev/cu.Bluetooth-PDA-Sync
/dev/tty.Bluetooth-Modem
/dev/cu.Bluetooth-Modem

The usbmodem1B11 options are presented only if the Arduino is plugged in.


Error messages from Jim's computer.  Using /dev/tty.modem

Binary sketch size: 1018 bytes (of a 32256 byte maximum)
/Volumes/Arduino/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/avrdude -C/Volumes/Arduino/Arduino.app/Contents/Resources/Java/hardware/tools/avr/etc/avrdude.conf -v -v -v -v -patmega328p -cstk500v1 -P/dev/tty.modem -b115200 -D -Uflash:w:/tmp/build7554345388825479034.tmp/Blink.cpp.hex:i

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

         System wide configuration file is "/Volumes/Arduino/Arduino.app/Contents/Resources/Java/hardware/tools/avr/etc/avrdude.conf"
         User configuration file is "/Users/jimhahn/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port            : /dev/tty.modem
         Using Programmer      : stk500v1
         Overriding Baud Rate  : 115200
avrdude: Send: 0 [30]   [20]
avrdude: Send: 0 [30]   [20]
avrdude: Send: 0 [30]   [20]
avrdude: Recv: 0 [30]
avrdude: stk500_getsync(): not in sync: resp=0x30
avrdude: Send: Q [51]   [20]
avrdude: Recv: Q [51]
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x51

avrdude done.  Thank you.


Randy's computer:

Macbook Intel processor
Mac OS 10.5.8
There are many devices plugged into the USB besides the Arduino.  These include a mouse, external disk, printer, hub.


Randy's computer, Arduino application, Tools->Serial Port

Only four options are presented for the Serial Port:

/dev/tty.Bluetooth-Modem
/dev/cu.Bluetooth-Modem
/dev/tty.Bluetooth-PDA-Sync
/dev/cu.Bluetooth-PDA-Sync

Why only these four? None appear to be anywhere near correct.

nickgammon

#1
Mar 29, 2011, 08:01 am Last Edit: Mar 29, 2011, 08:03 am by Nick Gammon Reason: 1
Did you install the FTDI driver? Especially on the Mac that doesn't report the serial port at all.

http://www.ftdichip.com/FTDrivers.htm

When I upload to the Uno from my Mac in verbose mode I see this, if it helps:

Code: [Select]

Binary sketch size: 2402 bytes (of a 32256 byte maximum)
/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/avrdude
  -C/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/etc/avrdude.conf
  -v -v -v -v -patmega328p -cstk500v1 -P/dev/tty.usbmodemfd1321 -b115200 -D
  -Uflash:w:/var/folders/1A/1AUycq24Ev4PKBlyDOFIG++++TI/-Tmp-/build7878823944259678721.tmp/sketch_mar29a.cpp.hex:i

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

        System wide configuration file is "/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/etc/avrdude.conf"
        User configuration file is "/Users/nick/.avrduderc"
        User configuration file does not exist or is not a regular file, skipping

        Using Port            : /dev/tty.usbmodemfd1321
        Using Programmer      : stk500v1
        Overriding Baud Rate  : 115200
avrdude: Send: 0 [30]   [20]
avrdude: Send: 0 [30]   [20]
avrdude: Send: 0 [30]   [20]
avrdude: Recv: . [14]
avrdude: Recv: . [10]
        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         :

... blah blah ...

### | 100% 0.31s

avrdude: verifying ...
avrdude: 2402 bytes of flash verified
avrdude: Send: Q [51]   [20]
avrdude: Recv: . [14]
avrdude: Recv: . [10]

avrdude done.  Thank you.
Please post technical questions on the forum, not by personal message. Thanks!

More info: http://www.gammon.com.au/electronics

jim_hahn

OK, I got it to work.

(Thanks, Nick, you got me thinking when you mentioned the fact that one computer did not report the serial ports)

The problem in the end is simple: The 10.4 Mac OSX does not work.

The place I got hung up was not realizing the Arduino app only 'builds' its list of possible serial ports based on what's plugging in at that instant. I had initially written down the port possibilities on paper when the Arduino was NOT plugged in. Then I walked through those ports and they all failed. I should have noticed, but didn't, that after I had plugged in the Arduino, two other ports showed up.

So, if you are on a 10.5 Mac and choose the tty.usbmodemNNN port, it's working.

Go Up