Welcome! Log In Create A New Profile


Marlin upload error : Communication timeout

Posted by Antoine13710 
Marlin upload error : Communication timeout
October 28, 2016 07:33AM
Hi everyone,

So here's my problem, for the past weeks I've been trying to upload the Marlin firmware on my RAMPS 1.4 and each time I try to upload I receive this error message :

avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_ReceiveMessage(): timeout
Une erreur est survenue lors du transfert du croquis
avrdude: stk500v2_getsync(): timeout communicating with programmer

Does anyone have any idea where does that might come from ?

My configuration is :
Operating system : Windows 10
Software : Arduino 1.6.12
Firmware : Marlin (the code compile without any poblem)
Board : RAMPS 1.4
Processor : Mega 2560

I already checked that the correct parameters are entered in the Arduino software :
Board type : Arduino/Genuino Mega or Mega2560
Processor : ATmega256 (Mega2560)
Port : COM5
Programmer : AVRISP.mkll

I try to reinstall the Arduino soft, reinstal the drivers, change the USB cable, change the USB port, I also tried to upload the firmware with only the processor board (without the powersheild).
Do you think it could be a hardware related problem?

I'm running out of ideas so any new options are welcome!
Re: Marlin upload error : Communication timeout
October 28, 2016 08:31AM
I think the Arduino has a corrupted or missing bootloader, you need a bit of extra kit called an FDTI cable to reinstall the bootloader and get it reprogramming it as usual.


There are other sources for FDTI cables. smiling smiley

3.3V devices like Arduino Due need a 3.3V FDTI cable, most kit uses 5V FDTI cables. Get the correct version for your particular controller board or it won't work, and could well blow up a 3.3V controller, using a 5V FDTI cable on it.

Edited 4 time(s). Last edit at 10/28/2016 08:37AM by DragonFire.
Re: Marlin upload error : Communication timeout
October 28, 2016 08:20PM

FTDI cables are just serial to usb converters, and yes they comes in 3.3v and 5v versions to match your i/o voltages. This is not needed on a ramps, unless you trying to bypass the usb to serial chip.

You need a avrisp to program a new boot loader (also called AVR Programmer). You can use a second arduino for this and just run the ArduinoISP sketch
eg Aliexpress
Re: Marlin upload error : Communication timeout
May 02, 2017 09:19AM
Hi Antoine,

Have you resolve your probleme ?

I am a new user and I've the message when trying to upload on RAMPS1.4.

If so can you help and share your solution step by step ?

Best regards,


Re: Marlin upload error : Communication timeout
May 03, 2017 11:21AM
Port : COM5
Programmer : AVRISP.mkll

This could be your problem. you EITHER use a USB cable plugged into your MEGA2560, select the correct pom port as given in Windows device manager and click on the 'upload' button


You plug your AVRISP programmer into the MEGA 2560's ICSP 6 pin connector and then select 'upload via programmer'..

If you are trying to flash the 2560 using the programmer and do NOT have a USB cable plugged in to the 2560 then check you have the 6 pin connector plugged into the ICSP socket the right way around, and you have selected the correct programmer in the Tools/programmer....

Re: Marlin upload error : Communication timeout
May 04, 2017 12:04PM
Hi dart16, thank you for your reply.

But the problem persists.

I use USB cable to rely my PC to arduino and the COM5 is used as the connection port.

But i notice that the ON LED is GREEN and the L LED is ORANGE and does not blink (may be this is the problem because with arduino UNO this LED blinks).

The TX and RX LED are off.

Please thank you for your help.

Re: Marlin upload error : Communication timeout
May 05, 2017 10:33AM
OK, so your 2560 isn't talking to your Arduino IDE software over your USB cable but your 2560 would seem to at least be recognised by windows...have you tried several different com port speed settings?.. i.e. 115200 & 250000. Other than that I would try a different Mega2560 board, especially if an UNO works ok with your computer/IDE/USB setup.
Re: Marlin upload error : Communication timeout
May 05, 2017 03:06PM
Hi dart16 , thanks a lot for your help.

Yes i have already test the 115200 or 250000 baudrate in configuration.h

Here are attached the screenshot of my arduino when timeout the error happens.

Re: Marlin upload error : Communication timeout
May 06, 2017 06:12AM
background info

There are two ways to upload firmware to a arduino
1) via usb serial, this is done by resetting the board to launch the bootloader. This is the default. when you click the right arrow "upload"
2) via avrisp, this bypasses the usb serial and the bootloader and puts the data directly into the 2560 chip, this is also the only way to install a new bootloader.


changing the baud rate in the firmware your trying to upload has zero effect on uploading the firmware.
The baud rate of the bootloader is defined in the boards.txt file and is a standard

Setting a programmer will be ignored when you do a normal upload, you have to use the special Sketch|Upload using programmer menu.
As far as you have stated, you don’t have a external programmer, so this is not an option.

Your error:
stk500v2_getsync(): timeout communicating with programmer


Your using the wrong serial port or
Your bootloader is damaged or missing or
the reset circuit is not working. (or RESET-EN "jumper" has been cut to deliberately stop reset working) or perhaps usb serial chip has a fault.

things to try:
Reboot your os, don't load anything else (serial is one program at a time, if something else locks it, you cant upload)
check your device manager that you have the correct serial port for the mega, then close device manager.
load up arduino ide, set the board to Mega2560, set the processor also to mega2560, load example blink sketch. don't play with anything else.
Click on the right pointing arrow (upload)

If that fails, find this RESET-EN on the board and check it is shorted. (its just some pads on the pcb, not real jumpers)

Check usb serial works. put a wire from the tx to the rx line
Open up the serial monitor, anything you send should come back to you. This send data down your usb, to the usb serial converter then back into the usb serial converter and back up the usb... (make sure to remove this wire when your done with this test)

replace boot loader. get yourself a avrisp and put a new bootloader on the atmega2560, any other 5v ardunio can be used as a avrisp
How depends on what type of avrisp you have, but I tend to use avrdude command line tool.

If you have done all this, the board is dead, throw it out.

Edited 1 time(s). Last edit at 05/06/2017 06:15AM by Dust.
Re: Marlin upload error : Communication timeout
June 01, 2017 09:10AM

Finally my board was dead !!!

After testing every thing descibed in this post, i finally buy a new new arduino mega board.

Thank you all for your help.

Sorry, only registered users may post in this forum.

Click here to login