Skip to content

Commit

Permalink
optimize framing performance
Browse files Browse the repository at this point in the history
  • Loading branch information
Livox-Infra committed Nov 29, 2023
1 parent 852c147 commit b6ff7d1
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

All notable changes to this project will be documented in this file.

## [1.2.4]
### Fixed
- Optimize framing performance

## [1.2.3]
### Fixed
- Optimize framing logic and reduce CPU usage
Expand Down
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

Livox ROS Driver 2 is the 2nd-generation driver package used to connect LiDAR products produced by Livox, applicable for ROS (noetic recommended) and ROS2 (foxy or humble recommended).

**Note :**

As a debugging tool, Livox ROS Driver is not recommended for mass production but limited to test scenarios. You should optimize the code based on the original source to meet your various needs.

## 1. Preparation

### 1.1 OS requirements
Expand Down
3 changes: 0 additions & 3 deletions src/comm/pub_handler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -239,9 +239,6 @@ void PubHandler::RawDataProcess() {
}
raw_data = raw_packet_queue_.front();
raw_packet_queue_.pop_front();
if (raw_packet_queue_.size() < 3) { // reduce CPU usage
std::this_thread::sleep_for(std::chrono::microseconds(50));
}
}
uint32_t id = 0;
GetLidarId(raw_data.lidar_type, raw_data.handle, id);
Expand Down

0 comments on commit b6ff7d1

Please sign in to comment.