Writing a Plugin to LidarView (Ubuntu 20.04)

I’ve installed LidarView 4.5.0 using the superbuild method, including the SLAM plugin. I have a LiDAR device for which there is no existing support in LidarView. I want to create a new plugin to integrate my LiDAR device into LidarView. I have access to the SDK for my LiDAR device, but I’m unsure about the specific changes I need to make in the LidarView source folders.

I found the existing plugins’ source files at the following location: build/superbuild/lidarview/src/Plugins. This directory includes plugins for other devices, such as Livox, Hesai, etc.

Could someone guide me on how to proceed with adding a new plugin? Specifically, I would like to know:

  1. Which files or folders should I start with? Should I copy an existing plugin, like the Livox plugin, and modify it?
  2. What are the key components and modifications needed to create a new plugin using my device’s SDK?
  3. Any best practices or tips for integrating a new LiDAR device into LidarView?

Any help or pointers would be greatly appreciated!
@Timothee_Couble @Gatien_Ferret

Hi @Nerd,

Is the LiDAR SDK you are using publicly available ? If so, it would be great to contribute back the plugin.

We have an exemple with the minimal things we need to introduce in a new interpreter, which is located here.

Assuming you are locating your code in LidarViewSrc/Plugins, you may directly reference it in this CMakeLists.txt

A good exemple for a concrete use case may be the Leishen interpreter for MS-C16. For reference :

  • the source code of the plugin is located here
  • The spec from the manufacturer is here
  • The official ROS driver is here

I hope this helps,

Gatien

Thanks alot @Gatien_Ferret. I’ll look into those references and get back to you.

Do we have to make any changes in the GUI?? Like Qt5 file??

You shouldn’t have to. Unless of course you specifically want to update the layout of the app

Adding a plugin is to use a new lidar device in lidarview. So I need to update the GUI?

No, they are automatically scanned in the constructor of the configuration window ( and added in the StackedInterpreters variable )

I tried to integrate the sdk with the plugin and I’ve updated all the CMakeLists. But it is not working I don’t know where I went wrong. I have ros2 driver for the lidar I’m using. Can I use the driver to integrate with the plugin?? Still I’m not sure how to integrate it. I’m not much familiar with C++. Can you help me? Please

The ROS2 driver can serve as a reference implementation, but cannot directly be plugged within LidarView, even though receiving live ROS2 messages is a feature we would very much like to add as well, but that most likely requires a quite large development.

We propose dedicated support packages for this type of things (to help you develop, or even develop the plugin on our side and deliver it to you).

They may be purchased directly here, but you may also contact us at kitware@kitware.fr for further info (we may have a slow response time in the following weeks due to vacation).

Is the SDK / ROS2 driver you are tring to implement publicly available ?

Got it. No, the SDK/ROS2 driver is not publicly available. I can tell how the SDK is implemented so you can give me an idea about how I can integrate the SDK as a plugin. With this example, https://gitlab.kitware.com/LidarView/lidarview-core/-/tree/master/Examples/Plugins/InterpreterExample?ref_type=heads.