Welcome! Log In Create A New Profile

Advanced

DIY Mendel90 Endstop config

Posted by jamesmoe 
DIY Mendel90 Endstop config
November 12, 2013 12:37PM
Good day all. I have completed my DIY Mendel90 based off of parts I printed out of PLA (except for the extruder body) about a year ago, and using sealed MDF as my frame. Just got around to assembling it this weekend. I thank my trusty Prusa i2 for completing my parts with its last dying breath before being disassembled for the 90.

I have to say to Nophead .. the OpenScad automation and file generation process is nothing like I have ever seen. It should be a model of how to automate an OpenSource design.

Since I did not buy your kit, do you have a PayPal account? I would like to send you a few dollars to say thanks for the completeness of your OpenSource materials that allowed the easy build process.

Stats:

MDF frame that has been primed and painted
PLA frame parts except for extruder body
Gregs Wade v3 .. mirrored to fit Mendel90
J-Head hot end .35mm
RAMPS 1.4
Nophead Marlin firmware adjusted for the RAMPS board (latest version as of November 9, 2013)

I fired up the printer yesterday, but was in a rush because I had to leave on a business trip. The behavior perplexed me and I need some help on the endstop switches.

If you note the picture of my printer, I have circled the three switches. Based on the orientation of my printer I consider these X-Max, Y-Max and Z-Min switches. NOTE: I understand Nophead's objection to Z-Min switch and may change it to a Z-Max switch and give the MatterControl auto bed leveling a shot.

1. When using PrintRun I can move each axis in the positive direction all the way to the Max endstop. When I try to move it back PrintRun is indicating that "Endstop Hit" and won't go back. Endstop inversion is good because when it is traveling in the positive direction and I hit one of the endstops, the axis stops.

2. How should homing work? Once I overcome issue 1, Should I home to 0,0 against a soft endstop, or home at 200,200 against the hard endstops? And how is it best to configure?

I reviewed your firmware against the stock Marlin and see some differences, but the endstop sections have gotten really confusing and I am not sure where this inability to move the axis in the opposite direction is coming from.

Thoughts?

Thank you,

- Jim Moeller (jamesmoe)
Attachments:
open | download - jamesmoe90.jpg (300.5 KB)
Re: DIY Mendel90 Endstop config
November 12, 2013 01:27PM
Opps. Make a mistake. 0,0 would actually be center. I usually home to -100,-100 where the endstops are at 100,100. I would not mind homing to 0,0 but still need to fix why it won't move off that Max endstops at 100,100
Re: DIY Mendel90 Endstop config
November 12, 2013 04:07PM
I actually have the X and Y axes as min end stops and have the axes reversed when looking from the front of the machine. However you can set it up either way and Marlin should still work.

To make them work as max endstops you need the connect them to the max inputs and set the homing direction to 1 instead of -1 and set the home pos to +100. You also need to jumper the MIN endstop connectors or set the pins to -1.


[www.hydraraptor.blogspot.com]
Re: DIY Mendel90 Endstop config
November 15, 2013 08:50AM
OK. I think this is what I need to do.

So I want to leave my axis in the right direction. Looking at the machine as the motor side being the front .. X+ to right, Y+

I have endstops at X- MAX and Y-MAX and Z-MIN and want them to home in that direction.

Here are my Marlin settings ... Cool?

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

// The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins.
const bool X_ENDSTOPS_INVERTING = false; // set to true to invert the logic of the endstops.
const bool Y_ENDSTOPS_INVERTING = false; // set to true to invert the logic of the endstops.
const bool Z_ENDSTOPS_INVERTING = false; // 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 false // for direct drive extruder v9 set to true, for geared extruder set to false
#define INVERT_E2_DIR false // 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_MIN_POS -100
#define X_MAX_POS 100
#define Y_MIN_POS -100
#define Y_MAX_POS 100
#define Z_MIN_POS 0
#define Z_MAX_POS 200

// The position of the homing switches. Use MAX_LENGTH * -0.5 if the center should be 0, 0, 0
#define X_HOME_POS (X_MAX_POS + 1)
#define Y_HOME_POS (Y_MAX_POS + 1)
#define Z_HOME_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)
Re: DIY Mendel90 Endstop config
November 15, 2013 12:26PM
Here are the settings I ended up with that SEEM to be working:

Please validate that there is not something terribly wrong with them.

Last question before I move on to my next task is in Pronterface, I set the options to Build Dimentions 205W x 190D x 150H. I set the home positions to 205, 190 and 0 respectively. What is the offset? The Nophead config is -100, -100, 0. Should I set these as -205, -190, 0?

// 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 false //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_MIN_POS 0
#define X_MAX_POS 205
#define Y_MIN_POS 0
#define Y_MAX_POS 190
#define Z_MIN_POS 0
#define Z_MAX_POS 150

// The position of the homing switches. Use MAX_LENGTH * -0.5 if the center should be 0, 0, 0
#define X_HOME_POS 205
#define Y_HOME_POS 190
#define Z_HOME_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)
Sorry, only registered users may post in this forum.

Click here to login