Welcome! Log In Create A New Profile

Advanced

Auto-levelling on a CoreXY printer with a Duet controller

Posted by David J 
Auto-levelling on a CoreXY printer with a Duet controller
October 18, 2015 06:02AM
The title says it all really - I have a Duet board that will soon be going into the CoreXY printer that I'm currently building. I have (hopefully) sorted the config, homing, pause and resume files, updated to the latest web page source, and will shortly be updating the firmware to 1.09k (now done! smiling smiley ).

But, unfortunately, I have no idea how to implement auto-levelling... any guidance would be appreciated.

Edited 1 time(s). Last edit at 10/18/2015 06:52AM by David J.
Re: Auto-levelling on a CoreXY printer with a Duet controller
October 18, 2015 10:08AM
The modern way to do bed probing and compensation in RepRapFirmware is to set up a bed.g file. RepRapFirmware currently supports 3, 4 and 5 point bed compensation. I may add more general grid-based compensation in future. Assuming you want to use 5 point, set up 4 points to move clockwise around the bed starting from the corner nearest (0,0), followed by a point in the centre. For a 200 x 200mm bed it would be something like this:

M561 ; clear any existing bed transform
G30 P0 X10 Y10 Z-99999 ; top left
G30 P1 X10 Y190 Z-99999 ; top right
G30 P2 X190 Y190 Z-99999 ; bottom right
G30 P3 X190 Y10 Z-99999 ; bottom left
G30 P4 X100 Y100 Z-99999 S0 ; centre, and calibrate

You can put additional commands in bed.g if you wish, e.g. a G28 homing command at the start (after the M561 command) and/or a G1 command at the end to move the head to a corner of the bed at the end.

HTH David

Edited 1 time(s). Last edit at 10/18/2015 12:21PM 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: Auto-levelling on a CoreXY printer with a Duet controller
October 18, 2015 11:15AM
Ahh - I was wondering if it was along the same lines as for deltas. That's easy enough. smiling smiley

Thanks.
Re: Auto-levelling on a CoreXY printer with a Duet controller
October 18, 2015 11:48AM
For anyone planning to copy dc42's bit of code - there was a slight error in there - 2 lines were identical. winking smiley

Really easy to work it out, but just for the record I reckon it should be:

; Auto calibration routine

M561 ; clear any existing bed transform
G30 P0 X10 Y10 Z-99999      ; front left
G30 P1 X190 Y10 Z-99999     ; front right
G30 P2 X190 Y190 Z-99999    ; back right
G30 P3 X10 Y190 Z-99999     ; back left
G30 P4 X100 Y100 Z-99999 S0 ; centre, and calibrate

Note that I changed the comments just so they registered with my brain. smiling smiley

Not nit-picking, just want to help anyone else who may pick this up at a later date and not spot the deliberate error...

Edited 1 time(s). Last edit at 10/18/2015 11:49AM by David J.
Re: Auto-levelling on a CoreXY printer with a Duet controller
October 18, 2015 12:24PM
Thanks for pointing out the error. I have corrected the original. Your version goes anti clockwise around the bed, and I am not sure that will work.



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: Auto-levelling on a CoreXY printer with a Duet controller
October 18, 2015 12:49PM
OK - I'll copy yours instead. (always ready to take advice... winking smiley )

I'm not sure that the comments on each line match the actual positions though - but maybe that's just my brain post-Sunday-lunch.

Edited 1 time(s). Last edit at 10/18/2015 12:50PM by David J.
Re: Auto-levelling on a CoreXY printer with a Duet controller
October 18, 2015 01:07PM
Whether the comments match will depend on where you put (0,0). On my Cartesian printer it is the back left corner of the bed, because the Y axis is the bed, which moves left-right. On a CoreXY I guess it makes more sense for X to be left-right and Y to be front-back, in which case (0,0) will be front left.



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: Auto-levelling on a CoreXY printer with a Duet controller
October 18, 2015 01:39PM
Excellent - we're both right, for different reasons! ☺
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 15, 2015 06:57AM
Resurrecting this old thread...

Everything is now wired up and running, and I can home correctly in X, Y and Z. The only problem is with auto-levelling - I home all the axes (axisses?) with G28 and then send a G29 command - and nothing happens.

Is this the right command, and are there any missing parameters?

I have attached copies of my config.g and bed.g for reference.

Cheers,
David
Attachments:
open | download - config.g (2.5 KB)
open | download - bed.g (369 bytes)
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 15, 2015 09:22AM
For bed compensation in RepRapFirmware you use G32, not G29.



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: Auto-levelling on a CoreXY printer with a Duet controller
November 15, 2015 10:57AM
Ah - I thought it would be simple! smiling smiley

Many thanks...
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 15, 2015 11:40AM
...and that's working nicely. smiling smiley

One oddity though - it probes the right points on the bed, apart from the centre position - it should be X100 Y100, but instead it seems to be X100 Y80. If I send G1 X100 Y100 it does go the correct place on the bed.

Edited 1 time(s). Last edit at 11/15/2015 11:43AM by David J.
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 15, 2015 04:01PM
Quote
David J
...and that's working nicely. smiling smiley

One oddity though - it probes the right points on the bed, apart from the centre position - it should be X100 Y100, but instead it seems to be X100 Y80. If I send G1 X100 Y100 it does go the correct place on the bed.

That is odd. Are you certain that the bed.g file on the SD card is up to date with the one you posted?



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: Auto-levelling on a CoreXY printer with a Duet controller
November 15, 2015 04:34PM
There's only ever been one - but I will check again.
UPDATE: It is the same as the one I uploaded a couple of posts back, with a couple of amendments - latest one attached. (originally the IR sensor was overlapping the front edge of the bed).

As an aside - I have a few questions about the web interface, so who should I ask? (I will start a new thread anyway)

Edited 2 time(s). Last edit at 11/15/2015 04:50PM by David J.
Attachments:
open | download - bed.g (370 bytes)
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 15, 2015 06:54PM
The web interface is maintained by Christian Hammacher, aka forum user zombiepantslol. The best place to attract his attention is probably on the Ormerod forum.



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: Auto-levelling on a CoreXY printer with a Duet controller
November 16, 2015 05:33AM
David J, either post your question here or send me a PM. Meanwhile I watch this forum (and the developers forum) quite frequently too.
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 16, 2015 06:52AM
I'm not sure who to ask about this anyway, so I'll start here!

When I used my Duet 0.6 board on a delta, I used various macros - these macros appeared on the web interface. I've since moved the board to a CoreXY printer, upgraded dc42's firmware to the 'k' version and updated the www directory to what I -think- is a recent version* from David's repository, and now I can't find any mention of the macros.

* the reprap.html code shows v1.06 in the comments - but it was 1.06 in the delta version!

Also - the fast filament load and unload for bowden seems to be missing.

I suspect that I'm not running the right stuff in the www directory, or it's not set up correctly, so I'm looking for a few clues to get me on the right path.

Cheers,
David
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 16, 2015 06:59AM
The latest version of the web interface is here [github.com]. I think my repo is up to date with it now, but a few weeks ago it wasn't.



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: Auto-levelling on a CoreXY printer with a Duet controller
November 16, 2015 08:08AM
I'll give that a try...
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 16, 2015 08:43AM
That's sorted it - I now have the web interface I am used to. smiling smiley

David - I wasn't having a pop at you, I probably picked the files up from the wrong place.

I now have a new problem! When I first home X and Y the console stays clear, as expected. After running G32, when I subsequently home either axis I get the following error message (in this case, after homing X).
G28 X
Error: Triangle interpolation: point outside all triangles!
I guess that I haven't configured something properly - any clues?
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 16, 2015 09:20AM
Here's a video of the wrong positioning:

Positioning error

If you look carefully at the print bed you can see the central hole where the thermocouple goes - I've set the end stops so that this is dead centre when I send G1 X100 Y100.
You will see that the last G32 test point is at X100 Y~80.

