On 15 August 2011 18:07, Ken Conley wrote: > On Mon, Aug 15, 2011 at 10:00 AM, Mark Rowan wrote: >> Ok, I've got ant working (thanks to the supplied build.xml on the >> rosjava wiki page you linked to, although there was a small error in >> the XML file which I've corrected on the wiki) but I can't seem to >> find any way to run the compiled classes using rosrun. Is this >> possible, or do we have to manually execute nodes using java >> -classpath package.class ? > > This is still be tweaked and documentation hasn't been written yet, > but you can use: > > " > rosrun rosjava_bootstrap run.py  [args ... ] > " Thanks for this info. I assume relates to the ROS package, not the Java package? > That script generally assumes that you are using the tags to > setup your path.  These tags are currently being finalized > and you'd have to look at rosjava_core packages for examples. My path is currently set manually in .bashrc -- is this a suitable alternative, or are the tags specifically required? > But, the script basically constructs the path from the export tags and runs: > > java -classpath org.ros.RosRun [args...] > > So that should be fairly similar to what you are used to. Thanks. I'm clearly doing something wrong, as run.py responds that it is 'Unable to locate node'. I have a ROS package directory, initialised with rospkg-create, and containing 'src' and 'build' directories. The 'src' contains a further Java package directory Running 'ant compile' takes my source and compiles it into the build directory, at myPackage/MyClass.class . Running 'rosrun rosjava_bootstrap run.py myPackage.MyClass' builds successfully from dependencies.xml (although it declares an error, "Could not load definitions from resource net/sf/antcontrib/antlib.xml. It could not be found." -- is this important?) but after the execution stage begins, the script returns "Unable to locate node myPackage.MyClass". The huge auto-generated classpath does not include the /build/ directory, which seems relevant. Thanks again, and sorry for the many questions! Mark -- Mark Rowan  |  http://www.tamias.co.uk