Paparazzi UAS  v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
autopilot_utils.h File Reference

Utility functions and includes for autopilots. More...

#include "std.h"
#include "modules/core/commands.h"
+ Include dependency graph for autopilot_utils.h:

Go to the source code of this file.

Macros

#define SetRotorcraftCommands(_cmd, _in_flight, _motors_on)   set_rotorcraft_commands(commands, _cmd, _in_flight, _motors_on)
 

Functions

uint8_t ap_mode_of_3way_switch (void)
 get autopilot mode as set by RADIO_MODE 3-way switch More...
 
void set_rotorcraft_commands (pprz_t *cmd_out, int32_t *cmd_in, bool in_flight, bool motors_on)
 Display descent speed in failsafe mode if needed. More...
 

Detailed Description

Utility functions and includes for autopilots.

Definition in file autopilot_utils.h.

Macro Definition Documentation

◆ SetRotorcraftCommands

#define SetRotorcraftCommands (   _cmd,
  _in_flight,
  _motors_on 
)    set_rotorcraft_commands(commands, _cmd, _in_flight, _motors_on)

Definition at line 39 of file autopilot_utils.h.

Function Documentation

◆ ap_mode_of_3way_switch()

uint8_t ap_mode_of_3way_switch ( void  )

get autopilot mode as set by RADIO_MODE 3-way switch

Definition at line 41 of file autopilot_utils.c.

◆ set_rotorcraft_commands()

void set_rotorcraft_commands ( pprz_t cmd_out,
int32_t cmd_in,
bool  in_flight,
bool  motors_on 
)

Display descent speed in failsafe mode if needed.

Set Rotorcraft commands.

Set Rotorcraft commands. Limit thrust and/or yaw depending of the in_flight and motors_on flag status

Display descent speed in failsafe mode if needed.

Limit thrust and/or yaw depending of the in_flight and motors_on flag status

A default implementation is provided, but the function can be redefined

Parameters
[out]cmd_outoutput command vector in pprz_t (usually commands array)
[in/out]cmd_in input commands to apply, might be affected by in_flight and motors_on param (FIXME really ?)
[in]in_flighttells if rotorcraft is in flight
[in]motors_ontells if motors are running

Set Rotorcraft commands.

Set Rotorcraft commands. Limit thrust and/or yaw depending of the in_flight and motors_on flag status

Definition at line 123 of file autopilot_utils.c.

References lock_wings, and WING_POS_NOMINAL_THRUST.