|
@@ -42,26 +42,22 @@ Endstops endstops;
|
42
|
42
|
bool Endstops::enabled, Endstops::enabled_globally; // Initialized by settings.load()
|
43
|
43
|
volatile char Endstops::endstop_hit_bits; // use X_MIN, Y_MIN, Z_MIN and Z_MIN_PROBE as BIT value
|
44
|
44
|
|
45
|
|
-#if ENABLED(X_DUAL_ENDSTOPS) || ENABLED(Y_DUAL_ENDSTOPS) || ENABLED(Z_DUAL_ENDSTOPS)
|
46
|
|
- uint16_t
|
47
|
|
-#else
|
48
|
|
- byte
|
49
|
|
-#endif
|
50
|
|
- Endstops::current_endstop_bits = 0,
|
51
|
|
- Endstops::old_endstop_bits = 0;
|
|
45
|
+Endstops::esbits_t Endstops::current_endstop_bits = 0,
|
|
46
|
+ Endstops::old_endstop_bits = 0;
|
52
|
47
|
|
53
|
48
|
#if HAS_BED_PROBE
|
54
|
49
|
volatile bool Endstops::z_probe_enabled = false;
|
55
|
50
|
#endif
|
56
|
51
|
|
|
52
|
+// Initialized by settings.load()
|
57
|
53
|
#if ENABLED(X_DUAL_ENDSTOPS)
|
58
|
|
- float Endstops::x_endstop_adj; // Initialized by settings.load()
|
|
54
|
+ float Endstops::x_endstop_adj;
|
59
|
55
|
#endif
|
60
|
56
|
#if ENABLED(Y_DUAL_ENDSTOPS)
|
61
|
|
- float Endstops::y_endstop_adj; // Initialized by settings.load()
|
|
57
|
+ float Endstops::y_endstop_adj;
|
62
|
58
|
#endif
|
63
|
59
|
#if ENABLED(Z_DUAL_ENDSTOPS)
|
64
|
|
- float Endstops::z_endstop_adj; // Initialized by settings.load()
|
|
60
|
+ float Endstops::z_endstop_adj;
|
65
|
61
|
#endif
|
66
|
62
|
|
67
|
63
|
/**
|
|
@@ -355,7 +351,7 @@ void Endstops::update() {
|
355
|
351
|
_ENDSTOP_HIT(AXIS, MINMAX); \
|
356
|
352
|
stepper.endstop_triggered(_AXIS(AXIS)); \
|
357
|
353
|
} \
|
358
|
|
- } while(0)
|
|
354
|
+ }while(0)
|
359
|
355
|
|
360
|
356
|
#if ENABLED(G38_PROBE_TARGET) && PIN_EXISTS(Z_MIN_PROBE) && !(CORE_IS_XY || CORE_IS_XZ)
|
361
|
357
|
// If G38 command is active check Z_MIN_PROBE for ALL movement
|
|
@@ -452,7 +448,6 @@ void Endstops::update() {
|
452
|
448
|
/**
|
453
|
449
|
* Check and update endstops according to conditions
|
454
|
450
|
*/
|
455
|
|
-
|
456
|
451
|
if (X_MOVE_TEST) {
|
457
|
452
|
if (stepper.motor_direction(X_AXIS_HEAD)) { // -direction
|
458
|
453
|
#if HAS_X_MIN
|