If you're trying to upload code with Arduino and you get an error message that looks something like this:
"Problem uploading code.....

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

(or any other error report when uploading code, aside from the obvious ones like compile errors or choosing the wrong serial port)

Here are the most common causes and things to check.

  1. Did you check the "Set RTS on close" box in the Windows Com port, as instructed in the manual?
  2. Are you selecting the right board? For ArduPilotMega, if your board uses an ATMega1280 processor (the big chip on the APM board will say "ATmega1280") select "Arduino Mega (Atmega1280)". If you've got an ATMega2560 chip, select "Arduino Mega 2560". For the original ArduPilot and ArduIMU, choose "Arduino Duemilanove".
  3. Is the cable plugged into a USB hub? That can sometimes cause trouble. Try plugging it straight into your PC.
  4. Are you using the latest FTDI drivers? Install them if not. If you're still having trouble, try reinstalling them.
  5. Check your solder joints! It's a good idea to reheat and reflow all of the ones you did, just to be sure.
  6. Other errors that have caused this problem in the past include a power source (such as your ESC) that is putting out a voltage outside the acceptable range of 4-7v, faulty USB or FTDI cables, and corrupted FTDI drivers. When in doubt, try a different power source, a different cable or a different PC.

Additional things to check if you're using the original ArduPilot board (not ArduPilotMega):

  1. [For original ArduPilot board only] Is your FTDI cable plugged in the right way? The black wire or side marked "black" should be on ArduPilot's BLK pin.
  2. [For original ArduPilot board only] Are you using the DIYDrones or Adafruit FTDI cable? We've had trouble with other ones...
  3. [For original ArduPilot board only] Is the ArduPilot board powered on, ideally through your RC system or ESC? (You can NOT power it from the FTDI cable; this is a safety measure to avoid power conflicts.)

If those all look fine and you're still getting the error message (especially if you can successfully load code to other Arduino boards), you may have a corrupted FTDI driver or a bad FTDI cable. Try reinstalling on another PC and see if that does the trick. If it doesn't, you may need a replacement FTDI cable.

In some rare cases, a power glitch may have resulted in a corrupted ArduPilot bootloader on the ATMega chip. This tutorial will show you how to reload the bootloader. (Warning--for experts only and requires an AVR programmer. This should not be necessary for most people.)

Other problems can include "Serial port not found" (just check that you've selected the right serial port in the Tools menu. It's the one assigned when you first plugged in the FTDI cable--probably 5 or higher), and the Arduino IDE freezing (try unplugging the FTDI cable. If that doesn't work, just reboot your computer).

Views: 30885


Admin
Comment by Thomas J Coyle III on August 5, 2009 at 12:22pm
Danilo,

Here is what you need to do: You will find two folders inside Ardupilot ver 2.2.3: one, the ArduPilot code, which will be called ArduPilot_EasyStar2[subversion] and the other just ArduPilot, which contains a .h file and readme. Move the ArduPilot folder to the \\arduino-0016\hardware\libraries folder on your PC. Since you did not load the .h file as instructed the Arduino IDE cannot compile the sketch.

Regards,
TCIII

3D Robotics
Comment by Chris Anderson on August 5, 2009 at 12:25pm
Thanks, Thomas. Just a reminder that these instructions are in the manual. RTFM!
Comment by Drew on August 29, 2009 at 4:41pm
I'm trying to get my gps to lock (I have the standard em406) and the lock light will not flash. I have it setup for north east mode, servo is plugged into output 1 (rudder?), power LED is illuminated, and Stat LED is flashing, battery is plugged into control input. I'm running the latest ardupilot (2.3). Help would be appreciated. Thanks!


3D Robotics
Comment by Chris Anderson on August 29, 2009 at 5:04pm
Drew,

--Have you switched the power solder jumper (since you're using a battery, not an ESC)?
--Have you used the field setup jumper/bind plug to program the GPS into binary mode, as described in the manual?

Admin
Comment by Thomas J Coyle III on August 29, 2009 at 5:14pm
Chris,

Drew appears to be using a 4 cell rechargeable battery so he is operating around ~5.2 vdc when fully charged which, I believe, is within spec. So he does not need to switch the power jumper. I power my Ardupilot with a 4 cell NMHi battery all the time when I am not using an ESC.

Regards,
TCIII
Comment by Drew on August 29, 2009 at 5:43pm
The manual shows how use a bind plug with the shield. I tried binding d6 and d7 on the ardupilot (nothing happened), are those the correct pins for binding? So I take it this will not work correctly until the GPS is in binary mode?
Comment by Drew on August 29, 2009 at 6:03pm
Something is starting to work, just tried jumping/binding between d6 and d7 and the blue light started flashing. So I rushed outside to make sure the gps could see the sky, however within two minutes or so the blue light completely stopped.

3D Robotics
Comment by Chris Anderson on August 29, 2009 at 6:17pm
Tom,

That is not regulated power, so the actual voltage under a current is unpredictable.

Drew,

You need to ground D6. The yellow status light should flash for a second (that's programming the GPS) and then the blue LED will flash until you get GPS lock. If you're not using an ESC, you should switch the power jumper. Behavior will be unpredictable if you don't get the power right.
Comment by Mogly (Umesh Tharanath) on October 9, 2009 at 6:10pm
Hello All,
Have a problem in uploading Code to ArduPilot board.

Binary sketch size: 15510 bytes (of a 30720 byte maximum)

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

I have gone through the forums. here. (http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1187909552/30)
But still i could not figure it out to over come this.


This Setting i used with speed 57600.
atmega328.name=Arduino Duemilanove or Nano w/ ATmega328

##############################################################

atmega328.name=Arduino Duemilanove or Nano w/ ATmega328

atmega328.upload.protocol=stk500
atmega328.upload.maximum_size=30720
atmega328.upload.speed=57600

atmega328.bootloader.low_fuses=0xFF
atmega328.bootloader.high_fuses=0xDA
atmega328.bootloader.extended_fuses=0x05
atmega328.bootloader.path=atmega
atmega328.bootloader.file=ATmegaBOOT_168_atmega328.hex
atmega328.bootloader.unlock_bits=0x3F
atmega328.bootloader.lock_bits=0x0F

atmega328.build.mcu=atmega328p
atmega328.build.f_cpu=16000000L
atmega328.build.core=arduino

##############################################################
Can anyone had the same problem and got solved. ?

Thanks In Advance.

not in sync-protocol error( 0x00-0x14-0x51).JPG

3D Robotics
Comment by Chris Anderson on October 9, 2009 at 6:31pm
Have you checked ALL seven items above? If so, you probably have a FTDI driver issue. Please try on another PC. If that doesn't work, you've got a hardware problem (bad cable, or soldering issue)

Comment

You need to be a member of DIY Drones to add comments!

Join DIY Drones

Groups

Season Two of the Trust Time Trial (T3) Contest 
A list of all T3 contests is here. The current round, the Vertical Horizontal one, is here

© 2019   Created by Chris Anderson.   Powered by

Badges  |  Report an Issue  |  Terms of Service