Skip to content
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

[Feature] C# API generation from .msg IDL files #114

Open
andrew-otiv opened this issue Jun 6, 2023 · 1 comment
Open

[Feature] C# API generation from .msg IDL files #114

andrew-otiv opened this issue Jun 6, 2023 · 1 comment
Labels

Comments

@andrew-otiv
Copy link

Thanks for the library! I'm not a user yet, just investigating what is available for a new project.

Is there a .msg file -> C# static types code generator already that I just haven't found?

There are no .msg files in the repo, and the test cases seem to be generating their own types from a C# API.

(In a multi-language project, .msg files would be the IDL and source of truth for message layout.)

Thanks in advance!

@hoffmann-stefan
Copy link
Member

Hi @andrew-otiv

The messages get generated by the rosidl_generator_dotnet package, which does this the same way as the message classes for the C++ and Python are generated. See https://github.com/ros2/rosidl. This whole process is deeply integrated into the colcon/ament/cmake build system that ROS uses and somewhat seems like magic ;)

This happens automatically in the ROS workspace when ros2_dotnet and the message packages get built. Just follow the README.md for setting up such a ROS workspace.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants