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

    Utilize unused I/O pins to jog CNC-spindel

    Scheduled Pinned Locked Moved
    Firmware wishlist
    5
    10
    988
    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.
    • radiomodellundefined
      radiomodell
      last edited by

      I am using Duet 3D Ethernet 1.04 in combination with DWC to control my CNC-mill. During jogging to zero-position of workpiece with the spindle I have to keep focus on not moving to far and crash by clicking the wrong jog button in DWC and the tool position of the mill at the same time.

      Thus i would appreciate a solution to jog my CNC-mill via unused I/O-pins. Axis should move as long as the input is triggered. Parameters should be : I/O-pin, axis to operate, direction of rotation and feed rate.

      Are other solutions like jog-wheel under development?

      Hermann

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

        Yes there is a solution being developed.

        If you want to build something yourself, the simplest approach is probably to take a 3.3V Arduino, connect the jog switches to it, and have it send GCode commands through the PanelDue port.

        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 1
        • frank26080115undefined
          frank26080115
          last edited by

          Idea: does DWC support arrow key inputs yet? javascript can do that really easily.

          it should be trivial to have a modal jogging dialog that can detect arrow key presses, and buy one of these

          alt text

          idea 2:

          If you want a really cheap solution right now, use https://duet3d.dozuki.com/Wiki/Gcode#Section_M581_Configure_external_trigger

          It only detects edges (presses, not holding) but that means you can get really clever, wire your buttons not to ground, but take an unused PWM pin, generate 50% duty cycle on the PWM pin.

          This means while your button is held down, there will be repeated edges to trigger the macro files in your firmware. Your macro files will just have G0 or G1 moves that are really short distances

          1 Reply Last reply Reply Quote 0
          • radiomodellundefined
            radiomodell
            last edited by

            Thanks for your reply's.
            @frank26080115 Modifying java script would be one solution. I did some modification on DWC1 but it was hard for me because I am not familiar with that huge project. I run DWC on an PC and a keyboard is available.
            @dc42 I will check effort to realize your "Arduino" solution. But I prefer standard instead of special solution. If there is something coming up I will be patient and give it a try.

            Hermann

            1 Reply Last reply Reply Quote 0
            • radiomodellundefined
              radiomodell
              last edited by

              Here is a piece of software as DC42 suggested. Thanks! An Arduino Nano is connected to the Panel-Due serial interface. Hidden in a box it works to move the tool head of my CNC-Mill controlled by Duet2 Ethernet.

              Jog2.jpg Jog1.jpg

              Arduino is 5 V, Duet2 interface is 3.3V. Serial connection is done via 3,3 V to 5 V level shifter!
              This line is added to my config.g : M575 P1 B57600 S0 to set communication without CRC check.

              Push button for directions, continuous move(Fortl.), homing and a switch to start jog mode in general are connected to the input pins of Arduino.

              Pushing a "direction button" moves the head a step with the configured distance. Pressing the "Fortl.(Continuous)" button simultaneous with a "direction button" moves the tool head continuously as long as both buttons are down.
              A "Home" button does the expected job.
              Values for distance, feed rate and timers can be modified to match software to your machine.
              A limitation at my machine: Continuous moves are singel steps fired continuously by Arduino. First steps fired are slowed down at the end a little bit until enough commands are buffered. Movement sounds a bit strange.

              I transferred this code is to Arduino via "B4R" form Anywhere Software. Download of B4R is free.

              B4RNanoJog.b4r.txt
              B4R needs extension ".B4R". Please remove extension ".TXT" from filname.

              Enjoy.

              Hermann

              Skysurferundefined FelixHundefined 2 Replies Last reply Reply Quote 2
              • Skysurferundefined
                Skysurfer @radiomodell
                last edited by

                @radiomodell I've just put together a WorkBee router with an ethernet Duet. The ability to add either keyboard moves or a pendant is sorely lacking, IMO. I also want an M6 (manual toolchange) facility in the programme. I'm still looking around for options... the board isn't exactly cheap. Running seperate programmes for each tool is painful in the extreme... 😞

                1 Reply Last reply Reply Quote 0
                • radiomodellundefined
                  radiomodell
                  last edited by

                  @Skysurfer Home build external Jog control is very helpful moving spindel head.
                  For CNC - Gcode generation I use Estlcam. Here it is easy to add commands for tool change.
                  Here is an extract of Tool change section in Estlcam.

                  M5
                  G54
                  G0 X5 Y5 Z220
                  T<t> P0
                  M291 S2 R"Werkzeugwechsel" P"Werkzeug Nr. <t> , <n>, Durchnesser : <d> mm , Vorschub:<f> einspannen"
                  M3 S<s>
                  G55
                  

                  Estlcam replaces the <t> parameter by tool number. <s> parameter is value of spindle rpm if needed.
                  Duet moves tool head to my workpiece change position and stops execution of file and displays a message box. Selectin "OK" button continues execution of work with new tool.
                  This is my solution to generate single G-Code file doing work with more than one tool.

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

                    See also this post and thread https://forum.duet3d.com/post/151672.

                    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
                    • FelixHundefined
                      FelixH @radiomodell
                      last edited by

                      @radiomodell wow, that is fantastic! Don't you have a tutorial on how to build one? This some of the things my Duet-driven Workbee is missing...

                      1 Reply Last reply Reply Quote 0
                      • radiomodellundefined
                        radiomodell
                        last edited by

                        @FelixH Sorry, there is no tutorial. What I used is one Box, some pushbutton , one switch, a level shifter and an Arduino Nano with some software. The software you can find in my post above. Inside software you find description what pins to use.

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