ROS Bridge for Trep.

Project Overview

Trep is a rigid-body simulation software developed in the NxR Lab at Northwestern by Elliot Johnson. As I continued to use both Trep and ROS (Robot Operating System) for several projects as a PhD student, it became clear that some utilities would be helpful in bridging the two pieces of software. There were two main tools in particular that would be useful. First, a parser that could create a Trep system from a URDF representation and second, a method to automatically advance the Trep simulation at a given ROS timestep. I put these two tools together which have been incorporated into Trep and also packaged on the ROS buildfarm.

The code for the ROS bridge tools is on Github: https://git.io/rostrep

An example ROS package called is available at: https://github.com/MurpheyLab/trep_urdf_demo

Tool Details

The URDF parser creates a Trep system model using certain tags from the URDF XML specification. The following tags are supported:

  • Link - name
    • Inertial
      • origin
      • mass
      • inertia (only ixx,iyy,izz supported, off-axes should be zero)
  • Joint - name, type: fixed, continuous, prismatic (no joint limits)
    • origin
    • parent
    • child
    • dynamics (damping only)
Additionally, one extra tag is supported on the Joint tag. Specifying kinematic='True' creates a kinematic configuration variable in trep for that joint.

The ROSMidpointVI class extends the MidpointVI class available in trep. This class automatically publishes all frames imported from the URDF to the /tf topic every time ROSMidpointVI.step() is called.

Related Projects.