Welcome! Log In Create A New Profile


Z Axis Stress Test and Z Feedrate (marlin)

Posted by Thinkyhead 
Z Axis Stress Test and Z Feedrate (marlin)
February 27, 2013 05:03PM
I've been tuning a Prusa i3 Mendel (single plate) with Wade & J-head and have reached the point where I'm getting decent prints at slower speeds, but at higher speeds it loses Z steps, especially with retract_lift enabled in Slic3r. Rather than go through a lot of printing to figure out where steps are being lost, I wrote a little PHP script to generate a Z Axis Stress Test. (My latest version of the test G-Code ZAxisStressTest.gcode.tar.gz is attached). I used the output of Slic3r as my guide in constructing the G-Code, and in the process of testing I became a little bit mystified about the Z Axis Feedrate.

Specifically, if I don't specify the Z Feedrate as the Default Feedrate (with G1 F120.0 for example) the Z Axis moves at a speed apparently even faster than the conservative MAX_FEEDRATE I have set in Marlin (120mm / min). I noticed in the output of Slic3r that nowhere does it explicitly set the Z Feedrate, so I assume it must be using whatever the last set value is. And I assume that when a print first begins the Z Feedrate is set to some sane default, which I assume is the MAX_FEEDRATE for the Z Axis.

What's especially interesting is that if I include a G28 (home all axes) in my G-Code, the Z Feedrate is set to the Z Homing Feedrate (180mm / min) which is definitely not print-friendly. So is that actually the case? That if I put a G28 into my start_gcode (in my Slic3r config) then the Z Feedrate will be set to 180 from then onward?

If you examine the attached G-Code, you'll see it performs 4 tests, homing and pausing in-between. (1) Move up 9.9mm, (2) Move up 9.9mm with 1/2 second pauses, (3) Move up 9.9mm with 0.2mm retract_lift behavior, and (4) Move up 9.9mm with 0.2mm retract_lift behavior and XY axis movement. In most of the tests G1 F120.0 after G28 works to keep the Z Feedrate under control, but in the last test the XY Feedrate values seem to mess with the Z Feedrate, making it too high and losing steps.

What's mysterious is that in the G-Code that Slic3r creates there doesn't seem to be any explicit setting of the Z Feedrate anywhere, and yet it's supposed to work correctly.

So I guess my ultimate question is, how do I keep my Z Feedrate under control so it doesn't go over 120 except when homing, no matter what?

Edited 2 time(s). Last edit at 02/27/2013 05:20PM by Thinkyhead.

| Lead Developer of Marlin Firmware
| Help support my work at Patreon and GoFundMe
Re: Z Axis Stress Test and Z Feedrate (marlin)
February 27, 2013 06:10PM
The limits in Marlin are mm/s not mm/m. If you set them correctly it doesn't matter what the slicer outputs, it gets clipped to the max.

Re: Z Axis Stress Test and Z Feedrate (marlin)
February 27, 2013 06:27PM
Ah, that makes perfect sense. So this unfortunate line...

#define DEFAULT_MAX_FEEDRATE { 500, 500, 150, 45 };

...should be more like...

#define DEFAULT_MAX_FEEDRATE { 500, 500, 2.5, 45 };

Somehow I lost track that the original value in that position was 5!
Sorry, only registered users may post in this forum.

Click here to login