Trouble with crazyflie2 hovering example. [Ubuntu 18.04, ROS Melodic, Gazebo 9]
umidah opened this issue · 22 comments
Good day, I installed CrazyS for ubuntu 18.04, ROS melodic and Gazebo9. When running the crazyflie2 hovering example, I could not get it to run.
I used the example command given in the readme:
roslaunch rotors_gazebo crazyflie2_hovering_example.launch
This was the error displayed for me.
... logging to /home/ajtpa/.ros/log/cdbdd2ee-835f-11ec-989a-e0d55ea1eb65/roslaunch-otonokizaka-11207.log
Checking log directory for disk usage. This may take a while.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.
xacro: in-order processing became default in ROS Melodic. You can drop the option.
name 'namespace' is not defined
when evaluating expression 'namespace'
when processing file: /home/ajtpa/catkin_ws/src/CrazyS/rotors_description/urdf/component_snippets.xacro
included from: /home/ajtpa/catkin_ws/src/CrazyS/rotors_description/urdf/crazyflie2_base.xacro
included from: /home/ajtpa/catkin_ws/src/CrazyS/rotors_description/urdf/mav_generic_odometry_sensor.gazebo
RLException: while processing /home/ajtpa/catkin_ws/src/CrazyS/rotors_gazebo/launch/spawn_mav_crazyflie.launch:
Invalid <param> tag: Cannot load command parameter [robot_description]: command [['/opt/ros/melodic/lib/xacro/xacro', '--inorder', '/home/ajtpa/catkin_ws/src/CrazyS/rotors_description/urdf/mav_generic_odometry_sensor.gazebo', 'enable_logging:=false',
If any more information is needed, I would gladly provide it.
EDIT: This was done in a fresh install of Ubuntu 18.04
Thanks for opening your first issue here! Make sure that no other issues on the same topic have already been opened!
Hello, I got the same issue that returns the same error message. I followed the instruction in the README.md for Ubuntu 18.04.
It seems that the problem lies in some hold definitions contained in the spawn_mav_crazyflie.launch
. Open the file, and add the --inorder
option as described in here https://answers.ros.org/question/354092/xacro-in-order-processing-for-husky_gazebo/. I hope this helps.
After trying to run the following command roslaunch husky_gazebo husky_playpen.launch from this tutorial: http://wiki.ros.org/husky_navigation/... I encounter the following error: ... logging to /home/daniel/.ros/log/2e76d420-a6c4-11ea-afba-2390d77f85eb/roslaunch-daniel-Inspiron-7559-14421.log Checking log directory for disk usage. This may take a while. Press Ctrl-C to interrupt Done checking log file disk usage. Usage is <1GB. xacro: in-order processing became default in ROS Melodic. You can drop the option. 'bool' object has no attribute 'lower' when evaluating expression 'topbar_needed_kinect.lower() == 'true' or topbar_needed_kinect == '1' or topbar_needed_realsense == 'true' or topbar_needed_realsense == '1'' when processing file: /home/daniel/husky_ws/src/husky_description/urdf/husky.urdf.xacro RLException: while processing /home/daniel/husky_ws/src/husky_gazebo/launch/spawn_husky.launch: while processing /home/daniel/husky_ws/src/husky_control/launch/control.launch: while processing /home/daniel/husky_ws/src/husky_description/launch/description.launch: Invalid tag: Cannot load command parameter [robot_description]: command [['/opt/ros/noetic/lib/xacro/xacro', '/home/daniel/husky_ws/src/husky_description/urdf/husky.urdf.xacro', '--inorder', 'robot_namespace:=/', 'laser_enabled:=true', 'kinect_enabled:=false', 'realsense_enabled:=false', 'urdf_extras:=']] returned with code [2]. Param xml is The traceback for the exception was written to the log file
Thanks for the reply, I'll check it out. If it does not work, I might try re-installing with ubuntu 20.04 and ROS noetic.
Looking at your screens, especially the second, it seems there is a problem with the namespace. Could you try to run any other launch file in the repository? I would like to understand if this problem affects only the file you mentioned or all the scripts have suffer of the same issue. Thanks!
Have you checked if the repository source is working correctly? I mean, run the following commands roscd rotors_control
and roscd rotors_gazebo
.
Ok, so everything seems to be right with the ROS environment. Have you tried to run the Crazyflie example without the controller?
Ok! Let me test it on my PC. I wil give you back in a short time.
Good day sir, are there updates to a fix to this issue? Thanks!
I tried installing it with Ubuntu 20.04 and it works with no issues, I guess there's a problem within Ubuntu 18.04. Thanks for your time.
Ok great! Did you compare the launch files? I'm curious if the problem lies there, or is it just a problem with ROS. However, this incompatibility problem is new to me.
Unfortunately no as I have already deleted my Ubuntu 18.04 to install the new version.
Ah, okay. Finally you managed to make it works, and this what really matters ;-) Enjoy!
Hello, I am facing the same issue on my 20.04 system. I correctly installed as per the instructions for Ubuntu 20.04.
I tried changing the "<param name="robot_description"......" in the "spawn_mav.launch" file including/ommiting '--inorder' or 'xacro' or 'xacro.py' as suggested in ( https://answers.ros.org/question/122021/xacro-problem-invalid-param-tag-cannot-load-command-parameter-robot_description/ ), without any success.
What's surprising is that I had no trouble working with RotorS installation from 'eth-asl' when I last used it 2 months back. Now, both the installations (earlier RotorS from eth-asl and CrazyS) give the same errors. Don't know if some update has caused this.
Thank you in advance for any help!
Just like the topic I posed, when I try to use roslaunch command to run in the terminal, I met this problem (as followed): Invalid tag: Cannot load command parameter [robot_description]: command [/opt/ros/groovy/stacks/xacro/xacro.py '/home/viki/ros_workspace/smartcar_description/urdf/smartcar.urdf.xacro'] returned with code [1]. Param xml is I have no idea how to solve this problem, I sincerely you could give the instructions about how to solve this problem. Thanks so much for your time. when I run the code rosrun xacro xacro.py /home/viki/ros_workspace/smartcar_description/urdf/smartcar.urdf.xacro to check the xacro, there is the information showed as followed: Expat parsing error. Check that: - Your XML is correctly formed - You have the xacro xmlns declaration: xmlns:xacro="http://www.ros.org/wiki/xacro" Traceback (most recent call last): File "/opt/ros/groovy/stacks/xacro/xacro.py", line 35, in xacro.main() File "/opt/ros/groovy/stacks/xacro/src/xacro.py", line 542, in main doc = parse(f) File "/usr/lib/python2.7/xml/dom/minidom.py", line 1920, in parse return expatbuilder.parse(file) File "/usr/lib/python2.7/xml/dom/expatbuilder.py", line 928, in parse result = builder.parseFile(file) File "/usr/lib/python2.7/xml/dom/expatbuilder.py", line 207, in parseFile parser.Parse(buffer, 0) xml.parsers.expat.ExpatError: junk after document element: line 197, column 0 Can you give me some information about how to solve the problem? Thanks so much!
I managed to solve the issue. Well, like I said it was indeed due to version updates. I removed xacro
and xacro-1.14.11.egg-info
directories from /opt/ros/noetic/lib/python3/dist-packages
folder using sudo rm -r ...
command and installed the 1.13.3 version of xacro using pip3 install xacro==1.13.3
. This simple downgrading from 1.14.11 to 1.13.3 worked for me, without any changes in launch files.
Great! Thanks for letting the community know about this. I'll add these instructions to the README.md file in case someone else experiences the problem.
Thanks a lot @anavsalkar. You saved me from a headache. Your solution worked.