APM:Libraries
Classes | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
AP_Baro_DPS280 Class Reference

#include <AP_Baro_DPS280.h>

Inheritance diagram for AP_Baro_DPS280:
[legend]
Collaboration diagram for AP_Baro_DPS280:
[legend]

Classes

struct  dps280_cal
 

Public Member Functions

 AP_Baro_DPS280 (AP_Baro &baro, AP_HAL::OwnPtr< AP_HAL::Device > dev)
 
void update ()
 
- Public Member Functions inherited from AP_Baro_Backend
 AP_Baro_Backend (AP_Baro &baro)
 
virtual ~AP_Baro_Backend (void)
 
virtual void accumulate (void)
 
virtual void handle_baro_msg (float pressure, float temperature)
 
void backend_update (uint8_t instance)
 
bool pressure_ok (float press)
 
uint32_t get_error_count () const
 

Static Public Member Functions

static AP_Baro_Backendprobe (AP_Baro &baro, AP_HAL::OwnPtr< AP_HAL::Device > dev)
 

Private Member Functions

bool init (void)
 
bool read_calibration (void)
 
void timer (void)
 
void calculate_PT (int32_t UT, int32_t UP, float &pressure, float &temperature)
 
void fix_config_bits16 (int16_t &v, uint8_t bits) const
 
void fix_config_bits32 (int32_t &v, uint8_t bits) const
 

Private Attributes

AP_HAL::OwnPtr< AP_HAL::Devicedev
 
uint8_t instance
 
uint32_t count
 
float pressure_sum
 
float temperature_sum
 
struct AP_Baro_DPS280::dps280_cal calibration
 

Additional Inherited Members

- Protected Member Functions inherited from AP_Baro_Backend
void _copy_to_frontend (uint8_t instance, float pressure, float temperature)
 
virtual void update_healthy_flag (uint8_t instance)
 
- Protected Attributes inherited from AP_Baro_Backend
AP_Baro_frontend
 
AP_HAL::Semaphore_sem
 
float _mean_pressure
 
uint32_t _error_count
 

Detailed Description

Definition at line 9 of file AP_Baro_DPS280.h.

Constructor & Destructor Documentation

◆ AP_Baro_DPS280()

AP_Baro_DPS280::AP_Baro_DPS280 ( AP_Baro baro,
AP_HAL::OwnPtr< AP_HAL::Device dev 
)

Definition at line 42 of file AP_Baro_DPS280.cpp.

Referenced by probe().

Here is the caller graph for this function:

Member Function Documentation

◆ calculate_PT()

void AP_Baro_DPS280::calculate_PT ( int32_t  UT,
int32_t  UP,
float &  pressure,
float &  temperature 
)
private

Definition at line 163 of file AP_Baro_DPS280.cpp.

Referenced by timer().

Here is the caller graph for this function:

◆ fix_config_bits16()

void AP_Baro_DPS280::fix_config_bits16 ( int16_t &  v,
uint8_t  bits 
) const
private

Definition at line 66 of file AP_Baro_DPS280.cpp.

Referenced by read_calibration().

Here is the caller graph for this function:

◆ fix_config_bits32()

void AP_Baro_DPS280::fix_config_bits32 ( int32_t &  v,
uint8_t  bits 
) const
private

Definition at line 76 of file AP_Baro_DPS280.cpp.

Referenced by read_calibration(), and timer().

Here is the caller graph for this function:

◆ init()

bool AP_Baro_DPS280::init ( void  )
private

Definition at line 123 of file AP_Baro_DPS280.cpp.

Referenced by probe().

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

◆ probe()

AP_Baro_Backend * AP_Baro_DPS280::probe ( AP_Baro baro,
AP_HAL::OwnPtr< AP_HAL::Device dev 
)
static

Definition at line 48 of file AP_Baro_DPS280.cpp.

Referenced by AP_Baro::init().

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

◆ read_calibration()

bool AP_Baro_DPS280::read_calibration ( void  )
private

Definition at line 86 of file AP_Baro_DPS280.cpp.

Referenced by init().

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

◆ timer()

void AP_Baro_DPS280::timer ( void  )
private

Definition at line 184 of file AP_Baro_DPS280.cpp.

Referenced by init().

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

◆ update()

void AP_Baro_DPS280::update ( void  )
virtual

Implements AP_Baro_Backend.

Definition at line 222 of file AP_Baro_DPS280.cpp.

Here is the call graph for this function:

Member Data Documentation

◆ calibration

struct AP_Baro_DPS280::dps280_cal AP_Baro_DPS280::calibration
private

◆ count

uint32_t AP_Baro_DPS280::count
private

Definition at line 31 of file AP_Baro_DPS280.h.

Referenced by timer(), and update().

◆ dev

AP_HAL::OwnPtr<AP_HAL::Device> AP_Baro_DPS280::dev
private

Definition at line 27 of file AP_Baro_DPS280.h.

Referenced by init(), read_calibration(), and timer().

◆ instance

uint8_t AP_Baro_DPS280::instance
private

Definition at line 29 of file AP_Baro_DPS280.h.

Referenced by init(), and update().

◆ pressure_sum

float AP_Baro_DPS280::pressure_sum
private

Definition at line 32 of file AP_Baro_DPS280.h.

Referenced by timer(), and update().

◆ temperature_sum

float AP_Baro_DPS280::temperature_sum
private

Definition at line 33 of file AP_Baro_DPS280.h.

Referenced by timer(), and update().


The documentation for this class was generated from the following files: