Browse Source

Syntax cleanup

pull/1/head
Scott Lahteine 8 years ago
parent
commit
79d42d87c1
  1. 17
      Marlin/planner.cpp

17
Marlin/planner.cpp

@ -1141,16 +1141,16 @@ void Planner::_buffer_line(const float &a, const float &b, const float &c, const
// Limit acceleration per axis
if (block->step_event_count <= cutoff_long) {
LIMIT_ACCEL_LONG(X_AXIS,0);
LIMIT_ACCEL_LONG(Y_AXIS,0);
LIMIT_ACCEL_LONG(Z_AXIS,0);
LIMIT_ACCEL_LONG(E_AXIS,ACCEL_IDX);
LIMIT_ACCEL_LONG(X_AXIS, 0);
LIMIT_ACCEL_LONG(Y_AXIS, 0);
LIMIT_ACCEL_LONG(Z_AXIS, 0);
LIMIT_ACCEL_LONG(E_AXIS, ACCEL_IDX);
}
else {
LIMIT_ACCEL_FLOAT(X_AXIS,0);
LIMIT_ACCEL_FLOAT(Y_AXIS,0);
LIMIT_ACCEL_FLOAT(Z_AXIS,0);
LIMIT_ACCEL_FLOAT(E_AXIS,ACCEL_IDX);
LIMIT_ACCEL_FLOAT(X_AXIS, 0);
LIMIT_ACCEL_FLOAT(Y_AXIS, 0);
LIMIT_ACCEL_FLOAT(Z_AXIS, 0);
LIMIT_ACCEL_FLOAT(E_AXIS, ACCEL_IDX);
}
}
block->acceleration_steps_per_s2 = accel;
@ -1256,6 +1256,7 @@ void Planner::_buffer_line(const float &a, const float &b, const float &c, const
v_exit *= v_factor;
v_entry *= v_factor;
}
// Calculate jerk depending on whether the axis is coasting in the same direction or reversing.
const float jerk = (v_exit > v_entry)
? // coasting axis reversal

Loading…
Cancel
Save