Electronics and Software - Can't Do This Anymore
The electronics and software for the build were relatively straightforward, as we just needed to rotate a motor at a fixed speed in one direction continuously.
Electronics:
- We used a motor shield connected to an Arduino Uno to drive the single DC motor (the same setup from the first build)
- We also incorporated an on/off switch to prevent us from having to plug and unplug the power cable to test
Software:
(Basic Motor Control With the Arduino Motor Shield)
//RMD Final Project Code
//Victor, Abhi, David
void setup() {
Serial.begin(9600);
pinMode(12, OUTPUT); //Initiates Motor Channel A pin
pinMode(9, OUTPUT); // Channel A Brake pin
}
void loop() {
digitalWrite(12, LOW); //Reverse direction
digitalWrite(9, LOW);
analogWrite(3, 255); //Run motor at full speed
}
Welcome to the University Wiki Service! Please use your IID (yourEID@eid.utexas.edu) when prompted for your email address during login or click here to enter your EID. If you are experiencing any issues loading content on pages, please try these steps to clear your browser cache.