Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shutdown when can not connect to sensor on startup in ROS2 (foxy/galactic) #214

Merged

Conversation

Samahu
Copy link
Contributor

@Samahu Samahu commented Sep 12, 2023

Related Issues & PRs

Summary of Changes

  • Shutdown node if failed to connect to the sensor on startup rather than hanging.

Validation

  • While sensor is properly wired launch ouster_ros through driver.launch.py or sensor.independent.launch.py
    • Verify the node configures and connects to the sensor as normal
  • Disconnect the sensor and then launch ouster_ros through driver.launch.py or sensor.independent.launch.py
    • Verify the node fails to connect and then shuts down as expected with an error message.
  • Validated by issue reporter.

Samahu and others added 22 commits February 20, 2023 13:39
* Update to the latest ouster sdk
* Forward multicast funcitonality + Other improvements and fixes
* Add service_msgs dependency to package.xml
* Correct sensor_mtp.launch for ros2 launch file format
* Move to most recent SDK update
* Declare and fill defaults for mtp paramters + fix uninitialzed compute_to_scan
* Launch file rename and README corrections
…ith latched topics (#102)

* Working port of latched metadata topic on ros2
* Update replay and record launch files to providing metadata file an optional parameter
* Remove extra white space in replay record command
* Undo changes to the metadata-qos-override
* minor code syntax improvements
* Add missing metadata topic when bag file isn't specified
* Use concise syntax and formatting
* Reverse logic for easier read
* Apply node transition if it exists
…parameters (#115)

* deprecate tf_prefix from os_cloud (#96)
Co-authored-by: Guillaume Doisy <[email protected]>

* Squashed commit of the following:
commit 6280bfa1178bdee4fe695cb4752efd5ff15279db
Author: Ussama Naal <[email protected]>
Date:   Fri Apr 28 07:54:34 2023 -0700
    Merge branch 'deprecate_tf_prefix'

commit 35f2fd2
Author: Guillaume Doisy <[email protected]>
Date:   Mon Apr 3 18:12:44 2023 +0100
    deprecate tf_prefix from os_cloud

* Update ChangeLog and package version
* Propagate the parameters to launch files
* Add a TODO note
---------

Co-authored-by: Guillaume Doisy <[email protected]>
…ocess (#108)

* Remove the use of static vars within components
* Resolve conflicts and update changelog and version
* Fix a typo 'instance'
…124)

* use static tf broadcaster for ros2 (#112)
* use separate params for tf frames
* send static transforms once
* Disable static transform publishers and update changelog and package version
* Disable rviz static transform publisher
* Remove rviz static transform publisher hack
* Remove left out variables
---------
Co-authored-by: Adam Aposhian <[email protected]>
#140)

* Switch from using ROS timers to thread for polling
* Specify param defaults for non-required params
* Factoring out Imu and Lidar packets handling
* Added os_driver which combines os_sensor and os_cloud +
Added required launch files +
Better abstraction of classes +
Simplified threading logic +
Added thread safe implemention of ring buffer (not hooked yet)
* Move down pragma once in the handlers
* Adding unit tests for the ThreadSafeRingBuffer
* Add one more case to the unit test of ThreadSafeRingBuffer
* Quick hook up of the ThreadSafeRingBuffer for os_sensor and os_driver
* Add an option to select the point_cloud frame
* Keep transforms in Lidar Frame by default with option to switch
* Formatting os_sensor and os_driver
* Provide support for parsing the community driver params file with approprite launch file
* Factor out tf transforms broadcast
* Formatting imu and lidar packet handlers
* Fix build issue
* Incorporate LaserScan message composition
* Refactor a bit and add the ability to process and publish point clouds and laser scans
* Restor os_cloud_node ability to process point clouds
* Parse proc_mask and hook to launch files and config
* Add support for the selecting IMU + create topics/subs when their respective flags enabled
* Reduce sync operations + restore sensor reset/reactivation
* Add the ability to override current qos settings
* Add minor note
* More detailed explanation about the IMG node
* Rename the file os_sensor_cloud_image_params to os_sensor_cloud_image_params.yaml and update corresponding launch files
* Expose use_system_default_qos parameter to xml launch file and use proper defaults
* Update minimal readme file and utilize os_driver by default +
add proc_mask to xml file +
Remove experminal marker from set_config and reset ros services
* Update CHANGELOG.rst and package version
* Apply && to accepted method of ThreadSafeRingBuffer +
nits and code formatting
* Add missing parameter declaration
* Re-formatting CHANGELOG a bit
* Added ImageProcessor to support IMG flag +
Define new argument scan_ring
* Expose scan_ring param and update relevant params description
* Added notes to size(), empty(), full()
* remove deprecated methods + naming nits
* Update ChangeLog + Fix load_metadata_from_file
* Try out building against Iron + revise sensor_mtp.launch
* Correct the params file name + document params
* Carry over fixes from foxy branch
* Update README.md to mention compatibilty mode
* Separately initialize vector elements
* Update changelog and package version
* Properly check for the write_text_to_file success
…er-ros-foxy (#163)

* Initialize point_cloud_frame with an empty string + and expose point_cloud_frame through launch xml files +
Remove unused/duplicate param definitions + Update descriptions
* Correct the name of the node to be activated for merged node
* Merge ouster-srvs into ouster-msgs package + Update dockerfile + Other fixes and code improvements
* Update launch file name within the dockerfile
* Update CHANGELOG.txt
* Update ouster_ros package version to highlight the breadking change due obseleting ouster_srvs
* Use angle brackets for external headers
* Remove unused library include
* Remove unused launch params in sensor_mtp.launch
* Fix the table of contents
* Quick implementtion of cloud destaggering
* Perform destaggering of point clouds during the copy + add a viz-reliable file + wrap all classes in ouster_ros
* Update changelog and version
* Reformat changelog
* Implemented UTC/TAI offset for the PTP timestamp mode
* Make sure all the timestamp values of LidarScan are utc corrected
* Modify timestamp values before producing a PointCloud
* Remove no longer needed comment from the Dockerfile
* Destagger timestamp when generating destagger point clouds
…-to-connect-to-lidar' into ROS-209-process-hangs-on-failure-to-connect-to-lidar-foxy
@Samahu Samahu added bug Something isn't working enhancement New feature or request labels Sep 12, 2023
@Samahu Samahu self-assigned this Sep 12, 2023
@Samahu Samahu changed the title Ros 209 process hangs on failure to connect to lidar foxy Shutdown when can not connect to sensor on startup in ROS2 (foxy/galactic) Sep 12, 2023
@Samahu Samahu marked this pull request as ready for review September 12, 2023 19:57
@Samahu Samahu merged commit 4a21509 into ros2-foxy Sep 12, 2023
2 checks passed
@Samahu Samahu deleted the ROS-209-process-hangs-on-failure-to-connect-to-lidar-foxy branch September 12, 2023 20:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants