From 2ccdf4f36d368dd5b5d24aab05dc54c39e8bf458 Mon Sep 17 00:00:00 2001 From: Gabe Rosenhouse Date: Wed, 19 Feb 2014 00:02:59 -0800 Subject: [PATCH 1/2] Use descriptive constants instead of numeric literals --- Marlin/Marlin_main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Marlin/Marlin_main.cpp b/Marlin/Marlin_main.cpp index f98d530dea..47f81a4d43 100644 --- a/Marlin/Marlin_main.cpp +++ b/Marlin/Marlin_main.cpp @@ -1241,7 +1241,7 @@ void process_commands() #else // NOT DELTA - home_all_axis = !((code_seen(axis_codes[0])) || (code_seen(axis_codes[1])) || (code_seen(axis_codes[2]))); + home_all_axis = !((code_seen(axis_codes[X_AXIS])) || (code_seen(axis_codes[Y_AXIS])) || (code_seen(axis_codes[Z_AXIS]))); #if Z_HOME_DIR > 0 // If homing away from BED do Z first if((home_all_axis) || (code_seen(axis_codes[Z_AXIS]))) { From d2d7d186b5aaa208351d0dda35b26b59b6fbebca Mon Sep 17 00:00:00 2001 From: Gabe Rosenhouse Date: Wed, 19 Feb 2014 00:10:17 -0800 Subject: [PATCH 2/2] Use descriptive constants, more --- Marlin/Marlin_main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Marlin/Marlin_main.cpp b/Marlin/Marlin_main.cpp index 47f81a4d43..a3f0d60489 100644 --- a/Marlin/Marlin_main.cpp +++ b/Marlin/Marlin_main.cpp @@ -2088,7 +2088,7 @@ void process_commands() } else { - bool all_axis = !((code_seen(axis_codes[0])) || (code_seen(axis_codes[1])) || (code_seen(axis_codes[2]))|| (code_seen(axis_codes[3]))); + bool all_axis = !((code_seen(axis_codes[X_AXIS])) || (code_seen(axis_codes[Y_AXIS])) || (code_seen(axis_codes[Z_AXIS]))|| (code_seen(axis_codes[E_AXIS]))); if(all_axis) { st_synchronize();