From 41253fbbdd1c3527eff45bbf6b65e1da0973ffc9 Mon Sep 17 00:00:00 2001 From: Joseph Coffland Date: Thu, 23 Jun 2016 16:44:09 -0700 Subject: [PATCH] Uppercase macro --- src/cycle_homing.c | 2 +- src/cycle_probing.c | 2 +- src/gcode_parser.c | 4 ++-- src/plan/arc.c | 2 +- src/plan/exec.c | 2 +- src/status.c | 2 +- src/status.h | 4 ++-- 7 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/cycle_homing.c b/src/cycle_homing.c index db5d483..bb9234c 100644 --- a/src/cycle_homing.c +++ b/src/cycle_homing.c @@ -347,7 +347,7 @@ static stat_t _homing_axis_move(int8_t axis, float target, float velocity) { cm.gm.feed_rate = velocity; mp_flush_planner(); // don't use cm_request_queue_flush() here cm_request_cycle_start(); - ritorno(cm_straight_feed(vect, flags)); + RITORNO(cm_straight_feed(vect, flags)); return STAT_EAGAIN; } diff --git a/src/cycle_probing.c b/src/cycle_probing.c index 3ea5cb2..d48acca 100644 --- a/src/cycle_probing.c +++ b/src/cycle_probing.c @@ -198,7 +198,7 @@ static stat_t _probing_start() { // initial probe state, don't probe if we're already contacted! bool closed = switch_get_active(pb.probe_switch); - if (!closed) ritorno(cm_straight_feed(pb.target, pb.flags)); + if (!closed) RITORNO(cm_straight_feed(pb.target, pb.flags)); return _set_pb_func(_probing_finish); } diff --git a/src/gcode_parser.c b/src/gcode_parser.c index ea69740..8343c79 100644 --- a/src/gcode_parser.c +++ b/src/gcode_parser.c @@ -249,7 +249,7 @@ static stat_t _execute_gcode_block() { EXEC_FUNC(cm_override_enables, override_enables); if (cm.gn.next_action == NEXT_ACTION_DWELL) // G4 - dwell - ritorno(cm_dwell(cm.gn.parameter)); + RITORNO(cm_dwell(cm.gn.parameter)); EXEC_FUNC(cm_set_plane, select_plane); EXEC_FUNC(cm_set_units_mode, units_mode); @@ -517,7 +517,7 @@ static stat_t _parse_gcode_block(char *buf) { } if (status != STAT_OK && status != STAT_COMPLETE) return status; - ritorno(_validate_gcode_block()); + RITORNO(_validate_gcode_block()); return _execute_gcode_block(); // if successful execute the block } diff --git a/src/plan/arc.c b/src/plan/arc.c index 477e690..8b01e40 100644 --- a/src/plan/arc.c +++ b/src/plan/arc.c @@ -456,7 +456,7 @@ stat_t cm_arc_feed(float target[], float flags[], // arc endpoints fp_ZERO(flags[arc.plane_axis_0]) & fp_ZERO(flags[arc.plane_axis_1]); // compute arc runtime values - ritorno(_compute_arc()); + RITORNO(_compute_arc()); // trap zero length arcs that _compute_arc can throw if (fp_ZERO(arc.length)) return STAT_MINIMUM_LENGTH_MOVE; diff --git a/src/plan/exec.c b/src/plan/exec.c index ff041dd..2159bab 100644 --- a/src/plan/exec.c +++ b/src/plan/exec.c @@ -105,7 +105,7 @@ static stat_t _exec_aline_segment() { travel_steps[i] = mr.target_steps[i] - mr.position_steps[i]; // Call the stepper prep function - ritorno(st_prep_line(travel_steps, mr.following_error, mr.segment_time)); + RITORNO(st_prep_line(travel_steps, mr.following_error, mr.segment_time)); // update position from target copy_vector(mr.position, mr.ms.target); diff --git a/src/status.c b/src/status.c index 2f63af4..ed691cc 100644 --- a/src/status.c +++ b/src/status.c @@ -29,7 +29,7 @@ #include -stat_t status_code; // allocate a variable for the ritorno macro +stat_t status_code; // allocate a variable for the RITORNO macro #define STAT_MSG(NAME, TEXT) static const char stat_##NAME[] PROGMEM = TEXT; #include "messages.def" diff --git a/src/status.h b/src/status.h index 1f80417..1047716 100644 --- a/src/status.h +++ b/src/status.h @@ -30,9 +30,9 @@ #include -// ritorno is a handy way to provide exception returns +// RITORNO is a handy way to provide exception returns // It returns only if an error occurred. (ritorno is Italian for return) -#define ritorno(a) if ((status_code = a) != STAT_OK) {return status_code;} +#define RITORNO(a) if ((status_code = a) != STAT_OK) {return status_code;} typedef enum { #define STAT_MSG(NAME, TEXT) STAT_##NAME, -- 2.27.0