groove count

This commit is contained in:
Kseninia Mikhaylova 2024-10-03 14:02:56 +03:00
parent c6c50ff882
commit 416fc2cddc
1 changed files with 3 additions and 2 deletions

View File

@ -21,9 +21,10 @@ bgp, 2023
#define STEPS_FRW 258 // шаги вперёд #define STEPS_FRW 258 // шаги вперёд
#define STEPS_BKW 0 // шаги назад #define STEPS_BKW 0 // шаги назад
#define STEPPER_SPEED 30 * 2 #define STEPPER_SPEED 10 * 21
#define STEPPER_REV 200 * 4 #define STEPPER_REV 200 * 4
#define STEPPER_DELAY 1000 #define STEPPER_DELAY 1000
#define GROOVE_COUNT 3
// ========================================================= // =========================================================
#include <EEPROM.h> #include <EEPROM.h>
@ -216,7 +217,7 @@ void feed()
digitalWrite(SLEEP, HIGH); digitalWrite(SLEEP, HIGH);
delayMicroseconds(STEPPER_DELAY); delayMicroseconds(STEPPER_DELAY);
for (int i = 0; i < feedAmount; i++) for (int i = 0; i < feedAmount; i++)
myStepper.step(STEPPER_REV); myStepper.step(STEPPER_REV / GROOVE_COUNT);
delayMicroseconds(STEPPER_DELAY); delayMicroseconds(STEPPER_DELAY);
// oneRev(); // oneRev();
disableMotor(); disableMotor();