Paparazzi UAS  v5.18.0_stable
Paparazzi is a free software Unmanned Aircraft System.
actuators.c File Reference
#include <sys/ioctl.h>
#include <fcntl.h>
#include "subsystems/actuators.h"
#include "subsystems/actuators/motor_mixing.h"
#include "actuators.h"
#include "autopilot.h"
+ Include dependency graph for actuators.c:

Go to the source code of this file.

Data Structures

struct  pwm_delos_quadruplet
 

Macros

#define PWM_MAGIC   'p'
 
#define PWM_DELOS_SET_RATIOS   _IOR(PWM_MAGIC, 9, pwm_delos_quadruplet*)
 
#define PWM_DELOS_SET_SPEEDS   _IOR(PWM_MAGIC, 10, pwm_delos_quadruplet*)
 
#define PWM_DELOS_SET_CTRL   _IOR(PWM_MAGIC, 11, unsigned int)
 
#define PWM_DELOS_REQUEST   _IO(PWM_MAGIC, 12)
 
#define PWM_NB_BITS   (9)
 
#define PWM_TOTAL_RANGE   (1<<PWM_NB_BITS)
 
#define PWM_REG_RATIO_PRECISION_MASK   (PWM_NB_BITS<<16)
 
#define PWM_REG_SATURATION   (PWM_REG_RATIO_PRECISION_MASK|PWM_TOTAL_RANGE)
 

Enumerations

enum  { SiP6_PWM0_START = (1<<0), SiP6_PWM1_START = (1<<1), SiP6_PWM2_START = (1<<2), SiP6_PWM3_START = (1<<3) }
 

Functions

void actuators_swing_init (void)
 
void actuators_swing_commit (void)
 

Variables

struct ActuatorsSwing actuators_swing
 
static int actuators_fd
 

Detailed Description

Actuator driver for the swing

Definition in file actuators.c.


Data Structure Documentation

◆ pwm_delos_quadruplet

struct pwm_delos_quadruplet

Definition at line 34 of file actuators.c.

Data Fields
unsigned int val[4]

Macro Definition Documentation

◆ PWM_DELOS_REQUEST

#define PWM_DELOS_REQUEST   _IO(PWM_MAGIC, 12)

Definition at line 38 of file actuators.c.

◆ PWM_DELOS_SET_CTRL

#define PWM_DELOS_SET_CTRL   _IOR(PWM_MAGIC, 11, unsigned int)

Definition at line 37 of file actuators.c.

◆ PWM_DELOS_SET_RATIOS

#define PWM_DELOS_SET_RATIOS   _IOR(PWM_MAGIC, 9, pwm_delos_quadruplet*)

Definition at line 35 of file actuators.c.

◆ PWM_DELOS_SET_SPEEDS

#define PWM_DELOS_SET_SPEEDS   _IOR(PWM_MAGIC, 10, pwm_delos_quadruplet*)

Definition at line 36 of file actuators.c.

◆ PWM_MAGIC

#define PWM_MAGIC   'p'

Definition at line 33 of file actuators.c.

◆ PWM_NB_BITS

#define PWM_NB_BITS   (9)

Definition at line 40 of file actuators.c.

◆ PWM_REG_RATIO_PRECISION_MASK

#define PWM_REG_RATIO_PRECISION_MASK   (PWM_NB_BITS<<16)

Definition at line 47 of file actuators.c.

◆ PWM_REG_SATURATION

#define PWM_REG_SATURATION   (PWM_REG_RATIO_PRECISION_MASK|PWM_TOTAL_RANGE)

Definition at line 48 of file actuators.c.

◆ PWM_TOTAL_RANGE

#define PWM_TOTAL_RANGE   (1<<PWM_NB_BITS)

Definition at line 44 of file actuators.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
SiP6_PWM0_START 
SiP6_PWM1_START 
SiP6_PWM2_START 
SiP6_PWM3_START 

Definition at line 59 of file actuators.c.

Function Documentation

◆ actuators_swing_commit()

void actuators_swing_commit ( void  )

◆ actuators_swing_init()

void actuators_swing_init ( void  )

Definition at line 66 of file actuators.c.

References actuators_fd, actuators_swing_commit(), PWM_DELOS_SET_CTRL, PWM_DELOS_SET_SPEEDS, SiP6_PWM0_START, SiP6_PWM1_START, SiP6_PWM2_START, and SiP6_PWM3_START.

+ Here is the call graph for this function:

Variable Documentation

◆ actuators_fd

int actuators_fd
static

Definition at line 56 of file actuators.c.

Referenced by actuators_swing_commit(), and actuators_swing_init().

◆ actuators_swing

struct ActuatorsSwing actuators_swing

Definition at line 55 of file actuators.c.

Referenced by actuators_swing_commit().