|
@@ -134,73 +134,69 @@ void manage_inactivity(bool ignore_stepper_queue = false);
|
134
|
134
|
extern bool extruder_duplication_enabled;
|
135
|
135
|
#endif
|
136
|
136
|
|
137
|
|
-#if ENABLED(DUAL_X_CARRIAGE) && HAS_X_ENABLE && HAS_X2_ENABLE
|
138
|
|
- #define enable_x() do { X_ENABLE_WRITE( X_ENABLE_ON); X2_ENABLE_WRITE( X_ENABLE_ON); } while (0)
|
139
|
|
- #define disable_x() do { X_ENABLE_WRITE(!X_ENABLE_ON); X2_ENABLE_WRITE(!X_ENABLE_ON); axis_known_position[X_AXIS] = false; } while (0)
|
|
137
|
+#if HAS_X2_ENABLE
|
|
138
|
+ #define enable_x() do{ X_ENABLE_WRITE( X_ENABLE_ON); X2_ENABLE_WRITE( X_ENABLE_ON); }while(0)
|
|
139
|
+ #define disable_x() do{ X_ENABLE_WRITE(!X_ENABLE_ON); X2_ENABLE_WRITE(!X_ENABLE_ON); axis_known_position[X_AXIS] = false; }while(0)
|
140
|
140
|
#elif HAS_X_ENABLE
|
141
|
141
|
#define enable_x() X_ENABLE_WRITE( X_ENABLE_ON)
|
142
|
|
- #define disable_x() { X_ENABLE_WRITE(!X_ENABLE_ON); axis_known_position[X_AXIS] = false; }
|
|
142
|
+ #define disable_x() do{ X_ENABLE_WRITE(!X_ENABLE_ON); axis_known_position[X_AXIS] = false; }while(0)
|
143
|
143
|
#else
|
144
|
|
- #define enable_x() ;
|
145
|
|
- #define disable_x() ;
|
|
144
|
+ #define enable_x() NOOP
|
|
145
|
+ #define disable_x() NOOP
|
146
|
146
|
#endif
|
147
|
147
|
|
148
|
|
-#if HAS_Y_ENABLE
|
149
|
|
- #if ENABLED(Y_DUAL_STEPPER_DRIVERS)
|
150
|
|
- #define enable_y() { Y_ENABLE_WRITE( Y_ENABLE_ON); Y2_ENABLE_WRITE(Y_ENABLE_ON); }
|
151
|
|
- #define disable_y() { Y_ENABLE_WRITE(!Y_ENABLE_ON); Y2_ENABLE_WRITE(!Y_ENABLE_ON); axis_known_position[Y_AXIS] = false; }
|
152
|
|
- #else
|
153
|
|
- #define enable_y() Y_ENABLE_WRITE( Y_ENABLE_ON)
|
154
|
|
- #define disable_y() { Y_ENABLE_WRITE(!Y_ENABLE_ON); axis_known_position[Y_AXIS] = false; }
|
155
|
|
- #endif
|
|
148
|
+#if HAS_Y2_ENABLE
|
|
149
|
+ #define enable_y() do{ Y_ENABLE_WRITE( Y_ENABLE_ON); Y2_ENABLE_WRITE(Y_ENABLE_ON); }while(0)
|
|
150
|
+ #define disable_y() do{ Y_ENABLE_WRITE(!Y_ENABLE_ON); Y2_ENABLE_WRITE(!Y_ENABLE_ON); axis_known_position[Y_AXIS] = false; }while(0)
|
|
151
|
+#elif HAS_Y_ENABLE
|
|
152
|
+ #define enable_y() Y_ENABLE_WRITE( Y_ENABLE_ON)
|
|
153
|
+ #define disable_y() do{ Y_ENABLE_WRITE(!Y_ENABLE_ON); axis_known_position[Y_AXIS] = false; }while(0)
|
156
|
154
|
#else
|
157
|
|
- #define enable_y() ;
|
158
|
|
- #define disable_y() ;
|
|
155
|
+ #define enable_y() NOOP
|
|
156
|
+ #define disable_y() NOOP
|
159
|
157
|
#endif
|
160
|
158
|
|
161
|
|
-#if HAS_Z_ENABLE
|
162
|
|
- #if ENABLED(Z_DUAL_STEPPER_DRIVERS)
|
163
|
|
- #define enable_z() { Z_ENABLE_WRITE( Z_ENABLE_ON); Z2_ENABLE_WRITE(Z_ENABLE_ON); }
|
164
|
|
- #define disable_z() { Z_ENABLE_WRITE(!Z_ENABLE_ON); Z2_ENABLE_WRITE(!Z_ENABLE_ON); axis_known_position[Z_AXIS] = false; }
|
165
|
|
- #else
|
166
|
|
- #define enable_z() Z_ENABLE_WRITE( Z_ENABLE_ON)
|
167
|
|
- #define disable_z() { Z_ENABLE_WRITE(!Z_ENABLE_ON); axis_known_position[Z_AXIS] = false; }
|
168
|
|
- #endif
|
|
159
|
+#if HAS_Z2_ENABLE
|
|
160
|
+ #define enable_z() do{ Z_ENABLE_WRITE( Z_ENABLE_ON); Z2_ENABLE_WRITE(Z_ENABLE_ON); }while(0)
|
|
161
|
+ #define disable_z() do{ Z_ENABLE_WRITE(!Z_ENABLE_ON); Z2_ENABLE_WRITE(!Z_ENABLE_ON); axis_known_position[Z_AXIS] = false; }while(0)
|
|
162
|
+#elif HAS_Z_ENABLE
|
|
163
|
+ #define enable_z() Z_ENABLE_WRITE( Z_ENABLE_ON)
|
|
164
|
+ #define disable_z() do{ Z_ENABLE_WRITE(!Z_ENABLE_ON); axis_known_position[Z_AXIS] = false; }while(0)
|
169
|
165
|
#else
|
170
|
|
- #define enable_z() ;
|
171
|
|
- #define disable_z() ;
|
|
166
|
+ #define enable_z() NOOP
|
|
167
|
+ #define disable_z() NOOP
|
172
|
168
|
#endif
|
173
|
169
|
|
174
|
170
|
#if HAS_E0_ENABLE
|
175
|
|
- #define enable_e0() E0_ENABLE_WRITE( E_ENABLE_ON)
|
|
171
|
+ #define enable_e0() E0_ENABLE_WRITE( E_ENABLE_ON)
|
176
|
172
|
#define disable_e0() E0_ENABLE_WRITE(!E_ENABLE_ON)
|
177
|
173
|
#else
|
178
|
|
- #define enable_e0() /* nothing */
|
179
|
|
- #define disable_e0() /* nothing */
|
|
174
|
+ #define enable_e0() NOOP
|
|
175
|
+ #define disable_e0() NOOP
|
180
|
176
|
#endif
|
181
|
177
|
|
182
|
178
|
#if (EXTRUDERS > 1) && HAS_E1_ENABLE
|
183
|
|
- #define enable_e1() E1_ENABLE_WRITE( E_ENABLE_ON)
|
|
179
|
+ #define enable_e1() E1_ENABLE_WRITE( E_ENABLE_ON)
|
184
|
180
|
#define disable_e1() E1_ENABLE_WRITE(!E_ENABLE_ON)
|
185
|
181
|
#else
|
186
|
|
- #define enable_e1() /* nothing */
|
187
|
|
- #define disable_e1() /* nothing */
|
|
182
|
+ #define enable_e1() NOOP
|
|
183
|
+ #define disable_e1() NOOP
|
188
|
184
|
#endif
|
189
|
185
|
|
190
|
186
|
#if (EXTRUDERS > 2) && HAS_E2_ENABLE
|
191
|
|
- #define enable_e2() E2_ENABLE_WRITE( E_ENABLE_ON)
|
|
187
|
+ #define enable_e2() E2_ENABLE_WRITE( E_ENABLE_ON)
|
192
|
188
|
#define disable_e2() E2_ENABLE_WRITE(!E_ENABLE_ON)
|
193
|
189
|
#else
|
194
|
|
- #define enable_e2() /* nothing */
|
195
|
|
- #define disable_e2() /* nothing */
|
|
190
|
+ #define enable_e2() NOOP
|
|
191
|
+ #define disable_e2() NOOP
|
196
|
192
|
#endif
|
197
|
193
|
|
198
|
194
|
#if (EXTRUDERS > 3) && HAS_E3_ENABLE
|
199
|
|
- #define enable_e3() E3_ENABLE_WRITE( E_ENABLE_ON)
|
|
195
|
+ #define enable_e3() E3_ENABLE_WRITE( E_ENABLE_ON)
|
200
|
196
|
#define disable_e3() E3_ENABLE_WRITE(!E_ENABLE_ON)
|
201
|
197
|
#else
|
202
|
|
- #define enable_e3() /* nothing */
|
203
|
|
- #define disable_e3() /* nothing */
|
|
198
|
+ #define enable_e3() NOOP
|
|
199
|
+ #define disable_e3() NOOP
|
204
|
200
|
#endif
|
205
|
201
|
|
206
|
202
|
/**
|