Pārlūkot izejas kodu

SKR 1.3 sensorless endstops hack (#16659)

ellensp 5 gadus atpakaļ
vecāks
revīzija
0949c0f326
1 mainītis faili ar 14 papildinājumiem un 15 dzēšanām
  1. 14
    15
      Marlin/src/pins/lpc1768/pins_BTT_SKR_V1_3.h

+ 14
- 15
Marlin/src/pins/lpc1768/pins_BTT_SKR_V1_3.h Parādīt failu

@@ -25,32 +25,31 @@
25 25
 
26 26
 /**
27 27
  * Limit Switches
28
- *
29
- * For Stallguard homing to max swap the min / max pins so
30
- * the MAX physical connectors can be used for other things.
31 28
  */
32
-#if X_HOME_DIR == -1 || !X_STALL_SENSITIVITY
29
+#if X_HOME_DIR > 0 && X_STALL_SENSITIVITY && !defined(USE_XMAX_PLUG)
30
+  // For StallGuard homing to MAX swap the MIN / MAX pins
31
+  // so the MAX physical connectors may be used for other things.
32
+  #define X_MIN_PIN          P1_28   // X_MAX (free)
33
+  #define X_MAX_PIN          P1_29   // X_MIN
34
+#else                                // else, non-endstop is free and appears in M43 output
33 35
   #define X_MIN_PIN          P1_29   // X_MIN
34 36
   #define X_MAX_PIN          P1_28   // X_MAX
35
-#else
36
-  #define X_MIN_PIN          P1_28   // X_MAX
37
-  #define X_MAX_PIN          P1_29   // X_MIN
38 37
 #endif
39 38
 
40
-#if Y_HOME_DIR == -1 || !Y_STALL_SENSITIVITY
39
+#if Y_HOME_DIR > 0 && Y_STALL_SENSITIVITY && !defined(USE_YMAX_PLUG)
40
+  #define Y_MIN_PIN          P1_26   // Y_MAX (free)
41
+  #define Y_MAX_PIN          P1_27   // Y_MIN
42
+#else
41 43
   #define Y_MIN_PIN          P1_27   // Y_MIN
42 44
   #define Y_MAX_PIN          P1_26   // Y_MAX
43
-#else
44
-  #define Y_MIN_PIN          P1_26   // Y_MAX
45
-  #define Y_MAX_PIN          P1_27   // Y_MIN
46 45
 #endif
47 46
 
48
-#if Z_HOME_DIR == -1 || !Z_STALL_SENSITIVITY
47
+#if Z_HOME_DIR > 0 && Z_STALL_SENSITIVITY && !defined(USE_ZMAX_PLUG)
48
+  #define Z_MIN_PIN          P1_24   // Z_MAX (free)
49
+  #define Z_MAX_PIN          P1_25   // Z_MIN
50
+#else
49 51
   #define Z_MIN_PIN          P1_25   // Z_MIN
50 52
   #define Z_MAX_PIN          P1_24   // Z_MAX
51
-#else
52
-  #define Z_MIN_PIN          P1_24   // Z_MAX
53
-  #define Z_MAX_PIN          P1_25   // Z_MIN
54 53
 #endif
55 54
 
56 55
 #define ONBOARD_ENDSTOPPULLUPS     // Board has built-in pullups

Notiek ielāde…
Atcelt
Saglabāt