Skip to content

Commit

Permalink
Change cpt_pointlaser_loc_ros::HALTakeMeasurement to std_srvs::Empty
Browse files Browse the repository at this point in the history
This way, the modules that use `cpt_pointlaser_loc_ros` do not need to build a custom empty message type.
  • Loading branch information
francescomilano172 committed Nov 6, 2020
1 parent a3db044 commit d78bfbe
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@
#include <kindr/minimal/quat-transformation.h>
#include <ros/ros.h>
#include <std_msgs/Int16.h>
#include <std_srvs/Empty.h>
#include <tf/transform_listener.h>

#include <Eigen/Geometry>

#include "cpt_pointlaser_loc_ros/HALTakeMeasurement.h"
#include "cpt_pointlaser_loc_ros/HighAccuracyLocalization.h"

namespace cad_percept {
Expand Down Expand Up @@ -53,8 +53,7 @@ class MabiLocalizer {
/// \return True if the measurements could be successfully taken; false otherwise (e.g., if the
/// initialization of the HAL routine, required when no previous measurements were taken, is not
/// successful.
bool takeMeasurement(cpt_pointlaser_loc_ros::HALTakeMeasurement::Request &request,
cpt_pointlaser_loc_ros::HALTakeMeasurement::Response &response);
bool takeMeasurement(std_srvs::Empty::Request &request, std_srvs::Empty::Response &response);
///
/// \brief Performs the actual HAL routine by optimizing over the factor graph previously built.
///
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,8 @@ bool MabiLocalizer::initializeHALRoutine() {
return true;
}

bool MabiLocalizer::takeMeasurement(
cpt_pointlaser_loc_ros::HALTakeMeasurement::Request &request,
cpt_pointlaser_loc_ros::HALTakeMeasurement::Response &response) {
bool MabiLocalizer::takeMeasurement(std_srvs::Empty::Request &request,
std_srvs::Empty::Response &response) {
// Initialize HAL routine if not previously done.
if (!initialized_hal_routine_) {
if (!initializeHALRoutine()) {
Expand Down

This file was deleted.

0 comments on commit d78bfbe

Please sign in to comment.