Livox-SDK / livox_ros_driver2

Livox device driver under Ros(Compatible with ros and ros2), support Lidar HAP and Mid-360.
Other
200 stars 161 forks source link

multi lidar time synchronization #43

Open h-gokul opened 1 year ago

h-gokul commented 1 year ago

I am able to use this driver for a single lidar setup and publish point clouds. However, to increase the FOV, I have two hap lidars fit next to each other. They arent extrinsically calibrated yet. I want the data to be published in a single topic, therefore I will set the multi_topic flag accordingly. I would like to know if this driver can time synchronize the pointclouds by default when setting up two lidars.

This is the config file

{
"lidar_summary_info" : {
    "lidar_type": 8
    },
"HAP": {
    "lidar_net_info" : {
        "cmd_data_port": 56000,
        "push_msg_port": 0,
        "point_data_port": 57000,
        "imu_data_port": 58000,
        "log_data_port": 59000
        },
    "host_net_info" : {
        "cmd_data_ip" : "192.168.1.5",
        "cmd_data_port": 56000,
        "push_msg_ip": "",
        "push_msg_port": 0,
        "point_data_ip": "192.168.1.5",
        "point_data_port": 57000,
        "imu_data_ip" : "192.168.1.5",
        "imu_data_port": 58000,
        "log_data_ip" : "",
        "log_data_port": 59000
        }
},
"HAP": {
    "lidar_net_info" : {
        "cmd_data_port": 56000,
        "push_msg_port": 0,
        "point_data_port": 57000,
        "imu_data_port": 58000,
        "log_data_port": 59000
        },
    "host_net_info" : {
        "cmd_data_ip" : "192.168.1.5",
        "cmd_data_port": 56000,
        "push_msg_ip": "",
        "push_msg_port": 0,
        "point_data_ip": "192.168.1.5",
        "point_data_port": 57000,
        "imu_data_ip" : "192.168.1.5",
        "imu_data_port": 58000,
        "log_data_ip" : "",
        "log_data_port": 59000
        }
},
"lidar_configs" : [
    {
    "ip" : "192.168.1.100",
    "pcl_data_type" : 1,
    "pattern_mode" : 0,
    "extrinsic_parameter" : {
        "roll": 0.0,
        "pitch": 0.0,
        "yaw": 0.0,
        "x": 0,
        "y": 0,
        "z": 0
        }
    },
    {
    "ip" : "192.168.1.101",
    "pcl_data_type" : 1,
    "pattern_mode" : 0,
    "extrinsic_parameter" : {
        "roll": 0.0,
        "pitch": 0.0,
        "yaw": 0.0,
        "x": 0,
        "y": 0,
        "z": 0
        }
    }
]
}
KimHyung commented 1 year ago

I used messge_filter to sync time when i merged point_cloud.

you can try this pointcloud_merger node to merge pointclouds with time_sync.

h-gokul commented 1 year ago

Thanks for your response. To clarify, I would like to obtain capture time synchronization between both lidar devices than just stitching the point clouds with a message filter