24 Commits

Author SHA1 Message Date
Terje Io
64c35930c7 Refactored offset handling, for improved readability and in preparation for rotation support.
Added experimental support for G66 (modal macro call) and G67 (end modal macro call).
Made axis letter to axis/motor assignment for axes ABCUVW freely changeable at compile time.
Fix for some G65 arguments being incorrectly validated for normal use (sign, range).
Added repeat support to G65 macro call via the optional L parameter word.
Changed default setting for ABC-axes to rotary.
Changed defaults for jerk settings to 10x acceleration settings.
Disabled jerk for jog, probe and spindle synchronized motion.
Added _active_probe system parameter, returns -1 if no probe inputs available.
Minor bug fix, G5.1 and G33.1 motion commands were not coverted to the correct string equivalent in $G output.
2026-01-25 07:51:44 +01:00
Terje Io
8c3d44bfca Added helper code for plugins claiming auxiliary ports to make plugin coding easier and behaviour consistent.
Some minor bug fixes such as incorrect error code returned for unknown $-commands and temporary incorrect position reporting on in-flight G92 offset changes.
2025-10-11 18:28:21 +02:00
Terje Io
e37572fe02 Improved M70-M73 modal state save and restore, should now handle overrides correctly.
Added lightweight JSON serializer outputting directly to file.
Fix for event handler sometimes called too early. Ref. issue #818.
For developers: added optional device filing system that can redirect file read/write to serial streams.
2025-10-02 15:18:28 +02:00
Terje Io
02b45f86e5 Fix for corrupted tool table entries not beeing reset. This may happen on resizing the tool table.
Added system parameter _tool_table_size, 0 if a tool table is not enabled.
Removed dependency on safety door input for parking settings: $41, $42, $56-$59, $392 and $393.
Removed strict dependency on spindle encoder input for spindle synced motion,
allows the use of the stepper spindle which has an implicit encoder.
2025-07-31 08:19:07 +02:00
Terje Io
9ed8d488f8 Added vfs_chmod() to VFS (Virtual File System), for setting basic file attributes.
Changed signature of vfs.on_mount() event.
Added grbl.on_cycle_start() event, fired on cycle start signal asserted or on cycle start real time command received.
2025-02-25 20:55:59 +01:00
Terje Io
c7c7d5a4cf Added $SDS command for outputting Stepper Driver Status. 2025-01-20 13:11:00 +01:00
Terje Io
efe4245a06 "hardened" task deregistration code and changed signature of setting available and ioport_find_free() calls.
Some low-level ioport improvements, added definition for virtual pins/ports.
Deprecated direct access to number of the different ioport ports in hal.port struct, use ioports_unclaimed() instead.
2025-01-14 17:13:56 +01:00
Terje Io
b80cd2f3f8 Changed error code reported when file not found for G65 macro or named O-sub calls from 39 to 84.
Removed IDLE state requirement for executing G65 macros, an error will no longer be returned and the macro will be run.
Added event handler for outputting welcome message on "native" USB connect for drivers that provides the linestate changed event.
2025-01-05 08:18:52 +01:00
Terje Io
9a98243fd3 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.
2024-10-27 07:27:25 +07:00
Terje Io
323dd84b79 Added (PRINT, <msg>) support and parameter formatting for DEBUG and PRINT commands.
Added named parameters for getting absolute (G53) position: _abs_x, abs_y, ...
Available when expression support is enabled.

Changed stepper enable HAL signature to allow current reduction when idle.
Added reference id to spindle registration in order to allow configuring default spindle, and possibly additional spindles, at compile time.
2024-09-29 12:38:49 +07:00
Terje Io
acaea365cd Added setting $486 that allows locking G59.1 - G59.3 coordinate system offsets against accidental changes. 2023-09-17 09:51:58 +02:00
Terje Io
ce7c3592b4 Added experimental support for program flow control, mainly available for use in G65 macros stored on SD card or in littlefs. 2023-05-29 00:46:05 +02:00
Terje Io
c652eee852 Now allows some $-commands while critical events are active or in sleep mode.
Added work envelope data to global sys struct, used by soft limits and jog limit handling.
2023-04-29 15:53:46 +02:00
Terje Io
c7a6f049e4 Minor fix for the grbl.on_state_changed event - incorrect state published following stop signal when streaming gcode.
Added core event for real-time report elements beeing forced++
2023-03-06 20:39:12 +01:00
Terje Io
fb60b493b5 Added settings, updated settings version to 22. See changelog for details.
Merged defaults.h with config.h, deleted defaults.h and harmonized settings defines.
2023-01-25 21:11:21 +01:00
Terje Io
b0d9e9e78a Fix for issue #209, incorrect handling of homing of more than one auto squared axis in each pass.
Error 55 will now be returned.
2022-10-23 07:27:20 +02:00
Terje Io
26fa15a990 Added authentication related error codes and messages. Added reboot required per settings to various reports. 2022-07-26 17:43:16 +02:00
Terje Io
f88b154b96 See changelog for details. 2021-11-28 16:52:00 +01:00
Terje Io
fc0f9ecf75 Fixed silly typedef mistake in setting struct, added settings $392 and $393 for spindle and coolant startup delays on safety door open. 2021-11-22 10:26:56 +01:00
Terje Io
f306bfa598 Renamed default hostnames and device names, added some HAL extensions and hardened code a bit. 2021-11-09 15:24:52 +01:00
Terje Io
71dc5ac333 Changed safety door/parking handling to be compliant with legacy Grbl.
Added $384 setting for controlling G92 offset persistence.
Improved $help command output and handling.
Moved the optional tool table in non-volatile storage.
Added gcode parameter support and optional expression support.
2021-09-29 10:22:47 +02:00
Terje Io
415886e53b Improved HAL/core stream handling etc. 2021-09-09 19:19:09 +02:00
Terje Io
f2eea4dcb4 some bug fixes: relative canned cycles, incorrect comments handling and auto square fail distance calulation (regression) 2021-05-05 20:27:19 +02:00
Terje Io
cdca5ad55c test check in 2021-02-22 12:29:17 +01:00