UniversalRobots / Universal_Robots_Client_Library

A C++ library for accessing the UR interfaces that facilitate the use of UR robotic manipulators by external applications.
Apache License 2.0
117 stars 86 forks source link

Added watchdog configuration for the reverse socket #178

Closed urmahp closed 11 months ago

urmahp commented 11 months ago

This enables the possibility to configure the read timeout for the reverse socket running in the external control script

Separated control modes into realtime and non realtime to have different possible configurations for the watchdog

Added test to verify the changes

Updated test and examples to coincide with the new changes

codecov[bot] commented 11 months ago

Codecov Report

Patch coverage is 97.89% of modified lines.

Files Changed Coverage
src/ur/ur_driver.cpp 84.61%
include/ur_client_library/comm/control_mode.h 100.00%
...lude/ur_client_library/control/reverse_interface.h 100.00%
include/ur_client_library/ur/ur_driver.h 100.00%
src/control/reverse_interface.cpp 100.00%
src/ur/robot_receive_timeout.cpp 100.00%

:loudspeaker: Thoughts on this report? Let us know!.

urmahp commented 11 months ago

I have updated the PR based on your comments.

urrsk commented 11 months ago

We should also add a test, that verifies that the reverse interface timeout as well with in the expected time.

urmahp commented 11 months ago

We should also add a test, that verifies that the reverse interface timeout as well with in the expected time.

As the timeout is configured in the script the reverse interface will not timeout, the script will timeout. We could add a test that verifies that the script times out, but that would be a test under the UrDriver class, as it would require robot communication.

urrsk commented 11 months ago

We should also add a test, that verifies that the reverse interface timeout as well with in the expected time.

As the timeout is configured in the script the reverse interface will not timeout, the script will timeout. We could add a test that verifies that the script times out, but that would be a test under the UrDriver class, as it would require robot communication.

True. And yes that is a good idea

urmahp commented 11 months ago

I have updated the PR in relation to the comments and added a better test coverage of the changes.