Marlin 2.1.2, E3D Hemera, SKR 1.4T and UBL

descriptionStandard

This article describes a update custom build for the custom firmware “Hemera SKR” based on Marlin 2.1.2 released 18th December 2022 and prepared for use with an updated custom hardware configuration comprising of the: E3D Hemera Hot-end, the BigTreeTech SKR 1.4 Turbo board, TMC2209 stepper drivers and the BLTouch v3.1. The printer frame and PSU are from a Ender 3 Pro (v1).

Note: this release changes ABL from bilinear to UBL (unified bed levelling).

This release is intended for use with the E3D Hemera Hot-end but can be adjusted to accommodate your own custom hardware configurations.

Here are some highlights on key features enabled in this custom version of Marlin 2.1.2:

Highlighted changes indicate significant changes:

  • Compiled for: LPC1769
  • BLTouch for ABL changed to UBL (unified bed levelling).
    • Auto bed levelling is used in addition to the Z-stop switch.
    • Restores bed levelling after G28.
  • Changed to AUTO_BED_LEVELING_UBL as bed levelling default.
  • Enabled PREHEAT_BEFORE_PROBING
  • Enabled PID_AUTOTUNE_MENU
  • Enabled: G26_MESH_VALIDATION is used to produce a Mesh Validation Pattern to validate bed levelling.
  • Reverted Z_HYBRID_THRESHOLD to 3
  • Changed PROBING_MARGIN to 25 (previously 35).
  • Enabled HOME_AFTER_DEACTIVATE to force re-homing if steppers are disabled.
  • Enabled LCD_BED_TRAMMING.
  • Enabled PRINTCOUNTER
  • Enabled DISABLE_INACTIVE_Z to prevent steppers being deactivated after timeout exceeded on Z.
  • Enabled HOST_ACTION_COMMANDS in firmware.

Previous changes included:

  • E3D Hemera Hot-end support
  • Bed-size reduced to safe values 235 and probe margins revised for new hot-end carriage and mount.
  • TMC2209 drivers with Stealth-chop & Hybrid threshold enabled on X, Y, Z axis.
    • TMC_DEBUG enabled by default.
  • Movement on any axis is restricted until axis’s are homed.
  • PID Tuning
  • Extruder fan after 50°C
  • Z Safe homing
  • Advanced pause & filament change
  • Homing & Probing wizards
  • Support to mute menu sound
  • Custom quick commands:
    • Home & Level bed
    • Home & Info

To read more on changes introduced check the official Marlin 2.1.2 change log. Before we begin it’s assumed that you have the following equipment:

  • E3D Hemera Hot-end.
  • BTT SKR 1.4 Turbo Board.
  • BLTouch v3.1 (other versions of the BLTouch will work but you will need to adjust settings related to the devices version and additional check the wiring).

Using the custom Marlin build: Hemera SKR

Depending upon your preference there are multiple options available to utilise this custom firmware. Binary releases have been provided and you can view the configuration used to compile them. Or if you prefer you may use the configuration provided here to aid in building your own custom firmware.

With minor adjustments this can be tweaked to accommodate other similar board + hot end configuration or give you an idea on how to utilise this with your own hardware configuration.

Binary release

Important: these binaries were updated on: 16th April 2023 to address an issue where: #define NOZZLE_TO_PROBE_OFFSET was incorrectly set to { -41, 2, 1 } and should have been { -41, 2, 0 }. The Z value of 1 here would cause a calculation error when reusing meshes where the nozzle Z offset would be out by 1mm. The value of Z declared here is used in mesh calculation.

Note: that your specific configuration will vary this configuration uses both end-stop switches and a UBL (BLTouch).

  • View related source and binary downloads at: Binary releases v2.1.2 on GitLab, there are 4 flavours available:
    • Classic Jerk
    • Classic Jerk + Input Shaping
    • Junction deviation
    • Junction deviation + Input Shaping (suggested)

Preparing a custom build

PlatformIO Installation

I suggest VSCode as a quick method for compiling the Marlin 2.1.2 from source.

  1. Download VSCode and install.
  2. Open VSCode > Extension Manager > Search for and install the official PlatformIO IDE extension.

Firmware configuration source files

You can download the binary release for the firm or optionally build you own with the configuration files and instructions provided.

If you use the binary release please consider reviewing the checklist on tasks to perform after updating your 3D printers firmware.

Building your own binary

I have made my Marlin configurations and compiled firmware binaries available for download they feature the same changes mentioned within this article; if you use my configuration you should review your Probe offsets, check driver currents & determine if your endstops require inversion.

You will find configurations for both the stock hot-end and the newly added E3D Hemera hot-end:

To build your own variant from source; start by downloading the relevant Marlin releases used in this article from Marlin 2.1.2 branch:

Once you have downloaded the sources above you will need to extract them to an accessible location, use the following steps as a reference:

  1. Download and extract Marlin 2.1.2 sources
  2. Copy the 4 files to the Marlin directory contained within the extracted Marlin 2.1.2 sources.
  3. Then update the platform.ini file default_envs to LPC1769 and save.
  4. Compile by running the PlatformIO build operation: CTRL + ALT + B (Windows users).

Binary release releases are available on the GitLab project page

Firmware configuration modifications

Next we will be modifying 2 specific files from the release to customise the firmware for to our requirements:

  • /Marlin/Configuration.h
  • /Marlin/Configuration_adv.h

Depending upon whether you used my configurations or the stock configurations will determine if you need to merge the changes required to support the new hardware:

  1. Compare file: /Marlin/Configuration.h with custom file: Configuration.h (GitLab)
  2. Compare file: /Marlin/Configuration_adv.h with custom file: Configuration_adv.h (GitLab)
Switching between Classic Jerk and Junction Deviation

In the configuration provided you can change from junction deviation back to classic jerk by commenting out (omitting) #CLASSIC_JERK (found in file Configuration.h).

To utilise Junction deviation comment out #CLASSIC_JERK as shown below:

//#define CLASSIC_JERK

To utilise Classic Jerk remove the omission by deleting forward slashes prepended to #CLASSIC_JERK as below:

#define CLASSIC_JERK
Disabling or Enabling Input Shaping

Find and modify the following:

To enable Input shaping:

#define INPUT_SHAPING_X
#define INPUT_SHAPING_Y

To disable Input shaping:

//#define INPUT_SHAPING_X
//#define INPUT_SHAPING_Y

Post-update checklist & suggested reading

Friendly reminder; consider reviewing the checklist on tasks to perform after updating your 3D printers firmware. If you have used a binary from above; this article covers how to adjust offsets etc. via Marlin G-codes.