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

    run two stepper motor at the same time with different speeds

    Scheduled Pinned Locked Moved
    Gcode meta commands
    6
    6
    490
    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.
    • adistrundefined
      adistr
      last edited by

      Hi,
      I want to run two stepper motor at the same time with different speeds (F) in the same command. How can I do it?

      Adi

      JoergS5undefined fcwiltundefined alankilianundefined sinned6915undefined 4 Replies Last reply Reply Quote 0
      • JoergS5undefined
        JoergS5 @adistr
        last edited by

        @adistr it's not the answer, but depending on what your use case is, a solution may be to use a gear attached to the stepper and use stepper's rotation as one rotation and gear's as the other. This would assure that they are in sync as additonal advantage.

        1 Reply Last reply Reply Quote 0
        • fcwiltundefined
          fcwilt @adistr
          last edited by

          @adistr said in run two stepper motor at the same time with different speeds:

          Hi,
          I want to run two stepper motor at the same time with different speeds (F) in the same command. How can I do it?

          Adi

          Define "speed". You cannot have two different F parameters but you can get different stepper behavior if you tell the firmware a "lie".

          Imagine that you do this with two identical steppers on axes A and B:

          M92 A100 B200

          Frederick

          Printers: a E3D MS/TC setup and a RatRig Hybrid. Using Duet 3 hardware running 3.4.6

          1 Reply Last reply Reply Quote 0
          • alankilianundefined
            alankilian @adistr
            last edited by

            @adistr You can do this easily by performing a 2D move using the G1 code.

            Imagine you have one motor connected to the "X" motor driver and another connected to the "Y" motor driver.

            Then, if you move 100 steps in X and 50 steps in Y, since the Duet firmware wants to keep the motors coordinated and wants to draw a straight line, it will step the Y motor at half the speed as the X motor and they sill stop at the same time.

            If you are not driving an actual 3D printer, you might want to use the G91 command at the beginning of your motions to set "relative" motion mode.

            Then you can do:
            G1 x100 Y50
            G1 X100 Y50
            G1 X100 Y50
            And your motors will move each time.

            If you use G90 "Absolute" mode your first G1 X100 Y50 will move the motors to 100 and 50 and all the other G1 X100 Y50 commands won't move the motors at all since the machine is already at X=100 Y=50 so there's no move to be done.

            Give it a try and tell us a little more about what you are building!

            SeemeCNC Rostock Max V3 converted to V3.2 with a Duet2 Ethernet Firmware 3.2 and SE300

            1 Reply Last reply Reply Quote 1
            • Phaedruxundefined
              Phaedrux Moderator
              last edited by

              I think you'll have to wait for firmware 3.5 which aims to implement independent motion systems.

              Z-Bot CoreXY Build | Thingiverse Profile

              1 Reply Last reply Reply Quote 0
              • sinned6915undefined
                sinned6915 @adistr
                last edited by

                @adistr have you tried playing with the steprates / u-step settings in the config?
                in theory you could give one motor assignment twice as many u-steps as the other and it should more 2x as fast if the same deg/step as the other motor.

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