Modification to Z Offset makes no difference to Z height.
-
I have been trying to adjust my Z Offset by homing all then using the Home Z Head Movement in the web interface to lower the head until I can just get a piece of paper to slide under the extruder. I then take a note of what the console tells me the Z position is and edit the following files;
homez.g
homeall.g
config.gI then reboot the Duet3D Wifi and test Z height with a HomeAll.
The extruder then goes back down to the same height position as before ignoring my Z Offset change. I've now tried this multiple times and with ever greater changes (so it is obvious that the Z Offset has changed) without any luck.
Can anyone see what I am doing wrong please?
config.g
; Drives
M569 P0 S1 ; Physical drive 0 (X) goes forwards
M569 P1 S0 ; Physical drive 1 (Y) goes forwards
M569 P2 S1 ; Physical drive 2 (Z) goes backwards
M569 P3 S0 ; Physical drive 3 (E) goes forwards
M350 X16 Y16 Z16 E16 I1 ; Configure microstepping without interpolation
M92 X80.00 Y80.00 Z400.00 E96.50 ; Set steps per mm
M566 X900.00 Y900.00 Z12.00 E1200.00 ; Set maximum instantaneous speed changes (mm/min)
M203 X6000.00 Y6000.00 Z600.00 E6000.00 ; Set maximum speeds (mm/min)
M201 X1000.00 Y1000.00 Z100.00 E5000.00 ; Set accelerations (mm/s^2)
M906 X800.00 Y800.00 Z800.00 E800.00 I30 ; Set motor currents (mA) and motor idle factor in per cent
M84 S30 ; Set idle timeout; Axis Limits
M208 X200 Y200 Z180 S0 ; Set axis maximum
M208 X0 Y0 Z9.60 S1 ; Set axis minimum (should stop at the edge of the bed ready to print position)Currently this just lets paper under the extruder.; Endstops
M574 X1 Y1 Z1 S0 ; Set active low and disabled endstopshomeall.g
; homeall.g
; called to home all axes
;
; generated by RepRapFirmware Configuration Tool v2 on Wed May 29 2019 19:19:18 GMT+0100 (British Summer Time)
G91 ; relative positioning
G1 Z5 F6000 S2 ; lift Z relative to current position
G1 S1 X-203 Y-205 F1800 ; move quickly to X and Y axis endstops and stop there (first pass)
; G1 S1 X-175 Y-185 F1800 ; move quickly to X and Y axis endstops and stop there (first pass)
G1 X5 Y5 F6000 ; go back a few mm
G1 S1 X-203 Y-205 F360 ; move slowly to X and Y axis endstops once more (second pass)
; G1 S1 X-175 Y-185 F360 ; move slowly to X and Y axis endstops once more (second pass)
G1 S1 Z-185 F1800 ; move Z down stopping at the endstop
G90 ; absolute positioning
G92 Z9.60 ; set Z to axis minimum (you may want to adjust this); Uncomment the following lines to lift Z after probing
;G91 ; relative positioning
;G1 S1 Z5 F100 ; lift Z relative to current position
;G90 ; absolute positioninghomez.g
; homez.g
; called to home the Z axis
;
; generated by RepRapFirmware Configuration Tool v2 on Wed May 29 2019 19:19:18 GMT+0100 (British Summer Time)
G91 ; relative positioning
G1 Z5 F6000 S2 ; lift Z relative to current position
G1 S1 Z-400 F1800 ; move Z down until the endstop is triggered
G92 Z9.60 ; set Z position to axis minimum (you may want to adjust this); Uncomment the following lines to lift Z after probing
;G91 ; relative positioning
;G1 S2 Z5 F100 ; lift Z relative to current position by 5mm
;G90 ; absolute positioning -
@b0m0a0k If what you enter in config.g is being overridden then the usual culprit is that you have a config-overide.g file. So check if you have a config-overide.g file and if you have, edit this and not your config.g file. I'm guessing that the G92 Z9.6 value is just a silly number that you are trying yes? Also, don't change the axis minimum (M208 S1) - leave that at zero. You haven't said what probe you are using but it's usually best to set the offset between when the probe triggers and Z=0 by using G31.
-
@deckingman Hi. Yes, I have a config-overide.g file and yes, that is just a silly number I am using just so there is an obvious change of height in the extruder that demonstrates that the change has taken effect.
I didn't mention the probe, a BLTouch Smart, because I hadn't really started to try and configure that. It's wired and the self-test is working and it responds as it should when you run the deployment test. But I didn't see much point in trying to complete the setup if I couldn't even get the Z offset to work first.
I have been trying to follow the setup process as detailed here; https://betrue3d.dk/bltouch-on-duet-wifi-configuratio-and-usage/#findzoffset but this stalls at "Find Z-offset:" section 3. Because the extruder won't lower any further. Even if I try the suggested "Note: If it refuses to move as it has reached Z-minima you can type in G92 Z5 to tell it, that you are 5mm from Z=0."
So I am back to basics in making sure that the Z Offset is doing what it's told first.
-
I think things have gotten over complicated.
@b0m0a0k said in Modification to Z Offset makes no difference to Z height.:
M208 X0 Y0 Z9.60 S1
This needs to be set to Z0. Or even slightly negative number to allow you to baby step below the 0 point on occasion. So set it to Z-0.2.
Then in homeall The G92 command only needs to be used if you can't adjust the position of your endstop switch. Ideally you would move the endstop so that when it triggers the nozzle is just about touching the bed. Then you can use G92 to make up for the small gap that's left.
However, since you have a Bltouch waiting in the wings, it might be time to get it working for you to simplify the whole process.
@b0m0a0k said in Modification to Z Offset makes no difference to Z height.:
Because the extruder won't lower any further.
If you've used G92 Z5 to trick it to think it's above the bed still, but it won't move any lower, I wonder if it physically cannot move any lower? Has your mechanical motion bottomed out?
Another option to use instead of the G92 Z5 trick is to send
M564 S0
which will allow movement outside of the set axis limits. This would temporarily allow you to go below Z0. -
I think some of this is just trying to prove that I understand what I put in config and how the printer reacts. I have removed the associated entry in config-override.g as suggested by @deckingman and rebooted the printer. When I home all the printer moves to the front left corner and then drops the extruder down until it touches the bed, at which time it activated the z stop switch (I can watch the Z-stop light come on).
But my config.g currently states that my Z offset should be positive 9.6 (this is not a final setting, it's just to prove the point). But the printer does not stop at 9.6 above the bed. It continues down until it hits the bed again.
So if it's not doing what I have asked it to do in config.g when I am misunderstanding what that entry in config.g is doing.
; Axis Limits
M208 X200 Y200 Z180 S0 ; Set axis maximum
M208 X0 Y0 Z9.60 S1 ; Set axis minimum (should stop at the edge of the bed ready to print position) Currently this just lets paper under the extruder.Another thing with this is that if I alter config.g - for sake of argument to the following;
M208 X0 Y0 Z9.60 S1
But when I "Home All" the extruder moves to the edge of the bed as expected and lowers (in my case until it contacts with the bed). But the web interface shows it's position as Z 9.60 - but it just lowered until it hit the bed, which I would have expected to show a negative number?
-
@b0m0a0k As we've said, don't alter M208 - keep your axis minumum at Z=0.
I don't use a BL touch but I'm assuming it works like any other probe. In which case the best way to home Z, IMO is to do a single probe using G30. You define the offset using G31. So you bring the bed and probe closer together until the probe triggers. Note the Z height. Then you move closer together still until the nozzle is just gripping a very thin piece of paper and note the Z height again. Then you take one Z height away from the other and the difference is the offset. This is the value you put into G31. From there after, whenever you probe the bed using G30, the firmware "knows" that Z=0 (nozzle just touching the bed) is G31 mms away from the point where the probe triggers.
-
Hi. OK, so I reverted All Z references back to "0" and reran the setup sequence as documented in the BeTrue3D tutorial (that's a great document by the way). I ran through to section 3 and again stumbled at lowering the nozzle until it touches the bed. I issued M564 S0 as suggested by @Phaedrux and this allowed me to continue jogging the nozzle down until it touched the bed.
Ran the configuration process three times as suggested by the tutorial and completed the setup successfully.
Ran my first Mesh Grid Compensation sequence and all hell broke loose. It's obvious by just looking at the setup that the probe was going to hang over the edge of the bed and not trigger, so I need to go read up on how you define the Mesh grid pattern. For now the nozzle happily descends until it crashes into the bed and I have to perform an emergency stop
... it's a learning curve
-
@b0m0a0k Don't forget that anything that is in config-override.g will over ride whatever is in config.g. I suggest to delete the override.g file, at least for now. It'll save a bit of confusion because then you'll know that everything is in one place and one place only.
-
@deckingman That's a great suggestion and one I'm happy to follow. I hadn't done it prior to this because that file starts with "This is a system-generated file - do not edit" which I assumed meant that it needs to be there.
Thanks for the clarification.
-
@b0m0a0k said in Modification to Z Offset makes no difference to Z height.:
@deckingman That's a great suggestion and one I'm happy to follow. I hadn't done it prior to this because that file starts with "This is a system-generated file - do not edit" which I assumed meant that it needs to be there.
Thanks for the clarification.
Another possibility is to remove or comment out the M501 line at the end of config.g so that config-override.g is not run. Then anything you save using M500 will still be written to config-override.g but ignored. You can use the editor in DWC to see what has been written to config-override.g and transfer lines from there to config.g if you need to, for example after tuning heaters.
@b0m0a0k said in Modification to Z Offset makes no difference to Z height.:
so I need to go read up on how you define the Mesh grid pattern
The M557 command defines the limits of the mesh grid; but you must also define the Z probe offset from the nozzle in the G31 command.
-
When I set up the Mesh Grid am I right in thinking that I am working out the coordinates where the probe will contact the bed and not where the extruder nozzle will be. If I do the former the probe won't always trigger because it will go off the edge of the bed?
This does of course mean that my bed leveling probe area is greatly reduced due to the distance between the nozzle and the probe - caused by the mounting location of the probe?
-
@b0m0a0k said in Modification to Z Offset makes no difference to Z height.:
"This is a system-generated file - do not edit" which I assumed meant that it needs to be there.
Possibly it was generated by saving the results of a heater PID tuning with M500?
-
@b0m0a0k said in Modification to Z Offset makes no difference to Z height.:
This does of course mean that my bed leveling probe area is greatly reduced due to the distance between the nozzle and the probe - caused by the mounting location of the probe?
Yes, this is common with probes that are offset from the nozzle, there will likely be some areas of the bed that the probe cannot reach, and areas where it will overhang the edge of the bed. The firmware does attempt to do some extrapolation for the areas that it cannot reach, so if it's generally flat to begin with, it's not likely to be much of an issue.
I find the best way to work out the extents of the mesh grid is to take the axis limits and your probe offset and the difference between them becomes your grid area.
For example, if your X axis is 200mm long from 0 to 200, and your probe is offset from the nozzle by +20mm that means your grid would begin at X20 and end at 200. Likewise, if your Y axis is 200mm long from 0 to 200, and your probe is offset by -20mm (ie, in front of the nozzle) then your Y grid would begin at Y0 and end at Y180. This assumes that the nozzle cannot travel off the edge of the bed at all. If it can travel farther than the edge of the bed, then your probe may be able to reach more.
-
Thanks for the confirmation @Phaedrux that all makes sense. I have calculated my Mesh by moving the extruder to all 4 corners and making a note of the coordinates. Then I have rerun this to allow for the probe overhand at the front of the bed and noted these adjusted settings.
I have ended up with this;
M557 X28:190 Y49:185 S20 : PROBE on the edges setting
I am now generally finding reasons not to click on Run Mesh Grid Compensation just in case I have programmed the printer for insanity by mistake
-
Well, Holy Hannah, that didn't blow up!
This is my 1st attempt, the test stopped short of where I though it would at the back of the bed - you can see it's well short of the edge.
I guess some fine tuning is in order. Sorry about the fuzzy nature of the second photo, my webcam did not want to prioritize focus on the far object.
-
@b0m0a0k said in Modification to Z Offset makes no difference to Z height.:
When I set up the Mesh Grid am I right in thinking that I am working out the coordinates where the probe will contact the bed and not where the extruder nozzle will be.
Yes, where the probe will contact the bed - assuming you have set the correct probe X and Y offsets in G31. The firmware will take those into account when calculating where to place the nozzle for each probe point. If that position is outside the limits that you declared using M208, that point won't be probed.