Paparazzi UAS v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
airspeed_uavcan.c File Reference

Airspeed sensor on the uavcan bus. More...

#include "airspeed_uavcan.h"
#include "uavcan/uavcan.h"
#include "core/abi.h"
#include "uavcan.equipment.air_data.RawAirData.h"
#include "modules/datalink/telemetry.h"
+ Include dependency graph for airspeed_uavcan.c:

Go to the source code of this file.

Macros

#define AIRSPEED_UAVCAN_SEND_ABI   true
 
#define AIRSPEED_UAVCAN_DIFF_P_SCALE   1.0f
 

Functions

static void airspeed_uavcan_downlink (struct transport_tx *trans, struct link_device *dev)
 
static void airspeed_uavcan_cb (struct uavcan_iface_t *iface, CanardRxTransfer *transfer)
 
void airspeed_uavcan_init (void)
 
void airspeed_uavcan_autoset_offset (bool set)
 

Variables

struct airspeed_uavcan_t airspeed_uavcan = {0}
 
static uavcan_event airspeed_uavcan_ev
 

Detailed Description

Airspeed sensor on the uavcan bus.

Definition in file airspeed_uavcan.c.

Macro Definition Documentation

◆ AIRSPEED_UAVCAN_DIFF_P_SCALE

#define AIRSPEED_UAVCAN_DIFF_P_SCALE   1.0f

Definition at line 38 of file airspeed_uavcan.c.

◆ AIRSPEED_UAVCAN_SEND_ABI

#define AIRSPEED_UAVCAN_SEND_ABI   true

Definition at line 33 of file airspeed_uavcan.c.

Function Documentation

◆ airspeed_uavcan_autoset_offset()

void airspeed_uavcan_autoset_offset ( bool  set)

◆ airspeed_uavcan_cb()

static void airspeed_uavcan_cb ( struct uavcan_iface_t iface,
CanardRxTransfer transfer 
)
static

Definition at line 83 of file airspeed_uavcan.c.

References airspeed_filter, airspeed_uavcan, airspeed_uavcan_t::diff_p, airspeed_uavcan_t::diff_p_offset, airspeed_uavcan_t::diff_p_scale, foo, msg, airspeed_uavcan_t::temperature, transfer(), UAVCAN_SENDER_ID, and update_butterworth_2_low_pass().

Referenced by airspeed_uavcan_init().

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

◆ airspeed_uavcan_downlink()

static void airspeed_uavcan_downlink ( struct transport_tx trans,
struct link_device dev 
)
static

Definition at line 63 of file airspeed_uavcan.c.

References airspeed_uavcan, dev, airspeed_uavcan_t::diff_p, foo, offset, sign(), airspeed_uavcan_t::temperature, and UAVCAN_SENDER_ID.

Referenced by airspeed_uavcan_init().

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

◆ airspeed_uavcan_init()

Variable Documentation

◆ airspeed_uavcan

◆ airspeed_uavcan_ev

uavcan_event airspeed_uavcan_ev
static

Definition at line 58 of file airspeed_uavcan.c.

Referenced by airspeed_uavcan_init().