27 #ifndef THROTTLE_CURVE_H
28 #define THROTTLE_CURVE_H
32 #include "generated/airframe.h"
static uint8_t mode
mode holds the current sonar mode mode = 0 used at high altitude, uses 16 wave patterns mode = 1 used...
int32_t coll_trim
Collective trim.
struct throttle_curve_t throttle_curve
float rpm_fb_p
RPM feedback p gain.
uint16_t throttle[THROTTLE_POINTS_NB]
Throttle points in the curve.
uint16_t rpm
Output RPM of the throttle curve.
uint16_t rpm_meas
RPM measured.
int16_t collective[THROTTLE_POINTS_NB]
The collective points in the curve.
uint16_t rpm[THROTTLE_POINTS_NB]
RPM points in the curve.
void throttle_curve_run(pprz_t in_cmd[], uint8_t autopilot_mode)
Run the throttle curve and generate the output throttle and pitch This depends on the FMODE(flight mo...
uint8_t nb_curves
The number of throttle/pitch curves.
uint8_t nav_mode
Nav Flight mode.
void throttle_curve_init(void)
Initialize the default throttle curve values.
int32_t throttle_trim
RPM feedback i gain.
uint16_t throttle
Output thrust(throttle) of the throttle curve.
struct curve_t curves[THROTTLE_CURVES_NB]
Throttle/pitch curves.
int16_t collective
Output collective of the throttle curve.
void nav_throttle_curve_set(uint8_t mode)
Set a specific throttle curve based on the mode given with this function.
uint8_t nb_points
The number of points in the curve.
bool rpm_measured
Whenever the RPM is measured.
float rpm_err_sum
Summed RPM error.
unsigned short uint16_t
Typedef defining 16 bit unsigned short type.
int int32_t
Typedef defining 32 bit int type.
short int16_t
Typedef defining 16 bit short type.
unsigned char uint8_t
Typedef defining 8 bit unsigned char type.