Gazebo-Ros搭建小车和场景并运行slam算法进行建图4--为机器人添加运动控制器控制其移动

这篇具有很好参考价值的文章主要介绍了Gazebo-Ros搭建小车和场景并运行slam算法进行建图4--为机器人添加运动控制器控制其移动。希望对大家有所帮助。如果存在错误或未考虑完全的地方,请大家不吝赐教,您也可以点击"举报违法"按钮提交疑问。

Gazebo-Ros搭建小车和场景并运行slam算法进行建图4–为机器人添加运动控制器控制其移动

1.要想机器人小车在gazebo中运动还需要为其添加运动插件

在文章3中的my_robot2.urdf 最下边(前边)添加如下部分:

​ 这里使用的二轮差速控制,选择对应的插件libgazebo_ros_diff_drive.so

<gazebo>
  <plugin name="differential_drive_controller" filename="libgazebo_ros_diff_drive.so">
    <rosDebuglevel>Debug</rosDebuglevel>
    <publishWheelTF>false</publishWheelTF>
    <publishTF>1</publishTF>
    <publishWheelJointState>false</publishWheelJointState>
    <updateRate>100.0</updateRate>
    <leftJoint>left_wheel_joint</leftJoint>
    <rightJoint>right_wheel_joint</rightJoint>
    <wheelSeparation>0.4</wheelSeparation>
    <wheelDiameter>0.12</wheelDiameter>
    <wheelAcceleration>1.8</wheelAcceleration>
    <commandTopic>cmd_vel</commandTopic>
    <odometryTopic>odom</odometryTopic>
    <robotBaseFrame>base_footprint</robotBaseFrame>
    <odometryFrame>odom</odometryFrame>
    <broadcastTF>1</broadcastTF>
  </plugin>
</gazebo>

  <gazebo>
    <plugin name="gazebo_ros_control" filename="libgazebo_ros_control.so">
      <robotNamespace>/my_robot</robotNamespace>
    </plugin>
  </gazebo>
其中
<wheelSeparation>0.4</wheelSeparation> 这个是轮距
<wheelDiameter>0.12</wheelDiameter> 这个是轮子直径,根据机器人模型的实际参数设置

添加上述部分,文章3中的my_robot2.urdf 更新为 --完整代码如下:

