Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
mavros::std_plugins::CommandPlugin Class Reference

Command plugin. More...

Inheritance diagram for mavros::std_plugins::CommandPlugin:
Inheritance graph
[legend]

Public Member Functions

 CommandPlugin ()
 
Subscriptions get_subscriptions () override
 Return vector of MAVLink message subscriptions (handlers) More...
 
void initialize (UAS &uas_) override
 Plugin initializer. More...
 
- Public Member Functions inherited from mavros::plugin::PluginBase
virtual ~PluginBase ()
 

Private Types

using L_CommandTransaction = std::list< CommandTransaction >
 

Private Member Functions

bool arming_cb (mavros_msgs::CommandBool::Request &req, mavros_msgs::CommandBool::Response &res)
 
void command_int (bool broadcast, uint8_t frame, uint16_t command, uint8_t current, uint8_t autocontinue, float param1, float param2, float param3, float param4, int32_t x, int32_t y, float z)
 
bool command_int_cb (mavros_msgs::CommandInt::Request &req, mavros_msgs::CommandInt::Response &res)
 
void command_long (bool broadcast, uint16_t command, uint8_t confirmation, float param1, float param2, float param3, float param4, float param5, float param6, float param7)
 
bool command_long_cb (mavros_msgs::CommandLong::Request &req, mavros_msgs::CommandLong::Response &res)
 
void handle_command_ack (const mavlink::mavlink_message_t *msg, mavlink::common::msg::COMMAND_ACK &ack)
 
bool land_cb (mavros_msgs::CommandTOL::Request &req, mavros_msgs::CommandTOL::Response &res)
 
bool send_command_int (bool broadcast, uint8_t frame, uint16_t command, uint8_t current, uint8_t autocontinue, float param1, float param2, float param3, float param4, int32_t x, int32_t y, float z, unsigned char &success)
 
bool send_command_long_and_wait (bool broadcast, uint16_t command, uint8_t confirmation, float param1, float param2, float param3, float param4, float param5, float param6, float param7, unsigned char &success, uint8_t &result)
 
bool set_home_cb (mavros_msgs::CommandHome::Request &req, mavros_msgs::CommandHome::Response &res)
 
template<typename MsgT >
void set_target (MsgT &cmd, bool broadcast)
 
bool takeoff_cb (mavros_msgs::CommandTOL::Request &req, mavros_msgs::CommandTOL::Response &res)
 
bool trigger_control_cb (mavros_msgs::CommandTriggerControl::Request &req, mavros_msgs::CommandTriggerControl::Response &res)
 
bool trigger_interval_cb (mavros_msgs::CommandTriggerInterval::Request &req, mavros_msgs::CommandTriggerInterval::Response &res)
 
bool vtol_transition_cb (mavros_msgs::CommandVtolTransition::Request &req, mavros_msgs::CommandVtolTransition::Response &res)
 
bool wait_ack_for (CommandTransaction &tr)
 

Private Attributes

L_CommandTransaction ack_waiting_list
 
ros::ServiceServer arming_srv
 
ros::NodeHandle cmd_nh
 
ros::Duration command_ack_timeout_dt
 
ros::ServiceServer command_int_srv
 
ros::ServiceServer command_long_srv
 
ros::ServiceServer land_srv
 
std::mutex mutex
 
ros::ServiceServer set_home_srv
 
ros::ServiceServer takeoff_srv
 
ros::ServiceServer trigger_control_srv
 
ros::ServiceServer trigger_interval_srv
 
bool use_comp_id_system_control
 
ros::ServiceServer vtol_transition_srv
 

Additional Inherited Members

- Public Types inherited from mavros::plugin::PluginBase
using ConstPtr = boost::shared_ptr< PluginBase const >
 
using HandlerCb = mavconn::MAVConnInterface::ReceivedCb
 generic message handler callback More...
 
using HandlerInfo = std::tuple< mavlink::msgid_t, const char *, size_t, HandlerCb >
 Tuple: MSG ID, MSG NAME, message type into hash_code, message handler callback. More...
 
using Ptr = boost::shared_ptr< PluginBase >
 
using Subscriptions = std::vector< HandlerInfo >
 Subscriptions vector. More...
 
- Protected Member Functions inherited from mavros::plugin::PluginBase
virtual void capabilities_cb (UAS::MAV_CAP capabilities)
 
virtual void connection_cb (bool connected)
 
void enable_capabilities_cb ()
 
void enable_connection_cb ()
 
template<class _C >
HandlerInfo make_handler (const mavlink::msgid_t id, void(_C::*fn)(const mavlink::mavlink_message_t *msg, const mavconn::Framing framing))
 
template<class _C , class _T >
HandlerInfo make_handler (void(_C::*fn)(const mavlink::mavlink_message_t *, _T &))
 
 PluginBase ()
 Plugin constructor Should not do anything before initialize() More...
 
- Protected Attributes inherited from mavros::plugin::PluginBase
UASm_uas
 

Detailed Description

Command plugin.

Send any command via COMMAND_LONG

Definition at line 57 of file command.cpp.


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


mavros
Author(s): Vladimir Ermakov
autogenerated on Tue Jun 1 2021 02:36:27