Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
slam_toolbox::SlamToolbox Class Referenceabstract

#include <slam_toolbox_common.hpp>

Inheritance diagram for slam_toolbox::SlamToolbox:
Inheritance graph
[legend]

Public Member Functions

 SlamToolbox (ros::NodeHandle &nh)
 
 ~SlamToolbox ()
 

Protected Member Functions

virtual karto::LocalizedRangeScanaddScan (karto::LaserRangeFinder *laser, const sensor_msgs::LaserScan::ConstPtr &scan, karto::Pose2 &karto_pose)
 
karto::LocalizedRangeScanaddScan (karto::LaserRangeFinder *laser, PosedScan &scanWPose)
 
virtual bool deserializePoseGraphCallback (slam_toolbox_msgs::DeserializePoseGraph::Request &req, slam_toolbox_msgs::DeserializePoseGraph::Response &resp)
 
karto::LaserRangeFindergetLaser (const sensor_msgs::LaserScan::ConstPtr &scan)
 
karto::LocalizedRangeScangetLocalizedRangeScan (karto::LaserRangeFinder *laser, const sensor_msgs::LaserScan::ConstPtr &scan, karto::Pose2 &karto_pose)
 
bool isPaused (const PausedApplication &app)
 
virtual void laserCallback (const sensor_msgs::LaserScan::ConstPtr &scan)=0
 
void loadPoseGraphByParams (ros::NodeHandle &nh)
 
void loadSerializedPoseGraph (std::unique_ptr< karto::Mapper > &, std::unique_ptr< karto::Dataset > &)
 
bool mapCallback (nav_msgs::GetMap::Request &req, nav_msgs::GetMap::Response &res)
 
bool pauseNewMeasurementsCallback (slam_toolbox_msgs::Pause::Request &req, slam_toolbox_msgs::Pause::Response &resp)
 
void publishPose (const karto::Pose2 &pose, const karto::Matrix3 &cov, const ros::Time &t)
 
void publishTransformLoop (const double &transform_publish_period)
 
void publishVisualizations ()
 
virtual bool serializePoseGraphCallback (slam_toolbox_msgs::SerializePoseGraph::Request &req, slam_toolbox_msgs::SerializePoseGraph::Response &resp)
 
void setParams (ros::NodeHandle &nh)
 
void setROSInterfaces (ros::NodeHandle &node)
 
void setSolver (ros::NodeHandle &private_nh_)
 
tf2::Stamped< tf2::TransformsetTransformFromPoses (const karto::Pose2 &pose, const karto::Pose2 &karto_pose, const ros::Time &t, const bool &update_reprocessing_transform)
 
bool shouldProcessScan (const sensor_msgs::LaserScan::ConstPtr &scan, const karto::Pose2 &pose)
 
bool shouldStartWithPoseGraph (std::string &filename, geometry_msgs::Pose2D &pose, bool &start_at_dock)
 
bool updateMap ()
 

Protected Attributes

std::string base_frame_
 
std::unique_ptr< loop_closure_assistant::LoopClosureAssistantclosure_assistant_
 
std::unique_ptr< karto::Datasetdataset_
 
bool enable_interactive_mode_
 
bool first_measurement_
 
std::unique_ptr< laser_utils::LaserAssistantlaser_assistant_
 
std::map< std::string, laser_utils::LaserMetadatalasers_
 
nav_msgs::GetMap::Response map_
 
std::string map_frame_
 
std::string map_name_
 
std::unique_ptr< map_saver::MapSavermap_saver_
 
tf2::Transform map_to_odom_
 
boost::mutex map_to_odom_mutex_
 
ros::Duration minimum_time_interval_
 
ros::NodeHandle nh_
 
std::string odom_frame_
 
std::unique_ptr< pose_utils::GetPoseHelperpose_helper_
 
boost::mutex pose_mutex_
 
ros::Publisher pose_pub_
 
double position_covariance_scale_
 
std::unique_ptr< karto::Pose2process_near_pose_
 
ProcessType processor_type_
 
tf2::Transform reprocessing_transform_
 
double resolution_
 
