CE432 Fall 2022
Homework 8
Name: David Lee

Email: djlee1@fortlewis.edu

Encoder controlled Stepper Motor

Introduction:
Using an Encoder control the movement of the stepper motor

Materials and Methods:
Arduino UNO, Breadboard, Encoder, Stepper Motor, Driver


Results:

Task 1: Connect and Control the Stepper motor using the Arduino



Figure 1: Shows a video of the Stepper motor Functioning Correctly
.
Task 2: Connect the Encoder and use it to control the Motor


Figure 2: Shows Print out the the Encoders position.
Figure 2 Shows that the encoder was connected to the circuit properly since we are able to see the arduino outputs



Figure 3: Video of the Encoder spinning to get the result in Figure 2



Figure 4: Video of the Encoder Controlling the Motor

The Code for this project is on the server at CE432/HW8/Encoder.ino



Discussion:
This Project was able to be succesfully completed. Learning how an encoder works was good and then being able to implement it with a stepper motor will be good for the Balancing car project.
The only issue I ran into while doing the project was that sometimes the encoder/arduino script wouldn't function corrected and it would bounce back and forth between two values on occasion.