当前位置:网站首页>[ROS] The difference between roscd and cd
[ROS] The difference between roscd and cd
2022-08-02 14:18:00 【CynalFly】

Linux: Ubuntu 18.04 (Bionic)
ROS: ROS Melodic Morenia
1. The difference between roscd and cd
cd, change directory, change directory.Both roscd and cd commands are used to switch to the specified directory.The differences between them are:
cdis the command for UNIX/Linux systems;roscdis a command of the ROS system and is part of therosbashcommand set;roscdcan only switch to those paths already included in>ROS_PACKAGE_PATHpackage in the environment variable.
2. Example
assumes you have created a catkin workspace and a catkin package named beginner_tutorials.
cd ~/catkin_ws/src/beginner_tutorials/roscd beginner_tutorialsBy comparison, roscd is faster to enter commands than cd.
3. Notes
If roscd prompts something like roscd: No such package/stack 'beginner_tutorials', you need to create catkin workspaceThe following steps make the environment variables take effect:
cd ~/catkin_wssource devel/setup.bashroscd beginner_tutorials But every time you compile catkin_make, you must use source devel/setup.bash to refresh the environment, otherwise the above problem will occur.How to solve this problem?It's actually very simple, just add the source ~/catkin_ws/devel/setup.bash command to the .bashrc script file, and let the system automatically refresh the workspace.
echo “source ~/catkin_ws/devel/setup.bash” >> ~/.bashrc We can open the bashrc file with the following command, the source ~/catkin_ws/devel/setup.bash command is in the last line of the script.
gedit ~/.bashrc4. References
[1] ROS.org. ROS Tutorial [EB/OL]. [2022-6-29]. http://wiki.ros.org/en/ROS/Tutorials
边栏推荐
猜你喜欢

如何解决mysql服务无法启动1069

第八单元 中间件

uview 2.x版本 tabbar在uniapp小程序里头点击两次才能选中图标

如何选择正规的期货交易平台开户?

深度学习框架pytorch快速开发与实战chapter4

Raft协议图解,缺陷以及优化

The world's largest Apache open source foundation is how it works?

MobileNet ShuffleNet & yolov5替换backbone

Sentinel源码(四)(滑动窗口流量统计)

Data Organization---Chapter 6 Diagram---Graph Traversal---Multiple Choice Questions
随机推荐
政策利空对行情没有长期影响,牛市仍将继续 2021-05-19
瑞吉外卖笔记——第10讲Swagger
idea社区版下载安装教程_安装天然气管道的流程
Flask框架
The bad policy has no long-term impact on the market, and the bull market will continue 2021-05-19
paddle window10环境下使用conda安装
VMM是什么?_兮是什么意思
ftp常用命令详解_iftop命令详解
Object detection scene SSD-Mobilenetv1-FPN
瑞吉外卖笔记——第08讲读写分离
2022-08-02日报:2022年7月最热的10篇AI论文
一维卷积神经网络_卷积神经网络的基础知识「建议收藏」
第十四单元 视图集及路由
【ROS】编译软件包packages遇到进度缓慢或卡死,使用swap
网页设计(新手入门)[通俗易懂]
yolov5改进(一) 添加注意力集中机制
[ROS](01)创建ROS工作空间
WeChat Mini Program-Recent Dynamic Scrolling Implementation
drf序列化器-Serializer
MySQL数据库语法格式