Skip to main content

SolveIKQueries Class

Declaration

class moveit_pro::behaviors::SolveIKQueries { ... }

Included Headers

#include <solve_ik_queries.hpp>

Base class

classServiceClientBehaviorBase<ServiceT>

A base class for behaviors which need to send a request to a ROS service client and wait for a result. More...

Public Constructors Index

SolveIKQueries (const std::string &name, const BT::NodeConfiguration &config, const std::shared_ptr< BehaviorContext > &shared_resources)
SolveIKQueries (const std::string &name, const BT::NodeConfiguration &config, const std::shared_ptr< moveit_pro::behaviors::BehaviorContext > &shared_resources, std::unique_ptr< ClientInterfaceBase< GetPlanningScene > > client_interface)

Private Member Functions Index

tl::expected< std::string, std::string >getServiceName () override

User-provided function to get the name of the service when initializing the service client. More...

tl::expected< GetPlanningScene::Request, std::string >createRequest () override

Creates a service request message. More...

tl::expected< bool, std::string >processResponse (const GetPlanningScene::Response &response) override

Given the planning scene, extract the robot's current joint state and then use that as the initial pose for solving the IK queries. More...

std::shared_future< tl::expected< bool, std::string > > &getFuture () override

Classes derived from AsyncBehaviorBase must implement getFuture() so that it returns a shared_future class member. More...

Private Member Attributes Index

std::shared_future< tl::expected< bool, std::string > >future_

Holds the result of calling the service asynchronously. More...

Public Static Functions Index

static BT::PortsListprovidedPorts ()
static BT::KeyValueVectormetadata ()

Description

Use IK to see if the robot's end effector can be moved to a list of poses. The robot's current joint state is used as the initial state for IK.

Data Port NamePort TypeObject Type
joint_group_nameInputstd::string
target_posesInputstd::vector<geometry_msgs::msg::PoseStamped>
timeoutInputdouble
check_collisionsInputbool
ik_query_resultsOutputstd::vector<bool>

Definition at line 30 of file solve_ik_queries.hpp.

Public Constructors

SolveIKQueries()

moveit_pro::behaviors::SolveIKQueries::SolveIKQueries (const std::string & name, const BT::NodeConfiguration & config, const std::shared_ptr< BehaviorContext > & shared_resources)

Declaration at line 33 of file solve_ik_queries.hpp, definition at line 61 of file solve_ik_queries.cpp.

SolveIKQueries()

moveit_pro::behaviors::SolveIKQueries::SolveIKQueries (const std::string & name, const BT::NodeConfiguration & config, const std::shared_ptr< moveit_pro::behaviors::BehaviorContext > & shared_resources, std::unique_ptr< ClientInterfaceBase< GetPlanningScene > > client_interface)

Declaration at line 36 of file solve_ik_queries.hpp, definition at line 68 of file solve_ik_queries.cpp.

Private Member Functions

createRequest()

tl::expected< GetPlanningScene::Request, std::string > moveit_pro::behaviors::SolveIKQueries::createRequest ()
virtual

Creates a service request message.

Returns

Returns an instance of GetPlanningScene::Request.

Declaration at line 51 of file solve_ik_queries.hpp, definition at line 106 of file solve_ik_queries.cpp.

getFuture()

std::shared_future< tl::expected< bool, std::string > > & moveit_pro::behaviors::SolveIKQueries::getFuture ()
inline virtual

Classes derived from AsyncBehaviorBase must implement getFuture() so that it returns a shared_future class member.

Definition at line 61 of file solve_ik_queries.hpp.

getServiceName()

tl::expected< std::string, std::string > moveit_pro::behaviors::SolveIKQueries::getServiceName ()
virtual

User-provided function to get the name of the service when initializing the service client.

Returns

Returns the name of the service. If not successful, returns an error message. Note that the criteria for success or failure is defined by the user's implementation of this function.

Declaration at line 45 of file solve_ik_queries.hpp, definition at line 101 of file solve_ik_queries.cpp.

processResponse()

tl::expected< bool, std::string > moveit_pro::behaviors::SolveIKQueries::processResponse (const GetPlanningScene::Response & response)

Given the planning scene, extract the robot's current joint state and then use that as the initial pose for solving the IK queries.

Parameters
response

The response from a service call that contains the planning scene msg.

Declaration at line 58 of file solve_ik_queries.hpp, definition at line 111 of file solve_ik_queries.cpp.

Private Member Attributes

future_

std::shared_future<tl::expected<bool, std::string> > moveit_pro::behaviors::SolveIKQueries::future_

Holds the result of calling the service asynchronously.

Definition at line 67 of file solve_ik_queries.hpp.

Public Static Functions

metadata()

BT::KeyValueVector moveit_pro::behaviors::SolveIKQueries::metadata ()
static

Declaration at line 42 of file solve_ik_queries.hpp, definition at line 93 of file solve_ik_queries.cpp.

providedPorts()

BT::PortsList moveit_pro::behaviors::SolveIKQueries::providedPorts ()
static

Declaration at line 40 of file solve_ik_queries.hpp, definition at line 75 of file solve_ik_queries.cpp.


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


Generated via doxygen2docusaurus 2.2.2 by Doxygen 1.9.8.