鱼香ROS社区
    • 版块
    • 最新
    • 未解决
    • 已解决
    • 群组
    • 注册
    • 登录
    紧急通知:禁止一切关于政治&VPN翻墙等话题,发现相关帖子会立马删除封号
    提问前必看的发帖注意事项: 社区问答规则(小鱼个人)更新 | 高质量帖子发布指南

    【FishBot四驱V2】资料教程汇总

    已定时 已固定 已锁定 已移动
    FishBot四驱机器人V2
    fishbot 四驱版 v2
    7
    15
    25.7k
    正在加载更多帖子
    • 从旧到新
    • 从新到旧
    • 最多赞同
    回复
    • 在新帖中回复
    登录后回复
    此主题已被删除。只有拥有主题管理权限的用户可以查看。
    • 2
      后知后觉的后知后觉
      最后由 编辑

      根据视频教程9.5.5完成机器人建图时,rviz2插件无法加载出map地图,
      21c405d7-649e-4eba-929a-5829ae177381-截图 2025-05-19 10-24-20.png
      查看话题如下:
      ros@ros-virtual-machine:~$ ros2 topic list
      /clicked_point
      /cmd_vel
      /goal_pose
      /initialpose
      /joint_states
      /map
      /map_metadata
      /map_updates
      /odom
      /parameter_events
      /point_cloud
      /pose
      /robot_description
      /rosout
      /scan
      /slam_toolbox/feedback
      /slam_toolbox/graph_visualization
      /slam_toolbox/scan_visualization
      /slam_toolbox/update
      /tf
      /tf_static
      /ydlidar_node/transition_event
      ros@ros-virtual-machine:~$
      @小鱼 什么原因导致的,怎么排查此问题?

      2 2 条回复 最后回复 回复 引用 0
      • 2
        后知后觉的后知后觉 @2889839823
        最后由 编辑

        @2889839823 ros@ros-virtual-machine:~/demo01_ws/fishros_ws$ source install/setup.bash
        ros@ros-virtual-machine:~/demo01_ws/fishros_ws$ ros2 launch fishbot_bringup bringup.launch.py
        [INFO] [launch]: All log files can be found below /home/ros/.ros/log/2025-05-19-10-35-33-997917-ros-virtual-machine-28449
        [INFO] [launch]: Default logging verbosity is set to INFO
        [INFO] [robot_state_publisher-1]: process started with pid [28451]
        [INFO] [odom2tf-2]: process started with pid [28453]
        [INFO] [micro_ros_agent-3]: process started with pid [28455]
        [INFO] [tcp_server-4]: process started with pid [28457]
        [micro_ros_agent-3] [1747622134.048096] info | UDPv4AgentLinux.cpp | init | running... | port: 8888
        [micro_ros_agent-3] [1747622134.048428] info | Root.cpp | set_verbose_level | logger setup | verbose_level: 4
        [robot_state_publisher-1] [INFO] [1747622134.074304017] [robot_state_publisher]: got segment base_footprint
        [robot_state_publisher-1] [INFO] [1747622134.074422352] [robot_state_publisher]: got segment base_link
        [robot_state_publisher-1] [INFO] [1747622134.074429396] [robot_state_publisher]: got segment laser_link
        [tcp_server-4] [INFO] [1747622134.233271164] [tcp_socket_server_node]: TCP端口:8889,已映射到串口设备:/tmp/tty_laser
        [tcp_server-4] [INFO] [1747622134.233652379] [tcp_socket_server_node]: 等待接受连接..
        [tcp_server-4] [INFO] [1747622137.636580747] [tcp_socket_server_node]: 来自('10.0.18.117', 61256)的连接已建立
        [INFO] [ydlidar_node-5]: process started with pid [28532]
        [ydlidar_node-5] [INFO] [1747622139.131033797] [ydlidar_node]: [YDLIDAR INFO] Current ROS Driver Version: 1.0.1
        [ydlidar_node-5]
        [ydlidar_node-5] [2025-05-19 10:35:39][info] SDK initializing
        [ydlidar_node-5] [2025-05-19 10:35:39][info] SDK has been initialized
        [ydlidar_node-5] [2025-05-19 10:35:39][info] SDK Version: 1.2.9
        [ydlidar_node-5] [2025-05-19 10:35:39][info] Connect elapsed time 0 ms
        [ydlidar_node-5] [2025-05-19 10:35:39][info] Lidar successfully connected [/tmp/tty_laser:115200]
        [ydlidar_node-5] [2025-05-19 10:35:39][info] Lidar running correctly! The health status good
        [ydlidar_node-5] [2025-05-19 10:35:39][info] Current Lidar Model Code 12
        [ydlidar_node-5] [2025-05-19 10:35:39][info] Check status, Elapsed time 0 ms
        [ydlidar_node-5] [2025-05-19 10:35:39][info] Lidar init success, Elapsed time [1]ms
        [micro_ros_agent-3] [1747622139.452562] info | Root.cpp | create_client | create | client_key: 0x3E84C3B8, session_id: 0x81
        [micro_ros_agent-3] [1747622139.452644] info | SessionManager.hpp | establish_session | session established | client_key: 0x3E84C3B8, address: 10.0.19.178:47138
        [micro_ros_agent-3] [1747622139.479878] info | ProxyClient.cpp | create_participant | participant created | client_key: 0x3E84C3B8, participant_id: 0x000(1)
        [micro_ros_agent-3] [1747622139.487761] info | ProxyClient.cpp | create_topic | topic created | client_key: 0x3E84C3B8, topic_id: 0x000(2), participant_id: 0x000(1)
        [micro_ros_agent-3] [1747622139.494860] info | ProxyClient.cpp | create_publisher | publisher created | client_key: 0x3E84C3B8, publisher_id: 0x000(3), participant_id: 0x000(1)
        [micro_ros_agent-3] [1747622139.504490] info | ProxyClient.cpp | create_datawriter | datawriter created | client_key: 0x3E84C3B8, datawriter_id: 0x000(5), publisher_id: 0x000(3)
        [micro_ros_agent-3] [1747622139.529864] info | ProxyClient.cpp | create_topic | topic created | client_key: 0x3E84C3B8, topic_id: 0x001(2), participant_id: 0x000(1)
        [micro_ros_agent-3] [1747622139.538058] info | ProxyClient.cpp | create_subscriber | subscriber created | client_key: 0x3E84C3B8, subscriber_id: 0x000(4), participant_id: 0x000(1)
        [micro_ros_agent-3] [1747622139.555822] info | ProxyClient.cpp | create_datareader | datareader created | client_key: 0x3E84C3B8, datareader_id: 0x000(6), subscriber_id: 0x000(4)
        [ydlidar_node-5] [2025-05-19 10:35:39][info] Start to getting intensity flag
        [ydlidar_node-5] [2025-05-19 10:35:40][info] Auto set intensity 0
        [ydlidar_node-5] [2025-05-19 10:35:40][info] [YDLIDAR] End to getting intensity flag
        [ydlidar_node-5] [2025-05-19 10:35:40][info] [YDLIDAR] Create thread 0x5ADB4640
        [ydlidar_node-5] [2025-05-19 10:35:40][info] Successed to start scan mode, Elapsed time 1553 ms
        [ydlidar_node-5] [2025-05-19 10:35:40][info] Scan Frequency: 5.00Hz
        [ydlidar_node-5] [2025-05-19 10:35:40][info] Fixed Size: 720
        [ydlidar_node-5] [2025-05-19 10:35:40][info] Sample Rate: 3.00K
        [ydlidar_node-5] [2025-05-19 10:35:40][info] Scan Frequency: 5.00Hz
        [ydlidar_node-5] [2025-05-19 10:35:40][info] Fixed Size: 720
        [ydlidar_node-5] [2025-05-19 10:35:40][info] Sample Rate: 3.00K
        [ydlidar_node-5] [2025-05-19 10:35:40][info] Scan Frequency: 5.00Hz
        [ydlidar_node-5] [2025-05-19 10:35:40][info] Fixed Size: 720
        [ydlidar_node-5] [2025-05-19 10:35:40][info] Sample Rate: 3.00K
        [ydlidar_node-5] [2025-05-19 10:35:41][info] Scan Frequency: 5.00Hz
        [ydlidar_node-5] [2025-05-19 10:35:41][info] Fixed Size: 720
        [ydlidar_node-5] [2025-05-19 10:35:41][info] Sample Rate: 3.00K
        [ydlidar_node-5] [2025-05-19 10:35:41][info] Scan Frequency: 5.00Hz
        [ydlidar_node-5] [2025-05-19 10:35:41][info] Fixed Size: 720
        [ydlidar_node-5] [2025-05-19 10:35:41][info] Sample Rate: 3.00K
        [ydlidar_node-5] [2025-05-19 10:35:41][info] Single Fixed Size: 380
        [ydlidar_node-5] [2025-05-19 10:35:41][info] Sample Rate: 3.00K
        [ydlidar_node-5] [2025-05-19 10:35:41][info] Successed to check the lidar, Elapsed time 492 ms
        [ydlidar_node-5] [2025-05-19 10:35:41][info] Now lidar is scanning...
        [ydlidar_node-5] [YDLIDAR ERROR]: -1 No error
        [ydlidar_node-5] [ERROR] [1747622146.712035262] [ydlidar_node]: Failed to get scan
        [ydlidar_node-5] [2025-05-19 10:35:46][error] Timeout count: 1
        [ydlidar_node-5] [YDLIDAR ERROR]: -1 Operation timed out
        [ydlidar_node-5] [ERROR] [1747622156.798528457] [ydlidar_node]: Failed to get scan
        [ydlidar_node-5] [2025-05-19 10:35:56][error] Timeout count: 1
        [ydlidar_node-5] [YDLIDAR ERROR]: -1 Operation timed out
        [ydlidar_node-5] [ERROR] [1747622166.783990347] [ydlidar_node]: Failed to get scan
        [ydlidar_node-5] [2025-05-19 10:36:06][error] Timeout count: 1
        [ydlidar_node-5] [2025-05-19 10:36:07][error] Check Sum 0xB856 != 0x5B88

        ros@ros-virtual-machine:~/demo01_ws/fishros_ws$ source install/setup.bash
        ros@ros-virtual-machine:~/demo01_ws/fishros_ws$ ros2 launch slam_toolbox online_async_launch.py use_sim_time:=False
        [INFO] [launch]: All log files can be found below /home/ros/.ros/log/2025-05-19-10-35-46-976244-ros-virtual-machine-28634
        [INFO] [launch]: Default logging verbosity is set to INFO
        [INFO] [async_slam_toolbox_node-1]: process started with pid [28640]
        [async_slam_toolbox_node-1] [INFO] [1747622147.055711681] [slam_toolbox]: Node using stack size 40000000
        [async_slam_toolbox_node-1] [INFO] [1747622147.102664316] [slam_toolbox]: Using solver plugin solver_plugins::CeresSolver
        [async_slam_toolbox_node-1] [INFO] [1747622147.102880888] [slam_toolbox]: CeresSolver: Using SCHUR_JACOBI preconditioner.
        [async_slam_toolbox_node-1] [INFO] [1747622147.347918489] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622147.096 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622147.474620045] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622147.222 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622147.601750969] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622147.347 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622147.725817995] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622147.474 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622147.852745500] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622147.601 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622147.979005300] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622147.725 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622148.105321842] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622147.852 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622148.230537213] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622147.979 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622148.356992339] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622148.105 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622148.482597934] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622148.230 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622148.611013998] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622148.357 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622148.735707447] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622148.482 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622148.861187621] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622148.611 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622148.987582063] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622148.735 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622149.114642320] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622148.861 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622149.240151010] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622148.987 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622149.366025813] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622149.114 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622149.491061351] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622149.240 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622149.618645713] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622149.366 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622149.743581896] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622149.491 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622149.868943573] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622149.618 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622149.997337944] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622149.743 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622150.122568177] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622149.869 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622150.248216090] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622149.997 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622150.374799130] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622150.122 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622150.501216264] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622150.248 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622150.628447436] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622150.374 for reason 'discarding message because the queue is full'
        [async_slam_toolbox_node-1] [INFO] [1747622150.754517197] [slam_toolbox]: Message Filter dropping message: frame 'laser_link' at time 1747622150.501 for reason 'discarding message because the queue is full'

        1 条回复 最后回复 回复 引用 0
        • 2
          后知后觉的后知后觉 @2889839823
          最后由 编辑

          @2889839823运行rviz2加载地图后,地图不会实时刷新,报错如下
          ros@ros-virtual-machine:~/demo01_ws/fishros_ws$ rviz2
          [INFO] [1747643790.580932382] [rviz2]: Stereo is NOT SUPPORTED
          [INFO] [1747643790.581076461] [rviz2]: OpenGl version: 4.3 (GLSL 4.3)
          [INFO] [1747643790.617443151] [rviz2]: Stereo is NOT SUPPORTED
          [INFO] [1747643799.501060541] [rviz2]: Trying to create a map of size 209 x 205 using 1 swatches
          [ERROR] [1747643799.533153654] [rviz2]: Vertex Program:rviz/glsl120/indexed_8bit_image.vert Fragment Program:rviz/glsl120/indexed_8bit_image.frag GLSL link result :
          active samplers with a different type refer to the same texture image unit
          [INFO] [1747643819.500981429] [rviz2]: Trying to create a map of size 209 x 205 using 1 swatches
          [INFO] [1747643824.525077935] [rviz2]: Trying to create a map of size 209 x 205 using 1 swatches
          [INFO] [1747643829.516767314] [rviz2]: Trying to create a map of size 209 x 205 using 1 swatches
          [INFO] [1747643834.508103811] [rviz2]: Trying to create a map of size 209 x 205 using 1 swatches

          @小鱼

          L 1 条回复 最后回复 回复 引用 0
          • L
            luqixuan 年度VIP @2889839823
            最后由 编辑

            @2889839823 # Rviz2 地图不刷新问题分析

            从您提供的日志来看,Rviz2 在加载地图时遇到了一些问题,导致地图无法实时刷新。以下是问题分析和解决方案:

            主要问题

            1. GLSL 着色器链接错误:

              [ERROR] [rviz2]: Vertex Program:rviz/glsl120/indexed_8bit_image.vert Fragment Program:rviz/glsl120/indexed_8bit_image.frag GLSL link result :
              active samplers with a different type refer to the same texture image unit
              

              这个错误表明 Rviz2 在渲染地图纹理时遇到了着色器问题。

            2. 地图重复尝试创建:
              日志显示 Rviz2 不断尝试创建相同尺寸的地图(209x205),这表明地图数据可能没有正确更新。

            可能的原因和解决方案

            1. OpenGL 驱动问题

            错误信息表明与 OpenGL 和 GLSL 着色器相关的问题,可能是由于:

            • 虚拟机中的 OpenGL 支持不完全
            • 显卡驱动问题

            解决方案:

            • 确保虚拟机已启用 3D 加速
            • 更新主机的显卡驱动
            • 尝试在物理机上运行而不是虚拟机

            2. Rviz2 配置问题

            解决方案:

            • 检查地图显示插件的设置:
              • 确保 "Topic" 设置正确指向您的地图话题(通常是 /map)
              • 检查 "Alpha" 值是否合适(通常设为 0.7-1.0)
              • 确认 "Color Scheme" 设置正确

            3. 地图数据发布问题

            解决方案:

            • 确保您的地图服务器(nav2_map_server 或类似的)正在运行并正确发布地图
            • 使用 ros2 topic echo /map 检查地图数据是否定期更新

            4. 尝试其他显示方式

            如果问题持续,可以尝试:

            • 使用 OccupancyGrid 显示而不是 Map
            • 降低地图的 QoS 设置

            其他建议

            1. 尝试完全删除 Rviz2 的配置文件(位于 ~/.rviz2/),然后重新启动 Rviz2 并重新配置。

            2. 检查系统资源使用情况,确保没有内存或 CPU 瓶颈。

            3. 如果可能,尝试在不同的机器上运行以确定是否是特定于虚拟机的问题。

            如果您能提供更多关于您的设置信息(如使用的 ROS2 版本、地图服务器配置等),我可以给出更具体的建议。

            2 1 条回复 最后回复 回复 引用 0
            • 2
              后知后觉的后知后觉 @luqixuan
              最后由 编辑

              @luqixuan e09c8683-15ce-40f4-b263-1c96f3b61947-图片.png 094dae82-2609-44a6-a00a-528a40695155-图片.png e3cb9147-46ca-4933-b79b-949ea9d70e46-图片.png

              L 1 条回复 最后回复 回复 引用 0
              • L
                luqixuan 年度VIP @2889839823
                最后由 编辑

                @2889839823 大概地图是正常的,显示不太行

                2 1 条回复 最后回复 回复 引用 0
                • 2
                  后知后觉的后知后觉 @luqixuan
                  最后由 编辑

                  @luqixuan 重新安装系统也还是有这个问题,虚拟机重新安装

                  1 条回复 最后回复 回复 引用 0
                  • S
                    sxy
                    最后由 编辑

                    鱼哥可以发一下fishbot的原理图吗

                    1 条回复 最后回复 回复 引用 0
                    • 2
                      2445085455 @小鱼
                      最后由 编辑

                      @小鱼 你好,有没有四驱v2的第九章后面的代码???

                      1 条回复 最后回复 回复 引用 0
                      • C
                        cym19906
                        最后由 编辑

                        可以聊一下合作吗?cym19906

                        1 条回复 最后回复 回复 引用 0
                        • 第一个帖子
                          最后一个帖子
                        皖ICP备16016415号-7
                        Powered by NodeBB | 鱼香ROS