Welcome! Log In Create A New Profile

Advanced

Automatic bed level - How does it work?

Posted by bitfield 
Re: Automatic bed level - How does it work?
August 12, 2015 08:41AM
M561
G30 P0 X70 Y20 Z-100000 H0.25
G30 P1 X70 Y160 Z-100000 H0.05
G30 P2 X200 Y160 Z-100000 H-0.25
G30 P3 X200 Y20 Z-100000 H-0.25
G30 P4 X100 Y100 Z-100000 H0 S0

So this is all that's needed, in a new bed.g file? Then run G32 after startup?
Re: Automatic bed level - How does it work?
August 12, 2015 09:03AM
That should be all you need in a bed.g file. The RepRapPro sample one moves the head to the prob poits via separate G1 commands, but I've no idea why they do that. You can add a final command such as G1 Z10 if you want to lift the head away from the bed at the end.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: Automatic bed level - How does it work?
August 12, 2015 03:50PM
I wish I could tell it's all working, but ...

When I upload the bed.g file through the web interface it seems to get stuck on "Uploading File(s), 100% Complete (3.5 KiB/s)". After 10 to 15 seconds I get "Communication Error" "Please check your printer is still on" , etc. When I hit OK I can re-connect but X, Y, Z is no longer homed. It's as if the printer rebooted.
The file seems to be uploaded. At least it's showing up and it has the right size. But when I run Auto bed compensation it doesn't seem to bother about the bed.g. On the third point it tries to go to X222 and overrun the X axis.

Just to make sure Auto bed compensation didn't differ from G32 I tried to issue the command manually with same result.

Also G-Code console says:
G32
Bed equation fits points [60.0, 0.0, 0.512] [60.0, 165.0, -0.872] [222.0, 165.0, 0.680] [222.0, 0.0, 3.000]

Edited 1 time(s). Last edit at 08/12/2015 03:56PM by bitfield.
Re: Automatic bed level - How does it work?
August 12, 2015 05:49PM
You need to upload bed.g via the button on the Settings page of the web interface (so that it gets put into /sys), not the one on the Gcode Files page. Or upload it to /sys using FTP.

Edited 1 time(s). Last edit at 08/12/2015 05:49PM by dc42.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: Automatic bed level - How does it work?
August 13, 2015 07:01AM
Well of course. Sorry about that. Wonderful feeling to be able to just press Home All and then Auto bed compensation and all four points are good. I had to adjust H slightly because of changes made to the extruder part.

Only annoying thing right now is that my Duet is restarting every time I upload a file through the web interface.confused smiley

Thanks for all the help dc42. This would have taken me so much longer without all your help!

Edited 1 time(s). Last edit at 08/13/2015 07:09AM by bitfield.
Re: Automatic bed level - How does it work?
August 13, 2015 07:09AM
Hmm, I uploaded a new, bigger file (a real print) and that worked fine.
Re: Automatic bed level - How does it work?
August 13, 2015 08:10AM
Quote
bitfield
Only annoying thing right now is that my Duet is restarting every time I upload a file through the web interface.confused smiley!

Can you attach your bed.g file, so that I can try to reproduce the problem?

Edited 2 time(s). Last edit at 08/13/2015 08:12AM by dc42.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: Automatic bed level - How does it work?
August 13, 2015 10:14AM
Here it is. It's more or less what you originally gave me.
Attachments:
open | download - bed.g (165 bytes)
Re: Automatic bed level - How does it work?
August 13, 2015 11:03AM
Quote
bitfield
Here it is. It's more or less what you originally gave me.

Thanks. I just tried uploading that file like a regular print file (using the "Upload Gcode file(s)" button on the Files tab, and it uploads correctly for me.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: Automatic bed level - How does it work?
August 13, 2015 12:18PM
Would you mind posting the output of M122 after a crash occurred? A Wireshark dump might help as well...
Re: Automatic bed level - How does it work?
August 13, 2015 01:38PM
This is the output from M122 after a crash.

Platform Diagnostics:
Memory usage:
Program static ram used: 41408
Dynamic ram used: 43424
Recycled dynamic ram: 1184
Current stack ram used: 2872
Maximum stack ram used: 4276
Never used ram: 8012
Last reset 00:02:05 ago, cause: watchdog
Last software reset code & available RAM: 0x0003, 7668
Spinning module during software reset: GCodes
Last message before reset: Move class exited.
Error status: 0
Bed probe heights: 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000
Free file entries: 10
Longest block write time: 0.0ms
Slowest main loop (seconds): 0.012535; fastest: 0.000046
Move Diagnostics:
MaxReps: 0
Heat Diagnostics:
Heater 1: I-accumulator = 0.0
GCodes Diagnostics:
Move available? no
Network Diagnostics:
Free connections: 15 of 16
Free transactions: 23 of 24
Free send buffers: 19 of 20
Webserver Diagnostics:

I could try to do a wireshark dump later.
Re: Automatic bed level - How does it work?
August 13, 2015 02:25PM
So it's a hardware watchdog reset. I suspect a firmware bug either in lwip or the webserver that is causing memory corruption or a never-ending interrupt.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Sorry, only registered users may post in this forum.

Click here to login