Gcode for z-axis alignment  

  RSS
lowell
(@lowell)
New Member

Anyone know the proper gcode to tell the printer to run the Z-axis all the way to the top to hit the physical limits.   I've been periodically noticing that the z-axis stepper motors are getting out of sync just a little.  Typically not bad enough to trigger a z-axis alignment warning during the 3x3 bed leveling, but enough that it's causing prints to fail.   I'm not 100% sure what's causing this every time; but I have caught my kids walking by the printer and manually turning the 8mm threads on the z-axis, so I can't really expect the printer to detect that.

So I was hoping to add some custom commands to each print job via my slicer (or maybe via OctoPrint somehow?) to force z-axis alignment right before the mesh bed leveling (G28/G80).

I've tried:

G1 Z210;  Stops short of hitting the physical top
G1 S1; Disables boundy checking? Nope, doesn't work
M45 Z; This "works" but runs the full calibration \w user prompt

I found the following Marlin gcode options, but apparently these aren't supported by Prusa's firmware:

  • G34 - Z Steppers Auto-Alignment; Sounds promising.  Not supported.
  • M121 - Disable Endstops -- not sure if this is what I want, but not supported.

Seems like maybe this is possible with G92 somehow (resetting the internal positioning, but I'm not exactly sure about how that could/should work.)

Anyone know what I'm missing?

Posted : 09/10/2019 6:38 am
Tim
(@tim-m30)
Illustrious Member

Just run Z-calibration once in a while.  Or turn the printer off, when it powers on it doesn't know its location and will easily bounce off the top.

FWIW, I rarely if ever need to realign Z.  I do a Z-cal when I run cal for other reasons, but not to solve print problems.   So I'd look for Z axis friction on your printer. Jam nuts, T-nuts, etc.

This post was modified 12 months ago by Tim
It is always wise to get more than one opinion......
Posted : 10/10/2019 11:01 pm
lowell
(@lowell)
New Member

I don't turn the printing off very often (at least for the 5 weeks I've owned it.)  It's connected to a PI with Octoprint and shutting it down correctly takes a few steps. 

My typical "solution" is to move the Z axis up half-way, reset the printer (via the "X" button) and then run the Z axis all the way to the top manually.   Octoprint automatically resets, most of the time, but it gets a bit grumpy about it.  That's why I was looking for a more automated way to go about it at the start of each print.  (I think a z-level operation every print is overkill, but it seem easier to implement via my slicer's preamble than to get Octoprint to run it daily, or every 5th print, or so on.)

I haven't been able to notice any mechanical issues with the z-axis.  But I could be missing something.  The Z-screw-covers seem to fit quite snuggly, but it doesn't seem like that actually impedes motion.  For the moment, I'm assuming the primary culprit is "little fingers".  (Still working on a proper enclosure to help reduce that problem.)  I was hoping for an automated (gcode) workaround in the meantime.

Posted : 15/10/2019 7:46 pm
Share:

Please Login or Register