From f2656ce225d7a19bfe4171b9e1c6d8381fe330d1 Mon Sep 17 00:00:00 2001 From: Bob Kuhn Date: Sun, 16 Apr 2023 18:35:13 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=A9=B9=20Fix=20laser=20with=20no=20PWM=20?= =?UTF-8?q?compile=20(#25290)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Marlin/src/feature/spindle_laser.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Marlin/src/feature/spindle_laser.h b/Marlin/src/feature/spindle_laser.h index a49e5611a4a90..9750d4807fc19 100644 --- a/Marlin/src/feature/spindle_laser.h +++ b/Marlin/src/feature/spindle_laser.h @@ -281,7 +281,7 @@ class SpindleLaser { set_enabled(state); if (state) { if (!menuPower) menuPower = cpwr_to_upwr(SPEED_POWER_STARTUP); - power = upower_to_ocr(menuPower); + power = TERN(SPINDLE_LASER_USE_PWM, upower_to_ocr(menuPower), 255); apply_power(power); } else apply_power(0);