Correction of heightmap is not really working
-
maybe my understanding is wrong.
in that way:
1 tilt calibration
2 z calibration
3 bed calibration??
-
To get the Z probe to make correct readings the Z trigger height setting in your G31 command needs to be set. Once set it shouldn't need to be changed unless your hardware changes.
It is important to use the probe to set the Z = 0 Datum. This insures that the logical position of Z=0 matches the physical position of Z=0.
There are three times you must do this:
- after leveling the bed
- before creating the heightmap
- before loading the heightmap
Frederick
-
@fcwilt Thx for your answer, but i am really a beginner and for me its not clear what you mean.
Here is my tilt calibration and bed calibration macro:
M561
G28
M561
G30 P0 X2 Y20 Z-99999 ; Probe near a leadscrew
G30 P1 X600 Y20 Z-99999 ; Probe near a leadscrew
G30 P2 X600 Y600 Z-99999 ; Probe near a leadscrew
G30 P3 X2 Y600 Z-99999 S4 ; Probe near a leadscrew
M400
G4 S1
G30 P0 X2 Y20 Z-99999 ; Probe near a leadscrew
G30 P1 X600 Y20 Z-99999 ; Probe near a leadscrew
G30 P2 X600 Y600 Z-99999 ; Probe near a leadscrew
G30 P3 X2 Y600 Z-99999 S4 ; Probe near a leadscrew
M400
M558 P9 C"zprobe.in" H5 F120 T6000 A1 R0.7
M950 S0 C"duex.pwm5"
M300 S1111 P444
M291 S3 R"Bed Mapping" P"The printer will now generate a new heightmap" ;
G28
M561 ; home
G29 S0 ; probe the bed and enable compensation
M300 S1888 P888
M291 S2 P"The bed plate is calibrated and the heightmap is loaded"Thats my z compensation macro:
M300 S666 P666 ;
M291 S3 P"Press OK to continue, or CANCEL to abort"
G28
M564 H0 S0 ;Negative movements are allowed
M561 ;
G90 ;
G1 X20 Y100 F6000;
M300 S1111 P666 ;
G4 S1 ;
M291 S2 R"Height clearance" P"Place a paper sheet under the nozzle and raise the bed until slight friction can be noticed" Z1 ;
G92 Z0 ;
G91 ;
G1 Z11 F200 ;
G90
G4 S1 ;
M300 S666 P666 ;
M291 S2 R"Height clearance" P"Please remove the paper sheet and wait for the bed-probing to begin" ;
G30 S-1 ;
M564 S1 H1 ; Negative movements are forbidden
M291 S2 R"Height clearance" P"Copy the reported height value on the G-Code console and paste it into the config.g file" ;I add the 0.3mm to the value i get from the macro and save it in the config.g file.
my heightmap;
RepRapFirmware height map file v2 generated at 2022-02-14 18:54, min error -0.171, max error 0.147, mean -0.034, deviation 0.069
axis0,axis1,min0,max0,min1,max1,radius,spacing0,spacing1,num0,num1
X,Y,20.00,600.00,20.00,620.00,-1.00,58.00,58.00,11,11
-0.005, -0.019, -0.011, -0.025, -0.015, -0.061, -0.073, -0.055, -0.077, -0.065, -0.067
-0.017, -0.019, -0.019, -0.021, -0.093, -0.095, -0.095, -0.091, -0.035, -0.061, -0.151
-0.021, -0.007, -0.025, -0.028, -0.081, -0.091, -0.057, -0.077, -0.055, -0.037, -0.169
0.033, 0.027, -0.027, -0.003, -0.045, -0.043, -0.047, -0.107, -0.135, -0.089, -0.167
0.075, 0.085, 0.039, 0.035, -0.011, -0.049, -0.041, -0.047, -0.077, -0.082, -0.119
0.083, 0.077, 0.019, 0.055, -0.007, -0.039, -0.049, -0.035, -0.103, -0.081, -0.117
0.119, 0.097, 0.071, 0.059, 0.013, -0.039, -0.047, -0.041, -0.119, -0.075, -0.095
0.147, 0.107, 0.103, 0.049, 0.001, -0.051, -0.033, -0.059, -0.075, -0.055, -0.093
0.121, 0.097, 0.075, 0.045, -0.001, -0.031, -0.053, -0.071, -0.067, -0.071, -0.065
0.085, 0.075, 0.027, -0.009, -0.021, -0.065, -0.077, -0.123, -0.111, -0.131, -0.033
0.037, -0.013, -0.003, -0.031, -0.093, -0.135, -0.110, -0.165, -0.171, -0.127, -0.115The part from ym config.g
; Z-Probe
M558 P9 C"zprobe.in" H5 F120 T6000 A1 R0.7
M950 S0 C"duex.pwm5"
G31 P500 X-18 Y24 Z2.917 (value was 2.617 + 0.3)if i go to any position on the bed the distance is never 0.3
G0 x*** y*** z 0.3
No clue whats wrong here. Please help what i do wrong or is wrong.
thanks a lot
Dieter -
Hi,
Let's see if we can get you sorted.
Your Z compensation macro is fine and is just one way of several to determine the Z parameter setting in your G31 command in your config.g file.
You are aware that after editing config.g you have to do something to get the file processed again so any changes take effect?
Re-booting or resetting will do what is needed.
And to mention it again once you have determined and set the Z parameter for G31 it should not need setting again unless your hardware changes.
With current firmware bed leveling code is meant to be put into a file called bed.g which is then invoked with a G30 command.
Height map creation code is meant to be put into a file called mesh.g which is then invoked with a G29 command.
You don't have to do it that way but it is what the DWC expects and there is no real reason to not do it that way.
Setting the Z=0 Datum, as mentioned in my previous post, is simple.
A good way that is simple is to use a G1 command to position the Z probe at the center of the bed. Then a single G30 command will probe the bed at that point and set the Z=0 datum.
G1 Xaaa Ybbb ; where aaa and bbb are the values needed to position the Z probe at bed center G30
Now you are ready to do other operations (G32 or G29) that use the Z probe.
If you have more questions feel free to ask.
Frederick
-
Can you post your homeall.g as well since it's getting called in your current file.
As Fcwilt says you should not need to do Z compensation more than once in a while. Once it's set in config.g it shouldn't change unless the hardware changes physically.
-
@phaedrux
ok
here are all my files:mesh.g i do not have
bed.g
; bed.g
; called to perform automatic bed compensation via G32
;M561 ; clear any bed transform
;G29 ; probe the bed and enable compensation
M291 S1 T46 R"Function disabled" P"For performing bed compensation, please navigate to the ""Macros"" tab"homeall.g
; homeall.g
; called to home all axes
M280 P0 S60 I1G91 ; relative positioning
M584 X0 Y5 Z6:7:8:9 U1 E3:4 P4 ; Driver mapping
M400
G1 H2 Z5 F200 ; lift Z relative to current position
G1 H1 X-605 Y605 U-605 F3000 ; move quickly to X and Y axis endstops and stop there (first pass)
G1 H2 X5 Y-5 F600 ; go back a few mm
G1 H1 X-605 Y605 U-605 F600 ; move slowly to X and Y axis endstops once more (second pass)
M400
M584 X0:1 Y5 Z6:7:8:9 U1 E3:4 P3 ; Driver mapping
M400
G90 ; absolute positioning
G30 ; home Z by probing the bed
M375 ; Loads the grid matrix file (Heightmap)here is my config.g
; General preferences_________________________________________________________
G90 ; send absolute coordinates...
M83 ; ...but relative extruder moves
M111 S0 ; Debug off
M555 P2 ; Set output to look like Marlin
M575 P1 B57600 S1 ; Set auxiliary serial port baud rate and require checksum (for PanelDue); Network_____________________________________________________________________
M550 P"Big 60X V3.3 ICY" ; set printer name
;M551 P"MODIX3D" ; Set password (optional)
M552 S1 ; enable network
M552 P192.168.10.169 ; My IP Address
M586 P0 S1 ; enable HTTP
M586 P1 S0 ; disable FTP
M586 P2 S0 ; disable Telnet; Drives_________________________________________________________________________
;Main board______________________________________________________________________
M569 P0 S1 ; Physical drive 0 . X1
M569 P1 S0 ; Physical drive 1 . X2
M569 P2 R-1 ; Physical drive 2 . Canceled
M569 P3 S1 ; Physical drive 3 . Main Extruder
M569 P4 S0 ; Physical drive 4 . Secondary Extruder
;Duex5 board_____________________________________________________________________
M569 P5 S0 ; Physical drive 5 . Y
M569 P6 S0 ; Physical drive 6 . Z1 (0,1000)
M569 P7 S0 ; Physical drive 7 . Z2 (0,0)
M569 P8 S0 ; Physical drive 8 . Z3 (1000,0)
M569 P9 S0 ; Physical drive 9 . Z4 (1000,1000);Settings_________________________________________________________
;M584 X0:1 Y5 Z6:7:8:9 U1 E3:4 P3 ; Driver mapping
;M671 X-189:-189:645:645 Y645:-64:-64:645 S10 ; Anticlockwise
M584 X0:1 Y5 Z6:7:8:9 U1 E3:4 P3 ; Driver mapping
M671 X-189:-189:645:645 Y645:-64:-64:645 S10 ; Anticlockwise;___________________________________________________________________
M350 X16 Y16 U16 I1 ; Configure microstepping with interpolation
M350 Z16 E16:16 I0 ; Configure microstepping without interpolationM92 X100.00 Y100.00 Z1969.60 E416.21:416.21 U100.00 ; Set steps per mm changed to fit my values 100mm messen und eintragen
M566 X240 Y360 Z30.00 E120.00:120.00 U240 P1 ; Set maximum instantaneous speed changes (mm/min)
M203 X9000.00 Y9000.00 Z200.00 E1200.00:1200.00 U9000.00 ; Set maximum speeds (mm/min)
M201 X1000 Y1000 Z120.00 E250.00:250.00 U1000 ; Set accelerations (mm/s^2)
M204 P500 ; Set print and travel accelerations (mm/s^2)
M906 X1800 Y1800.00 E1000.00:1000.00 U1800 I40 ; Set motor currents (mA) and motor idle factor in per cent
M906 Z1800.00 I50 ; Set motor currents (mA) and motor idle factor in per cent
M84 S100 X Y U E0 E1 ; Set idle timeout - one minute; Axis Limits
M208 X0 Y0 Z-1 S1 ; set axis minima
M208 X600 Y600 Z630 S0 ; my print area, changed to hight 630 do changes; Axis Limits_______________________________________________________
; M208 X0:600 Y0:600 Z-1:630 U0:600 ; Set axis minima and maxima; Endstops
M574 X1 S1 P"xstop" ; configure switch-type (e.g. microswitch) endstop for low end on X via pin xstop
M574 U1 S1 P"e0stop" ; configure switch-type (e.g. microswitch) endstop for low end on X via pin xstop
M574 Y2 S1 P"ystop" ; configure switch-type (e.g. microswitch) endstop for low end on Y via pin ystop; Z-Probe
;M558 P5 C"^zprobe.in" H5 F120 T6000 A8 R0.7 ; set Z probe type to bltouch and the dive height + speeds Changed A1 to A8
M558 P9 C"zprobe.in" H5 F120 T6000 A1 R0.7 ; set Z probe type to bltouch and the dive height + speeds Changed A1 to A8 ggf ohne ^ testen damit 1000 weggeht
M950 S0 C"duex.pwm5"G31 P500 X-18 Y24 Z2.917
M556 S50 X0 Y0 Z0 ; set orthogonal axis compensation parameters
M557 X20:600 Y20:620 S58 ; define mesh grid 420 points S58M376 H10 ; Height (mm) over which to taper off the bed compensation 10, 30
; Heaters___________________________________________________________
M140 H-1 ; disable heated bed (overrides default heater mapping);E0_________________________________________________________________
M308 S0 P"spi.cs1" Y"rtd-max31865"
M950 H0 C"e0heat" T0 ; create nozzle heater output on e0heat and map it to sensor 0
;M307 H0 B0 S1.00 ; PID calibration
;M307 H0 B0 R2.210 C296.8:231.2 D4.23 S1.00 V24.1 ; WAKÜ OLD
;M307 H0 B0 R3.431 C120.9:113.1 D5.70 S1.00 V23.9 ;NEW TAKOTO
M307 H0 B0 R3.818 C129.1:116.6 D3.00 S1.00 V23.9 ;New TAKOTO mit Wärmeleitpaste
M143 H0 S300 ; set temperature limit for heater 0 to 300°;E1_________________________________________________________________
M308 S1 P"spi.cs2" Y"rtd-max31865"
M950 H1 C"e1heat" T1 ; create nozzle heater output on e1heat and map it to sensor 1
;M307 H1 B0 S1.00 ; PID calibration
M307 H1 B0 R3.746 C151.8:132.3 D3.63 S1.00 V23.9 ; NEW TAKOTO
M143 H1 S300 ; set temperature limit for heater 1 to 300°; Fans______________________________________________________________
M950 F0 C"fan0" Q500 ; create fan 0 on pin fan0 and set its frequency
M106 P0 S0 H-1 ; set fan 0 value. Thermostatic control is turned on
M950 F1 C"fan1" Q500 ; create fan 1 on pin fan1 and set its frequency
M106 P1 S0 H-1 ; set fan 1 value. Thermostatic control is turned on
M950 F2 C"duex.fan7" Q500 ; create LED on pin fan2 and set its frequency
M106 P2 S0 H-1 ; Disable fan channel for LED
;M106 P2 S255 ; LED on by default
M950 F3 C"duex.fan5" Q500 ; create fan 3 on pin fan1 and set its frequency
M106 P3 S255 H0 T45 ; set fan 3 value. Thermostatic control is turned on
M950 F4 C"duex.fan6" Q500 ; create fan 4 on pin fan1 and set its frequency
M106 P4 S255 H1 T45 ; set fan 4 value. Thermostatic control is turned on; Tools______________________________________________________________
;T0_________________________________________________________________
M563 P0 S"E0 Primary" D0 H0 F0 ; define tool 0
G10 P0 X0 Y0 Z0 ; set tool 0 axis offsets
G10 P0 R0 S210 ; set initial tool 0 active and standby temperatures to 0C;T1_________________________________________________________________
M563 P1 S"E1 Secondary" D1 H1 F1 ; define tool 1
G10 P1 X0 Y49 Z0 ; set tool 1 axis offsets
G10 P1 R0 S210 ; set initial tool 1 active and standby temperatures to 0C; Automatic power saving____________________________________________
M911 S22.5 R29.0 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; Set voltage thresholds and actions to run on power loss. Power Failure Pause; Custom settings__________________________________________________
M950 J0 C"exp.e2stop" ; create Input Pin 0 on pin E2 to for M581 Command.
M581 T1 P0 S0 R1 ; Regular filament sensor for E0 As External Trigger
;M591 D0 P7 C"e1stop" S1 L4.2 E10 R10:300 ; Clog Detector E0 [Add-On]M950 J1 C"exp.e3stop" ; create Input Pin 1 on pin E3 to for M581 Command.
M581 T1 P1 S0 R1 ; Regular filament sensor for E1 As External Trigger
;M591 D1 P7 C"zstop" S1 L4.2 E10 R10:300 ; Clog Detector E1 [Add-On]M950 J2 C"exp.e4stop" ; create Input Pin 2 on pin E4 to for M581 Command.
;M581 T0 P2 S0 R0 ; Crash Detector [Add-On]Let me know which files you need
really thx for your help
Dieter -
So i run first the tilt and bed compansation:
results are:
15.2.2022, 05:57:08 Leadscrew adjustments made: 0.042 -0.019 -0.014 -0.015, points used 4, (mean, deviation) before (-0.003, 0.017) after (0.000, 0.000)
15.2.2022, 05:56:23 M98 P"0:/macros/Calibration macros/03_Tilt and Bed leveling"
Leadscrew adjustments made: -0.037 0.084 -0.059 0.062, points used 4, (mean, deviation) before (0.011, 0.037) after (0.000, 0.000)M292
121 points probed, min error -0.194, max error 0.068, mean -0.036, deviation 0.052
Height map saved to file 0:/sys/heightmap.csv -
And if you start a print at that point?
-
-
@phaedrux my head has a distance of around 2.4mm
so i run the z compansation
M300 S666 P666 ;
M291 S3 P"Press OK to continue, or CANCEL to abort"
G28
M564 H0 S0 ;Negative movements are allowed
M561 ;
G90 ;
;G1 X300 Y300 F6000;
G1 X20 Y100 F6000;
M300 S1111 P666 ;
G4 S1 ;
M291 S2 R"Height clearance" P"Place a paper sheet under the nozzle and raise the bed until slight friction can be noticed" Z1 ;
G92 Z0 ;
G91 ;
G1 Z11 F200 ;
G90
G4 S1 ;
M300 S666 P666 ;
M291 S2 R"Height clearance" P"Please remove the paper sheet and wait for the bed-probing to begin" ;
G30 S-1 ;
M564 S1 H1 ; Negative movements are forbidden
M291 S2 R"Height clearance" P"Copy the reported height value on the G-Code console and paste it into the config.g file" ;I moved the head down to 0.3mm
the result is:
15.2.2022, 08:56:42 M292
Stopped at height 2.622 mm
15.2.2022, 08:56:42 M98 P"0:/macros/Calibration macros/02_Z-Offset Calibration"
Stopped at height 2.622 mmso I add that value plus 0.3 ( 2.922) to the config.g
G31 P500 x-18 y24 z2.922save it and reset .
than i do homeall
with the command g0 x20 y100 z0.3 i move the head to the same position where i did the calibration for the 0.3mm.
during the run to the point all 4 motors for the bed are rotating. When it stops the value is 0.3mm , so correct.
then i move the head to the right front corner with the command:
g0 x600 y 100 z0.3
the head moves to that position and the 4 motors from the bed are rotating very little.
at the point x600 y100 i meassure a distance of 0.15 between bed and nozzle instead of 3mm.
the heightmap says at that point z-0.018mm
that my problem.
-
@fcwilt i don´t know why they using U axes.
-
@icy_snake said in Correction of heightmap is not really working:
@fcwilt i don´t know why they using U axes.
Who is "they?
I was looking at the contents of your config.g file and that is where U is created.
I can find no reason for doing that.
Frederick
-
@fcwilt thx, i did not write that, its the people from modix.
they wrote that file.the printer has following setup
4 motors for the bed
2 motors for x axis
1 motor for y axis
2 motors for extruder -
@icy_snake said in Correction of heightmap is not really working:
@fcwilt thx, i did not write that, its the people from modix.
they wrote that file.the printer has following setup
4 motors for the bed
2 motors for x axis
1 motor for y axis
2 motors for extruderThanks.
The folks at modix don't seem to know what they are doing. As a result you are having a tough time getting your printer working correctly.
In your config.g file you have these two commands:
M574 X1 S1 P"xstop" ; configure switch-type (e.g. microswitch) endstop for low end on X via pin xstop M574 U1 S1 P"e0stop" ; configure switch-type (e.g. microswitch) endstop for low end on X via pin xstop
Replace them with this:
M574 X1 S1 P"xstop + e0stop"
Then remove all references to U in the config.g and home all files and the M584, M400 and M375 commands in the home all file.
Reboot and issue G28 X to verify that X homes correctly.
You have two X steppers. The firmware supports multiple endstop sensors for an axis that has multiple steppers. Issuing a G1 H1 command to home such an axis causes each stepper to run until the endstop sensor associated with that stepper is triggered. The association is created in the M574 command for that axis where the two endstop sensors appear as I have shown above.
One we correct his problem we can work on:
- getting your Z probe configured correctly
- setting the Z=0 datum as needed
- creating mesh.g and populating it with the needed code
- correcting bed.g to only contain the needed code
Frederick
-
This post is deleted! -
This post is deleted! -
@icy_snake missed one M584
so it´s ok now no error message anymore -
@icy_snake Thx Frederick
i´m from germany Augsburg. You are from the USA, located Verginia? For time offset.
east cost 6 hours i´m ahead. -
Hello Frederick
I´m ready what i should do next.
One we correct his problem we can work on:
getting your Z probe configured correctly setting the Z=0 datum as needed creating mesh.g and populating it with the needed code correcting bed.g to only contain the needed code
-
Hi,
I'm just getting up. Got to get dressed and then get breakfast.
Then I will be back.
Frederick