<?xml version="1.0" ?>
<robot name="my_robot">

    <link name="base_link">
        <collision>
	    <origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0" />
            <geometry>
                <cylinder length="0.16" radius="0.20" />
            </geometry>        
        </collision>

        <visual>
	    <origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0" />
            <geometry>
                <cylinder length="0.16" radius="0.20" />
            </geometry>
	    <material name="orange">
                <color rgba="1 0.4 0 1"/>
            </material>
        </visual>

	<inertial>
            <origin xyz="0 0 0" rpy="0 0 0"/>
            <mass value="6" />
            <inertia ixx="1" ixy="0" ixz="0" iyy="1" iyz="0" izz="1" />
        </inertial>
    </link>

    <gazebo reference="base_link">
   	<material>Gazebo/Orange</material>
    </gazebo>

    <joint name="left_wheel_joint" type="continuous">
        <origin xyz="0 0.19 -0.05" rpy="0 0 0"/>
        <parent link="base_link"/>
        <child link="left_wheel_link"/>
        <axis xyz="0 1 0"/>
    </joint>

    <link name="left_wheel_link">
	<collision>
	    <origin xyz="0 0 0" rpy="1.5707 0 0" />
            <geometry>
                <cylinder radius="0.06" length = "0.025"/>
            </geometry>
	</collision>

        <visual>
            <origin xyz="0 0 0" rpy="1.5707 0 0" />
            <geometry>
                <cylinder radius="0.06" length = "0.025"/>
            </geometry>
        </visual>

	<inertial>
            <origin xyz="0 0 0"/>
            <mass value="1" />
            <inertia ixx="1" ixy="0" ixz="0" iyy="1" iyz="0" izz="1" />
        </inertial>		
    </link>

    <joint name="right_wheel_joint" type="continuous">
        <origin xyz="0 -0.19 -0.05" rpy="0 0 0"/>
        <parent link="base_link"/>
        <child link="right_wheel_link"/>
        <axis xyz="0 1 0"/>
    </joint>

    <link name="right_wheel_link">
	<collision>
	    <origin xyz="0 0 0" rpy="1.5707 0 0" />
            <geometry>
                <cylinder radius="0.06" length = "0.025"/>
            </geometry>
	</collision>

        <visual>
            <origin xyz="0 0 0" rpy="1.5707 0 0" />
            <geometry>
                <cylinder radius="0.06" length = "0.025"/>
            </geometry>
        </visual>

	<inertial>
            <origin xyz="0 0 0"/>
            <mass value="1" />
            <inertia ixx="1" ixy="0" ixz="0" iyy="1" iyz="0" izz="1" />
        </inertial>
    </link>

    <joint name="front_caster_joint" type="continuous">
        <origin xyz="0.18 0 -0.095" rpy="0 0 0"/>
        <parent link="base_link"/>
        <child link="front_caster_link"/>
        <axis xyz="0 1 0"/>
    </joint>

    <link name="front_caster_link">
	<collision>
	    <origin xyz="0 0 0" rpy="0 0 0" />
            <geometry>
                <sphere radius="0.015"/>
            </geometry>
	</collision>

        <visual>
            <origin xyz="0 0 0" rpy="0 0 0"/>
            <geometry>
                <sphere radius="0.015" />
            </geometry>
        </visual>

	<inertial>
            <origin xyz="0 0 0"/>
            <mass value="1" />
            <inertia ixx="1" ixy="0" ixz="0" iyy="1" iyz="0" izz="1" />
        </inertial>
    </link>

    <joint name="back_caster_joint" type="continuous">
        <origin xyz="-0.18 0 -0.095" rpy="0 0 0"/>
        <parent link="base_link"/>
        <child link="back_caster_link"/>
        <axis xyz="0 1 0"/>
    </joint>

    <link name="back_caster_link">
	<collision>
	    <origin xyz="0 0 0" rpy="0 0 0" />
            <geometry>
                <sphere radius="0.015"/>
            </geometry>
	</collision>

        <visual>
            <origin xyz="0 0 0" rpy="0 0 0"/>
            <geometry>
                <sphere radius="0.015" />
            </geometry>
        </visual>

	<inertial>
            <origin xyz="0 0 0"/>
            <mass value="1" />
            <inertia ixx="1" ixy="0" ixz="0" iyy="1" iyz="0" izz="1" />
        </inertial>
    </link>

    <link name="camera_link">
	<collision>
	    <origin xyz=" 0 0 0 " rpy="0 0 0" />
            <geometry>          
                <box size="0.02 0.05 0.03" />
            </geometry>
	</collision>

        <visual>
            <origin xyz=" 0 0 0 " rpy="0 0 0" />
            <geometry>          
                <box size="0.02 0.05 0.03" />
            </geometry>
            <material name="black">
                <color rgba="0 0 0 0.95"/>
            </material>
        </visual>

	<inertial>
            <origin xyz="0 0 0"/>
            <mass value="1" />
            <inertia ixx="1" ixy="0" ixz="0" iyy="1" iyz="0" izz="1" />
        </inertial>
    </link>

    <gazebo reference="camera_link">
   	<material>Gazebo/Black</material>
	<sensor type="camera" name="camera1">
      <update_rate>30.0</update_rate>
      <camera name="head">
        <horizontal_fov>1.3962634</horizontal_fov>
        <image>
          <width>800</width>
          <height>800</height>
          <format>R8G8B8</format>
        </image>
        <clip>
          <near>0.02</near>
          <far>300</far>
        </clip>
        <noise>
          <type>gaussian</type>
          <!-- Noise is sampled independently per pixel on each frame.
               That pixel's noise value is added to each of its color
               channels, which at that point lie in the range [0,1]. -->
          <mean>0.0</mean>
          <stddev>0.007</stddev>
        </noise>
      </camera>
      <plugin name="camera_controller" filename="libgazebo_ros_camera.so">
        <alwaysOn>true</alwaysOn>
        <updateRate>0.0</updateRate>
        <cameraName>rrbot/camera1</cameraName>
        <imageTopicName>image_raw</imageTopicName>
        <cameraInfoTopicName>camera_info</cameraInfoTopicName>
        <frameName>camera_link</frameName>
        <hackBaseline>0.07</hackBaseline>
        <distortionK1>0.0</distortionK1>
        <distortionK2>0.0</distortionK2>
        <distortionK3>0.0</distortionK3>
        <distortionT1>0.0</distortionT1>
        <distortionT2>0.0</distortionT2>
      </plugin>
	</sensor>
    </gazebo>

    <joint name="camera_joint" type="fixed">
        <origin xyz="0.17 0 0.095" rpy="0 0 0"/>
        <parent link="base_link"/>
        <child link="camera_link"/>
    </joint>

    <link name="laser_link">
	<collision>
	   <origin xyz=" 0 0 0 " rpy="0 0 0" />
	   <geometry>
		<cylinder length="0.05" radius="0.05"/>
	   </geometry>
	</collision>

	<visual>
	   <origin xyz=" 0 0 0 " rpy="0 0 0" />
	   <geometry>
		<cylinder length="0.05" radius="0.05"/>
	   </geometry>
	   <material name="black"/>
	</visual>

	<inertial>
            <origin xyz="0 0 0"/>
            <mass value="1" />
            <inertia ixx="1" ixy="0" ixz="0" iyy="1" iyz="0" izz="1" />
        </inertial>
    </link>

    <gazebo reference="laser_link">
   	<material>Gazebo/Black</material>
	<sensor type="gpu_ray" name="head_hokuyo_sensor">
      	   <pose>0 0 0 0 0 0</pose>
      	   <visualize>false</visualize>
      	   <update_rate>40</update_rate>
      	   <ray>
        	<scan>
          	   <horizontal>
            		<samples>720</samples>
            		<resolution>1</resolution>
            		<min_angle>-1.570796</min_angle>
            		<max_angle>1.570796</max_angle>
          	   </horizontal>
        	</scan>
        	<range>
          	   <min>0.10</min>
          	   <max>30.0</max>
          	   <resolution>0.01</resolution>
        	</range>
        	<noise>
          	   <type>gaussian</type>
          	<!-- Noise parameters based on published spec for Hokuyo laser
               achieving "+-30mm" accuracy at range < 10m.  A mean of 0.0m and
               stddev of 0.01m will put 99.7% of samples within 0.03m of the true
               reading. -->
          	   <mean>0.0</mean>
          	   <stddev>0.01</stddev>
        	</noise>
      	   </ray>
       	   <plugin name="gazebo_ros_head_hokuyo_controller" filename="libgazebo_ros_gpu_laser.so">
        	<topicName>/scan</topicName>
        	<frameName>laser_link</frameName>
      	   </plugin>
    	</sensor>
    </gazebo>

    <joint name="laser_joint" type="fixed">
        <origin xyz="0 0 0.105" rpy="0 0 0"/>
        <parent link="base_link"/>
        <child link="laser_link"/>
    </joint>

   <link name="imu_link">
	<collision>
	    <origin xyz=" 0 0 0 " rpy="0 0 0" />
            <geometry>          
                <box size="0.02 0.02 0.01" />
            </geometry>
	</collision>

        <visual>
            <origin xyz=" 0 0 0 " rpy="0 0 0" />
            <geometry>          
                <box size="0.02 0.02 0.01" />
            </geometry>
        </visual>

	<inertial>
            <origin xyz="0 0 0"/>
            <mass value="0.5" />
            <inertia ixx="1" ixy="0" ixz="0" iyy="1" iyz="0" izz="1" />
        </inertial>
    </link>

  <gazebo reference="imu_link">
    <gravity>true</gravity>
    <sensor name="imu_sensor" type="imu">
      <always_on>true</always_on>
      <update_rate>100</update_rate>
      <visualize>true</visualize>
      <topic>__default_topic__</topic>
      <plugin filename="libgazebo_ros_imu_sensor.so" name="imu_plugin">
        <topicName>imu</topicName>
        <bodyName>imu_link</bodyName>
        <updateRateHZ>10.0</updateRateHZ>
        <gaussianNoise>0.0</gaussianNoise>
        <xyzOffset>0 0 0</xyzOffset>
        <rpyOffset>0 0 0</rpyOffset>
        <frameName>imu_link</frameName>
        <initialOrientationAsReference>false</initialOrientationAsReference>
      </plugin>
      <pose>0 0 0 0 0 0</pose>
    </sensor>
  </gazebo>

    <joint name="imu_joint" type="fixed">
        <origin xyz="0.1 0 0.085" rpy="0 0 0"/>
        <parent link="base_link"/>
        <child link="imu_link"/>
    </joint>

