Macros

This topic contains 3 replies, has 2 voices, and was last updated by  Jeffeb3 4 months, 2 weeks ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #104294

    Edward
    Participant

    Hello all,

    I wrote some macros for the three points on the bed to help level it. The head moves to the correct position but it does it very slowly and all three axes are moving simultaneously. I would like the Z to move up first and then the X and Y to move into position. Any advice on how to tweak them? Here is the first one.

    GO Z10 X10 Y110; Bed level Position 1

    #104296

    Jeffeb3
    Participant

    F for speed in mm/min

    If you give it x,y, and z it will move in all directions at once.

    G0 Z10 F300; move Z at 5mm/s
    G0 X100 Y100 F1200 ; move xy at 20mm/s

    Those are in absolute coordinates (assuming you didn’t change them to relative) so it will be 10mm and 100mm away fron the origin, which is either where you started it, where you G92’ed it or where you homed it.

    2 users thanked author for this post.
    #104297

    Edward
    Participant

    Thanks for the F for speed tip. I’m not sure what you mean by absolute and relative coordinates. I home all axes and then start with the bed level position 1 macro. That takes the head to X10 and Y110 on my machine. I think you mean if I didn’t home all axes it would think wherever the head was when I start the macro is X0 Y0 Z0. Should I add G92( I think that’s home all) to the first macro so it always starts in the correct spot?

    #104298

    Jeffeb3
    Participant

    If this is right after a home, it’s probably fine. Just to be safe, you can add G90 to the top.

    If, for some reason, you had ran G91 (from some other gcode, perhaps) then G0 X10 would go ten more mm, not go to the 10 position.

    A relative move will move that much difference. So if you were at X=20 and you did G0 X10, it would go to X=20+10=30mm.

    A relative move is always based on 0,0. So if you were at X=20 and you did G0 X10, it would go to X=10.

    Especially pay attention to the Z.

    2 users thanked author for this post.
Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.