Jump to content
Ultimaker Community of 3D Printing Experts
anton_33

Cura Start and End code

Recommended Posts

Hi everyone,

I am new to 3D printing and would like to change the start and end settings of my prints.

How can I make it so that the extruder positions itself 15mm above the bed in the front right corner, pushes out 20 mm of filament and then starts the print. And once the print is done it moves back to front right corner but moves the extruder to the top height, like 150mm above the bed or something.

This is the Current start and End Code that I have in Marlin.

Start:

G21 ;metric values

G90 ;absolute positioning

M82 ;set extruder to absolute mode

M107 ;start with the fan off

G28 X0 Y0 ;move X/Y to min endstops

G28 Z0 ;move Z to min endstops

G1 Z15.0 F9000 ;move the platform down 15mm

G92 E0 ;zero the extruded length

G1 F200 E3 ;extrude 3mm of feed stock

G92 E0 ;zero the extruded length again

G1 F9000

;Put printing message on LCD screen

M117 Printing...

End:

M104 S0 ;extruder heater off

M140 S0 ;heated bed heater off (if you have it)

G91 ;relative positioning

G1 E-1 F300 ;retract the filament a bit before lifting the nozzle, to release some of the pressure

G1 Z+0.5 E-5 X-20 Y-20 F9000 ;move Z up a bit and retract filament even more

G28 X0 Y0 ;move X/Y to min endstops, so the head is out of the way

M84 ;steppers off

G90 ;absolute positioning

Btw, I am using a Maker Select V2. I don't know if that makes a difference.

Thanks,

Anton

Share this post


Link to post
Share on other sites

G0 and G1 are identical commands and tell the printer to "go" or "go to" some location. You can specify all 4 axes or just one axes or anything in between. So

G0 X50 Y50 Z15

Moves to that location with the nozzle 15mm above the bed. I don't know how wide your bed is and I don't know where 0,0 is for you. On UM printers 0,0 is front left and they are a little over 215mm wide so:

G0 X200 Y0 Z15 is safe for a UM printer.

To extrude it's the part where it does this:

G92 E0 ;zero the extruded length

G1 F200 E3 ;extrude 3mm of feed stock

G92 E0 ;zero the extruded length again

The G92's are important - that sets current position for an axis (in this case E axis to position zero). Without that you don't know where the E axis will move to - it depends where the E axis left off which might be at the 10 meter point from a previous print.

The G1 F200 E3 moves 3mm of filament. The F200 is the feedrate which stays in effect for all subsequent G0 or G1 comnmands until F is mentioned again. It's in mm/minute so divide by 60 to get mm/sec. Or take your mm/sec value you want and multiply by 60.

Does that answer all your questions?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Our picks

    • Taking Advantage of DfAM
      This is a statement that’s often made about AM/3DP. I'll focus on the way DfAM can take advantage of some of the unique capabilities that AM and 3DP have to offer. I personally think that the use of AM/3DP for light-weighting is one of it’s most exciting possibilities and one that could play a key part in the sustainability of design and manufacturing in the future.
        • Like
      • 3 replies
×

Important Information

Welcome to the Ultimaker Community of 3D printing experts. Visit the following links to read more about our Terms of Use or our Privacy Policy. Thank you!