Slamtec c1 support added

Ive created a fork of Ajasra’s SlamtecChop too include the 2.1 drivers and C1 support. Currently I have only tested on Slamtec C1 with usb connection.

There are a number of anomalies with the c1 device, you cant set motor speed, the library now only supports dense_boost. Ive made it so you dont have too do all the visual studio linking.
The operator will run at 10fps, so it is best to run in a seperate instance and use something like touchin / out chop to share too your master application. I will add a release for the driver at some point so you dont have too go through the drama of compiling.

Im not sure this should be merged into the main branch yet until its tested on various devices. The current master (apparently) does that already for A series and S series.

2 Likes

That sounds like a great update! Adding 2.1 drivers and C1 support should make integration smoother. The 10fps operator workaround is smart—looking forward to your driver release for easier setup! :rocket:

@asterix I’m looking forward to the release the has the driver already compiled, thanks for your work on this!

Is anyone familiar with the real world results of using the C1 with its 0.72° Angular Resolution vs a S2/S3 with their 0.12° Angular Resolution? For example, if the sensor was used to gather input from a 10 ft x 10 ft area would the 0.60° decrease in angular resolution be much of an improvement?

Trying this branch with a C1 and I am unable to get it to work.

I compiled with VS2022 (unable to download 2019). Pretty sure I did that correctly, but its been about 3 years since I’ve compiled with VS, so its possible I did something wrong.
– I placed the rplidar sdk inside of the slamtec folder and compiled from there.
– I ended up with a debug folder and opened the TOE.
– The C++ chop shows an error “failed to load plugin”

Any clues?

̶I̶f̶ ̶a̶n̶y̶o̶n̶e̶ ̶c̶a̶n̶ ̶p̶r̶o̶v̶i̶d̶e̶ ̶a̶ ̶p̶r̶e̶c̶o̶m̶p̶i̶l̶e̶d̶ ̶v̶e̶r̶s̶i̶o̶n̶ ̶p̶l̶e̶a̶s̶e̶,̶ ̶I̶’̶d̶ ̶b̶e̶ ̶v̶e̶r̶y̶ ̶g̶r̶a̶t̶e̶f̶u̶l̶.̶

Edit: I compiled the solution with VS2019 (latest update).
TD loads the plugin but just as with Ajasra’s original version, nothing happens, no matter which baud rate I select, it just doesnt see the device.

Using RPLIDAR C1 over USB with the CP210x thingy which for me is on COM7, which I also put in the properties panel.
Works fine in robostudio

SlamtecCHOP.zip (308.6 KB)

After looking around in the VS project, I noticed the baud rate options include 460800 (the rate for the C1 specifically), but it didn’t show in the parameters of the TD plugin somehow :man_shrugging:

then in parameters.cpp I changed the line:
bw.defaultValue = “1000000”; to bw.defaultValue = “460800”;
and re-built the solution, and now its there in the parameters and the lidar actually works! :smiley:

But TD stalls to ~10fps, I guess because everything runs in the main thread.
Seems like the upstream project already had this on the todo list in RPLidarDevice.cpp but not sure if that is actively developed.

@asterix maybe you can reach out to the dev and collaborate? :face_holding_back_tears:

compiled version of the modification:
SlamtecCHOP.zip (308.6 KB)

Brute force workaround for the lack of threading is to encapsulate the CHOP in a tox and run it in TouchEngine, then the main project stays at 60fps.

SlamtecLidar.tox (1.4 KB)

2 Likes

So far so good, 2 instances on USB are working fine with TouchEngine and tox. Thank you for the solution!

Hello,
is anyone else experiencing the issue that scan points remain in the data i.e. the trail of a person is visible even after the person has left?

Using @incognites compiled version