gcode_macro: Add support for SET_GCODE_VARIABLE command

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2019-05-28 12:17:08 -04:00 committed by KevinOConnor
parent 6e88320d62
commit a68f577adf
3 changed files with 37 additions and 1 deletions

View file

@ -1487,6 +1487,13 @@
# command "MY_DELAY" would evaluate to "G4 P50". The default is to
# require that all parameters used in the gcode script be present in
# the command invoking the macro.
#variable_<name>:
# One may specify any number of options with a "variable_" prefix.
# The given variable name will then be available during macro
# expansion. For example, a config with "variable_my_name = zebra"
# might have a gcode config containing "M117 My name is {my_name}".
# Variables can be changed at run-time using the SET_GCODE_VARIABLE
# command.
# Enable the "M118" and "RESPOND" extended commands.