Welcome! Log In Create A New Profile


Marlin 1.1.x (1.1.8) on Mendel90 (top homing) home offset

Posted by electroluke 
Marlin 1.1.x (1.1.8) on Mendel90 (top homing) home offset
April 04, 2018 02:10PM

I have a Mendel90 "Sturdy" with RAMPS1.4 electronics, Reprapdiscount smart controler, all-metal hotend (E3D clone), and trapezium Z rods, currently running Marlin 1.1.x (from 1.1.x branch on github, but display says 1.1.8 on bootup)

It homes to Z_Max, which I've set to 210 in the FW to correct later with M206 Z-29.9 (So actual max is about 180).


Now, there's 2 strange things:

On the display (RRD Smart controler) it shows 210 as Z position after homing, while M114 correctly reports 180.1 This is a problem when using "move axis" from the menu, as that also starts from 210 on Z axis and so can move Z axis "below" (into, rather) the bed. Why does Marlin keep 2 different variables for Z position, one on the display and one for M114?

Also, when using "Set home offsets" from the menu, it says "to far" when X=0, Y=0 and Z=29.9 / on the bed. While it "knows" it's a top homing printer (config.h has the settings for an endstop at ZMAX and none at ZMIN), so why doesn't it just set z-offset to -29.9 so Z is zero when the nozzle is on the bed? (I now set Z-offset over USB with M206 but would like to have an option in the LCD menu for it and "set home offsets" seems to be the right one, except it is'nt made for top-homing printers).

I guess the first one is a bug and the second a feature request?

How should I proceed to both improve the functionality of my printer and Marlin? Should I be using the "not for production" 1.1.x_bugfix branch?
Re: Marlin 1.1.x (1.1.8) on Mendel90 (top homing) home offset
April 05, 2018 03:22PM
Disclaimer: I have the exact same electronics as you do. However I never used the Monitor for anything serious, I just have it out for esthetics and the reset button within reach. I use OctoPrint and I am a huge fan of the terminal.

The one is for printing space/volume the other is for actual ability of axis to move to.
The 210 is the absolute position, while the 180 is the relative (to your x0,y0,z0) position.
As far as logic goes you can have a wiping sponge at below the bed on the side of the bed.
My print volume atm is x200, y200, z300, but my axis have a moving ability of x270, y315, z335. (Upgrade to 200x300 heatbed imminent)
My M206 looks like x-35, y-67, z-2.8. And if I would to type g0 z0 while the nozzle is at x100,y100 it would ram my heatbed.
However when I Home-Z, it elevates Z 10mm up, then homes to X, before finally homing Z. Not sure it's Marlin or OctoPrint.
I use Cura 3.2.1. I've added the M206 offset to the slicer "g-code begin" section just to be sure. I find EPROM confusing.

Proud owner and maker of build from scratch FDM 3D printer [forums.reprap.org]
Re: Marlin 1.1.x (1.1.8) on Mendel90 (top homing) home offset
April 13, 2018 06:57AM
Ok, thank you, that is clear, it shows absolute coordinates, not relative. Just a thing to keep in mind when using "move axis" that I don't ram Z trough the bed because absolute 0 is below the bed.

Then the other thing about the home offsets. It is not documented on the wiki (at least not where I looked: [reprap.org] and [reprap.org]), but "set home offsets" from the LCD menu calls M428 (used to call G92 in older versions).

G92 is documented in the GCODES wiki page:

M428 isn't. It is just mentioned on the "Marlin" wiki page. So after a fair bit of digging through the code on github:

   * M428: Set home_offset based on the distance between the
   *       current_position and the nearest "reference point."
   *       If an axis is past center its endstop position
   *       is the reference-point. Otherwise it uses 0. This allows
   *       the Z offset to be set near the bed when using a max endstop.
   *       M428 can't be used more than 2cm away from 0 or an endstop.
   *       Use M206 to set these values directly.

(It is in Marlin_main.cpp, for those wondering. I tried looking in parser.h parser.cpp etc. first)

So, more then 2cm is "too far" and it already accounts for endstops at either side (MIN or MAX).

I'm going to set my printers' MAX to something within 2cm of the actual bed. (It would be really nice to set Z0 without attaching a computer to the printer... Also on the 2 printers in the makerspace)

Could someone with a wiki account please include the documentation of the M428 command there? (On the gcodes page and/or the marlin page) (especially the 2cm limit!)
Also here: [marlinfw.org] the 2cm limit that bit me is not mentioned... PR done

Edited 2 time(s). Last edit at 04/13/2018 07:26AM by electroluke.
Sorry, only registered users may post in this forum.

Click here to login