forked from DCC-EX/EX-Turntable
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstandard_steppers.h
More file actions
32 lines (24 loc) · 858 Bytes
/
Copy pathstandard_steppers.h
File metadata and controls
32 lines (24 loc) · 858 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
/*
* © 2022 Peter Cole
*
* These are the standard stepper controller and motor definitions.
*/
#ifndef STANDARD_STEPPERS_h
#define STANDARD_STEPPERS_h
#include <Arduino.h>
#include "AccelStepper.h"
#define UNUSED_PIN 127
#define FULLSTEPS 4096
/*
* RKS left these as original only added #ifndef to have A4988 only for RT_EX_TURNTABLE
*/
#ifndef USE_RT_EX_TURNTABLE
#define ULN2003_HALF_CW AccelStepper(AccelStepper::HALF4WIRE, A3, A1, A2, A0)
#define ULN2003_HALF_CCW AccelStepper(AccelStepper::HALF4WIRE, A0, A2, A1, A3)
#define ULN2003_FULL_CW AccelStepper(AccelStepper::FULL4WIRE, A3, A1, A2, A0)
#define ULN2003_FULL_CCW AccelStepper(AccelStepper::FULL4WIRE, A0, A2, A1, A3)
#define A4988 AccelStepper(AccelStepper::DRIVER, A0, A1)
#else
#define A4988 AccelStepper(AccelStepper::DRIVER, STEPPER_STEP_PIN, STEPPER_DIR_PIN)
#endif
#endif