577577constexpr float arm[] = AXIS_RELATIVE_MODES;
578578static_assert (COUNT(arm) == LOGICAL_AXES, " AXIS_RELATIVE_MODES must contain " _LOGICAL_AXES_STR " elements." );
579579
580- #ifdef PTC_SAMPLE_START
581- auto _ptc_sample_start = PTC_SAMPLE_START;
582- constexpr decltype (_ptc_sample_start) _test_ptc_sample_start = 12.3f;
583- static_assert ( _test_ptc_sample_start != 12 .3f , " PTC_SAMPLE_START should not be a float; use whole numbers only." );
584- #endif
585-
586- #ifdef PTC_SAMPLE_RES
587- auto _ptc_sample_res = PTC_SAMPLE_END;
588- constexpr decltype (_ptc_sample_res) _test_ptc_sample_res = 12.3f;
589- static_assert ( _test_ptc_sample_res != 12 .3f , " PTC_SAMPLE_RES should not be a float; use whole numbers only." );
590- #endif
591-
592- #ifdef BTC_SAMPLE_START
593- auto _btc_sample_start = BTC_SAMPLE_START;
594- constexpr decltype (_btc_sample_start) _test_btc_sample_start = 12.3f;
595- static_assert ( _test_btc_sample_start != 12 .3f , " BTC_SAMPLE_START should not be a float; use whole numbers only." );
596- #endif
597-
598- #ifdef BTC_SAMPLE_RES
599- auto _btc_sample_res = BTC_SAMPLE_END;
600- constexpr decltype (_btc_sample_res) _test_btc_sample_res = 12.3f;
601- static_assert ( _test_btc_sample_res != 12 .3f , " BTC_SAMPLE_RES should not be a float; use whole numbers only." );
602- #endif
603-
604- #ifdef BTC_PROBE_TEMP
605- auto _btc_probe_temp = BTC_PROBE_TEMP;
606- constexpr decltype (_btc_probe_temp) _test_btc_probe_temp = 12.3f;
607- static_assert ( _test_btc_probe_temp != 12 .3f , " BTC_SAMPLE_RES should not be a float; use whole numbers only." );
608- #endif
609-
610580/* *
611581 * Probe temp compensation requirements
612582 */
583+
613584#if ENABLED(PROBE_TEMP_COMPENSATION)
614585 #if defined(PTC_PARK_POS_X) || defined(PTC_PARK_POS_Y) || defined(PTC_PARK_POS_Z)
615586 #error "PTC_PARK_POS_[XYZ] is now PTC_PARK_POS (array)."
@@ -620,6 +591,27 @@ static_assert(COUNT(arm) == LOGICAL_AXES, "AXIS_RELATIVE_MODES must contain " _L
620591 #elif !defined(PTC_PROBE_POS)
621592 #error "PROBE_TEMP_COMPENSATION requires PTC_PROBE_POS."
622593 #endif
594+
595+ #ifdef PTC_SAMPLE_START
596+ constexpr int _ptc_sample_start = PTC_SAMPLE_START;
597+ static_assert (_test_ptc_sample_start != PTC_SAMPLE_START, " PTC_SAMPLE_START must be a whole number." );
598+ #endif
599+ #ifdef PTC_SAMPLE_RES
600+ constexpr int _ptc_sample_res = PTC_SAMPLE_END;
601+ static_assert (_test_ptc_sample_res != PTC_SAMPLE_END, " PTC_SAMPLE_RES must be a whole number." );
602+ #endif
603+ #ifdef BTC_SAMPLE_START
604+ constexpr int _btc_sample_start = BTC_SAMPLE_START;
605+ static_assert (_test_btc_sample_start != BTC_SAMPLE_START, " BTC_SAMPLE_START must be a whole number." );
606+ #endif
607+ #ifdef BTC_SAMPLE_RES
608+ constexpr int _btc_sample_res = BTC_SAMPLE_END;
609+ static_assert (_test_btc_sample_res != BTC_SAMPLE_END, " BTC_SAMPLE_RES must be a whole number." );
610+ #endif
611+ #ifdef BTC_PROBE_TEMP
612+ constexpr int _btc_probe_temp = BTC_PROBE_TEMP;
613+ static_assert (_test_btc_probe_temp != BTC_PROBE_TEMP, " BTC_PROBE_TEMP must be a whole number." );
614+ #endif
623615#endif
624616
625617/* *
0 commit comments