From 3580e32142ceca52a2ec0c3acb477acb135803f5 Mon Sep 17 00:00:00 2001 From: Holger Weber Date: Fri, 27 Feb 2026 00:56:23 +0100 Subject: [PATCH] Fixed sending ack after move is done. --- src/Functions.cpp | 22 +- src/Helper_Functions.cpp | 12 +- svg/holger.svg | 24 +- svg/rect.svg | 979 +++++++++++++++++++++++++++++++++++++++ 4 files changed, 1008 insertions(+), 29 deletions(-) create mode 100644 svg/rect.svg diff --git a/src/Functions.cpp b/src/Functions.cpp index db236d2..1bc9181 100644 --- a/src/Functions.cpp +++ b/src/Functions.cpp @@ -83,23 +83,23 @@ void stepperMove() int penStepsEBB = 0; // Pen int rotStepsEBB = 0; // Rot - moveToDestination(); - if (!parseSMArgs(&duration, &penStepsEBB, &rotStepsEBB)) { sendError(); return; } - sendAck(); - + if ((penStepsEBB == 0) && (rotStepsEBB == 0)) { - delay(duration); + // delay(duration); + sendAck(); return; } - + prepareMove(duration, penStepsEBB, rotStepsEBB); + moveToDestination(); + sendAck(); } void setPen() @@ -110,7 +110,7 @@ void setPen() char *arg; char cstrMsg[20]; - moveToDestination(); + // moveToDestination(); arg = nextCommandArg(); if (arg != NULL) @@ -136,12 +136,12 @@ void setPen() { value = atoi(val); sendAck(); - delay(value); + // delay(value); } if (val == NULL && arg != NULL) { sendAck(); - delay(500); + // delay(500); } // Serial.println("delay"); if (val == NULL && arg == NULL) @@ -154,7 +154,7 @@ void togglePen() int value; char *arg; - moveToDestination(); + // moveToDestination(); arg = nextCommandArg(); if (arg != NULL) @@ -164,7 +164,7 @@ void togglePen() doTogglePen(); sendAck(); - delay(value); + // delay(value); } void doTogglePen() diff --git a/src/Helper_Functions.cpp b/src/Helper_Functions.cpp index c3ee5d8..2650eda 100644 --- a/src/Helper_Functions.cpp +++ b/src/Helper_Functions.cpp @@ -230,16 +230,16 @@ void prepareMove(uint16_t duration, int penStepsEBB, int rotStepsEBB) void moveOneStep() { - while (g_pStepperPen->isRunning() || g_pStepperRotate->isRunning()) - ; - Log("moveOneStep done"); + Log("moveOneStep"); + while (g_pStepperPen->isRunning() || g_pStepperRotate->isRunning()); + Log("done"); } void moveToDestination() { - while (g_pStepperPen->isRunning() || g_pStepperRotate->isRunning()) - ; - Log("moveToDestination done"); + Log("moveToDestination"); + while (g_pStepperPen->isRunning() || g_pStepperRotate->isRunning()); + Log("done"); } void setprgButtonState() diff --git a/svg/holger.svg b/svg/holger.svg index ea74c68..3693997 100644 --- a/svg/holger.svg +++ b/svg/holger.svg @@ -1,7 +1,7 @@ @@ -40,9 +40,9 @@ inkscape:pagecheckerboard="0" inkscape:deskcolor="#d1d1d1" showgrid="false" - inkscape:zoom="0.44539441" - inkscape:cx="1011.4631" - inkscape:cy="619.67549" + inkscape:zoom="0.22269721" + inkscape:cx="222.2749" + inkscape:cy="624.16589" inkscape:window-width="1920" inkscape:window-height="1008" inkscape:window-x="0" @@ -135,7 +135,7 @@ + + + + + + + + + + image/svg+xml + + 2026-02-26T20:25:37.207Z + + + EggBot Sorbische Eier + + + + + Copyright 2026 André Fiedler + + + + + EggBot Sorbische Eier + + + eggi-1652987163-1.3.40 + https://eggbot.app/ + https://eggbot.app/ + de + + + sorbian + eggbot + ornament + version-1.3.40 + + + 2048x1024px + Generated with EggBot Sorbische Eier using eggbot-app 1.3.40 + + + EggBot Sorbische Eier + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +