CE 432 Fall 2021
HW 6: Sensors and Actuators
Taylor Nakai
tsnakai@fortlewis.edu

Introduction:
In this homework, we used Dr. Li's Intro in Position and Temperature Sensors and Light, Sound, Piezo, Capacitive, Accel, RFID slides that were provided to answer the questions asked. The homework had us gain experience with strain gauges, the HC-SR04 ultrasonic module, pulse generators, the MPU6050, a buzzer, the NEMA17 stepper motor, joystick, Open-Smart 2.4 GHz transceiver, and a rotary encoder. This homework was necessary as it alllowed us to gain experience and comfortability with these three parts to prepare us for upcoming Robotics II Projects like the Two-Wheel Balancing Car. The first problem had us analyze the Wheatstone Bridge and strain gauges that formed the the full-bridge, half-bridge, and quarter-bridge and explain why the full bridge is the most sensitive. The second problem had us create a sketch without using the SR04 library to measure distance using the HC-SR04 ultrasonic module. The third problem had us create a pulse detector using a function generator, an Arduino Uno, and an oscilloscope. The fourth problem had us create a vibration detector using a MPU6050, an Arduino Uno, and a buzzer. The fifth problem had us create a sketch that allowed us to control the speed and rotation direction of the NEMA17 stepper motor. The sixth problem had us implement Algorithm II using the rotary encoder and the Arduino Uno. All the code used in this homework is in the 'HW_6_Sensors_Actuators.txt" file.

Materials:
MaterialsQuantity
Analog Joystick1
Open-Smart Transceiver
2
Arduino Uno2
A4988 Motor Driver1
NEMA17 Stepper Motor1
HC-SR04 Ultrasonic Module
1
MPU6050 1
Buzzer 1
Rotary Encoder
1
Lipo Battery3
Bread Board1
Lipo Battery Catridge1
Jumper CablesInfinity

Problem 1:
In the first problem had us analyze the Wheatstone Bridge and strain gauges that formed the the full-bridge, half-bridge, and quarter-bridge and explain why the full bridge is the most sensitive. Figure 1 shows all the calculations for the full-bridge, half-bridge, and quarter-bridge. We can see from the calculations that the full-bridge is two times more sensitive than the half-bridge and four times more sensitive than the quarter-bridge.


Figure 1. Calulations of the full-bridge, half-bridge, and quarter-bridge.


Problem 2:
In the second problem we had to create a sketch without using the SR04 library to measure distance using the HC-SR04 ultrasonic module. Figure 2 shows the demonstration of the HC-SR04 module measuring distance.


Figure 2. Demonstration of the HC-SR04 module measuring distance.

Problem 3:
In third problem we had to create a pulse detector using a function generator, an Arduino Uno, and an oscilloscope. Figure 3 shows the demonstration of the pulse detector sensing a pulse and delivering a ~400 us pulse around ~800 us later than the input pulse.


Figure 3. Demonstration of the pulse detector system.

Problem 4:
In the fourth problem we had to create a vibration detector using a MPU6050, an Arduino Uno, and a buzzer. Figure 4 shows the demonstration of the vibration detector using an Arduino Uno, MPU6050, and a buzzer.


Figure 4. Demonstration of the vibration detector system.

Problem 5:
In the fifth problem we had to create a sketch that allowed us to control the speed and rotation direction of the NEMA17 stepper motor. Figure 5 shows the demonstration of controlling the speed and rotation direction of the NEMA17 stepper motor.


Figure 5. Demonstration of controlling the speed and rotation direction of NEMA17 stepper motor.

Problem 6:
In the sixth problem we had to implement Algorithm II using the rotary encoder and the Arduino Uno. Figure 6 shows the demonstration implementing algorithm II using the rotatary encoder.


Figure 6. Demonstration of implementation of algorithm II using the rotatory encoder.


Figure 7. Explanation of implementation of algorithm II using the rotatory encoder.

Discussion:
By completing this homework, we were able to gain comfortability using the strain gauges, the HC-SR04 ultrasonic module, pulse generators, the MPU6050, a buzzer, the NEMA17 stepper motor, joystick, Open-Smart 2.4 GHz transceiver, and a rotary encoder. Learning about all of these sensors and components was interesting. The one that took me the longest was the pulse generator problem. It was nice to be able to implement code that made the sensors function as they were supposed to. I believe that know more about these sensors and component will be beneficial. This was a goood homework where I was able to expand my knowledge. Overall, this homework was fun and I hope that we'll be able to use all these sensors and components more often in the future.
------------------------------------------------