您当前的位置: 首页 >  ubuntu
  • 0浏览

    0关注

    483博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文

Ubuntu18.04 安装 ros2 foxy

高精度计算机视觉 发布时间:2021-12-12 14:37:59 ,浏览量:0

下面这些笔记有点老了,等我有时间处理一下最新的。。。

先占个坑。

安装 colcon and vcs

sudo apt update && sudo apt install -y  build-essential sudo apt install -y git cmake python3-pip pip3 install -U colcon-common-extensions vcstool

添加环境变量,让终端可以直接执行colcon和vcs

vi ~/.bashrc

添加到末尾

export PATH=$PATH:~/.local/bin/ source ~/.bashrc

Get ros2 foxy repo 下载源码

mkdir -p ~/ros2_foxy/src cd ~/ros2_foxy wget https://raw.githubusercontent.com/ros2/ros2/foxy/ros2.repos vcs import src < ros2.repos Download OGRE

下载rviz依赖

https://github.com/OGRECave/ogre/archive/v1.12.1.zip

unzip to ~/ros2_foxy

On linux you additionally need the following system headers to build the GL & GLES2 RenderSystems (command for Ubuntu):

sudo apt-get install libgles2-mesa-dev furthermore we recommend installing the following optional packages

sudo apt-get install libsdl2-dev libxt-dev libxaw7-dev doxygen Build ros2 安装编译依赖

pip3 install lark numpy

sudo apt-get install python3-pyqt5 pyqt5-dev-tools qttools5-dev-tools

sudo apt-get install python3-sip-dev

编译

cd ~/ros2_foxy/ colcon build --symlink-install 环境激活 . ~/ros2_foxy/install/local_setup.bash 测试 启动 C++ talker:

. ~/ros2_foxy/install/local_setup.bash ros2 run demo_nodes_cpp talker

启动 Python listener:

. ~/ros2_foxy/install/local_setup.bash ros2 run demo_nodes_py listener  

关注
打赏
1661664439
查看更多评论
立即登录/注册

微信扫码登录

0.0481s