Welcome! Log In Create A New Profile

Advanced

Marlin: Z Endstop 'follows' current Z position

Posted by fangkb 
Marlin: Z Endstop 'follows' current Z position
June 01, 2013 03:18AM
Hi,

Situation: The endstop point for Z axis keeps tracking its current position.

Example:
When I move Z to position 1.00, Z1.00 becomes the endstop position, and further movement in the negative direction triggers the endstop. If I then move Z to position 2.00, Z2.00 then becomes the new point at which endstop is triggered.

echo:endstops hit: Z:1.00
echo:endstops hit: Z:2.00
echo:endstops hit: Z:3.00

Basically the endstop point keeps tracking its current new Z position. M199 reports that th e z endstop is always triggered, even though the hardware is not. Hardware is not a problem as I have switched between X, Y, and Z endstop, and also have uploaded to 2 gen6.d electronic boards having the same problem.

SENDING:M119
Reporting endstop status
x_min: open
y_min: open
z_min: TRIGGERED

The firmware mechanical settings are shown below.

Please help. Thank you very much.

--------------------------------------------------------------------------------

// corse Endstop Settings
//#define ENDSTOPPULLUPS // Comment this out (using // at the start of the line) to disable the endstop pullup resistors

#ifndef ENDSTOPPULLUPS
// fine Enstop settings: Individual Pullups. will be ignord if ENDSTOPPULLUPS is defined
#define ENDSTOPPULLUP_XMAX
#define ENDSTOPPULLUP_YMAX
#define ENDSTOPPULLUP_ZMAX
#define ENDSTOPPULLUP_XMIN
#define ENDSTOPPULLUP_YMIN
#define ENDSTOPPULLUP_ZMIN
#endif

#ifdef ENDSTOPPULLUPS
#define ENDSTOPPULLUP_XMAX
#define ENDSTOPPULLUP_YMAX
#define ENDSTOPPULLUP_ZMAX
#define ENDSTOPPULLUP_XMIN
#define ENDSTOPPULLUP_YMIN
#define ENDSTOPPULLUP_ZMIN
#endif

// The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
const bool X_ENDSTOPS_INVERTING = true; // set to true to invert the logic of the endstops.
const bool Y_ENDSTOPS_INVERTING = true; // set to true to invert the logic of the endstops.
const bool Z_ENDSTOPS_INVERTING = true; // set to true to invert the logic of the endstops.
//#define DISABLE_MAX_ENDSTOPS

// For Inverting Stepper Enable Pins (Active Low) use 0, Non Inverting (Active High) use 1
#define X_ENABLE_ON 0
#define Y_ENABLE_ON 0
#define Z_ENABLE_ON 0
#define E_ENABLE_ON 0 // For all extruders

// Disables axis when it's not being used.
#define DISABLE_X false
#define DISABLE_Y false
#define DISABLE_Z false
#define DISABLE_E false // For all extruders

#define INVERT_X_DIR false // for Mendel set to false, for Orca set to true
#define INVERT_Y_DIR false // for Mendel set to true, for Orca set to false
#define INVERT_Z_DIR true // for Mendel set to false, for Orca set to true
#define INVERT_E0_DIR true // for direct drive extruder v9 set to true, for geared extruder set to false
#define INVERT_E1_DIR true // for direct drive extruder v9 set to true, for geared extruder set to false
#define INVERT_E2_DIR true // for direct drive extruder v9 set to true, for geared extruder set to false

// ENDSTOP SETTINGS:
// Sets direction of endstops when homing; 1=MAX, -1=MIN
#define X_HOME_DIR -1
#define Y_HOME_DIR -1
#define Z_HOME_DIR -1

#define min_software_endstops true //If true, axis won't move to coordinates less than HOME_POS.
#define max_software_endstops true //If true, axis won't move to coordinates greater than the defined lengths below.
// Travel limits after homing
#define X_MAX_POS 60
#define X_MIN_POS 0
#define Y_MAX_POS 1000
#define Y_MIN_POS 0
#define Z_MAX_POS 200
#define Z_MIN_POS 0

#define X_MAX_LENGTH (X_MAX_POS - X_MIN_POS)
#define Y_MAX_LENGTH (Y_MAX_POS - Y_MIN_POS)
#define Z_MAX_LENGTH (Z_MAX_POS - Z_MIN_POS)

// The position of the homing switches
//#define MANUAL_HOME_POSITIONS // If defined, MANUAL_*_HOME_POS below will be used
//#define BED_CENTER_AT_0_0 // If defined, the center of the bed is at (X=0, Y=0)

//Manual homing switch locations:
#define MANUAL_X_HOME_POS 0
#define MANUAL_Y_HOME_POS 0
#define MANUAL_Z_HOME_POS 0
Re: Marlin: Z Endstop 'follows' current Z position
June 01, 2013 11:43PM
Just my 2 cents
i think its the last 3 lines in your file.
//Manual homing switch locations:
#define MANUAL_X_HOME_POS 0
#define MANUAL_Y_HOME_POS 0
#define MANUAL_Z_HOME_POS 0
I don't have these in my config.h ( im using a Gen6d board) I would comment them out and try your system again. Im not sure what their purpose is.

Unrelated to your issue i noticed you have some weird travel limits
// Travel limits after homing
#define X_MAX_POS 60
#define X_MIN_POS 0
#define Y_MAX_POS 1000
#define Y_MIN_POS 0
#define Z_MAX_POS 200
#define Z_MIN_POS 0

Seems to indicate your print bed is 60mm wide and 1 meter long ??? Surely that's impossible
Re: Marlin: Z Endstop 'follows' current Z position
June 02, 2013 12:49AM
Thank you for replying, bigfilsing.

bigfilsing Wrote:
-------------------------------------------------------
> Just my 2 cents
> i think its the last 3 lines in your file.
> //Manual homing switch locations:
> #define MANUAL_X_HOME_POS 0
> #define MANUAL_Y_HOME_POS 0
> #define MANUAL_Z_HOME_POS 0
> I don't have these in my config.h ( im using a
> Gen6d board) I would comment them out and try your
> system again. Im not sure what their purpose is.
>
I'm not sure what these does either. If anyone could please explain?

> Unrelated to your issue i noticed you have some
> weird travel limits
> // Travel limits after homing
> #define X_MAX_POS 60
> #define X_MIN_POS 0
> #define Y_MAX_POS 1000
> #define Y_MIN_POS 0
> #define Z_MAX_POS 200
> #define Z_MIN_POS 0
>
> Seems to indicate your print bed is 60mm wide and
> 1 meter long ??? Surely that's impossible
You're right. It is for my own testing to understand how it works (set different values to find out what whether it has effect on the actual movement).

Thanks!
Re: Marlin: Z Endstop 'follows' current Z position
June 02, 2013 04:57AM
to the best of my knowledge the define max and min are to limit the amount the software/firm ware can drive the steppers in any one direction
you wouldn't want it to be able to drive it beyond its physical limits . That's assuming you don't have MAX end stops.
So once each axis has been homed the firmware knows not to drive it further than the value you have assigned to MAX_POS ***

Edited 1 time(s). Last edit at 06/02/2013 08:45PM by bigfilsing.
Re: Marlin: Z Endstop 'follows' current Z position
June 03, 2013 02:44AM
if you're using mechanical endstops uncomment //#define DISABLE_MAX_ENDSTOPS try the m119 command without any being triggered what does it say? come back with that take it from there i had endstop problems but got it sorted now
Sorry, only registered users may post in this forum.

Click here to login