Skip to content
Snippets Groups Projects
Commit 13d03b66 authored by Julian Cerruti's avatar Julian Cerruti Committed by GitHub
Browse files

Merge pull request #225 from adamantivm/kinetic-updates

Updates for Kinetic release
parents 389b657e 6274b193
No related branches found
No related tags found
No related merge requests found
......@@ -2,6 +2,11 @@
Changelog
=========
0.3.0 (2016-12-13)
------------------
* Updates for Kinetic release.
* NativeNodeMain for C++ node integration.
0.2.1 (2015-02-25)
------------------
* allow setting of the talker topic name in pubsub tutorial.
......
rosjava is the first pure Java implementation of ROS.
From [ROS.org](http://www.ros.org/wiki/): ROS is an open-source, meta-operating
system for your robot. It provides the services you would expect from an
operating system, including hardware abstraction, low-level device control,
implementation of commonly-used functionality, message-passing between
processes, and package management.
Developed at Google in cooperation with Willow Garage, rosjava enables
integration of Android and ROS compatible robots. This project is under active
development and currently alpha quality software. Please report bugs and feature
requests on the [issues
list](https://github.com/rosjava/rosjava/issues?state=open).
To get started, visit the
[rosjava_core](http://rosjava.github.com/rosjava_core/latest) and
[android_core](http://rosjava.github.com/android_core/latest) pages for
documentation concerning the core libraries and examples. Also visit the roswiki
[rosjava](http://wiki.ros.org/rosjava) and
[android](http://wiki.ros.org/android) pages for more general rosjava-android
information.
Still have questions? Check out the ros-users [discussion
list](https://discourse.ros.org/c/rosjava), post questions to [ROS
Answers](http://answers.ros.org/questions/) with the tag "rosjava," or join #ROS
on irc.oftc.net.
rosjava was announced publicly during the [Cloud Robotics tech talk at Google
I/O 2011](http://www.youtube.com/watch?feature=player_embedded&v=FxXBUp-4800).
Looking for a robot platform to experiment with ROS, Android, and cloud
robotics? The [OSRF](http://www.osrfoundation.org/)
[TurtleBot](http://wiki.ros.org/Robots/TurtleBot) is a great mobile perception
platform for [getting started with robotics
development](http://www.youtube.com/watch?feature=player_embedded&v=MOEjL8JDvd0).
### Branches ###
The master branch reflects the latest version of rosjava. All development
happens on the master branch in the form of pull requests from developers.
Unless you are developing rosjava itself, you should _not_ use the master
branch.
Named branches are created whenever a new version of ROS is released. These
branches are considered stable. No new features will be added to these branches,
however, bug fixes may be cherry picked from master.
### Pull Requests ###
You must sign a Contributor License Agreement (CLA) before we can accept any
code. The CLA protects you and us.
* If you are an individual writing original source code and you're sure you own
the intellectual property, then you'll need to sign an [individual
CLA](https://developers.google.com/open-source/cla/individual).
* If you work for a company that wants to allow you to contribute your work to
SL4A, then you'll need to sign a [corporate
CLA](https://developers.google.com/open-source/cla/corporate).
Follow either of the two links above to access the appropriate CLA and
instructions for how to sign and return it. Damon will respond on either github
or email to confirm.
......@@ -19,7 +19,7 @@ task wrapper(type: Wrapper) {
}
buildscript {
apply from: "https://github.com/rosjava/rosjava_bootstrap/raw/indigo/buildscript.gradle"
apply from: "https://github.com/rosjava/rosjava_bootstrap/raw/kinetic/buildscript.gradle"
}
apply plugin: "catkin"
......@@ -31,16 +31,16 @@ allprojects {
subprojects {
if (name != 'docs') {
/*
/*
* The ros plugin configures a few things:
*
*
* - local deployment repository : where it dumps the jars and packaged artifacts)
* - local maven repositories : where it finds your locally installed/built artifacts)
* - local maven repositories : where it finds your locally installed/built artifacts)
* - external maven repositories : where it goes looking if it can't find dependencies locally
*
*
* To modify, or add repos to the default external maven repositories list, pull request against this code:
*
* https://github.com/rosjava/rosjava_bootstrap/blob/indigo/gradle_plugins/src/main/groovy/org/ros/gradle_plugins/RosPlugin.groovy#L31
*
* https://github.com/rosjava/rosjava_bootstrap/blob/kinetic/gradle_plugins/src/main/groovy/org/ros/gradle_plugins/RosPlugin.groovy#L31
*/
apply plugin: "ros-java"
apply plugin: "osgi"
......
......@@ -28,7 +28,7 @@ you simply need to clone the github repository
git clone https://github.com/rosjava/rosjava_core
cd rosjava_core
git checkout -b indigo origin/indigo
git checkout -b kinetic origin/kinetic
and proceed immediately to the section on :ref:`building`.
......
<?xml version="1.0"?>
<package>
<name>rosjava_core</name>
<version>0.2.1</version>
<version>0.3.0</version>
<description>
An implementation of ROS in pure-Java with Android support.
</description>
......
......@@ -18,11 +18,11 @@ dependencies {
compile project(':apache_xmlrpc_common')
compile project(':apache_xmlrpc_server')
compile project(':apache_xmlrpc_client')
compile 'org.ros.rosjava_bootstrap:message_generation:[0.2,0.3)'
compile 'org.ros.rosjava_messages:rosjava_test_msgs:[0.2,0.3)'
compile 'org.ros.rosjava_bootstrap:message_generation:[0.3,0.4)'
compile 'org.ros.rosjava_messages:rosjava_test_msgs:[0.3,0.4)'
compile 'org.ros.rosjava_messages:rosgraph_msgs:[1.11,1.12)'
compile 'org.ros.rosjava_messages:geometry_msgs:[1.11,1.12)'
compile 'org.ros.rosjava_messages:nav_msgs:[1.11,1.12)'
compile 'org.ros.rosjava_messages:geometry_msgs:[1.12,1.13)'
compile 'org.ros.rosjava_messages:nav_msgs:[1.12,1.13)'
compile 'org.ros.rosjava_messages:tf2_msgs:[0.5,0.6)'
compile 'dnsjava:dnsjava:2.1.1'
compile 'org.apache.commons:com.springsource.org.apache.commons.logging:1.1.1'
......
package org.ros.node;
import org.ros.node.AbstractNodeMain;
import org.ros.node.ConnectedNode;
import org.ros.node.Node;
import org.ros.namespace.GraphName;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import java.util.List;
import java.util.Map;
/**
* A java wrapper to load and run a native-code ROS node.
*
* Note: there are no actual native methods declared in this class. We only define an interface. The native methods should be declared in the child class.
*
* @author ecorbellini@creativa77.com.ar (Ernesto Corbellini)
*/
public abstract class NativeNodeMain extends AbstractNodeMain {
private Log log = LogFactory.getLog(NativeNodeMain.class);
private String libName;
private String masterUri = null;
private String hostName = null;
private String nodeName = null;
private String[] remappingArguments;
private boolean shuttingDown = false;
/**
* @param libName
* The name of the library to load.
*
* @param remappings
* A string array with ROS argument remapping pairs in each element.
**/
public NativeNodeMain(String libName, String[] remappings) {
this.libName = libName;
// if no remapping is needed, create an empty array
if (remappings == null) {
remappingArguments = new String[0];
}
log.info("Trying to load native library '" + libName + "'...");
try
{
System.loadLibrary(libName);
}
catch (SecurityException e)
{
log.info("Error loading library! SecurityException");
}
catch (UnsatisfiedLinkError e)
{
log.info("Error loading library! UnsatisfiedLinkError");
}
catch (NullPointerException e)
{
log.info("Error loading library! NullPointerException");
}
}
/**
* @param libName
* The name of the library to load.
**/
public NativeNodeMain(String libName) {
this(libName, null);
}
// These methods define the execution model interface for this node.
protected abstract void execute(String rosMasterUri, String rosHostName, String rosNodeName, String[] remappingArguments);
protected abstract void shutdown();
@Override
public void onStart(final ConnectedNode connectedNode) {
// retain important ROS info
masterUri = connectedNode.getMasterUri().toString();
hostName = connectedNode.getUri().getHost();
nodeName = this.libName;
// create a new thread to execute the native code.
new Thread() {
@Override
public void run() {
execute(masterUri, hostName, nodeName, remappingArguments);
// node execution has finished so we propagate the shutdown sequence only if we aren't already shutting down for other reasons
if(!shuttingDown) {
connectedNode.shutdown();
}
}
}.start();
}
@Override
public void onShutdown(Node node) {
shuttingDown = true;
shutdown();
}
}
......@@ -20,6 +20,6 @@ mainClassName = 'org.ros.RosRun'
dependencies {
compile project(':rosjava')
compile 'org.ros.rosjava_messages:sensor_msgs:[1.11,1.12)'
compile 'org.ros.rosjava_messages:sensor_msgs:[1.12,1.13)'
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment