Question: write a Arduino code that would work for this lab Requirements and Procedure: Use your hands and a screwdriver to put together the mini 2
write a Arduino code that would work for this lab
Requirements and Procedure:
Use your hands and a screwdriver to put together the mini layer rover platform. There
are two DC motors that you will need to attach securely to the red aluminum chassis.
Think about the cables coming from the motors and where you may want them to go
not go Please consult the pictures below at the bottom of Part for a better
understanding of what the end result may look like.
Pickup an Adafruit or Arduino Motor Shield from Lab material location in B&H
Connect your Shield to your Uno.
Connect your DC motors to the motor and pins.
You are now ready to code away! If you are using the Adafruit Shield, Load the Adafruit
Motor Shield and Adafruit Motor Shield V library, which will also load some examples
from the examples menu Spend time looking at the DC Motor control example this
will be most helpful.
Develop code to make Rover do a dance at least different steps eg turn right, move
forward, turn left, move backward, etc. on command. Define your state machine in
Arduino code. You might think about a push button. At the end of the dance, Rover
must wait until the next command. Hint: Think about how you could represent "waiting
for a command" in code, and how this relates to your state machine diagram.
Finally, disconnect the umbilical USB The V battery you were using to power the
motors can also be used to power the Arduino. Note the jumper that came with your
Shield there is a spot on the Motor Shield that will accept the jumper and will connect
V power to the Vin on the Arduino. You will then have Rover doing a dance, alone, on
command of a button press.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
