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

Use system tool to ping connection of a sick scanner #109

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

LotfiZ
Copy link

@LotfiZ LotfiZ commented Sep 19, 2022

Context

In some applications, we need to restart the scanners (from a PLC) without necessary restart the unit that run ROS driver.

Actual Behavior

If we restart the scanners while the ROS driver is running, the actual behavior is that no data are output because there is no way to check if the connection is dropped so the node is getting stuck. This is explained here : #79, #95.

Feature Behavior

From #79, @puck-fzi gave some options to implement a watchdog, so i tried to implement the "easier" one but not the best i concede. However, in our case its working!

So i used the system tool to ping the IP address of the scanner in a separate thread and check if a packet is received or not. If its not the case, shutdown the node and after that you can respawn with specific tag in a launch file or maybe with another way. The objective here is to check for a disconnection while the ROS driver is running.

Finally, i dont know if this pull could be merged to the principal branch but it could be useful for people who had the same issue.

Thank you!

@lenpuc
Copy link
Collaborator

lenpuc commented Jan 10, 2023

Hi Thanks for contributing.

I will have a look through it. The feature might be useful for different applications.
Thanks

@lenpuc
Copy link
Collaborator

lenpuc commented Apr 4, 2023

For now, I will not integrate it into the main branch, however, I am leaving this PR open, so other people can see and use it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants