diff --git a/Marlin/src/inc/SanityCheck.h b/Marlin/src/inc/SanityCheck.h index 60b328ea67..1ff1e2b641 100644 --- a/Marlin/src/inc/SanityCheck.h +++ b/Marlin/src/inc/SanityCheck.h @@ -1028,6 +1028,9 @@ static_assert(NUM_SERVOS <= NUM_SERVO_PLUGS, "NUM_SERVOS (or some servo index) i #undef MPC_AUTOTUNE_MENU #undef MPC_PTC #endif +#if !WITHIN(PID_MAX, 0, 255) + #error "PID_MAX must be an integer from 0 to 255." +#endif #if ENABLED(MPC_INCLUDE_FAN) #if !HAS_FAN @@ -1048,6 +1051,9 @@ static_assert(NUM_SERVOS <= NUM_SERVO_PLUGS, "NUM_SERVOS (or some servo index) i #if ALL(PIDTEMPBED, BED_LIMIT_SWITCHING) #error "To use BED_LIMIT_SWITCHING you must disable PIDTEMPBED." #endif +#if !WITHIN(MAX_BED_POWER, 0, 255) + #error "MAX_BED_POWER must be an integer from 0 to 255." +#endif // Fan Kickstart power #if FAN_KICKSTART_TIME