This commit is contained in:
Gregg 2023-06-27 22:19:43 -05:00
commit cd85ca5c94
2 changed files with 11 additions and 4 deletions

View File

@ -107,7 +107,7 @@ The **StepperControl** class provides the following methods to operate and contr
* not all *modes* are supported by all driver chips
* the quarter- and eighth-step modes require microstepping PWM functionality (either via ESP32 pins, or onboard the driver chip)
* it is possible, though not recommended, to change the step type *mode* while the motor is turning
* see Stepper Motor Modes for a brief primer on how stepper motors are typically driven
* see [Stepper Motor Modes](StepperModes.md) for a brief primer on how stepper motors are typically driven
---

View File

@ -1,7 +1,14 @@
# Stepper Motor Modes
![fullStep2](images/fullStepTwoPhase.png)
A typical stepper motor has two sets of coils, *A* and *B*. Applying a current to one or both coils creates a magnetic field that fixes the motor's position. Any changes to the direction and/or magnitude of the current flowing through the coils causes the motor to "step" to a new fixed position. By repeatedly changing the current flow according to a specific pattern the motor can be made to continuously step clockwise or counterclockwise. The specific pattern chosen, known as the *step mode* in the **StepperControl** class, determines the size of the step and overall performance of the motor. The speed at which changes to the current flow are made determines the speed at which the motor rotates.
![fullStep1](images/fullStepOnePhase.png)
**StepperControl** supports two different types of step modes: digital-only modes that simply set the direction of the current flow to either fully on or off, and PWM modes that use a PWM signal to also modulate the magnitude of the current flow.
![halfStep2](images/halfStep.png)
<img width="290" alt="image" src="https://github.com/HomeSpan/HomeSpan/assets/68477936/8bea7031-7325-4ded-8ebd-5554d8f1e13d"><br>
<img width="291" alt="image" src="https://github.com/HomeSpan/HomeSpan/assets/68477936/cbf2fea5-072e-4fef-9231-504bb483b0c0"><br>
<img width="434" alt="image" src="https://github.com/HomeSpan/HomeSpan/assets/68477936/ec317c77-fbd9-4641-9d50-d822b477c9ec"><br>
<img width="505" alt="image" src="https://github.com/HomeSpan/HomeSpan/assets/68477936/75a6176b-b5b4-4b85-a394-a4d6e1f9bf3d"><br>