Skip to content

Commit

Permalink
Merge pull request #515 from robotology/fix/vel2
Browse files Browse the repository at this point in the history
Fix handling of velocityControlImplementationType option in gazebo_yarp_controlboard
  • Loading branch information
traversaro authored Sep 22, 2020
2 parents c042735 + 6abbdd5 commit 52491d6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugins/controlboard/src/ControlBoardDriver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1046,11 +1046,11 @@ bool GazeboYarpControlBoardDriver::setPIDsForGroup_VELOCITY(std::vector<std::str

// Check velocityControlImplementationType value
// If not present, default to direct_velocity_pid for now
if (m_pluginParameters.find("velocityControlImplementationType").isNull()) {
if (pidGroup.find("velocityControlImplementationType").isNull()) {
yWarning("VELOCITY_CONTROL: 'velocityControlImplementationType' param missing. "
" Using the default value of 'direct_velocity_pid', but the parameter will be compulsory gazebo-yarp-plugins 4.");
} else {
std::string velocityControlImplementationType = m_pluginParameters.find("velocityControlImplementationType").toString();
std::string velocityControlImplementationType = pidGroup.find("velocityControlImplementationType").toString();

if (velocityControlImplementationType == "direct_velocity_pid") {
m_velocity_control_type = DirectVelocityPID;
Expand Down

0 comments on commit 52491d6

Please sign in to comment.