Duet3D Logo Duet3D
    • Tags
    • Documentation
    • Order
    • Register
    • Login

    CNC Pause and Resume config files

    Scheduled Pinned Locked Moved
    Gcode meta commands
    3
    44
    1.7k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Nightowlundefined
      Nightowl @OwenD
      last edited by

      This post is deleted!
      1 Reply Last reply Reply Quote 0
      • Nightowlundefined
        Nightowl
        last edited by Nightowl

        Well, I think I've got it, but there may be a tweak I could use to improve it, but as I've only got one spindle/tool this will probably do. This pause.g file works and saves the spindle speed to the defined variable:

        set global.savedSpindleSpeed = spindles[0].active
        echo "Spindle speed saved at " ^ {global.savedSpindleSpeed} ^ "RPM"
        G1 Z{max(move.axes[2].userPosition+5,move.axes[2].max-5)} F2400 ; move the Z axis to a safe height		
        G0 X273.5 Y560 ; move XY to a safe place
        M5 ; turn the spindle off
        

        ...and the resume.g file turns the spindle back on, although I think there are a few spurious lines in it now. I'll deal with that in the morning!

        Thanks @OwenD and @dc42 for your help with this 👍 👍

        1 Reply Last reply Reply Quote 0
        • Nightowlundefined
          Nightowl
          last edited by

          This post is deleted!
          1 Reply Last reply Reply Quote 0
          • Nightowlundefined
            Nightowl
            last edited by

            This post is deleted!
            1 Reply Last reply Reply Quote 0
            • First post
              Last post
            Unless otherwise noted, all forum content is licensed under CC-BY-SA