gear
This commit is contained in:
parent
6cb3dcacd4
commit
d85ff8ace8
|
@ -16,10 +16,10 @@ bgp, 2023
|
||||||
#define RELAY 10 // d10 ключ для отключения терминала и двигателя в ночное время
|
#define RELAY 10 // d10 ключ для отключения терминала и двигателя в ночное время
|
||||||
#define BTN_PIN2 11 // кнопка настройки
|
#define BTN_PIN2 11 // кнопка настройки
|
||||||
|
|
||||||
#define STEPPER_SPEED 10 * 21
|
#define STEPPER_SPEED 100 * 1
|
||||||
#define STEPPER_REV 200 * 4
|
#define STEPPER_REV 200 * 4 * 1
|
||||||
#define STEPPER_DELAY 1000
|
#define STEPPER_DELAY 1000
|
||||||
#define GROOVE_COUNT 3
|
#define GROOVE_COUNT 1
|
||||||
#define GEAR 4
|
#define GEAR 4
|
||||||
|
|
||||||
// =========================================================
|
// =========================================================
|
||||||
|
@ -213,7 +213,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 * 1/GEAR) / GROOVE_COUNT);
|
myStepper.step((STEPPER_REV * GEAR) / GROOVE_COUNT);
|
||||||
delayMicroseconds(STEPPER_DELAY);
|
delayMicroseconds(STEPPER_DELAY);
|
||||||
// oneRev();
|
// oneRev();
|
||||||
disableMotor();
|
disableMotor();
|
||||||
|
|
Loading…
Reference in New Issue