Burn Bootloader and Firmware on Ender3
by Amit_Jain in Workshop > 3D Printing
9432 Views, 4 Favorites, 0 Comments
Burn Bootloader and Firmware on Ender3
Many of us, have an Ender 3 printer. It works amazing for an entry-level 3d printer. I got mine 2 years back with an 8-bit board and never felt any need to upgrade the firmware.
Until, I wanted to experiment with Octoprint but to my surprise, it does not support the stock firmware that comes with the 3D Printer. It is a must to upgrade the firmware to marlin...
I started with my research and noticed few hurdles that I needed to solve
- Cannot upgrade firmware over USB cable
- Need USB ISP or Arduino to update firmware
- Need a boot-loader, where to get that one from?
- Connections to board sound scary
- What if I brick my printer?
- All tutorials available were not up to date
So in this tutorial, I will share how to burn a bootloader using an Arduino nano and then upgrade the firmware using a USB cable directly connected to the printer. It sounds scary at first, but it is not.
I was pleasantly surprised by how simple and quick this was...
Supplies
Software
- Arduino IDE
- Marlin 1.x source code
- Drivers for Arduino Nano
- Board manager for Sanguino
- u8Lib
Hardware
- Arduino Nano
- Jumper wire
- USB cable
- PC with Windows
Gather Info
- Before we start anything we need to get the details of the board
- To get the same open the 3d printer and take some close-up photos
- Mine was 1.1.4V with Atmega1284p 8-bit board
- Based on personal experience, I could not compile Marlin 2.x for my 8bit board. So I recommend using Marlin 1.x
- There is no separate software for the bootloader that one can find on the internet. It is included as part of Arduino ide ( with Sanguino board lib)
Prepare Marlin Code
- Download the latest source code from https://github.com/MarlinFirmware/Configurations/tree/release-1.1.9
- Do not use Marlin 2.x for an 8-bit board
- Extract the Marlin firmware to C:\Temp\Marlin-1.1.x
- Download latest config files from https://github.com/MarlinFirmware/Configurations/tree/release-1.1.9/config/examples/Creality/Ender-3
- And paste them in folder C:\Temp\Marlin-1.1.x\Marlin and paste/overwrite config files
- Make sure that the config files are specific to ender3 only
- File names for reference
- Configuration_adv.h,
- Configuration.h,
- _Statusscreen.h and
- _Bootscreen.h
Prepare Arduino IDE
- Go to https://www.arduino.cc/en/software and download the latest ide based on your OS
- Connect the Arduino nano to the PC via a USB cable, in a few minutes the drivers for USB chip is automatically loaded
- Go to https://www.arduinolibraries.info/libraries/u8glib and download the latest lib zip
- In Arduino IDE Menu, "Sketch" > "Include Library" > "add .Zip Library", select the downloaded zip file and press open
- The u8glib library will be installed and added to ide
- In Arduino IDE Menu, "Files" > "Preferences", add additional board manager https://raw.githubusercontent.com/Lauszus/Sanguino/master/package_lauszus_sanguino_index.json
- Press OK/save and close the preferences window
- Under "Tools" > "Board" > "Board Manager", install sanguino board
- You may have to restart Arduino ide for all lib and boards to load
- Connect the 3d printer and PC using a USB cable, so that the usb drivers are also installed (optional)
Burn Bootloader Using Nano
- Disclaimer: Once you burn the bootloader, it will overwrite your current firmware.
- Connect Arduino nano to PC via a USB cable and burn ArduinoISP code on it
- Make connections as shown in the picture between ISP pinouts of the ender3 and nano
- Change the IDE settings
- Board: Sanguino
- Processor: ATmega1284p
- Port: Based on the com port detected
- Programer: ArduinoISP
- Under "Tools"> "Burn Bootloader"
- Within a few seconds the bootloader is written on the ender3 board
- Our bigger hurdle is now solved.
- Disconnect Arduino nano
Upgrade Marlin Firmware
- Connect ender 3 via a USB cable to your pc, in few minutes the latest driver for the USB / board i installed and ready for use
- Go to folder C:\Temp\Marlin-1.1.x\Marlin
- Open Marlin.ino, this, in turn, opens Arduino IDE.
- Verify files Configuration_adv.h and Configuration.h, are for ender3
- If you want recovery post power loss, enable it as shown
- Compile the firmware to make sure there are not errors
- If successful, write the new firmware to ender 3
- Disconnect the USB cable. restart the printer
- Initialize EPROM
- Voila we have Marlin firmware on our ender 3, ready to use
Learnings
- The steps are easier than I originally thought
- The main hurdle is the bootloader, once that is solved, one can upgrade firmware anytime
- Marlin 2.x should not be used on old 8bit boards
- Marlin 1.1.9 is bit laggy and downgraded it to Marlin 1.1.4 from Creality's website https://www.creality3dofficial.com/pages/firmware-download
- I discovered that "Recover on power loss" in Marlin is buggy, even for completed prints, it gave me the option to resume print. So I disabled it and connected my printer on a UPS :)
Please share suggestions/feedback