G32 doesnt save after True Bed Leveling
-
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
-
@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
-
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
-
@johny can you tell us what printer you're using?
-
@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
-
@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
-
@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. -
@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
-
@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
-
@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.
-
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
-
@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
-
What about G32 using absolute position instead of relative?
-
@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
-
@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 -
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
-
@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
-
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
-
@fcwilt after several iterations and tryouts the problem is still there.
I can’t calibrate the first layer, the difference in the bed is very high… I dunno if it’s the compensation or something else. That’s why I was saying that the calibration wasn’t saved. I can post a picture of the printed 1st layer…
The mesh didn’t help btw @droftarts -
@johny Can you please at least post a picture of the bed mesh? As there's nothing else saved, ie there is not calibration with G32, it just levels the gantry with the information it gets from probing at the points you tell it to, there's very little else for us to go on. Maybe a picture of your machine that shows the whole bed, with an indication where it is probing. And yes, a picture of the first layer if you want.
Also, when you make a bed mesh, make sure any previous bed mesh is cancelled.
Ian