The sequence shown is:
  1. Send the print head to some random position
  2. Home the printer
  3. Send G32
  4. Send G1 X100 Y100 (just to show that it will go to the right position normally)

Apologies for the rubbish focussing, and ignore the motor noises (I haven't adjusted the motor currents properly).
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 16, 2015 05:22PM
Quote
David J
That's sorted it - I now have the web interface I am used to. smiling smiley

David - I wasn't having a pop at you, I probably picked the files up from the wrong place.

I now have a new problem! When I first home X and Y the console stays clear, as expected. After running G32, when I subsequently home either axis I get the following error message (in this case, after homing X).
G28 X
Error: Triangle interpolation: point outside all triangles!
I guess that I haven't configured something properly - any clues?

That's a known issue. It's been there ever since RepRapPro implemented the 5-point bed compensation. It's harmless enough, but one of these days I'll get around to fixing it.



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: Auto-levelling on a CoreXY printer with a Duet controller
November 16, 2015 06:35PM
I would like to get to the bottom of this, but I am tied up with other things at present. Feel free to remind me of this issue towards the end of the week.

Quote
David J
Here's a video of the wrong positioning:

Positioning error

If you look carefully at the print bed you can see the central hole where the thermocouple goes - I've set the end stops so that this is dead centre when I send G1 X100 Y100.
You will see that the last G32 test point is at X100 Y~80.

The sequence shown is:
  1. Send the print head to some random position
  2. Home the printer
  3. Send G32
  4. Send G1 X100 Y100 (just to show that it will go to the right position normally)

Apologies for the rubbish focussing, and ignore the motor noises (I haven't adjusted the motor currents properly).



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: Auto-levelling on a CoreXY printer with a Duet controller
November 21, 2015 06:11AM
Quote
dc42
I would like to get to the bottom of this, but I am tied up with other things at present. Feel free to remind me of this issue towards the end of the week.

Reminder, as you invited! winking smiley

This doesn't seem to be a big issue, as the prints do seem to come out correctly - although I haven't yet done a print that covers the entire bed. Be nice to get it behaving properly though.
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 21, 2015 09:08AM
David, there is a very early beta of 1.09m at [dl.dropboxusercontent.com]. It includes a couple of fixes to the CoreXY motion code, which might have a bearing on the problem you reported. So please try it - but use it with care, because it needs as lot more testing before I do a release based on it.

Edited 1 time(s). Last edit at 11/21/2015 01:33PM 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: Auto-levelling on a CoreXY printer with a Duet controller
November 21, 2015 11:08AM
I'll bear that in mind - but as this machine is new to me I'm still proceeding cautiously until I'm fully up to speed with the way it works. If a fault springs from that stuff I need to know that it's the code not the printer!

Though it's very likely that I will have a go... smiling smiley
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 25, 2015 11:10AM
Late update: I tried to print something a bit larger today, and found out that auto-levelling isn't doing its job properly - one side of the first layer was very thin, and the opposite side was fat.

David, I will try your beta software this evening. Is the version you posted still good for trying out? Or is there a later one? (I have downloaded 'm' already).

Edited 1 time(s). Last edit at 11/25/2015 02:00PM by David J.
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 25, 2015 05:49PM
I updated it again yesterday evening.



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: Auto-levelling on a CoreXY printer with a Duet controller
November 26, 2015 04:59AM
Thanks - I'll download it, and apply it later today.

EDIT: Just tried it - the nozzle still goes to X100 Y~80 on the 5th probe.

Edited 1 time(s). Last edit at 11/26/2015 05:10AM by David J.
Re: Auto-levelling on a CoreXY printer with a Duet controller
November 26, 2015 05:27AM
David, at the end of the 5th probe, does the printer think it's at Y=80 or Y=100?

If it thinks it's at Y=100, then perhaps your travel speed or acceleration settings are too high and you are losing steps? You can change the travel speed between probe points using the T parameter in the M558 command.

Edited 1 time(s). Last edit at 11/26/2015 05:28AM 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].
Sorry, only registered users may post in this forum.

Click here to login