Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save av-jok/572bfbd5ba5682ba54f55fdba086a9b1 to your computer and use it in GitHub Desktop.
Save av-jok/572bfbd5ba5682ba54f55fdba086a9b1 to your computer and use it in GitHub Desktop.
Various Custom G-Code for the Artist-D in Prusa Slicer
G91 ;Relative positioning
G0 E-2 F2700 ;Retract a bit
G0 E-2 Z0.2 F2400 ;Retract and raise Z
G0 X5 Y5 F3000 ;Wipe out
G0 Z10 ;Raise Z more
G90 ;Absolute positionning
G0 Y310 ;Present print
M106 S0 ;Turn-off fan
M104 S0 T0 ;Turn-off hotend 1
M104 S0 T1 ;Turn-off hotend 2
M140 S0 ;Turn-off bed
G28X ; Home x-carriages
M605 S1 ; Reset to auto-park
M84 X Y E ;Disable all steppers but Z
G91 ;Relative positioning
G0 E-2 F2700 ;Retract a bit
G0 E-2 Z0.2 F2400 ;Retract and raise Z
G0 X5 Y5 F3000 ;Wipe out
G0 Z10 ;Raise Z more
G90 ;Absolute positionning
{if current_extruder==0}
G0 X0 Y310 ;Present print
{else}
G0 X310 Y310 ;Present print
{endif}
M106 S0 ;Turn-off fan
M104 S0 T0 ;Turn-off hotend 1
M104 S0 T1 ;Turn-off hotend 2
M140 S0 ;Turn-off bed
G28X ; Home x-carriages
M84 X Y E ;Disable all steppers but Z
; -- BEGIN - DUPLICATION MODE INITIALIZATION --
M605 S1 ; AUTO-PARK MODE
T0 ; SET TOOL 0
G28 ; HOME ALL AXIS
M605 S2 X155 ; SET DUPLICATION MODE AND NOZZLE OFFSET
G28 X ; HOME X AXIS
G1 X77.5 ; SET BOTH EXTRUDERS TO THE MIDDLE OF THEIR PRINT AREA
; -- END - DUPLICATION MODE INITIALIZATION
M140 S[first_layer_bed_temperature] ; Set Heat Bed temperature
M104 S[first_layer_temperature] ; Set Extruder temperature
M190 S[first_layer_bed_temperature] ; Wait for Heat Bed temperature
G1 Z15.0 F6000 ;Move the platform down 15mm
;Prime the extruder
G92 E0 ; Reset Extruder
G1 Z2.0 F3000 ; Move Z Axis up little to prevent scratching of Heat Bed
G1 X10 Y20 Z0.3 F5000.0 ; Move to start position
M109 S[first_layer_temperature] ; Wait for Extruder temperature
G1 X10 Y200.0 Z0.2 F1500.0 E15 ; Draw the first line
G1 X10.3 Y200.0 Z0.2 F5000.0 ; Move to side a little
G1 X10.3 Y20 Z0.2 F1500.0 E30 ; Draw the second line
G92 E0 ; Reset Extruder
G1 Z2.0 F3000 ; Move Z Axis up little to prevent scratching of Heat Bed
G1 X14 Y20 Z0.2 F5000.0 ; Move over to prevent blob squish
; -- BEGIN - MIRROR MODE INITIALIZATION --
M605 S1
T0
G28
M605 S2 X155
G28 X
G1 X77.5
M605 S3 X155
; -- END - MIRROR MODE INITIALIZATION
M140 S[first_layer_bed_temperature] ; Set Heat Bed temperature
M104 S[first_layer_temperature] ; Set Extruder temperature
M190 S[first_layer_bed_temperature] ; Wait for Heat Bed temperature
G1 Z15.0 F6000 ;Move the platform down 15mm
;Prime the extruder
G92 E0 ; Reset Extruder
G1 Z2.0 F3000 ; Move Z Axis up little to prevent scratching of Heat Bed
G1 X10 Y20 Z0.3 F5000.0 ; Move to start position
M109 S[first_layer_temperature] ; Wait for Extruder temperature
G1 X10 Y200.0 Z0.2 F1500.0 E15 ; Draw the first line
G1 X10.3 Y200.0 Z0.2 F5000.0 ; Move to side a little
G1 X10.3 Y20 Z0.2 F1500.0 E30 ; Draw the second line
G92 E0 ; Reset Extruder
G1 Z2.0 F3000 ; Move Z Axis up little to prevent scratching of Heat Bed
G1 X14 Y20 Z0.2 F5000.0 ; Move over to prevent blob squish
M605S1 ; Set to auto-park
T[initial_tool]
M140 S[first_layer_bed_temperature] ; Set Heat Bed temperature
M104 S[first_layer_temperature_[initial_tool]] ; Set Extruder temperature
G28 ;Home
M190 S[first_layer_bed_temperature] ; Wait for Heat Bed temperature
G1 Z15.0 F6000 ;Move the platform down 15mm
;Prime the extruder
G92 E0 ; Reset Extruder
G1 Z2.0 F3000 ; Move Z Axis up little to prevent scratching of Heat Bed
G1 X10 Y20 Z0.3 F5000.0 ; Move to start position
M109 S[first_layer_temperature_[initial_tool]] ; Wait for Extruder temperature
G1 X10 Y200.0 Z0.2 F1500.0 E15 ; Draw the first line
G1 X10.3 Y200.0 Z0.2 F5000.0 ; Move to side a little
G1 X10.3 Y20 Z0.2 F1500.0 E30 ; Draw the second line
G92 E0 ; Reset Extruder
G1 Z2.0 F3000 ; Move Z Axis up little to prevent scratching of Heat Bed
G1 X14 Y20 Z0.2 F5000.0 ; Move over to prevent blob squish
; TOOL CHANGE ---START---
T[next_extruder]
{if current_extruder != next_extruder}
M104 S175 T[current_extruder]
{endif}
{if layer_num==0}
M109 S[first_layer_temperature_[next_extruder]] T[next_extruder] ; Wait for Extruder temperature
{else}
M109 S[temperature_[next_extruder]] T[next_extruder] ; Wait for Extruder temperature
{endif}
; TOOL CHANGE ---END---
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment