
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 seven most common causes and things to check.
1) Is your FTDI cable plugged in the right way? The black wire or side marked "black" should be on ArduPilot's BLK pin.
2) If you have the older ATmega168 board did you select "Arduino Diecimila" as the board in the Arduino Tools menu? If you have the newer ATmega328 board, did you select "Arduino Duemilanova w/ATmega328"?
3) Are you using the
DIYDrones FTDI cable? We've had trouble with other ones...
4) Is the cable plugged into a USB hub? That can sometimes cause trouble. Try plugging it straight into your PC.
5) 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.)
6) The board is set up to auto-reset when you load a sketch with the FTDI cable, so you don't have to manually press the reset button to get the bootloader. If that's not working for you, check the RTS setting in your PC's port settings ("Set RTS on close" should be checked) as described
here. [Note: if you're using Linux, there's no direct equivalent to this. Instead, you may have to unplug the USB and plug it back in every time you want to upload code]
7) Are you using the
latest FTDI drivers? Install them if not. If you're still having trouble, try reinstalling them.
8) If you're using the Version 1 (red) shield, you should unplug you GPS module before loading code. The Version 2 (blue) shield does not require this.
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. Try reinstalling on another PC and see if that does the trick.
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).
You need to be a member of DIY Drones to add comments!
Join DIY Drones