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: 26605

Tags: ardupilot

Comment by Roy Stevens on February 27, 2009 at 4:50pm
Hey guys,
I was fiddling with my board trying to upload sketches for a while and having no success. After a while (not sure exactly what I did to possibly cause this) when I plugged in the FTDI cable I got the message "USB Device Not Recognized" and it continued on to explain that the device has 'malfunctioned'. Sounds to me like I fried something on the board somehow but if anyone has a possible explanation I'd be grateful to hear your input.
Comment by Noth666 on March 10, 2009 at 11:52am
@jeff and roy: naw, you just need to manually reinstall the driver for the ftdi from the control panel. Or remove VID's (google how if you do not know, instructions on MS website) if the driver does not help. VID removal will fix it for sure.

I have another issue, I get the same error as above but different hexcode and also my MODE light never comes on. I am still trying to get it to work the first time and its still in the demo mode. LOCK and STAT blink the correct way.

Anyone have an idea of what is the issue? Board looks fine physically, looked it over with a magnifying glass to make sure there are no shorts.

3D Robotics
Comment by Chris Anderson on March 10, 2009 at 11:59am
North66: Could you please describe the following:
--What FTDI cable are you using?
--How are you powering the board?
--Have you run through ALL of the checklist items above?
Comment by Noth666 on March 10, 2009 at 12:19pm
Chis, smack me if you want :P. I did not do the RTS thing until now, and it worked after I did.. Damn, I should know to check all the things in the list, I worked ages in techsupport...
Comment by Neal Kelley on April 29, 2009 at 6:07pm
Hello.. i have purchase my board from fun spark.. I can not seem to get the code loaded.. i am getting the "avrdude: stk500_getsync(): not in sync: resp=0x78
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x78avrdude: stk500_getsync(): not in sync: resp=0x78
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x78" error...

i have tried all of the other possible solution and no luck...
when i connect the sparkfun ftdi breakout.. the amber led blinks and i have a solid red light. When I start loading the software.. the blue led and amber led flash.. any suggestions?
Comment by Neal Kelley on April 29, 2009 at 6:08pm
i have my baud rate for the com port to 9600 and i also have checked that rts close deal...

3D Robotics
Comment by Chris Anderson on April 29, 2009 at 9:00pm
@Neal: The baud rate doesn't matter. If you've got one of the new Atmega328 boards you need to select the ATmega328 board from w/in the Arduinino IDE
Comment by Michael on May 2, 2009 at 6:05am
Chris,

I keep getting the following error when i try to load the 2.1 code to the new 328 ArduPilot board "In function 'void setup()':
error: 'init_ardupilot' was not declared in this scope In function 'void loop()':"

I read all the posts and did everything they say, but the same error keeps appearing, not sure what i have done wrong?
Comment by space_nut on July 28, 2009 at 10:55pm
I'm having trouble getting the debugging code to send stuff back to the IDE..

3D Robotics
Comment by Chris Anderson on July 28, 2009 at 11:04pm
Check your baud rate in the IDE. It must match the GPS baud rate. 57k is the default for the EM406

Comment

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

Join DIY Drones

© 2014   Created by Chris Anderson.

Badges  |  Report an Issue  |  Terms of Service