added support for G92
This commit is contained in:
parent
68ff56a8b1
commit
c491324e89
2
gcode.c
2
gcode.c
@ -36,6 +36,7 @@
|
|||||||
#define NEXT_ACTION_DEFAULT 0
|
#define NEXT_ACTION_DEFAULT 0
|
||||||
#define NEXT_ACTION_DWELL 1
|
#define NEXT_ACTION_DWELL 1
|
||||||
#define NEXT_ACTION_GO_HOME 2
|
#define NEXT_ACTION_GO_HOME 2
|
||||||
|
#define NEXT_ACTION_SET_COORDINATE_OFFSET 3
|
||||||
|
|
||||||
#define MOTION_MODE_SEEK 0 // G0
|
#define MOTION_MODE_SEEK 0 // G0
|
||||||
#define MOTION_MODE_LINEAR 1 // G1
|
#define MOTION_MODE_LINEAR 1 // G1
|
||||||
@ -235,6 +236,7 @@ uint8_t gc_execute_line(char *line) {
|
|||||||
switch (next_action) {
|
switch (next_action) {
|
||||||
case NEXT_ACTION_GO_HOME: mc_go_home(); clear_vector(gc.position); break;
|
case NEXT_ACTION_GO_HOME: mc_go_home(); clear_vector(gc.position); break;
|
||||||
case NEXT_ACTION_DWELL: mc_dwell(trunc(p*1000)); break;
|
case NEXT_ACTION_DWELL: mc_dwell(trunc(p*1000)); break;
|
||||||
|
case NEXT_ACTION_SET_COORDINATE_OFFSET: break; // no action needed
|
||||||
case NEXT_ACTION_DEFAULT:
|
case NEXT_ACTION_DEFAULT:
|
||||||
switch (gc.motion_mode) {
|
switch (gc.motion_mode) {
|
||||||
case MOTION_MODE_CANCEL: break;
|
case MOTION_MODE_CANCEL: break;
|
||||||
|
Loading…
Reference in New Issue
Block a user