| Crates.io | unitree-lidar-l1-rust |
| lib.rs | unitree-lidar-l1-rust |
| version | 0.1.0 |
| created_at | 2025-07-08 08:28:21.83735+00 |
| updated_at | 2025-07-08 08:28:21.83735+00 |
| description | Rust wrapper for Unitree Lidar L1 SDK |
| homepage | https://github.com/godbrigero/Unilidar-SDK-Rust |
| repository | https://github.com/godbrigero/Unilidar-SDK-Rust |
| max_upload_size | |
| id | 1742196 |
| size | 940,411 |
As you know, the official SDK is not available for rust users since it it written in C++. This project is a wrapper for the official SDK that allows you to use the SDK in rust.
cargo add unitree-lidar-l1-rust
The static libraries are included in the published crate, so no additional setup is required!
git clone https://github.com/yourusername/unitree_lidar_l1_rust
cd unitree_lidar_l1_rust
cargo build
let mut reader = LidarReader::new("/dev/ttyUSB0", 0.0, 50.0).unwrap();
reader.start_lidar();
let mut stream = reader.into_stream();
while let Some(result) = stream.next() {
match result {
LidarResult::PointCloud(points) => {
println!("Point cloud: {:?}", points);
}
LidarResult::ImuReading(imu) => {
println!("IMU reading: {:?}", imu);
}
}
}
cargo build