Mesh bed leveling G29 issues
-
The Mesh is working when testing with tailored significant corrections -test heightmap similar to this one (15 points):
20.0, 20.0, 10.0, 10.0, 10.0 0.0, 0.0, 0.0, 0.0, 0.0 -10.0, -10.0, -10.0, -20.0, -20.0
I noticed sometimes if applying mesh two times, the Z axis motor steps count got lost by 10mm (or 6000steps) while showing that the virtual position is still 0mm (by using M114). This would be really hard to detect if the increments are much smaller like 0.03mm. Of course G29 S2 should be able to solve it, but still there is so many issues that it maybe good to check. This requires some more tools. Could somebody with encoder confirm this?
It seems likely that only short movements are affected on first layer.
So I was wondering if grid size has some effect.@dc42 mentions in thread Testing the effects of changing microstepping and segmentation that "The only time RRF normally uses segmentation is when using mesh bed leveling and a move is longer than the grid spacing." Its also mentioned in the Gcode Wiki (in regards setting up other kinematics like delta etc.)
But in another thread, first layer extrusion (?) issues
the same issue happens with heated bed / Delta configuration printer.Could this be still related to the mentioned segmentation? Is there way to change or configure segmentation now in RRF 3 for Cartesian machines?
Could you please explain how the Mesh bed algorithm and segmentation connection is done in RRF? @fcwilt
-
@petriheino said in Mesh bed leveling G29 issues:
I noticed sometimes if applying mesh two times, the Z axis motor steps count got lost by 10mm (or 6000steps)ow in RRF 3 for Cartesian machines?
What do you mean by "applying the mesh two times"?
Could you please explain how the Mesh bed algorithm and segmentation connection is done in RRF? @fcwilt
I would if I knew anything about that topic but I don't.
Sorry.
Frederick
-
What issues are you actually having? You never really explain what problem you're having.
For best results, please share with us your config.g, homeall.g, homez.g, bed.g, start.g if used, and your slicer start gcode section so that we can see what happens between turning on your printer and when a print starts.
Share also an image of your heightmap display, and the results of M122 and M98 P"config.g".
-
/Sys/ folder codes
config.g; Configuration file for Duet WiFi (firmware version 3) G90 ; send absolute coordinates... M83 ; ...but relative extruder moves M550 P"Y51" ; set printer name ; Network M552 S1 ; enable network M586 P0 S1 ; enable HTTP M586 P1 S0 ; disable FTP M586 P2 S0 ; disable Telnet ; Drives M569 P0 S1 ; P0 = X-axis M569 P1 S0 ; P1 = Y-axis M569 P2 S0 ; P2 = Z-axis M569 P3 S1 ; P3 = Extruder 1 M584 X0 Y1 Z2 E3 ; set drive mapping M350 X16 Y16 Z16 I1 ; Microstepping X Y Z M350 E256 I0 ; Microstepping E M92 X80.00 Y80.00 Z400.0 E2210.000 ; set steps per mm M906 X2000 Y2000 Z1400 E1700 I30 ; set motor currents (mA) and motor idle factor in percent M84 S30 ; Set idle timeout ;Kinematics M566 X300 Y300 Z120 E3000 ;instantaneous speed change / Jerk (mm/min) M566 P1 ;Jerk policy M203 X6000 Y6000 Z1200 E6000 ;max speeds (mm/min) M201 X2000 Y2000 Z20 E9000 ;accelerations (mm/s^2) M204 P600 T600 ; Axis Limits M208 X0 Y0 Z0 S1 ; set axis minima M208 X195 Y165 Z210 S0 ; set axis maxima ; Endstops M574 X1 S1 P"xstop" ; configure active-high endstop for low end on X via pin null M574 Y1 S1 P"ystop" ; configure active-high endstop for low end on Y via pin null M574 Z2 S1 P"zstop" ; configure Z-probe endstop for high end on Z ; Z-Probe M950 S0 C"exp.heater3" ; create servo pin 0 for BLTouch M558 P9 C"^exp.e2stop" H5 F120 T1800 ;Bltouch setup G31 P25 X0 Y40 Z2.00 ;Higher Value = closer to bed M557 X10:190 Y40:140 P5:4 ; define mesh grid ; Heaters M308 S1 P"e0temp" Y"thermistor" T100000 B4980 C1.09016e-7 ; configure sensor 1 as thermistor on pin e0temp M950 H1 C"e0heat" T1 ; create nozzle heater output on e0heat and map it to sensor 1 M307 H1 B0 S1.00 ; disable bang-bang mode for heater and set PWM limit M143 H1 S300 ; set temperature limit for heater 1 to 300C ; Fans M950 F0 C"exp.heater4" Q250 ;Print cooling fan M106 P0 S0 H-1 ;Set fan 0 value. M950 F1 C"exp.heater5" Q250 ;Heatsink fan M106 P1 S255 H-1 ; Set fan 1 value M950 F2 C"fan2" Q250 ; LED M106 P2 S255 H-1 ; Set fan 2 value ; 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 ; Miscellaneous M575 P1 S1 B57600 ; enable support for PanelDue M501
Homeall.g
; homeall.g G91 ; relative positioning G1 H1 Z215 F1500 ; move Z up stopping at the endstop G1 H2 Z-0.5 F1200 ; go back a few mm G1 H1 Z215 F600 ; move slowly to Z axis endstop once more (second pass) G1 H1 X-205 Y-155 F5000 ; move quickly to X and Y axis endstops and stop there (first pass) G1 H2 X5 Y5 F3000 ; go back a few mm G1 H1 X-205 Y-155 F600 ; move slowly to X and Y axis endstops once more (second pass) G90 ; absolute positioning G92 X0 Y0 Z210 ; set Z position to axis maximum
Homez.g
G91 ; relative positioning G1 H1 Z215 F1800 ; move Z up until the endstop is triggered G1 H2 Z-0.5 F1200 ; go back a few mm G1 H1 Z215 F600 ; move slowly to Z axis endstop once more (second pass) G92 Z210 ; set Z position to axis maximum (you may want to adjust this) G90 ; absolute positioning
Bed.g
; bed.g ; called to perform automatic bed compensation via G32 ; ; generated by RepRapFirmware Configuration Tool v3.1.4 on Mon Oct 19 2020 17:24:09 GMT+0300 (Eastern European Summer Time) M561 ; clear any bed transform ; Probe the bed at 7 points G30 P0 X0 Y84.9 H0 Z-99999 G30 P1 X73.53 Y-42.45 H0 Z-99999 G30 P2 X-73.53 Y-42.45 H0 Z-99999 G30 P3 X0 Y42.4 H0 Z-99999 G30 P4 X36.72 Y-21.2 H0 Z-99999 G30 P5 X-36.72 Y-21.2 H0 Z-99999 G30 P6 X0 Y0 H0 Z-99999 S
start.g
;****start.g**** ;****setup print**** G29 S2 ; clear previous height map G21 ; units to mm G90 ; absolute positioning M83 ; relative extruder mode M280 P0 S160 ; BLTouch alarm release G4 P100 ; delay for BLTouch G28 ; home all M400 ; Finish commands ;****BLTouch routine**** G1 X10 Y0 Z15 F9000 ; probe one point 1/2 G30 ; probe one point 2/2 G29 ; Option: probe heightmap ;****Pressure advance [PA], default values, for PLA**** M572 D0 S0.06 ; PA value S0.** M400 ; Finish commands
Slicer start gcode
M83 ; relative extrusion mode ;Pressure advance M572 D0 S0.06 ;Pressure advance enabled M400 ; Finish all current moves and for pressure advances. ;Wipe nozzle before printing G1 Z10 F1200 ; Go to wipe position G1 X20 Y165 F6000 ; Go to wipe position G1 Z0.2 F1200 ; Go to wipe height G91 ; relative movement for wipe extrusion G1 E10.0 F300 ; Extrude 10mm for wipe M400 ; wait for moves to finishng G90 ; world coordinate position G92 E0 ; zero extruder G4 S1 ; wait for wipe to drop G1 Y140.0 E1 F900 ; Move on bed wipe the nozzle ;START CODE END
Image of heightmap display
Heightmap.csv
RepRapFirmware height map file v2 generated at 2021-08-11 12:19, min error -0.058, max error 0.068, mean 0.007, deviation 0.034 axis0,axis1,min0,max0,min1,max1,radius,spacing0,spacing1,num0,num1 X,Y,10.00,190.00,40.00,140.00,-1.00,45.00,33.33,5,4 0.003, -0.003, -0.045, -0.045, -0.058 0.013, -0.020, -0.035, 0.023, -0.003 0.010, 0.015, 0.007, 0.043, 0.030 0.010, 0.033, 0.033, 0.068, 0.065
After print is ready:
M122M122 === Diagnostics === RepRapFirmware for Duet 2 WiFi/Ethernet version 3.3 (2021-06-15 21:44:54) running on Duet WiFi 1.02 or later Board ID: 0JD0M-9P6M2-NW4SN-6J9D6-3S86K-TBTML Used output buffers: 3 of 24 (20 max) === RTOS === Static ram: 23876 Dynamic ram: 75104 of which 0 recycled Never used RAM 12580, free system stack 114 words Tasks: NETWORK(ready,14.0%,237) HEAT(delaying,0.0%,330) Move(notifyWait,0.1%,313) MAIN(running,85.7%,445) IDLE(ready,0.1%,29), total 100.0% Owned mutexes: WiFi(NETWORK) === Platform === Last reset 00:21:45 ago, cause: software Last software reset at 2021-08-11 11:54, reason: User, GCodes spinning, available RAM 15112, slot 2 Software reset code 0x0003 HFSR 0x00000000 CFSR 0x00000000 ICSR 0x0041f000 BFAR 0xe000ed38 SP 0x00000000 Task MAIN Freestk 0 n/a Error status: 0x00 Aux0 errors 0,0,0 Step timer max interval 0 MCU temperature: min 41.0, current 43.4, max 44.6 Supply voltage: min 23.8, current 24.2, max 24.4, under voltage events: 0, over voltage events: 0, power good: yes Heap OK, handles allocated/used 99/0, heap memory allocated/used/recyclable 2048/12/12, gc cycles 0 Driver 0: position 14234, standstill, SG min/max 0/16 Driver 1: position 5394, standstill, SG min/max 0/140 Driver 2: position 158, standstill, SG min/max 0/234 Driver 3: position 0, standstill, SG min/max not available Driver 4: position 0, standstill, SG min/max not available Driver 5: position 0 Driver 6: position 0 Driver 7: position 0 Driver 8: position 0 Driver 9: position 0 Driver 10: position 0 Driver 11: position 0 Date/time: 2021-08-11 12:37:54 Cache data hit count 4294967295 Slowest loop: 155.31ms; fastest: 0.17ms I2C nak errors 0, send timeouts 0, receive timeouts 0, finishTimeouts 0, resets 0 === Storage === Free file entries: 10 SD card 0 detected, interface speed: 20.0MBytes/sec SD card longest read time 4.0ms, write time 5.0ms, max retries 0 === Move === DMs created 83, maxWait 291335ms, bed compensation in use: mesh, comp offset 0.000 === MainDDARing === Scheduled moves 1210, completed moves 1210, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 2], CDDA state -1 === AuxDDARing === Scheduled moves 0, completed moves 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1 === Heat === Bed heaters = -1 -1 -1 -1, chamberHeaters = -1 -1 -1 -1 Heater 1 is on, I-accum = 0.6 === GCodes === Segments left: 0 Movement lock held by null HTTP is idle in state(s) 0 Telnet is idle in state(s) 0 File is idle in state(s) 0 USB is idle in state(s) 0 Aux is idle in state(s) 0 Trigger is idle in state(s) 0 Queue is idle in state(s) 0 LCD is idle in state(s) 0 Daemon is idle in state(s) 0 Autopause is idle in state(s) 0 Code queue is empty. === Network === Slowest loop: 183.07ms; fastest: 0.00ms Responder states: HTTP(2) HTTP(4) HTTP(0) HTTP(0) FTP(0) Telnet(0), 0 sessions HTTP sessions: 1 of 8 - WiFi - Network state is active WiFi module is connected to access point Failed messages: pending 0, notready 0, noresp 0 WiFi firmware version 1.23 WiFi MAC address 84:0d:8e:b2:f4:92 WiFi Vcc 3.38, reset reason Turned on by main processor WiFi flash size 4194304, free heap 23416 WiFi IP address 192.168.86.114 WiFi signal strength -57dBm, mode none, reconnections 0, sleep mode modem Clock register ffffffff Socket states: 4 2 0 0 0 0 0 0
M98 P"config.g"
M98 P"config.g" HTTP is enabled on port 80 FTP is disabled TELNET is disabled Error: bad model parameters
-
Hi @Phaedrux , configs in previous post (cartesian coordinate system, direct extruder, BLTouch).
The error is exactly the same as in this thread: first layer extrusion (?) issues
When starting a print, first layer height variation is +-0.05 .... +-0.15mm.
@fcwilt if not using G29 S2 in start.g file, then z motor stepcount gets lost when repeating measurement with G30 -> G29. This can be seen by using M114 and comparing the Z stepcount.
-
@petriheino said in Mesh bed leveling G29 issues:
first layer extrusion (?) issues
I'd be cautious comparing to that issue being that it's a delta printer which has many considerations of it's own with geometry and calibration. Plus in that case it seems mostly an issue of over extrusion and perhaps fingerprints on the bed.
I notice your bed.g file is setup for the old style compensation which is no longer recommended. Are you actually using G32 at all in your routine?
I also notice that you are homing to Z max with an endstop. This isn't an issue in and of itself because I also see that you are homing with the probe before actually meshing the bed and starting the print. It would also be wise to move the point you probe from the corner to the center of the bed, since that's typically where you will actually be printing.
I would note that for your heightmap it's a bit sparse at only 20 points along a narrow band of the bed surface. I would suggest doing a more detailed mesh over as large an area of your bed surface as the probe can actually reach by altering your M557 command. If there are any ripples of variables between the probe points there's no way to adjust for that since the firmware uses interpolation between the points. The downside to more points is that it takes more time to complete, but if the bed is otherwise stable, you can just reload the saved detailed heightmap at the start of the print rather than reprobing fresh each time. At the very least doing a detailed mesh is useful for seeing what the surface is actually like.
-
One thing I never see suggested is that if a user suspects that the bed profile is not being applied to a print, is to try this:
- Tape something like a strip of thick construction paper across the bed.
- Do a bed profile
- View the bed profile, and it should clearly show the "lump" in the bed.
- Remove the paper
- Do a fake print (no filament) that crosses that area and watch the Z clearance. When it gets to where the paper was, you should see the nozzle move away from the bed as it approaches.
-
I did that very thing but not intentionally.
I use a 1mm thickness gauge to determine if the position Z=1 puts the tip of the nozzle 1mm off the bed.
I happened to have left the gauge on the bed and created a height map.
As luck would have it the probe did encounter the gauge and the height map clearly reflected that.
Frederick
-
@fcwilt Yeah I've left a few items on the bed and get firmly reminded when the nozzle moves!
-
@phaedrux Would you recommend trying with the
G32
command?
How many points, and whichS
parameter to use inbed.g
?Tested, G30 corner vs. center, could not notice difference in first layer print quality.
Here is picture of heightmap with 400 points (20x20 grid). Near center of plate, there is a hole, as seen from heightmap.
Note: Buildplate was removed/inserted back in between measurements.Heightmap.csv
RepRapFirmware height map file v2 generated at 2021-08-13 09:50, min error -0.395, max error 0.037, mean -0.011, deviation 0.028 axis0,axis1,min0,max0,min1,max1,radius,spacing0,spacing1,num0,num1 X,Y,10.00,190.00,40.00,140.00,-1.00,9.47,5.26,20,20 -0.010, -0.020, -0.028, -0.040, -0.045, -0.050, -0.040, -0.030, -0.040, -0.030, -0.025, -0.023, -0.023, -0.028, -0.025, -0.033, -0.043, -0.050, -0.058, -0.060 -0.010, -0.013, -0.023, -0.033, -0.038, -0.035, -0.035, -0.038, -0.033, -0.028, -0.020, -0.020, -0.018, -0.020, -0.025, -0.025, -0.033, -0.038, -0.040, -0.030 -0.010, -0.018, -0.023, -0.028, -0.023, -0.018, -0.023, -0.025, -0.023, -0.025, -0.018, -0.023, -0.020, -0.023, -0.028, -0.025, -0.025, -0.025, -0.035, -0.035 -0.010, -0.018, -0.015, -0.015, -0.008, -0.013, -0.018, -0.023, -0.025, -0.025, -0.025, -0.020, -0.020, -0.018, -0.028, -0.020, -0.008, -0.008, -0.020, -0.015 -0.008, -0.015, -0.013, -0.018, -0.003, -0.003, -0.005, -0.008, -0.013, -0.023, -0.030, -0.028, -0.025, -0.025, -0.035, -0.023, -0.013, -0.010, -0.008, -0.010 -0.008, -0.015, -0.015, -0.008, 0.005, 0.005, 0.003, -0.003, -0.018, -0.030, -0.030, -0.023, -0.025, -0.028, -0.030, -0.023, -0.013, -0.003, -0.005, -0.005 -0.015, -0.018, -0.015, -0.008, 0.005, 0.007, 0.007, 0.010, -0.018, -0.028, -0.040, -0.025, -0.013, -0.030, -0.040, -0.038, -0.015, 0.000, 0.000, -0.005 -0.010, -0.015, -0.010, -0.010, 0.013, 0.013, 0.010, 0.000, -0.010, -0.028, -0.395, -0.023, -0.003, -0.020, -0.045, -0.030, -0.008, 0.005, 0.010, 0.005 -0.020, -0.018, -0.015, -0.008, 0.013, 0.020, 0.015, 0.005, -0.005, -0.025, -0.038, -0.023, -0.008, -0.018, -0.028, -0.020, -0.003, 0.007, 0.007, 0.007 -0.015, -0.018, -0.020, -0.013, 0.013, 0.023, 0.010, 0.003, -0.005, -0.020, -0.030, -0.028, -0.008, -0.013, -0.015, -0.008, 0.005, 0.013, 0.017, 0.017 -0.020, -0.025, -0.023, -0.030, -0.013, 0.005, -0.003, -0.005, -0.015, -0.028, -0.030, -0.028, -0.023, -0.010, -0.005, 0.000, 0.023, 0.023, 0.025, 0.020 -0.025, -0.028, -0.023, -0.015, -0.008, 0.005, 0.017, 0.007, 0.000, -0.005, -0.010, -0.015, -0.008, 0.000, 0.005, 0.017, 0.033, 0.030, 0.025, 0.017 -0.025, -0.030, -0.028, -0.025, -0.005, 0.003, 0.003, 0.000, -0.003, -0.003, -0.008, -0.005, 0.000, 0.003, 0.015, 0.025, 0.030, 0.033, 0.025, 0.020 -0.033, -0.030, -0.033, -0.033, -0.018, -0.005, 0.003, 0.003, -0.003, -0.003, 0.000, -0.003, 0.007, 0.010, 0.015, 0.035, 0.033, 0.030, 0.025, 0.020 -0.033, -0.035, -0.035, -0.035, -0.018, -0.015, -0.015, -0.005, -0.008, -0.005, -0.005, 0.005, 0.007, 0.013, 0.025, 0.033, 0.035, 0.033, 0.030, 0.023 -0.030, -0.035, -0.030, -0.040, -0.028, -0.020, -0.015, -0.013, -0.008, -0.005, -0.005, 0.005, 0.010, 0.020, 0.027, 0.035, 0.033, 0.035, 0.030, 0.023 -0.030, -0.030, -0.028, -0.038, -0.040, -0.028, -0.023, -0.015, -0.018, -0.008, -0.010, 0.005, 0.007, 0.023, 0.027, 0.030, 0.030, 0.023, 0.020, 0.003 -0.028, -0.033, -0.040, -0.045, -0.045, -0.043, -0.030, -0.023, -0.020, -0.008, -0.003, 0.003, 0.015, 0.023, 0.030, 0.035, 0.030, 0.023, 0.005, 0.013 -0.028, -0.028, -0.038, -0.043, -0.045, -0.043, -0.040, -0.030, -0.023, -0.013, -0.010, 0.005, 0.015, 0.025, 0.025, 0.033, 0.030, 0.017, 0.013, 0.003 -0.025, -0.028, -0.038, -0.045, -0.043, -0.043, -0.038, -0.035, -0.025, -0.020, -0.008, 0.000, 0.010, 0.023, 0.027, 0.037, 0.030, 0.023, 0.007, 0.003
-
Well the bed itself looks quite flat and level, so there isn't much work for the mesh to do. If you're still having issues with the first layer I would start to look elsewhere.
Can you show a photo of what your resulting prints look like and what settings you're using?
The probe trigger offset needs to be accurate for the height to be correct.
The print temp on the nozzle and bed need to be correct.
The bed itself needs to be clean and free of oils.
The extruder flow rate needs to be accurate.
The print speed needs to be rather slow and low jerk/acceleration for best results on the first layer.
Increasing the extrusion width can also be useful to get more surface area contact and squish.
-
@petriheino -Did you probe cold or preheated bed? Some bed have thermal big deformation....