赞
踩
环境:
vm17
ubuntu20
参考文章:
【XTDrone Ubuntu20.04】XTDrone+ Ubuntu20.04 + PX4安装-CSDN博客
仿真平台基础配置(对应PX4 1.13版) (yuque.com)
https://blog.csdn.net/weixin_45291614/article/details/133657158
Ubuntu20.04安装ros noetic最简单教程。(换源下载只需2分钟+安装解压3min)-CSDN博客
正文:
1、依赖
sudo apt install ninja-build exiftool ninja-build protobuf-compiler libeigen3-dev genromfs xmlstarlet libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev python3-pip gawk
pip2 install pandas jinja2 pyserial cerberus pyulog==0.7.0 numpy toml pyquaternion empy pyyaml
这里本人没有pip2 直接pip 即
pip install pandas jinja2 pyserial cerberus pyulog==0.7.0 numpy toml pyquaternion empy pyyaml
pip3 install packaging numpy empy toml pyyaml jinja2 pyargparse kconfiglib jsonschema future
2、ros安装
Ubuntu20.04安装ros noetic最简单教程。(换源下载只需2分钟+安装解压3min)-CSDN博客
参考这个就可以了 无脑装
完成ros安装之后 进行
mkdir -p ~/catkin_ws/src
mkdir -p ~/catkin_ws/scripts
cd catkin_ws && catkin init # 使用catkin_make话,则为cd catkin_ws/src && catkin_init_workspace
catkin build # 使用catkin_make话,则为 cd .. && catkin_make--build之前需要进行一下操作
sudo apt install python3-catkin-tools
还有一个什么pip 需要安装的 忘了 基本上是 缺什么依赖补什么 即
pip install xxx
3、gazebo
需要把gazebo11卸载,再装gazebo9
sudo apt-get remove gazebo*
sudo apt-get remove libgazebo*
sudo apt-get remove ros-noetic-gazebo*
--卸载ga11a、添加软件仓库
sudo sh -c 'echo "deb http://packages.osrfoundation.org/gazebo/ubuntu-stable `lsb_release -cs` main" > /etc/apt/sources.list.d/gazebo-stable.list'b、获取密钥
wget https://packages.osrfoundation.org/gazebo.key -O - | sudo apt-key add -c、更新软件原
sudo apt-get updated、安装
sudo apt-get install gazebo9
sudo apt-get install libgazebo9-dev #一定要记得这个e、检查
gazebo #应该要能打开gazebof、升级
sudo apt-get upgrade
还没结束
接下来的依赖
sudo apt-get install ros-noetic-moveit-msgs ros-noetic-object-recognition-msgs ros-noetic-octomap-msgs ros-noetic-camera-info-manager ros-noetic-control-toolbox ros-noetic-polled-camera ros-noetic-controller-manager ros-noetic-transmission-interface ros-noetic-joint-limits-interface
cd ~/catkin_ws/src
git clone https://github.com/ros-simulation/gazebo_ros_pkgs.git
cd ~/catkin_ws
catkin build--这里会报错 错的问题是
AttributeError: module 'em' has no attribute 'RAW_OPT'
pip3 install --user empy==3.3.4 解决办法
判断是否安装成果
roscore
--另开终端
source ~/catkin_ws/devel/setup.bash
rosrun gazebo_ros gazebo
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。