0
$\begingroup$

Rosanswers logo

Hi, I'm new to both ROS and android. Just one question, can a robot running on roscpp or rospy subscribe to a topic published by an Android rosjava?


Originally posted by sskk89 on ROS Answers with karma: 15 on 2011-09-11

Post score: 0

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

Yes, it will work. The client libraries just implement the ROS communication protocol which is the same for java, c++, python and lisp.


Originally posted by Lorenz with karma: 22731 on 2011-09-11

This answer was ACCEPTED on the original site

Post score: 1


Original comments

Comment by uzair on 2013-11-12:
Can my publisher in rospy and subscriber in rosjava be in two separate packages in the same workspace?I am new to ROS and there are different build commands for rospy like catkin_make and gradlew for rosjava. Can i use the same workspace for building both the scripts by putting them in two seperate packages or should i put them in the same package?

Comment by Daniel Stonier on 2013-11-13:
It doesn't matter where they are. You could have a source workspace for buliding your desktop (python) packages. And a completely separate source workspace where you build your android packages. The only thing in common they need is the message package.

Comment by uzair on 2013-11-14:
but the message packages are different for rospy and rosjava right? we use std_msgs for python and rosjava_messages for rosjava..do i add both of these package dependencies to both the packages between whom i am publishing and subscribing? cant i just use the same topic and message type for the publisher and subscriber?

Comment by Daniel Stonier on 2013-11-14:
Its actually std_msgs + genpy for python and std_msgs + rosjava_bootstrap + java_messages for rosjava. genpy generates the python modules for std_msgs and puts them inside std_msgs. rosjava_bootstrap generates the java artifacts for std_msgs and puts them inside rosjava_messages.

Comment by Daniel Stonier on 2013-11-14:
We'd like a genjava eventually, not too far off that target now.

Comment by uzair on 2013-11-14:
So if i put my publisher(rospy) in catkin_ws/src1 and my subscriber(rosjava) in catkin_ws/src2, how do i build them separately then? catkin_ws/src1 needs catkin_make whereas catkin_ws/src2 needs gradle. I really appreciate all the help.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.