Fix some trailing whitespace, macros

This commit is contained in:
Scott Lahteine 2018-09-17 17:30:04 -05:00
parent 54bd124665
commit c5e5cc5e9f
6 changed files with 14 additions and 14 deletions

View file

@ -397,11 +397,11 @@
#if IS_KINEMATIC #if IS_KINEMATIC
const float seconds = cartesian_xy_mm / feedrate; // seconds to move xy distance at requested rate const float seconds = cartesian_xy_mm / feedrate; // seconds to move xy distance at requested rate
uint16_t segments = lroundf(delta_segments_per_second * seconds), // preferred number of segments for distance @ feedrate uint16_t segments = LROUND(delta_segments_per_second * seconds), // preferred number of segments for distance @ feedrate
seglimit = lroundf(cartesian_xy_mm * (1.0f / (DELTA_SEGMENT_MIN_LENGTH))); // number of segments at minimum segment length seglimit = LROUND(cartesian_xy_mm * (1.0f / (DELTA_SEGMENT_MIN_LENGTH))); // number of segments at minimum segment length
NOMORE(segments, seglimit); // limit to minimum segment length (fewer segments) NOMORE(segments, seglimit); // limit to minimum segment length (fewer segments)
#else #else
uint16_t segments = lroundf(cartesian_xy_mm * (1.0f / (DELTA_SEGMENT_MIN_LENGTH))); // cartesian fixed segment length uint16_t segments = LROUND(cartesian_xy_mm * (1.0f / (DELTA_SEGMENT_MIN_LENGTH))); // cartesian fixed segment length
#endif #endif
NOLESS(segments, 1U); // must have at least one segment NOLESS(segments, 1U); // must have at least one segment

View file

@ -273,7 +273,7 @@ static bool probe_calibration_points(float z_pt[NPP + 1], const int8_t probe_poi
for (int8_t circle = 0; circle <= offset; circle++) { for (int8_t circle = 0; circle <= offset; circle++) {
const float a = RADIANS(210 + (360 / NPP) * (rad - 1)), const float a = RADIANS(210 + (360 / NPP) * (rad - 1)),
r = delta_calibration_radius * (1 - 0.1 * (zig_zag ? offset - circle : circle)), r = delta_calibration_radius * (1 - 0.1 * (zig_zag ? offset - circle : circle)),
interpol = fmod(rad, 1); interpol = FMOD(rad, 1);
const float z_temp = calibration_probe(cos(a) * r, sin(a) * r, stow_after_each, set_up); const float z_temp = calibration_probe(cos(a) * r, sin(a) * r, stow_after_each, set_up);
if (isnan(z_temp)) return false; if (isnan(z_temp)) return false;
// split probe point to neighbouring calibration points // split probe point to neighbouring calibration points

View file

@ -2666,7 +2666,7 @@ bool Planner::buffer_line(const float &rx, const float &ry, const float &rz, con
float mm = millimeters; float mm = millimeters;
if (mm == 0.0) if (mm == 0.0)
mm = (delta_mm_cart[X_AXIS] != 0.0 || delta_mm_cart[Y_AXIS] != 0.0) ? SQRT(sq(delta_mm_cart[X_AXIS]) + sq(delta_mm_cart[Y_AXIS]) + sq(delta_mm_cart[Z_AXIS])) : fabs(delta_mm_cart[Z_AXIS]); mm = (delta_mm_cart[X_AXIS] != 0.0 || delta_mm_cart[Y_AXIS] != 0.0) ? SQRT(sq(delta_mm_cart[X_AXIS]) + sq(delta_mm_cart[Y_AXIS]) + sq(delta_mm_cart[Z_AXIS])) : ABS(delta_mm_cart[Z_AXIS]);
inverse_kinematics(raw); inverse_kinematics(raw);