Tweaks and bug fixes. Increase to 3 startup blocks. Remove purge/added unlock command

- Increased the number of startup blocks to 3 for no good reason other
than it doesn't increase the flash size.

- Removed the purge buffer command and replaced with an disable homing
lock command.

- Homing now blocks all g-code commands (not system commands) until the
homing cycle has been performed or the disable homing lock is sent.
Homing is required upon startup or if Grbl loses it position. This is
for safety reasons.

- Cleaned up some of the Grbl states and re-organized it to be little
more cohesive.

- Cleaned up the feedback and status messages to not use so much flash
space, as it's a premium now.

 - Check g-code and dry run switches how are mutually exclusive and
can't be enabled when the other is. And automatically resets Grbl when
disabled.

- Some bug fixes and other minor tweaks.
This commit is contained in:
Sonny Jeon
2012-11-05 21:40:52 -07:00
parent c2b31a06ff
commit f41dd69273
9 changed files with 96 additions and 97 deletions

View File

@ -215,7 +215,7 @@ void mc_go_home()
limits_go_home(); // Perform homing routine.
if (sys.abort) {
sys.state = STATE_LOST; // Homing routine did not complete.
sys.state = STATE_ALARM; // Homing routine did not complete.
return;
}
@ -253,7 +253,8 @@ void mc_alarm()
// Only this function can set the system alarm. This is done to prevent multiple kill calls
// by different processes.
if (bit_isfalse(sys.execute, EXEC_ALARM)) {
// Set system alarm flag.
// Set system alarm flag to have the main program check for anything wrong with shutting
// down the system.
sys.execute |= EXEC_ALARM;
// Immediately force stepper, spindle, and coolant to stop.
st_go_idle();