<gazebo>
  <plugin name="differential_drive_controller" filename="libgazebo_ros_diff_drive.so">
    <rosDebuglevel>Debug</rosDebuglevel>
    <publishWheelTF>false</publishWheelTF>
    <publishTF>1</publishTF>
    <publishWheelJointState>false</publishWheelJointState>
    <updateRate>100.0</updateRate>
    <leftJoint>left_wheel_joint</leftJoint>
    <rightJoint>right_wheel_joint</rightJoint>
    <wheelSeparation>0.4</wheelSeparation>
    <wheelDiameter>0.12</wheelDiameter>
    <wheelAcceleration>1.8</wheelAcceleration>
    <commandTopic>cmd_vel</commandTopic>
    <odometryTopic>odom</odometryTopic>
    <robotBaseFrame>base_footprint</robotBaseFrame>
    <odometryFrame>odom</odometryFrame>
    <broadcastTF>1</broadcastTF>
  </plugin>
</gazebo>

  <gazebo>
    <plugin name="gazebo_ros_control" filename="libgazebo_ros_control.so">
      <robotNamespace>/my_robot</robotNamespace>
    </plugin>
  </gazebo>

</robot>

2.使用turtlebot3中的控制机器人的文件

​ 2.1在src目录下创建teleop_robot功能包,并添加依赖rospy geometry_msgs

