78 const unsigned int dim = transmission_info.
actuators_.size();
79 if (expected_dim != dim)
82 "' of type '" << transmission_info.
type_ <<
83 "'. Expected " << expected_dim <<
" actuators, got " << dim <<
".");
91 const unsigned int dim = transmission_info.
joints_.size();
92 if (expected_dim != dim)
95 "' of type '" << transmission_info.
type_ <<
96 "'. Expected " << expected_dim <<
" joints, got " << dim <<
".");
104 TiXmlElement element(
"");
105 std::stringstream element_stream;
106 element_stream << element_str;
107 element_stream >> element;
112 const std::string& actuator_name,
113 const std::string& transmission_name,
118 const std::string& joint_name,
119 const std::string& transmission_name,
124 const std::string& joint_name,
125 const std::string& transmission_name,
130 const std::string& actuator_name,
131 const std::string& transmission_name,
136 const std::string& joint_name,
137 const std::string& transmission_name,
static TiXmlElement loadXmlElement(const std::string &element_str)
#define ROS_ERROR_STREAM_NAMED(name, args)
Abstract interface for loading transmission instances from configuration data.
std::shared_ptr< TransmissionLoader > TransmissionLoaderSharedPtr
Contains semantic info about a given transmission loaded from XML (URDF)
static ParseStatus getActuatorReduction(const TiXmlElement &parent_el, const std::string &actuator_name, const std::string &transmission_name, bool required, double &reduction)
Structs to hold transmission data loaded straight from XML (URDF).
static ParseStatus getActuatorRole(const TiXmlElement &parent_el, const std::string &actuator_name, const std::string &transmission_name, bool required, std::string &role)
static bool checkActuatorDimension(const TransmissionInfo &transmission_info, const unsigned int expected_dim)
static ParseStatus getJointRole(const TiXmlElement &parent_el, const std::string &joint_name, const std::string &transmission_name, bool required, std::string &role)
virtual TransmissionSharedPtr load(const TransmissionInfo &transmission_info)=0
static ParseStatus getJointReduction(const TiXmlElement &parent_el, const std::string &joint_name, const std::string &transmission_name, bool required, double &reduction)
std::shared_ptr< Transmission > TransmissionSharedPtr
std::vector< ActuatorInfo > actuators_
static ParseStatus getJointOffset(const TiXmlElement &parent_el, const std::string &joint_name, const std::string &transmission_name, bool required, double &offset)
virtual ~TransmissionLoader()=default
std::vector< JointInfo > joints_
static bool checkJointDimension(const TransmissionInfo &transmission_info, const unsigned int expected_dim)