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

Importing custom urdf file #475

Open
YunSang123 opened this issue Jan 5, 2025 · 4 comments
Open

Importing custom urdf file #475

YunSang123 opened this issue Jan 5, 2025 · 4 comments

Comments

@YunSang123
Copy link

Hi, I am a beginner to Genesis. In my knowledge, there isn't any tutorial page for a beginner for me to import custom urdf file.

How can I import my custom urdf file?

Also, I want to import my .urdf.xacro file. Is it currently impossible to load any urdf.xacro file?

Thanks!

@zhouxian
Copy link
Collaborator

zhouxian commented Jan 5, 2025 via email

@YunSang123
Copy link
Author

Oh, I forgot the stl file. Thanks!

Also, I was wondering whether genesis can import .urdf.xacro file.

@zhouxian
Copy link
Collaborator

zhouxian commented Jan 6, 2025

I don’t think so. Not yet

could you briefly describe how is it different than regular urdf?

@oscar-lima
Copy link

From http://wiki.ros.org/xacro and https://github.com/ros/xacro:

"Xacro is an XML macro language. With xacro, you can construct shorter and more readable XML files by using macros that expand to larger XML expressions."

So you can create "functions" (called macros) and "variables" (called properties), include other xacro files and resolve absolute xacro paths from ROS packages using functions such as "find package" among others.

One caveat is that xacro relies heavily on ROS. An alternative would be to borrow xacro_standalone.py from pybullet.

NOTE: ROS users can generate (more like compile...) URDF from xacro easily (with one command) and save the result locally. This can be then loaded into genesis. However is annoying to generate the file over and over again if you make changes or for users than don't (or don't want to) have ROS installed.

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

No branches or pull requests

3 participants