std::unique_ptr< tf2_ros::MessageFilter< sensor_msgs::LaserScan > > scan_filter_
 
std::unique_ptr< message_filters::Subscriber< sensor_msgs::LaserScan > > scan_filter_sub_
 
std::unique_ptr< laser_utils::ScanHolderscan_holder_
 
std::string scan_topic_
 
std::unique_ptr< mapper_utils::SMappersmapper_
 
boost::mutex smapper_mutex_
 
boost::shared_ptr< karto::ScanSolversolver_
 
pluginlib::ClassLoader< karto::ScanSolversolver_loader_
 
ros::ServiceServer ssDesserialize_
 
ros::ServiceServer ssMap_
 
ros::ServiceServer ssPauseMeasurements_
 
ros::ServiceServer ssSerialize_
 
ros::Publisher sst_
 
ros::Publisher sstm_
 
PausedState state_
 
std::unique_ptr< tf2_ros::Buffertf_
 
ros::Duration tf_buffer_dur_
 
std::unique_ptr< tf2_ros::TransformBroadcastertfB_
 
std::unique_ptr< tf2_ros::TransformListenertfL_
 
std::vector< std::unique_ptr< boost::thread > > threads_
 
int throttle_scans_
 
ros::Duration transform_timeout_
 
double yaw_covariance_scale_
 

Detailed Description

Definition at line 55 of file slam_toolbox_common.hpp.

Constructor & Destructor Documentation

◆ SlamToolbox()

slam_toolbox::SlamToolbox::SlamToolbox ( ros::NodeHandle nh)

Definition at line 28 of file slam_toolbox_common.cpp.

◆ ~SlamToolbox()

slam_toolbox::SlamToolbox::~SlamToolbox ( )

Definition at line 65 of file slam_toolbox_common.cpp.

Member Function Documentation

◆ addScan() [1/2]

karto::LocalizedRangeScan * slam_toolbox::SlamToolbox::addScan ( karto::LaserRangeFinder laser,
const sensor_msgs::LaserScan::ConstPtr &  scan,
karto::Pose2 karto_pose 
)
protectedvirtual

Reimplemented in slam_toolbox::LocalizationSlamToolbox.

Definition at line 476 of file slam_toolbox_common.cpp.

◆ addScan() [2/2]

karto::LocalizedRangeScan * slam_toolbox::SlamToolbox::addScan ( karto::LaserRangeFinder laser,
PosedScan &  scanWPose 
)
protected

Definition at line 467 of file slam_toolbox_common.cpp.

◆ deserializePoseGraphCallback()

bool slam_toolbox::SlamToolbox::deserializePoseGraphCallback ( slam_toolbox_msgs::DeserializePoseGraph::Request &  req,
slam_toolbox_msgs::DeserializePoseGraph::Response &  resp 
)
protectedvirtual

◆ getLaser()

karto::LaserRangeFinder * slam_toolbox::SlamToolbox::getLaser ( const sensor_msgs::LaserScan::ConstPtr &  scan)
protected

Definition at line 289 of file slam_toolbox_common.cpp.

◆ getLocalizedRangeScan()

karto::LocalizedRangeScan * slam_toolbox::SlamToolbox::getLocalizedRangeScan ( karto::LaserRangeFinder laser,
const sensor_msgs::LaserScan::ConstPtr &  scan,
karto::Pose2 karto_pose 
)
protected

Definition at line 391 of file slam_toolbox_common.cpp.

◆ isPaused()

bool slam_toolbox::SlamToolbox::isPaused ( const PausedApplication &  app)
protected

Definition at line 609 of file slam_toolbox_common.cpp.

◆ laserCallback()

virtual void slam_toolbox::SlamToolbox::laserCallback ( const sensor_msgs::LaserScan::ConstPtr &  scan)
protectedpure virtual

◆ loadPoseGraphByParams()

void slam_toolbox::SlamToolbox::loadPoseGraphByParams ( ros::NodeHandle nh)
protected

Definition at line 223 of file slam_toolbox_common.cpp.

◆ loadSerializedPoseGraph()

