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

    Swapping 0 location

    Scheduled Pinned Locked Moved
    Tuning and tweaking
    2
    2
    119
    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.
    • Tryptamineundefined
      Tryptamine
      last edited by

      I somehow calibrated my printer s.t. The 0 location is rear right.
      I want to be it at the front left.

      I try to switch the configuration but I do not get it to work.

      The old, working stuff is:

      ; Drives
      M569 P0 S1                                         ; physical drive 0 goes forwards
      M569 P1 S1                                         ; physical drive 1 goes forwards
      M569 P2 S1                                         ; physical drive 2 goes forwards
      M569 P3 S0                                         ; physical drive 3 goes forwards
      M584 X0 Y1 Z2:4 E3                                   ; set drive mapping
      M350 X16 Y16 Z16 E16 I1                            ; configure microstepping with interpolation
      M92 X160.00 Y160.00 Z400.00 E420.00                ; set steps per mm
      M566 X900.00 Y900.00 Z60.00 E1200.00               ; set maximum instantaneous speed changes (mm/min)
      M203 X18000.00 Y18000.00 Z1000.00 E18000.00          ; set maximum speeds (mm/min)
      M201 X1200.00 Y1200.00 Z20.00 E2000.00             ; set accelerations (mm/s^2)
      M906 X1000 Y1000 Z800 E1000 I30                    ; set motor currents (mA) and motor idle factor in per cent
      M84 S30                                            ; Set idle timeout
      
      ; Axis Limits
      M208 X0 Y0 Z0 S1                                   ; set axis minima
      M208 X345 Y305 Z290 S0                             ; set axis maxima
      
      ; Endstops
      M574 X1 S1 P"xstop"                                ; configure switch-type (e.g. microswitch) endstop for high end on X via pin xstop
      M574 Y1 S1 P"ystop"                                ; configure switch-type (e.g. microswitch) endstop for high end on Y via pin ystop
      M574 Z1 S2                                         ; configure Z-probe endstop for low end on Z
      
      ; Z-Probe
      M950 S0 C"exp.heater3"                             ; create servo pin 0 for BLTouch
      M558 P9 C"^zprobe.in" H5 F120 T12000               ; set Z probe type to bltouch and the dive height + speeds
      G31 P500 X28 Y9 Z1                                 ; set Z probe trigger value, offset and trigger height
      M557 X70:370 Y15:314 P4                           ; define mesh grid
      
      ; Heaters
      M308 S0 P"e1temp" Y"thermistor" T105526 B4138      ; configure sensor 0 as thermistor on pin e1temp (bedtemp BROKEN)
      M950 H0 C"bedheat" T0                              ; create bed heater output on bedheat and map it to sensor 0
      ;M307 H1 A1123.6 C133.0 D3.5 S0.40 V23.9 B0
      M307 H1 R10.976 K0.652:0.000 D2.65 E1.35 S0.10 B0 V24.0
      
      M140 H0                                            ; map heated bed to heater 0
      M143 H0 S120                                       ; set temperature limit for heater 0 to 120C
      M308 S1 P"e0temp" Y"thermistor" T103901 B4138      ; configure sensor 1 as thermistor on pin e0temp
      M950 H1 C"e0heat" T1                               ; create nozzle heater output on e0heat and map it to sensor 1
      M143 H1 S280                                       ; set temperature limit for heater 1 to 280C
      
      
      ;M301 H0 P131.9 I1.423 D566.0
      
      ; Fans
      M950 F0 C"fan0" Q500                               ; create fan 0 on pin fan0 and set its frequency
      M106 P0 S0 H-1                                     ; set fan 0 value. Thermostatic control is turned off
      M950 F1 C"fan1" Q500                               ; create fan 1 on pin fan1 and set its frequency
      M106 P1 S1 H1 T120                                 ; set fan 1 value. Thermostatic control is turned on
      
      ; Tools
      M563 P0 D0 H1 F0                                   ; define tool 0
      G10 P0 X0 Y0 Z0                                    ; set tool 0 axis offsets
      G10 P0 R0 S0                                       ; set initial tool 0 active and standby temperatures to 0C
      
      ; Custom settings are not defined
      
      ; Miscellaneous
      M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; set voltage thresholds and actions to run on power loss
      
      

      I generated a new RepRap config with endstops located at the axis minima:

      
      ; Drives
      M569 P0 S1                                         ; physical drive 0 goes forwards
      M569 P1 S1                                         ; physical drive 1 goes forwards
      M569 P2 S1                                         ; physical drive 2 goes forwards
      M569 P3 S1                                         ; physical drive 3 goes forwards
      M584 X0 Y1 Z2 E3                                   ; set drive mapping
      M350 X16 Y16 Z16 E16 I1                            ; configure microstepping with interpolation
      M92 X160.00 Y160.00 Z400.00 E420.00                ; set steps per mm
      M566 X900.00 Y900.00 Z60.00 E1200.00               ; set maximum instantaneous speed changes (mm/min)
      M203 X18000.00 Y18000.00 Z180.00 E1200.00          ; set maximum speeds (mm/min)
      M201 X1200.00 Y1200.00 Z20.00 E2000.00             ; set accelerations (mm/s^2)
      M906 X1000 Y1000 Z800 E1000 I30                    ; set motor currents (mA) and motor idle factor in per cent
      M84 S30                                            ; Set idle timeout
      
      ; Axis Limits
      M208 X0 Y0 Z0 S1                                   ; set axis minima
      M208 X345 Y305 Z290 S0                             ; set axis maxima
      
      ; Endstops
      M574 X1 S1 P"xstop"                                ; configure switch-type (e.g. microswitch) endstop for low end on X via pin xstop
      M574 Y1 S1 P"ystop"                                ; configure switch-type (e.g. microswitch) endstop for low end on Y via pin ystop
      M574 Z1 S2                                         ; configure Z-probe endstop for low end on Z
      
      ; Z-Probe
      M950 S0 C"exp.heater3"                             ; create servo pin 0 for BLTouch
      M558 P9 C"^zprobe.in" H3 F180 T18000               ; set Z probe type to bltouch and the dive height + speeds
      G31 P500 X28 Y9 Z1                                 ; set Z probe trigger value, offset and trigger height
      M557 X15:215 Y15:195 S20                           ; define mesh grid
      
      ; Heaters
      M308 S0 P"e1temp" Y"thermistor" T105526 B4138      ; configure sensor 0 as thermistor on pin e1temp (bedtemp BROKEN)
      M950 H0 C"bedheat" T0                              ; create bed heater output on bedheat and map it to sensor 0
      ;M307 H1 A1123.6 C133.0 D3.5 S0.40 V23.9 B0
      M307 H1 R10.976 K0.652:0.000 D2.65 E1.35 S0.10 B0 V24.0
      
      M140 H0                                            ; map heated bed to heater 0
      M143 H0 S120                                       ; set temperature limit for heater 0 to 120C
      M308 S1 P"e0temp" Y"thermistor" T103901 B4138      ; configure sensor 1 as thermistor on pin e0temp
      M950 H1 C"e0heat" T1                               ; create nozzle heater output on e0heat and map it to sensor 1
      M143 H1 S280                                       ; set temperature limit for heater 1 to 280C
      
      ; Fans
      M950 F0 C"fan0" Q500                               ; create fan 0 on pin fan0 and set its frequency
      M106 P0 S0 H-1                                     ; set fan 0 value. Thermostatic control is turned off
      M950 F1 C"fan1" Q500                               ; create fan 1 on pin fan1 and set its frequency
      M106 P1 S1 H1 T120                                 ; set fan 1 value. Thermostatic control is turned on
      
      ; Tools
      M563 P0 D0 H1 F0                                   ; define tool 0
      G10 P0 X0 Y0 Z0                                    ; set tool 0 axis offsets
      G10 P0 R0 S0                                       ; set initial tool 0 active and standby temperatures to 0C
      
      ; Custom settings are not defined
      
      ; Miscellaneous
      M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; set voltage thresholds and actions to run on power loss
      
      

      And now when homing, axis are moving in the wrong directions. So they are going where there is no endstop.

      Do i additionally have to invert my Motors?

      My endstops are on the front left side of my printer.
      Here should also be the origin, X pointing to the right, y to the back, and z upwards, generating a right-handed coordinate system.

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

        @tryptamine yes you will need to invert the X and Y motor directions, which you can do with the M569 commands - change S1 to S0 for those two motors.

        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 1
        • First post
          Last post
        Unless otherwise noted, all forum content is licensed under CC-BY-SA