Updated interface protocol. Fixed M2 bug.

- Updated interface protocol to play nicer with interface programs. All
Grbl responses beginning with '$' signifies a setting. Bracketed '[]'
responses are feedback messages containing either state, parameter, or
general messages. Chevron '<>' response are from the real-time status
messages, i.e. position.

- M2 Program end command was causing a system alarm. Fixed. Thanks
@blinkenlight !
This commit is contained in:
Sonny Jeon
2012-11-19 17:39:40 -07:00
parent b3f5536530
commit 9e0ce55dbc
4 changed files with 41 additions and 42 deletions

View File

@ -327,10 +327,11 @@ uint8_t plan_check_full_buffer()
return(false);
}
// Block until all buffered steps are executed.
// Block until all buffered steps are executed or in a cycle state. Works with feed hold
// during a synchronize call, if it should happen. Also, waits for clean cycle end.
void plan_synchronize()
{
while (plan_get_current_block()) {
while (plan_get_current_block() || sys.state == STATE_CYCLE) {
protocol_execute_runtime(); // Check and execute run-time commands
if (sys.abort) { return; } // Check for system abort
}