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

    Changing motor direction with 1XD board external driver stepper

    Scheduled Pinned Locked Moved Solved
    Firmware installation
    4
    15
    530
    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.
    • Omicletteundefined
      Omiclette @alankilian
      last edited by

      @alankilian I will post an image shortly. I don't think the connection is wrong since the motor can turn in both direction. The problem is that reversing the motor direction using the S parameter doesn't work...

      alankilianundefined T3P3Tonyundefined 2 Replies Last reply Reply Quote 0
      • alankilianundefined
        alankilian @Omiclette
        last edited by

        @omiclette

        Oh I get it.

        I have no idea then. Sorry.

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

        1 Reply Last reply Reply Quote 0
        • T3P3Tonyundefined
          T3P3Tony administrators @Omiclette
          last edited by

          @omiclette I agree if the motor runs both way then its probably not a wiring issue.

          What is reported when you send M569 P121.0 from the console (it should say if the driver runs forward or in reverse). then send M569 P121 S1 to reverse it (assuming you have it as in the config.g snippet above), then send M569 P121 again to report the new value. it should say its now in reverse. If that works see if the extrude and retract now work as expected.

          www.duet3d.com

          Omicletteundefined 1 Reply Last reply Reply Quote 0
          • Omicletteundefined
            Omiclette @T3P3Tony
            last edited by

            @t3p3tony said in Changing motor direction with 1XD board external driver stepper:

            M569 P121.0

            So with the following line in config.g file :

            M569 P121.0 S0 R0 T7:7:7:7 ; change enable polarity, active = disable driv

            This is what is reported from M569 P121.0 :
            6f53e8ef-7d00-4b26-aded-f900e2f2cdc7-image.png
            I have just noticed that the step timing is somewhat wrong, I don't know why it doesn't stay 7:7:7:7 us.

            If I change for S1, I get this :

            b10403b6-0ebe-4961-927a-066bb70403f5-image.png

            In both cases (S0 and S1), the "retract" jog command makes the actuator go in the direction to extrude and the "extrude" jog command makes the actuator go in the direction to retract.

            Also, when I make changes in config.g, I need to shut down and turn back on the power of the Duet 3 6HC for the Stepservo to move. I don't understand why...

            jay_s_ukundefined T3P3Tonyundefined 2 Replies Last reply Reply Quote 0
            • jay_s_ukundefined
              jay_s_uk @Omiclette
              last edited by

              @omiclette post an output of M122 B121

              Owns various duet boards and is the main wiki maintainer for the Teamgloomy LPC/STM32 port of RRF. Assume I'm running whatever the latest beta/stable build is

              Omicletteundefined 1 Reply Last reply Reply Quote 0
              • Omicletteundefined
                Omiclette @jay_s_uk
                last edited by

                @jay_s_uk said in Changing motor direction with 1XD board external driver stepper:

                M122 B121

                M122 B121
                Diagnostics for board 121:
                Duet EXP1XD firmware version 3.3 (2021-06-15 16:12:29)
                Bootloader ID: SAMC21 bootloader version 2.0 (2020-10-15b1)
                Never used RAM 5568, free system stack 2789 words
                Tasks: Move(notifyWait,0.0%,153) HEAT(delaying,0.0%,117) CanAsync(notifyWait,0.0%,64) CanRecv(notifyWait,0.0%,77) CanClock(notifyWait,0.0%,64) MAIN(running,96.5%,443) IDLE(ready,0.0%,41) AIN(delaying,3.4%,142), total 100.0%
                Last reset 00:03:42 ago, cause: power up
                Last software reset data not available
                Driver 0: position 0, 80.0 steps/mm, steps req 0 done 0
                Moves scheduled 0, completed 0, in progress 0, hiccups 0, step errors 0, maxPrep 0, maxOverdue 0, maxInc 0, mcErrs 0, gcmErrs 0
                Peak sync jitter 0/5, peak Rx sync delay 573, resyncs 0/0, no step interrupt scheduled
                VIN: 23.1V
                MCU temperature: min 24.2C, current 24.4C, max 24.7C
                Ticks since heat task active 80, ADC conversions started 111411, completed 111411, timed out 0, errs 0
                Last sensors broadcast 0x00000000 found 0 85 ticks ago, loop time 0
                CAN messages queued 20, send timeouts 0, received 2016, lost 0, free buffers 37, min 37, error reg 0
                dup 0, oos 0/0/0/0, bm 0, wbm 0, rxMotionDelay 0

                1 Reply Last reply Reply Quote 0
                • T3P3Tonyundefined
                  T3P3Tony administrators @Omiclette
                  last edited by

                  @omiclette said in Changing motor direction with 1XD board external driver stepper:

                  I have just noticed that the step timing is somewhat wrong, I don't know why it doesn't stay 7:7:7:7 us.

                  These are the timing values that are actually used, they are the closest ones possible on the 1XD larger than the one specified. They don't match exactly due to the requirement of a multiple of clock cycles to be between step/dir outputs.

                  as an aside you can just send the command in the console (e.g. M569 P121.0 S1) to test the differences, no need to upload config.g each time.

                  Can you try using G1 E10 F300 (feel free to substitute different movement amount and feedrate speed to suit your setup) and see if the direction change in M569 still makes no difference when sending G1 instead of using the UI.

                  www.duet3d.com

                  Omicletteundefined 1 Reply Last reply Reply Quote 0
                  • Omicletteundefined
                    Omiclette @T3P3Tony
                    last edited by

                    @t3p3tony Thanks for the tip! When sending a G1 E20 F1000, the motor does change direction when M569 P121.0 S1 or M569 P121.0 S0 is sent. It appears that it is the UI that does not follow the S parameter changes.

                    T3P3Tonyundefined 1 Reply Last reply Reply Quote 0
                    • T3P3Tonyundefined
                      T3P3Tony administrators @Omiclette
                      last edited by

                      @chrishamm any ideas here? the extrude/ retract buttons appear to be compensating for the change in M569 S0/1 for the extruder motor so the direction can't be changed.

                      @Omiclette can you confirm the firmware version you are running on the main board and the 1XD:

                      M115
                      M115 B121

                      Also see in DWC what version that is.

                      Also if you can upgrade to 3.4b7 on both, and upgrade DWC at the same time that would be good.

                      www.duet3d.com

                      Omicletteundefined 2 Replies Last reply Reply Quote 1
                      • Omicletteundefined
                        Omiclette @T3P3Tony
                        last edited by

                        @t3p3tony said in Changing motor direction with 1XD board external driver stepper:

                        M115

                        8e3a36dc-630f-4bc3-9144-74f38877225e-image.png
                        8356af01-f351-4ae6-b25b-6dac9f336af2-image.png
                        Ok I will try updating to 3.4b7 at the end of the day.

                        1 Reply Last reply Reply Quote 0
                        • Omicletteundefined
                          Omiclette @T3P3Tony
                          last edited by

                          @t3p3tony Hello, I just did the firmware update to 3.4b7. Changing the S parameter from S0 to S1 now changes the rotation direction of the motor controlled by the 1XD board. Thank you for your help, the issue is solved.

                          1 Reply Last reply Reply Quote 0
                          • Phaedruxundefined Phaedrux marked this topic as a question
                          • Phaedruxundefined Phaedrux has marked this topic as solved
                          • First post
                            Last post
                          Unless otherwise noted, all forum content is licensed under CC-BY-SA