Skip to content

AccelStepper library issue

When in the main loop is added for example a logging function about temperature, like:

    // Get inside Temperature
    pca9540.set_channel(PCA9540_CH1);
    temp_sensor.wake_up();
    rotator.inside_temperature = temp_sensor.get_temp();
    temp_sensor.sleep();
    if (rotator.inside_temperature > OVER_TEMP) {
        rotator.rotator_status = error;
        rotator.rotator_error = over_temperature;
    }

the stepper motors moves slower than without the above code in main loop.
One solution is to change the the accelstepper library with arduino-libraries/Stepper.

Edited by Agis Zisimatos
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information