[ROS2][fix] Fix multiple issues in converters
Goal
Fix issues in new converters. Bugs discovered using Ouster converter on dd bag.
Add config file for converters
Add a service to allow user to ask for a new computation of estimation parameters (rotation sense or/and angles clusters useful to estimate time and laser_id).
Changes
Fix issues in new converters
1. Rename variables
- InitEstimParamToDo -> RotSenseAndClustersEstimated / RotationSenseEstimated
- ClockwiseRotationBool -> RotationIsClockwise
- ClusteringAngles -> ClusterizeVerticalAngles
- notConverged -> hasConverged
- new_mean -> newMean
- angle_v -> vertAngle
- ClockwiseRotation -> IsRotationClockwise
- laser_id in ComputeLaserId function is removed
- isTimeValid -> timeIsValid
- nLasers -> nbLasers
- toPublish -> msg_sended
2. Do not estimate clusters for converters which already provide laser_id
3. Replace values by references when possible
4. Add missing const
5. Change double to int when possible
nbLasers and return of ComputeLaserId
6. Add check for too long frame (there was a too short frame).
This also ensures that the frame time is in the same unit as the point time
7. Remove extra spaces
8. Uniformize upper/lower cases
9. Remove return copy of ClusteringAngles @ FindVerticalAngles
10. Change type of DeviceIdMap and move DeviceId outside for loop of converters
Add service
Add two different services :
- EstimParams.srv to estimate again rotation duration and rotation sense, respectively useful for laser_id and time estimations. To be used with Raw or Robosense node.
- EstimSense.srv to estimate again rotation sense again. Useful for Velodyne and Ouster nodes which do not estimate laser_id.
Add config
Add conversion_config.yaml file, and changes the slam launchfiles.
Also fix some type issues in converters (remove const from PossibleFrequencies which is now a parameter).
Add the nb_thread parameter to all conversion nodes.
TODO
-
Add service to each converter to reset variables and relaunch the auto computation of the rotationDuration and the clusters -
Add parameter file for the user and call it in launch files -
Add nbthreads param for omp for loops
@jeanne.faure PTAL