MARLIN 2.x VERSION ALSO AVAILABLE!
Please check the new article for Marlin 2 and BLTouch up to 3.x on Ender 3 although be aware that the version I recommend for 8-bit boards is the 1.1.9.
This is the 1.1.9 version of vanilla Marlin Firmware pre-configured for Creality Ender 3 printers with the original or generic BL Touch sensors. The standard configuration file from Marlin distribution was carefully reviewed to include the latest Ender 3 specific settings from the official Creality firmware.
I made avaliable the 2.x versions of Marlin for the same board and printer but I recommend using the 1.1.9.x because it is much more stable and has more features. The 2.x versions of Marlin are too big for the board memory and several features had to be removed in order to fit the firmware.
- Official Marlin firmware with all hardware settings from Creality latest official firmware (March 2020).
- BLTouch original/generic up to 3.x. enabled by default.
- No need to remove any capacitors from the board.
- Installs from the original Arduino IDE (smaller download and frequent updates from Arduino team).
- Source code was modified to prevent releasing the BLTouch sensor during "beep" events triggered by LCD menus.
- Thermal runway protection enabled.
- Does not reset the bed level settings after the G28 (Home) command.
- Custom menu with maintenance mode, emergency mode and full auto bed leveling sequence (warmup, wait, home, level and then save settings).
- Ultra-precise bilinerar bed leveling algorithm with 25 probing points and slow probing (takes around 5 minutes to complete, 10 including the bed heating).
- Run and toggle the bed level and BLTouch tools from LCD menus.
- Slim menus enabled.
- Baby steps enabled and configured for the "Magic Numbers".
- All changes from the original Marlin config file were marked with the comment tag "Customized DBP"
- BLTouch installed on pin 27
- Z stop switch removed (it can block the Z axis movement)
- IMPORTANT! BLTouch tip height must be adjusted according to the official instruction manuals. There are different BLTouch sensors and the YouTube videos tips are most of the times wrong
- Bootloader installed
- Arduino IDE
- About 10 minutes of your life
- Quit any software that could try to access the printer from the USB port (Cura, Serial Monitor, OctoPrint, etc...).
- Configure the Arduino IDE to download the Sanguino board. Add the following URL to the board manager (File->Preferences->Additional boards manager):
- Install the following libraries/boards in the Arduino IDE:
- With all requirements in place unpack this entire Marlin distribution to a folder and open the "Marlin.ino" file from the Arduino IDE.
- Look for the configuration.h file and change the following lines to the relative coordinates of your BLTouch mount to the Nozzle. The actual settings are for this mount. If you don't have the measurements now you can configure it later with the M851 GCode (see instructions below).
#define X_PROBE_OFFSET_FROM_EXTRUDER -42 #define Y_PROBE_OFFSET_FROM_EXTRUDER -5 #define Z_PROBE_OFFSET_FROM_EXTRUDER 0
- Compile and upload the firmware. Make sure you are using the following settings.
- Board configuration: ATMega 1284P 16Mhz
- Programmer configuration: AVRISP MKII
- COM Port: Depends of your computer. Usually only one is available for selection.
- Follow the post-installation instructions below.
Installing the pre-compiled HEX
The pre-compiled firmware is also available here. You can simply burn the compiled HEX file directly to your Ender3 board without installing the Arduino IDE.
To upload the pre-compiled firmware you will need the AVRDUDE 6.3 tool. For your convenience I included the Windows version of this tool in the zip file that contains the HEX firmware but the tool is also shipped with the Arduino IDE. The upload command in Windows PowerShell should look like this:
./avrdude -p atmega1284p -c arduino -P COM3 -b 115200 -v -U flash:w:firmware.hex:i
The serial port is something between COM1 and COM8, depending on where the USB driver is pointing to, and firmware.hex is the file you are uploading. If you are using other operating system like Linux the port address will be somehting like this /dev/ttyUSB0.
After initializing the board with the new firmware don't forget to reconfigure the probe offsets running the following command from any serial terminal. Replace the default offset values in the command (-42, -5, 0) with the ones for your probe mount.
M851 X-42 Y-5 Z0 M500
Finally, follow the post-installation instructions below.
- Manually pre-level the bed! This is important because the BLTouch has limited max/min detection ranges and the print quality can be affected if the Z-Axis moves too much.
- Cool down the bed and the nozzle. Heating should have little to no effect on this specific procedure.
- Disable stepper motors using the LCD menu command.
- Place a credit card on one the bed, the thickness of the card will be used as a reference distance.
- Turn the Z axis with your hand until the nozzle hits the credit card.
- Move hot end to several positions of the bed, starting from the 4 corners. For each position, adjust the bed level knobs to keep the nozzle at the credit card thickness distance from the nozzle. This is what you would do in manual calibration but instead of using a paper you will use the card for convenience. The card thickness does not matter because the BLTouch probe will redefine the Z reference.
- Heat the bed to the printing temperature and run the bed level command from the LCD (Prepare -> Bed Leveling -> Level bed) or using the G29 gcode or using the Heat and Level command from the custom menu (recommended). Note that the Heat and Level command waits 2 minutes after the bed is hot to allow the mounted surfaces to expand/contract properly.
- Save the settings using the LCD menu or the M500 gcode (if you used the Heat and Level custom command, they will be automatically saved).
- Add the following gcode to the startup code of you slicer, right after the line of the G28 command to load the bed level configuration from the memory before every print:
- After enabling the bed level, print something large and flat to adjust the Z offset. The nozzle will always be far from the bed until you adjust the offset to a negative value (LCD -> Prepare -> Bed Leveling -> Z Offset). Don't forget to save the settings after the print to keep the offset in the memory, you can use the LCD or the M500 GCode for this.