Hi,
I went trough several manuals how to burn a bootloader on 3D printer (in my case Ender 3). I should point out, that I'm total noob in electronics/programming but I will try to describe the problem and my partial solution in detail as clear as possible. Based on the problem description below, can someone please write me a concise manual, what to do to burn bootloader without error?
-
So first of all, I've bought this cheap UNO clone (see attached image), connected it to PC and installed CH341SER driver so it's now visible as "USB-SERIAL CH340" as can be seen in 02image.
-
I followed instruction an try to upload bootloader onto this UNO clone (used ISP file "File/Examples/11.ArduinoISP"; selected UNO board "Tools/Board/Arduino Genuino UNO; selected port COM9; and selected programmer option "AVRISP mkII"). In other words, I worked as described in numerous manuals. Unfortunately, following error popped:
Arduino: 1.8.7 (Windows 7), Board: "Arduino/Genuino Uno"
Sketch uses 4402 bytes (13%) of program storage space. Maximum is 32256 bytes.
Global variables use 482 bytes (23%) of dynamic memory, leaving 1566 bytes for local variables. Maximum is 2048 bytes.
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0xf3
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0xf3
avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0xe0
avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0xe0
avrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0xe0
avrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0x00
avrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0xe0
avrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0xe0
avrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0xe0
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x00
Problem uploading to board. See http://www.arduino.cc/en/Guide/Troubleshooting#upload for suggestions.
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
Any suggestions why this happened and how to solve this?
Anyway, I try to solve this problem on my own (99.99% wrong approach, but.. somehow it worked, continue reading)
-
So i tried to upload bootloader using different board (not "Arduino/Genuino UNO"). The package of boards I chose and install was "Atmel AVR Xplained-minis by Atmel University France version 0.6.0" containing board "Atmega328p-xmini". I used this exact board to upload bootloader on this UNO clone and the process was successful. After upload of bootloader, I tried to upload simple "Blink" example and the LED of UNO clone started to blink. This was impossible before bootloader upload. So I guess the upload was successful even when "Atmega328p-xmini" board was used for UNO clone (strange?).
-
I continued with the bootloader burn process as described in manuals. I can mention two of these from Teaching Tech (Ender 3: How to install a bootloader and update firmware - YouTube) and TH3D Studio (Bootloader Flashing Guide - CR-10/Ender 2/Ender 3/Ender 5/X3S/X5S/Wanhao i3 - 1284p Boards - YouTube). I followed the wiring in these manuals, briefly:
Ender 3 (Melzi) -----> UNO clone
MISO ----------------> MISO
5V -------------------> 5V
SCK -----------------> SCK
MOSI ---------------> MOSI
GND ----------------> GND
RESET --------------> Digital Pin 10
When I completed this wiring (via jumper wires), I checked the tightness of joints connection and connected the UNO clone to PC. Melzi board LED turned on as well as 3D printer LCD (connection seemed to be ok). I proceed to step of bootloader burning. In "Tools/Board" I've chose "Sanguino" (installed from "Sanguino by Kristian Sloth Lauszus version 1.0.2" using boards manager), selected processor "ATmega1284 or ATmega1284p (16MHz)" and appropriate com port (COM9). Next, I selected programmer option "Arduino as ISP" and clicked on "Burn Bootloader". Here is the error I got:
Arduino: 1.8.7 (Windows 7), Board: "Sanguino, ATmega1284 or ATmega1284P (16 MHz)"
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x15
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x15
avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x14
avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x01
avrdude: stk500_initialize(): (a) protocol error, expect=0x14, resp=0x10
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.
avrdude: stk500_disable(): unknown response=0x12
Error while burning bootloader.
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
I have tried this exact setup and procedure using different PC and the error was identical
So what I had done so far?
I manage to upload bootloader onto UNO clone using different board selection.
However I was not able to burn bootloader from this UNO clone to ATmega1284p (16MHz) on the Melzi board of Ender printer.
Any suggestions what should I do to complete the process of bootloader burning? It's driving me nuts already :((
Possible options ("my" theory):
A) Upload bootloader using "Arduino/Genuino UNO" board, so it can be successfully burned using programmer option "Arduino as ISP".
B) Somehow add option "ATmega328p-xmini" to programmer, so the bootloader can be uploaded without error.
My apologies for the non-technical language and inaccurate description, my knowledge is limited. My English also sucks Can someone please help me?