MarlinFirmware / Marlin

Marlin is an optimized firmware for RepRap 3D printers based on the Arduino platform. Many commercial 3D printers come with Marlin installed. Check with your vendor if you need source code for your specific machine.
https://marlinfw.org
GNU General Public License v3.0
16.22k stars 19.22k forks source link

[FR] G26 pattern is needlessly slow and troublesome #9430

Open chambm opened 6 years ago

chambm commented 6 years ago

Thanks for maintaining this great firmware!

When I was using bilinear leveling I would never use G26 because it was so much faster and less error prone to use a test pattern like this: https://www.thingiverse.com/thing:2751421 image

But of course this pattern doesn't know anything about the mesh coordinates. But it prints without any retractions, which makes it faster and easier to print (i.e. if the nozzle offset is wrong the print doesn't turn into a huge mess of disconnected circles).

Is it feasible to add an option for G26 to print continuously without retractions? I'd like to use UBL because it allows more mesh points.

tcm0116 commented 6 years ago

It would also be great if G26 could be cancelled and if you could still use the LCD while it's running to do things like adjust the Z offset.

mylife4aiurr commented 6 years ago

It would also be great if G26 could be cancelled and if you could still use the LCD while it's running to do things like adjust the Z offset.

Cant you cancel a running G26 by holding the click wheel in? Mistaken?

Roxy-3D commented 6 years ago

Cant you cancel a running G26 by holding the click wheel in? Mistaken?

Yes. As well as other long functions like G29 P1

I'm in the process of adding a 'F' ast option to G26 that will print straight lines all the way across the bed and no circles at the mesh points. (I had to move the 'F' filament option to a new letter.)

Is it feasible to add an option for G26 to print continuously without retractions? I'd like to use UBL because it allows more mesh points.

Yes... That is a good idea. We could add a 'N' parameter so G26 N doesn't do retraction. 'N' could be "No Retractraction". But the GCode Nazi's will have an aneurysm. Is there an easy to remember way to tell G26 not to do retractions??? (The other thing that has to be done better is allow different amounts retraction and priming. Right now it is fixed at a ratio of 1.0 mm of retraction and 1.2 mm or priming. That clearly doesn't work for every machine.)

chambm commented 6 years ago

Yes we can cancel easily but we can't baby step. Baby step would be very useful for assisting the overall mesh level.

Fast mode sounds great! After posting this I thought about it and the (diagonal) lines will be much better for sure, but some infill-like parts along the path would also be helpful to easily see whether the lines are being squashed enough to close gaps. And it can still be done without retraction. Thanks for considering it!

Squid116 commented 6 years ago

@Roxy-3D if available you could enable fwretract for g26? that way could use the printer's settings to set retraction.

chambm commented 6 years ago

Allow Q to be set to 0 to disable retraction? No new letter needed, just documentation. :)

Roxy-3D commented 6 years ago

After posting this I thought about it and the (diagonal) lines will be much better for sure, but some infill-like parts along the path would also be helpful to easily see whether the lines are being squashed enough to close gaps. And it can still be done without retraction.

Diagonal makes sense for a number of reasons. I was already thinking about how (as an option) to rotate the mesh validation pattern by 45 degrees.

if available you could enable fwretract for g26? that way could use the printer's settings to set retraction.

All of the code that does Firmware Retraction is available to be called by any sub-function of UBL. What are you thinking? (If firmware retraction is available... It defaults to be what happens???)

Allow Q to be set to 0 to disable retraction? No new letter needed, just documentation. :)

Yeah!!! Of course. At least it is documented in the code!!!!

   *
   *   Q #  Multiplier  Retraction Multiplier. Normally not needed. Retraction defaults to 1.0mm and
   *                    un-retraction is at 1.2mm   These numbers will be scaled by the specified amount
   *
   *   R #  Repeat      Prints the number of patterns given as a parameter, starting at the current location.
   *                    If a parameter isn't given, every point will be printed unless G26 is interrupted.
   *                    This works the same way that the UBL G29 P4 R parameter works.
   *
   *                    NOTE:  If you do not have an LCD, you -must- specify R. This is to ensure that you are
   *                    aware that there's some risk associated with printing without the ability to abort in
   *                    cases where mesh point Z value may be inaccurate. As above, if you do not include a
   *                    parameter, every point will be printed.
Squid116 commented 6 years ago

@Roxy-3D yeah if the user has fwretraction enabled then the g26 pattern should use g10/g11 instead of manually specifying retractions.

Roxy-3D commented 6 years ago

If the user has enabled firmware retraction... My guess is they want it enabled during calibration type things as well as during the printing phases. Because that is what we are talking about doing.

chambm commented 6 years ago

When doing Mesh Edit, is it supposed to be the nozzle that moves to the mesh point, or the probe? I got the list of mesh points reported by G29 W1:

MESH_X = [0.000,14.286,28.571,42.857,57.143,71.429,85.714,100.000,114.286,128.571,142.857,157.143,171.429,185.714,200.000];
MESH_Y = [30.000,42.429,54.857,67.286,79.714,92.143,104.571,117.000,129.429,141.857,154.286,166.714,179.143,191.571,204.000];

When I use Mesh Edit to go to the various points, when I go to [0,0] it goes to X0, Y0. When I go to [14,14] it goes to X200 Y204. Why isn't [0,0] in the mesh at X0 Y30 (my probe Y offset is set to 30)?

I'm trying to find an ideal substitute for G26, because it's just infuriating for me to sit and watch it blob filament on my nozzle even with the nozzle at very close to the right height. I'm currently trying with a pattern like: image

Where each line passes through a diagonal of the mesh points. The pattern is 2 pairs of parallel lines for each diagonal, with a gap between the pair. Each line of the pair will be double the extrusion width, while the gap should be half the extrusion width. If the gap is bigger than that (or if there's a gap between the outer 2 lines, which should have no gap), then that part of the mesh is too high. If the gap is squished or the 2 pairs are joined, the mesh is too low. But this only works if I can use the Mesh edit tool precisely so that I know which point I'm editing. In other words, either the nozzle or the probe should be over the point(s) that I'm editing.

My relevant defines:

#define X_PROBE_OFFSET_FROM_EXTRUDER 0     // X offset: -left  +right  [of the nozzle]
#define Y_PROBE_OFFSET_FROM_EXTRUDER 30     // Y offset: -front +behind [the nozzle]
#define X_BED_SIZE 200
#define Y_BED_SIZE 205
#define X_MAX_POS X_BED_SIZE
#define Y_MAX_POS Y_BED_SIZE
#define MESH_INSET 0
qwewer0 commented 3 years ago

@chambm Could you test G26 on the latest bugfix-2.0.x, maybe with this https://github.com/MarlinFirmware/Marlin/issues/20615?

Sebazzz commented 3 years ago

I've been trying to adapt G26 to draw filled circles instead of crosshairs, in an attempt to make it a good bit more useful:

image

I'm not sure if it is due to the arcing, but I'm running into what appears to be slight overextrusion.

zalexzperez commented 3 years ago

Is there a way to increase the travel speed for the G26 pattern test? It's painfully slow... and filament starts to ooze between points.

qwewer0 commented 3 years ago

Is there a way to increase the travel speed for the G26 pattern test? It's painfully slow... and filament starts to ooze between points.

Do you mean G26_XY_FEEDRATE_TRAVEL?