18 #ifndef _GAZEBO_CESSNA_PLUGIN_HH_
19 #define _GAZEBO_CESSNA_PLUGIN_HH_
81 private:
bool FindJoint(
const std::string &_sdfParam,
91 private:
void OnControl(ConstCessnaPtr &_msg);
95 private:
void UpdatePIDs(
double _dt);
98 private:
void PublishState();
101 private:
static const unsigned int kLeftAileron = 0;
102 private:
static const unsigned int kLeftFlap = 1;
103 private:
static const unsigned int kRightAileron = 2;
104 private:
static const unsigned int kRightFlap = 3;
105 private:
static const unsigned int kElevators = 4;
106 private:
static const unsigned int kRudder = 5;
107 private:
static const unsigned int kPropeller = 6;
125 private: std::array<physics::JointPtr, 7> joints;
128 private: int32_t propellerMaxRpm = 2500;
131 private: std::array<float, 7> cmds;
137 private: std::array<common::PID, 6> controlSurfacesPID;
143 private: std::mutex mutex;
Allow moving the control surfaces of a Cessna C-172 plane.
Definition: CessnaPlugin.hh:63
Forward declarations for transport.
boost::shared_ptr< Publisher > PublisherPtr
Definition: TransportTypes.hh:49
boost::shared_ptr< Subscriber > SubscriberPtr
Definition: TransportTypes.hh:53
boost::shared_ptr< Joint > JointPtr
Definition: PhysicsTypes.hh:117
Information for use in an update event.
Definition: UpdateInfo.hh:30
boost::shared_ptr< Node > NodePtr
Definition: TransportTypes.hh:57
default namespace for gazebo
boost::shared_ptr< Connection > ConnectionPtr
Definition: CommonTypes.hh:153
boost::shared_ptr< Model > ModelPtr
Definition: PhysicsTypes.hh:93
A plugin with access to physics::Model.
Definition: Plugin.hh:245
#define GAZEBO_VISIBLE
Use to represent "symbol visible" if supported.
Definition: system.hh:59
Generic PID controller class.
Definition: PID.hh:36
A Time class, can be used to hold wall- or sim-time.
Definition: Time.hh:44