forked from UniversalRobots/Universal_Robots_Client_Library
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Tcp socket improvements (UniversalRobots#222)
Couple of improvements related to TCP communication: 1. the error handling in `tcp_server::readData` seems wrong since the error case should be when the number of bytes received is strictly negative and not equal to 0 2. added early disconnection in `tcp_socket::read` in case of permanent failure in order to ease failure detection 3. added robustness to `UrDriver::sendScript`: the program sending is now retried once after closing and reconnecting the secondary stream. This is the workaround described in UniversalRobots/Universal_Robots_ROS_Driver#459. It helps mitigate program sending issues when working with the UR ROS2 driver in headless mode. New tests added for 2 and 3. For 1 the debug output of `TCPServerTest::client_connections` seems to confirm the behaviour makes sense. We now see `client from FD <xx> sent a connection reset package` which is what I'd expect given the client willingly terminates connection.
- Loading branch information
1 parent
85fbc55
commit 881adb0
Showing
6 changed files
with
87 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters