From 6e67ad51b70ce4f02be967bb14e5557a021e48eb Mon Sep 17 00:00:00 2001 From: Andrew <18502096+classicrocker883@users.noreply.github.com> Date: Thu, 4 Jan 2024 18:07:53 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=8E=A8=20Followup=20to=20optional=20M111/?= =?UTF-8?q?M115=20(#26626)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Followup to #26603 --- Marlin/Configuration_adv.h | 84 +++++++++++++++--------------- Marlin/src/gcode/gcode.cpp | 2 +- Marlin/src/gcode/gcode.h | 4 +- Marlin/src/gcode/host/M115.cpp | 4 +- Marlin/src/inc/Warnings.cpp | 4 +- Marlin/src/lcd/e3v2/proui/dwin.cpp | 2 +- ini/features.ini | 2 +- 7 files changed, 51 insertions(+), 51 deletions(-) diff --git a/Marlin/Configuration_adv.h b/Marlin/Configuration_adv.h index 10316ac928..248841d748 100644 --- a/Marlin/Configuration_adv.h +++ b/Marlin/Configuration_adv.h @@ -3836,38 +3836,6 @@ */ //#define CNC_COORDINATE_SYSTEMS -// @section reporting - -/** - * Auto-report fan speed with M123 S - * Requires fans with tachometer pins - */ -//#define AUTO_REPORT_FANS - -/** - * Auto-report temperatures with M155 S - */ -#define AUTO_REPORT_TEMPERATURES -#if ENABLED(AUTO_REPORT_TEMPERATURES) && TEMP_SENSOR_REDUNDANT - //#define AUTO_REPORT_REDUNDANT // Include the "R" sensor in the auto-report -#endif - -/** - * Auto-report position with M154 S - */ -//#define AUTO_REPORT_POSITION -#if ENABLED(AUTO_REPORT_POSITION) - //#define AUTO_REPORT_REAL_POSITION // Auto-report the real position -#endif - -/** - * Include capabilities in M115 output - */ -#define EXTENDED_CAPABILITIES_REPORT -#if ENABLED(EXTENDED_CAPABILITIES_REPORT) - //#define M115_GEOMETRY_REPORT -#endif - // @section security /** @@ -3910,13 +3878,51 @@ // @section reporting -// Extra options for the M114 "Current Position" report +/** + * Extra options for the M114 "Current Position" report + */ //#define M114_DETAIL // Use 'M114` for details to check planner calculations //#define M114_REALTIME // Real current position based on forward kinematics //#define M114_LEGACY // M114 used to synchronize on every call. Enable if needed. + +/** + * Auto-report fan speed with M123 S + * Requires fans with tachometer pins + */ +//#define AUTO_REPORT_FANS + //#define REPORT_FAN_CHANGE // Report the new fan speed when changed by M106 (and others) +/** + * Auto-report temperatures with M155 S + */ +#define AUTO_REPORT_TEMPERATURES +#if ENABLED(AUTO_REPORT_TEMPERATURES) && TEMP_SENSOR_REDUNDANT + //#define AUTO_REPORT_REDUNDANT // Include the "R" sensor in the auto-report +#endif + +/** + * Auto-report position with M154 S + */ +//#define AUTO_REPORT_POSITION +#if ENABLED(AUTO_REPORT_POSITION) + //#define AUTO_REPORT_REAL_POSITION // Auto-report the real position +#endif + +/** + * M115 - Report capabilites. Disable to save ~1150 bytes of flash. + * Some hosts (and serial TFT displays) rely on this feature. + */ +#define CAPABILITIES_REPORT +#if ENABLED(CAPABILITIES_REPORT) + // Include capabilities in M115 output + #define EXTENDED_CAPABILITIES_REPORT + #if ENABLED(EXTENDED_CAPABILITIES_REPORT) + //#define M115_GEOMETRY_REPORT + #endif +#endif + // @section gcode /** @@ -3928,7 +3934,9 @@ //#define GCODE_QUOTED_STRINGS // Support for quoted string parameters #endif -// Support for MeatPack G-code compression (https://github.com/scottmudge/OctoPrint-MeatPack) +/** + * Support for MeatPack G-code compression (https://github.com/scottmudge/OctoPrint-MeatPack) + */ //#define MEATPACK_ON_SERIAL_PORT_1 //#define MEATPACK_ON_SERIAL_PORT_2 @@ -3942,12 +3950,6 @@ */ #define DEBUG_FLAGS_GCODE -/** - * M115 - Report capabilites. Disable to save ~1150 bytes of flash. - * Some hosts (and serial TFT displays) rely on this feature. - */ -#define REPORT_CAPABILITIES_GCODE - /** * Enable this option for a leaner build of Marlin that removes * workspace offsets to slightly optimize performance. @@ -3975,8 +3977,6 @@ //#define VARIABLE_G0_FEEDRATE // The G0 feedrate is set by F in G0 motion mode #endif -// @section gcode - /** * Startup commands * diff --git a/Marlin/src/gcode/gcode.cpp b/Marlin/src/gcode/gcode.cpp index 945da708b4..5fb0594d9f 100644 --- a/Marlin/src/gcode/gcode.cpp +++ b/Marlin/src/gcode/gcode.cpp @@ -670,7 +670,7 @@ void GcodeSuite::process_parsed_command(const bool no_ok/*=false*/) { case 92: M92(); break; // M92: Set the steps-per-unit for one or more axes case 114: M114(); break; // M114: Report current position - #if ENABLED(REPORT_CAPABILITIES_GCODE) + #if ENABLED(CAPABILITIES_REPORT) case 115: M115(); break; // M115: Report capabilities #endif diff --git a/Marlin/src/gcode/gcode.h b/Marlin/src/gcode/gcode.h index d5adf6c415..ae60ac7556 100644 --- a/Marlin/src/gcode/gcode.h +++ b/Marlin/src/gcode/gcode.h @@ -149,7 +149,7 @@ * * M113 - Get or set the timeout interval for Host Keepalive "busy" messages. (Requires HOST_KEEPALIVE_FEATURE) * M114 - Report current position. - * M115 - Report capabilities. (Extended capabilities requires EXTENDED_CAPABILITIES_REPORT) + * M115 - Report capabilities. (Requires CAPABILITIES_REPORT) * M117 - Display a message on the controller screen. (Requires an LCD) * M118 - Display a message in the host console. * @@ -761,7 +761,7 @@ private: static void M114(); - #if ENABLED(REPORT_CAPABILITIES_GCODE) + #if ENABLED(CAPABILITIES_REPORT) static void M115(); #endif diff --git a/Marlin/src/gcode/host/M115.cpp b/Marlin/src/gcode/host/M115.cpp index ae8e615507..d1571d58ac 100644 --- a/Marlin/src/gcode/host/M115.cpp +++ b/Marlin/src/gcode/host/M115.cpp @@ -22,7 +22,7 @@ #include "../../inc/MarlinConfig.h" -#if ENABLED(REPORT_CAPABILITIES_GCODE) +#if ENABLED(CAPABILITIES_REPORT) #include "../gcode.h" #include "../queue.h" // for getting the command port @@ -275,4 +275,4 @@ void GcodeSuite::M115() { #endif // EXTENDED_CAPABILITIES_REPORT } -#endif // REPORT_CAPABILITIES_GCODE +#endif // CAPABILITIES_REPORT diff --git a/Marlin/src/inc/Warnings.cpp b/Marlin/src/inc/Warnings.cpp index 384fe04c61..560acf4cd8 100644 --- a/Marlin/src/inc/Warnings.cpp +++ b/Marlin/src/inc/Warnings.cpp @@ -46,8 +46,8 @@ #warning "DEBUG_FLAGS_GCODE is recommended if you have space. Some hosts rely on it." #endif -#if DISABLED(REPORT_CAPABILITIES_GCODE) - #warning "REPORT_CAPABILITIES_GCODE is recommended if you have space. Some hosts rely on it." +#if DISABLED(CAPABILITIES_REPORT) + #warning "CAPABILITIES_REPORT is recommended if you have space. Some hosts rely on it." #endif #if ENABLED(LA_DEBUG) diff --git a/Marlin/src/lcd/e3v2/proui/dwin.cpp b/Marlin/src/lcd/e3v2/proui/dwin.cpp index 5262dba385..7520b46b60 100644 --- a/Marlin/src/lcd/e3v2/proui/dwin.cpp +++ b/Marlin/src/lcd/e3v2/proui/dwin.cpp @@ -2306,7 +2306,7 @@ void setMoveZ() { hmiValue.axis = Z_AXIS; setPFloatOnClick(Z_MIN_POS, Z_MAX_POS, #endif #endif -#if ENABLED(ADVANCED_PAUSE_FEATURE) +#if ENABLED(CONFIGURE_FILAMENT_CHANGE) void setFilLoad() { setPFloatOnClick(0, EXTRUDE_MAXLENGTH, UNITFDIGITS); } void setFilUnload() { setPFloatOnClick(0, EXTRUDE_MAXLENGTH, UNITFDIGITS); } #endif diff --git a/ini/features.ini b/ini/features.ini index f9822fa7a8..32fd6c2621 100644 --- a/ini/features.ini +++ b/ini/features.ini @@ -323,7 +323,7 @@ CNC_COORDINATE_SYSTEMS = build_src_filter=+ EXPECTED_PRINTER_CHECK = build_src_filter=+ HOST_KEEPALIVE_FEATURE = build_src_filter=+ -REPORT_CAPABILITIES_GCODE = build_src_filter=+ +CAPABILITIES_REPORT = build_src_filter=+ AUTO_REPORT_POSITION = build_src_filter=+ REPETIER_GCODE_M360 = build_src_filter=+ HAS_GCODE_M876 = build_src_filter=+