Navigation

    蓝鲸ROS机器人论坛

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • Popular
    ROS交流群
    ROS Group
    产品服务
    Product Service
    开源代码库
    Github
    官网
    Official website
    技术交流
    Technological exchanges
    激光雷达
    LIDAR
    ROS教程
    ROS Tourials
    深度学习
    Deep Learning
    机器视觉
    Computer Vision

    xiaoqiang tutorial (14) using rplidar A2 with gmapping

    产品服务
    5
    10
    5596
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • weijiz
      weijiz last edited by weijiz

      Xiaoqiang Homepage

      Using rplidar A2 with gmapping

      1.Start the gmapping node

      Ensure that the lidar is properly installed, and launch the gmapping launch file after ssh login the host.

      ssh xiaoqiang@192.168.XXX.XXX
      roslaunch gmapping slam_gmapping_xiaoqiang_rplidar_a2.launch
      

      Open rviz in the local virtual machine, select the slam_gmapping/gmapping/launch/rplidar_a2_test.rviz configuration file and open it in Xiaoqiang ROS directory.

      Note: Some systems can't do this. You can copy that file directly to your local computer and open it locally.

      export ROS_MASTER_URI=http://xiaoqiang-desktop:11311
      rviz
      

      0_1536825603040_1b4bcf75-4533-4722-a339-5787e629abb6-image.png

      Wait a few seconds, normal results similar to the following figure will appear.

      0_1536825625702_9328c378-e0f1-4ddf-827a-ca8191efe2dd-image.png

      2.Remote control Xiaoqiang and start to build a map

      The first way: use the windows remote control client, refer to this post

      The second way:using the ssh remote control

      ssh xiaoqiang@192.168.XXX.XXX
      rosrun nav_test control.py
      

      The third way: use mobile app, refer to this post Xiaoqiang mobile remote control app for Android

      0_1536825683715_63efe665-05cd-4256-9af0-f613a33aa6b3-image.png

      3.Save the map

      ssh login Xiaoqiang, in the Xiaoqiang home directory save the map as the beginning of work0 file.

      ssh xiaoqiang@192.168.XXX.XXX
      rosrun map_server map_saver -f work0
      

      0_1536825762493_a2f354b7-a061-4239-b711-71aec4d7da27-image.png

      Xiaoqiang Homepage
      Back To Index

      ccsky 1 Reply Last reply Reply Quote 0
      • ccsky
        ccsky @weijiz last edited by

        @weijiz 在 xiaoqiang tutorial (14) using rplidar A2 with gmapping 中说:

        am_gmapping_xiaoqiang_rplida

        0_1543220318823_e4446829-b22e-4f3a-b21f-d0fa76ac54c4-image.png

        启动roslaunch gmapping slam_gmapping_xiaoqiang_rplidar_a2.launch 时报错,是什么原因呢? 会不会影响在rviz中构建地图?

        xiaoqiang 1 Reply Last reply Reply Quote 0
        • xiaoqiang
          xiaoqiang @ccsky last edited by

          @ccsky Check if the rplidar is connected to the car host computer usb port.
          Run "ls /dev " ,check ttyUSB002 is listed or not

          ccsky 1 Reply Last reply Reply Quote 0
          • ccsky
            ccsky @xiaoqiang last edited by

            @xiaoqiang
            0_1543276786115_a5af3842-b3b7-46b4-9559-72ee50ab0ece-image.png

            没有ttyUSB002, 我们用的是XQ-4 Pro的小车。这个不是带有雷达吗?

            weijiz 1 Reply Last reply Reply Quote 0
            • weijiz
              weijiz @ccsky last edited by

              @ccsky 你的雷达没有对应的串口设备。可能是雷达的串口没插好。也有可能雷达是坏的

              雾琴水音 1 Reply Last reply Reply Quote 0
              • 雾琴水音
                雾琴水音 @weijiz last edited by

                @weijiz 如果列出usb001和usb002,还报出这个错误是什么原因

                weijiz 1 Reply Last reply Reply Quote 0
                • weijiz
                  weijiz @雾琴水音 last edited by

                  @雾琴水音 看看权限设置对不对,一般有这个的话是不会出现上面的错误的

                  雾琴水音 1 Reply Last reply Reply Quote 0
                  • 雾琴水音
                    雾琴水音 @weijiz last edited by

                    @weijiz 好的 谢谢您

                    1 Reply Last reply Reply Quote 0
                    • qq303956
                      qq303956 last edited by

                      您好RVIZ最后出现这种情况怎么处理呢 可以说稍微详细一些嘛 谢谢了 2020-12-07 13-24-20屏幕截图.png

                      xiaoqiang 1 Reply Last reply Reply Quote 0
                      • xiaoqiang
                        xiaoqiang @qq303956 last edited by

                        @qq303956 上面rviz错误是tf关系缺失,检查tf树,可能原因:里程计没有正常发布,或gmapping没有正常工作导致map到odom这个tf关系没发布

                        1 Reply Last reply Reply Quote 0
                        • 1 / 1
                        • First post
                          Last post
                        Copyright © 2015-2023 BlueWhale community