Setting up Marlin is fiddly at the best of times. Having to revise your configurations every update certainly doesn’t help. This is a no nonsense, simple guide (and note to self) to configuring Marlin 2.0 for the Ender 3/Pro with BLTouch ABL sensor. I’m using an SKR v1.4 Turbo. The same applies for the original Creality Melzi 1.X.X boards, just be sure to save as much space as possible!
The Template
Firstly, you’ll need the Marlin firmware with the appropriate template settings.
- Start by downloading the latest stable release of Marlin from here.
- Extract the zip.
- Copy the 4 files from
config/examples/Creality/Ender-3
to theMarlin/
folder, overwriting the 2 already there.
Configuration.h
Open the new Marlin/Configuration.h
file using a text editor suitable for code, like Sublime Text or Notepad++. We’ll customise our configuration now:
- Change
STRING_CONFIG_H_AUTHOR
to clearly differentiate the configuration from the default - Disable
SHOW_BOOTSCREEN
andSHOW_CUSTOM_BOOTSCREEN
to save space by commenting out the lines (prefix them with#
) - Ensure you have the correct BAUDRATE. The original Ender 3 was configured to 115200 by Creality, but the newer Ender 3 Pro (and newer Creality motherboards) default to 250000. You may be fine with 250000 on an older Ender 3.
- Change
CUSTOM_MACHINE_NAME
to represent your printer, e.g."Ender 3 Pro"
- If you’re using a BLTouch ABL sensor:
- Uncomment
#define BLTOUCH
#define SERVO0_PIN 27
is not required to set up your BLTouch in Marlin 2.x, as it’s defined in the pins folder by default- You’ll need to customise the offset between Probe and Extruder. In Marlin 1.x, this was done with
X
,Y
andZ_PROBE_OFFSET_FROM_EXTRUDER
. In Marlin 2.x, they’re now combined inNOZZLE_TO_PROBE_OFFSET
. Instructions are in the comments. Using the Creality BLTouch Kit bracket, mine is{ -43, -9, 0 }
. It’s safer to leave Z as 0 here are calibrate this yourself later. - To keep the probe away from the edge of the bed, increase
MIN_PROBE_EDGE
to 20 - You can increase
XY_PROBE_SPEED
to 10000 to speed up probing slightly - Uncomment
#define AUTO_BED_LEVELING_BILINEAR
to enable bilinear ABL - By default, bilinear ABL uses a 3×3 grid. You can change this by editing
GRID_MAX_POINTS_X
underEITHER(AUTO_BED_LEVELING_LINEAR, AUTO_BED_LEVELING_BILINEAR)
. Mine is set to 5, for a 5×5 grid - Uncomment
#define LCD_BED_LEVELING
to add bed leveling menu items
- Uncomment
- If your bed is non-standard, you’ll need to adjust the size and/or travel limits to make sure Marlin knows this. I use bulldog clips to secure a glass bed. To ensure the nozzle stays clear of the clips, I’ve changed the following:
Y_BED_SIZE
from 235 to 199,X_MIN_POS
from 0 to -2,Y_MIN_POS
from 0 to -24. - Uncomment
Z_SAFE_HOMING
. This prevents your Z homing from occuring without prior X and Y homing. Without this, you may accidentally miss the bed when homing Z. - To increase the homing speed, increase
HOMING_FEEDRATE_XY
from(20*60)
to(40*60)
andHOMING_FEEDRATE_Z
from(4*60)
to(8*60)
. - If you want to use PID to efficiently heat your bed, uncomment
#define PIDTEMPBED
. You’ll need to calibrate this later. - If you’re using a “silent” Creality board v1.1.4 or v1.1.5, you’re using TMC2208 drivers in standalone mode. Uncomment
X
,Y
,Z
andE0_DRIVER_TYPE
and set them toTMC2208_STANDALONE
. - To save space, uncomment
#define SLIM_LCD_MENUS
. This will remove many menu items that you won’t need if controlling using a PC or OctoPrint. - To save space:
- Comment out
#define SPEAKER
. This will stop fully disable the speaker. - If you won’t be printing from SD card, comment out
#define SDSUPPORT
and#define POWER_LOSS_RECOVERY
. If you are still using an SD card, it’s time to look into OctoPi. - If you can do without scrolling long file names on the display, comment out
#define SCROLL_LONG_FILENAMES
.
- Comment out
- Save the file and close the file.
Configuration_adv.h
Open the new Marlin/Configuration_adv.h
file in your chosen text editor.
- If you’re using a BLTouch:
- Uncomment
#define BLTOUCH_DELAY
and change from 500 to 200. This reduces the pause after each individual probe. - Babystepping allows the nozzle to move a tiny amount without changing the recorded coordinates for the hotend. This is usually used for calibrating your Z Offset for a perfect first layer. You can increase
BABYSTEP_MULTIPLICATOR_Z
and_XY
to 10 for faster motion. - Uncomment
BABYSTEP_ZPROBE_OFFSET
and#define BABYSTEP_ZPROBE_GFX_OVERLAY
- Uncomment
- If you want to use Linear Advance to increase your print quality at higher speeds, uncomment
#define LIN_ADVANCE
and setLIN_ADVANCE_K
from 0.22 to 0, which will enable the feature but turn it off. Your GCODE will need to specify the K value, which you’ll calibrate later. You need different K values for different filament types. Note that LinearsAdvance is not compatible with the TMC2208 stepper driver in Standalone mode (using StealthChop), so will not worth with Creality “silent” boards v1.1.4 and v1.1.5. - To save space, comment out
#define ARC_SUPPORT
. This feature is used by other types of CNC machines, but usually not 3D printers. - If you want to display progress and time remaining from another system with the
M73
command, such as OctoPrint, uncommentLCD_SET_PROGRESS_MANUALLY
. If your system will also send theM73 R
parameter to update the time remaining, uncommentUSE_M73_REMAINING_TIME
. - Marlin watches the rate of temperature increase for hotend and bed. If it’s too slow, it will trigger an error and halt your print. If you have the windows open for ventilation and it’s cold out, this can be a problem. Increase
WATCH_BED_TEMP_PERIOD
a little if you have this issue. - Save your changes and close the file.
To The Printer!
- Take a copy of your
M503
output to save your current printer settings. You’ll need to put some of these back later. - Open
Marlin/Marlin.ino
with the Arduino IDE and write the new firmware to your printer. - Run
M502
to set all settings to those specified in your firmware files, thenM500
to store these settings in the EEPROM. - Depending on your configuration, you’ll now want to calibrate your Z-Probe Offset, PID for Hotend and Heated Bed and Linear Advance, or set them from your previous values.
19 responses to “Configuring Marlin 2.0 for an Ender 3/Pro and BLTouch”
Daniel! .. THANK YOU .. this worked perfectly .. I did have to disable SD Card printing to get it to fit though …. (but I left all the menus in tact)
I followed this to the letter but I seem to blow the memory allowance. How did you get this to work?
Double check you’ve followed every step to disable the functionality you won’t need. Admittedly, I also disabled SD card, so easily had enough space. You may need to disable some other functionality, maybe M73, Linear Advance or PID heating. Otherwise, have a google for saving space on Marlin 2, there may be something else you can do without that I’ve missed.
SAME problem I cant really disable carrd reader so I dont have enough space
You’ll need to think carefully about what features you can live without and disable them to bring down the space your firmware requires.
So I followed this, and I’d definitely like to use the printer with an sd card rather than being hooked up to my computer all the time, and it says that the region “text” overflowed by 8832 bytes.
You’ll need to think carefully about what features you can live without and disable them to bring down the space your firmware requires.
Many thanks for this guide, I was a few days in with no success but finally managed to get things sorted.
Works great! Was able to save space and get rid of the nasty overflow error.
[…] A simple guide (and note to self) to configuring Marlin 2.0 for the Ender 3/Pro with BLTouch ABL sen… […]
my extruder hits the right side but goes along the front fine and the right side but it just doesnt go left from there
Hi, I have been struggling with Antclabs v3.1 BLTouch on BTT SKR1.4 Turbo board with Marlin for 4 weeks now. Have viewed numerous you tube and web based instrcutions without any luck. Your article got the closest but BLTouch failed at 1st probe every time for bed levelling.
Any help with config for this to work woul dbe a life (and marriage) saver.
Looks like Configuration.h should be PROBING_MARGIN, not MIN_PROBE_EDGE. Couldn’t find the MIN_PROBE_EDGE and set MIN_PROBE_MARGIN to 20 and it works as expected.
Thanks – the Marlin team aren’t one for backwards compatibility, so expect variable names to change without warning when you update to newer versions.
There are no examples in the config folder 🙁
Forget it, I’ve found it on github (I’m not really familiar with github 🙁 )
This described lines are not available in Configuration.h for Ender 3 with board 4.2.7:
#define SERVO0_PIN 27
#define MIN_PROBE_EDGE
#define XY_PROBE_SPEED
#define LCD_BED_LEVELING
Ok, I understood like half of this. Where do I go to learn about this subject from the beginning? I know nothing about marlin comment uncomment ect.
to comment something, add // to the beginning
to uncomment, remove the // from the beginning
Marlin uses the same programing as arduino. there are tons of tutorials out there for arduino.