Paparazzi UAS  v5.15_devel-230-gc96ce27
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
dcf.c File Reference
#include <math.h>
#include <std.h>
#include "modules/muti/dcf/dcf.h"
#include "subsystems/datalink/telemetry.h"
#include "subsystems/navigation/common_nav.h"
#include "autopilot.h"
+ Include dependency graph for dcf.c:

Go to the source code of this file.

Macros

#define DCF_GAIN_K   10
 
#define DCF_RADIUS   80
 
#define DCF_TIMEOUT   1500
 
#define DCF_BROADTIME   200
 

Functions

static void send_dcf (struct transport_tx *trans, struct link_device *dev)
 
void dcf_init (void)
 
bool distributed_circular (uint8_t wp)
 
void send_theta_to_nei (void)
 
void parseRegTable (uint8_t *buf)
 
void parseThetaTable (uint8_t *buf)
 

Variables

struct dcf_con dcf_control = {DCF_GAIN_K, DCF_RADIUS, DCF_TIMEOUT, 0, DCF_BROADTIME}
 
struct dcf_tab dcf_tables
 
uint32_t last_transmision = 0
 

Macro Definition Documentation

#define DCF_BROADTIME   200

Default broadcasting time

Definition at line 55 of file dcf.c.

#define DCF_GAIN_K   10

Default gain k for the algorithm

Definition at line 43 of file dcf.c.

#define DCF_RADIUS   80

Default radius for the circumference

Definition at line 47 of file dcf.c.

#define DCF_TIMEOUT   1500

Default timeout for the neighbors' information

Definition at line 51 of file dcf.c.

Function Documentation

void dcf_init ( void  )

Definition at line 63 of file dcf.c.

References DCF_MAX_NEIGHBORS, dcf_tables, DefaultPeriodic, dcf_tab::error_sigma, register_periodic_telemetry(), send_dcf(), and dcf_tab::tableNei.

+ Here is the call graph for this function:

void parseRegTable ( uint8_t buf)

Definition at line 140 of file dcf.c.

References ac_id, DCF_MAX_NEIGHBORS, dcf_tables, and dcf_tab::tableNei.

void parseThetaTable ( uint8_t buf)

Definition at line 169 of file dcf.c.

References DCF_MAX_NEIGHBORS, dcf_tables, get_sys_time_msec(), dcf_tab::last_theta, and dcf_tab::tableNei.

+ Here is the call graph for this function:

static void send_dcf ( struct transport_tx *  trans,
struct link_device *  dev 
)
static

Definition at line 33 of file dcf.c.

References DCF_MAX_NEIGHBORS, dcf_tables, dcf_tab::error_sigma, and dcf_tab::tableNei.

Referenced by dcf_init().

+ Here is the caller graph for this function:

void send_theta_to_nei ( void  )

Definition at line 125 of file dcf.c.

References DCF_MAX_NEIGHBORS, dcf_tables, DefaultChannel, DefaultDevice, dcf_tab::tableNei, and dcf_con::theta.

Referenced by distributed_circular().

+ Here is the caller graph for this function:

Variable Documentation

struct dcf_con dcf_control = {DCF_GAIN_K, DCF_RADIUS, DCF_TIMEOUT, 0, DCF_BROADTIME}

Definition at line 58 of file dcf.c.

struct dcf_tab dcf_tables
uint32_t last_transmision = 0

Definition at line 61 of file dcf.c.

Referenced by distributed_circular().