​ $ cd ~/Documents/test_ws/src
​ $ catkin_create_pkg teleop_robot rospy geometry_msgs

​ 2.2 在teleop_robot/src文件夹下创建文件teleop_robot_key.py

​ $ cd src/teleop_robot/src/
​ $ gedit teleop_robot_key

​ 输入以下内容:

#!/usr/bin/env python
import rospy
from geometry_msgs.msg import Twist
import sys, select, os
if os.name == 'nt':
  import msvcrt, time
else:
  import tty, termios

BURGER_MAX_LIN_VEL = 0.32
BURGER_MAX_ANG_VEL = 2.84

WAFFLE_MAX_LIN_VEL = 0.26
WAFFLE_MAX_ANG_VEL = 1.82

LIN_VEL_STEP_SIZE = 0.01
ANG_VEL_STEP_SIZE = 0.1

msg = """
Control Your TurtleBot3!
---------------------------
Moving around:
        w
   a    s    d
        x

w/x : increase/decrease linear velocity (Burger : ~ 0.32, Waffle and Waffle Pi : ~ 0.26)
a/d : increase/decrease angular velocity (Burger : ~ 2.84, Waffle and Waffle Pi : ~ 1.82)

space key, s : force stop

CTRL-C to quit
"""

e = """
Communications Failed
"""

