ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

psoetens's profile - activity

2017-04-20 16:36:27 -0500 received badge  Famous Question (source)
2014-12-14 23:15:32 -0500 received badge  Popular Question (source)
2014-12-14 23:15:32 -0500 received badge  Notable Question (source)
2014-08-22 02:45:06 -0500 received badge  Necromancer (source)
2014-06-19 15:56:55 -0500 received badge  Supporter (source)
2014-02-25 09:04:30 -0500 answered a question How to get rosjava generate classes instead of interfaces ?

The post above was confused by http://answers.ros.org/question/10276... which probably refers to an older version where this was possible.

The getting started guide of rosjava here: http://docs.rosjava.googlecode.com/hg...

explains how to instantiate messages using a factory. All messages are interfaces on purpose.

2014-02-25 08:38:39 -0500 asked a question How to get rosjava generate classes instead of interfaces ?

Hi,

I followed the rosjava tutorials for 'unofficial messages' for Hydro. It all works, but I get an interface .java file instead of a class. For example:

scip_api/msgs/Alarm.msg:

string alarm_name
string data_name

scip_api/build/generated-src/scip_api/Alarm.java:

package scip_api;

public interface Alarm extends org.ros.internal.message.Message {
  static final java.lang.String _TYPE = "scip_api/Alarm";
  static final java.lang.String _DEFINITION = "string alarm_name\nstring data_name";
  java.lang.String getAlarmName();
  void setAlarmName(java.lang.String value);
  java.lang.String getDataName();
  void setDataName(java.lang.String value);
}

While for the std_msgs types, the generated .java file is a class (at least for String.msg it is)

What did I do wrong ? I used the released ros-hydro-rosjava packages for Ubuntu 12.04

2012-04-18 15:59:23 -0500 received badge  Editor (source)
2012-04-18 15:58:39 -0500 answered a question Using the orocos/rtt rosparam service in c++

What you need to do for this particular service is to first load the service:

// In your TaskContext subclass:
PluginLoader::Instance()->loadService("rosparam", this);

And then you could dynamic_cast the service pointer:

boost::shared_ptr<RosParam> rp = boost::dynamic_pointer_cast<RosParam>( this->provides("rosparam") );

rp->storeProperties(); // etc.

UNFORTUNATELY, this service was implemented fully in the .cpp file, so no header is available. What you can do, if you don't want to submit a patch which creates a nice hpp/cpp file and installs the hpp, you can write this as a workaround:

OperationCaller<bool(void)> storeProperties = this->provides("rosparam")->getOperation("storeProperties");

storeProperties(); // calls the Service's Operation.

Peter

2012-02-18 09:43:28 -0500 answered a question Asus Xtion Pro Live poor framerate

I'm not having this issue but I did download and compile the latest OpenNI and PrimeSense Sensor sources, stable branches : http://www.openni.org/Downloads.aspx (you need to git clone them).

You'll have to install OpenNI (first) and the Sensor (second) packages on top of your openni-dev Debian package (effectively overwriting the files of the Debian package). You can do this by following the build and installation instructions in the README files in the top directories of both packages.

If it doesn't work, you can revert all by calling the ./install.sh script with the -u option for both packages and then to do

sudo aptitude reinstall openni-dev

So it's quite safe to try this out.

2011-11-08 08:26:12 -0500 received badge  Teacher (source)
2011-11-08 07:00:44 -0500 answered a question How to handle OS Dependant manifest.xml ?

Orocos has a special mechanism such that you don't have to put any <export> statement in the manifest.xml file, but can use a generated pkg-config file instead.

In your CMakeLists.txt file:

orocos_library( arp_core apr_core.cpp )
orocos_generate_package() # last line in your CMakeLists.txt file

it will generate a .pc file alongside your manifest.xml file with the correct -L and -l flags.

This .pc file will be automatically used by depending on the arp_core package, as usual in another manifest.xml file:

<depend package="arp_core" />

For the documentation of CMake macros, see the Orocos Toolchain CMake wiki