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

    Wrong position after homing axes

    Scheduled Pinned Locked Moved
    General Discussion
    3
    54
    3.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.
    • CoolM8undefined
      CoolM8
      last edited by

      This is my full config.g:

      ; General preferences
      M111 S1 ; Debugging off
      G21 ; Work in millimetres
      G90 ; Send absolute coordinates...
      M83 ; ...but relative extruder moves
      M555 P2 ; Set firmware compatibility to look like Marlin
      M564 H0 S1

      M208 X0 Y0 Z0 S1 ; Set axis minima
      M208 X180 Y180 Z205 S0 ; Set axis maxima
      M669 K0

      ; Endstops
      M574 X1 Y1 S0 ; Define active low and unused microswitches
      M574 Z1 S2
      M558 P1 H5 F120 T6000
      M557 X0:180 Y15:180 S20 ; Define mesh grid
      G31 P500 X40 Y0 Z0.35 ; Set Z probe trigger value, offset and trigger height

      ; Drives
      M569 P0 S0 ; Drive 0 goes forwards
      M569 P1 S1 ; Drive 1 goes forwards
      M569 P2 S0 ; Drive 2 goes forwards
      M569 P3 S1 ; Drive 3 goes forwards
      M350 X32 Y32 Z8 E16 I0 ; Configure microstepping without interpolation
      M92 X157.4804 Y157.4804 Z533.3333 E832 ; Set steps per mm
      M566 X1200 Y1200 Z480 E120 ; Set maximum instantaneous speed changes (mm/min)
      M203 X8100 Y8100 Z300 E1200 ; Set maximum speeds (mm/min)
      M201 X500 Y500 Z100 E250 ; Set accelerations (mm/s^2)
      M906 X1200 Y1200 Z1100 E1100 I30 ; Set motor currents (mA) and motor idle factor in per cent
      M84 S30 ; Set idle timeout

      ; Heaters
      M143 S290; Set maximum heater temperature to 310C
      M301 H0 S1.00 P10 I0.1 D200 T0.4 W180 B30 ; Use PID on bed heater (may require further tuning)
      M305 P0 T100000 B4138 C0 R4700 ; Set thermistor + ADC parameters for heater 0
      ;M305 P1 R4700 T100000 B4388
      M305 P1 X200

      ; Tools
      M563 P0 D0 H1 ; 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

      ; Network
      M550 PUltimaker ; Set machine name
      M552 S1 ; Enable network and acquire dynamic address via DHCP

      ; Fans
      M106 P0 S1 I0 F500 H1 T45 ; Set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned on
      ;M106 P1 S1 I0 F500 H-1 ; Set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned off
      ;M106 P2 S1 I0 F500 H-1 ; Set fan 2 value, PWM signal inversion and frequency. Thermostatic control is turned off

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

        And homing files?

        Z-Bot CoreXY Build | Thingiverse Profile

        1 Reply Last reply Reply Quote 0
        • Vetiundefined
          Veti
          last edited by

          @CoolM8 said in Wrong position after homing axes:

          M564 H0 S1

          i have pointed out to you earlier that this should not be in the config. why do you insist on having that in your config?

          1 Reply Last reply Reply Quote 0
          • CoolM8undefined
            CoolM8
            last edited by

            @Veti
            I had M564 H0 in there, because i was used to be able to move the printhead without homed axes with the original printer hardware. When I remove completely, I cannot even home any of my axes, always getting: G0/G1: insufficient axes homed. This is also the case when I have M546 H1 S1.

            homeX:
            ; Lift Z relative to current position
            G91
            G1 Z5 F6000
            G90

            ; Move quickly to X axis endstop and stop there (first pass)
            G1 X-210 F1200 S1

            ; Go back a few mm
            G91
            G1 X5 F6000
            G90

            ; Move slowly to X axis endstop once more (second pass)
            G1 X-210 F360 S1

            ; Lower Z again
            G91
            G1 Z-5 F6000
            G90

            homeY:
            ; Lift Z relative to current position
            G91
            G1 Z5 F6000
            G90

            ; Move quickly to Y axis endstop and stop there (first pass)
            G1 Y-210 F1800 S1

            ; Go back a few mm
            G91
            G1 Y5 F6000
            G90

            ; Move slowly to X axis endstop once more (second pass)
            G1 Y-210 F360 S1

            ; Lower Z again
            G91
            G1 Z-5 F6000
            G90

            homeZ:
            ; Lift Z relatively to current position
            G91
            G1 Z5 F6000 S2

            ; Back to absolute positioning
            G90

            ; Go to first bed probe point and home the Z axis
            G1 X100 Y100 F6000
            G30

            ; Uncomment the following lines to lift Z after probing
            ;G91
            ;G1 Z5 F100
            ;G90

            homeall:
            ; homeall.g
            ; called to home all axes
            ;
            ; generated by RepRapFirmware Configuration Tool on Wed Apr 19 2017 22:18:05 GMT+0200 (W. Europe Daylight Time)

            ; Relative positioning
            G91

            ; Lift Z
            G1 Z5 F6000

            ; Course home X and Y
            G1 X-210 Y-210 F1800 S1

            ; Move away from the endstops
            G1 X5 Y5 F6000

            ; Fine home X and Y
            G1 X-210 Y-210 F360 S1

            ; Absolute positioning
            G90

            ; Go to first bed probe point and home Z
            G1 X100 Y100 F1800

            G30

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

              Thanks for providing the homing files. Makes it much easier.

              @CoolM8 said in Wrong position after homing axes:

              G0/G1: insufficient axes homed.

              This is due to the Z moves to lift the print head above the bed before the axis are homed. M564 H0 is the brute force way of removing the check.

              Trying to run homez before x and y are homed means that the G1 XY move you have in there has no reference point. X and Y must be homed before homing Z.

              To correct the insufficient homed axis error without using M564 H0 you must add S2 to the Z moves in your homing files.

              For example:

              homeX:
              ; Lift Z relative to current position
              G91
              G1 Z5 F6000
              G90
              
              ; Move quickly to X axis endstop and stop there (first pass)
              G1 X-210 F1200 S1
              
              ; Go back a few mm
              G91
              G1 X5 F6000
              G90
              
              ; Move slowly to X axis endstop once more (second pass)
              G1 X-210 F360 S1
              
              ; Lower Z again
              G91
              G1 Z-5 F6000
              G90
              

              Would become:

              homeX:
              ; Lift Z relative to current position
              G91
              G1 Z5 F6000 S2
              G90
              
              ; Move quickly to X axis endstop and stop there (first pass)
              G1 X-210 F1200 S1
              
              ; Go back a few mm
              G91
              G1 X5 F6000
              G90
              
              ; Move slowly to X axis endstop once more (second pass)
              G1 X-210 F360 S1
              
              ; Lower Z again
              G91
              G1 Z-5 F6000 S2
              G90
              

              Note the S2 on the Z move to raise and lower the print head.

              The same would apply to the homey, homez and homeall files.

              Here's a check list to go through to ensure that homing works properly.

              • 0,0 places the nozzle on the front left corner of the print surface
              • if the endstop position is beyond 0,0 the axis minima should be negative, this can help account for any offset and keep parts properly positioned on the bed. This means if the nozzle is at the corner of the bed but still needs to move 10mm to the left to trigger the endstop, your axis minima for X is -10.
              • X+ moves to the right, Y+ moves to the back
              • homing direction moves towards the endstops
              • The probe should be positioned so that it is in the middle of the print surface before the G30 command
              • the XY probe offset and Z trigger height should be measured and inputted into G31 in config.g

              Z-Bot CoreXY Build | Thingiverse Profile

              1 Reply Last reply Reply Quote 0
              • CoolM8undefined
                CoolM8
                last edited by

                Yes, if I add S2 to my Z-axis movement, I can again properly home X and Y.
                But G30 still throws the same error when running homeZ or homeAll.

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

                  @CoolM8 after you home x and y, what happens if you send this manually?

                  G90
                  G1 X100 Y100 F1800
                  G30

                  Z-Bot CoreXY Build | Thingiverse Profile

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

                    Do you meet the points I mentioned?

                    Z-Bot CoreXY Build | Thingiverse Profile

                    CoolM8undefined 1 Reply Last reply Reply Quote 0
                    • CoolM8undefined
                      CoolM8 @Phaedrux
                      last edited by

                      Yes, everything is configured as you stated in your check list.

                      The command G1 X100 Y100 F1800 moves the print head to the center.
                      G30 throws the error:

                      G30
                      Error: G0/G1: insufficient axes homed
                      
                      1 Reply Last reply Reply Quote 0
                      • Phaedruxundefined
                        Phaedrux Moderator
                        last edited by

                        That's really odd. And that's after x and y are homed? Do they show as homed?

                        Can you send G92 Z10 before you send G30?

                        Change Z10 for whatever appears to be close.to the actual z axis height at the time.

                        Z-Bot CoreXY Build | Thingiverse Profile

                        1 Reply Last reply Reply Quote 0
                        • Vetiundefined
                          Veti
                          last edited by

                          you made a lot of manual changes to the files from the configurator and changed the order of them.

                          i would suggest you input your parameters in the configurator again and replace all files with the generated ones.

                          1 Reply Last reply Reply Quote 1
                          • CoolM8undefined
                            CoolM8
                            last edited by

                            @Phaedrux said in Wrong position after homing axes:

                            G92 Z10

                            If I run this before G30, no error is thrown. But the behavior with G30 is still the same: Strange movement in X and wrong placement in the end.

                            @Veti
                            Might be a good idea, I will try that tomorrow.

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

                              Just occured to me... Do you have a deployprobe.g and retractprobe.g file in the /sys folder? If so delete them.

                              Z-Bot CoreXY Build | Thingiverse Profile

                              1 Reply Last reply Reply Quote 1
                              • CoolM8undefined
                                CoolM8
                                last edited by

                                Well, that was it. Now it seems to be working correctly.

                                Funny, as longer as it takes to solve a problem, the simpler the solution is.

                                Thank you very much for your support.

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

                                  I don't know why it didn't occur to me sooner honestly.

                                  This is why it helps to see every file from the sys folder at once. Get a complete picture.

                                  If you'd followed vetis advice and torched the folder and redid the files you'd have the same result.

                                  Z-Bot CoreXY Build | Thingiverse Profile

                                  1 Reply Last reply Reply Quote 0
                                  • Vetiundefined
                                    Veti
                                    last edited by

                                    good catch. phaedrux

                                    but out of curiosity. why did you put movement commands into your deployprobe.g ?

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

                                      @Veti It doesn't actually have to have any movement commands in it. I'm not sure exactly what the mechanism here is, but when the files exist when using a probe that doesn't require them you get weird behaviour.

                                      Z-Bot CoreXY Build | Thingiverse Profile

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