G1 F9000 X0 Y0
G1 F10000 Z298 ; Go to Z top prime position.
G1 F9000 X-130 Y-10 ; Go to X Y prime position.
G1 Z297 ; Go to Z prime position.
; G1 F120 E1 ; Prime old tool to get consistency end of filament
; G4 P3000 ; wait 5 sec to get a nice filament-end before tool change.
; G1 F9000 E-20 ; Prime old tool to get consistency end of filament
; G4 P2000 ;
G1 F6000 E-45 ;
G4 P6000 ;
G1 F4000 E-140 ;
T[new_tool]; Tool change
G92 E0 ; Zero tool.
G1 F1200 E135 ; Priming new tool.
G1 F90 E150;
G92 E0 ; Zero tool.
G1 F9000 E-20 ; Retract extruder by 3 mm to avoid thin string going to print area.
G1 X0 Y0 F9000;
G1 F8000 X[next_position_x] Y[next_position_y] ; Go to X Y printing position.
G1 F10000 Z[next_position_z]; Go to Z printing position.
G1 E0.5 F1200; Extrude 0.5mm that was retracted by 3.0mm at tool change
compensate for filament pressure in tube.
G92 E0; Set Extruder 0
============================================