def getKey():
    if os.name == 'nt':
        timeout = 0.1
        startTime = time.time()
        while(1):
            if msvcrt.kbhit():
                if sys.version_info[0] >= 3:
                    return msvcrt.getch().decode()
                else:
                    return msvcrt.getch()
            elif time.time() - startTime > timeout:
                return ''

    tty.setraw(sys.stdin.fileno())
    rlist, _, _ = select.select([sys.stdin], [], [], 0.1)
    if rlist:
        key = sys.stdin.read(1)
    else:
        key = ''

    termios.tcsetattr(sys.stdin, termios.TCSADRAIN, settings)
    return key

def vels(target_linear_vel, target_angular_vel):
    return "currently:\tlinear vel %s\t angular vel %s " % (target_linear_vel,target_angular_vel)

def makeSimpleProfile(output, input, slop):
    if input > output:
        output = min( input, output + slop )
    elif input < output:
        output = max( input, output - slop )
    else:
        output = input

    return output

def constrain(input, low, high):
    if input < low:
      input = low
    elif input > high:
      input = high
    else:
      input = input

    return input

def checkLinearLimitVelocity(vel):
    if turtlebot3_model == "burger":
      vel = constrain(vel, -BURGER_MAX_LIN_VEL, BURGER_MAX_LIN_VEL)
    elif turtlebot3_model == "waffle" or turtlebot3_model == "waffle_pi":
      vel = constrain(vel, -WAFFLE_MAX_LIN_VEL, WAFFLE_MAX_LIN_VEL)
    else:
      vel = constrain(vel, -BURGER_MAX_LIN_VEL, BURGER_MAX_LIN_VEL)

    return vel

def checkAngularLimitVelocity(vel):
    if turtlebot3_model == "burger":
      vel = constrain(vel, -BURGER_MAX_ANG_VEL, BURGER_MAX_ANG_VEL)
    elif turtlebot3_model == "waffle" or turtlebot3_model == "waffle_pi":
      vel = constrain(vel, -WAFFLE_MAX_ANG_VEL, WAFFLE_MAX_ANG_VEL)
    else:
      vel = constrain(vel, -BURGER_MAX_ANG_VEL, BURGER_MAX_ANG_VEL)

    return vel

if __name__=="__main__":
    if os.name != 'nt':
        settings = termios.tcgetattr(sys.stdin)

    rospy.init_node('turtlebot3_teleop')
    pub = rospy.Publisher('cmd_vel', Twist, queue_size=10)

    turtlebot3_model = rospy.get_param("model", "burger")

    status = 0
    target_linear_vel   = 0.0
    target_angular_vel  = 0.0
    control_linear_vel  = 0.0
    control_angular_vel = 0.0

    try:
        print(msg)
        while not rospy.is_shutdown():
            key = getKey()
            if key == 'w' :
                target_linear_vel = checkLinearLimitVelocity(target_linear_vel + LIN_VEL_STEP_SIZE)
                status = status + 1
                print(vels(target_linear_vel,target_angular_vel))
            elif key == 'x' :
                target_linear_vel = checkLinearLimitVelocity(target_linear_vel - LIN_VEL_STEP_SIZE)
                status = status + 1
                print(vels(target_linear_vel,target_angular_vel))
            elif key == 'a' :
                target_angular_vel = checkAngularLimitVelocity(target_angular_vel + ANG_VEL_STEP_SIZE)
                status = status + 1
                print(vels(target_linear_vel,target_angular_vel))
            elif key == 'd' :
                target_angular_vel = checkAngularLimitVelocity(target_angular_vel - ANG_VEL_STEP_SIZE)
                status = status + 1
                print(vels(target_linear_vel,target_angular_vel))
            elif key == ' ' or key == 's' :
                target_linear_vel   = 0.0
                control_linear_vel  = 0.0
                target_angular_vel  = 0.0
                control_angular_vel = 0.0
                print(vels(target_linear_vel, target_angular_vel))
            else:
                if (key == '\x03'):
                    break

            if status == 20 :
                print(msg)
                status = 0

            twist = Twist()

            control_linear_vel = makeSimpleProfile(control_linear_vel, target_linear_vel, (LIN_VEL_STEP_SIZE/2.0))
            twist.linear.x = control_linear_vel; twist.linear.y = 0.0; twist.linear.z = 0.0

            control_angular_vel = makeSimpleProfile(control_angular_vel, target_angular_vel, (ANG_VEL_STEP_SIZE/2.0))
            twist.angular.x = 0.0; twist.angular.y = 0.0; twist.angular.z = control_angular_vel

            pub.publish(twist)

    except:
        print(e)

    finally:
        twist = Twist()
        twist.linear.x = 0.0; twist.linear.y = 0.0; twist.linear.z = 0.0
        twist.angular.x = 0.0; twist.angular.y = 0.0; twist.angular.z = 0.0
        pub.publish(twist)

    if os.name != 'nt':
        termios.tcsetattr(sys.stdin, termios.TCSADRAIN, settings)

