From b8066d03c370fb8ab688fa6b41d9ea2dd588616e Mon Sep 17 00:00:00 2001 From: Makoto Schoppert Date: Wed, 26 Feb 2020 19:49:40 -0500 Subject: [PATCH 1/2] Update planner.cpp Fix build errors around undeclared variables. --- Marlin/src/module/planner.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Marlin/src/module/planner.cpp b/Marlin/src/module/planner.cpp index 7c387ac75304..6a115a57c088 100644 --- a/Marlin/src/module/planner.cpp +++ b/Marlin/src/module/planner.cpp @@ -2404,9 +2404,9 @@ bool Planner::_populate_block(block_t * const block, bool split_move, #endif { const float jerk = ABS(current_speed[i]); // cs : Starting from zero, change in speed for this axis - maxj = (max_jerk[axis] // mj : The max jerk setting for this axis + const float maxj = (max_jerk[i] // mj : The max jerk setting for this axis #ifdef TRAVEL_EXTRA_XYJERK - + (axis == X_AXIS || axis == Y_AXIS ? extra_xyjerk : 0) + + (i == X_AXIS || i == Y_AXIS ? extra_xyjerk : 0) #endif ); From 8ac49a7cc7e269095f696b48cadf5245d4116233 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Thu, 27 Feb 2020 03:29:15 -0600 Subject: [PATCH 2/2] Update planner.cpp --- Marlin/src/module/planner.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Marlin/src/module/planner.cpp b/Marlin/src/module/planner.cpp index 6a115a57c088..2067ecc23f56 100644 --- a/Marlin/src/module/planner.cpp +++ b/Marlin/src/module/planner.cpp @@ -2403,8 +2403,8 @@ bool Planner::_populate_block(block_t * const block, bool split_move, LOOP_XYZE(i) #endif { - const float jerk = ABS(current_speed[i]); // cs : Starting from zero, change in speed for this axis - const float maxj = (max_jerk[i] // mj : The max jerk setting for this axis + const float jerk = ABS(current_speed[i]), // cs : Starting from zero, change in speed for this axis + maxj = (max_jerk[i] // mj : The max jerk setting for this axis #ifdef TRAVEL_EXTRA_XYJERK + (i == X_AXIS || i == Y_AXIS ? extra_xyjerk : 0) #endif