From 5aad55b0f241f478ad3cfe8fa9a1bad91f3da815 Mon Sep 17 00:00:00 2001 From: kisslorand Date: Sun, 20 Aug 2023 23:00:18 +0300 Subject: [PATCH] Corner Leveling Marlin Fix --- README.md | 2 +- TFT/src/User/API/LevelingControl.c | 4 +- TFT/src/User/API/Settings.c | 9 +- TFT/src/User/API/Settings.h | 9 +- TFT/src/User/API/config.c | 20 ++-- TFT/src/User/API/config.h | 5 +- TFT/src/User/API/config.inc | 5 +- TFT/src/User/API/parseACK.c | 48 +++++---- TFT/src/User/Configuration.h | 12 +-- TFT/src/User/Menu/LevelCorner.c | 151 ++++++++++------------------- TFT/src/User/config.ini | 23 +++-- 11 files changed, 136 insertions(+), 152 deletions(-) diff --git a/README.md b/README.md index 6a214abb2b..b7598a5952 100644 --- a/README.md +++ b/README.md @@ -120,7 +120,7 @@ the following options must be enabled in Marlin firmware. `AUTO_REPORT_TEMPERATURES` (in Configuration_adv.h)
`AUTO_REPORT_POSITION` (in Configuration_adv.h)
`EXTENDED_CAPABILITIES_REPORT` (in Configuration_adv.h)
-`M115_GEOMETRY_REPORT` (in Configuration_adv.h)
+`MIN/MAX_SOFTWARE_ENDSTOPS` (in Configuration.h)
`M114_DETAIL` (in Configuration_adv.h)
`REPORT_FAN_CHANGE` (in Configuration_adv.h)
diff --git a/TFT/src/User/API/LevelingControl.c b/TFT/src/User/API/LevelingControl.c index 21cd6ce8ff..dae467469b 100644 --- a/TFT/src/User/API/LevelingControl.c +++ b/TFT/src/User/API/LevelingControl.c @@ -12,8 +12,8 @@ float probedZ = 0.0f; // last Z offset measured by probe int16_t setCoordValue(AXIS axis, ALIGN_POSITION align) { - return ((align == LEFT || align == BOTTOM) ? infoSettings.machine_size_min[axis] + infoSettings.level_edge - : infoSettings.machine_size_max[axis] - infoSettings.level_edge) - infoParameters.HomeOffset[axis]; + return ((align == LEFT || align == BOTTOM) ? infoSettings.level_edge + : infoSettings.bed_size[axis] - infoSettings.level_edge); } void levelingGetPointCoords(LEVELING_POINT_COORDS coords) diff --git a/TFT/src/User/API/Settings.c b/TFT/src/User/API/Settings.c index ac2a480535..ac0f21d32c 100644 --- a/TFT/src/User/API/Settings.c +++ b/TFT/src/User/API/Settings.c @@ -157,8 +157,13 @@ void initSettings(void) for (int i = 0; i < AXIS_NUM; i++) // x, y, z { - infoSettings.machine_size_min[i] = default_size_min[i]; - infoSettings.machine_size_max[i] = default_size_max[i]; + infoSettings.endstop_min[i] = default_size_min[i]; + infoSettings.endstop_max[i] = default_size_max[i]; + } + + for (int i = 0; i < AXIS_NUM - 1; i++) // x, y + { + infoSettings.bed_size[i] = default_size_max[i]; } for (int i = 0; i < SPEED_COUNT; i++) diff --git a/TFT/src/User/API/Settings.h b/TFT/src/User/API/Settings.h index 499116f564..f27f837ec1 100644 --- a/TFT/src/User/API/Settings.h +++ b/TFT/src/User/API/Settings.h @@ -14,10 +14,10 @@ extern "C" { // Config version support (format YYYYMMDD) // change if new elements/keywords are added/removed/changed in the Configuration.h // this number should match CONFIG_VERSION in Configuration.h -#define CONFIG_SUPPPORT 20230821 +#define CONFIG_SUPPPORT 20231001 #define FONT_FLASH_SIGN 20230821 // (YYYYMMDD) change if fonts require updating -#define CONFIG_FLASH_SIGN 20230821 // (YYYYMMDD) change if any keyword(s) in config.ini is added or removed +#define CONFIG_FLASH_SIGN 20231001 // (YYYYMMDD) change if any keyword(s) in config.ini is added or removed #define LANGUAGE_FLASH_SIGN 20230821 // (YYYYMMDD) change if any keyword(s) in language pack is added or removed #define ICON_FLASH_SIGN 20230821 // (YYYYMMDD) change if any icon(s) is added or removed @@ -222,8 +222,9 @@ typedef struct uint16_t max_temp[MAX_HEATER_COUNT]; // hotends + bed + chamber uint16_t min_ext_temp; uint8_t fan_max[MAX_FAN_COUNT]; - int16_t machine_size_min[AXIS_NUM]; // X, Y, Z - int16_t machine_size_max[AXIS_NUM]; // X, Y, Z + int16_t endstop_min[AXIS_NUM]; // X, Y, Z + int16_t endstop_max[AXIS_NUM]; // X, Y, Z + uint16_t bed_size[AXIS_NUM - 1]; // X, Y uint16_t xy_speed[SPEED_COUNT]; uint16_t z_speed[SPEED_COUNT]; uint16_t ext_speed[SPEED_COUNT]; diff --git a/TFT/src/User/API/config.c b/TFT/src/User/API/config.c index b5d05a67b1..9635a303d2 100644 --- a/TFT/src/User/API/config.c +++ b/TFT/src/User/API/config.c @@ -774,18 +774,22 @@ void parseConfigKey(uint16_t index) if (key_seen("CtI:")) SET_VALID_INT_VALUE(infoSettings.fan_max[7], MIN_FAN_SPEED, MAX_FAN_SPEED); break; - case C_INDEX_SIZE_MIN: - if (key_seen("X")) SET_VALID_INT_VALUE(infoSettings.machine_size_min[X_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); - if (key_seen("Y")) SET_VALID_INT_VALUE(infoSettings.machine_size_min[Y_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); - if (key_seen("Z")) SET_VALID_INT_VALUE(infoSettings.machine_size_min[Z_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); + case C_INDEX_ENDSTOP_MIN: + if (key_seen("X")) SET_VALID_INT_VALUE(infoSettings.endstop_min[X_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); + if (key_seen("Y")) SET_VALID_INT_VALUE(infoSettings.endstop_min[Y_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); + if (key_seen("Z")) SET_VALID_INT_VALUE(infoSettings.endstop_min[Z_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); break; - case C_INDEX_SIZE_MAX: - if (key_seen("X")) SET_VALID_INT_VALUE(infoSettings.machine_size_max[X_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); - if (key_seen("Y")) SET_VALID_INT_VALUE(infoSettings.machine_size_max[Y_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); - if (key_seen("Z")) SET_VALID_INT_VALUE(infoSettings.machine_size_max[Z_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); + case C_INDEX_ENDSTOP_MAX: + if (key_seen("X")) SET_VALID_INT_VALUE(infoSettings.endstop_max[X_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); + if (key_seen("Y")) SET_VALID_INT_VALUE(infoSettings.endstop_max[Y_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); + if (key_seen("Z")) SET_VALID_INT_VALUE(infoSettings.endstop_max[Z_AXIS], MIN_SIZE_LIMIT, MAX_SIZE_LIMIT); break; + case C_INDEX_BED_SIZE: + if (key_seen("X")) SET_VALID_INT_VALUE(infoSettings.bed_size[X_AXIS], 0, MAX_SIZE_LIMIT); + if (key_seen("Y")) SET_VALID_INT_VALUE(infoSettings.bed_size[Y_AXIS], 0, MAX_SIZE_LIMIT); + case C_INDEX_XY_SPEED: if (key_seen("S")) SET_VALID_INT_VALUE(infoSettings.xy_speed[0], MIN_SPEED_LIMIT, MAX_SPEED_LIMIT); if (key_seen("N")) SET_VALID_INT_VALUE(infoSettings.xy_speed[1], MIN_SPEED_LIMIT, MAX_SPEED_LIMIT); diff --git a/TFT/src/User/API/config.h b/TFT/src/User/API/config.h index 2e1eddeedb..14c3fde638 100644 --- a/TFT/src/User/API/config.h +++ b/TFT/src/User/API/config.h @@ -69,8 +69,9 @@ extern "C" { #define CONFIG_MAX_TEMP "max_temp:" #define CONFIG_MIN_TEMP "min_temp:" #define CONFIG_FAN_MAX "fan_max:" -#define CONFIG_SIZE_MIN "size_min:" -#define CONFIG_SIZE_MAX "size_max:" +#define CONFIG_ENDSTOP_MIN "pos_min:" +#define CONFIG_ENDSTOP_MAX "pos_max:" +#define CONFIG_BED_SIZE "bed_size:" #define CONFIG_XY_SPEED "xy_speed:" #define CONFIG_Z_SPEED "z_speed:" #define CONFIG_EXT_SPEED "ext_speed:" diff --git a/TFT/src/User/API/config.inc b/TFT/src/User/API/config.inc index 35b9f35f65..67fd545f9a 100644 --- a/TFT/src/User/API/config.inc +++ b/TFT/src/User/API/config.inc @@ -62,8 +62,9 @@ X_CONFIG (CONTROLLER_FAN) X_CONFIG (MAX_TEMP) X_CONFIG (MIN_TEMP) X_CONFIG (FAN_MAX) -X_CONFIG (SIZE_MIN) -X_CONFIG (SIZE_MAX) +X_CONFIG (ENDSTOP_MIN) +X_CONFIG (ENDSTOP_MAX) +X_CONFIG (BED_SIZE) X_CONFIG (XY_SPEED) X_CONFIG (Z_SPEED) X_CONFIG (EXT_SPEED) diff --git a/TFT/src/User/API/parseACK.c b/TFT/src/User/API/parseACK.c index 40e3329f32..674374a029 100644 --- a/TFT/src/User/API/parseACK.c +++ b/TFT/src/User/API/parseACK.c @@ -784,22 +784,23 @@ void parseACK(void) // Tuning parsed responses //---------------------------------------- - // parse and store build volume size - else if (ack_seen("work:")) + // parse and store soft endstops (M211) + else if (GET_BIT(infoMachineSettings.softwareEndstops, 1)) { - if (ack_continue_seen("min:")) + if (ack_seen("Min:")) { - if (ack_continue_seen("x:")) infoSettings.machine_size_min[X_AXIS] = ack_value(); - if (ack_continue_seen("y:")) infoSettings.machine_size_min[Y_AXIS] = ack_value(); - if (ack_continue_seen("z:")) infoSettings.machine_size_min[Z_AXIS] = ack_value(); - } + // check endstop minimum values + if (ack_continue_seen("X")) infoSettings.endstop_min[X_AXIS] = ack_value(); + if (ack_continue_seen("Y")) infoSettings.endstop_min[Y_AXIS] = ack_value(); + if (ack_continue_seen("Z")) infoSettings.endstop_min[Z_AXIS] = ack_value(); - if (ack_continue_seen("max:")) - { - if (ack_continue_seen("x:")) infoSettings.machine_size_max[X_AXIS] = ack_value(); - if (ack_continue_seen("y:")) infoSettings.machine_size_max[Y_AXIS] = ack_value(); - if (ack_continue_seen("z:")) infoSettings.machine_size_max[Z_AXIS] = ack_value(); + // check endstop maximum values + if (ack_continue_seen("X")) infoSettings.endstop_max[X_AXIS] = ack_value(); + if (ack_continue_seen("Y")) infoSettings.endstop_max[Y_AXIS] = ack_value(); + if (ack_continue_seen("Z")) infoSettings.endstop_max[Z_AXIS] = ack_value(); } + + SET_BIT_OFF(infoMachineSettings.softwareEndstops, 1); // clear "M211 seen" flag } // parse M48, repeatability test else if (ack_starts_with("Mean:")) @@ -835,10 +836,12 @@ void parseACK(void) else if (ack_starts_with("M211") || ack_seen("Soft endstops")) { uint8_t curValue = infoMachineSettings.softwareEndstops; - infoMachineSettings.softwareEndstops = ack_continue_seen("ON"); + SET_BIT_VALUE(infoMachineSettings.softwareEndstops, 0, ack_continue_seen("ON")); // set ON/Off bit if (curValue != infoMachineSettings.softwareEndstops) // send a notification only if status is changed addToast(DIALOG_TYPE_INFO, ack_cache); + + SET_BIT_ON(infoMachineSettings.softwareEndstops, 1); // set "M211 seen" flag } // parse M303, PID autotune finished message else if (ack_starts_with("PID Autotune finished")) @@ -916,16 +919,23 @@ void parseACK(void) mblUpdateStatus(true); } // parse G30, feedback to get the 4 corners Z value returned by Marlin for LevelCorner menu - else if (ack_seen("Bed X: ")) + else if (ack_seen("Bed X:")) { float x = ack_value(); - float y = 0; - if (ack_continue_seen("Y: ")) - y = ack_value(); + if (ack_continue_seen("Y:")) + { + float y = ack_value(); - if (ack_continue_seen("Z: ")) - levelingSetProbedPoint(x, y, ack_value()); // save probed Z value + if (ack_continue_seen("Z:")) + levelingSetProbedPoint(x, y, ack_value()); // save probed Z value + } + } + // parse G30 coordinate unreachable message + else if (ack_seen("Z Probe Past Bed")) + { + levelingSetProbedPoint(-1, -1, 0); // cancel waiting for coordinates + BUZZER_PLAY(SOUND_ERROR); } #if DELTA_PROBE_TYPE != 0 // parse and store Delta calibration settings diff --git a/TFT/src/User/Configuration.h b/TFT/src/User/Configuration.h index 679fd4772e..6773dd4121 100644 --- a/TFT/src/User/Configuration.h +++ b/TFT/src/User/Configuration.h @@ -1,7 +1,7 @@ #ifndef _CONFIGURATION_H_ #define _CONFIGURATION_H_ -#define CONFIG_VERSION 20230821 +#define CONFIG_VERSION 20231001 //==================================================================================================== //=============================== Settings Configurable On config.ini ================================ @@ -491,11 +491,11 @@ #define FAN_MAX {255, 255, 255, 255, 255, 255, 255, 255} // Default: {255, 255, 255, 255, 255, 255, 255, 255} /** - * Machine Size / Build Area - * The TFT will auto-detect the machine size (min and max) in Marlin firmware (requires - * enabling "M115_GEOMETRY_REPORT" in Configuration_adv.h in Marlin firmware). - * Format: [size_min: X Y Z] - * [size_max: X Y Z] + * Motion limits + * This sets the minimum and maximum motion limits. The TFT can autodect it from an M211 respone. + * For this "MIN/MAX_SOFTWARE_ENDSTOPS" must be enabled in Marlin's "Configuration.h". + * Format: [pos_min: X Y Z] + * [pos_max: X Y Z] * Unit: [distance in mm] * Value range: [min: -2000, max: 2000] */ diff --git a/TFT/src/User/Menu/LevelCorner.c b/TFT/src/User/Menu/LevelCorner.c index df71ffa665..3acfdafd8b 100644 --- a/TFT/src/User/Menu/LevelCorner.c +++ b/TFT/src/User/Menu/LevelCorner.c @@ -1,91 +1,58 @@ #include "LevelCorner.h" #include "includes.h" -const uint8_t valIconIndex[LEVELING_POINT_COUNT] = {4, 5, 1, 0, 3}; +const uint8_t valIconIndex[LEVELING_POINT_COUNT] = {KEY_ICON_4, KEY_ICON_5, KEY_ICON_1, KEY_ICON_0, KEY_ICON_3}; // buffer current Z value measured in Level Corner = {position 1, position 2, position 3, position 4, probe accuracy(M48)} float levelCornerPosition[LEVELING_POINT_COUNT] = {0}; int16_t origLevelEdge = -1; -uint8_t getLevelEdgeMin(void) +static uint8_t getLevelEdgeMin(void) { - // min edge limit for the probe with probe offset set in parseACK.c - int16_t maxXedge = getParameter(P_PROBE_OFFSET, AXIS_INDEX_X) + getParameter(P_HOME_OFFSET, AXIS_INDEX_X); - int16_t maxYedge = getParameter(P_PROBE_OFFSET, AXIS_INDEX_Y) + getParameter(P_HOME_OFFSET, AXIS_INDEX_Y); + uint16_t edge = 0; + int16_t val; + int16_t probeOffset; + int16_t homeOffset; - maxXedge = ABS(maxXedge); - maxYedge = ABS(maxYedge); + probeOffset = getParameter(P_PROBE_OFFSET, X_AXIS); + homeOffset = getParameter(P_HOME_OFFSET, X_AXIS); - return MAX(maxXedge, maxYedge) + 1; + val = infoSettings.endstop_min[X_AXIS] + probeOffset + homeOffset; + if (val > edge) edge = val; + + val = infoSettings.bed_size[X_AXIS] - infoSettings.endstop_max[X_AXIS] - probeOffset - homeOffset; + if (val > edge) edge = val; + + probeOffset = getParameter(P_PROBE_OFFSET, Y_AXIS); + homeOffset = getParameter(P_HOME_OFFSET, Y_AXIS); + + val = infoSettings.endstop_min[Y_AXIS] + probeOffset + homeOffset; + if (val > edge) edge = val; + + val = infoSettings.bed_size[Y_AXIS] - infoSettings.endstop_max[Y_AXIS] - probeOffset - homeOffset; + if (val > edge) edge = val; + + return edge + 1; } -uint8_t getLevelEdgeDefault(void) +static uint8_t getLevelEdgeDefault(void) { return MAX(origLevelEdge, getLevelEdgeMin()); } -void setLevelEdgeMin(void) +static void setLevelEdgeMin(void) { infoSettings.level_edge = getLevelEdgeMin(); } // draw values under icons -void refreshValue(MENUITEMS * levelItems, uint8_t index) +static void refreshValue(MENUITEMS * levelItems, uint8_t index) { - sprintf((char *)levelItems->items[valIconIndex[index]].label.address, "%.4f", levelCornerPosition[index]); + sprintf((char *)levelItems->items[valIconIndex[index]].label.address, "%.3f", levelCornerPosition[index]); menuDrawIconText(&levelItems->items[valIconIndex[index]], valIconIndex[index]); } -void checkRefreshValue(MENUITEMS * levelItems) -{ - LEVELING_POINT levelingPoint = levelingGetProbedPoint(); - - if (levelingPoint != LEVEL_NO_POINT) - { - levelCornerPosition[levelingPoint] = levelingGetProbedZ(); - refreshValue(levelItems, levelingPoint); - - levelingResetProbedPoint(); // reset to check for new updates - } -} - -// show M48 on icon -void drawProbeAccuracyIcon(MENUITEMS * levelItems) -{ - uint8_t index = 4; - GUI_POINT loc; - LIVE_INFO lvIcon; - char * str = "M48"; - - loc.x = 5; - loc.y = ICON_HEIGHT - 5; - - lvIcon.iconIndex = levelItems->items[valIconIndex[index]].icon; - lvIcon.enabled[0] = true; - lvIcon.enabled[1] = true; - lvIcon.enabled[2] = false; - - lvIcon.lines[0].h_align = LEFT; - lvIcon.lines[0].v_align = BOTTOM; - lvIcon.lines[0].fn_color = LC_VAL_COLOR; - lvIcon.lines[0].text_mode = GUI_TEXTMODE_TRANS; - lvIcon.lines[0].pos = loc; - lvIcon.lines[0].font = FONT_SIZE_NORMAL; - - lvIcon.lines[1].h_align = LEFT; - lvIcon.lines[1].v_align = BOTTOM; - lvIcon.lines[1].fn_color = LC_VAL_COLOR_2; - lvIcon.lines[1].text_mode = GUI_TEXTMODE_TRANS; - lvIcon.lines[1].pos = (GUI_POINT){loc.x - 2, loc.y - 2}; - lvIcon.lines[1].font = FONT_SIZE_NORMAL; - - lvIcon.lines[0].text = (uint8_t *)str; - lvIcon.lines[1].text = (uint8_t *)str; - - showLiveInfo(valIconIndex[index], &lvIcon, false); -} - void menuLevelCorner(void) { MENUITEMS levelCornerItems = { @@ -93,19 +60,19 @@ void menuLevelCorner(void) LABEL_LEVEL_CORNER, // icon label { - {ICON_POINT_4, LABEL_DYNAMIC}, - {ICON_POINT_3, LABEL_DYNAMIC}, + {ICON_POINT_4, LABEL_NULL}, + {ICON_POINT_3, LABEL_NULL}, {ICON_LEVEL_EDGE_DISTANCE, LABEL_DISTANCE}, - {ICON_BLTOUCH, LABEL_DYNAMIC}, - {ICON_POINT_1, LABEL_DYNAMIC}, - {ICON_POINT_2, LABEL_DYNAMIC}, + {ICON_BLTOUCH, LABEL_NULL}, + {ICON_POINT_1, LABEL_NULL}, + {ICON_POINT_2, LABEL_NULL}, {ICON_RESUME, LABEL_START}, {ICON_BACK, LABEL_BACK}, } }; KEY_VALUES key_num = KEY_IDLE; - char iconText[LEVELING_POINT_COUNT][15]; + char iconText[LEVELING_POINT_COUNT][5] = {"---", "---", "---", "---", "M48"}; if (origLevelEdge < 0) // initialize leveling edge value to be used for leveling corner if not yet initialized (-1) { @@ -113,15 +80,12 @@ void menuLevelCorner(void) infoSettings.level_edge = getLevelEdgeDefault(); // set leveling edge value for leveling corner } - for (uint8_t i = 0; i < LEVELING_POINT_COUNT; i++) + for (uint8_t i = LEVEL_BOTTOM_LEFT; i < LEVELING_POINT_COUNT; i++) { levelCornerItems.items[valIconIndex[i]].label.address = (uint8_t *)iconText[i]; - - refreshValue(&levelCornerItems, i); } menuDrawPage(&levelCornerItems); - drawProbeAccuracyIcon(&levelCornerItems); while (MENU_IS(menuLevelCorner)) { @@ -129,11 +93,25 @@ void menuLevelCorner(void) switch (key_num) { case KEY_ICON_0: - levelingProbePoint(LEVEL_TOP_LEFT); - break; - case KEY_ICON_1: - levelingProbePoint(LEVEL_TOP_RIGHT); + case KEY_ICON_4: + case KEY_ICON_5: + case KEY_ICON_6: + for (int lvlPoint = LEVEL_BOTTOM_LEFT; lvlPoint <= LEVEL_TOP_LEFT; lvlPoint++) + { + if (key_num < KEY_ICON_6 && key_num != valIconIndex[lvlPoint]) + continue; + + levelingProbePoint(lvlPoint); + + // wait until point probing is executed + TASK_LOOP_WHILE(levelingGetProbedPoint() == LEVEL_NO_POINT); + + levelCornerPosition[lvlPoint] = levelingGetProbedZ(); + refreshValue(&levelCornerItems, lvlPoint); + levelingResetProbedPoint(); // reset to check for new updates + } + break; case KEY_ICON_2: @@ -151,27 +129,6 @@ void menuLevelCorner(void) case KEY_ICON_3: mustStoreCmd("M48\n"); - - drawProbeAccuracyIcon(&levelCornerItems); - break; - - case KEY_ICON_4: - levelingProbePoint(LEVEL_BOTTOM_LEFT); - break; - - case KEY_ICON_5: - levelingProbePoint(LEVEL_BOTTOM_RIGHT); - break; - - case KEY_ICON_6: - for (int i = LEVEL_BOTTOM_LEFT; i <= LEVEL_TOP_LEFT; i++) - { - levelingProbePoint(i); - - // following loop needed to guarantee the value for each point beeing probed is updated at least one time on the menu - TASK_LOOP_WHILE(isNotEmptyCmdQueue(), checkRefreshValue(&levelCornerItems)); - } - break; case KEY_ICON_7: @@ -185,7 +142,5 @@ void menuLevelCorner(void) } loopProcess(); - - checkRefreshValue(&levelCornerItems); } } diff --git a/TFT/src/User/config.ini b/TFT/src/User/config.ini index 969a6421f2..e8e0ef1559 100644 --- a/TFT/src/User/config.ini +++ b/TFT/src/User/config.ini @@ -43,7 +43,7 @@ # AUTO_REPORT_TEMPERATURES (in Configuration_adv.h) # AUTO_REPORT_POSITION (in Configuration_adv.h) # EXTENDED_CAPABILITIES_REPORT (in Configuration_adv.h) -# M115_GEOMETRY_REPORT (in Configuration_adv.h) +# MIN/MAX_SOFTWARE_ENDSTOPS (in Configuration.h) # M114_DETAIL (in Configuration_adv.h) # REPORT_FAN_CHANGE (in Configuration_adv.h) # @@ -503,15 +503,22 @@ min_temp:180 # Value range: [min: 25, max: 255] fan_max:F0:255 F1:255 F2:255 F3:255 F4:255 F5:255 CtA:255 CtI:255 -#### Machine Size / Build Area -# The TFT will auto-detect the machine size (min and max) in Marlin firmware (requires -# enabling "M115_GEOMETRY_REPORT" in Configuration_adv.h in Marlin firmware). -# Format: [size_min: X Y Z] -# [size_max: X Y Z] +#### Motion limits +# This sets the minimum and maximum motion limits. The TFT can autodect it from an M211 respone. +# For this "MIN/MAX_SOFTWARE_ENDSTOPS" must be enabled in Marlin's "Configuration.h". +# Format: [pos_min: X Y Z] +# [pos_max: X Y Z] # Unit: [distance in mm] # Value range: [min: -2000, max: 2000] -size_min:X0 Y0 Z0 -size_max:X235 Y235 Z250 +pos_min:X0 Y0 Z0 +pos_max:X235 Y235 Z250 + +#### Bed size +# Set the bed X and Y size. +# Format: [bed_size: X Y] +# Unit: [size in mm] +# Value range: [min: 0, max: 2000] +bed_size: X235 Y235 #### X & Y Move Speeds/Feedrates # Move speeds used in Move menu to move X and Y axes.