diff --git a/dda.c b/dda.c index c5d4f2c..b179a13 100644 --- a/dda.c +++ b/dda.c @@ -172,14 +172,14 @@ void dda_create(DDA *dda, TARGET *target) { if (dda->waitfor_temp) return; + // We end at the passed target. + memcpy(&(dda->endpoint), target, sizeof(TARGET)); + if (DEBUG_DDA && (debug_flags & DEBUG_DDA)) sersendf_P(PSTR("\nCreate: X %lq Y %lq Z %lq F %lu\n"), dda->endpoint.axis[X], dda->endpoint.axis[Y], dda->endpoint.axis[Z], dda->endpoint.F); - // we end at the passed target - memcpy(&(dda->endpoint), target, sizeof(TARGET)); - #ifdef LOOKAHEAD // Set the start and stop speeds to zero for now = full stops between // moves. Also fallback if lookahead calculations fail to finish in time.