This is an individual homework. While you may discuss the problems of this homework with others, at no time should you let any other person type the commands for you or use other persons computers for this homework. We will detect plagiarism using automated tools and will prosecute all violations to the fullest extent of the university regulations, including failing this course, academic probation, and expulsion from the university. If you have technical problems with completing any of the tasks on your own computer (e.g. because your Linux is not running {properly}) let us know in advance and we will find a solution!
Robotics Labs
These labs are for class A students only. Class B students can observe by joining a class A group. All registered groups (register here) will be assigned to one of the four practice tracks (A, B, C or D).
Practice is on three Saturdays (May 21st, May 28th and June 4th).
Practice Track
Time
A
08:00 - 10:00
B
10:15 - 12:15
C
13:15 - 15:15
D
15:30 - 17:30
Learn ROS
The goal of this praparation is to get familiar with ROS. ROS - the Robot Operating System - is a set of software libraries and tools for writing robot applications. It features drivers and state-of-the-art algorithms as well as powerful developer tools and is open source. We will be using ROS to program the robots in the practice sessions.
You should learn the basic principles of ROS: Messages, Topics and Nodes as well as how to replay sensor data using rosbag and how to visualize the sensor data using rviz. You can use any source you want for learning about ROS, but I recommend the official documentation and tutorials:
Use rosbag info to find out about the topics and messages of the bagfile.
Start a roscore. Use: roscore Remember that you might have to source first if you want to use any ROS program: source /opt/ros/indigo/setup.bash (replace "indigo" with "jade" if you use the "jade" version of ROS)
Play back the bagfile. For example use: rosbag play follow_line.bag You may play with the options -r and --pause
Use rostopic list, rostopic info xxx, rostopic echo xxx, rosmsg show xxx, rosnode list, rosnode info xxx (replace xxx with a name) to find out about the topics and messages of the bagfile.
You can get help about the programs by typing in just the program name without arguments (e.g. rosnode) and also get detailed help for specific commands (e.g. rostopic echo -h)
Arrange your consoles such that the rosbag info, the rosbag play, the rostopic list and the rostopic echo are all visible at the same time.
Make a screen shot of the whole screen (press the Print Screen button on your keyboard). The four consoles from above should be visible. Name the file "consoles.png". Do not edit any of the screen shots in any way!
Add your consoles.png to the gradebot "robotics lab prep 1" repository and push it to the gradebot.
Part 2: Learn about rviz
Start a roscore.
Play back the bagfile from part 1.
Use ROS rviz to display the data in the bagfile. Use: rosrun rviz rviz Display the odometry.
Make a screen shot of the whole screen (press the Print Screen button on your keyboard). The rviz window should be visible as well as some parts of the consoles. Name the file "rviz.png". Clarification: In the rviz window of the screen shot the full odometry "path" should be visible!
Add your rviz.png to the gradebot "robotics lab prep 1" repository and push it to the gradebot.
Hints for part 2: To display the odometry you need to add a "Display" of the type "Odometry". So in the Displays dock of the rviz application click on "Add" and select "Odometry". In the "Displays" dock you also see a new "Odometry" entry in the tree view. Expand it and enter the topic (name) for the messages that you want to display. Hint: If you click on "Topic" while the bagfile is playing you can simply select a topic rather than having to type the topic in by hand. You can also play with the other parameters in the tree view (e.g. try to adjust the "Length" to 0.1.
Part 3: Prepare for the lab session
Install the following Ubuntu packages: ros-indigo-kobuki (e.g. sudo apt-get install ros-indigo-kobuki)
Unfortunately for ROS jade those packages are not available. You have to compile those yourself. Run those commands in a terminal:
Download this program and add it to gradebot's robotics homework 1 repository.
Change the program such that the rosnode name will have the following format forward_YOUR_NAME_IN_PINYIN
Change the program such that the string that is being published on the topic "chatter" has the following format Hello, I am <your pingyin name> <current time>
Start a roscore.
Execute the program using: python ./hello.py
Use rostopic echo to display the messages published by the node.
Make a screen shot with the name "hello.png".
Push your program and "hello.png" to the gradebot robotics homework 1 repository.
Grading
The gradebot will check the existence of your checked files. Still the TA and teacher will check every image and the the python files manually if they meet the tasks. The scores could be manually altered (lowered) if the requirements are not met (for example rostopic echo is not showing anything in part 1 or the points are not visible in rviz in part 2). This will happen after the due date.
Getting Help
If you have any questions or problems with this homework please try to get help from the other students first, ask questions on the forum and search the Internet for solutions. A great source for information is for example the ROS answers website.
Additionally Prof. Schwertfeger will be available for answering questions and to help in the Robotics Lab during his office hours.