Auto Bed Leveling PINDA



  • It´s frustrating. I got everything running and Mesh Bed leveling was working fine. Until I started the first bigger print... At some points its too low and at some others it´s too high... Without any rule...

    Thats my config.g:

    ; Configuration file for Duet WiFi (firmware version 1.21)
    ; executed by the firmware on start-up
    ;
    ; generated by RepRapFirmware Configuration Tool v2.0.4 on Sat Sep 14 2019 17:19:08 GMT+0200 (Mitteleuropäische Sommerzeit)

    ; General preferences
    G90 ; send absolute coordinates...
    M83 ; ...but relative extruder moves
    M550 P"Steffens JG Aurora" ; set printer name

    ; Network
    M552 S1 ; enable network
    M586 P0 S1 ; enable HTTP
    M586 P1 S0 ; disable FTP
    M586 P2 S1 ; enable Telnet
    M552 P10.115.111.109 ; (0 = DHCP)
    M554 P10.115.111.108 ; Gateway
    M553 P255.255.255.0 ; Netmask

    ; Drives
    M569 P0 S1 ; physical drive 0 goes forwards
    M569 P1 S0 ; physical drive 1 goes backwards
    M569 P2 S0 ; physical drive 2 goes backwards
    M569 P3 S1 ; 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 Z803.37 E408.92 ; set steps per mm
    M566 X600.00 Y300.00 Z12.00 E300.00 ; set maximum instantaneous speed changes (mm/min)
    M203 X15000.00 Y15000.00 Z1800.00 E12000.00 ; set maximum speeds (mm/min)
    M201 X1500.00 Y1500.00 Z200.00 E2000.00 ; set accelerations (mm/s^2)
    M906 X1000 Y1000 Z1000 E1000 I30 ; 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 X320 Y305 Z305 S0 ; set axis maxima

    ; Endstops
    M574 X1 Y1 Z1 S0 ; set active low and disabled endstops
    M574 Z1 S2 ; Set endstops controlled by probe

    ; Z-Probe
    M558 P5 H2 F5000 T12000 ; Set Z probe type to switch and the dive height + speeds
    G31 P800 X40 Y-5 Z1.54 ; 1.54 is the calculated Set Z probe trigger value, offset and trigger height
    ; The larger the number the closest it gets to the bed
    ;i.e. 1.50 puts the nozzle closer to the bed than 1.20
    M851 Z-0.25 ; Z Offset
    M557 X50:300 Y0:290 S15 ; Define mesh grid

    ; Heaters
    M307 H0 B0 S1.00 ; disable bang-bang mode for the bed heater and set PWM limit
    M305 P0 T100000 B4138 R4700 ; set thermistor + ADC parameters for heater 0
    M143 H0 S120 ; set temperature limit for heater 0 to 120C
    M305 P1 T100000 B4138 R4700 ; set thermistor + ADC parameters for heater 1
    M143 H1 S280 ; set temperature limit for heater 1 to 280C

    ; Fans
    M106 P0 S0 I0 F500 H T45 ; set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned on
    M106 P1 S1 I0 F500 H1 T45 ; set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned on

    ; 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
    M574 X1 Y1 Z0 S3
    M915 P0 S3 R0
    M915 P1 S5 R0

    M501 ;config override
    ; Miscellaneous
    T0 ; select first tool

    And thats my slicers beginning script:

    M104 S[first_layer_temperature] ; set extruder temp

    M140 S[first_layer_bed_temperature] ; set bed temp
    Tx

    M190 S[first_layer_bed_temperature] ; wait for bed temp

    M109 S[first_layer_temperature] ; wait for extruder temp
    G28 X;
    G28 Y;
    G28 Z;
    G32;
    G1 X0 Y0;
    G1 Z0.2
    G1 Y-3.0 F1000.0
    G1 X55.0 F2000.0

    G1 Z0.3 F1000.0
    G92 E0.0

    G1 X150.0 E25.0 F2200.0

    G1 Y-2.0 F1000.0

    G1 X55.0 E25 F1400.0

    G1 Z0.20 F1000.0

    G1 X5.0 E4.0 F1000.0

    G92 E0.0

    I hope somebody can help me.

    Have a nice day/evening.



  • Hi,

    Well I would suggest you first update to the most recent firmware.

    I see a M851 command - cannot find what it is supposed to do.

    I don't see a G29 command anywhere - this is used as part of mesh compensation.

    Frederick



  • @fcwilt Hey, will do this.

    Its supposed to give me a better overview over my offsets.

    The G29 is in my bed.g which is called with G32.

    William



  • @WillGIam said in Auto Bed Leveling PINDA:

    @fcwilt Hey, will do this.

    Its supposed to give me a better overview over my offsets.

    The G29 is in my bed.g which is called with G32.

    William

    I cannot find the M851 command anywhere. Can you provide a link to the description?

    And please post your bed.g file.

    Thanks.

    Frederick



  • M851 is not a supported gcode in reprapfirmware. https://reprap.org/wiki/G-code#M851:_Set_Z-Probe_Offset

    You should use the G31 z value to set the offset between probe trigger point and the nozzle touching the bed at Z0. As described here. https://duet3d.dozuki.com/Wiki/Test_and_calibrate_the_Z_probe

    Please include your homing files in addition to the bed.g

    If you run a G29 on it's own, what does the resulting bed height map image look like?



  • @Phaedrux said in Auto Bed Leveling PINDA:

    M851 is not a supported gcode in reprapfirmware. https://reprap.org/wiki/G-code#M851:_Set_Z-Probe_Offset

    You should use the G31 z value to set the offset between probe trigger point and the nozzle touching the bed at Z0. As described here. https://duet3d.dozuki.com/Wiki/Test_and_calibrate_the_Z_probe

    Please include your homing files in addition to the bed.g

    If you run a G29 on it's own, what does the resulting bed height map image look like?

    @fcwilt thanks for your answers!

    It's not supported? It's working fine 😳😂 I'm using this command on many printers with duet an there is no problem.

    I will post the other files later this day. But everything ist working fine, he is compensating at the first layer, but wrong.

    My Pinda offset is 38mm in X. Does this mean the Pinda is right from the nozzle or left?

    My heightmap looks good too. Will post that later too.



  • Funnily enough, M851 is in the firmware! https://github.com/dc42/RepRapFirmware/blob/590805f79240c2ebee1ff1fed229dee3827f81e5/src/GCodes/GCodes2.cpp#L4154

    	case 851: // Set Z probe offset, only for Marlin compatibility
    		{
    			ZProbe params = platform.GetCurrentZProbeParameters();
    			if (gb.Seen('Z'))
    			{
    				params.triggerHeight = -gb.GetFValue();
    				params.saveToConfigOverride = true;
    				platform.SetZProbeParameters(platform.GetZProbeType(), params);
    			}
    			else
    			{
    				reply.printf("Z probe offset is %.2fmm", (double)(-params.triggerHeight));
    			}
    		}
    		break;
    

    So it should work.

    Ian



  • @droftarts As I said: it does. But this is not the topic. Everything is working fine, at some points I'm getting great results...



  • @WillGIam Sure, but as everyone who had replied to you so far had mentioned it, I thought it would be good to clear that up. So, on to the problem...

    First, read this: https://blog.prusaprinters.org/prusa-tech-insider-1-mesh-bed-leveling/

    It points out a number of issues with PINDA probes:

    • "we found out that it’s necessary to minimize the measurement error with repeated measurements using the P.I.N.D.A. sensor. Therefore, there are repeated distance measurements during MBL process – typically 3 to 5 in one location."
    • "Another thing is, the P.I.N.D.A. sensor sensitivity is highly temperature-dependent."
    • "And then there was another issue – the magnets in the heatbed. These can throw off the readings"

    Could these be effecting the bed mesh? Can you post an image of your bed mesh?

    Ian



  • @droftarts Hey, this was no offense! I´m happy you posted the firmware quote.

    The first thing is a great hint. But how to probe more than one time at one point? thats only possible with bed.g, so I can´t probe every point I can now isnt it?

    I read the same about the temperature, so I heat up the bed before leveling see my homez.g:

    M203 Z500
    G91 ; relative positioning
    G1 Z5 F1000 S2 ; lift Z relative to current position
    G90 ; absolute positioning
    G1 X5 Y5 F12000 ; go to first probe point
    G30 ; home Z by probing the bed
    M203 Z1800

    The heatbed is too far away from the heatbed I think. Compared to Prusa 😄

    Thanks for your answer!



  • @WillGIam said in Auto Bed Leveling PINDA:

    But how to probe more than one time at one point?

    Check the M558 command for these parameters that you are not (it seems) currently using.

    From the online docs:

    Annn Maximum number of times to probe each point, default 1. Maximum, as of 2.03, is 31. Setting M558 A parameter to anything >31 set it to 0 instead of to 31

    Snnn Tolerance when probing multiple times, default 0.03mm

    The A and S parameters control multiple probing. Probing is repeated until two consecutive probe attempts produce results that differ by no more than the S parameter; then the average of those two results is used. However, if the number of attempts specified by the A parameter is reached without getting two consecutive results within tolerance of each other, no further probe attempts are made and the average result of all the attempts is used.

    Frederick



  • @fcwilt Yes, I did that today. The minimum tolerance is 0.1mm... That sounds a bit too much. Otherwise Im getting the unconsistent Z Probe readings error. I will try with 0.1 tolerance first.

    Thanks a lot for your help.



  • @fcwilt okay, tried it out: With S0.05 and A6 (he is only using 3) I get lower tolerance. I´m now trying to print a bigger part. Lets see what happens.



  • @droftarts said in Auto Bed Leveling PINDA:

    Funnily enough, M851 is in the firmware!

    Well whatdya know.



  • @WillGIam said in Auto Bed Leveling PINDA:

    @fcwilt okay, tried it out: With S0.05 and A6 (he is only using 3) I get lower tolerance. I´m now trying to print a bigger part. Lets see what happens.

    I think I recall that if you use S-1 that forces the number of readings set by A and then averages them.

    Frederick


Log in to reply