ros2-rust / ros2_rust

Rust bindings for ROS 2
Apache License 2.0
911 stars 125 forks source link

Create better examples #124

Open nnmm opened 2 years ago

nnmm commented 2 years ago

It would be nice to have demo applications that show something resembling useful work. They could showcase multi-threading, launch files, calling a Rust library from C++, and (once they've landed) services.

styczen commented 1 year ago

I would like to work more on this issue. @nnmm could you provide more detailed information?

There are at least 3 repositories on ROS2 Github organization:

It might be a good idea to replicate some of those in Rust and more.

jhdcs commented 1 year ago

While I'm not @nnmm, I would like to add in my two cents, if they would help.

All three should be implemented, eventually, however there are perhaps different priorities for them. While we already have a couple examples, we do not have any real demo applications. Perhaps we could try making a small demo application, and write a tutorial around it?

The danger with this is that the library is still in a bit of flux - major features are still coming out, and the "ergonomics" of the library are still fairly untested. It may be likely that the demos would need to be re-written, which may be less trivial to do than if it was just an additional example or two. However, at the same time, writing the demo application would be a good way of actually testing the features and ergonomics of the library.

I think that this is what the issue is intending to do. If @nnmm agrees, I can rename the issue to something like "Create demo applications", and make a new issue for creating tutorials. Also, anyone that would be working on this issue would be encouraged to create issues with findings about how to make the library easier to use - hopefully some of the spawned issues might be things that other contributors would be able to easily implement!

esteve commented 1 year ago

@jhdcs I agree about adding demos (not just examples), partly because it'll show what rclrs can do, but also to know what's missing and should be added to the roadmap. For example, ROS 1 has traditionally used the Turtlesim package as a way of teaching ROS and to show several of its features. It's a fairly complete demo, with simulation, navigation, teleop, etc.

styczen commented 1 year ago

@esteve @jhdcs For me renaming this issue and creating a new one with examples sounds good. I'll probably try writing demos with Turtlesim. Regarding the demo, probably the best option is to use simulation from Turtlesim package repo and implement teleop, mimic, draw_square. Later use some GUI library to port whole simulation because I have no experience with GUI programming in Rust, that's why I would like to try this after other parts are implemented.