Multi LiDAR를 위한 LiDAR 드라이버 세팅

Multi Lidar를 위한 LiDAR 드라이버 세팅

  • 압축 파일명: bpearl_only_rslidar_sdk.zip

  • multi_lidar 디렉토리의 bpearl_only_rslidar_sdk를 깃허브 주소를 참고하여 실행 시 Bpearl 센서 2대 동작 가능 Center LiDAR의 경우 FutureDrive ROS2 NIRO에서 실행시키는 기존 상태 그대로 사용

    colcon build  
    source install/setup.bash  
    ros2 launch rslidar_sdk start.py
  • Configuration: src/rslidar_sdk/config.yaml

    • Bpearl 1
      - driver:
      	  lidar_type: RSBP             #LiDAR type - RS16, RS32, RSBP, RSHELIOS, RSHELIOS_16P, RS128, RS80, RS48, RSP128, RSP80, RSP48, 
      								   #             RSM1, RSM1_JUMBO, RSM2, RSE1
      	  msop_port: 1990              #Msop port of lidar
      	  difop_port: 1991             #Difop port of lidar
      	  start_angle: 0               #Start angle of point cloud
      	  end_angle: 360               #End angle of point cloud 
      	  wait_for_difop: true
      	  min_distance: 0.2            #Minimum distance of point cloud
      	  max_distance: 200            #Maximum distance of point cloud
      	  use_lidar_clock: false       #True--Use the lidar clock as the message timestamp
      								   #False-- Use the system clock as the timestamp
      	  pcap_path: /home/robosense/lidar.pcap #The path of pcap file
      	ros:
      	  ros_frame_id: rslidar_left                           #Frame id of packet message and point cloud message
      	  ros_recv_packet_topic: /left/rslidar_packets          #Topic used to receive lidar packets from ROS
      	  ros_send_packet_topic: /left/rslidar_packets          #Topic used to send lidar packets through ROS
      	  ros_send_point_cloud_topic: /left/rslidar_points      #Topic used to send point cloud through ROS
      	  
      	  proto:
      	  point_cloud_recv_port: 60024                     
      	  point_cloud_send_port: 60024                     
      	  msop_recv_port: 60025                       
      	  msop_send_port: 60025                       
      	  difop_recv_port: 60026                      
      	  difop_send_port: 60026       
      	  point_cloud_send_ip: 192.168.1.202                   
      	  packet_send_ip: 192.168.1.202 
    • Bpearl 2
      - driver:
            lidar_type: RSBP             #LiDAR type - RS16, RS32, RSBP, RSHELIOS, RSHELIOS_16P, RS128, RS80, RS48, RSP128, RSP80, RSP48, 
                                         #             RSM1, RSM1_JUMBO, RSM2, RSE1
            msop_port: 2010              #Msop port of lidar
            difop_port: 2011             #Difop port of lidar
            start_angle: 0               #Start angle of point cloud
            end_angle: 360               #End angle of point cloud 
            wait_for_difop: true
            min_distance: 0.2            #Minimum distance of point cloud
            max_distance: 200            #Maximum distance of point cloud
            use_lidar_clock: false       #True--Use the lidar clock as the message timestamp
                                         #False-- Use the system clock as the timestamp
            pcap_path: /home/robosense/lidar.pcap #The path of pcap file
          ros:
            ros_frame_id: rslidar_right                           #Frame id of packet message and point cloud message
            ros_recv_packet_topic: /right/rslidar_packets          #Topic used to receive lidar packets from ROS
            ros_send_packet_topic: /right/rslidar_packets          #Topic used to send lidar packets through ROS
            ros_send_point_cloud_topic: /right/rslidar_points      #Topic used to send point cloud through ROS
            
            proto:
            point_cloud_recv_port: 60027                     
            point_cloud_send_port: 60027                     
            msop_recv_port: 60028                       
            msop_send_port: 60028                       
            difop_recv_port: 60029                      
            difop_send_port: 60029       
            point_cloud_send_ip: 192.168.1.204                 
            packet_send_ip: 192.168.1.204
Link to original

Multi LiDAR를 위한 FutureDrive ROS2 NIRO 코드 셋팅

Multi LiDAR를 위한 FutureDrive ROS2 NIRO 코드 셋팅

  • 압축 파일명: future_ros2.zip

sensor_kit.xacro

  • Left, right LiDAR 추가로 인한 left, right frame_id 추가
<xacro:VLP-16  
      parent="sensor_kit_base_link"  
      name="rslidar_left"  
      topic="/left/rslidar_points"  
      hz="10"  
      samples="220"  
      gpu="false"  
    >  
      <origin  
        xyz="${calibration['sensor_kit_base_link']['rslidar_left_base_link']['x']}  
             ${calibration['sensor_kit_base_link']['rslidar_left_base_link']['y']}  
             ${calibration['sensor_kit_base_link']['rslidar_left_base_link']['z']}"  
        rpy="${calibration['sensor_kit_base_link']['rslidar_left_base_link']['roll']}  
             ${calibration['sensor_kit_base_link']['rslidar_left_base_link']['pitch']}  
             ${calibration['sensor_kit_base_link']['rslidar_left_base_link']['yaw']}"  
      />  
    </xacro:VLP-16>

sensor_kit_calibration.yaml

  • frame_idbase_link 간 연결 관계 추가
rslidar_left_base_link:
	x: 0.0
	y: 0.629
	z: 0.42
	roll: -1.396267
	pitch: 0.0
	yaw: 0.0

robosense_lidar_node.launch.py

  • concatenate_data node 추가
nodes.append(
        ComposableNode(
            package="pointcloud_preprocessor",
            plugin="pointcloud_preprocessor::PointCloudConcatenateDataSynchronizerComponent",
            name="concatenate_data",
            remappings=[("output", "concat_3lidars/pointcloud")],
            parameters=[{
	            "input_topics": [
					"pointcloud_raw_ex","/left/rslidar_points","/right/rslidar_points",
					],
				"output_frame": LaunchConfiguration("base_frame"),
				}],
            extra_arguments=[{"use_intra_process_comms": LaunchConfiguration("use_intra_process")}],
        )
    )
Link to original