Mesh levelling on 3.1.1
-
@Phaedrux said in Mesh levelling on 3.1.1:
Post the results of M122 and M98 P"config.g"
Post your config.g and homing files, and bed.g
Post your start.g and your slicer start gcode.config.g
; Configuration file for Duet WiFi (firmware version 3)
; executed by the firmware on start-up
;
; generated by RepRapFirmware Configuration Tool v3.1.4 on Tue Oct 20 2020 12:22:07 GMT+1100 (Australian Eastern Daylight Time); General preferences
G90 ; send absolute coordinates...
M83 ; ...but relative extruder moves
M550 P"Funmat HT #2" ; set printer name; Network
M551 P"redacted" ; set password
M552 S1 ; enable network
M586 P0 S1 ; enable HTTP
M586 P1 S0 ; disable FTP
M586 P2 S0 ; disable Telnet; Drives
M569 P0 S0 ; X physical drive 0 goes backwards
M569 P1 S1 ; Y physical drive 1 goes forwards
M569 P2 S0 ; Z physical drive 2 goes backwards
M569 P3 S0 ; E physical drive 3 goes forwards
M584 X0 Y1 Z2 E3 ; set drive mapping
M350 X16 Y16 Z16 E16 I1 ; configure microstepping with interpolation
M92 X80.00 Y80.00 Z800.00 E410.00 ; set steps per mmM566 X300.00 Y300.00 Z180.00 E1200 ; set maximum instantaneous speed changes (mm/min)
M203 X9000.00 Y9000.00 Z1800.00 E10000 ;changed to allow faster z for piezo trigger (1200 works)
;M201 X3000.00 Y3000.00 Z15.00 E500.00 ;recommended settings and PA currently tuned PA on this value
M201 X1000.00 Y1000.00 Z30.00 E700.00 ; set max accelerations (mm/s^2) ;upped z to 25 for z probeM204 P800.00 T1500.00 ;set default acceleration P=x,y,z T=extruder
M906 X1150 Y1150 Z1300 E700 I45 ; 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 X255 Y250 Z260 S0 ; set axis maxima; Endstops
M574 X1 S1 P"!xstop" ; configure active-low endstop for Min X axis via pin !xstop //omron limit switch
M574 Y1 S1 P"!ystop" ; configure active-low endstop for Min Y axis via pin !ystop //omron limit switch
M574 Z1 S1 P"zstop" ; configure active-low endstop for min Z axis via pin zstop inverting the signal. //biqu optical sensor;Z Emergency-Stop
M950 J1 C"!e1stop" ; configure active-low input (endstop) via pin e1stop //omron limit switch on z just prior to min limit ball screw crash.
M581 P1 T0 C0 S1 ;T0 = emergency stop on trigger; C0 or C1 = when it may trigger: C0 is anytime; C1 is only during a print, S1 or S0 = sets it as raising edge (S1) or falling edge (S0); Z-Probe
M558 C"!^zprobe.in" P8 F7000 T7000 H10 I1 R0.3 A5 S0.005 ; Z probe type to PIEZO (P8 = unfiltered, F = feed mm/min dive speed 116mm/sec,
; T-travel between spots mm/min H=dive height mm, I1 - invert reading, R0.5 - pause 0.5sec
; before each probe, A3 - probe 3 times, S0.01 - tolerance between probes required) and theG31 -0.777 ; set the z height at which the probe will recognise it's z
;M558 P0 H5 F120 T6000 ; disable Z probe but set dive height, probe speed and travel speed (old before piezo)
;M557 X20:240 Y20:240 S44 ; define mesh grid - max bed size
M557 X30:230 Y20:230 S40 ; define mesh grid - reduced bed size to avoid cooling duct on back bed holders; Heaters
M308 S0 P"bedtemp" Y"thermistor" T122000 B4050 ; configure sensor 0 as thermistor on pin bedtemp
M950 H0 C"bedheat" T0 ; create bed heater output on bedheat and map it to sensor 0
M307 H0 A=143 C=1300 D=20 B0 ; enable pid mode for the bed heater
M140 H0 ; map heated bed to heater 0
M143 H0 S160 ; set temperature limit for heater 0 to 160CM308 S1 P"spi.cs1" Y"rtd-max31865" ; configure sensor 1 as thermocouple via CS pin spi.cs1
M950 H1 C"e0heat" T1 ; create nozzle heater output on e0heat and map it to sensor 1
M307 H1 A=450 C=160 D=5.3 V=24 B0 ; disable bang-bang mode for heater and set PWM limitM308 S2 P"e1temp" Y"thermistor" T100000 B3950 ; configure sensor 2 as thermistor on pin e1temp
M950 H2 C"e1heat" T2 ; create chamber heater output on e1heat and map it to sensor 2
M307 H2 A145 C1600 D4.5 V24 B0 S1 ; enable bang-bang mode for the chamber heater and set PWM limit
M141 H2 ; map chamber to heater 2; Fans
M950 F0 C"fan0" Q500 ; create fan 0 on pin fan0 and set its frequency to 500Hz (default for 2 wire)
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.0 H1:2 T45 ; set fan 1 value to full speed. Thermostatic control is turned on for heater 1 & 2; 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
; Screw positions
M671 X28:228:129 Y188:188:16 P0.5; Miscellaneous
M302 S180 R180 ; min extruder temp and retraction
M575 P1 S1 B57600 ; enable support for PanelDue
M911 S21 R23 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; set voltage thresholds and actions to run on power loss;BigTreeTech Filament Runout Sensor
;see: https://forum.duet3d.com/topic/17107/how-to-setup-the-bigtreetech-smart-filament-sensor/48M591 D0 P7 C"^e0stop" L7 R75:200 E22 S1 ;
-
@fcwilt 0.00 is what shows up in web control
-
; homex.g
; called to home the X axis
;
; generated by RepRapFirmware Configuration Tool v3.1.4 on Tue Oct 20 2020 12:22:07 GMT+1100 (Australian Eastern Daylight Time)
G91 ; relative positioning
G1 H2 Z5 F6000 ; lift Z relative to current position
G1 H1 X-265 F1800 ; move quickly to X axis endstop and stop there (first pass)
G1 H2 X5 F6000 ; go back a few mm
G1 H1 X-265 F360 ; move slowly to X axis endstop once more (second pass)
G1 H2 Z-5 F6000 ; lower Z again
G90 ; absolute positioning -
; homey.g
; called to home the Y axis
;
; generated by RepRapFirmware Configuration Tool v3.1.4 on Tue Oct 20 2020 12:22:07 GMT+1100 (Australian Eastern Daylight Time)
G91 ; relative positioning
G1 H2 Z5 F6000 ; lift Z relative to current position
G1 H1 Y-265 F1800 ; move quickly to Y axis endstop and stop there (first pass)
G1 H2 Y5 F6000 ; go back a few mm
G1 H1 Y-265 F360 ; move slowly to Y axis endstop once more (second pass)
G1 H2 Z-5 F6000 ; lower Z again
G90 ; absolute positioning -
@lael said in Mesh levelling on 3.1.1:
G31 -0.777 ; set the z height at which the probe will recognise it's z
That line is incorrect.
You should have at least the P X Y and Z parameters but you have none and a value all on it's own.
Frederick
-
@lael said in Mesh levelling on 3.1.1:
@fcwilt 0.00 is what shows up in web control
If you comment out the G92 Z0 in homeall.g what value is displayed?
Thanks.
Frederick
-
; homez.g
; called to home the Z axis
;
; generated by RepRapFirmware Configuration Tool v3.1.4 on Tue Oct 20 2020 12:22:07 GMT+1100 (Australian Eastern Daylight Time)
G91 ; relative positioning
G1 H2 Z5 F600 ; increase (drop) Z relative to current position by 5mm @300mm/min (5mm/sec)
G1 H1 Z-265 F600 ; decrease Z until the endstop is triggered @10mm / sec
G92 Z0 ; set Z position to axis minimum (you may want to adjust this)
G1 H2 Z5 F300 ; lift Z relative to current position - Z=5 @6000mm/min (100mm/sec)
G1 H1 Z-10 F180 ; move Z down until the endstop is triggered @3mm/sec; Uncomment the following lines to lift Z after probing
;G91 ; relative positioning
;G1 Z5 F100 ; lift Z relative to current position
;G90 ; absolute positioning -
start.g
G28 ;home all axis
G0 X130 Y130 Z10 ; go to bed center, 10mm above
G30 ; probe for datum ref point
G29 S1 ; Load Grid Compensation
T0 ; Selects Tool 0 (active temp)
M703 ; Ensure filament specific settings are loaded
G1 X10 Y10 ; move close to origin -
G28 ;Home All Axis
G92 E0 ;zero extruded lengthG0 X0 Y0 F9000 ; Go to front
Slicer Start G Code:G0 Z0.20 ; Drop to 0.2 above bed
G92 E0 ; zero the extruded length
G1 X40 E35 F600 ; Extrude 35mm of filament in a 4cm line @600mm/min 60mm/sec
G92 E0 ; zero the extruded length
G1 E-1 F30 ; Retract a little
G1 X80 F4000 ; Quickly wipe away from the filament lineG0 F3600 X20 Y20 ;rapid movement to X20, Y20
I had G29 S1 which was removed after creating the start.g macro
-
@fcwilt 0.71mm
-
@lael said in Mesh levelling on 3.1.1:
@fcwilt 0.71mm
OK so the end stop triggers are 0.71 and at the point the Z axis stops moving.
Is that the actual Z position of the nozzle.
If you include the G92 Z0 you are telling the firmware that the Z position is 0.
So where exactly is the nozzle tip - at Z = 0.71 or Z = 0.00 or perhaps something else?
Thanks
Frederick
-
Can we see the code that you use to create the height map?
Thanks.
Frederick
-
@fcwilt so far I've just been running through the mesh levelling tutorial / example and haven't made a macro for it. To remap I've gone through the entire procedure manually.
In terms of the nozzle tip, you mean relative to the bed?
-
@lael said in Mesh levelling on 3.1.1:
I've gone through the entire procedure manually.
Did you do a G30 prior to the G29 that actually started the probing of the bed?
In terms of the nozzle tip, you mean relative to the bed?
Yes.
Frederick
-
@fcwilt said in Mesh levelling on 3.1.1:
@lael said in Mesh levelling on 3.1.1:
I've gone through the entire procedure manually.
Did you do a G30 prior to the G29 that actually started the probing of the bed?
yes
In terms of the nozzle tip, you mean relative to the bed?
The bed is quite warped, but at the center where I run the G30's for printing etc, it is just the right height above the bed to grip a piece of paper lightly. So I guess ~0.1 or a little less or so.
-
If you are going to use the G92 Znnn command you should determine as best you can what the actual nozzle position is and use that value.
Did you correct your G31 command and include the P X Y and Z parameters?
Frederick
-
So what is the relationship between all of the Z points?
Here is my understanding so far:
G92 Z0 sets printing 0 - so the firmware is expecting 0 to be where the nozzle should be when putting down the first layer.
G31 sets the location where the probe will be triggered - so in my case it is a piezo sensor which is triggered when the nozzle impacts the bed. So a -0.7mm makes sense as that is when the nozzle will actually contact the bed?
Home Z will move the head/bed (bed in my case) to the end stop, which will reference that location as zero.
Then mesh compensation will apply the additional compensation it has found above or below the Z point. The G30 datum point - sets the location at which the mesh map will be applied from? or does it overrride the G31 in config.g?
-
@lael said in Mesh levelling on 3.1.1:
The G30 datum point - sets the location at which the mesh map will be applied from? or does it overrride the G31 in config.g?
G30 uses the trigger height from G31
Usually when you have a probe, you don't use a Z min endstop at all. You use the probe for homing Z and creating the mesh. That way the Z0 reference is always the same based on the probe.
-
@lael said in Mesh levelling on 3.1.1:
G92 Z0 sets printing 0 - so the firmware is expecting 0 to be where the nozzle should be when putting down the first layer.
It's essential that the firmware knows the actual position of the nozzle on the X, Y and Z axes. For the Z axis that position can be set using an end stop or a Z probe. While the end stop references the frame, the Z probe references the bed which is better because any changes due to the heating of the bed are compensated for with each setting of the Z=0 datum.
G31 sets the location where the probe will be triggered - so in my case it is a piezo sensor which is triggered when the nozzle impacts the bed. So a -0.7mm makes sense as that is when the nozzle will actually contact the bed?
Not exactly. When the Z probe is triggered the Z trigger height value in G31 is used to set the firmware's Z position value so that the firmware "knows" where the nozzle is positioned on the Z axis. If the value in G31 is wrong the firmware's "knowledge" of the nozzle position will be wrong.
Home Z will move the head/bed (bed in my case) to the end stop, which will reference that location as zero.
Just as the G31 Z trigger height value is used to set the Z position value when the Z probe is triggered the G92 Znnn is used to set the Z position value when the end stop is triggered. Naturally the nnn value needs to match the actual Z position when the end stop is triggered.
Then mesh compensation will apply the additional compensation it has found above or below the Z point. The G30 datum point - sets the location at which the mesh map will be applied from? or does it overrride the G31 in config.g?
The G30 sets the Z=0 datum. The G29 probing is determining the Z difference at each probe point in reference to the point used for G30 - the differences can be plus or minus. Thus the same XY position must always be used when setting the Z=0 datum with G30.
Since the Z=0 datum determines the plus/minus Z values in the height map it is necessary to use G30 when creating the height map AND when loading the height map.
If for some reason the Z=0 datum used when creating the height map differs significantly from the Z=0 datum used when later loading the height map you can get the error about the Z offset.
I hope that covers it and I have'nt made any errors - it's late here.
Frederick
-
@fcwilt So if no G30 was used prior to loading a mesh map, what does it use as the datum? the value from G31, or maybe the current zero point?