-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathTEST_Macros.txt
67 lines (56 loc) · 1.6 KB
/
TEST_Macros.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
[gcode_macro G29]
gcode:
{% set t = params.T|default(0)|float %}
{% if printer.idle_timeout.state == "Printing" %}
{action_respond_info("This command cannot be used while printing")}
{% elif printer.toolhead.homed_axes != "xyz" %}
{action_respond_info("Please home XYZ first")}
{% else %}
SAVE_GCODE_STATE NAME=G29_state
G90
G1 Z10 F240
{% if t > 30.0 %}
M190 S{t}
{% endif %}
BED_MESH_CALIBRATE
{% if 'S' in params %}
M140 S{params.S}
{% endif %}
G90
G1 Z10 F240
G1 X150 Y155 F6000
RESTORE_GCODE_STATE NAME=G29_state MOVE=0
{% endif %}
[gcode_macro WIPE_LINE]
gcode:
{% set z = params.Z|default(0.25)|float %}
{% set n = params.N|default(0.4)|float %}
{% if printer.toolhead.homed_axes != "xyz" %}
{action_respond_info("Please home XYZ first")}
{% elif printer.extruder.temperature < 170 %}
{action_respond_info("Extruder temperature too low")}
{% else %}
SAVE_GCODE_STATE NAME=WIPE_LINE_state
M82
G90
G92 E0
G1 X10 Y20 Z5 F3000
G1 Z{z} F3000
G1 X10 Y150 F1500 E10.83
G1 X{ n + 10.0 } F5000
G1 Y22 F1500 E21.5
G1 Y20 F5000
RESTORE_GCODE_STATE NAME=WIPE_LINE_state MOVE=0
{% endif %}
# Do nozzle priming
[gcode_macro PRIME_EXTRUDER]
gcode:
M117 Priming
G92 E0
G1 X10.1 Y20 Z2.0 F2000
G1 X10.1 Y200 Z0.28 F2000.0 E15; Draw the first line
G1 X10.4 Y200 Z0.28 F5000.0; Move to the side a little
G1 X10.4 Y20.0 Z0.28 F2000.0 E30; Draw the second line
G92 E0
G1 F2400 E-0.7 # Small retract to remove pressure
G1 Z2.0 F3000 ;Move Z Axis up