Package Summary
Tags | No category tags. |
Version | 0.0.0 |
License | TODO: License declaration |
Build type | AMENT_CMAKE |
Use | RECOMMENDED |
Repository Summary
Description | ROS2 navigaiton tutorials and do quadruped robot |
Checkout URI | https://github.com/duyongquan/openrobotics.git |
VCS Type | git |
VCS Version | main |
Last Updated | 2024-01-16 |
Dev Status | UNKNOWN |
Released | UNRELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (-)
Good First Issues (-) Pull Requests to Review (-) |
Package Description
Additional Links
Maintainers
- quan
Authors
1 tutorial 1(member_functions_test)
1.1 功能介绍
客户端fibonacci请求,服务器fibonacci生成fibonacci数据
fibonacci: 1, 2, 3, 5, 8,13, …
1.2 代码
头文件tutorials_action_demo1_member_functions.hpp
class MinimalActionClient : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ClientGoalHandle<Fibonacci>;
explicit MinimalActionClient(const rclcpp::NodeOptions & node_options = rclcpp::NodeOptions());
bool is_goal_done() const;
void send_goal();
private:
void goal_response_callback(GoalHandleFibonacci::SharedPtr goal_handle);
void feedback_callback(
GoalHandleFibonacci::SharedPtr,
const std::shared_ptr<const Fibonacci::Feedback> feedback);
void result_callback(const GoalHandleFibonacci::WrappedResult & result);
rclcpp_action::Client<Fibonacci>::SharedPtr client_ptr_;
rclcpp::TimerBase::SharedPtr timer_;
bool goal_done_;
}; // class MinimalActionClient
//#####################################################################################
class MinimalActionServer : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ServerGoalHandle<Fibonacci>;
explicit MinimalActionServer(const rclcpp::NodeOptions & options = rclcpp::NodeOptions());
private:
rclcpp_action::Server<Fibonacci>::SharedPtr action_server_;
rclcpp_action::GoalResponse handle_goal(
const rclcpp_action::GoalUUID & uuid,
std::shared_ptr<const Fibonacci::Goal> goal);
rclcpp_action::CancelResponse handle_cancel(
const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void execute(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void handle_accepted(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
}; // class MinimalActionServer
tutorials_action_demo1_member_functions.cpp
- ```cpp
- MinimalActionClient::MinimalActionClient(const rclcpp::NodeOptions & node_options)
- Node(“minimal_action_client”, node_options),
goal_done_(false)
{
this->client_ptr_ = rclcpp_action::create_client
( this->get_node_base_interface(), this->get_node_graph_interface(), this->get_node_logging_interface(), this->get_node_waitables_interface(), "fibonacci"); this->timer_ = this->create_wall_timer( std::chrono::milliseconds(500), std::bind(&MinimalActionClient::send_goal, this)); }
bool MinimalActionClient::is_goal_done() const { return this->goal_done_; }
void MinimalActionClient::send_goal() { using namespace std::placeholders;
this->timer_->cancel();
File truncated at 100 lines see the full file
Package Dependencies
Deps | Name |
---|---|
tutorials_msgs | |
rclcpp | |
std_msgs | |
rclcpp_action | |
ament_cmake | |
ament_lint_auto | |
ament_lint_common |
System Dependencies
Dependant Packages
Name | Deps |
---|---|
rosgpt | |
rosgpt | |
sjtu_drone_bringup | |
rosgpt_vision |
Launch files
Messages
Services
Plugins
Recent questions tagged action at Robotics Stack Exchange
Package Summary
Tags | No category tags. |
Version | 0.0.0 |
License | TODO: License declaration |
Build type | AMENT_CMAKE |
Use | RECOMMENDED |
Repository Summary
Description | ROS2 navigaiton tutorials and do quadruped robot |
Checkout URI | https://github.com/duyongquan/openrobotics.git |
VCS Type | git |
VCS Version | main |
Last Updated | 2024-01-16 |
Dev Status | UNKNOWN |
Released | UNRELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (-)
Good First Issues (-) Pull Requests to Review (-) |
Package Description
Additional Links
Maintainers
- quan
Authors
1 tutorial 1(member_functions_test)
1.1 功能介绍
客户端fibonacci请求,服务器fibonacci生成fibonacci数据
fibonacci: 1, 2, 3, 5, 8,13, …
1.2 代码
头文件tutorials_action_demo1_member_functions.hpp
class MinimalActionClient : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ClientGoalHandle<Fibonacci>;
explicit MinimalActionClient(const rclcpp::NodeOptions & node_options = rclcpp::NodeOptions());
bool is_goal_done() const;
void send_goal();
private:
void goal_response_callback(GoalHandleFibonacci::SharedPtr goal_handle);
void feedback_callback(
GoalHandleFibonacci::SharedPtr,
const std::shared_ptr<const Fibonacci::Feedback> feedback);
void result_callback(const GoalHandleFibonacci::WrappedResult & result);
rclcpp_action::Client<Fibonacci>::SharedPtr client_ptr_;
rclcpp::TimerBase::SharedPtr timer_;
bool goal_done_;
}; // class MinimalActionClient
//#####################################################################################
class MinimalActionServer : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ServerGoalHandle<Fibonacci>;
explicit MinimalActionServer(const rclcpp::NodeOptions & options = rclcpp::NodeOptions());
private:
rclcpp_action::Server<Fibonacci>::SharedPtr action_server_;
rclcpp_action::GoalResponse handle_goal(
const rclcpp_action::GoalUUID & uuid,
std::shared_ptr<const Fibonacci::Goal> goal);
rclcpp_action::CancelResponse handle_cancel(
const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void execute(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void handle_accepted(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
}; // class MinimalActionServer
tutorials_action_demo1_member_functions.cpp
- ```cpp
- MinimalActionClient::MinimalActionClient(const rclcpp::NodeOptions & node_options)
- Node(“minimal_action_client”, node_options),
goal_done_(false)
{
this->client_ptr_ = rclcpp_action::create_client
( this->get_node_base_interface(), this->get_node_graph_interface(), this->get_node_logging_interface(), this->get_node_waitables_interface(), "fibonacci"); this->timer_ = this->create_wall_timer( std::chrono::milliseconds(500), std::bind(&MinimalActionClient::send_goal, this)); }
bool MinimalActionClient::is_goal_done() const { return this->goal_done_; }
void MinimalActionClient::send_goal() { using namespace std::placeholders;
this->timer_->cancel();
File truncated at 100 lines see the full file
Package Dependencies
Deps | Name |
---|---|
tutorials_msgs | |
rclcpp | |
std_msgs | |
rclcpp_action | |
ament_cmake | |
ament_lint_auto | |
ament_lint_common |
System Dependencies
Dependant Packages
Name | Deps |
---|---|
rosgpt | |
rosgpt | |
sjtu_drone_bringup | |
rosgpt_vision |
Launch files
Messages
Services
Plugins
Recent questions tagged action at Robotics Stack Exchange
Package Summary
Tags | No category tags. |
Version | 0.0.0 |
License | TODO: License declaration |
Build type | AMENT_CMAKE |
Use | RECOMMENDED |
Repository Summary
Description | ROS2 navigaiton tutorials and do quadruped robot |
Checkout URI | https://github.com/duyongquan/openrobotics.git |
VCS Type | git |
VCS Version | main |
Last Updated | 2024-01-16 |
Dev Status | UNKNOWN |
Released | UNRELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (-)
Good First Issues (-) Pull Requests to Review (-) |
Package Description
Additional Links
Maintainers
- quan
Authors
1 tutorial 1(member_functions_test)
1.1 功能介绍
客户端fibonacci请求,服务器fibonacci生成fibonacci数据
fibonacci: 1, 2, 3, 5, 8,13, …
1.2 代码
头文件tutorials_action_demo1_member_functions.hpp
class MinimalActionClient : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ClientGoalHandle<Fibonacci>;
explicit MinimalActionClient(const rclcpp::NodeOptions & node_options = rclcpp::NodeOptions());
bool is_goal_done() const;
void send_goal();
private:
void goal_response_callback(GoalHandleFibonacci::SharedPtr goal_handle);
void feedback_callback(
GoalHandleFibonacci::SharedPtr,
const std::shared_ptr<const Fibonacci::Feedback> feedback);
void result_callback(const GoalHandleFibonacci::WrappedResult & result);
rclcpp_action::Client<Fibonacci>::SharedPtr client_ptr_;
rclcpp::TimerBase::SharedPtr timer_;
bool goal_done_;
}; // class MinimalActionClient
//#####################################################################################
class MinimalActionServer : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ServerGoalHandle<Fibonacci>;
explicit MinimalActionServer(const rclcpp::NodeOptions & options = rclcpp::NodeOptions());
private:
rclcpp_action::Server<Fibonacci>::SharedPtr action_server_;
rclcpp_action::GoalResponse handle_goal(
const rclcpp_action::GoalUUID & uuid,
std::shared_ptr<const Fibonacci::Goal> goal);
rclcpp_action::CancelResponse handle_cancel(
const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void execute(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void handle_accepted(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
}; // class MinimalActionServer
tutorials_action_demo1_member_functions.cpp
- ```cpp
- MinimalActionClient::MinimalActionClient(const rclcpp::NodeOptions & node_options)
- Node(“minimal_action_client”, node_options),
goal_done_(false)
{
this->client_ptr_ = rclcpp_action::create_client
( this->get_node_base_interface(), this->get_node_graph_interface(), this->get_node_logging_interface(), this->get_node_waitables_interface(), "fibonacci"); this->timer_ = this->create_wall_timer( std::chrono::milliseconds(500), std::bind(&MinimalActionClient::send_goal, this)); }
bool MinimalActionClient::is_goal_done() const { return this->goal_done_; }
void MinimalActionClient::send_goal() { using namespace std::placeholders;
this->timer_->cancel();
File truncated at 100 lines see the full file
Package Dependencies
Deps | Name |
---|---|
tutorials_msgs | |
rclcpp | |
std_msgs | |
rclcpp_action | |
ament_cmake | |
ament_lint_auto | |
ament_lint_common |
System Dependencies
Dependant Packages
Name | Deps |
---|---|
rosgpt | |
rosgpt | |
sjtu_drone_bringup | |
rosgpt_vision |
Launch files
Messages
Services
Plugins
Recent questions tagged action at Robotics Stack Exchange
Package Summary
Tags | No category tags. |
Version | 0.0.0 |
License | TODO: License declaration |
Build type | AMENT_CMAKE |
Use | RECOMMENDED |
Repository Summary
Description | ROS2 navigaiton tutorials and do quadruped robot |
Checkout URI | https://github.com/duyongquan/openrobotics.git |
VCS Type | git |
VCS Version | main |
Last Updated | 2024-01-16 |
Dev Status | UNKNOWN |
Released | UNRELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (-)
Good First Issues (-) Pull Requests to Review (-) |
Package Description
Additional Links
Maintainers
- quan
Authors
1 tutorial 1(member_functions_test)
1.1 功能介绍
客户端fibonacci请求,服务器fibonacci生成fibonacci数据
fibonacci: 1, 2, 3, 5, 8,13, …
1.2 代码
头文件tutorials_action_demo1_member_functions.hpp
class MinimalActionClient : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ClientGoalHandle<Fibonacci>;
explicit MinimalActionClient(const rclcpp::NodeOptions & node_options = rclcpp::NodeOptions());
bool is_goal_done() const;
void send_goal();
private:
void goal_response_callback(GoalHandleFibonacci::SharedPtr goal_handle);
void feedback_callback(
GoalHandleFibonacci::SharedPtr,
const std::shared_ptr<const Fibonacci::Feedback> feedback);
void result_callback(const GoalHandleFibonacci::WrappedResult & result);
rclcpp_action::Client<Fibonacci>::SharedPtr client_ptr_;
rclcpp::TimerBase::SharedPtr timer_;
bool goal_done_;
}; // class MinimalActionClient
//#####################################################################################
class MinimalActionServer : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ServerGoalHandle<Fibonacci>;
explicit MinimalActionServer(const rclcpp::NodeOptions & options = rclcpp::NodeOptions());
private:
rclcpp_action::Server<Fibonacci>::SharedPtr action_server_;
rclcpp_action::GoalResponse handle_goal(
const rclcpp_action::GoalUUID & uuid,
std::shared_ptr<const Fibonacci::Goal> goal);
rclcpp_action::CancelResponse handle_cancel(
const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void execute(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void handle_accepted(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
}; // class MinimalActionServer
tutorials_action_demo1_member_functions.cpp
- ```cpp
- MinimalActionClient::MinimalActionClient(const rclcpp::NodeOptions & node_options)
- Node(“minimal_action_client”, node_options),
goal_done_(false)
{
this->client_ptr_ = rclcpp_action::create_client
( this->get_node_base_interface(), this->get_node_graph_interface(), this->get_node_logging_interface(), this->get_node_waitables_interface(), "fibonacci"); this->timer_ = this->create_wall_timer( std::chrono::milliseconds(500), std::bind(&MinimalActionClient::send_goal, this)); }
bool MinimalActionClient::is_goal_done() const { return this->goal_done_; }
void MinimalActionClient::send_goal() { using namespace std::placeholders;
this->timer_->cancel();
File truncated at 100 lines see the full file
Package Dependencies
Deps | Name |
---|---|
tutorials_msgs | |
rclcpp | |
std_msgs | |
rclcpp_action | |
ament_cmake | |
ament_lint_auto | |
ament_lint_common |
System Dependencies
Dependant Packages
Name | Deps |
---|---|
rosgpt | |
rosgpt | |
sjtu_drone_bringup | |
rosgpt_vision |
Launch files
Messages
Services
Plugins
Recent questions tagged action at Robotics Stack Exchange
Package Summary
Tags | No category tags. |
Version | 0.0.0 |
License | TODO: License declaration |
Build type | AMENT_CMAKE |
Use | RECOMMENDED |
Repository Summary
Description | ROS2 navigaiton tutorials and do quadruped robot |
Checkout URI | https://github.com/duyongquan/openrobotics.git |
VCS Type | git |
VCS Version | main |
Last Updated | 2024-01-16 |
Dev Status | UNKNOWN |
Released | UNRELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (-)
Good First Issues (-) Pull Requests to Review (-) |
Package Description
Additional Links
Maintainers
- quan
Authors
1 tutorial 1(member_functions_test)
1.1 功能介绍
客户端fibonacci请求,服务器fibonacci生成fibonacci数据
fibonacci: 1, 2, 3, 5, 8,13, …
1.2 代码
头文件tutorials_action_demo1_member_functions.hpp
class MinimalActionClient : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ClientGoalHandle<Fibonacci>;
explicit MinimalActionClient(const rclcpp::NodeOptions & node_options = rclcpp::NodeOptions());
bool is_goal_done() const;
void send_goal();
private:
void goal_response_callback(GoalHandleFibonacci::SharedPtr goal_handle);
void feedback_callback(
GoalHandleFibonacci::SharedPtr,
const std::shared_ptr<const Fibonacci::Feedback> feedback);
void result_callback(const GoalHandleFibonacci::WrappedResult & result);
rclcpp_action::Client<Fibonacci>::SharedPtr client_ptr_;
rclcpp::TimerBase::SharedPtr timer_;
bool goal_done_;
}; // class MinimalActionClient
//#####################################################################################
class MinimalActionServer : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ServerGoalHandle<Fibonacci>;
explicit MinimalActionServer(const rclcpp::NodeOptions & options = rclcpp::NodeOptions());
private:
rclcpp_action::Server<Fibonacci>::SharedPtr action_server_;
rclcpp_action::GoalResponse handle_goal(
const rclcpp_action::GoalUUID & uuid,
std::shared_ptr<const Fibonacci::Goal> goal);
rclcpp_action::CancelResponse handle_cancel(
const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void execute(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void handle_accepted(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
}; // class MinimalActionServer
tutorials_action_demo1_member_functions.cpp
- ```cpp
- MinimalActionClient::MinimalActionClient(const rclcpp::NodeOptions & node_options)
- Node(“minimal_action_client”, node_options),
goal_done_(false)
{
this->client_ptr_ = rclcpp_action::create_client
( this->get_node_base_interface(), this->get_node_graph_interface(), this->get_node_logging_interface(), this->get_node_waitables_interface(), "fibonacci"); this->timer_ = this->create_wall_timer( std::chrono::milliseconds(500), std::bind(&MinimalActionClient::send_goal, this)); }
bool MinimalActionClient::is_goal_done() const { return this->goal_done_; }
void MinimalActionClient::send_goal() { using namespace std::placeholders;
this->timer_->cancel();
File truncated at 100 lines see the full file
Package Dependencies
Deps | Name |
---|---|
tutorials_msgs | |
rclcpp | |
std_msgs | |
rclcpp_action | |
ament_cmake | |
ament_lint_auto | |
ament_lint_common |
System Dependencies
Dependant Packages
Name | Deps |
---|---|
rosgpt | |
rosgpt | |
sjtu_drone_bringup | |
rosgpt_vision |
Launch files
Messages
Services
Plugins
Recent questions tagged action at Robotics Stack Exchange
Package Summary
Tags | No category tags. |
Version | 0.0.0 |
License | TODO: License declaration |
Build type | AMENT_CMAKE |
Use | RECOMMENDED |
Repository Summary
Description | ROS2 navigaiton tutorials and do quadruped robot |
Checkout URI | https://github.com/duyongquan/openrobotics.git |
VCS Type | git |
VCS Version | main |
Last Updated | 2024-01-16 |
Dev Status | UNKNOWN |
Released | UNRELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (-)
Good First Issues (-) Pull Requests to Review (-) |
Package Description
Additional Links
Maintainers
- quan
Authors
1 tutorial 1(member_functions_test)
1.1 功能介绍
客户端fibonacci请求,服务器fibonacci生成fibonacci数据
fibonacci: 1, 2, 3, 5, 8,13, …
1.2 代码
头文件tutorials_action_demo1_member_functions.hpp
class MinimalActionClient : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ClientGoalHandle<Fibonacci>;
explicit MinimalActionClient(const rclcpp::NodeOptions & node_options = rclcpp::NodeOptions());
bool is_goal_done() const;
void send_goal();
private:
void goal_response_callback(GoalHandleFibonacci::SharedPtr goal_handle);
void feedback_callback(
GoalHandleFibonacci::SharedPtr,
const std::shared_ptr<const Fibonacci::Feedback> feedback);
void result_callback(const GoalHandleFibonacci::WrappedResult & result);
rclcpp_action::Client<Fibonacci>::SharedPtr client_ptr_;
rclcpp::TimerBase::SharedPtr timer_;
bool goal_done_;
}; // class MinimalActionClient
//#####################################################################################
class MinimalActionServer : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ServerGoalHandle<Fibonacci>;
explicit MinimalActionServer(const rclcpp::NodeOptions & options = rclcpp::NodeOptions());
private:
rclcpp_action::Server<Fibonacci>::SharedPtr action_server_;
rclcpp_action::GoalResponse handle_goal(
const rclcpp_action::GoalUUID & uuid,
std::shared_ptr<const Fibonacci::Goal> goal);
rclcpp_action::CancelResponse handle_cancel(
const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void execute(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void handle_accepted(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
}; // class MinimalActionServer
tutorials_action_demo1_member_functions.cpp
- ```cpp
- MinimalActionClient::MinimalActionClient(const rclcpp::NodeOptions & node_options)
- Node(“minimal_action_client”, node_options),
goal_done_(false)
{
this->client_ptr_ = rclcpp_action::create_client
( this->get_node_base_interface(), this->get_node_graph_interface(), this->get_node_logging_interface(), this->get_node_waitables_interface(), "fibonacci"); this->timer_ = this->create_wall_timer( std::chrono::milliseconds(500), std::bind(&MinimalActionClient::send_goal, this)); }
bool MinimalActionClient::is_goal_done() const { return this->goal_done_; }
void MinimalActionClient::send_goal() { using namespace std::placeholders;
this->timer_->cancel();
File truncated at 100 lines see the full file
Package Dependencies
Deps | Name |
---|---|
tutorials_msgs | |
rclcpp | |
std_msgs | |
rclcpp_action | |
ament_cmake | |
ament_lint_auto | |
ament_lint_common |
System Dependencies
Dependant Packages
Name | Deps |
---|---|
rosgpt | |
rosgpt | |
sjtu_drone_bringup | |
rosgpt_vision |
Launch files
Messages
Services
Plugins
Recent questions tagged action at Robotics Stack Exchange
Package Summary
Tags | No category tags. |
Version | 0.0.0 |
License | TODO: License declaration |
Build type | AMENT_CMAKE |
Use | RECOMMENDED |
Repository Summary
Description | ROS2 navigaiton tutorials and do quadruped robot |
Checkout URI | https://github.com/duyongquan/openrobotics.git |
VCS Type | git |
VCS Version | main |
Last Updated | 2024-01-16 |
Dev Status | UNKNOWN |
Released | UNRELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (-)
Good First Issues (-) Pull Requests to Review (-) |
Package Description
Additional Links
Maintainers
- quan
Authors
1 tutorial 1(member_functions_test)
1.1 功能介绍
客户端fibonacci请求,服务器fibonacci生成fibonacci数据
fibonacci: 1, 2, 3, 5, 8,13, …
1.2 代码
头文件tutorials_action_demo1_member_functions.hpp
class MinimalActionClient : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ClientGoalHandle<Fibonacci>;
explicit MinimalActionClient(const rclcpp::NodeOptions & node_options = rclcpp::NodeOptions());
bool is_goal_done() const;
void send_goal();
private:
void goal_response_callback(GoalHandleFibonacci::SharedPtr goal_handle);
void feedback_callback(
GoalHandleFibonacci::SharedPtr,
const std::shared_ptr<const Fibonacci::Feedback> feedback);
void result_callback(const GoalHandleFibonacci::WrappedResult & result);
rclcpp_action::Client<Fibonacci>::SharedPtr client_ptr_;
rclcpp::TimerBase::SharedPtr timer_;
bool goal_done_;
}; // class MinimalActionClient
//#####################################################################################
class MinimalActionServer : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ServerGoalHandle<Fibonacci>;
explicit MinimalActionServer(const rclcpp::NodeOptions & options = rclcpp::NodeOptions());
private:
rclcpp_action::Server<Fibonacci>::SharedPtr action_server_;
rclcpp_action::GoalResponse handle_goal(
const rclcpp_action::GoalUUID & uuid,
std::shared_ptr<const Fibonacci::Goal> goal);
rclcpp_action::CancelResponse handle_cancel(
const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void execute(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void handle_accepted(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
}; // class MinimalActionServer
tutorials_action_demo1_member_functions.cpp
- ```cpp
- MinimalActionClient::MinimalActionClient(const rclcpp::NodeOptions & node_options)
- Node(“minimal_action_client”, node_options),
goal_done_(false)
{
this->client_ptr_ = rclcpp_action::create_client
( this->get_node_base_interface(), this->get_node_graph_interface(), this->get_node_logging_interface(), this->get_node_waitables_interface(), "fibonacci"); this->timer_ = this->create_wall_timer( std::chrono::milliseconds(500), std::bind(&MinimalActionClient::send_goal, this)); }
bool MinimalActionClient::is_goal_done() const { return this->goal_done_; }
void MinimalActionClient::send_goal() { using namespace std::placeholders;
this->timer_->cancel();
File truncated at 100 lines see the full file
Package Dependencies
Deps | Name |
---|---|
tutorials_msgs | |
rclcpp | |
std_msgs | |
rclcpp_action | |
ament_cmake | |
ament_lint_auto | |
ament_lint_common |
System Dependencies
Dependant Packages
Name | Deps |
---|---|
rosgpt | |
rosgpt | |
sjtu_drone_bringup | |
rosgpt_vision |
Launch files
Messages
Services
Plugins
Recent questions tagged action at Robotics Stack Exchange
Package Summary
Tags | No category tags. |
Version | 0.0.0 |
License | TODO: License declaration |
Build type | AMENT_CMAKE |
Use | RECOMMENDED |
Repository Summary
Description | ROS2 navigaiton tutorials and do quadruped robot |
Checkout URI | https://github.com/duyongquan/openrobotics.git |
VCS Type | git |
VCS Version | main |
Last Updated | 2024-01-16 |
Dev Status | UNKNOWN |
Released | UNRELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (-)
Good First Issues (-) Pull Requests to Review (-) |
Package Description
Additional Links
Maintainers
- quan
Authors
1 tutorial 1(member_functions_test)
1.1 功能介绍
客户端fibonacci请求,服务器fibonacci生成fibonacci数据
fibonacci: 1, 2, 3, 5, 8,13, …
1.2 代码
头文件tutorials_action_demo1_member_functions.hpp
class MinimalActionClient : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ClientGoalHandle<Fibonacci>;
explicit MinimalActionClient(const rclcpp::NodeOptions & node_options = rclcpp::NodeOptions());
bool is_goal_done() const;
void send_goal();
private:
void goal_response_callback(GoalHandleFibonacci::SharedPtr goal_handle);
void feedback_callback(
GoalHandleFibonacci::SharedPtr,
const std::shared_ptr<const Fibonacci::Feedback> feedback);
void result_callback(const GoalHandleFibonacci::WrappedResult & result);
rclcpp_action::Client<Fibonacci>::SharedPtr client_ptr_;
rclcpp::TimerBase::SharedPtr timer_;
bool goal_done_;
}; // class MinimalActionClient
//#####################################################################################
class MinimalActionServer : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ServerGoalHandle<Fibonacci>;
explicit MinimalActionServer(const rclcpp::NodeOptions & options = rclcpp::NodeOptions());
private:
rclcpp_action::Server<Fibonacci>::SharedPtr action_server_;
rclcpp_action::GoalResponse handle_goal(
const rclcpp_action::GoalUUID & uuid,
std::shared_ptr<const Fibonacci::Goal> goal);
rclcpp_action::CancelResponse handle_cancel(
const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void execute(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void handle_accepted(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
}; // class MinimalActionServer
tutorials_action_demo1_member_functions.cpp
- ```cpp
- MinimalActionClient::MinimalActionClient(const rclcpp::NodeOptions & node_options)
- Node(“minimal_action_client”, node_options),
goal_done_(false)
{
this->client_ptr_ = rclcpp_action::create_client
( this->get_node_base_interface(), this->get_node_graph_interface(), this->get_node_logging_interface(), this->get_node_waitables_interface(), "fibonacci"); this->timer_ = this->create_wall_timer( std::chrono::milliseconds(500), std::bind(&MinimalActionClient::send_goal, this)); }
bool MinimalActionClient::is_goal_done() const { return this->goal_done_; }
void MinimalActionClient::send_goal() { using namespace std::placeholders;
this->timer_->cancel();
File truncated at 100 lines see the full file
Package Dependencies
Deps | Name |
---|---|
tutorials_msgs | |
rclcpp | |
std_msgs | |
rclcpp_action | |
ament_cmake | |
ament_lint_auto | |
ament_lint_common |
System Dependencies
Dependant Packages
Name | Deps |
---|---|
rosgpt | |
rosgpt | |
sjtu_drone_bringup | |
rosgpt_vision |
Launch files
Messages
Services
Plugins
Recent questions tagged action at Robotics Stack Exchange
Package Summary
Tags | No category tags. |
Version | 0.0.0 |
License | TODO: License declaration |
Build type | AMENT_CMAKE |
Use | RECOMMENDED |
Repository Summary
Description | ROS2 navigaiton tutorials and do quadruped robot |
Checkout URI | https://github.com/duyongquan/openrobotics.git |
VCS Type | git |
VCS Version | main |
Last Updated | 2024-01-16 |
Dev Status | UNKNOWN |
Released | UNRELEASED |
Tags | No category tags. |
Contributing |
Help Wanted (-)
Good First Issues (-) Pull Requests to Review (-) |
Package Description
Additional Links
Maintainers
- quan
Authors
1 tutorial 1(member_functions_test)
1.1 功能介绍
客户端fibonacci请求,服务器fibonacci生成fibonacci数据
fibonacci: 1, 2, 3, 5, 8,13, …
1.2 代码
头文件tutorials_action_demo1_member_functions.hpp
class MinimalActionClient : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ClientGoalHandle<Fibonacci>;
explicit MinimalActionClient(const rclcpp::NodeOptions & node_options = rclcpp::NodeOptions());
bool is_goal_done() const;
void send_goal();
private:
void goal_response_callback(GoalHandleFibonacci::SharedPtr goal_handle);
void feedback_callback(
GoalHandleFibonacci::SharedPtr,
const std::shared_ptr<const Fibonacci::Feedback> feedback);
void result_callback(const GoalHandleFibonacci::WrappedResult & result);
rclcpp_action::Client<Fibonacci>::SharedPtr client_ptr_;
rclcpp::TimerBase::SharedPtr timer_;
bool goal_done_;
}; // class MinimalActionClient
//#####################################################################################
class MinimalActionServer : public rclcpp::Node
{
public:
using Fibonacci = tutorials_msgs::action::Fibonacci;
using GoalHandleFibonacci = rclcpp_action::ServerGoalHandle<Fibonacci>;
explicit MinimalActionServer(const rclcpp::NodeOptions & options = rclcpp::NodeOptions());
private:
rclcpp_action::Server<Fibonacci>::SharedPtr action_server_;
rclcpp_action::GoalResponse handle_goal(
const rclcpp_action::GoalUUID & uuid,
std::shared_ptr<const Fibonacci::Goal> goal);
rclcpp_action::CancelResponse handle_cancel(
const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void execute(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
void handle_accepted(const std::shared_ptr<GoalHandleFibonacci> goal_handle);
}; // class MinimalActionServer
tutorials_action_demo1_member_functions.cpp
- ```cpp
- MinimalActionClient::MinimalActionClient(const rclcpp::NodeOptions & node_options)
- Node(“minimal_action_client”, node_options),
goal_done_(false)
{
this->client_ptr_ = rclcpp_action::create_client
( this->get_node_base_interface(), this->get_node_graph_interface(), this->get_node_logging_interface(), this->get_node_waitables_interface(), "fibonacci"); this->timer_ = this->create_wall_timer( std::chrono::milliseconds(500), std::bind(&MinimalActionClient::send_goal, this)); }
bool MinimalActionClient::is_goal_done() const { return this->goal_done_; }
void MinimalActionClient::send_goal() { using namespace std::placeholders;
this->timer_->cancel();
File truncated at 100 lines see the full file
Package Dependencies
Deps | Name |
---|---|
tutorials_msgs | |
rclcpp | |
std_msgs | |
rclcpp_action | |
ament_cmake | |
ament_lint_auto | |
ament_lint_common |
System Dependencies
Dependant Packages
Name | Deps |
---|---|
rosgpt | |
rosgpt | |
sjtu_drone_bringup | |
rosgpt_vision |