-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
roslibrust ros1 native example node with multiple subscriber and timed publishing #11
Comments
roslibrust mentions having to turn on the ros1 feature to get the ros1 native nodes, looks like this happened automatically:
|
-> The difference is that rostopic hz uses |
This gets me a much smaller
If I don't want to have to know the right paths and build time, is there a way build.rs could search within ROS_PACKAGE_PATH just for the messages/message packages I need (which could be listed in build.rs). This would be the similar to having to list packages in package.xml. Or call |
Fixed with updated version of roslibrust 8a0c98c |
Make a ros node with several subscriber and publishers using the roslibrust ros1 native feature:
https://github.com/Carter12s/roslibrust?tab=readme-ov-file#experimental-support-for-ros1-native
https://github.com/lucasw/ros_one2z/tree/main/ros1_rlr
So far roslibrust has seems to be able to find ros messages from ROS_PACKAGE_PATH better than rosrust (certain messages cause the rosrust build to fail, TBD insert link to issue/comments about that).
But maybe roslibrust build times are much longer (haven't tried rosrust recently) - is that because it is building a lot of messages that go unused? This also may be because I'm calling the message codegen macro, try following the example (https://github.com/Carter12s/roslibrust?tab=readme-ov-file#code-generation-of-ros-messages https://github.com/Carter12s/roslibrust/blob/master/example_package/build.rs). Could also try curating ROS_PACKAGE_PATH just for building this, only provide paths to the messages it needs.
Lots of basic ros features are missing (e.g.
__name
__ns
and topic remap RosLibRust/roslibrust#113), but really if only publishing and subscribing work the rest can be worked around. The namespace features can be implemented in the node (and then put into a library here, and then probably can figure out how to add them upstream after that).Probably need Corrosion and build with cmake to get the nodes to a place where rosrun and roslaunch will work, but perhaps the right cargo command (
--out-dir
?) can place the binaries where needed. But the name and namespacing comes first.Need to learn tokio to have multiple subscribers and timed publishing in the same node. Seems more complicated than it ought to be but I suppose rospy and roscpp went to a lot of effort to hide inherent complexities.
Haven't tried service calls yet- ultimately want dynamic reconfigure working (or 'dynamic dynamic reconfigure', don't bother with implementing .cfg message building) but could live without that for a while. Can implement the dynamic reconfigure interface manually here then maybe push it upstream or into a standalone crate later.
The text was updated successfully, but these errors were encountered: