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

    Toolchange script for parking extruder

    Scheduled Pinned Locked Moved
    General Discussion
    3
    7
    962
    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.
    • danny_v1undefined
      danny_v1
      last edited by

      Hello, my new x axis with a parking dual extruder is almost ready. Is it possible to make a toolchange script like this?

      {IF NEWTOOL=1}T1
      'switch to new tool and do these things
      {IF NEWTOOL=1}M109 S240 T1 ;heat right tool to 240C before moving
      {IF NEWTOOL=1}G1 F800 E-1.0
      {IF NEWTOOL=1}G1 F800 E5.0 ;Default purge
      {IF NEWTOOL=1}G4 S5 ;Stabilize Hotend's pressure dwell 5 seconds
      {IF NEWTOOL=1}G92 E0 ;Zero extruder
      {IF NEWTOOL=1}G1 F800 E-1 ;Retract
      {IF NEWTOOL=1}G1 F800
      {IF NEWTOOL=1}G91
      {IF NEWTOOL=1}G1 F12000 Z2
      {IF NEWTOOL=1}G90

      {IF NEWTOOL=0}T0
      ; switch to new tool and do these things
      {IF NEWTOOL=0}M104 S200 T1 ;let right extruder cool to 200 while unused
      {IF NEWTOOL=0}G1 F1200 E-1.0
      {IF NEWTOOL=0}G1 F1000 E5.0 ;Default purge
      {IF NEWTOOL=0}G4 S2 ;Stabilize Hotend's pressure with dwell for 2 seconds
      {IF NEWTOOL=0}G92 E0 ;Zero extruder
      {IF NEWTOOL=0}G1 F2400 E-4 ;Retract
      {IF NEWTOOL=0}G1 F12000
      {IF NEWTOOL=0}G91
      {IF NEWTOOL=0}G1 F12000 Z2
      {IF NEWTOOL=0}G90

      (This is an example from simplify3d)

      Thanks danny_v1

      1 Reply Last reply Reply Quote 0
      • dc42undefined
        dc42 administrators
        last edited by

        Have you read https://duet3d.dozuki.com/Wiki/ConfiguringRepRapFirmwareCartesianPrinter#Section_Tool_change_files ?

        Duet WiFi hardware designer and firmware engineer
        Please do not ask me for Duet support via PM or email, use the forum
        http://www.escher3d.com, https://miscsolutions.wordpress.com

        1 Reply Last reply Reply Quote 0
        • danny_v1undefined
          danny_v1
          last edited by

          Oh ok thanks!

          So if I understand it correctly I don't need the hole If instructions.

          Just for the understanding, when I do a home position on the x-axis, I also pick up Tool 0, so If the x-axis is homed Tool 0 is always attached. Then when I start a print I Do my bed leveling with a bltouch sensor which is connected with Tool 0. Then in the print is a tool change to Tool 1 and then I run tfree1.g, tpre1.g and tpost1.g. And the Tool 1 is now active. If there is a tool change back to Tool 0 I run tfree0.g, tpre0.g and tpost0.g.

          After the print I home my x-axis again and then automatically Tool 0 will attached again.

          I hope now I got it.

          Thanks

          danny_v1

          1 Reply Last reply Reply Quote 0
          • dc42undefined
            dc42 administrators
            last edited by

            Yes that all sounds correct to me. Note, the tool change files are not run if the printer has not been homed. You can also use the P parameter on the T command to specify that you don't want some of the tool change files to be run.

            Duet WiFi hardware designer and firmware engineer
            Please do not ask me for Duet support via PM or email, use the forum
            http://www.escher3d.com, https://miscsolutions.wordpress.com

            1 Reply Last reply Reply Quote 0
            • Scachiundefined
              Scachi
              last edited by

              Isn't the tfree file run of the currently active tool ?
              So when activating tool1 from tool0 it will: run tfree0.g, tpre1.g and tpost1.g ?

              dc42undefined 1 Reply Last reply Reply Quote 0
              • dc42undefined
                dc42 administrators @Scachi
                last edited by

                @scachi said in Toolchange script for parking extruder:

                Isn't the tfree file run of the currently active tool ?
                So when activating tool1 from tool0 it will: run tfree0.g, tpre1.g and tpost1.g ?

                Yes, if the firmware knows that the printer has been homed.

                Duet WiFi hardware designer and firmware engineer
                Please do not ask me for Duet support via PM or email, use the forum
                http://www.escher3d.com, https://miscsolutions.wordpress.com

                1 Reply Last reply Reply Quote 0
                • danny_v1undefined
                  danny_v1
                  last edited by

                  Ok I will try it. Thank you very much!

                  Kind regards

                  danny_v1

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