瀏覽代碼

Add SENSORLESS_HOMING to Archim 2.0 (#10500)

Marcio Teixeira 7 年之前
父節點
當前提交
10a25f733e
共有 1 個檔案被更改,包括 35 行新增13 行删除
  1. 35
    13
      Marlin/src/pins/pins_ARCHIM2.h

+ 35
- 13
Marlin/src/pins/pins_ARCHIM2.h 查看文件

43
 // Items marked * have been altered from Archim v1.0
43
 // Items marked * have been altered from Archim v1.0
44
 //
44
 //
45
 
45
 
46
+// TMC2130 Diag Pins (currently just for reference)
47
+#define X_DIAG_PIN         59   // PA4 X_DIAG
48
+#define Y_DIAG_PIN         48   // PC15 Y_DIAG
49
+#define Z_DIAG_PIN         36   // PC4 Z_DIAG
50
+#define E0_DIAG_PIN        78   // PB23 E1_DIAG
51
+#define E1_DIAG_PIN        25   // PD0 E2_DIAG
52
+
46
 //
53
 //
47
 // Limit Switches
54
 // Limit Switches
48
 //
55
 //
49
-#define X_MIN_PIN          14   // PD4 MIN ES1
50
-#define X_MAX_PIN          32   // PD10 MAX ES1
51
-#define Y_MIN_PIN          29   // PD6 MIN ES2
52
-#define Y_MAX_PIN          15   // PD5 MAX ES2
53
-#define Z_MIN_PIN          31   // PA7 MIN ES3
54
-#define Z_MAX_PIN          30   // PD9 MAX ES3
56
+// Only use Diag Pins when SENSORLESS_HOMING is enabled for the TMC2130 drivers.
57
+// Otherwise use a physical endstop based configuration.
58
+
59
+#if DISABLED(SENSORLESS_HOMING)
60
+ #define X_MIN_PIN          14   // PD4 MIN ES1
61
+ #define X_MAX_PIN          32   // PD10 MAX ES1
62
+ #define Y_MIN_PIN          29   // PD6 MIN ES2
63
+ #define Y_MAX_PIN          15   // PD5 MAX ES2
64
+#else
65
+  #if X_HOME_DIR == -1
66
+    #define X_MIN_PIN      X_DIAG_PIN
67
+    #define X_MAX_PIN      32
68
+  #else
69
+    #define X_MIN_PIN      14
70
+    #define X_MAX_PIN      X_DIAG_PIN
71
+  #endif
72
+
73
+  #if Y_HOME_DIR == -1
74
+    #define Y_MIN_PIN      Y_DIAG_PIN
75
+    #define Y_MAX_PIN      15
76
+  #else
77
+    #define Y_MIN_PIN      29
78
+    #define Y_MAX_PIN      Y_DIAG_PIN
79
+  #endif
80
+#endif
81
+
82
+ #define Z_MIN_PIN          31   // PA7 MIN ES3
83
+ #define Z_MAX_PIN          30   // PD9 MAX ES3
55
 
84
 
56
 //
85
 //
57
 // Z Probe (when not Z_MIN_PIN)
86
 // Z Probe (when not Z_MIN_PIN)
69
 #ifndef X_CS_PIN
98
 #ifndef X_CS_PIN
70
   #define X_CS_PIN         39   // PC7 X_nCS
99
   #define X_CS_PIN         39   // PC7 X_nCS
71
 #endif
100
 #endif
72
-#define X_DIAG_PIN         59   // PA4 X_DIAG
73
 
101
 
74
 #define Y_STEP_PIN         51   // PC12 Y-STEP *
102
 #define Y_STEP_PIN         51   // PC12 Y-STEP *
75
 #define Y_DIR_PIN          92   // PC11 Y-DIR -AddOns *
103
 #define Y_DIR_PIN          92   // PC11 Y-DIR -AddOns *
77
 #ifndef Y_CS_PIN
105
 #ifndef Y_CS_PIN
78
   #define Y_CS_PIN         50   // PC13 Y_nCS
106
   #define Y_CS_PIN         50   // PC13 Y_nCS
79
 #endif
107
 #endif
80
-#define Y_DIAG_PIN         48   // PC15 Y_DIAG
81
 
108
 
82
 #define Z_STEP_PIN         46   // PC17 Z-STEP *
109
 #define Z_STEP_PIN         46   // PC17 Z-STEP *
83
 #define Z_DIR_PIN          47   // PC16 Z-DIR *
110
 #define Z_DIR_PIN          47   // PC16 Z-DIR *
85
 #ifndef Z_CS_PIN
112
 #ifndef Z_CS_PIN
86
   #define Z_CS_PIN         45   // PC18 Z_nCS
113
   #define Z_CS_PIN         45   // PC18 Z_nCS
87
 #endif
114
 #endif
88
-#define Z_DIAG_PIN         36   // PC4 Z_DIAG
89
 
115
 
90
 #define E0_STEP_PIN       107   // PB10 E1-STEP -AddOns *
116
 #define E0_STEP_PIN       107   // PB10 E1-STEP -AddOns *
91
 #define E0_DIR_PIN         96   // PC10 E1-DIR -AddOns *
117
 #define E0_DIR_PIN         96   // PC10 E1-DIR -AddOns *
93
 #ifndef E0_CS_PIN
119
 #ifndef E0_CS_PIN
94
   #define E0_CS_PIN       104   // PC20 E1_nCS -AddOns *
120
   #define E0_CS_PIN       104   // PC20 E1_nCS -AddOns *
95
 #endif
121
 #endif
96
-#define E0_DIAG_PIN        78   // PB23 E1_DIAG
97
 
122
 
98
 #define E1_STEP_PIN        22   // PB26 E2_STEP *
123
 #define E1_STEP_PIN        22   // PB26 E2_STEP *
99
 #define E1_DIR_PIN         97   // PB24 E2_DIR -AddOns *
124
 #define E1_DIR_PIN         97   // PB24 E2_DIR -AddOns *
101
 #ifndef E1_CS_PIN
126
 #ifndef E1_CS_PIN
102
   #define E1_CS_PIN        19   // PA10 E2_nCS
127
   #define E1_CS_PIN        19   // PA10 E2_nCS
103
 #endif
128
 #endif
104
-#define E1_DIAG_PIN        25   // PD0 E2_DIAG
105
 
129
 
106
 //
130
 //
107
 // Software SPI pins for TMC2130 stepper drivers.
131
 // Software SPI pins for TMC2130 stepper drivers.
132
 #define HEATER_2_PIN        8   // D8 PC22 FET_PWM5
156
 #define HEATER_2_PIN        8   // D8 PC22 FET_PWM5
133
 #define HEATER_BED_PIN      9   // D9 PC21 BED_PWM
157
 #define HEATER_BED_PIN      9   // D9 PC21 BED_PWM
134
 
158
 
135
-
136
 //
159
 //
137
 // Misc. Functions
160
 // Misc. Functions
138
 //
161
 //
139
 #define SDSS               87   // D87 PA29 CS
162
 #define SDSS               87   // D87 PA29 CS
140
 
163
 
141
-
142
 //////////////////////////
164
 //////////////////////////
143
 // LCDs and Controllers //
165
 // LCDs and Controllers //
144
 //////////////////////////
166
 //////////////////////////

Loading…
取消
儲存