Paparazzi UAS v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
Loading...
Searching...
No Matches
nps_ivy.c File Reference
#include "nps_ivy.h"
#include <stdlib.h>
#include <stdio.h>
#include <sys/types.h>
#include <unistd.h>
#include <Ivy/ivy.h>
#include <Ivy/ivyloop.h>
#include "generated/airframe.h"
#include "math/pprz_algebra_float.h"
#include "math/pprz_algebra_double.h"
#include "nps_main.h"
#include "nps_autopilot.h"
#include "nps_fdm.h"
#include "nps_sensors.h"
#include "nps_atmosphere.h"
#include "generated/settings.h"
#include "pprzlink/dl_protocol.h"
#include "modules/datalink/downlink.h"
#include "modules/gps/gps.h"
+ Include dependency graph for nps_ivy.c:

Go to the source code of this file.

Data Structures

Functions

static void on_WORLD_ENV (IvyClientPtr app, void *user_data, int argc, char *argv[])
 
static void on_DL_SETTING (IvyClientPtr app, void *user_data, int argc, char *argv[])
 
int find_launch_index (void)
 
void nps_ivy_beforeloop (struct nps_ivy_metadata_t *args)
 
void nps_ivy_init (char *ivy_bus, bool nodisplay)
 
void nps_ivy_send_WORLD_ENV_REQ (void)
 
void nps_ivy_display (struct NpsFdm *fdm_data, struct NpsSensors *sensors_data)
 
void nps_ivy_run (void)
 

Variables

bool nps_ivy_send_world_env = false
 
static MsgRcvPtr ivyPtr = NULL
 
static int seq = 1
 
static int ap_launch_index
 
static struct nps_ivy_metadata_t nps_ivy_metadata
 

Data Structure Documentation

◆ nps_ivy_metadata_t

struct nps_ivy_metadata_t

Definition at line 43 of file nps_ivy.c.

+ Collaboration diagram for nps_ivy_metadata_t:
Data Fields
long int period_ns
struct timespec requestStart

Function Documentation

◆ find_launch_index()

int find_launch_index ( void  )

Definition at line 172 of file nps_ivy.c.

References foo, and idx.

Referenced by nps_ivy_init().

+ Here is the caller graph for this function:

◆ nps_ivy_beforeloop()

void nps_ivy_beforeloop ( struct nps_ivy_metadata_t args)

Definition at line 51 of file nps_ivy.c.

References clock_get_current_time, fdm, foo, nps_ivy_display(), and sensors.

Referenced by nps_ivy_init().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ nps_ivy_display()

void nps_ivy_display ( struct NpsFdm fdm_data,
struct NpsSensors sensors_data 
)

Definition at line 232 of file nps_ivy.c.

References double_quat_vmult(), fdm, fdm_mutex, foo, nps_ivy_send_world_env, nps_ivy_send_WORLD_ENV_REQ(), RATE_FLOAT_OF_BFP, and sensors.

Referenced by nps_ivy_beforeloop().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ nps_ivy_init()

void nps_ivy_init ( char ivy_bus,
bool  nodisplay 
)

Definition at line 72 of file nps_ivy.c.

References ap_launch_index, DISPLAY_DT, find_launch_index(), foo, nps_ivy_beforeloop(), nps_ivy_metadata, nps_ivy_send_world_env, on_DL_SETTING(), on_WORLD_ENV(), and nps_ivy_metadata_t::period_ns.

Referenced by nps_main_display().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ nps_ivy_run()

void nps_ivy_run ( void  )

Definition at line 303 of file nps_ivy.c.

References foo.

Referenced by nps_main_display().

+ Here is the caller graph for this function:

◆ nps_ivy_send_WORLD_ENV_REQ()

void nps_ivy_send_WORLD_ENV_REQ ( void  )

Definition at line 142 of file nps_ivy.c.

References fdm, foo, ivyPtr, nps_ivy_send_world_env, on_WORLD_ENV(), and seq.

Referenced by nps_ivy_display().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ on_DL_SETTING()

static void on_DL_SETTING ( IvyClientPtr  app,
void user_data,
int  argc,
char argv[] 
)
static

Definition at line 193 of file nps_ivy.c.

References ap_launch_index, DefaultChannel, DefaultDevice, foo, and nps_update_launch_from_dl().

Referenced by nps_ivy_init().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ on_WORLD_ENV()

static void on_WORLD_ENV ( IvyClientPtr  app,
void user_data,
int  argc,
char argv[] 
)
static

Definition at line 109 of file nps_ivy.c.

References foo, gps_has_fix, nps_atmosphere_set_wind_ned(), nps_set_time_factor(), FloatVect3::x, FloatVect3::y, and FloatVect3::z.

Referenced by nps_ivy_init(), and nps_ivy_send_WORLD_ENV_REQ().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Variable Documentation

◆ ap_launch_index

int ap_launch_index
static

Definition at line 31 of file nps_ivy.c.

Referenced by nps_ivy_init(), and on_DL_SETTING().

◆ ivyPtr

MsgRcvPtr ivyPtr = NULL
static

Definition at line 29 of file nps_ivy.c.

Referenced by nps_ivy_send_WORLD_ENV_REQ().

◆ nps_ivy_metadata

struct nps_ivy_metadata_t nps_ivy_metadata
static

Referenced by nps_ivy_init().

◆ nps_ivy_send_world_env

bool nps_ivy_send_world_env = false

◆ seq

int seq = 1
static