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

    G32 doesnt save after True Bed Leveling

    Scheduled Pinned Locked Moved
    General Discussion
    6
    63
    2.6k
    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.
    • johnyundefined
      johny @droftarts
      last edited by johny

      @droftarts Yes and no, i removed the G28 after the G32 to test and the behavior is the same but even if the Z gets homed in the center it shouldn't affect the bed tilt; the bed should keep leveled between left and right; homing will affect both Z axis and not only 1.
      Without mesh compensation, the G32 should level the 2 Z axis
      Edit: my bed is a thick 8mm aluminum block (not easy to bend)

      droftartsundefined 1 Reply Last reply Reply Quote 0
      • droftartsundefined
        droftarts administrators @johny
        last edited by

        @johny You have a G28 at the beginning, too! The offset it the same both sides, and it only shows after you've homed, QED your bed isn't flat.

        Ian

        Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

        1 Reply Last reply Reply Quote 0
        • fcwiltundefined
          fcwilt @johny
          last edited by fcwilt

          @johny

          You can use this sort of code to keep leveling the bed until a desired result is obtained or a specified number of attempts have been made.

          Doing a fixed number of repeats with no checking assumes things are working. The code below insures it actually is working.

          Note that this code was taken from a printer with three Z steppers, you would just change the three G30s to two.

          var success = false
          
          while true
            ; run leveling pass
          
            G30 P0 X-145 Y-65 Z-99999 
            G30 P1 X0    Y100 Z-99999 
            G30 P2 X145  Y-65 Z-99999 S3
          
            if move.calibration.initial.deviation < 0.02
              set var.success = true
              break
          
            ; check pass limit - exit loop if pass limit reached
          
            if iterations = 5
              break
          
          ; --- check for failure ---
          
          if !var.success
            set var.msg = "Unable to level bed - pass limit reached"
          
            M291 R{var.msg} P"Aborting" S2
            abort var.msg
          
          

          Printers: a small Utilmaker style, a small CoreXY and a E3D MS/TC setup. Various hotends. Using Duet 3 hardware running 3.4.6

          johnyundefined 1 Reply Last reply Reply Quote 0
          • johnyundefined
            johny @fcwilt
            last edited by

            @fcwilt After the first iteration the level is ok the problem is that every time it calibrates it doesn't fix the calibration.
            Example:
            1 macro with 2 calibrations

            • 1º iteration detects 0,6mm difference and adjust
            • 2º iteration detects only 0,01 difference
              I would assume its leveled

            Run the macro again

            • 1º iteration detects 0,6mm difference and adjust
            • 2º iteration detects only 0,01 difference

            It doesn't make any sense because this is a non-ending loop, after successful calibration if I run it again it will always detect the same difference.

            @droftarts I don't understand how the small wobble of 0,01mm on a 6mm plate makes a 0,6mm difference between the 2 Z leadscrews and keeps this difference after calibration. Even if my bed was completely off the G32 should calibrate between the 2 led screws no? Btw i am not speaking about offset

            droftartsundefined infiniteloopundefined 2 Replies Last reply Reply Quote 0
            • droftartsundefined
              droftarts administrators @johny
              last edited by

              @johny
              08a5da80-9a64-4076-8a77-d7a77d70a17c-image.png

              The first adjustment is made relative to Z0, which is set by homing Z, which the macro is doing at the start (or it's done at the end). The first two points reported are the measured offset from Z0 of EACH probe point, and both are about 0.64mm out, ie level with each other, just offset from the central Z0. Subsequent adjustments are done relative to this new offset, and are effectively 0.001mm out.
              But then you home Z again, and reset the Z0 point, before the next iteration.

              Like I said, your bed is warped, or possibly the weight of the X carriage is causing a rotation around the X axis, or a droop, so the probe is closer to the bed in the middle than at the ends. Or you are probing off the edge of the PEI sheet at the ends, but on the sheet in the middle.

              Ian

              Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

              1 Reply Last reply Reply Quote 0
              • infiniteloopundefined
                infiniteloop @johny
                last edited by

                @johny can you tell us what printer you're using?

                johnyundefined 1 Reply Last reply Reply Quote 0
                • johnyundefined
                  johny @infiniteloop
                  last edited by

                  @droftarts i think finally i understood what you said, you say that the points on both Z leadscrews are at the same position relative to Z0 and leveled but they are not, the bed is 0,6mm off on the right. How should it look like my bed.g and homeall.g ?

                  @infiniteloop custom-made BLV cube

                  droftartsundefined infiniteloopundefined 2 Replies Last reply Reply Quote 0
                  • droftartsundefined
                    droftarts administrators @johny
                    last edited by

                    @johny said in G32 doesnt save after True Bed Leveling:

                    but they are not, the bed is 0,6mm off on the right.

                    No, that's not quite right.

                    Leadscrew adjustments made: -0.649 -0.645, points used 2, (mean, deviation) before (-0.647, 0.001) after (0.000, 0.000)
                    

                    -0.649 -0.645, points used 2: The first set of points is the measured variation from Z=0 for each point
                    (mean, deviation) before (-0.647, 0.001): This is the average (mean) of the two points, and the amount each is off (deviation) from this average.
                    after (0.000, 0.000): The "after" shows the average, and the deviation from average, it is after the correction.

                    So it is not off 0.6mm on the right. As far as the firmware is concerned, these two points are level with each other. They just happen to be 0.64mm below (or above, I can't remember which way the signs go) Z0 in the middle of the bed.

                    Like I said, do a bed mesh. It may be enlightening.

                    Ian

                    Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

                    johnyundefined 1 Reply Last reply Reply Quote 0
                    • johnyundefined
                      johny @droftarts
                      last edited by

                      @droftarts Will do it and record a video as well because after the first iteration only the right motor gets calibrated.
                      I will create another macro without G28 to see.

                      jay_s_ukundefined droftartsundefined fcwiltundefined 3 Replies Last reply Reply Quote 0
                      • jay_s_ukundefined
                        jay_s_uk @johny
                        last edited by

                        @johny thats typically the way RRF works. The first z motor remains static and the rest of the motors are adjusted to match the first

                        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

                        1 Reply Last reply Reply Quote 0
                        • droftartsundefined
                          droftarts administrators @johny
                          last edited by

                          @johny It applies a rotation around the origin ie X0 Y0 Z0. If your origin is front left, then yes, most of the movement will be on the right hand side. If your origin is in the middle, the adjustment is usually equal.

                          Ian

                          Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

                          fcwiltundefined 1 Reply Last reply Reply Quote 0
                          • infiniteloopundefined
                            infiniteloop @johny
                            last edited by

                            @johny said in G32 doesnt save after True Bed Leveling:

                            custom-made BLV cube

                            Thank you. I just thought of the faint possibility of the Z-steppers loosing microsteps, but after all, I think @droftarts is on the right track.

                            1 Reply Last reply Reply Quote 0
                            • fcwiltundefined
                              fcwilt @droftarts
                              last edited by

                              @droftarts

                              I don't know if G32 behaves differently with two Z steppers but on my three stepper printer, which has 0,0 in the middle of the bed, it appears that the 1st Z stepper is not used during leveling.

                              I know when doing it on my printers with three "thumbscrews" for leveling, the adjustments have always called for on the 2nd and 3rd thumbscrews.

                              Which makes sense since the outcome will be the same as adjusting all three steppers/thumbscrews.

                              Frederick

                              Printers: a small Utilmaker style, a small CoreXY and a E3D MS/TC setup. Various hotends. Using Duet 3 hardware running 3.4.6

                              1 Reply Last reply Reply Quote 0
                              • fcwiltundefined
                                fcwilt @johny
                                last edited by

                                @johny said in G32 doesnt save after True Bed Leveling:

                                @droftarts Will do it and record a video as well because after the first iteration only the right motor gets calibrated.
                                I will create another macro without G28 to see.

                                From the current docs on G32 and bed leveling:

                                If your bed is not perfectly flat or the gantry sags a little when the head is over the middle of the bed, the process will cause a small shift in the Z=0 position. To correct this, if you are using the Z probe to do Z homing, you can just re-home Z at the end of your bed.g file.

                                Based on that you want to keep the G28 Z

                                I don't home with the probe but I have always re-set the Z=0 Datum after leveling the bed.

                                Frederick

                                Printers: a small Utilmaker style, a small CoreXY and a E3D MS/TC setup. Various hotends. Using Duet 3 hardware running 3.4.6

                                johnyundefined 1 Reply Last reply Reply Quote 0
                                • johnyundefined
                                  johny @fcwilt
                                  last edited by

                                  What about G32 using absolute position instead of relative?

                                  droftartsundefined 1 Reply Last reply Reply Quote 0
                                  • droftartsundefined
                                    droftarts administrators @johny
                                    last edited by

                                    @johny said in G32 doesnt save after True Bed Leveling:

                                    What about G32 using absolute position instead of relative?

                                    What are you trying to achieve? I don't think switching G32 to relative moves will make any difference, or it will produce an error, though I've never tried.

                                    Ian

                                    Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

                                    johnyundefined 1 Reply Last reply Reply Quote 0
                                    • johnyundefined
                                      johny @droftarts
                                      last edited by

                                      @droftarts Just trying to be able to print correctly the first layer on the entire 300mm bed 😞
                                      I made a new macro and its correct, without the g28 it doesn't correct anymore.
                                      How do you suggest starting the print? Like this?

                                      G28 XY
                                      M561 ; Clear any bed transform
                                      G1 X1... Y... ; Move Probe to middle of bed
                                      G30
                                      G29 S1

                                      fcwiltundefined droftartsundefined 2 Replies Last reply Reply Quote 0
                                      • fcwiltundefined
                                        fcwilt @johny
                                        last edited by

                                        @johny

                                        It's just possible that using G28 Z is the source of the problem because, in addition to invoking homeZ.g, it first marks the axis as un-homed.

                                        As I mentioned I don't home with the Z probe but I do set the Z=0 Datum after bed leveling by doing a G30 at the center of the bed, but it doesn't changed the homed state of anything that is already homed.

                                        Maybe the un-homing that occurs with the G28 Z causes the firmware to "forget" the adjustments made during bed leveling.

                                        Just thinking out loud here.

                                        And since you are supposed to set the Z=0 Datum using the same XY position when creating the height map and when loading the height map you can follow the bed leveling with a G30 to set the Z=0 Datum and then load the height map and all should be fine.

                                        It has always worked for me.

                                        Frederick

                                        Printers: a small Utilmaker style, a small CoreXY and a E3D MS/TC setup. Various hotends. Using Duet 3 hardware running 3.4.6

                                        1 Reply Last reply Reply Quote 0
                                        • droftartsundefined
                                          droftarts administrators @johny
                                          last edited by droftarts

                                          @johny That start should be fine. The G30 is setting Z0 at the bed centre anyway. And you are loading a bed mesh. What does your bed mesh look like? Maybe share a picture of the printer.

                                          @fcwilt said in G32 doesnt save after True Bed Leveling:

                                          I don't know if G32 behaves differently with two Z steppers but on my three stepper printer, which has 0,0 in the middle of the bed, it appears that the 1st Z stepper is not used during leveling.

                                          I just tried it on my centre origin machine (with two leadscrews, left and right of the bed), definitely both leadscrews get adjusted around the centre, ie the origin.

                                          @fcwilt said in G32 doesnt save after True Bed Leveling:

                                          Maybe the un-homing that occurs with the G28 Z causes the firmware to "forget" the adjustments made during bed leveling.

                                          As far as I can tell, there is no adjustment, just that both the probed points are -0.64mm from the Z datum sent at the bed centre. There's nothing to 'forget'. One way to test would be to run G32 with no Z homing or G30 after, and see at what height the nozzle hits the bed in the centre.

                                          Ian

                                          Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

                                          fcwiltundefined 1 Reply Last reply Reply Quote 1
                                          • fcwiltundefined
                                            fcwilt @droftarts
                                            last edited by

                                            @droftarts

                                            The screen shots the OP posted shows there were adjustments. The fact that they were the same doesn't mean the firmware wasn't turning the steppers trying to get both sides to read "0".

                                            It is pretty clear that, as you mentioned, the bed is simply higher in the center than at the edges. So re-setting the Z=0 Datum in the center is going to once again make the edges read low.

                                            You got it right early on - good job.

                                            Frederick

                                            Printers: a small Utilmaker style, a small CoreXY and a E3D MS/TC setup. Various hotends. Using Duet 3 hardware running 3.4.6

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