From be8b5472615daad6a53694eb215e46c7a9377303 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Mon, 1 Mar 2021 07:10:00 -0600 Subject: [PATCH] Fix some config builds --- Marlin/src/gcode/feature/caselight/M355.cpp | 10 ++++++---- Marlin/src/module/motion.cpp | 2 +- Marlin/src/module/motion.h | 4 +++- Marlin/src/pins/pins.h | 2 +- .../share/PlatformIO/scripts/STM32F103VE_longer.py | 1 - 5 files changed, 11 insertions(+), 8 deletions(-) diff --git a/Marlin/src/gcode/feature/caselight/M355.cpp b/Marlin/src/gcode/feature/caselight/M355.cpp index 6634a90f4..b0d94e7cd 100644 --- a/Marlin/src/gcode/feature/caselight/M355.cpp +++ b/Marlin/src/gcode/feature/caselight/M355.cpp @@ -60,10 +60,12 @@ void GcodeSuite::M355() { if (!caselight.on) SERIAL_ECHOLNPGM(STR_OFF); else { - if (TERN0(CASELIGHT_USES_BRIGHTNESS, TERN(CASE_LIGHT_USE_NEOPIXEL, true, PWM_PIN(CASE_LIGHT_PIN)))) { - SERIAL_ECHOLN(int(caselight.brightness)); - return; - } + #if CASELIGHT_USES_BRIGHTNESS + if (TERN(CASE_LIGHT_USE_NEOPIXEL, true, PWM_PIN(CASE_LIGHT_PIN))) { + SERIAL_ECHOLN(int(caselight.brightness)); + return; + } + #endif SERIAL_ECHOLNPGM(STR_ON); } } diff --git a/Marlin/src/module/motion.cpp b/Marlin/src/module/motion.cpp index 580700bfe..6fff80ff7 100644 --- a/Marlin/src/module/motion.cpp +++ b/Marlin/src/module/motion.cpp @@ -1569,7 +1569,7 @@ void prepare_line_to_destination() { if (bump) { // Move away from the endstop by the axis HOMING_BUMP_MM if (DEBUGGING(LEVELING)) DEBUG_ECHOLNPAIR("Move Away: ", -bump, "mm"); - do_homing_move(axis, -bump, TERN0(HOMING_Z_WITH_PROBE, axis == Z_AXIS) ? MMM_TO_MMS(Z_PROBE_FEEDRATE_FAST) : 0, false); + do_homing_move(axis, -bump, TERN(HOMING_Z_WITH_PROBE, (axis == Z_AXIS ? z_probe_fast_mm_s : 0), 0), false); #if ENABLED(DETECT_BROKEN_ENDSTOP) // Check for a broken endstop diff --git a/Marlin/src/module/motion.h b/Marlin/src/module/motion.h index 2595084b4..f784c7bf8 100644 --- a/Marlin/src/module/motion.h +++ b/Marlin/src/module/motion.h @@ -65,7 +65,9 @@ extern xyz_pos_t cartes; #define XY_PROBE_FEEDRATE_MM_S PLANNER_XY_FEEDRATE() #endif -constexpr feedRate_t z_probe_fast_mm_s = MMM_TO_MMS(Z_PROBE_FEEDRATE_FAST); +#if HAS_BED_PROBE + constexpr feedRate_t z_probe_fast_mm_s = MMM_TO_MMS(Z_PROBE_FEEDRATE_FAST); +#endif /** * Feed rates are often configured with mm/m diff --git a/Marlin/src/pins/pins.h b/Marlin/src/pins/pins.h index 78aeaf066..b8cf695fb 100644 --- a/Marlin/src/pins/pins.h +++ b/Marlin/src/pins/pins.h @@ -255,7 +255,7 @@ #elif MB(OVERLORD) #include "mega/pins_OVERLORD.h" // ATmega2560 env:mega2560 #elif MB(HJC2560C_REV1) - #include "mega/pins_HJC2560C_REV1.h" // ATmega2560 env:mega2560 + #include "mega/pins_HJC2560C_REV2.h" // ATmega2560 env:mega2560 #elif MB(HJC2560C_REV2) #include "mega/pins_HJC2560C_REV2.h" // ATmega2560 env:mega2560 #elif MB(LEAPFROG_XEED2015) diff --git a/buildroot/share/PlatformIO/scripts/STM32F103VE_longer.py b/buildroot/share/PlatformIO/scripts/STM32F103VE_longer.py index bbdfcd93b..321dd01b8 100644 --- a/buildroot/share/PlatformIO/scripts/STM32F103VE_longer.py +++ b/buildroot/share/PlatformIO/scripts/STM32F103VE_longer.py @@ -18,7 +18,6 @@ for i, flag in enumerate(env["LINKFLAGS"]): elif flag == "-T": env["LINKFLAGS"][i + 1] = custom_ld_script - # Rename ${PROGNAME}.bin and save it as 'project.bin' (No encryption on the Longer3D) def encrypt(source, target, env): firmware = open(target[0].path, "rb")