From 63e40620bac29d880212f01d1ea5b645eccb19a9 Mon Sep 17 00:00:00 2001 From: Sai Kishor Kothakota Date: Tue, 21 May 2024 07:52:54 +0200 Subject: [PATCH] Apply suggestions from Bence's code review Co-authored-by: Bence Magyar --- hardware_interface/doc/hardware_interface_types_userdoc.rst | 2 +- hardware_interface/src/resource_manager.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hardware_interface/doc/hardware_interface_types_userdoc.rst b/hardware_interface/doc/hardware_interface_types_userdoc.rst index 478742bc15..d8338bf7a6 100644 --- a/hardware_interface/doc/hardware_interface_types_userdoc.rst +++ b/hardware_interface/doc/hardware_interface_types_userdoc.rst @@ -45,7 +45,7 @@ Hardware Groups ***************************** Hardware Component Groups serve as a critical organizational mechanism within complex systems, facilitating error handling and fault tolerance. By grouping related hardware components together, such as actuators within a manipulator, users can establish a unified framework for error detection and response. -Hardware Component Groups play a vital role in propagating errors across interconnected hardware components. For instance, in a manipulator system, grouping actuators together allows for error propagation. If one actuator fails within the group, the error can propagate to the other actuators, signaling a potential issue across the system. By default, the actuator errors are isolated to their own hardware component, allowing the rest to continue operation unaffected. In the provided ROS2 control configuration, the ```` tag within each ```` block signifies the grouping of hardware components, enabling error propagation mechanisms within the system. +Hardware Component Groups play a vital role in propagating errors across interconnected hardware components. For instance, in a manipulator system, grouping actuators together allows for error propagation. If one actuator fails within the group, the error can propagate to the other actuators, signaling a potential issue across the system. By default, the actuator errors are isolated to their own hardware component, allowing the rest to continue operation unaffected. In the provided ros2_control configuration, the ```` tag within each ```` block signifies the grouping of hardware components, enabling error propagation mechanisms within the system. Examples ***************************** diff --git a/hardware_interface/src/resource_manager.cpp b/hardware_interface/src/resource_manager.cpp index fa9053be93..d77f915eee 100644 --- a/hardware_interface/src/resource_manager.cpp +++ b/hardware_interface/src/resource_manager.cpp @@ -912,7 +912,7 @@ class ResourceStorage } // If it is anything other than OK, change the return type of the hardware group state // to the respective return type - if (value > hw_group_state_.at(group_name)) + if (value != return_type::OK) { hw_group_state_.at(group_name) = value; }