CSCE 439/839: Robotics
Homework 2
Instructor: Carrick Detweiler
carrick _at_ cse.unl.edu
University of Nebraska-Lincoln
Fall 2013
Started: Thursday, October 10, 2013
Due: 5pm Friday, October 25th, 2013
Instructions: This homework is an individual
assignment, collaboration is not allowed. If you discuss any problems
with others, please note this on the assignment as described in the
syllabus. Also note any materials outside of lecture notes, course
textbooks, and datasheets that you used. Answer all questions with
complete sentences and describe your reasoning where appropriate
for full credit. This homework is due on the date listed above before
the start of class.
You should also make sure that you properly label and describe any figures or plots that you include in your writeup. You will not receive full credit if you do not explain these. In addition, while you do
not need to turn in a printout of your code for this assignment (instead you should submit via handin), you should refer to your code where needed to answer the questions (e.g. say "See file mynode/launch/test.launch for this problem, which ...").
You must bring a printout (typed, not hand written) of your assignment class on the day it is due! Make sure to answer questions in complete sentences and explain answers as needed.
You must also turn in your code for all parts of this problem
and a PDF version of your report by visiting http://cse.unl.edu/~cse439/handin/. Failing to
electronically turn in your code (and PDF) will result in a 10 point penalty on
this assignment. Points may also be deducted for coding errors, poor
style, or poor commenting.
Name:
Hovercraft
5pts] What are the requirements for a robot to be
omnidirectional?
5pts] With uni-directional thrusters (as ours are) what is
the minimum number of thrusters needed to create an omni-directional
hovercraft that is also able to rotate either direction in the x-axis? What if the thrusters are bi-directional? Explain.
5pts] What are two problems that may occur if the center
of mass of your hovercraft is not centered on the vehicle?
5pts] How much current do the processors on the
hoverboard use when the thrusters are not running. How much
power does one thruster set at 0.5 require? Include a plot of the
current over time for both of these. (Hint: there are ROS topics that
gives information on these.)
ROS: In this problem, you will create a ROS node that will
compute statistics for the Huskers' Football team. For these questions, refer to the hw2 code, especially the rawStats node that defines and publishes a message of
type offensivePlay on the topic
/plays/huskerOffensivePlay.
5pts] What ROS command-line command do you use to
create a new node, called offensiveStats that is written in C++ or Python
and is able to subscribe to messages of type offensivePlay?
5pts] Write the code in this node to compute the pass completion
percentage (number completed passes divided by total number of passes
attempted).
5pts] Create a new message type that contains the pass
completion percentage as well as the total passing and rushing
(non-passing yards gained) yards for this game. How do you ensure
that this message is compiled when you run rosmake?
5pts] Write the code to create a publisher, populate, and
send the above message. Make sure to comment your code.
5pts] What command would you use to plot the total yards
completed? Give the command, the proper arguments, and include the plot.
5pts] Without changing the rawStats node, launch a new pair of nodes that publish raw stats on the topic \plays\opponentOffensivePlay and also generates the offensive stats for the opponent. Hint: look into "remap" in the ros documentation.
5pts] Create a launch file that will launch all four nodes.
Sensing
5pts] What is the difference between precision and
accuracy? Which is more important for the gyroscope on the
hovercraft? Why?
5pts] How do you get position information from an
accelerometer? What would the position error be if the accelerometer
has a 2% error after moving 50 meters?
5pts] 839 Only: The
gyro on the hovercraft tends to drift. What additional sensor(s)
could you add to the hovercraft to correct for this drift. How would
this work?
Path Planning
Figure 1: Bug algorithms
5pts] In Figure 1, draw the path the Bug1
algorithm would take. Explain the algorithm.
5pts] Draw the visibility graph for Figure 2 and
indicate the path that the robot follow from the start to the goal.
Explain.
5pts] 839 Only: In Figure 1, draw the path Tangent Bug
would take (in a different color/style line or on a separte
plot). Explain the algorithm.
5pts] 839 Only: In
Figure 1, one of the Bug algorithms outperformed the
other. Draw a different figure where the performance is reversed.
Explain what happens.
Figure 2: Visibility Graph
PID
5pts] Write the equations for a PID controller and explain
the impact of each of the P, I, and D terms.
5pts] In a controller running at 10Hz with P=10, I=0.1,
and D=4 (without any loop time compensation), what would you set the
parameters to if the loop rate was increased to 20Hz? Why?
5pts] 839 Only: List and explain 2 different problems that can occur
with PID controllers and how you can mitigate these problems in a PID
controller.
Which question took the most time on this assignment?
Approximately how much time did the total assignment take?
File translated from
TEX
by
TTH,
version 3.89.
On 18 Oct 2013, 10:10.