|
|
|
@ -16,7 +16,7 @@
|
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
|
*
|
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
|
|
|
*
|
|
|
|
|
*/
|
|
|
|
|
#pragma once
|
|
|
|
@ -262,7 +262,7 @@
|
|
|
|
|
#error "LCD_PIN_RESET is now LCD_RESET_PIN. Please update your pins definitions."
|
|
|
|
|
#elif defined(EXTRUDER_0_AUTO_FAN_PIN) || defined(EXTRUDER_1_AUTO_FAN_PIN) || defined(EXTRUDER_2_AUTO_FAN_PIN) || defined(EXTRUDER_3_AUTO_FAN_PIN)
|
|
|
|
|
#error "EXTRUDER_[0123]_AUTO_FAN_PIN is now E[0123]_AUTO_FAN_PIN. Please update your Configuration_adv.h."
|
|
|
|
|
#elif defined(PID_FAN_SCALING) && FAN_COUNT <= 0
|
|
|
|
|
#elif defined(PID_FAN_SCALING) && !HAS_FAN
|
|
|
|
|
#error "PID_FAN_SCALING needs at least one fan enabled."
|
|
|
|
|
#elif defined(min_software_endstops) || defined(max_software_endstops)
|
|
|
|
|
#error "(min|max)_software_endstops are now (MIN|MAX)_SOFTWARE_ENDSTOPS. Please update your configuration."
|
|
|
|
@ -283,9 +283,9 @@
|
|
|
|
|
#elif defined(NEOPIXEL_RGBW_LED)
|
|
|
|
|
#error "NEOPIXEL_RGBW_LED is now NEOPIXEL_LED. Please update your configuration."
|
|
|
|
|
#elif ENABLED(DELTA) && defined(DELTA_PROBEABLE_RADIUS)
|
|
|
|
|
#error "Remove DELTA_PROBEABLE_RADIUS and use MIN_PROBE_EDGE to inset the probe area instead."
|
|
|
|
|
#error "Remove DELTA_PROBEABLE_RADIUS and use PROBING_MARGIN to inset the probe area instead."
|
|
|
|
|
#elif ENABLED(DELTA) && defined(DELTA_CALIBRATION_RADIUS)
|
|
|
|
|
#error "Remove DELTA_CALIBRATION_RADIUS and use MIN_PROBE_EDGE to inset the probe area instead."
|
|
|
|
|
#error "Remove DELTA_CALIBRATION_RADIUS and use PROBING_MARGIN to inset the probe area instead."
|
|
|
|
|
#elif defined(UBL_MESH_INSET)
|
|
|
|
|
#error "UBL_MESH_INSET is now just MESH_INSET. Please update your configuration."
|
|
|
|
|
#elif defined(UBL_MESH_MIN_X) || defined(UBL_MESH_MIN_Y) || defined(UBL_MESH_MAX_X) || defined(UBL_MESH_MAX_Y)
|
|
|
|
@ -294,14 +294,24 @@
|
|
|
|
|
#error "ABL_PROBE_PT_[123]_[XY] is no longer required. Please remove it from Configuration.h."
|
|
|
|
|
#elif defined(UBL_PROBE_PT_1_X) || defined(UBL_PROBE_PT_1_Y) || defined(UBL_PROBE_PT_2_X) || defined(UBL_PROBE_PT_2_Y) || defined(UBL_PROBE_PT_3_X) || defined(UBL_PROBE_PT_3_Y)
|
|
|
|
|
#error "UBL_PROBE_PT_[123]_[XY] is no longer required. Please remove it from Configuration.h."
|
|
|
|
|
#elif defined(MIN_PROBE_EDGE)
|
|
|
|
|
#error "MIN_PROBE_EDGE is now called PROBING_MARGIN. Please update your configuration."
|
|
|
|
|
#elif defined(MIN_PROBE_EDGE_LEFT)
|
|
|
|
|
#error "MIN_PROBE_EDGE_LEFT is now called PROBING_MARGIN_LEFT. Please update your configuration."
|
|
|
|
|
#elif defined(MIN_PROBE_EDGE_RIGHT)
|
|
|
|
|
#error "MIN_PROBE_EDGE_RIGHT is now called PROBING_MARGIN_RIGHT. Please update your configuration."
|
|
|
|
|
#elif defined(MIN_PROBE_EDGE_FRONT)
|
|
|
|
|
#error "MIN_PROBE_EDGE_FRONT is now called PROBING_MARGIN_FRONT. Please update your configuration."
|
|
|
|
|
#elif defined(MIN_PROBE_EDGE_BACK)
|
|
|
|
|
#error "MIN_PROBE_EDGE_BACK is now called PROBING_MARGIN_BACK. Please update your configuration."
|
|
|
|
|
#elif defined(LEFT_PROBE_BED_POSITION)
|
|
|
|
|
#error "LEFT_PROBE_BED_POSITION has been replaced by MIN_PROBE_EDGE_LEFT. Please update your configuration."
|
|
|
|
|
#error "LEFT_PROBE_BED_POSITION is obsolete. Set a margin with PROBING_MARGIN or PROBING_MARGIN_LEFT instead."
|
|
|
|
|
#elif defined(RIGHT_PROBE_BED_POSITION)
|
|
|
|
|
#error "RIGHT_PROBE_BED_POSITION has been replaced by MIN_PROBE_EDGE_RIGHT. Please update your configuration."
|
|
|
|
|
#error "RIGHT_PROBE_BED_POSITION is obsolete. Set a margin with PROBING_MARGIN or PROBING_MARGIN_RIGHT instead."
|
|
|
|
|
#elif defined(FRONT_PROBE_BED_POSITION)
|
|
|
|
|
#error "FRONT_PROBE_BED_POSITION has been replaced by MIN_PROBE_EDGE_FRONT. Please update your configuration."
|
|
|
|
|
#error "FRONT_PROBE_BED_POSITION is obsolete. Set a margin with PROBING_MARGIN or PROBING_MARGIN_FRONT instead."
|
|
|
|
|
#elif defined(BACK_PROBE_BED_POSITION)
|
|
|
|
|
#error "BACK_PROBE_BED_POSITION has been replaced by MIN_PROBE_EDGE_BACK. Please update your configuration."
|
|
|
|
|
#error "BACK_PROBE_BED_POSITION is obsolete. Set a margin with PROBING_MARGIN or PROBING_MARGIN_BACK instead."
|
|
|
|
|
#elif defined(ENABLE_MESH_EDIT_GFX_OVERLAY)
|
|
|
|
|
#error "ENABLE_MESH_EDIT_GFX_OVERLAY is now MESH_EDIT_GFX_OVERLAY. Please update your configuration."
|
|
|
|
|
#elif defined(BABYSTEP_ZPROBE_GFX_REVERSE)
|
|
|
|
@ -355,7 +365,7 @@
|
|
|
|
|
#error "LEVEL_BED_CORNERS requires LEVEL_CORNERS_INSET_LFRB values. Please update your Configuration.h."
|
|
|
|
|
#elif defined(BEZIER_JERK_CONTROL)
|
|
|
|
|
#error "BEZIER_JERK_CONTROL is now S_CURVE_ACCELERATION. Please update your configuration."
|
|
|
|
|
#elif DISABLED(CLASSIC_JERK) && defined(JUNCTION_DEVIATION_FACTOR)
|
|
|
|
|
#elif HAS_JUNCTION_DEVIATION && defined(JUNCTION_DEVIATION_FACTOR)
|
|
|
|
|
#error "JUNCTION_DEVIATION_FACTOR is now JUNCTION_DEVIATION_MM. Please update your configuration."
|
|
|
|
|
#elif defined(JUNCTION_ACCELERATION_FACTOR)
|
|
|
|
|
#error "JUNCTION_ACCELERATION_FACTOR is obsolete. Delete it from Configuration_adv.h."
|
|
|
|
@ -411,6 +421,8 @@
|
|
|
|
|
#error "SPINDLE_STOP_ON_DIR_CHANGE is now SPINDLE_CHANGE_DIR_STOP. Please update your Configuration_adv.h."
|
|
|
|
|
#elif defined(SPINDLE_LASER_ENABLE_INVERT)
|
|
|
|
|
#error "SPINDLE_LASER_ENABLE_INVERT is now SPINDLE_LASER_ACTIVE_HIGH. Please update your Configuration_adv.h."
|
|
|
|
|
#elif defined(CUTTER_POWER_DISPLAY)
|
|
|
|
|
#error "CUTTER_POWER_DISPLAY is now CUTTER_POWER_UNIT. Please update your Configuration_adv.h."
|
|
|
|
|
#elif defined(CHAMBER_HEATER_PIN)
|
|
|
|
|
#error "CHAMBER_HEATER_PIN is now HEATER_CHAMBER_PIN. Please update your configuration and/or pins."
|
|
|
|
|
#elif defined(TMC_Z_CALIBRATION)
|
|
|
|
@ -437,6 +449,10 @@
|
|
|
|
|
#error "POWER_SUPPLY is now obsolete. Please remove it from Configuration.h."
|
|
|
|
|
#elif defined(MKS_ROBIN_TFT)
|
|
|
|
|
#error "MKS_ROBIN_TFT is now FSMC_GRAPHICAL_TFT. Please update your configuration."
|
|
|
|
|
#elif defined(TFT_LVGL_UI)
|
|
|
|
|
#error "TFT_LVGL_UI is now TFT_LVGL_UI_FSMC. Please update your configuration."
|
|
|
|
|
#elif defined(SPI_GRAPHICAL_TFT)
|
|
|
|
|
#error "SPI_GRAPHICAL_TFT is now TFT_LVGL_UI_SPI. Please update your configuration."
|
|
|
|
|
#elif defined(SDPOWER)
|
|
|
|
|
#error "SDPOWER is now SDPOWER_PIN. Please update your configuration and/or pins."
|
|
|
|
|
#elif defined(STRING_SPLASH_LINE1) || defined(STRING_SPLASH_LINE2)
|
|
|
|
@ -489,6 +505,42 @@
|
|
|
|
|
#error "Z_QUAD_ENDSTOPS is now Z_MULTI_ENDSTOPS. Please update Configuration_adv.h."
|
|
|
|
|
#elif defined(DUGS_UI_MOVE_DIS_OPTION)
|
|
|
|
|
#error "DUGS_UI_MOVE_DIS_OPTION is spelled DGUS_UI_MOVE_DIS_OPTION. Please update Configuration_adv.h."
|
|
|
|
|
#elif defined(ORIG_E0_AUTO_FAN_PIN) || defined(ORIG_E1_AUTO_FAN_PIN) || defined(ORIG_E2_AUTO_FAN_PIN) || defined(ORIG_E3_AUTO_FAN_PIN) || defined(ORIG_E4_AUTO_FAN_PIN) || defined(ORIG_E5_AUTO_FAN_PIN) || defined(ORIG_E6_AUTO_FAN_PIN) || defined(ORIG_E7_AUTO_FAN_PIN)
|
|
|
|
|
#error "ORIG_Ex_AUTO_FAN_PIN is now just Ex_AUTO_FAN_PIN. Make sure your pins are up to date."
|
|
|
|
|
#elif defined(ORIG_CHAMBER_AUTO_FAN_PIN)
|
|
|
|
|
#error "ORIG_CHAMBER_AUTO_FAN_PIN is now just CHAMBER_AUTO_FAN_PIN. Make sure your pins are up to date."
|
|
|
|
|
#elif defined(HOMING_BACKOFF_MM)
|
|
|
|
|
#error "HOMING_BACKOFF_MM is now HOMING_BACKOFF_POST_MM. Please update Configuration_adv.h."
|
|
|
|
|
#elif defined(X_HOME_BUMP_MM) || defined(Y_HOME_BUMP_MM) || defined(Z_HOME_BUMP_MM)
|
|
|
|
|
#error "[XYZ]_HOME_BUMP_MM is now HOMING_BUMP_MM. Please update Configuration_adv.h."
|
|
|
|
|
#elif defined(DIGIPOT_I2C)
|
|
|
|
|
#error "DIGIPOT_I2C is now DIGIPOT_MCP4451 (or DIGIPOT_MCP4018). Please update Configuration_adv.h."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#ifdef FIL_RUNOUT_INVERTING
|
|
|
|
|
#if FIL_RUNOUT_INVERTING
|
|
|
|
|
#warning "FIL_RUNOUT_INVERTING true is now FIL_RUNOUT_STATE HIGH. Please update Configuration.h."
|
|
|
|
|
#else
|
|
|
|
|
#warning "FIL_RUNOUT_INVERTING false is now FIL_RUNOUT_STATE LOW. Please update Configuration.h."
|
|
|
|
|
#endif
|
|
|
|
|
#ifndef FIL_RUNOUT_STATE
|
|
|
|
|
#define FIL_RUNOUT_STATE ((FIL_RUNOUT_INVERTING) ? HIGH : LOW)
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Probe temp compensation requirements
|
|
|
|
|
*/
|
|
|
|
|
#if ENABLED(PROBE_TEMP_COMPENSATION)
|
|
|
|
|
#if defined(PTC_PARK_POS_X) || defined(PTC_PARK_POS_Y) || defined(PTC_PARK_POS_Z)
|
|
|
|
|
#error "PTC_PARK_POS_[XYZ] is now PTC_PARK_POS (array). Please update Configuration_adv.h."
|
|
|
|
|
#elif !defined(PTC_PARK_POS)
|
|
|
|
|
#error "PROBE_TEMP_COMPENSATION requires PTC_PARK_POS."
|
|
|
|
|
#elif defined(PTC_PROBE_POS_X) || defined(PTC_PROBE_POS_Y)
|
|
|
|
|
#error "PTC_PROBE_POS_[XY] is now PTC_PROBE_POS (array). Please update Configuration_adv.h."
|
|
|
|
|
#elif !defined(PTC_PROBE_POS)
|
|
|
|
|
#error "PROBE_TEMP_COMPENSATION requires PTC_PROBE_POS."
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
@ -637,7 +689,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#elif PROGRESS_MSG_EXPIRE < 0
|
|
|
|
|
#error "PROGRESS_MSG_EXPIRE must be greater than or equal to 0."
|
|
|
|
|
#endif
|
|
|
|
|
#elif ENABLED(LCD_SET_PROGRESS_MANUALLY) && !HAS_GRAPHICAL_LCD && DISABLED(EXTENSIBLE_UI)
|
|
|
|
|
#elif ENABLED(LCD_SET_PROGRESS_MANUALLY) && NONE(HAS_GRAPHICAL_LCD, EXTENSIBLE_UI)
|
|
|
|
|
#error "LCD_SET_PROGRESS_MANUALLY requires LCD_PROGRESS_BAR, Graphical LCD, or EXTENSIBLE_UI."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
@ -648,7 +700,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
/**
|
|
|
|
|
* Custom Boot and Status screens
|
|
|
|
|
*/
|
|
|
|
|
#if ENABLED(SHOW_CUSTOM_BOOTSCREEN) && !(HAS_GRAPHICAL_LCD || ENABLED(TOUCH_UI_FTDI_EVE))
|
|
|
|
|
#if ENABLED(SHOW_CUSTOM_BOOTSCREEN) && NONE(HAS_GRAPHICAL_LCD, TOUCH_UI_FTDI_EVE)
|
|
|
|
|
#error "SHOW_CUSTOM_BOOTSCREEN requires Graphical LCD or TOUCH_UI_FTDI_EVE."
|
|
|
|
|
#elif ENABLED(CUSTOM_STATUS_SCREEN_IMAGE) && !HAS_GRAPHICAL_LCD
|
|
|
|
|
#error "CUSTOM_STATUS_SCREEN_IMAGE requires a Graphical LCD."
|
|
|
|
@ -723,6 +775,15 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#error "BABYSTEP_HOTEND_Z_OFFSET requires 2 or more HOTENDS."
|
|
|
|
|
#elif BOTH(BABYSTEP_ALWAYS_AVAILABLE, MOVE_Z_WHEN_IDLE)
|
|
|
|
|
#error "BABYSTEP_ALWAYS_AVAILABLE and MOVE_Z_WHEN_IDLE are incompatible."
|
|
|
|
|
#elif !defined(BABYSTEP_MULTIPLICATOR_Z)
|
|
|
|
|
#error "BABYSTEPPING requires BABYSTEP_MULTIPLICATOR_Z."
|
|
|
|
|
#elif ENABLED(BABYSTEP_XY) && !defined(BABYSTEP_MULTIPLICATOR_XY)
|
|
|
|
|
#error "BABYSTEP_XY requires BABYSTEP_MULTIPLICATOR_XY."
|
|
|
|
|
#elif ENABLED(BABYSTEP_MILLIMETER_UNITS)
|
|
|
|
|
static_assert(BABYSTEP_MULTIPLICATOR_Z <= 0.1f, "BABYSTEP_MULTIPLICATOR_Z must be less or equal to 0.1mm.");
|
|
|
|
|
#if ENABLED(BABYSTEP_XY)
|
|
|
|
|
static_assert(BABYSTEP_MULTIPLICATOR_XY <= 0.25f, "BABYSTEP_MULTIPLICATOR_XY must be less than or equal to 0.25mm.");
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
@ -781,6 +842,10 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#if ENABLED(NOZZLE_PARK_FEATURE)
|
|
|
|
|
constexpr float npp[] = NOZZLE_PARK_POINT;
|
|
|
|
|
static_assert(COUNT(npp) == XYZ, "NOZZLE_PARK_POINT requires X, Y, and Z values.");
|
|
|
|
|
constexpr xyz_pos_t npp_xyz = NOZZLE_PARK_POINT;
|
|
|
|
|
static_assert(WITHIN(npp_xyz.x, X_MIN_POS, X_MAX_POS), "NOZZLE_PARK_POINT.X is out of bounds (X_MIN_POS, X_MAX_POS).");
|
|
|
|
|
static_assert(WITHIN(npp_xyz.y, Y_MIN_POS, Y_MAX_POS), "NOZZLE_PARK_POINT.Y is out of bounds (Y_MIN_POS, Y_MAX_POS).");
|
|
|
|
|
static_assert(WITHIN(npp_xyz.z, Z_MIN_POS, Z_MAX_POS), "NOZZLE_PARK_POINT.Z is out of bounds (Z_MIN_POS, Z_MAX_POS).");
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
@ -804,14 +869,15 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if ENABLED(TOOLCHANGE_FILAMENT_SWAP)
|
|
|
|
|
#ifndef TOOLCHANGE_FIL_SWAP_LENGTH
|
|
|
|
|
#error "TOOLCHANGE_FILAMENT_SWAP requires TOOLCHANGE_FIL_SWAP_LENGTH. Please update your Configuration."
|
|
|
|
|
#elif !defined(TOOLCHANGE_FIL_SWAP_RETRACT_SPEED)
|
|
|
|
|
#error "TOOLCHANGE_FILAMENT_SWAP requires TOOLCHANGE_FIL_SWAP_RETRACT_SPEED. Please update your Configuration."
|
|
|
|
|
#elif !defined(TOOLCHANGE_FIL_SWAP_PRIME_SPEED)
|
|
|
|
|
#error "TOOLCHANGE_FILAMENT_SWAP requires TOOLCHANGE_FIL_SWAP_PRIME_SPEED. Please update your Configuration."
|
|
|
|
|
#ifndef TOOLCHANGE_FS_LENGTH
|
|
|
|
|
#error "TOOLCHANGE_FILAMENT_SWAP requires TOOLCHANGE_FS_LENGTH. Please update your Configuration_adv.h."
|
|
|
|
|
#elif !defined(TOOLCHANGE_FS_RETRACT_SPEED)
|
|
|
|
|
#error "TOOLCHANGE_FILAMENT_SWAP requires TOOLCHANGE_FS_RETRACT_SPEED. Please update your Configuration_adv.h."
|
|
|
|
|
#elif !defined(TOOLCHANGE_FS_PRIME_SPEED)
|
|
|
|
|
#error "TOOLCHANGE_FILAMENT_SWAP requires TOOLCHANGE_FS_PRIME_SPEED. Please update your Configuration_adv.h."
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if ENABLED(TOOLCHANGE_PARK)
|
|
|
|
|
#ifndef TOOLCHANGE_PARK_XY
|
|
|
|
|
#error "TOOLCHANGE_PARK requires TOOLCHANGE_PARK_XY. Please update your Configuration."
|
|
|
|
@ -935,6 +1001,9 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
WITHIN(LIN_ADVANCE_K, 0, 10),
|
|
|
|
|
"LIN_ADVANCE_K must be a value from 0 to 10 (Changed in LIN_ADVANCE v1.5, Marlin 1.1.9)."
|
|
|
|
|
);
|
|
|
|
|
#if ENABLED(S_CURVE_ACCELERATION) && DISABLED(EXPERIMENTAL_SCURVE)
|
|
|
|
|
#error "LIN_ADVANCE and S_CURVE_ACCELERATION may not play well together! Enable EXPERIMENTAL_SCURVE to continue."
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
@ -1104,7 +1173,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
/**
|
|
|
|
|
* Junction deviation is incompatible with kinematic systems.
|
|
|
|
|
*/
|
|
|
|
|
#if DISABLED(CLASSIC_JERK) && IS_KINEMATIC
|
|
|
|
|
#if HAS_JUNCTION_DEVIATION && IS_KINEMATIC
|
|
|
|
|
#error "CLASSIC_JERK is required for DELTA and SCARA."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
@ -1120,7 +1189,8 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
+ ENABLED(FIX_MOUNTED_PROBE) \
|
|
|
|
|
+ ENABLED(NOZZLE_AS_PROBE) \
|
|
|
|
|
+ (HAS_Z_SERVO_PROBE && DISABLED(BLTOUCH)) \
|
|
|
|
|
+ ENABLED(BLTOUCH) \
|
|
|
|
|
+ ENABLED(BLTOUCH) && DISABLED(CREALITY_TOUCH) \
|
|
|
|
|
+ ENABLED(CREALITY_TOUCH) \
|
|
|
|
|
+ ENABLED(TOUCH_MI_PROBE) \
|
|
|
|
|
+ ENABLED(SOLENOID_PROBE) \
|
|
|
|
|
+ ENABLED(Z_PROBE_ALLEN_KEY) \
|
|
|
|
@ -1230,13 +1300,21 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if DISABLED(NOZZLE_AS_PROBE)
|
|
|
|
|
static_assert(MIN_PROBE_EDGE >= 0, "MIN_PROBE_EDGE must be >= 0.");
|
|
|
|
|
static_assert(MIN_PROBE_EDGE_BACK >= 0, "MIN_PROBE_EDGE_BACK must be >= 0.");
|
|
|
|
|
static_assert(MIN_PROBE_EDGE_FRONT >= 0, "MIN_PROBE_EDGE_FRONT must be >= 0.");
|
|
|
|
|
static_assert(MIN_PROBE_EDGE_LEFT >= 0, "MIN_PROBE_EDGE_LEFT must be >= 0.");
|
|
|
|
|
static_assert(MIN_PROBE_EDGE_RIGHT >= 0, "MIN_PROBE_EDGE_RIGHT must be >= 0.");
|
|
|
|
|
static_assert(PROBING_MARGIN >= 0, "PROBING_MARGIN must be >= 0.");
|
|
|
|
|
static_assert(PROBING_MARGIN_BACK >= 0, "PROBING_MARGIN_BACK must be >= 0.");
|
|
|
|
|
static_assert(PROBING_MARGIN_FRONT >= 0, "PROBING_MARGIN_FRONT must be >= 0.");
|
|
|
|
|
static_assert(PROBING_MARGIN_LEFT >= 0, "PROBING_MARGIN_LEFT must be >= 0.");
|
|
|
|
|
static_assert(PROBING_MARGIN_RIGHT >= 0, "PROBING_MARGIN_RIGHT must be >= 0.");
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#define _MARGIN(A) TERN(IS_SCARA, SCARA_PRINTABLE_RADIUS, TERN(DELTA, DELTA_PRINTABLE_RADIUS, A##_CENTER))
|
|
|
|
|
static_assert(PROBING_MARGIN < _MARGIN(X), "PROBING_MARGIN is too large.");
|
|
|
|
|
static_assert(PROBING_MARGIN_BACK < _MARGIN(Y), "PROBING_MARGIN_BACK is too large.");
|
|
|
|
|
static_assert(PROBING_MARGIN_FRONT < _MARGIN(Y), "PROBING_MARGIN_FRONT is too large.");
|
|
|
|
|
static_assert(PROBING_MARGIN_LEFT < _MARGIN(X), "PROBING_MARGIN_LEFT is too large.");
|
|
|
|
|
static_assert(PROBING_MARGIN_RIGHT < _MARGIN(X), "PROBING_MARGIN_RIGHT is too large.");
|
|
|
|
|
#undef _MARGIN
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Make sure Z raise values are set
|
|
|
|
|
*/
|
|
|
|
@ -1252,8 +1330,8 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#error "Probes need Z_AFTER_PROBING >= 0."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if MULTIPLE_PROBING || EXTRA_PROBING
|
|
|
|
|
#if !MULTIPLE_PROBING
|
|
|
|
|
#if MULTIPLE_PROBING > 0 || EXTRA_PROBING > 0
|
|
|
|
|
#if MULTIPLE_PROBING == 0
|
|
|
|
|
#error "EXTRA_PROBING requires MULTIPLE_PROBING."
|
|
|
|
|
#elif MULTIPLE_PROBING < 2
|
|
|
|
|
#error "MULTIPLE_PROBING must be 2 or more."
|
|
|
|
@ -1350,15 +1428,19 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if HAS_MESH
|
|
|
|
|
#if HAS_CLASSIC_JERK
|
|
|
|
|
static_assert(DEFAULT_ZJERK > 0.1, "Low DEFAULT_ZJERK values are incompatible with mesh-based leveling.");
|
|
|
|
|
#endif
|
|
|
|
|
#elif ENABLED(G26_MESH_VALIDATION)
|
|
|
|
|
#error "G26_MESH_VALIDATION requires MESH_BED_LEVELING, AUTO_BED_LEVELING_BILINEAR, or AUTO_BED_LEVELING_UBL."
|
|
|
|
|
#if HAS_MESH && HAS_CLASSIC_JERK
|
|
|
|
|
static_assert(DEFAULT_ZJERK > 0.1, "Low DEFAULT_ZJERK values are incompatible with mesh-based leveling.");
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if ENABLED(MESH_EDIT_GFX_OVERLAY) && !(ENABLED(AUTO_BED_LEVELING_UBL) && HAS_GRAPHICAL_LCD)
|
|
|
|
|
#if ENABLED(G26_MESH_VALIDATION)
|
|
|
|
|
#if !EXTRUDERS
|
|
|
|
|
#error "G26_MESH_VALIDATION requires at least one extruder."
|
|
|
|
|
#elif !HAS_MESH
|
|
|
|
|
#error "G26_MESH_VALIDATION requires MESH_BED_LEVELING, AUTO_BED_LEVELING_BILINEAR, or AUTO_BED_LEVELING_UBL."
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if ENABLED(MESH_EDIT_GFX_OVERLAY) && !BOTH(AUTO_BED_LEVELING_UBL, HAS_GRAPHICAL_LCD)
|
|
|
|
|
#error "MESH_EDIT_GFX_OVERLAY requires AUTO_BED_LEVELING_UBL and a Graphical LCD."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
@ -1384,9 +1466,11 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
/**
|
|
|
|
|
* Homing
|
|
|
|
|
*/
|
|
|
|
|
#if X_HOME_BUMP_MM < 0 || Y_HOME_BUMP_MM < 0 || Z_HOME_BUMP_MM < 0
|
|
|
|
|
#error "[XYZ]_HOME_BUMP_MM must be greater than or equal to 0."
|
|
|
|
|
#endif
|
|
|
|
|
constexpr float hbm[] = HOMING_BUMP_MM;
|
|
|
|
|
static_assert(COUNT(hbm) == XYZ, "HOMING_BUMP_MM requires X, Y, and Z elements.");
|
|
|
|
|
static_assert(hbm[X_AXIS] >= 0, "HOMING_BUMP_MM.X must be greater than or equal to 0.");
|
|
|
|
|
static_assert(hbm[Y_AXIS] >= 0, "HOMING_BUMP_MM.Y must be greater than or equal to 0.");
|
|
|
|
|
static_assert(hbm[Z_AXIS] >= 0, "HOMING_BUMP_MM.Z must be greater than or equal to 0.");
|
|
|
|
|
|
|
|
|
|
#if ENABLED(CODEPENDENT_XY_HOMING)
|
|
|
|
|
#if ENABLED(QUICK_HOME)
|
|
|
|
@ -1424,6 +1508,28 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* System Power Sensor
|
|
|
|
|
*/
|
|
|
|
|
#if ENABLED(POWER_MONITOR_CURRENT) && !PIN_EXISTS(POWER_MONITOR_CURRENT)
|
|
|
|
|
#error "POWER_MONITOR_CURRENT requires a valid POWER_MONITOR_CURRENT_PIN."
|
|
|
|
|
#elif ENABLED(POWER_MONITOR_VOLTAGE) && !PIN_EXISTS(POWER_MONITOR_VOLTAGE)
|
|
|
|
|
#error "POWER_MONITOR_VOLTAGE requires POWER_MONITOR_VOLTAGE_PIN to be defined."
|
|
|
|
|
#elif BOTH(POWER_MONITOR_CURRENT, POWER_MONITOR_VOLTAGE) && POWER_MONITOR_CURRENT_PIN == POWER_MONITOR_VOLTAGE_PIN
|
|
|
|
|
#error "POWER_MONITOR_CURRENT_PIN and POWER_MONITOR_VOLTAGE_PIN must be different."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Volumetric Extruder Limit
|
|
|
|
|
*/
|
|
|
|
|
#if ENABLED(VOLUMETRIC_EXTRUDER_LIMIT)
|
|
|
|
|
#if ENABLED(NO_VOLUMETRICS)
|
|
|
|
|
#error "VOLUMETRIC_EXTRUDER_LIMIT requires NO_VOLUMETRICS to be disabled."
|
|
|
|
|
#elif MIN_STEPS_PER_SEGMENT > 1
|
|
|
|
|
#error "VOLUMETRIC_EXTRUDER_LIMIT is not compatible with MIN_STEPS_PER_SEGMENT greater than 1."
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* ULTIPANEL encoder
|
|
|
|
|
*/
|
|
|
|
@ -1451,7 +1557,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
* Deploying the Allen Key probe uses big moves in z direction. Too dangerous for an unhomed z-axis.
|
|
|
|
|
*/
|
|
|
|
|
#if ENABLED(Z_PROBE_ALLEN_KEY) && (Z_HOME_DIR < 0) && ENABLED(Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN)
|
|
|
|
|
#error "You can't home to a z min endstop with a Z_PROBE_ALLEN_KEY"
|
|
|
|
|
#error "You can't home to a z min endstop with a Z_PROBE_ALLEN_KEY."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
@ -1547,28 +1653,10 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Test Heater, Temp Sensor, and Extruder Pins; Sensor Type must also be set.
|
|
|
|
|
* A Sensor ID has to be set for each heater
|
|
|
|
|
*/
|
|
|
|
|
#if !HAS_HEATER_0
|
|
|
|
|
#error "HEATER_0_PIN not defined for this board."
|
|
|
|
|
#elif !ANY_PIN(TEMP_0, MAX6675_SS)
|
|
|
|
|
#error "TEMP_0_PIN not defined for this board."
|
|
|
|
|
#elif ((defined(__AVR_ATmega644P__) || defined(__AVR_ATmega1284P__)) && !PINS_EXIST(E0_STEP, E0_DIR))
|
|
|
|
|
#error "E0_STEP_PIN or E0_DIR_PIN not defined for this board."
|
|
|
|
|
#elif ( !(defined(__AVR_ATmega644P__) || defined(__AVR_ATmega1284P__)) && (!PINS_EXIST(E0_STEP, E0_DIR) || !HAS_E0_ENABLE))
|
|
|
|
|
#error "E0_STEP_PIN, E0_DIR_PIN, or E0_ENABLE_PIN not defined for this board."
|
|
|
|
|
#elif EXTRUDERS && TEMP_SENSOR_0 == 0
|
|
|
|
|
#error "TEMP_SENSOR_0 is required with any extruders."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
// Pins are required for heaters
|
|
|
|
|
#if ENABLED(HEATER_0_USES_MAX6675) && !PIN_EXISTS(MAX6675_SS)
|
|
|
|
|
#error "MAX6675_SS_PIN (required for TEMP_SENSOR_0) not defined for this board."
|
|
|
|
|
#elif (HOTENDS > 1 || ENABLED(HEATERS_PARALLEL)) && !HAS_HEATER_1
|
|
|
|
|
#error "HEATER_1_PIN not defined for this board."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if HOTENDS > 1
|
|
|
|
|
#if HAS_MULTI_HOTEND
|
|
|
|
|
#if ENABLED(HEATER_1_USES_MAX6675) && !PIN_EXISTS(MAX6675_SS2)
|
|
|
|
|
#error "MAX6675_SS2_PIN (required for TEMP_SENSOR_1) not defined for this board."
|
|
|
|
|
#elif TEMP_SENSOR_1 == 0
|
|
|
|
@ -1690,9 +1778,13 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#error "TEMP_SENSOR_7 shouldn't be set with only 1 HOTEND."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if TEMP_SENSOR_CHAMBER && !PIN_EXISTS(TEMP_CHAMBER)
|
|
|
|
|
#error "TEMP_SENSOR_CHAMBER requires TEMP_CHAMBER_PIN. Please add it to your configuration."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if TEMP_SENSOR_PROBE
|
|
|
|
|
#if !PIN_EXISTS(TEMP_PROBE)
|
|
|
|
|
#error "TEMP_SENSOR_PROBE requires TEMP_PROBE_PIN."
|
|
|
|
|
#error "TEMP_SENSOR_PROBE requires TEMP_PROBE_PIN. Please add it to your configuration."
|
|
|
|
|
#elif !HAS_TEMP_ADC_PROBE
|
|
|
|
|
#error "TEMP_PROBE_PIN must be an ADC pin."
|
|
|
|
|
#elif !ENABLED(FIX_MOUNTED_PROBE)
|
|
|
|
@ -1704,6 +1796,30 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#error "TEMP_SENSOR_1 is required with TEMP_SENSOR_1_AS_REDUNDANT."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Test Heater, Temp Sensor, and Extruder Pins
|
|
|
|
|
*/
|
|
|
|
|
#if !HAS_HEATER_0
|
|
|
|
|
#error "HEATER_0_PIN not defined for this board."
|
|
|
|
|
#elif !ANY_PIN(TEMP_0, MAX6675_SS)
|
|
|
|
|
#error "TEMP_0_PIN not defined for this board."
|
|
|
|
|
#elif ((defined(__AVR_ATmega644P__) || defined(__AVR_ATmega1284P__)) && !PINS_EXIST(E0_STEP, E0_DIR))
|
|
|
|
|
#error "E0_STEP_PIN or E0_DIR_PIN not defined for this board."
|
|
|
|
|
#elif ( !(defined(__AVR_ATmega644P__) || defined(__AVR_ATmega1284P__)) && (!PINS_EXIST(E0_STEP, E0_DIR) || !HAS_E0_ENABLE))
|
|
|
|
|
#error "E0_STEP_PIN, E0_DIR_PIN, or E0_ENABLE_PIN not defined for this board."
|
|
|
|
|
#elif EXTRUDERS && TEMP_SENSOR_0 == 0
|
|
|
|
|
#error "TEMP_SENSOR_0 is required if there are any extruders."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
// Pins are required for heaters
|
|
|
|
|
#if ENABLED(HEATER_0_USES_MAX6675) && !PIN_EXISTS(MAX6675_SS)
|
|
|
|
|
#error "MAX6675_SS_PIN (required for TEMP_SENSOR_0) not defined for this board."
|
|
|
|
|
#elif HAS_HOTEND && !HAS_TEMP_HOTEND
|
|
|
|
|
#error "TEMP_0_PIN (required for TEMP_SENSOR_0) not defined for this board."
|
|
|
|
|
#elif EITHER(HAS_MULTI_HOTEND, HEATERS_PARALLEL) && !HAS_HEATER_1
|
|
|
|
|
#error "HEATER_1_PIN is not defined. TEMP_SENSOR_1 might not be set, or the board (not EEB / EEF?) doesn't define a pin."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Temperature status LEDs
|
|
|
|
|
*/
|
|
|
|
@ -1792,8 +1908,10 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
* Endstop Tests
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#define _PLUG_UNUSED_TEST(AXIS,PLUG) (DISABLED(USE_##PLUG##MIN_PLUG, USE_##PLUG##MAX_PLUG) && !(ENABLED(AXIS##_DUAL_ENDSTOPS) && WITHIN(AXIS##2_USE_ENDSTOP, _##PLUG##MAX_, _##PLUG##MIN_)))
|
|
|
|
|
#define _AXIS_PLUG_UNUSED_TEST(AXIS) (_PLUG_UNUSED_TEST(AXIS,X) && _PLUG_UNUSED_TEST(AXIS,Y) && _PLUG_UNUSED_TEST(AXIS,Z))
|
|
|
|
|
#define _PLUG_UNUSED_TEST(A,P) (DISABLED(USE_##P##MIN_PLUG, USE_##P##MAX_PLUG) \
|
|
|
|
|
&& !(ENABLED(A##_DUAL_ENDSTOPS) && WITHIN(A##2_USE_ENDSTOP, _##P##MAX_, _##P##MIN_)) \
|
|
|
|
|
&& !(ENABLED(A##_MULTI_ENDSTOPS) && WITHIN(A##2_USE_ENDSTOP, _##P##MAX_, _##P##MIN_)) )
|
|
|
|
|
#define _AXIS_PLUG_UNUSED_TEST(A) (_PLUG_UNUSED_TEST(A,X) && _PLUG_UNUSED_TEST(A,Y) && _PLUG_UNUSED_TEST(A,Z))
|
|
|
|
|
|
|
|
|
|
// At least 3 endstop plugs must be used
|
|
|
|
|
#if _AXIS_PLUG_UNUSED_TEST(X)
|
|
|
|
@ -1818,8 +1936,12 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#error "Enable USE_YMAX_PLUG when homing Y to MAX."
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
#if Z_HOME_DIR < 0 && DISABLED(USE_ZMIN_PLUG)
|
|
|
|
|
|
|
|
|
|
// Z homing direction and plug usage flags
|
|
|
|
|
#if Z_HOME_DIR < 0 && NONE(USE_ZMIN_PLUG, HOMING_Z_WITH_PROBE)
|
|
|
|
|
#error "Enable USE_ZMIN_PLUG when homing Z to MIN."
|
|
|
|
|
#elif Z_HOME_DIR > 0 && ENABLED(USE_PROBE_FOR_Z_HOMING)
|
|
|
|
|
#error "Z_HOME_DIR must be -1 when homing Z with the probe."
|
|
|
|
|
#elif Z_HOME_DIR > 0 && DISABLED(USE_ZMAX_PLUG)
|
|
|
|
|
#error "Enable USE_ZMAX_PLUG when homing Z to MAX."
|
|
|
|
|
#endif
|
|
|
|
@ -1984,35 +2106,64 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#endif
|
|
|
|
|
#undef _RGB_TEST
|
|
|
|
|
|
|
|
|
|
#if DISABLED(NO_COMPILE_TIME_PWM)
|
|
|
|
|
#define _TEST_PWM(P) PWM_PIN(P)
|
|
|
|
|
#else
|
|
|
|
|
#define _TEST_PWM(P) 1 // pass
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Auto Fan check for PWM pins
|
|
|
|
|
*/
|
|
|
|
|
#if HAS_AUTO_FAN && EXTRUDER_AUTO_FAN_SPEED != 255 && DISABLED(NO_COMPILE_TIME_PWM)
|
|
|
|
|
#if HAS_AUTO_FAN && EXTRUDER_AUTO_FAN_SPEED != 255
|
|
|
|
|
#define AF_ERR_SUFF "_AUTO_FAN_PIN is not a PWM pin. Set EXTRUDER_AUTO_FAN_SPEED to 255."
|
|
|
|
|
#if HAS_AUTO_FAN_0
|
|
|
|
|
static_assert(PWM_PIN(E0_AUTO_FAN_PIN), "E0" AF_ERR_SUFF);
|
|
|
|
|
static_assert(_TEST_PWM(E0_AUTO_FAN_PIN), "E0" AF_ERR_SUFF);
|
|
|
|
|
#elif HAS_AUTO_FAN_1
|
|
|
|
|
static_assert(PWM_PIN(E1_AUTO_FAN_PIN), "E1" AF_ERR_SUFF);
|
|
|
|
|
static_assert(_TEST_PWM(E1_AUTO_FAN_PIN), "E1" AF_ERR_SUFF);
|
|
|
|
|
#elif HAS_AUTO_FAN_2
|
|
|
|
|
static_assert(PWM_PIN(E2_AUTO_FAN_PIN), "E2" AF_ERR_SUFF);
|
|
|
|
|
static_assert(_TEST_PWM(E2_AUTO_FAN_PIN), "E2" AF_ERR_SUFF);
|
|
|
|
|
#elif HAS_AUTO_FAN_3
|
|
|
|
|
static_assert(PWM_PIN(E3_AUTO_FAN_PIN), "E3" AF_ERR_SUFF);
|
|
|
|
|
static_assert(_TEST_PWM(E3_AUTO_FAN_PIN), "E3" AF_ERR_SUFF);
|
|
|
|
|
#elif HAS_AUTO_FAN_4
|
|
|
|
|
static_assert(PWM_PIN(E4_AUTO_FAN_PIN), "E4" AF_ERR_SUFF);
|
|
|
|
|
static_assert(_TEST_PWM(E4_AUTO_FAN_PIN), "E4" AF_ERR_SUFF);
|
|
|
|
|
#elif HAS_AUTO_FAN_5
|
|
|
|
|
static_assert(PWM_PIN(E5_AUTO_FAN_PIN), "E5" AF_ERR_SUFF);
|
|
|
|
|
static_assert(_TEST_PWM(E5_AUTO_FAN_PIN), "E5" AF_ERR_SUFF);
|
|
|
|
|
#elif HAS_AUTO_FAN_6
|
|
|
|
|
static_assert(PWM_PIN(E6_AUTO_FAN_PIN), "E6" AF_ERR_SUFF);
|
|
|
|
|
static_assert(_TEST_PWM(E6_AUTO_FAN_PIN), "E6" AF_ERR_SUFF);
|
|
|
|
|
#elif HAS_AUTO_FAN_7
|
|
|
|
|
static_assert(PWM_PIN(E7_AUTO_FAN_PIN), "E7" AF_ERR_SUFF);
|
|
|
|
|
static_assert(_TEST_PWM(E7_AUTO_FAN_PIN), "E7" AF_ERR_SUFF);
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Make sure only one EEPROM type is enabled
|
|
|
|
|
*/
|
|
|
|
|
#if ENABLED(EEPROM_SETTINGS) && 1 < ENABLED(SDCARD_EEPROM_EMULATION) + ENABLED(FLASH_EEPROM_EMULATION) + ENABLED(SRAM_EEPROM_EMULATION)
|
|
|
|
|
#error "Please select only one of SDCARD, FLASH, or SRAM_EEPROM_EMULATION."
|
|
|
|
|
#if ENABLED(EEPROM_SETTINGS)
|
|
|
|
|
#if 1 < 0 \
|
|
|
|
|
+ ENABLED(I2C_EEPROM) \
|
|
|
|
|
+ ENABLED(SPI_EEPROM) \
|
|
|
|
|
+ ENABLED(QSPI_EEPROM) \
|
|
|
|
|
+ ENABLED(SDCARD_EEPROM_EMULATION) \
|
|
|
|
|
+ ENABLED(FLASH_EEPROM_EMULATION) \
|
|
|
|
|
+ ENABLED(SRAM_EEPROM_EMULATION) \
|
|
|
|
|
+ ENABLED(IIC_BL24CXX_EEPROM)
|
|
|
|
|
#error "Please select only one method of EEPROM Persistent Storage."
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Make sure features that need to write to the SD card are
|
|
|
|
|
* disabled unless write support is enabled.
|
|
|
|
|
*/
|
|
|
|
|
#if ENABLED(SDCARD_READONLY)
|
|
|
|
|
#if ENABLED(POWER_LOSS_RECOVERY)
|
|
|
|
|
#error "POWER_LOSS_RECOVERY is incompatible with SDCARD_READONLY."
|
|
|
|
|
#elif ENABLED(BINARY_FILE_TRANSFER)
|
|
|
|
|
#error "BINARY_FILE_TRANSFER is incompatible with SDCARD_READONLY."
|
|
|
|
|
#elif ENABLED(SDCARD_EEPROM_EMULATION)
|
|
|
|
|
#error "SDCARD_EEPROM_EMULATION is incompatible with SDCARD_READONLY."
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
@ -2024,6 +2175,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
+ (ENABLED(ULTRA_LCD) && DISABLED(IS_ULTRA_LCD)) \
|
|
|
|
|
+ (ENABLED(U8GLIB_SSD1306) && DISABLED(IS_U8GLIB_SSD1306)) \
|
|
|
|
|
+ (ENABLED(MINIPANEL) && DISABLED(MKS_MINI_12864, ENDER2_STOCKDISPLAY)) \
|
|
|
|
|
+ (ENABLED(MKS_MINI_12864) && DISABLED(MKS_LCD12864)) \
|
|
|
|
|
+ (ENABLED(EXTENSIBLE_UI) && DISABLED(IS_EXTUI)) \
|
|
|
|
|
+ (ENABLED(ULTIPANEL) && DISABLED(IS_ULTIPANEL)) \
|
|
|
|
|
+ ENABLED(RADDS_DISPLAY) \
|
|
|
|
@ -2050,7 +2202,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
+ ENABLED(CARTESIO_UI) \
|
|
|
|
|
+ ENABLED(LCD_FOR_MELZI) \
|
|
|
|
|
+ ENABLED(ULTI_CONTROLLER) \
|
|
|
|
|
+ ENABLED(MKS_MINI_12864) \
|
|
|
|
|
+ ENABLED(MKS_LCD12864) \
|
|
|
|
|
+ ENABLED(ENDER2_STOCKDISPLAY) \
|
|
|
|
|
+ ENABLED(FYSETC_MINI_12864_X_X) \
|
|
|
|
|
+ ENABLED(FYSETC_MINI_12864_1_2) \
|
|
|
|
@ -2058,6 +2210,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
+ ENABLED(FYSETC_MINI_12864_2_1) \
|
|
|
|
|
+ ENABLED(FYSETC_GENERIC_12864_1_1) \
|
|
|
|
|
+ ENABLED(CR10_STOCKDISPLAY) \
|
|
|
|
|
+ ENABLED(DWIN_CREALITY_LCD) \
|
|
|
|
|
+ ENABLED(ANET_FULL_GRAPHICS_LCD) \
|
|
|
|
|
+ ENABLED(AZSMZ_12864) \
|
|
|
|
|
+ ENABLED(SILVER_GATE_GLCD_CONTROLLER) \
|
|
|
|
@ -2067,12 +2220,15 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
+ ENABLED(MKS_12864OLED_SSD1306) \
|
|
|
|
|
+ ENABLED(U8GLIB_SH1106_EINSTART) \
|
|
|
|
|
+ ENABLED(OVERLORD_OLED) \
|
|
|
|
|
+ ENABLED(FYSETC_242_OLED_12864) \
|
|
|
|
|
+ ENABLED(DGUS_LCD_UI_ORIGIN) \
|
|
|
|
|
+ ENABLED(DGUS_LCD_UI_FYSETC) \
|
|
|
|
|
+ ENABLED(DGUS_LCD_UI_HIPRECY) \
|
|
|
|
|
+ ENABLED(MALYAN_LCD) \
|
|
|
|
|
+ ENABLED(TOUCH_UI_FTDI_EVE) \
|
|
|
|
|
+ ENABLED(FSMC_GRAPHICAL_TFT)
|
|
|
|
|
+ ENABLED(FSMC_GRAPHICAL_TFT) \
|
|
|
|
|
+ ENABLED(TFT_LVGL_UI_FSMC) \
|
|
|
|
|
+ ENABLED(TFT_LVGL_UI_SPI)
|
|
|
|
|
#error "Please select no more than one LCD controller option."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
@ -2084,6 +2240,10 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
#undef IS_EXTUI
|
|
|
|
|
#undef IS_ULTIPANEL
|
|
|
|
|
|
|
|
|
|
#if 1 < ENABLED(LCD_SCREEN_ROT_0) + ENABLED(LCD_SCREEN_ROT_90) + ENABLED(LCD_SCREEN_ROT_180) + ENABLED(LCD_SCREEN_ROT_270)
|
|
|
|
|
#error "Please enable only one LCD_SCREEN_ROT_* option: 0, 90, 180, or 270."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* FYSETC Mini 12864 RGB backlighting required
|
|
|
|
|
*/
|
|
|
|
@ -2414,10 +2574,12 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
|
|
|
|
/**
|
|
|
|
|
* Digipot requirement
|
|
|
|
|
*/
|
|
|
|
|
#if ENABLED(DIGIPOT_MCP4018)
|
|
|
|
|
#if !defined(DIGIPOTS_I2C_SDA_X) || !defined(DIGIPOTS_I2C_SDA_Y) || !defined(DIGIPOTS_I2C_SDA_Z) \
|
|
|
|
|
|| !defined(DIGIPOTS_I2C_SDA_E0) || !defined(DIGIPOTS_I2C_SDA_E1)
|
|
|
|
|
#error "DIGIPOT_MCP4018 requires DIGIPOTS_I2C_SDA_* pins to be defined."
|
|
|
|
|
#if HAS_I2C_DIGIPOT
|
|
|
|
|
#if BOTH(DIGIPOT_MCP4018, DIGIPOT_MCP4451)
|
|
|
|
|
#error "Enable only one of DIGIPOT_MCP4018 or DIGIPOT_MCP4451."
|
|
|
|
|
#elif !MB(MKS_SBASE) \
|
|
|
|
|
&& (!defined(DIGIPOTS_I2C_SDA_X) || !defined(DIGIPOTS_I2C_SDA_Y) || !defined(DIGIPOTS_I2C_SDA_Z) || !defined(DIGIPOTS_I2C_SDA_E0) || !defined(DIGIPOTS_I2C_SDA_E1))
|
|
|
|
|
#error "DIGIPOT_MCP4018/4451 requires DIGIPOTS_I2C_SDA_* pins to be defined."
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
@ -2654,9 +2816,9 @@ static_assert( _ARR_TEST(3,0) && _ARR_TEST(3,1) && _ARR_TEST(3,2)
|
|
|
|
|
|
|
|
|
|
#if ENABLED(BACKLASH_COMPENSATION)
|
|
|
|
|
#ifndef BACKLASH_DISTANCE_MM
|
|
|
|
|
#error "BACKLASH_COMPENSATION requires BACKLASH_DISTANCE_MM"
|
|
|
|
|
#error "BACKLASH_COMPENSATION requires BACKLASH_DISTANCE_MM."
|
|
|
|
|
#elif !defined(BACKLASH_CORRECTION)
|
|
|
|
|
#error "BACKLASH_COMPENSATION requires BACKLASH_CORRECTION"
|
|
|
|
|
#error "BACKLASH_COMPENSATION requires BACKLASH_CORRECTION."
|
|
|
|
|
#elif IS_CORE
|
|
|
|
|
constexpr float backlash_arr[] = BACKLASH_DISTANCE_MM;
|
|
|
|
|
static_assert(!backlash_arr[CORE_AXIS_1] && !backlash_arr[CORE_AXIS_2],
|
|
|
|
@ -2689,10 +2851,14 @@ static_assert( _ARR_TEST(3,0) && _ARR_TEST(3,1) && _ARR_TEST(3,2)
|
|
|
|
|
* Prusa MMU2 requirements
|
|
|
|
|
*/
|
|
|
|
|
#if ENABLED(PRUSA_MMU2)
|
|
|
|
|
#if DISABLED(NOZZLE_PARK_FEATURE)
|
|
|
|
|
#error "PRUSA_MMU2 requires NOZZLE_PARK_FEATURE."
|
|
|
|
|
#elif EXTRUDERS != 5
|
|
|
|
|
#if EXTRUDERS != 5
|
|
|
|
|
#error "PRUSA_MMU2 requires EXTRUDERS = 5."
|
|
|
|
|
#elif DISABLED(NOZZLE_PARK_FEATURE)
|
|
|
|
|
#error "PRUSA_MMU2 requires NOZZLE_PARK_FEATURE. Enable it to continue."
|
|
|
|
|
#elif EITHER(PRUSA_MMU2_S_MODE, MMU_EXTRUDER_SENSOR) && DISABLED(FILAMENT_RUNOUT_SENSOR)
|
|
|
|
|
#error "PRUSA_MMU2_S_MODE or MMU_EXTRUDER_SENSOR requires FILAMENT_RUNOUT_SENSOR. Enable it to continue."
|
|
|
|
|
#elif BOTH(PRUSA_MMU2_S_MODE, MMU_EXTRUDER_SENSOR)
|
|
|
|
|
#error "Enable only one of PRUSA_MMU2_S_MODE or MMU_EXTRUDER_SENSOR."
|
|
|
|
|
#elif DISABLED(ADVANCED_PAUSE_FEATURE)
|
|
|
|
|
static_assert(nullptr == strstr(MMU2_FILAMENT_RUNOUT_SCRIPT, "M600"), "ADVANCED_PAUSE_FEATURE is required to use M600 with PRUSA_MMU2.");
|
|
|
|
|
#endif
|
|
|
|
@ -2736,6 +2902,45 @@ static_assert( _ARR_TEST(3,0) && _ARR_TEST(3,1) && _ARR_TEST(3,2)
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if HAS_CUTTER
|
|
|
|
|
#ifndef CUTTER_POWER_UNIT
|
|
|
|
|
#error "CUTTER_POWER_UNIT is required with a spindle or laser. Please update your Configuration_adv.h."
|
|
|
|
|
#elif !CUTTER_UNIT_IS(PWM255) && !CUTTER_UNIT_IS(PERCENT) && !CUTTER_UNIT_IS(RPM)
|
|
|
|
|
#error "CUTTER_POWER_UNIT must be PWM255, PERCENT, or RPM. Please update your Configuration_adv.h."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if ENABLED(LASER_POWER_INLINE)
|
|
|
|
|
#if ENABLED(SPINDLE_CHANGE_DIR)
|
|
|
|
|
#error "SPINDLE_CHANGE_DIR and LASER_POWER_INLINE are incompatible."
|
|
|
|
|
#elif ENABLED(LASER_MOVE_G0_OFF) && DISABLED(LASER_MOVE_POWER)
|
|
|
|
|
#error "LASER_MOVE_G0_OFF requires LASER_MOVE_POWER. Please update your Configuration_adv.h."
|
|
|
|
|
#endif
|
|
|
|
|
#if ENABLED(LASER_POWER_INLINE_TRAPEZOID)
|
|
|
|
|
#if DISABLED(SPINDLE_LASER_PWM)
|
|
|
|
|
#error "LASER_POWER_INLINE_TRAPEZOID requires SPINDLE_LASER_PWM to function."
|
|
|
|
|
#elif ENABLED(S_CURVE_ACCELERATION)
|
|
|
|
|
//#ifndef LASER_POWER_INLINE_S_CURVE_ACCELERATION_WARN
|
|
|
|
|
// #define LASER_POWER_INLINE_S_CURVE_ACCELERATION_WARN
|
|
|
|
|
// #warning "Combining LASER_POWER_INLINE_TRAPEZOID with S_CURVE_ACCELERATION may result in unintended behavior."
|
|
|
|
|
//#endif
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
#if ENABLED(LASER_POWER_INLINE_INVERT)
|
|
|
|
|
//#ifndef LASER_POWER_INLINE_INVERT_WARN
|
|
|
|
|
// #define LASER_POWER_INLINE_INVERT_WARN
|
|
|
|
|
// #warning "Enabling LASER_POWER_INLINE_INVERT means that `M5` won't kill the laser immediately; use `M5 I` instead."
|
|
|
|
|
//#endif
|
|
|
|
|
#endif
|
|
|
|
|
#else
|
|
|
|
|
#if SPINDLE_LASER_POWERUP_DELAY < 1
|
|
|
|
|
#error "SPINDLE_LASER_POWERUP_DELAY must be greater than 0."
|
|
|
|
|
#elif SPINDLE_LASER_POWERDOWN_DELAY < 1
|
|
|
|
|
#error "SPINDLE_LASER_POWERDOWN_DELAY must be greater than 0."
|
|
|
|
|
#elif ENABLED(LASER_MOVE_POWER)
|
|
|
|
|
#error "LASER_MOVE_POWER requires LASER_POWER_INLINE."
|
|
|
|
|
#elif ANY(LASER_POWER_INLINE_TRAPEZOID, LASER_POWER_INLINE_INVERT, LASER_MOVE_G0_OFF, LASER_MOVE_POWER)
|
|
|
|
|
#error "Enabled an inline laser feature without inline laser power being enabled."
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
#define _PIN_CONFLICT(P) (PIN_EXISTS(P) && P##_PIN == SPINDLE_LASER_PWM_PIN)
|
|
|
|
|
#if BOTH(SPINDLE_FEATURE, LASER_FEATURE)
|
|
|
|
|
#error "Enable only one of SPINDLE_FEATURE or LASER_FEATURE."
|
|
|
|
@ -2746,15 +2951,11 @@ static_assert( _ARR_TEST(3,0) && _ARR_TEST(3,1) && _ARR_TEST(3,2)
|
|
|
|
|
#elif ENABLED(SPINDLE_LASER_PWM)
|
|
|
|
|
#if !defined(SPINDLE_LASER_PWM_PIN) || SPINDLE_LASER_PWM_PIN < 0
|
|
|
|
|
#error "SPINDLE_LASER_PWM_PIN is required for SPINDLE_LASER_PWM."
|
|
|
|
|
#elif !PWM_PIN(SPINDLE_LASER_PWM_PIN)
|
|
|
|
|
#elif !_TEST_PWM(SPINDLE_LASER_PWM_PIN)
|
|
|
|
|
#error "SPINDLE_LASER_PWM_PIN not assigned to a PWM pin."
|
|
|
|
|
#elif SPINDLE_LASER_POWERUP_DELAY < 1
|
|
|
|
|
#error "SPINDLE_LASER_POWERUP_DELAY must be greater than 0."
|
|
|
|
|
#elif SPINDLE_LASER_POWERDOWN_DELAY < 1
|
|
|
|
|
#error "SPINDLE_LASER_POWERDOWN_DELAY must be greater than 0."
|
|
|
|
|
#elif !defined(SPINDLE_LASER_PWM_INVERT)
|
|
|
|
|
#error "SPINDLE_LASER_PWM_INVERT is required for (SPINDLE|LASER)_FEATURE."
|
|
|
|
|
#elif !defined(SPEED_POWER_SLOPE) || !defined(SPEED_POWER_INTERCEPT) || !defined(SPEED_POWER_MIN) || !defined(SPEED_POWER_MAX)
|
|
|
|
|
#elif !(defined(SPEED_POWER_INTERCEPT) && defined(SPEED_POWER_MIN) && defined(SPEED_POWER_MAX) && defined(SPEED_POWER_STARTUP))
|
|
|
|
|
#error "SPINDLE_LASER_PWM equation constant(s) missing."
|
|
|
|
|
#elif _PIN_CONFLICT(X_MIN)
|
|
|
|
|
#error "SPINDLE_LASER_PWM pin conflicts with X_MIN_PIN."
|
|
|
|
@ -2817,8 +3018,8 @@ static_assert( _ARR_TEST(3,0) && _ARR_TEST(3,1) && _ARR_TEST(3,2)
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
#if HAS_ADC_BUTTONS && defined(ADC_BUTTON_DEBOUNCE_DELAY) && !WITHIN(ADC_BUTTON_DEBOUNCE_DELAY, 16, 255)
|
|
|
|
|
#error "ADC_BUTTON_DEBOUNCE_DELAY must be an integer from 16 to 255."
|
|
|
|
|
#if HAS_ADC_BUTTONS && defined(ADC_BUTTON_DEBOUNCE_DELAY) && ADC_BUTTON_DEBOUNCE_DELAY < 16
|
|
|
|
|
#error "ADC_BUTTON_DEBOUNCE_DELAY must be greater than 16."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
@ -2833,3 +3034,22 @@ static_assert( _ARR_TEST(3,0) && _ARR_TEST(3,1) && _ARR_TEST(3,2)
|
|
|
|
|
#if SAVED_POSITIONS > 256
|
|
|
|
|
#error "SAVED_POSITIONS must be an integer from 0 to 256."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Sanity checks for stepper chunk support
|
|
|
|
|
*/
|
|
|
|
|
#if ENABLED(DIRECT_STEPPING)
|
|
|
|
|
#if ENABLED(LIN_ADVANCE)
|
|
|
|
|
#error "DIRECT_STEPPING is incompatible with LIN_ADVANCE. Enable in external planner if possible."
|
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Sanity check for WIFI
|
|
|
|
|
*/
|
|
|
|
|
#if ENABLED(ESP3D_WIFISUPPORT) && DISABLED(ARDUINO_ARCH_ESP32)
|
|
|
|
|
#error "ESP3D_WIFISUPPORT requires an ESP32 controller. Use WIFISUPPORT for standalone ESP3D modules."
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
// Misc. Cleanup
|
|
|
|
|
#undef _TEST_PWM
|
|
|
|
|