From 3854d200bb68fcf3ca40467c89d786fcd405284d Mon Sep 17 00:00:00 2001 From: chamnit Date: Tue, 25 Oct 2016 20:03:30 -0600 Subject: [PATCH] Mandate all probe cycles ignore feed overrides. - For repeatability reasons, all G38.x probe cycles ignore feed rate overrides and move at their programmed speed. - The mandate can be removed with a new config.h option. - Updated the documentation to reflect the change. --- doc/csv/build_option_codes_en_US.csv | 1 + doc/log/commit_log_v1.1.txt | 11 +++++++++++ doc/markdown/interface.md | 1 + grbl/config.h | 7 +++++++ grbl/gcode.c | 3 +++ grbl/report.c | 3 +++ 6 files changed, 26 insertions(+) diff --git a/doc/csv/build_option_codes_en_US.csv b/doc/csv/build_option_codes_en_US.csv index e53b975..d77bc15 100644 --- a/doc/csv/build_option_codes_en_US.csv +++ b/doc/csv/build_option_codes_en_US.csv @@ -7,6 +7,7 @@ "Z","Homing force origin","Enabled" "H","Homing single axis commands","Enabled" "L","Two limit switches on axis","Enabled" +"A","Allow feed rate overrides in probe cycles","Enabled" "R","Classic compatibility mode","Enabled" "*","Restore all EEPROM command","Disabled" "$","Restore EEPROM `$` settings command","Disabled" diff --git a/doc/log/commit_log_v1.1.txt b/doc/log/commit_log_v1.1.txt index 27330bf..a3be169 100644 --- a/doc/log/commit_log_v1.1.txt +++ b/doc/log/commit_log_v1.1.txt @@ -1,3 +1,14 @@ +---------------- +Date: 2016-10-25 +Author: chamnit +Subject: Resolved parking accessory handling issue. + +- Yikes. Totally borked the last parking “fix”. Testing shows that all +accessories are now properly handled when retracting and restoring. It +was caused by not accounting for the planner re-factoring correctly in +the parking code. + + ---------------- Date: 2016-10-24 Author: Sonny Jeon diff --git a/doc/markdown/interface.md b/doc/markdown/interface.md index ff53853..e62d41f 100644 --- a/doc/markdown/interface.md +++ b/doc/markdown/interface.md @@ -311,6 +311,7 @@ Feedback messages provide non-critical information on what Grbl is doing, what i | **`Z`** | Homing force origin enabled | | **`H`** | Homing single axis enabled | | **`L`** | Two limit switches on axis enabled | +| **`A`** | Allow feed rate overrides in probe cycles | | **`R`** | Classic compatiblity mode enabled | | **`*`** | Restore all EEPROM disabled | | **`$`** | Restore EEPROM `$` settings disabled | diff --git a/grbl/config.h b/grbl/config.h index e80e9a9..c5ea217 100644 --- a/grbl/config.h +++ b/grbl/config.h @@ -540,6 +540,13 @@ // that any of these commands are used need continuous motions through them. #define FORCE_BUFFER_SYNC_DURING_WCO_CHANGE // Default enabled. Comment to disable. +// By default, Grbl disables feed rate overrides for all G38.x probe cycle commands. Although this +// may be different than some pro-class machine control, it's arguable that it should be this way. +// Most probe sensors produce different levels of error that is dependent on rate of speed. By +// keeping probing cycles to their programmed feed rates, the probe sensor should be a lot more +// repeatable. If needed, you can disable this behavior by uncommenting the define below. +// #define ALLOW_FEED_OVERRIDE_DURING_PROBE_CYCLES // Default disabled. Uncomment to enable. + // Enables and configures parking motion methods upon a safety door state. Primarily for OEMs // that desire this feature for their integrated machines. At the moment, Grbl assumes that // the parking motion only involves one axis, although the parking implementation was written diff --git a/grbl/gcode.c b/grbl/gcode.c index 578b083..c0d0bce 100644 --- a/grbl/gcode.c +++ b/grbl/gcode.c @@ -1040,6 +1040,9 @@ uint8_t gc_execute_line(char *line) } else { // NOTE: gc_block.values.xyz is returned from mc_probe_cycle with the updated position value. So // upon a successful probing cycle, the machine position and the returned value should be the same. + #ifndef ALLOW_FEED_OVERRIDE_DURING_PROBE_CYCLES + pl_data->condition |= PL_COND_FLAG_NO_FEED_OVERRIDE; + #endif uint8_t is_probe_away = false; uint8_t is_no_error = false; if ((gc_state.modal.motion == MOTION_MODE_PROBE_AWAY) || (gc_state.modal.motion == MOTION_MODE_PROBE_AWAY_NO_ERROR)) { is_probe_away = true; } diff --git a/grbl/report.c b/grbl/report.c index 23fd148..4fe425e 100644 --- a/grbl/report.c +++ b/grbl/report.c @@ -569,6 +569,9 @@ void report_build_info(char *line) #ifdef LIMITS_TWO_SWITCHES_ON_AXES serial_write('L'); #endif + #ifdef ALLOW_FEED_OVERRIDE_DURING_PROBE_CYCLES + serial_write('A'); + #endif #ifdef USE_CLASSIC_GRBL_INTERFACE serial_write('R'); #endif