Ask Your Question
0

urdf to sdf conversion error

asked 2020-04-24 16:04:46 -0500

jean01 gravatar image

updated 2020-04-24 16:40:33 -0500

Hello,

I wanted to add a bumper contact sensor in hector quadrotor demo on theconstructsim. I changed the xacro file, converted to urdf and in the end I need to convert urdf to sdf with the following command

gz sdf -p /quadrotor_base.urdf > /quadrotor_base.sdf

but it is giving me the error

bash: /quadrotor_base.sdf: Permission denied

why can this be? How can I solve this?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2020-04-25 07:08:39 -0500

gvdhoorn gravatar image

I need to convert urdf to sdf with the following command

gz sdf -p /quadrotor_base.urdf > /quadrotor_base.sdf

but it is giving me the error

bash: /quadrotor_base.sdf: Permission denied

why can this be?

Most likely because the paths you specify point to files in the root directory, which is a directory a normal user cannot write to.

How can I solve this?

Specify paths (at least for the output) where you do have write permissions.

Did you perhaps forget to add a dot (ie: .)? So /quadrotor_base.urdf would become ./quadrotor_base.urdf, which would mean: the quadrotor_base.urdf in the current directory.

edit flag offensive delete link more

Comments

Note that this is not something specific to ROS or Gazebo, but a general Linux problem.

gvdhoorn gravatar image gvdhoorn  ( 2020-04-25 07:09:04 -0500 )edit

thank you. I will notify if I confirm the answer is working.

jean01 gravatar image jean01  ( 2020-04-25 11:48:22 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2020-04-24 16:04:46 -0500

Seen: 21 times

Last updated: Apr 25