mirror of
https://github.com/grblHAL/core.git
synced 2026-09-27 19:13:58 +08:00
Changed _vminor named parameter to contain build date in YYMMDD format, previously value was 0.
Added support for LinuxCNC style (ABORT,<msg>) comment, requires expressions enabled. Terminates gcode program, outputs message and returns error 253. Added PRM[<setting>] and PRM[<setting>,<bit>] functions to expressions, returns $-setting value or value of bit in integer type setting. "hardened" flow control code, fixed bug in repeat...continue handling. Changed signature of grbl.on_gcode_comment event, now returns status code.
This commit is contained in:
@@ -683,12 +683,14 @@ static status_code_t set_startup_line (sys_state_t state, char *args, uint_fast8
|
||||
|
||||
status_code_t retval = Status_OK;
|
||||
|
||||
args = gc_normalize_block(args, NULL);
|
||||
args = gc_normalize_block(args, &retval, NULL);
|
||||
|
||||
if(strlen(args) >= (sizeof(stored_line_t) - 1))
|
||||
retval = Status_Overflow;
|
||||
else if ((retval = gc_execute_block(args)) == Status_OK) // Execute gcode block to ensure block is valid.
|
||||
settings_write_startup_line(lnr, args);
|
||||
if(retval == Status_OK) {
|
||||
if(strlen(args) >= (sizeof(stored_line_t) - 1))
|
||||
retval = Status_Overflow;
|
||||
else if ((retval = gc_execute_block(args)) == Status_OK) // Execute gcode block to ensure block is valid.
|
||||
settings_write_startup_line(lnr, args);
|
||||
}
|
||||
|
||||
return retval;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user