3.进入工作空间根目录进行编译

$ cd ~/Documents/test_ws
$ catkin_make
$ source devel/setup.bash
$ rospack find teleop_robot  (编译好的话可以找到这个功能包的所在路径)

4.开启三个终端测试控制效果

进入终端进入到~/Documents/test_ws后需要执行一下
$ source devel/setup.bash 

然后分别在三个终端运行以下三个命令:
1.打开gazebo
$ roslaunch myrobot_description test.launch 

2.打开rviz
$ roslaunch myrobot_description display_my_robot.launch 

3.运行控制节点,根据提示可以改变线速度和角速度让机器人动起来
$ rosrun teleop_robot teleop_robot_key

Gazebo-Ros搭建小车和场景并运行slam算法进行建图4--为机器人添加运动控制器控制其移动

Gazebo-Ros搭建小车和场景并运行slam算法进行建图4--为机器人添加运动控制器控制其移动

5.接下来就是运行slam算法了

主要就是slam算法订阅的传感器主题要和机器人发布的传感器一致,这里是/scan,还有坐标系,这里雷达的坐标系是 laser_link .文章来源地址https://www.toymoban.com/news/detail-409945.html

到了这里,关于Gazebo-Ros搭建小车和场景并运行slam算法进行建图4--为机器人添加运动控制器控制其移动的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处: 如若内容造成侵权/违法违规/事实不符,请点击违法举报进行投诉反馈,一经查实,立即删除!

领支付宝红包 赞助服务器费用

