ros 安装及基础学习
来源:互联网 发布:java开发微信的步骤 编辑:程序博客网 时间:2024/06/05 02:12
安装网址(ubuntu 16.04):
http://wiki.ros.org/kinetic/Installation/Ubuntu安装问题:* Could not resolve 'cn.archive.ubuntu.com' 解决: * sudo gedit /etc/hosts * 末尾添加: 91.189.88.149 archive.ubuntu.com 91.189.88,149 security.ubuntu.com 202.118.1.64 cn.archive.ubuntu.com * /etc/init.d/networking restart* snapd is not configured yet 解决: * 先到 /etc/apt/sources.list更新sources.list,执行sources.list问题的所有命令 * https://www.ubuntuupdates.org/package/core/xenial/main/proposed/snapd * 网页中: apt重新下载安装 即可 * 如果再次安装 ros kinetic出错,那你需要执行以下命令: http://blog.csdn.net/heray1990/article/details/47803541 链接中第19行说要执行:sudo mv /var/lib/dpkg/info/* /var/lib/dpkg/info_old/,但是我发现/var/lib/dpkg/info/是个空文件夹,所以没执行19-21的命令,执行运行安装ros kinetic的命令,完美安装完毕* sources.list问题: 解决: * 更新命令: sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak sudo gedit /etc/apt/sources.list , 然后复制文末souces.lists内容到sources.lists内 sudo apt update * 在文末
ros官方网站:
http://www.ros.org/http://wiki.ros.org/cn
学习博客:
由浅到深理解ROSP: http://www.cnblogs.com/zjiaxing/p/5541733.html
基础学习:
- 运行catkin_make命令一定要在workspace文件夹下;
- 创建完workspace文件夹后,就有必要将此目录添加到ROS_PACKAGE_PATH
- echo “export ROS_PACKAGE_PATH=~/dev/catkin_ws:${ROS_PACKAGE_PATH}” >> ~/.bashrc
- ~/.bashrc
修改CMakeLists:
查看package.xml, 确保它包含一下两条语句:
message_generation
message_runtime
注意,在构建的时候,我们只需要”message_generation”。然而,在运行的时候,我们只需要”message_runtime”。
Do not just add this line to your CMakeLists.txt, modify the existing line
find_package(catkin REQUIRED COMPONENTS roscpp rospy std_msgs message_generation)
catkin_package(
…
CATKIN_DEPENDS message_runtime …
…)add_message_files(
FILES
Num.msg
)add_service_files(
FILES
AddTwoInts.srv
)generate_messages(
DEPENDENCIES
std_msgs
)In your catkin workspace
$ catkin_make
- 运行py文件:
- Don’t forget to make the node executable:
- chmod +x scripts/add_two_ints_client.py
- In your catkin workspace
- cd ~/catkin_ws
- catkin_make
- cd ~/catkin_ws
- . devel/setup.bash
- rosrun package node
- Don’t forget to make the node executable:
sources.list 文件:
# deb cdrom:[Ubuntu 16.04.3 LTS _Xenial Xerus_ - Release amd64 (20170801)]/ xenial main restricted# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to# newer versions of the distribution.deb http://mirrors.aliyun.com/ubuntu/ xenial main restricted# deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial main restricted## Major bug fix updates produced after the final release of the## distribution.deb http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted# deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial-updates main restricted## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu## team. Also, please note that software in universe WILL NOT receive any## review or updates from the Ubuntu security team.deb http://mirrors.aliyun.com/ubuntu/ xenial universe# deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial universedeb http://mirrors.aliyun.com/ubuntu/ xenial-updates universe# deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial-updates universe## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu## team, and may not be under a free licence. Please satisfy yourself as to## your rights to use the software. Also, please note that software in## multiverse WILL NOT receive any review or updates from the Ubuntu## security team.deb http://mirrors.aliyun.com/ubuntu/ xenial multiverse# deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial multiversedeb http://mirrors.aliyun.com/ubuntu/ xenial-updates multiverse# deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial-updates multiverse## N.B. software from this repository may not have been tested as## extensively as that contained in the main release, although it includes## newer versions of some applications which may provide useful features.## Also, please note that software in backports WILL NOT receive any review## or updates from the Ubuntu security team.deb http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse# deb-src http://cn.archive.ubuntu.com/ubuntu/ xenial-backports main restricted universe multiverse## Uncomment the following two lines to add software from Canonical's## 'partner' repository.## This software is not part of Ubuntu, but is offered by Canonical and the## respective vendors as a service to Ubuntu users.# deb http://archive.canonical.com/ubuntu xenial partner# deb-src http://archive.canonical.com/ubuntu xenial partnerdeb http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted# deb-src http://security.ubuntu.com/ubuntu xenial-security main restricteddeb http://mirrors.aliyun.com/ubuntu/ xenial-security universe# deb-src http://security.ubuntu.com/ubuntu xenial-security universedeb http://mirrors.aliyun.com/ubuntu/ xenial-security multiverse# deb-src http://security.ubuntu.com/ubuntu xenial-security multiverse
阅读全文
0 0
- ros 安装及基础学习
- ROS学习--树莓派安装及摄像头
- ROS学习--OSX安装
- ROS学习(一) 安装ROS indigo
- ROS学习小结(一):ROS安装
- ROS wiki安装及配置
- Ubuntu ROS安装及测试
- ROS学习--(一)安装
- 学习1:ROS的安装
- 《ROS精品入门》学习笔记二:ROS基础
- [跟我学ROS]1.ROS系统介绍及安装
- ROS indigo 安装及工作空间创建,ROS卸载
- Ubuntu安装ROS及ROS下的一些package
- ROS学习笔记(二):安装,环境配置及指令简介
- ROS 学习系列 -- 树莓派编译安装完整版本ROS
- ROS学习笔记 -- 树莓派安装完整的ROS
- ROS学习手记 - 1了解并安装ROS+创建ROS_Package
- ROS学习笔记【一】——ROS系统安装
- 使用GreenDao添加数据-查询数据
- LightOJ
- 【二分+最大流】BZOJ1305 [CQOI2009]dance跳舞
- MVP+banner+banner点击事件+webview
- 机器学习-KMeans聚类 K值以及初始类簇中心点的选取
- ros 安装及基础学习
- linux中的防火墙管理之firewall
- Lct
- 访问者模式(Visitor)-----基于JAVA语言
- HDU 3374
- 并发编程volatile关键字分析
- python的数据类型(上)
- python selenium2示例
- 计算机组成原理(一)