cyberbotics / urdf2webots

Utility to convert URDF files to Webots PROTO nodes
Apache License 2.0
127 stars 43 forks source link

Converter prunes URDF branches of sensors #178

Closed astumpf closed 1 year ago

astumpf commented 2 years ago

Unfortunately, I found out about this problem only recently. But latest version of the converter is pruning important (static/fixed) links from the URDF where sensors are attached. In this specific case, the optical frames of cameras are truncated.

Current behavior:

Camera frame is supposed to be the optical link that is truncated by the converter. I suspect that Webot has a fallback to attach them to the root link as seen in the following screenshot.

Screenshot from 2022-06-27 18-02-35

Expected behavior:

Cheated by changing the URDF to set the camera frame to the last non-truncated link.

Screenshot from 2022-06-27 18-01-06

FrederikBark commented 2 years ago

The RemoveDummyLinksAndStaticBaseFlag function doesn't check if a link has sensors, as they haven't been parsed at that point. Additionally a preserveFixedJoint or preserveLink tag would be needed in case some frames are needed in ros applications.

astumpf commented 2 years ago

This issue is currently a major blocker when working with Webots. Any hint or ideas to fix it?

astumpf commented 1 year ago

Solved with #189