Awesome
xacro2urdf
Parser(xacro.py) for xacro to urdf based on saulrh/xacro. This xacro.py
can be executed without ROS environment.
My Environment
- windows 8.1
- python3.6 with Anaconda
- Visual Studio Code
How to use
- Run
test_xacro.py
to verify that thexacro.py
is working properly. - Run
python xacro.py
can get some helpful information. - Move
xacro.py
to the same directory asurdf
folder. You can see the file structure in abb_irb4600_support folder for detail. - Run
python xacro.py -o ./target.urdf urdf/origin.xacro
to start convertion. For example,python xacro.py -o ./test_abb_4600.urdf urdf/irb4600_60_205.xacro
in abb_irb4600_support folder. If convert successfully, thetest_abb_4600.urdf
will be generated.
Attention: The xacro.py
must be in same directory as urdf
folder.
What's difference from saulrh/xacro code
Because saulrh/xacro code need python2 environment and works incorrectly in my computer, so I convert the code from python2 to python3 and fix some bugs in file path reading in line 378. You can see the change through the comments.