|
@@ -20,7 +20,14 @@
|
20
|
20
|
*
|
21
|
21
|
*/
|
22
|
22
|
|
|
23
|
+#include "../../inc/MarlinConfig.h"
|
|
24
|
+
|
|
25
|
+#if ENABLED(ARC_SUPPORT)
|
|
26
|
+
|
23
|
27
|
#include "../gcode.h"
|
|
28
|
+#include "../../module/motion.h"
|
|
29
|
+#include "../../module/planner.h"
|
|
30
|
+#include "../../module/temperature.h"
|
24
|
31
|
|
25
|
32
|
#if N_ARC_CORRECTION < 1
|
26
|
33
|
#undef N_ARC_CORRECTION
|
|
@@ -203,7 +210,7 @@ void plan_arc(
|
203
|
210
|
* G2 I10 ; CW circle centered at X+10
|
204
|
211
|
* G3 X20 Y12 R14 ; CCW circle with r=14 ending at X20 Y12
|
205
|
212
|
*/
|
206
|
|
-void gcode_G2_G3(bool clockwise) {
|
|
213
|
+void GcodeSuite::G2_G3(const bool clockwise) {
|
207
|
214
|
if (IsRunning()) {
|
208
|
215
|
|
209
|
216
|
#if ENABLED(SF_ARC_FIX)
|
|
@@ -211,7 +218,7 @@ void gcode_G2_G3(bool clockwise) {
|
211
|
218
|
relative_mode = true;
|
212
|
219
|
#endif
|
213
|
220
|
|
214
|
|
- gcode.get_destination_from_command();
|
|
221
|
+ get_destination_from_command();
|
215
|
222
|
|
216
|
223
|
#if ENABLED(SF_ARC_FIX)
|
217
|
224
|
relative_mode = relative_mode_backup;
|
|
@@ -254,7 +261,7 @@ void gcode_G2_G3(bool clockwise) {
|
254
|
261
|
|
255
|
262
|
// Send the arc to the planner
|
256
|
263
|
plan_arc(destination, arc_offset, clockwise);
|
257
|
|
- gcode.refresh_cmd_timeout();
|
|
264
|
+ refresh_cmd_timeout();
|
258
|
265
|
}
|
259
|
266
|
else {
|
260
|
267
|
// Bad arguments
|
|
@@ -263,3 +270,5 @@ void gcode_G2_G3(bool clockwise) {
|
263
|
270
|
}
|
264
|
271
|
}
|
265
|
272
|
}
|
|
273
|
+
|
|
274
|
+#endif // ARC_SUPPORT
|