forked from chirpy2605/voron
-
Notifications
You must be signed in to change notification settings - Fork 0
/
nozzlewiper.cfg
105 lines (98 loc) · 3.64 KB
/
nozzlewiper.cfg
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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
###############################################################################
## NOZZLE WIPER v2 - A nozzle purge bucket and brush for the Voron 0.1
##
## Configuration:
##
## 1. Set the correct PWM pin that you connected the Orange wire
## to in the [servo wipeServo] section replacing XXNN
## 2. Home X, Y and Z axes
## 3. Lower Z by at least 50mm
## 4. Run the NW_DEPLOY macro and ensure the servo extends the arm 90 degrees
## 5. Use the printer controls to move the nozzle so that it is in the centre
## of the purge bucket on the X and Y axis
## 7. Run M114 to get the nozzle position and set variable_x and variable_y.
## If you do not set these values the macro will fail as the defaults are
## deliberately wrong
## 8. Move the nozzle into the center of the brush and raise the Nozzle Wiper
## on the frame mount until the nozzle just rests into the brush. Try not
## to let the brush touch the sock or it could wear it out prematurely.
## Secure the position by tightening the 2 M3x8mm screws on the frame mount
## 9. Move the nozzle out of the way from the brush and purge bucket
## 10. Run NW_RETRACT and ensure the servo moves the arm back away to the side
##
## Testing:
##
## 1. Heat the nozzle to the printing temperature of the loaded filament
## 2. Home all axes
## 3. Be prepared to hit the Emergency Stop button if things don't go as they
## should
## 4. Run NW_CLEAN_NOZZLE
##
## That should be all changes needed. Call the NW_CLEAN_NOZZLE macro from
## the end of your START_PRINT macro to wipe the nozzle clean before printing
###############################################################################
[servo wipeServo]
pin: XXNN
minimum_pulse_width: 0.0005
maximum_servo_angle: 180
[gcode_macro NW_CLEAN_NOZZLE]
gcode:
{% if "xyz" in printer.toolhead.homed_axes %}
SAVE_GCODE_STATE NAME=NW_CLEAN_NOZZLE
G90
NW_DEPLOY
NW_PURGE
NW_WIPE
NW_RETRACT
RESTORE_GCODE_STATE NAME=NW_CLEAN_NOZZLE
{% else %}
{ action_raise_error("Home All Axis First") }
M117 Home All Axis First
{% endif %}
[gcode_macro NW_BUCKET_POS]
# Sensible values for variable_x would be 32, but adjust as per the instructions
variable_x: -1000
# Sensible values for variable_y would be around 60, but adjust as per the instructions
variable_y: -1000
# Sensible value for variable_z is 50
variable_z: 50
gcode:
M118 bucket pos X:{printer["gcode_macro NW_BUCKET_POS"].x} Y:{printer["gcode_macro NW_BUCKET_POS"].y} Z:{printer["gcode_macro NW_BUCKET_POS"].z}
[gcode_macro NW_DEPLOY]
gcode:
G90
G0 Z{printer["gcode_macro NW_BUCKET_POS"].z}
SET_SERVO SERVO=wipeServo ANGLE=15
G4 P500
[gcode_macro NW_RETRACT]
gcode:
SET_SERVO SERVO=wipeServo ANGLE=120
SET_SERVO SERVO=wipeServo WIDTH=0 # OFF
G4 P500
[gcode_macro NW_WIPE]
gcode:
G90
G0 Z{printer["gcode_macro NW_BUCKET_POS"].z} F5000
G0 X{printer["gcode_macro NW_BUCKET_POS"].x} Y{printer["gcode_macro NW_BUCKET_POS"].y - 25} F5000
{% for wipes in range(1, 4) %}
G0 Y{printer["gcode_macro NW_BUCKET_POS"].y - 25} F{2000}
G0 Y{printer["gcode_macro NW_BUCKET_POS"].y - 55} F{2000}
{% endfor %}
G0 X60 F5000
G0 Y60 F5000
[gcode_macro NW_PURGE]
gcode:
G90
G0 Z{printer["gcode_macro NW_BUCKET_POS"].z} F5000
G0 Y{printer["gcode_macro NW_BUCKET_POS"].y+40} F5000
G0 X{printer["gcode_macro NW_BUCKET_POS"].x}
G0 Y{printer["gcode_macro NW_BUCKET_POS"].y} F5000
{% if printer.extruder.temperature >= 180 %}
M83
G1 E10 F150
G1 E-2 F{150 * 750}
G4 P{2000}
G92 E0
{% else %}
{ action_raise_error("Nozzle Temp must be > 180C") }
{% endif %}