相关文章

  • 基于ROS和YOLO的SLAM智能小车仿真系统设计

    Ubuntu 20.4 ros-noetic gazebo yolov4 nvidia525+cuda10.1+cudnn_7.6.5 将darknet文件夹移动到darknet_ros文件夹下 链接: https://download.csdn.net/download/qq_42281475/87502982. 将下载的yolo_network_config替换roscar_gazebo_yolov4/src/darknet_ros/darknet_ros/目录下的文件 链接: https://download.csdn.net/download/qq_42281475/87502991

    2024年02月10日
    浏览(39)
  • gazebo仿真环境搭建+配置+小车运动仿真

    ubuntu版本:20.04 gazebo版本:gazebo11 1.打开gazebo 终端输入“gazebo”或者直接点gazebo软件图标。   2.前往建筑编辑器 点击上方“Edit” → “Buiding Edit ” 或者快捷键 “Ctrl + B” 进入建筑编辑器。 左边图形界面可以建造墙,添加门、窗、梯子。也可以更改以后墙的颜色和纹理。

    2024年02月06日
    浏览(43)
  • ORB-SLAM2算法6之D435i双目IR相机运行ROS版ORB-SLAM2并发布位姿pose的rostopic

    ORB-SLAM2算法1已成功编译安装 ROS 版本 ORB-SLAM2 到本地,以及ORB-SLAM2算法5

    2024年02月09日
    浏览(46)
  • 基于Gazebo搭建移动机器人,并结合SLAM系统完成建图仿真

    博客地址:https://www.cnblogs.com/zylyehuo/ gazebo小车模型创建及仿真详见之前博客 gazebo小车模型(附带仿真环境) - zylyehuo - 博客园 gazebo+rviz 仿真 - zylyehuo - 博客园 参考链接 Autolabor-ROS机器人入门课程《ROS理论与实践》 安装 gmapping 包(用于构建地图): sudo apt install ros-melodic-gmapping 安

    2024年02月04日
    浏览(51)
  • ROS自学笔记二十: Gazebo里面仿真环境搭建

    Gazebo 中创建仿真实现方式有两种:1直接添加内置组件创建仿真环境2: 手动绘制仿真环境 添加完毕后,选择 file --- Save World as 选择保存路径(功能包下: worlds 目录),文件名自定义,后缀名设置为 .world 点击: 左上角 file --- Save (保存路径功能包下的: models) 然后 file --- Exit Building

    2024年02月06日
    浏览(38)
  • 基于Gazebo搭建移动机器人,并结合SLAM系统完成定位和建图仿真

    博客地址:https://www.cnblogs.com/zylyehuo/ gazebo小车模型创建及仿真详见之前博客 gazebo小车模型(附带仿真环境) - zylyehuo - 博客园 gazebo+rviz 仿真 - zylyehuo - 博客园 参考链接 Autolabor-ROS机器人入门课程《ROS理论与实践》 安装 gmapping 包(用于构建地图): sudo apt install ros-melodic-gmapping 安

    2024年02月04日
    浏览(46)
  • ROS学习第三十六节——Gazebo仿真环境搭建

    1.1加入环境模型 在工程文件中创建worlds文件夹,并把之前下载的box_house.world文件放入  1.2编写launch文件 deamo03_car_world.launch 2.1启动 Gazebo 并添加组件 2.2保存仿真环境 添加完毕后,选择 file --- Save World as 选择保存路径(功能包下: worlds 目录),文件名自定义,后缀名设置为 .worl

    2023年04月24日
    浏览(40)
  • ubuntu20.04_ROS中运行gazebo控制机器人模型报错

    1.无法启动类型为[controller_ manager/spawner]的节点:controller_ manager ERROR: cannot launch node of type [controller_manager/spawner]: controller_manager ROS path [0]=/opt/ros/noetic/share/ros ROS path [1]=/home/lym/catkin_ws/src ROS path [2]=/opt/ros/noetic/share 解决办法:安装controller_manager 2.控制器生成程序找不到预期的控

    2024年02月16日
    浏览(50)
  • 【ROS&GAZEBO】多旋翼无人机仿真(一)——搭建仿真环境

    【ROSGAZEBO】多旋翼无人机仿真(一)——搭建仿真环境 【ROSGAZEBO】多旋翼无人机仿真(二)——基于rotors的仿真 【ROSGAZEBO】多旋翼无人机仿真(三)——自定义无人机模型 【ROSGAZEBO】多旋翼无人机仿真(四)——探索控制器原理 【ROSGAZEBO】多旋翼无人机仿真(五)——位置

    2023年04月17日
    浏览(78)
  • 【ROS2机器人入门到实战】Gazebo仿真环境搭建

    当前平台文章汇总地址:ROS2机器人从入门到实战 获取完整教程及配套资料代码,请关注公众号鱼香ROS获取 教程配套机器人开发平台:两驱版| 四驱版 为方便交流,搭建了机器人技术问答社区:地址 fishros.org.cn 本节我们要在Gazebo中建立一个测试的环境,其实也很简单,利用

    2024年02月05日
    浏览(62)

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

博客赞助

微信扫一扫打赏

请作者喝杯咖啡吧~博客赞助

支付宝扫一扫领取红包,优惠每天领

二维码1

领取红包

二维码2

领红包