|
|
@ -316,7 +316,7 @@ bool target_direction;
|
|
|
|
|
|
|
|
|
|
|
|
#if HAS_SERVO_ENDSTOPS
|
|
|
|
#if HAS_SERVO_ENDSTOPS
|
|
|
|
const int servo_endstop_id[] = SERVO_ENDSTOP_IDS;
|
|
|
|
const int servo_endstop_id[] = SERVO_ENDSTOP_IDS;
|
|
|
|
const int servo_endstop_angles[][2] = SERVO_ENDSTOP_ANGLES;
|
|
|
|
const int servo_endstop_angle[][2] = SERVO_ENDSTOP_ANGLES;
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
#ifdef BARICUDA
|
|
|
|
#ifdef BARICUDA
|
|
|
@ -581,7 +581,7 @@ void servo_init() {
|
|
|
|
#if HAS_SERVO_ENDSTOPS
|
|
|
|
#if HAS_SERVO_ENDSTOPS
|
|
|
|
for (int i = 0; i < 3; i++)
|
|
|
|
for (int i = 0; i < 3; i++)
|
|
|
|
if (servo_endstop_id[i] >= 0)
|
|
|
|
if (servo_endstop_id[i] >= 0)
|
|
|
|
servo[servo_endstop_id[i]].move(servo_endstop_angles[i][1]);
|
|
|
|
servo[servo_endstop_id[i]].move(servo_endstop_angle[i][1]);
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -1325,7 +1325,7 @@ static void setup_for_endstop_move() {
|
|
|
|
#if HAS_SERVO_ENDSTOPS
|
|
|
|
#if HAS_SERVO_ENDSTOPS
|
|
|
|
|
|
|
|
|
|
|
|
// Engage Z Servo endstop if enabled
|
|
|
|
// Engage Z Servo endstop if enabled
|
|
|
|
if (servo_endstop_id[Z_AXIS] >= 0) servo[servo_endstop_id[Z_AXIS]].move(servo_endstop_angles[Z_AXIS][0]);
|
|
|
|
if (servo_endstop_id[Z_AXIS] >= 0) servo[servo_endstop_id[Z_AXIS]].move(servo_endstop_angle[Z_AXIS][0]);
|
|
|
|
|
|
|
|
|
|
|
|
#elif defined(Z_PROBE_ALLEN_KEY)
|
|
|
|
#elif defined(Z_PROBE_ALLEN_KEY)
|
|
|
|
feedrate = Z_PROBE_ALLEN_KEY_DEPLOY_1_FEEDRATE;
|
|
|
|
feedrate = Z_PROBE_ALLEN_KEY_DEPLOY_1_FEEDRATE;
|
|
|
@ -1425,7 +1425,7 @@ static void setup_for_endstop_move() {
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
// Change the Z servo angle
|
|
|
|
// Change the Z servo angle
|
|
|
|
servo[servo_endstop_id[Z_AXIS]].move(servo_endstop_angles[Z_AXIS][1]);
|
|
|
|
servo[servo_endstop_id[Z_AXIS]].move(servo_endstop_angle[Z_AXIS][1]);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
#elif defined(Z_PROBE_ALLEN_KEY)
|
|
|
|
#elif defined(Z_PROBE_ALLEN_KEY)
|
|
|
@ -1679,7 +1679,7 @@ static void homeaxis(AxisEnum axis) {
|
|
|
|
#if HAS_SERVO_ENDSTOPS
|
|
|
|
#if HAS_SERVO_ENDSTOPS
|
|
|
|
// Engage Servo endstop if enabled
|
|
|
|
// Engage Servo endstop if enabled
|
|
|
|
if (axis != Z_AXIS && servo_endstop_id[axis] >= 0)
|
|
|
|
if (axis != Z_AXIS && servo_endstop_id[axis] >= 0)
|
|
|
|
servo[servo_endstop_id[axis]].move(servo_endstop_angles[axis][0]);
|
|
|
|
servo[servo_endstop_id[axis]].move(servo_endstop_angle[axis][0]);
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
// Set a flag for Z motor locking
|
|
|
|
// Set a flag for Z motor locking
|
|
|
@ -1781,7 +1781,7 @@ static void homeaxis(AxisEnum axis) {
|
|
|
|
#if HAS_SERVO_ENDSTOPS
|
|
|
|
#if HAS_SERVO_ENDSTOPS
|
|
|
|
// Retract Servo endstop if enabled
|
|
|
|
// Retract Servo endstop if enabled
|
|
|
|
if (servo_endstop_id[axis] >= 0)
|
|
|
|
if (servo_endstop_id[axis] >= 0)
|
|
|
|
servo[servo_endstop_id[axis]].move(servo_endstop_angles[axis][1]);
|
|
|
|
servo[servo_endstop_id[axis]].move(servo_endstop_angle[axis][1]);
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|