[2.0.x] 6th-order jerk-controlled motion planning in real-time for AVR (#10373)

This commit is contained in:
Eduardo José Tagle
2018-04-11 20:13:42 -03:00
committed by Scott Lahteine
parent 5676b187b4
commit 57a899a412
5 changed files with 1265 additions and 126 deletions

View File

@ -98,12 +98,15 @@ class Stepper {
static volatile uint32_t step_events_completed; // The number of step events executed in the current block
#if ENABLED(BEZIER_JERK_CONTROL)
static int32_t bezier_A, // A coefficient in Bézier speed curve
bezier_B, // B coefficient in Bézier speed curve
bezier_C, // C coefficient in Bézier speed curve
bezier_F; // F coefficient in Bézier speed curve
static uint32_t bezier_AV; // AV coefficient in Bézier speed curve
static bool bezier_2nd_half; // If Bézier curve has been initialized or not
static int32_t bezier_A, // A coefficient in Bézier speed curve
bezier_B, // B coefficient in Bézier speed curve
bezier_C; // C coefficient in Bézier speed curve
static uint32_t bezier_F; // F coefficient in Bézier speed curve
static uint32_t bezier_AV; // AV coefficient in Bézier speed curve
#ifdef __AVR__
static bool A_negative; // If A coefficient was negative
#endif
static bool bezier_2nd_half; // If Bézier curve has been initialized or not
#endif
#if ENABLED(LIN_ADVANCE)
@ -361,7 +364,7 @@ class Stepper {
}
#if ENABLED(BEZIER_JERK_CONTROL)
static void _calc_bezier_curve_coeffs(const int32_t v0, const int32_t v1, const uint32_t steps);
static void _calc_bezier_curve_coeffs(const int32_t v0, const int32_t v1, const uint32_t av);
static int32_t _eval_bezier_curve(const uint32_t curr_step);
#endif