From afc2dd6cab2c50ddca1506350a8845b82a4ffce7 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Thu, 25 Jan 2024 22:09:06 -0600 Subject: [PATCH] =?UTF-8?q?=F0=9F=8E=A8=20Misc.=20cleanup=2025-01?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Marlin/src/HAL/HC32/inc/SanityCheck.h | 6 ++---- Marlin/src/HAL/HC32/printf_retarget.cpp | 2 +- Marlin/src/module/scara.cpp | 4 +--- 3 files changed, 4 insertions(+), 8 deletions(-) diff --git a/Marlin/src/HAL/HC32/inc/SanityCheck.h b/Marlin/src/HAL/HC32/inc/SanityCheck.h index d7c6894039..ef8d9a9975 100644 --- a/Marlin/src/HAL/HC32/inc/SanityCheck.h +++ b/Marlin/src/HAL/HC32/inc/SanityCheck.h @@ -58,11 +58,9 @@ #endif #if TEMP_SENSOR_SOC - #if !defined(TEMP_SOC_PIN) + #ifndef TEMP_SOC_PIN #error "TEMP_SOC_PIN must be defined to use TEMP_SENSOR_SOC." - #endif - - #if defined(TEMP_SOC_PIN) && IS_GPIO_PIN(TEMP_SOC_PIN) + #elif IS_GPIO_PIN(TEMP_SOC_PIN) #error "TEMP_SOC_PIN must not be a valid GPIO pin to avoid conflicts." #endif #endif diff --git a/Marlin/src/HAL/HC32/printf_retarget.cpp b/Marlin/src/HAL/HC32/printf_retarget.cpp index 2c98415dff..8a48aca3d4 100644 --- a/Marlin/src/HAL/HC32/printf_retarget.cpp +++ b/Marlin/src/HAL/HC32/printf_retarget.cpp @@ -23,7 +23,7 @@ #ifdef ARDUINO_ARCH_HC32 #ifdef REDIRECT_PRINTF_TO_SERIAL -#if !defined(__GNUC__) +#ifndef __GNUC__ #error "only GCC is supported" #endif diff --git a/Marlin/src/module/scara.cpp b/Marlin/src/module/scara.cpp index 9c149670e9..0f00ab5643 100644 --- a/Marlin/src/module/scara.cpp +++ b/Marlin/src/module/scara.cpp @@ -229,9 +229,7 @@ float segments_per_second = DEFAULT_SEGMENTS_PER_SECOND; // Move all carriages together linearly until an endstop is hit. //do_blocking_move_to_xy_z(pos, mlz, homing_feedrate(Z_AXIS)); - current_position.x = 0 ; - current_position.y = 0 ; - current_position.z = max_length(Z_AXIS) ; + current_position.set(0, 0, max_length(Z_AXIS)); line_to_current_position(homing_feedrate(Z_AXIS)); planner.synchronize();