APM:Libraries
Public Member Functions | Private Member Functions | Private Attributes | List of all members
AP_Airspeed_SDP3X Class Reference

#include <AP_Airspeed_SDP3X.h>

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

Public Member Functions

 AP_Airspeed_SDP3X (AP_Airspeed &frontend, uint8_t _instance)
 
 ~AP_Airspeed_SDP3X (void)
 
bool init () override
 
bool get_differential_pressure (float &pressure) override
 
bool get_temperature (float &temperature) override
 
- Public Member Functions inherited from AP_Airspeed_Backend
 AP_Airspeed_Backend (AP_Airspeed &frontend, uint8_t instance)
 
virtual ~AP_Airspeed_Backend ()
 

Private Member Functions

void _timer ()
 
bool _send_command (uint16_t cmd)
 
bool _crc (const uint8_t data[], unsigned size, uint8_t checksum)
 
float _correct_pressure (float press)
 

Private Attributes

float _temp
 
float _press
 
uint16_t _temp_count
 
uint16_t _press_count
 
float _temp_sum
 
float _press_sum
 
uint32_t _last_sample_time_ms
 
uint16_t _scale
 
AP_HAL::OwnPtr< AP_HAL::I2CDevice_dev
 

Additional Inherited Members

- Protected Member Functions inherited from AP_Airspeed_Backend
int8_t get_pin (void) const
 
float get_psi_range (void) const
 
uint8_t get_bus (void) const
 
AP_Airspeed::pitot_tube_order get_tube_order (void) const
 
float get_airspeed_ratio (void) const
 
void set_use_zero_offset (void)
 
void set_skip_cal (void)
 
void set_offset (float ofs)
 
- Protected Attributes inherited from AP_Airspeed_Backend
AP_HAL::Semaphoresem
 

Detailed Description

Definition at line 34 of file AP_Airspeed_SDP3X.h.

Constructor & Destructor Documentation

◆ AP_Airspeed_SDP3X()

AP_Airspeed_SDP3X::AP_Airspeed_SDP3X ( AP_Airspeed frontend,
uint8_t  _instance 
)

Definition at line 41 of file AP_Airspeed_SDP3X.cpp.

◆ ~AP_Airspeed_SDP3X()

AP_Airspeed_SDP3X::~AP_Airspeed_SDP3X ( void  )
inline

Definition at line 38 of file AP_Airspeed_SDP3X.h.

Here is the call graph for this function:

Member Function Documentation

◆ _correct_pressure()

float AP_Airspeed_SDP3X::_correct_pressure ( float  press)
private

Definition at line 198 of file AP_Airspeed_SDP3X.cpp.

Referenced by get_differential_pressure(), and ~AP_Airspeed_SDP3X().

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

◆ _crc()

bool AP_Airspeed_SDP3X::_crc ( const uint8_t  data[],
unsigned  size,
uint8_t  checksum 
)
private

Definition at line 315 of file AP_Airspeed_SDP3X.cpp.

Referenced by _timer(), init(), and ~AP_Airspeed_SDP3X().

Here is the caller graph for this function:

◆ _send_command()

bool AP_Airspeed_SDP3X::_send_command ( uint16_t  cmd)
private

Definition at line 49 of file AP_Airspeed_SDP3X.cpp.

Referenced by _timer(), init(), and ~AP_Airspeed_SDP3X().

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

◆ _timer()

void AP_Airspeed_SDP3X::_timer ( )
private

Definition at line 159 of file AP_Airspeed_SDP3X.cpp.

Referenced by init(), and ~AP_Airspeed_SDP3X().

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

◆ get_differential_pressure()

bool AP_Airspeed_SDP3X::get_differential_pressure ( float &  pressure)
overridevirtual

Implements AP_Airspeed_Backend.

Definition at line 276 of file AP_Airspeed_SDP3X.cpp.

Referenced by ~AP_Airspeed_SDP3X().

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

◆ get_temperature()

bool AP_Airspeed_SDP3X::get_temperature ( float &  temperature)
overridevirtual

Implements AP_Airspeed_Backend.

Definition at line 295 of file AP_Airspeed_SDP3X.cpp.

Referenced by _correct_pressure(), and ~AP_Airspeed_SDP3X().

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

◆ init()

bool AP_Airspeed_SDP3X::init ( void  )
overridevirtual

Implements AP_Airspeed_Backend.

Definition at line 56 of file AP_Airspeed_SDP3X.cpp.

Referenced by ~AP_Airspeed_SDP3X().

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

Member Data Documentation

◆ _dev

AP_HAL::OwnPtr<AP_HAL::I2CDevice> AP_Airspeed_SDP3X::_dev
private

Definition at line 64 of file AP_Airspeed_SDP3X.h.

Referenced by _send_command(), _timer(), and init().

◆ _last_sample_time_ms

uint32_t AP_Airspeed_SDP3X::_last_sample_time_ms
private

Definition at line 61 of file AP_Airspeed_SDP3X.h.

Referenced by _timer(), get_differential_pressure(), and get_temperature().

◆ _press

float AP_Airspeed_SDP3X::_press
private

Definition at line 56 of file AP_Airspeed_SDP3X.h.

Referenced by get_differential_pressure().

◆ _press_count

uint16_t AP_Airspeed_SDP3X::_press_count
private

Definition at line 58 of file AP_Airspeed_SDP3X.h.

Referenced by _timer(), and get_differential_pressure().

◆ _press_sum

float AP_Airspeed_SDP3X::_press_sum
private

Definition at line 60 of file AP_Airspeed_SDP3X.h.

Referenced by _timer(), and get_differential_pressure().

◆ _scale

uint16_t AP_Airspeed_SDP3X::_scale
private

Definition at line 62 of file AP_Airspeed_SDP3X.h.

Referenced by _timer(), and init().

◆ _temp

float AP_Airspeed_SDP3X::_temp
private

Definition at line 55 of file AP_Airspeed_SDP3X.h.

Referenced by get_temperature().

◆ _temp_count

uint16_t AP_Airspeed_SDP3X::_temp_count
private

Definition at line 57 of file AP_Airspeed_SDP3X.h.

Referenced by _timer(), and get_temperature().

◆ _temp_sum

float AP_Airspeed_SDP3X::_temp_sum
private

Definition at line 59 of file AP_Airspeed_SDP3X.h.

Referenced by _timer(), and get_temperature().


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