void slam_toolbox::SlamToolbox::loadSerializedPoseGraph ( std::unique_ptr< karto::Mapper > &  mapper,
std::unique_ptr< karto::Dataset > &  dataset 
)
protected

Definition at line 635 of file slam_toolbox_common.cpp.

◆ mapCallback()

bool slam_toolbox::SlamToolbox::mapCallback ( nav_msgs::GetMap::Request &  req,
nav_msgs::GetMap::Response &  res 
)
protected

Definition at line 574 of file slam_toolbox_common.cpp.

◆ pauseNewMeasurementsCallback()

bool slam_toolbox::SlamToolbox::pauseNewMeasurementsCallback ( slam_toolbox_msgs::Pause::Request &  req,
slam_toolbox_msgs::Pause::Response &  resp 
)
protected

Definition at line 592 of file slam_toolbox_common.cpp.

◆ publishPose()

void slam_toolbox::SlamToolbox::publishPose ( const karto::Pose2 pose,
const karto::Matrix3 cov,
const ros::Time t 
)
protected

Definition at line 549 of file slam_toolbox_common.cpp.

◆ publishTransformLoop()

void slam_toolbox::SlamToolbox::publishTransformLoop ( const double &  transform_publish_period)
protected

Definition at line 166 of file slam_toolbox_common.cpp.

◆ publishVisualizations()

void slam_toolbox::SlamToolbox::publishVisualizations ( )
protected

Definition at line 191 of file slam_toolbox_common.cpp.

◆ serializePoseGraphCallback()

bool slam_toolbox::SlamToolbox::serializePoseGraphCallback ( slam_toolbox_msgs::SerializePoseGraph::Request &  req,
slam_toolbox_msgs::SerializePoseGraph::Response &  resp 
)
protectedvirtual

Reimplemented in slam_toolbox::LocalizationSlamToolbox.

Definition at line 616 of file slam_toolbox_common.cpp.

◆ setParams()

void slam_toolbox::SlamToolbox::setParams ( ros::NodeHandle nh)
protected

Definition at line 108 of file slam_toolbox_common.cpp.

◆ setROSInterfaces()

void slam_toolbox::SlamToolbox::setROSInterfaces ( ros::NodeHandle node)
protected

Definition at line 147 of file slam_toolbox_common.cpp.

◆ setSolver()

void slam_toolbox::SlamToolbox::setSolver ( ros::NodeHandle private_nh_)
protected

Definition at line 83 of file slam_toolbox_common.cpp.

◆ setTransformFromPoses()

tf2::Stamped< tf2::Transform > slam_toolbox::SlamToolbox::setTransformFromPoses ( const karto::Pose2 pose,
const karto::Pose2 karto_pose,
const ros::Time t,
const bool &  update_reprocessing_transform 
)
protected

Definition at line 340 of file slam_toolbox_common.cpp.

◆ shouldProcessScan()

bool slam_toolbox::SlamToolbox::shouldProcessScan ( const sensor_msgs::LaserScan::ConstPtr &  scan,
const karto::Pose2 pose 
)
protected

Definition at line 415 of file slam_toolbox_common.cpp.

◆ shouldStartWithPoseGraph()

bool slam_toolbox::SlamToolbox::shouldStartWithPoseGraph ( std::string &  filename,
geometry_msgs::Pose2D &  pose,
bool &  start_at_dock 
)
protected

Definition at line 250 of file slam_toolbox_common.cpp.

◆ updateMap()

bool slam_toolbox::SlamToolbox::updateMap ( )
protected

Definition at line 313 of file slam_toolbox_common.cpp.

Member Data Documentation

◆ base_frame_

std::string slam_toolbox::SlamToolbox::base_frame_
protected

Definition at line 113 of file slam_toolbox_common.hpp.

◆ closure_assistant_

std::unique_ptr<loop_closure_assistant::LoopClosureAssistant> slam_toolbox::SlamToolbox::closure_assistant_
protected

Definition at line 131 of file slam_toolbox_common.hpp.

◆ dataset_

std::unique_ptr<karto::Dataset> slam_toolbox::SlamToolbox::dataset_
protected

Definition at line 124 of file slam_toolbox_common.hpp.

