mirror of
https://github.com/Klipper3d/klipper.git
synced 2025-12-15 20:59:56 +01:00
gcode: Split G0/G1 command handling to new gcode_move class
Split up the main GCodeParser class into GCodeDispatch and GCodeMove classes. The GCodeMove class is now available using the "gcode_move" printer object name. This split simplifies the gcode.py code. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
@@ -73,7 +73,7 @@ gcode:
|
||||
|
||||
[gcode_macro TEST_expression]
|
||||
gcode:
|
||||
{% if printer.gcode.gcode_position.x != 0.0 %}
|
||||
{% if printer.gcode_move.gcode_position.x != 0.0 %}
|
||||
M112
|
||||
{% else %}
|
||||
{ action_respond_info("TEST_expression") }
|
||||
@@ -108,7 +108,7 @@ gcode:
|
||||
|
||||
[gcode_macro TEST_in]
|
||||
gcode:
|
||||
{% if "abc" in printer or "gcode" not in printer %}
|
||||
{% if "abc" in printer or "toolhead" not in printer %}
|
||||
M112
|
||||
{% endif %}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user