     }
     if (_currentDelays > 2000)
     {
-        delay(floorf(_currentDelays / 1000));
+        delay((int)(_currentDelays / 1000));
         delayMicroseconds(_currentDelays % 1000);
     }
     else

    Serial.begin(115200);
    delay(1000);
    Serial.println("opened");
    stepperX.setMicroStep(32);
    stepperY.setMicroStep(32);
    stepperX.enableOutputs();
    stepperY.enableOutputs();
}

void loop()

#include <MeStepper.h>
#define STATES_COUNT 128
#define COMMANDS_COUNT 3
#define PULSES_PER_MM 50
#define CURVE_SECTION 0.5
#define NUM_STEPS 100
// #define DEBUG true
struct MotionState
{
    bool dirX;
    bool dirY;
    long err;
    double dx;
    double dy;
    long tx;