◆ enable_interactive_mode_

bool slam_toolbox::SlamToolbox::enable_interactive_mode_
protected

Definition at line 120 of file slam_toolbox_common.hpp.

◆ first_measurement_

bool slam_toolbox::SlamToolbox::first_measurement_
protected

Definition at line 120 of file slam_toolbox_common.hpp.

◆ laser_assistant_

std::unique_ptr<laser_utils::LaserAssistant> slam_toolbox::SlamToolbox::laser_assistant_
protected

Definition at line 128 of file slam_toolbox_common.hpp.

◆ lasers_

std::map<std::string, laser_utils::LaserMetadata> slam_toolbox::SlamToolbox::lasers_
protected

Definition at line 125 of file slam_toolbox_common.hpp.

◆ map_

nav_msgs::GetMap::Response slam_toolbox::SlamToolbox::map_
protected

Definition at line 139 of file slam_toolbox_common.hpp.

◆ map_frame_

std::string slam_toolbox::SlamToolbox::map_frame_
protected

Definition at line 113 of file slam_toolbox_common.hpp.

◆ map_name_

std::string slam_toolbox::SlamToolbox::map_name_
protected

Definition at line 113 of file slam_toolbox_common.hpp.

◆ map_saver_

std::unique_ptr<map_saver::MapSaver> slam_toolbox::SlamToolbox::map_saver_
protected

Definition at line 130 of file slam_toolbox_common.hpp.

◆ map_to_odom_

tf2::Transform slam_toolbox::SlamToolbox::map_to_odom_
protected

Definition at line 136 of file slam_toolbox_common.hpp.

◆ map_to_odom_mutex_

boost::mutex slam_toolbox::SlamToolbox::map_to_odom_mutex_
protected

Definition at line 137 of file slam_toolbox_common.hpp.

◆ minimum_time_interval_

ros::Duration slam_toolbox::SlamToolbox::minimum_time_interval_
protected

Definition at line 114 of file slam_toolbox_common.hpp.

◆ nh_

ros::NodeHandle slam_toolbox::SlamToolbox::nh_
protected

Definition at line 103 of file slam_toolbox_common.hpp.

◆ odom_frame_

std::string slam_toolbox::SlamToolbox::odom_frame_
protected

Definition at line 113 of file slam_toolbox_common.hpp.

◆ pose_helper_

std::unique_ptr<pose_utils::GetPoseHelper> slam_toolbox::SlamToolbox::pose_helper_
protected

Definition at line 129 of file slam_toolbox_common.hpp.

◆ pose_mutex_

boost::mutex slam_toolbox::SlamToolbox::pose_mutex_
protected

Definition at line 137 of file slam_toolbox_common.hpp.

◆ pose_pub_

ros::Publisher slam_toolbox::SlamToolbox::pose_pub_
protected

Definition at line 109 of file slam_toolbox_common.hpp.

◆ position_covariance_scale_

double slam_toolbox::SlamToolbox::position_covariance_scale_
protected

Definition at line 118 of file slam_toolbox_common.hpp.

◆ process_near_pose_

std::unique_ptr<karto::Pose2> slam_toolbox::SlamToolbox::process_near_pose_
protected

Definition at line 141 of file slam_toolbox_common.hpp.

◆ processor_type_

ProcessType slam_toolbox::SlamToolbox::processor_type_
protected

Definition at line 140 of file slam_toolbox_common.hpp.

◆ reprocessing_transform_

tf2::Transform slam_toolbox::SlamToolbox::reprocessing_transform_
protected

Definition at line 142 of file slam_toolbox_common.hpp.

◆ resolution_

double slam_toolbox::SlamToolbox::resolution_
protected

Definition at line 117 of file slam_toolbox_common.hpp.

◆ scan_filter_

std::unique_ptr<tf2_ros::MessageFilter<sensor_msgs::LaserScan> > slam_toolbox::SlamToolbox::scan_filter_
protected

Definition at line 108 of file slam_toolbox_common.hpp.

◆ scan_filter_sub_

std::unique_ptr<message_filters::Subscriber<sensor_msgs::LaserScan> > slam_toolbox::SlamToolbox::scan_filter_sub_
protected

Definition at line 107 of file slam_toolbox_common.hpp.

◆ scan_holder_

std::unique_ptr<laser_utils::ScanHolder> slam_toolbox::SlamToolbox::scan_holder_
protected

Definition at line 132 of file slam_toolbox_common.hpp.

◆ scan_topic_

std::string slam_toolbox::SlamToolbox::scan_topic_
protected

Definition at line 113 of file slam_toolbox_common.hpp.

◆ smapper_

std::unique_ptr<mapper_utils::SMapper> slam_toolbox::SlamToolbox::smapper_
protected

Definition at line 123 of file slam_toolbox_common.hpp.

◆ smapper_mutex_

boost::mutex slam_toolbox::SlamToolbox::smapper_mutex_
protected

Definition at line 137 of file slam_toolbox_common.hpp.

◆ solver_

boost::shared_ptr<karto::ScanSolver> slam_toolbox::SlamToolbox::solver_
protected

Definition at line 146 of file slam_toolbox_common.hpp.

◆ solver_loader_

pluginlib::ClassLoader<karto::ScanSolver> slam_toolbox::SlamToolbox::solver_loader_
protected

Definition at line 145 of file slam_toolbox_common.hpp.

◆ ssDesserialize_

ros::ServiceServer slam_toolbox::SlamToolbox::ssDesserialize_
protected

Definition at line 110 of file slam_toolbox_common.hpp.

◆ ssMap_

ros::ServiceServer slam_toolbox::SlamToolbox::ssMap_
protected

Definition at line 110 of file slam_toolbox_common.hpp.

◆ ssPauseMeasurements_

ros::ServiceServer slam_toolbox::SlamToolbox::ssPauseMeasurements_
protected

Definition at line 110 of file slam_toolbox_common.hpp.

◆ ssSerialize_

ros::ServiceServer slam_toolbox::SlamToolbox::ssSerialize_
protected

Definition at line 110 of file slam_toolbox_common.hpp.

◆ sst_

ros::Publisher slam_toolbox::SlamToolbox::sst_
protected

Definition at line 109 of file slam_toolbox_common.hpp.

◆ sstm_

ros::Publisher slam_toolbox::SlamToolbox::sstm_
protected

Definition at line 109 of file slam_toolbox_common.hpp.

◆ state_

PausedState slam_toolbox::SlamToolbox::state_
protected

Definition at line 138 of file slam_toolbox_common.hpp.

◆ tf_

std::unique_ptr<tf2_ros::Buffer> slam_toolbox::SlamToolbox::tf_
protected

Definition at line 104 of file slam_toolbox_common.hpp.

◆ tf_buffer_dur_

ros::Duration slam_toolbox::SlamToolbox::tf_buffer_dur_
protected

Definition at line 114 of file slam_toolbox_common.hpp.

◆ tfB_

std::unique_ptr<tf2_ros::TransformBroadcaster> slam_toolbox::SlamToolbox::tfB_
protected

Definition at line 106 of file slam_toolbox_common.hpp.

◆ tfL_

std::unique_ptr<tf2_ros::TransformListener> slam_toolbox::SlamToolbox::tfL_
protected

Definition at line 105 of file slam_toolbox_common.hpp.

◆ threads_

std::vector<std::unique_ptr<boost::thread> > slam_toolbox::SlamToolbox::threads_
protected

Definition at line 135 of file slam_toolbox_common.hpp.

◆ throttle_scans_

int slam_toolbox::SlamToolbox::throttle_scans_
protected

Definition at line 115 of file slam_toolbox_common.hpp.

◆ transform_timeout_

ros::Duration slam_toolbox::SlamToolbox::transform_timeout_
protected

Definition at line 114 of file slam_toolbox_common.hpp.

◆ yaw_covariance_scale_

double slam_toolbox::SlamToolbox::yaw_covariance_scale_
protected

Definition at line 119 of file slam_toolbox_common.hpp.


The documentation for this class was generated from the following files:


slam_toolbox
Author(s): Steve Macenski
autogenerated on Thu Jan 11 2024 03:37:56