Browse Source

Home retract distance configureable per axis.

Bernhard 13 years ago
parent
commit
a0dc66f7bf
2 changed files with 7 additions and 2 deletions
  1. 5
    0
      Marlin/Configuration.h
  2. 2
    2
      Marlin/Marlin.pde

+ 5
- 0
Marlin/Configuration.h View File

207
 #define NUM_AXIS 4 // The axis order in all axis related arrays is X, Y, Z, E
207
 #define NUM_AXIS 4 // The axis order in all axis related arrays is X, Y, Z, E
208
 #define HOMING_FEEDRATE {50*60, 50*60, 4*60, 0}  // set the homing speeds (mm/min)
208
 #define HOMING_FEEDRATE {50*60, 50*60, 4*60, 0}  // set the homing speeds (mm/min)
209
 
209
 
210
+//homing hits the endstop, then retracts by this distance, before it tries to slowly bump again:
211
+#define X_HOME_RETRACT_MM 5 
212
+#define Y_HOME_RETRACT_MM 5 
213
+#define Z_HOME_RETRACT_MM 1 
214
+
210
 #define AXIS_RELATIVE_MODES {false, false, false, false}
215
 #define AXIS_RELATIVE_MODES {false, false, false, false}
211
 
216
 
212
 #define MAX_STEP_FREQUENCY 40000 // Max step frequency for Ultimaker (5000 pps / half step)
217
 #define MAX_STEP_FREQUENCY 40000 // Max step frequency for Ultimaker (5000 pps / half step)

+ 2
- 2
Marlin/Marlin.pde View File

469
     \
469
     \
470
     current_position[LETTER##_AXIS] = 0;\
470
     current_position[LETTER##_AXIS] = 0;\
471
     plan_set_position(current_position[X_AXIS], current_position[Y_AXIS], current_position[Z_AXIS], current_position[E_AXIS]);\
471
     plan_set_position(current_position[X_AXIS], current_position[Y_AXIS], current_position[Z_AXIS], current_position[E_AXIS]);\
472
-    destination[LETTER##_AXIS] = -5 * LETTER##_HOME_DIR;\
472
+    destination[LETTER##_AXIS] = -LETTER##_HOME_RETRACT_MM * LETTER##_HOME_DIR;\
473
     prepare_move(); \
473
     prepare_move(); \
474
     \
474
     \
475
-    destination[LETTER##_AXIS] = 10 * LETTER##_HOME_DIR;\
475
+    destination[LETTER##_AXIS] = 2*LETTER##_HOME_RETRACT_MM * LETTER##_HOME_DIR;\
476
     feedrate = homing_feedrate[LETTER##_AXIS]/2 ;  \
476
     feedrate = homing_feedrate[LETTER##_AXIS]/2 ;  \
477
     prepare_move(); \
477
     prepare_move(); \
478
     \
478
     \

Loading…
Cancel
Save