上一节玩了 exbot 在RViz里的仿真控制,这里我们用urdf文件写个自己的小车模型,ref: http://blog.csdn.net/hcx25909/article/details/8904292

(待修正)

1.  创建一个package: smartcar_description

创建一个package: smartcar_description  urdf  ,依赖:urdf

$ catkin_create_pkg smartcar_description urdf

2. SmartCar 尺寸数据

因为建立的是一个非常简单的机器人,所以我们尽量使用简单的元素:使用长方体代替车模,使用圆柱代替车轮,具体尺寸如下:

3. 创建智能车的描述文件smartcar.urdf

在smartcar_description文件夹下建立urdf文件夹,创建智能车的描述文件smartcar.urdf,描述代码如下:

4. 创建launch文件

    <launch>
<arg name="model" />
<arg name="gui" default="False" />
<param name="robot_description" textfile="$(find smartcar_description)/urdf/smartcar.urdf" />
<param name="use_gui" value="$(arg gui)"/>
<node name="joint_state_publisher" pkg="joint_state_publisher" type="joint_state_publisher" ></node>
<node name="robot_state_publisher" pkg="robot_state_publisher" type="state_publisher" />
<node name="rviz" pkg="rviz" type="rviz" args="-d $(find urdf_tutorial)/urdf.rviz" />
</launch>

5. 效果演示

在Terminal中输入演示命令:

   $ roslaunch  smartcar_description  base.urdf.rviz.launch  gui:=true  

这里我们遇到了一个错误,

 

我想原因是来源网页作者使用了Groovy版本的ROS(相对本系列使用的Hydro要老),所以我的计划是先完成urdf的学习再来进行此例程:http://wiki.ros.org/urdf

在完成urdf之前,关于ros_tf的学习应该是基础,所以接下来先进行ros tf(transform)的学习。

在学习tf过程中,发现运行多个节点需要用到launch文件,所以launch文件的学习应该是最前的。

launch file >> tf >> urdf

ROS进阶学习手记 7.2 -- RViz仿真实例2:Create SmartCar的更多相关文章

  1. ROS进阶学习手记 7 -- RViz仿真实例1

    [任务2]:     用simulator: RViz 工具,完成对小车的建模,名字drive RViz = dvrv, 用 dvrv_node 发布topic和数据格式,向它发送位置指令,使它能接受 ...

  2. ROS进阶学习笔记(11)- Turtlebot Navigation and SLAM - ROSMapModify - ROS地图修改

    ROS进阶学习笔记(11)- Turtlebot Navigation and SLAM - 2 - MapModify地图修改 We can use gmapping model to genera ...

  3. ROS进阶学习笔记(11)- Turtlebot Navigation and SLAM

    (写在前面: 这里参考rbx书中第八章和ROS社区教程进行学习,先看社区教程) ===  Doing the Turtlebot Navigation   === ref ros wiki: http ...

  4. ROS 进阶学习笔记(13) - Combine Subscriber and Publisher in Python, ROS

    Combine Subscriber and Publisher in Python, ROS This article will describe an example of Combining S ...

  5. ROS进阶学习笔记(10)- 搭建自己的Turtlebot(5) - Interactive Makers

    用interactive_makers控制Turtlebot移动 interactive_makers 是Willow Garage公司开发的一个虚拟控制工具,可通过鼠标在虚拟环境中的操作,完成实际机 ...

  6. ROS 进阶学习笔记(12) - Communication with ROS through USART Serial Port

    Communication with ROS through USART Serial Port We always need to communicate with ROS through seri ...

  7. Learning ROS forRobotics Programming Second Edition学习笔记(八)indigo rviz gazebo

    中文译著已经出版,详情请参考:http://blog.csdn.net/ZhangRelay/article/category/6506865 Learning ROS forRobotics Pro ...

  8. ROS学习手记 - 2.1: Create and Build ROS Package 生成包(Python)

    ROS学习手记 - 2.1: Create and Build ROS Package 生成包(Python) 时隔1年,再回来总结这个问题,因为它是ros+python开发中,太常用的一个操作,需要 ...

  9. ROS入门学习

    ROS学习笔记 ROS入门网站; ROS入门书籍 ROS主要包含包括功能包.节点.话题.消息类型和服务; ROS功能包/软件包(Packages) ROS软件包是一组用于实现特定功能的相关文件的集合, ...

随机推荐

  1. Delphi中使用ADO连接Excel

    第一部分: . 设置ADOConnection的ConnectionString属性的OLE DB的提供者要选择Microsoft Jet 4.0 OLE DB Provider(这本来是用于连接Ac ...

  2. spring IOC中四种依赖注入方式

    在spring ioc中有三种依赖注入,分别是:https://blog.csdn.net/u010800201/article/details/72674420 a.接口注入:b.setter方法注 ...

  3. List<T>Distinct 过滤

    public class TestDuplicateDefine : IEqualityComparer<student> { public bool Equals(student x, ...

  4. LaTex与数学公式

    w(t) \longrightarrow \bigg[\frac{\sqrt{2\sigma ^2\beta}}{s+\beta}\bigg]  \longrightarrow \bigg[\frac ...

  5. 解除IE锁定主页批处理

    解除IE锁定主页.bat rem 解除IE锁定主页@echo offecho HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main [ ...

  6. WhereHows前后端配置文件

    前端: # This is the main configuration file for the application. # ~~~~~ # Secret key # ~~~~~ # The se ...

  7. bzoj4939: [Ynoi2016]掉进兔子洞

    将权值排序,设权值x排序后在[l,r]出现,x在区间中出现k次,则用[l,l+k-1]为1,[l+k,r]为0来表示x的出现次数 用bitset表示可重集中每个元素的出现次数,用莫队处理出询问区间对应 ...

  8. SQL优化系列——索引

    索引可能是数据库中最被误解的主题,因为有很多方式让你糊涂索引如何工作,以及服务器如何使用它们.要正确设计索引,让索引在数据库服务器中满足以下三个重要目的:1,索引使服务器查找一组相邻行,而不是单独的行 ...

  9. 力奋github:https://github.com/birdstudiocn

    我的github地址https://github.com/birdstudiocn

  10. mysql查询优化之三:查询优化器提示(hint)

    目录: <MySQL中的两种临时表>--强制使用临时表 SQL_BUFFER_RESULT <MySQL 多表关联更新及删除> <mysql查询优化之三:查询优化器提示( ...