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

    Using Duet 2 and DueX5 just to control motor speeds?

    Scheduled Pinned Locked Moved
    Using Duet Controllers
    2
    5
    262
    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.
    • Jaspergundefined
      Jasperg
      last edited by

      I am not sure if what I am trying to do is possible. I have 5 (for now, I would like to use 6 or 8 ) stepper motors working together on a design I am making. This is not a printer, they are free to rotate independently, I just want to coordinate them together, for different effects.

      I currently have some Python code running on a Raspberry pi that is calculating a speed for each motor based on inputs from an xbox controller, at the moment it is sending the required motor speeds to an Arduino with stepper drivers attached.

      I am hoping to use my Duet 2 with a DueX5 instead of the Arduino. Would it be possible to set up each motor on the Duet 2 + x5 to just run, and continually adjust each of the motor speeds using Gcode? (sent from the Raspberry Pi)

      It seems like this might be possible, but I cannot quite figure it out, as most information I am reading is assuming you will be building a printer and need end stops etc. Also I cannot tell from what I read If it is possible to use gcode just to input a speed, without it being linked to a location and an acceleration. All I need is to be able to set the speed of each motor, as all the other calculations are done on the Raspberry pi

      Any hints on how to try this are much appreciated!

      o_lampeundefined 1 Reply Last reply Reply Quote 0
      • o_lampeundefined
        o_lampe @Jasperg
        last edited by o_lampe

        @jasperg
        without digging too deep into it, I'd say you can define rotary axes to have continuous moves without limits or endstops.
        See M584 R + S param
        Fake speed changes would be possible by changing steps/mm for each axis on the fly. You might need a higher 'segments/second' setting in M669 for faster reaction.
        But there might also be an 'official' way with G0 X Fnnnn?

        Jaspergundefined 1 Reply Last reply Reply Quote 0
        • Jaspergundefined
          Jasperg @o_lampe
          last edited by

          @o_lampe hey thanks for the tip! That sounds like a convincing option. I had pretty much given up on using the Duet, but I'll have one more try. I wonder if changing steps/mm while the motors are running will only come into effect after after an new movement?

          o_lampeundefined 1 Reply Last reply Reply Quote 0
          • o_lampeundefined
            o_lampe @Jasperg
            last edited by o_lampe

            @jasperg said in Using Duet 2 and DueX5 just to control motor speeds?:

            I wonder if changing steps/mm while the motors are running will only come into effect after after an new movement?

            That's right, but with the M669 segmentation setting even an infinite track will be chopped into small pieces.
            I have good results on a duet2Wifi with 100segments/second and minimum track length of 0.1mm, just to give you a starting point.

            Jaspergundefined 1 Reply Last reply Reply Quote 0
            • Jaspergundefined
              Jasperg @o_lampe
              last edited by

              @o_lampe thank you so much for the tips! I am going try this weekend. With our your suggestions I think I would have given up.

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