Skip to content

SQUIRREL Summer School 2014

Michael Zillich edited this page Jul 24, 2014 · 26 revisions

Program

Please find the program here

Hands-on work

Part of the school will be hands-on team work on the Robotino robot. To this end we have set a system to let the robot clean up, in a very simplified manner. Some parts of this system are left empty as stubs for you to fill in.

Groups

We will have three groups, one for each robot. Each team will have its own clone of the relevant repositories.

Team Red

  • Senka Krivic
  • Jie Sun
  • Vicky Carrissi
  • Joao Freire
  • Abd El-Moniem Bayoumi

Team Green

  • Simon Hangl
  • Ekaterina Potapova
  • Cristina Zaga
  • Stefan Osswald

Team Blue

  • Michael Cashmore
  • Markus Bajones
  • Jaebok Kim
  • Malte Ahl (Peter Regier, Juergen Hess?)

Prerequisites

The SQUIRREL development system is Ubuntu 12.04 with ROS hydro.

Additionally I had to install the following packages for a fresh 12.04 install:

sudo apt-get install libglew1.6-dev libglm-dev libsuitesparse-dev libopenni2-dev

Also please follow the steps here to install PCL (a specific version different from the standard ROS one).

Getting the code

For each team fork these repositories:

squirrel-project/common squirrel-project/planning squirrel-project/object_perception

I suggest the team leader forks the repositories into her/his private github repo, and gives other team members read/write access.

The mission

mission

The Robotino will be placed into a pen with various objects. Some of these objects need to be tidied, while others are okay where they are. To tidy up the pen, the Robotino must first discover the objects, identify them, and then push any untidy objects to the wall.

The goal of the demo is to implement "explore" and "push".

behaviour

Explore is supposed to move Robotino around in search of untidy objects. Push means simply that Robotino moves into the object until it is against the wall.

System

system

  • The Knowledge Base is used to store discovered objects, and whatever information has been discovered about them.
  • For this scenario the planning system will simply dispatch whatever action accords with the described behaviour. These actions are: explore, classify, and push.
  • The Perception Interface is where these actions are received and are implemented. Currently only classify is implemented.

Running the system

The knowledge base, planning system, and action interface can be launched using the launch files:

catkin_ws$ source devel/setup.bash

catkin_ws$ roslaunch planning_system planning_system.launch

catkin_ws$ rosrun pcl_object_segmenter pcl_object_segmenter_service _seg_type:=1

catkin_ws$ rosrun object_classifier object_classifier_node _models_dir:=catkin_ws/models _training_dir:=catkin_ws/training

A visualisation of the current behviour can be ran using:

catkin_ws$ rosrun planning_system squirrelVis

Modifying the code

There are already stubs in c++ for implementing the Explore and Push actions, both in the planning_system package, in the planning repository:

  • planning_system/squirrel/ExploreAction.cpp
  • planning_system/squirrel/PushAction.cpp

Explore action stub:

void PerceptionInterface::executeExplore(const planning_dispatch_msgs::ActionDispatch::ConstPtr& msg) {

  // acknowledgement feedback
  planning_dispatch_msgs::ActionFeedback feedbackEnabled;
  feedbackEnabled.action_id = msg->action_id;
  feedbackEnabled.status = "action enabled";
  feedbackPub.publish(feedbackEnabled);

  // TODO: move around

  // in some places:		
  executeObserve(msg);

  if(actionCancelled[msg->action_id]) {
  	// TODO: explore is cancelled; finish immediately.
  }

  // after about "msg->duration" seconds of exploration:

  // completion feedback
  planning_dispatch_msgs::ActionFeedback feedbackAchieved;
  feedbackAchieved.action_id = msg->action_id;
  feedbackAchieved.status = "action achieved";
  feedbackPub.publish(feedbackAchieved);

}

ROS topics

The robot will be offering these topics

Velocity Commands:

Topic: /cmd_vel, Typ: geometry_msgs/Twist

Odometry:

Topic: /odom Typ: nav_msgs/Odometry

Bumper:

Topic: /bumper Typ: std_msgs/Bool (True oder False)

IR Sensor (9 sensors):

Topic: /distance_sensors Typ: sensor_msgs/PointCloud

Xtion Pro:

Topic: /camera/depth_registered/points Typ: sensor_msgs/PointCloud2

Webcam (if needed)

Topic: /webcam/image_raw Typ: sensor_msgs/Image

The robot

  1. Get access to the dhcp server: Come to me and give me your MAC address of the eth0 device

  2. Put this into your /etc/hosts:

192.168.167.9 robotino 192.168.167.5 robotino2

  1. Connect to one of the switches

  2. There are the following users on the robot:

robotino: team01, team02 robotino2: team3, team4

The team name is also the password.

  1. Starting the robot:
  • Press the start button for 3 seconds
  • Only one user has to launch ROS, preferably this way:
    • log in
    • start a screen
    • sudo start_robot.sh
    • detach the screen
  1. Shutting down:
  • Press the start again for 3 seconds
  1. For programming: Please use the already created catkin workspace (~/catkin_ws) in the team account

  2. To start programs from your own machine, you need to put the following into your bashrc:

export ROS_MASTER_URI=http://:11311 export ROS_IP=