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

RobotHWGroup with aliased interfaces #138

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
6ecdde0
Adding RobotHWGroup, which maintains a group of RobotHW as if it were…
kphawkins Jan 8, 2014
ecbc3d3
Updated tests, added changes to infrastructure.
kphawkins Jan 8, 2014
398e3a0
Updated documentation for RobotHWGroup.
kphawkins Jan 8, 2014
bc0d586
Added NULL-checking for the new method added.
kphawkins Jan 9, 2014
f5b54c0
Modified hardware_interface to allow multiple RobotHW registered in a
kphawkins Jan 13, 2014
d6b9daa
Removed getHandles/registerHandles and reimplemented in concatManagers:
kphawkins Jan 17, 2014
1d835cd
Moved concatManagers to base class ResourceManager, updated Interface…
kphawkins Jan 18, 2014
05bb7fb
Removed implementation of RobotHWGroup and moved its implementation t…
kphawkins Jan 18, 2014
c0f9e08
InterfaceManager keeps track of how many interfaces are combined in a…
kphawkins Jan 18, 2014
53b7a97
Added incremental InterfaceManager:get<T>() call test, as per Adolfo'…
kphawkins Jan 18, 2014
4ce12bd
Adding multi_controller.h, an extension of controller.h which allows …
kphawkins Jan 20, 2014
bcaad43
Adding new tests to test loading multiple different interfaces into a…
kphawkins Jan 20, 2014
613f30d
Added Controller2/3/4 for different numbers of interfaces.
kphawkins Jan 20, 2014
bdc2836
Merge branch 'hydro-devel' into hydro-devel-multi-iface
kphawkins Jul 20, 2014
b068bbb
Merge pull request #176 from bulwahn/hydro-devel
Jul 30, 2014
d3b838b
Adding PosVelAccJointInterface, a JointHandle which also allows for c…
kphawkins Aug 19, 2014
bdeaeb4
Merge branch 'hydro-add-pva-joint-iface' into hydro-devel-multi-iface
kphawkins Aug 19, 2014
841123a
Making ControllerInfo::hardware_interface a set
kphawkins Aug 19, 2014
079af40
Fixing hardware_interface reference in controller_manager_gui
kphawkins Aug 21, 2014
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ class Controller: public ControllerBase
{
ROS_ERROR("This controller requires a hardware interface of type '%s'."
" Make sure this is registered in the hardware_interface::RobotHW class.",
getHardwareInterfaceType().c_str());
getHardwareInterfaceTypes().begin()->c_str());
return false;
}

Expand All @@ -130,9 +130,11 @@ class Controller: public ControllerBase
return true;
}

virtual std::string getHardwareInterfaceType() const
virtual std::set<std::string> getHardwareInterfaceTypes() const
{
return hardware_interface::internal::demangledTypeName<T>();
std::set<std::string> ret_types;
ret_types.insert(hardware_interface::internal::demangledTypeName<T>());
return ret_types;
}

private:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,24 @@ class ControllerBase
/** \name Non Real-Time Safe Functions
*\{*/

/// Get the name of this controller's hardware interface type
virtual std::string getHardwareInterfaceType() const = 0;
/// Get the names of the hardware interface types this controller uses
virtual std::set<std::string> getHardwareInterfaceTypes() const = 0;

/// Get the single name of the hardware interface this controller uses
virtual std::string getHardwareInterfaceType()
{
std::set<std::string> types = getHardwareInterfaceTypes();

if(types.size() == 0) {
ROS_WARN("This controller has no interface type!");
return std::string("");
}

if(types.size() > 1)
ROS_WARN("This controller has more than one interface type!"
"Use 'getHardwareInterfaceTypes' instead.");
return *(types.begin());
}

/** \brief Request that the controller be initialized
*
Expand Down
Loading