Skip to content

CentralLabFacilities/rosjava_tf

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

rosjava_tf

This package provides an implementation of TF for rosjava.

Dependencies / Installation

We use jgrapht to represent the tree of TF frames and javax.vecmath for linear algebra. All dependencies are handled via gradle. Just clone this package into your rosjava workspace and run catkin_make.

If you need cross-compile compatability for older java versions have a look at the java6 branch.

Usage

Creating a subscriber

import org.ros.rosjava.tf.Transform;
import org.ros.rosjava.tf.pubsub.TransformListener;

...

TransformListener tfl = new TransformListener(connectedNode);
long now = (long) System.currentTimeMillis() * 1000000; // nanoseconds
String from = "map";
String to = "base_link";

try {
  Transform tx = tfl.getTree().lookupTransformBetween(from, to, now);
  System.out.println(tx);
}
catch (Exception e) {
  System.err.println("Error: "+e.toString());
}

Aknowledgments

Most of this software is based on the previous works of Nick Armstrong Crews' rosjava-tf package. It has been updated to Kinetic and many unfinished and/or broken methods have been fixed.

About

TF implementation for rosjava.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 95.6%
  • CMake 4.4%