gcode: Carry over #original and #command in get_extended_params()

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2017-10-02 21:48:45 -04:00
parent c2e1c53356
commit 06420b0ddf
1 changed files with 3 additions and 1 deletions

View File

@ -204,7 +204,9 @@ class GCodeParser:
eargs = m.group('args')
try:
eparams = [earg.split('=', 1) for earg in eargs.split()]
return { k.upper(): v for k, v in eparams }
eparams = { k.upper(): v for k, v in eparams }
eparams.update({k: params[k] for k in params if k.startswith('#')})
return eparams
except ValueError as e:
raise error("Malformed command '%s'" % (params['#original'],))
# Temperature wrappers