SocrobOmniSoftware: Difference between revisions

From ISRWiki
Jump to navigation Jump to search
No edit summary
Line 3: Line 3:
== About ==
== About ==


This page presents instructions and ROS drivers to use the SocRob OMNI platform. This platform does not contain any computer on-board, so everything must be connected to a laptop placed in the robot.
This page presents instructions and ROS drivers to use the SocRob OMNI platform. This platform does not contain any computer on-board, so everything must be connected to a laptop placed in the robot.  
 
It is considered that the computer has a ROS Fuerte installation.  


The software contains drivers for:
The software contains drivers for:
* motors -- control motors and recieve odometry
* motors -- control motors and receive odometry
* compass -- compass angle and motor temperatures, since both are connected to the same Arduino
* compass -- compass angle and motor temperatures, since both are connected to the same Arduino
* kicker -- control the kicker and recieve charged voltage
<!--* kicker -- control the kicker and receive charged voltage-->


There is a control hierarchy implemented in control_selector.
There is a control hierarchy implemented in control_selector.
Line 48: Line 46:
<code>
<code>
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", OWNER="socrob"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", OWNER="socrob"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="0042", OWNER="socrob"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="0042", OWNER="socrob"
</code>
</code>
Line 57: Line 56:


Please note:
Please note:
* This software was extensively tested with ROS Fuerte.
* The environment variable MY_ID must be set to the robot number. For example: <code>export MY_ID=2</code>
* The environment variable MY_ID must be set to the robot number. For example: <code>export MY_ID=2</code>
* Ethernet must be configured with the static IP address 172.16.46.80. Camera IP is 172.16.46.8#(robot's number)
* Ethernet must be configured with the static IP address 172.16.46.80. Camera IP is 172.16.46.8#(robot's number)
Line 71: Line 71:
** socrob_display -- Utility to display debug images.
** socrob_display -- Utility to display debug images.


=== Motors Node ===


==== Subscribed Topics ====
== Motors Node ==
 
=== Subscribed Topics ===


* control_input_final -- Final command, fused by control_selector
* control_input_final -- Final command, fused by control_selector
* watchdogs/all_ok -- Final robot status, fused by show_stopper
* watchdogs/all_ok -- Final robot status, fused by show_stopper


==== Published Topics ====
=== Published Topics ===


* odometry -- Odometry
* odometry -- Odometry
* world_info/isRunning -- Button state
* world_info/isRunning -- Button state


=== Compass Node ===
=== Defined in ''src/Libraries/WorldDefinition.hpp'' ===


==== Published Topics ====
* MaximumSpeed -- Maximum speed of the robot
 
 
== Compass Node ==
 
=== Published Topics ===


* compass_angle -- Compass angle in radians
* compass_angle -- Compass angle in radians
* temperature -- Motors temperature for each motor in degrees celsius
* temperature -- Motors temperature for each motor in degrees celsius


=== Kicker Node ===


==== Subscribed Topics ====
<!--
== Kicker Node ==
 
=== Subscribed Topics ===


* world_info/isRunning -- The kicker is only charged if the robot is playing or ready to play
* world_info/isRunning -- The kicker is only charged if the robot is playing or ready to play
* kick -- Kick with intensity from 0 to 100
* kick -- Kick with intensity from 0 to 100
-->
== MJPEG Camera Node ==
=== Published Topics ===
* image_raw -- Image stream from the camera
=== Parameters ===
* filename -- Camera URL or video filename to read (for the OMNI platform cameras use ''http://172.16.46.8#/video.mjpg'')





Revision as of 10:11, 26 September 2013

SocRob OMNI platform

About

This page presents instructions and ROS drivers to use the SocRob OMNI platform. This platform does not contain any computer on-board, so everything must be connected to a laptop placed in the robot.

The software contains drivers for:

  • motors -- control motors and receive odometry
  • compass -- compass angle and motor temperatures, since both are connected to the same Arduino

There is a control hierarchy implemented in control_selector.

There are a few watchdogs implemented to stop the robot in extreme situations:

  • camera_watchdog -- stops the robot if no image is received from the camera
  • temperature_watchdog -- stops the robot is motors temperature becomes too high
  • show_stopper -- fuses the information from watchdogs to determine if the robot must be stopped


Software

SocRob ROS Packages

The source code can be found here: SocRob_OMNI_ROS-1.0.tar.xz. This must be decompressed to a directory in the ROS_PACKAGE_PATH.

System Dependencies

Install system dependencies (Boost, libFTDI and curl) with:

sudo apt-get install libboost-all-dev libftdipp-dev libftdipp1 curl

FTDI Access Permissions

You might be able to use USB devices without this, but in some cases you must explicitly give permissions for your user to access FTDI devices over USB.

Create a Udev file as root with:

sudo nano /etc/udev/rules.d/10-socrob.rules

and fill it with

SUBSYSTEMS=="usb", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", OWNER="socrob"

SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="0042", OWNER="socrob"

replacing socrob with your username.


Usage

Please note:

  • This software was extensively tested with ROS Fuerte.
  • The environment variable MY_ID must be set to the robot number. For example: export MY_ID=2
  • Ethernet must be configured with the static IP address 172.16.46.80. Camera IP is 172.16.46.8#(robot's number)
  • When using a launch file, all of the ROS parameters must be initialized. Check driver.launch for an example.
  • When using roscore without a launch file, the script to set the parameters must be run from inside socrob_ros with: sh config/set_params_real.sh

Packages

  • socrob_ros -- All drivers that still depend on the old MeRMaID libraries and some examples.
  • socrob_aux -- Independent ROS packages:
    • mermaid_defines -- Legacy MeRMaID header with some typedefs and defines.
    • mermaid_xml -- Legacy MeRMaID library to process xml files (new ROS projects should use yaml and rosparam).
    • mjpeg_camera -- Network camera driver.
    • socrob_base -- Base headers for SocRob code and Math template library.
    • socrob_display -- Utility to display debug images.


Motors Node

Subscribed Topics

  • control_input_final -- Final command, fused by control_selector
  • watchdogs/all_ok -- Final robot status, fused by show_stopper

Published Topics

  • odometry -- Odometry
  • world_info/isRunning -- Button state

Defined in src/Libraries/WorldDefinition.hpp

  • MaximumSpeed -- Maximum speed of the robot


Compass Node

Published Topics

  • compass_angle -- Compass angle in radians
  • temperature -- Motors temperature for each motor in degrees celsius



MJPEG Camera Node

Published Topics

  • image_raw -- Image stream from the camera

Parameters


Examples

The driver.launch file will launch the OmniManual teleoperation utility along with a transformed view of the camera image, simulation a forward view with rear view mirror. Pressing h will show the terminal's commands.

The line_points node is an example of how to process and extract information from images.