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

    Microstepping pros/cons

    Scheduled Pinned Locked Moved
    Tuning and tweaking
    6
    16
    7.8k
    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
      last edited by

      @briangilbert:

      M350 X128 I100 ; Set 128x microstepping without interpolation

      After seeing your example I'm guessing I should be specifying it for XYZ axis'?

      That's correct, you are currently only increasing microstepping for the X motor. Also the I parameter should be 0 or 1.

      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
      • briangilbertundefined
        briangilbert
        last edited by

        @dc42

        Putting my hand up to help improve Wiki's if you are open to me calling you occasionally to clarify things?

        Co-creator of the Zesty Nimble direct drive extruder

        1 Reply Last reply Reply Quote 0
        • RCarlyleundefined
          RCarlyle
          last edited by

          As far as the motor itself is concerned, there's absolutely no disadvantage to finer microstepping. No loss of torque, no change in heat production, no downside whatsoever. It simply vibrates less when the step position changes, because each incremental movement is smaller. So it's quieter and motion is smoother.

          The driver also typically doesn't care, as long as you don't get into really extreme territory like if the pulse times and direction change delays get so short that it can't pick them up. Drivers with crummy chopper algorithms like the 8825 can miss some very fine low-current microsteps, which puts ripples into the print. It may be visually more appealing to have coarser evenly-spaced microsteps than very fine microsteps with repeating error ripples. But the 2660 shouldn't have that kind of issue, because it uses an adaptive chopper algorithm that monitors for missed microsteps and adjusts the decay times accordingly.

          The controller is really the main limit for microstepping. You don't want to bog down the processor with step generation. I don't know what the ARM M4F in the Duet Wifi is capable of yet, but Repetier on an 84mhz ARM M3 can handle 80 khz and Smoothie can do, err, I think 100 khz or so with its slightly faster 120 mhz ARM M3.

          At higher speeds, when the motor is inductance-limited and isn't actually reaching its target current, microstepping no longer adds any value whatsoever. You actually end up with slightly more torque at high speeds with full or half stepping. But you probably shouldn't be running 3d printers at that kind of speed.

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

            I ran some timing tests on the 1.14 firmware. With just one axis motor moving, the Duet WiFi step pulse rate tops out at 240kHz. With all 3 motors moving at the same speed (e.g. pure Z movement on a delta), the step pulse rate tops out at 130KHz. However, these figures do not allow for anything else happening at the same time, so you should aim to keep the step frequencies well below these values.

            It has just occurred to me that I can optimise the case of multiple motors moving at the same rate a little. I will implement this in the next release.

            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
            • RCarlyleundefined
              RCarlyle
              last edited by

              Remind me, do you have step doubling implemented? That's a fairly straightforward solution that ends up acting much like dynamic microstepping.

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

                Yes, the firmware switches to 2, 4 or 8x stepping when the frequency gets high enough. In my timing tests I could see on the oscilloscope that it was running at 8x.

                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
                • RCarlyleundefined
                  RCarlyle
                  last edited by

                  So, it's doing 8x pulsing to get to 130 khz? That's rather surprising.

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

                    The firmware currently switches to double stepping when the interval between step pulses falls below 70us. Then quad stepping if the average interval falls below 35us, and octal stepping below 17.5us. That figure was based on measurements using the wired Duet, and should probably be reduced for the Duet WiFi with its faster processor.

                    The main purpose of going to double etc. stepping is to reduce the number of delta movement calculations when the firmware is configured for a delta printer. Each delta calculation involves the calculation of the square root of a 60-bit number, so it is quite expensive in CPU time. Bear in mind that delta movement in RepRapFirmware does not use segmentation - except that when it switches to double etc. stepping I guess you could call that micro-segmentation.

                    In the next release, I'll probably reduce the 70us somewhat for delta movements in the Duet WiFi build, and use an even smaller value for Cartesian movements.

                    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
                    • dc42undefined
                      dc42 administrators
                      last edited by

                      I just made a few more optimisations to the step pulse generation. For non delta moves, the maximum step rate for 3 motors moving simultaneously has risen from 130kHz to 166kHz per motor (so about 500kHz total step pulse rate) , For just one motor moving, it is up from 240 to 280kHz.

                      The experimental binary is at https://dl.dropboxusercontent.com/u/19369680/DuetWiFiFirmware.bin,

                      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
                      • botundefined
                        bot
                        last edited by

                        Fantastic news. Are you seeing improvements due to the on-board FPU? These figures are approaching the performance specs of some rather pricey CNC controllers (KFLOP, to be exact), this is very exciting.

                        *not actually a robot

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