Skip to content

Commit 3a28a1f

Browse files
marciotthinkyhead
authored andcommitted
🩹 Fix ADVANCE_K + DISTINCT_E_FACTORS sanity check (MarlinFirmware#25007)
1 parent 360e037 commit 3a28a1f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Marlin/src/inc/SanityCheck.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1353,7 +1353,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
13531353
#if ENABLED(LIN_ADVANCE)
13541354
#if DISTINCT_E > 1
13551355
constexpr float lak[] = ADVANCE_K;
1356-
static_assert(COUNT(lak) < DISTINCT_E, "The ADVANCE_K array has too many elements (i.e., more than " STRINGIFY(DISTINCT_E) ").");
1356+
static_assert(COUNT(lak) <= DISTINCT_E, "The ADVANCE_K array has too many elements (i.e., more than " STRINGIFY(DISTINCT_E) ").");
13571357
#define _LIN_ASSERT(N) static_assert(N >= COUNT(lak) || WITHIN(lak[N], 0, 10), "ADVANCE_K values must be from 0 to 10 (Changed in LIN_ADVANCE v1.5, Marlin 1.1.9).");
13581358
REPEAT(DISTINCT_E, _LIN_ASSERT)
13591359
#undef _LIN_ASSERT

0 commit comments

Comments
 (0)