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

    Motors coupled how do I call the H command?

    Scheduled Pinned Locked Moved Solved
    General Discussion
    4
    11
    247
    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.
    • dc42undefined
      dc42 administrators @tkln
      last edited by

      @tkln when you assign multiple motors to an axis in M584, any G1 commands that refer to that axis will drive all the motors for that axis by the same amount. For example, if your machine is a Cartesian, then G91 G1 X5 will move the motors connected to drivers 0.2 and 0.3 by an amount that gives 5mm of axis movement.

      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

      tklnundefined 1 Reply Last reply Reply Quote 1
      • tklnundefined
        tkln @dc42
        last edited by

        @dc42
        So when the motors are coupled you can't control the motors individually with the G1 H1 command, right?
        Can I decouple the motors in the printing process and then use the G1 H1 command?

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

          @tkln said in Motors coupled how do I call the H command?:

          So when the motors are coupled you can't control the motors individually with the G1 H1 command, right?
          Correct.
          Can I decouple the motors in the printing process and then use the G1 H1 command?

          Yes, it's possible to use M584 to assign one of the motor to a different axis. When you've finished moving them independently you can use M584 to combine them again and use the M584 P parameter to hide the additional axis.

          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

          tklnundefined 2 Replies Last reply Reply Quote 1
          • tklnundefined tkln has marked this topic as solved
          • tklnundefined
            tkln @dc42
            last edited by

            @dc42
            Do I only have to redefine M584 or also the current, microstepping etc.?

            M350 
            M92 
            M566
            M203
            M201
            M906 
            
            droftartsundefined 1 Reply Last reply Reply Quote 0
            • droftartsundefined
              droftarts administrators @tkln
              last edited by droftarts

              @tkln The motors (on each axis) must be identical, because the values used for M350, M92, M566, M203, M201 and M906 are used for ALL motors on that axis. The only exception is the extruder axes, where each one is treated as a separate axis. So in this (your config.g from your other thread):

              M350 X16 Y16 Z16 E16 I1                                 ; configure microstepping with interpolation
              M92 X160.00 Y160.00 Z160.00 E690.00                     ; set steps per mm
              M566 X1200.00 Y1200.00 Z1200.00 E600.00                 ; set maximum instantaneous speed changes (mm/min)
              M203 X18000.00 Y18000.00 Z18000.00 E7200.00             ; set maximum speeds (mm/min)
              M201 X1000.00 Y1000.00 Z1000.00 E3000.00                ; set accelerations (mm/s^2)
              M906 X1800:1800 Y1800:1800 Z1800:1800 E1200 I80         ; set motor currents (mA) and motor idle factor in per cent
              M84 S30                                                 ; Set idle timeout
              

              Everything is correct EXCEPT M906. You can only have one value for each axis. It should be:

              M906 X1800 Y1800 Z1800 E1200 I80         ; set motor currents (mA) and motor idle factor in per cent
              

              See https://docs.duet3d.com/User_manual/Connecting_hardware/Motors_configuring#configuring-steps-and-speeds for examples of each of the Gcodes above.

              Ian

              Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

              1 Reply Last reply Reply Quote 1
              • tklnundefined
                tkln @dc42
                last edited by tkln

                @dc42
                For a better understanding, if I have coupled the axes like this:

                ; Drives
                M569 P0.0 S0                                            
                M569 P0.1 S1                                            
                M569 P0.2 S0                                            
                M569 P0.3 S1                                            
                M569 P0.4 S0                                            
                M569 P0.5 S0                                            
                M569 P1.0 S0                                            
                
                M584 X0.4:0.5 Y0.2:0.3 Z0.0:0.1 E1.0
                

                How do I have to name the axes if I want to decouple them or can I name them whatever I want?
                Here's an example of how I would do it in a gcode file:

                M584 X0.4 U0.5 Y0.2 V0.3 Z0.0 W0.1 E1.0 
                G91
                G1 X-150 Y-150 Z-150 U-150 V-150 W-150 E0.0 F500.0 H2
                G1 X-20.4318 Y-20.4318 Z-1.63587 U-1.63587 V16.7082 W16.7082 E0.0 F300.0 H2
                G1 X20.4318 Y20.4318 Z1.63587 U1.63587 V-16.7082 W-16.7082 E0.0 F500.0 H2
                G1 X-12.4304 Y-12.4304 Z19.5077 U19.5077 V-12.4304 W-12.4304 E0.0 F300.0 H2
                G1 X12.4304 Y12.4304 Z-19.5077 U-19.5077 V12.4304 W12.4304 E0.0 F500.0 H2
                

                Do I have to define the UVW somewhere beforehand in the config or something?
                I want that driver:
                P0.0 = X
                P0.1 = Y
                P0.2 = Z
                P0.3 = U
                P0.4 = V
                P0.5 = W

                😊

                deckingmanundefined 1 Reply Last reply Reply Quote 0
                • deckingmanundefined
                  deckingman @tkln
                  last edited by deckingman

                  @tkln said in Motors coupled how do I call the H command?:
                  ..............................

                  I want that driver:
                  P0.0 = X
                  P0.1 = Y
                  P0.2 = Z
                  P0.3 = U
                  P0.4 = V
                  P0.5 = W

                  For the above to work, use M584 X0.0 Y 0.1 Z0.2 U0.3 V0.4 W0.5 P6. The "P6" is important. Without that (unless something has changed since I had a CoreXYUVAB) only the 3 main axes (X,Y and Z) will show up. Once you have done what you need to do with the individual axes, remap the motors to X Y and Z using M584 but use the P3 to hide the additional U V and W axes.

                  Ian
                  https://somei3deas.wordpress.com/
                  https://www.youtube.com/@deckingman

                  tklnundefined 1 Reply Last reply Reply Quote 1
                  • tklnundefined
                    tkln @deckingman
                    last edited by

                    @deckingman thanks 😉

                    Do I have to adjust something like current, ... in the config file for UVW?

                    M350 X16 U16 Y16 V16 Z16 W16 E16 I1                      						; configure microstepping with interpolation (*)
                    M92 X160.00 U160.00 Y160.00 V160.00 Z160.00 W160.00 E690.00                     ; set steps per mm (*)
                    M566 X1200.00 U1200.00 Y1200.00 V1200.00 Z1200.00 W1200.00 E600.00              ; set maximum instantaneous speed changes (mm/min) (*)
                    M203 X18000.00 U18000.00 Y18000.00 V18000.00 Z18000.00 W18000.00 E7200.00       ; set maximum speeds (mm/min) (*)
                    M201 X1000.00 U1000.00 Y1000.00 V1000.00 Z1000.00 W1000.00 E3000.00             ; set accelerations (mm/s^2) (*)
                    M906 X1600 U1600 Y1600 V1600 Z1600 W1600 E1200 I80        						; set motor currents (mA) and motor idle factor in per cent (*)
                    M84 S30                                        
                    
                    dc42undefined 1 Reply Last reply Reply Quote 0
                    • dc42undefined
                      dc42 administrators @tkln
                      last edited by dc42

                      @tkln yes, you need to specify at least the current for UVW in M906 and the steps/mm for UVW in M92 (as you have done). You can only do this after you have created the UVW axes in M584.

                      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

                      tklnundefined 1 Reply Last reply Reply Quote 1
                      • tklnundefined
                        tkln @dc42
                        last edited by

                        @dc42 thanks that works ❤

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