Library for basic air data calculations  0.5b
Public Member Functions | Public Attributes | List of all members
AirDC Class Reference

#include <AirDC.h>

Public Member Functions

 AirDC (int pid)
 
void RhoAir (int mode)
 
void IAS (int mode)
 
void CAS (int mode)
 
void TAS (int mode)
 
void Mach (int mode)
 
void OAT (int mode)
 
void ISAAltitude (int mode)
 
double CorrectDp (int SensorID, double DpMeas)
 
String OutputSerial (int mode)
 
void PitotCorrection (int mode)
 
void Viscosity (int mode)
 
void Red (int mode)
 
void CalibrationFactor (int mode)
 
void PrepareData (void)
 

Public Attributes

int _pid
 
char _status [11]
 
char _logfile [15] =DEFAULT_LOG_FILE
 
char _datasel [25] ={'0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','\0'}
 
double _dataout [25]
 
double _d
 
double _PitotXcog
 
double _PitotYcog
 
double _PitotZcog
 
double _p
 
double _pRaw
 
double _T
 
double _TRaw
 
double _RH
 
double _qc
 
double _qcRaw
 
double _AOA
 
double _AOS
 
double _pSeaLevel
 
double _Tdeltap
 
double _Tabsp
 
double _TdeltapRaw
 
double _TabspRaw
 
double _Rho
 
double _IAS
 
double _CAS
 
double _TAS
 
double _TASPCorrected
 
double _M
 
double _TAT
 
double _h
 
double _mu
 
double _Re
 
double _AOAdot
 
double _AOSdot
 
double _up
 
double _uT
 
double _uRH
 
double _uqc
 
double _uRho
 
double _uIAS
 
double _uCAS
 
double _uTAS
 
double _uTAT
 
double _uh
 
double _Ip
 
double _Iq
 
double _Ir
 
double _c
 
double _DpZeroMeas
 
double _GainDp
 

Constructor & Destructor Documentation

◆ AirDC()

AirDC::AirDC ( int  pid)

AirDC - Library for Basic Air Data calculations J.L.J (C)2015, Basic Air Data Team.
Refer to http:\www.basicairdata.eu

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implie d warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

AirDC Default constructor

Member Function Documentation

◆ CalibrationFactor()

void AirDC::CalibrationFactor ( int  mode)

Returns the calibration factor for the probe in function of operative conditions

Parameters
Mode1 fixed value c=1
Mode2 Basic Air Data 8 mm Probe
Returns
Void

◆ CAS()

void AirDC::CAS ( int  mode)

◆ CorrectDp()

double AirDC::CorrectDp ( int  SensorID,
double  DpMeas 
)

Calculates correction factor for differential pressure measurements (SI) taken by sensorID

Parameters
SensorIDIndicates the Sensor
Pascaldeltap measurement
Returns
Correction Offset [Pa]

◆ IAS()

void AirDC::IAS ( int  mode)

Calcualtes Indicated Airspeed IAS=ASI=EAS

Parameters
ModeIndicates the calculation method. 1 is Basic Air Data default http://www.basicairdata.eu/pitot-tube.html
https://en.wikipedia.org/wiki/Equivalent_airspeed
Returns
Void

◆ ISAAltitude()

void AirDC::ISAAltitude ( int  mode)

Calculates barometric altitude with ISA atmosphere

Parameters
Mode1 Uncorrected altitude above mean sea level http://www.basicairdata.eu/altimeter.html
Mode2 Corrected above mean sea level altitude, pressure at sea level should be available, https://en.wikipedia.org/wiki/QNH
Returns
Void

◆ Mach()

void AirDC::Mach ( int  mode)

◆ OAT()

void AirDC::OAT ( int  mode)

Calculates Outside Air Temperature

Parameters
ModeIndicates the calculation method. 1 is Basic Air Data default https://en.wikipedia.org/wiki/Total_air_temperature
Returns
Void

◆ OutputSerial()

String AirDC::OutputSerial ( int  mode)

◆ PitotCorrection()

void AirDC::PitotCorrection ( int  mode)

Correct TAS based on pitot placement

Parameters
Mode1 No compensation
Mode2 Steady state(no angular acceleration) assumed for this method
http://basicairdata.blogspot.it/2014/07/pitot-correction-for-position-and.html
Returns
Void

◆ PrepareData()

void AirDC::PrepareData ( void  )

Order all the data within an array

Returns
Void

◆ Red()

void AirDC::Red ( int  mode)

Calculates Re number

Parameters
Mode1 Uses _d as reference dimension
Returns
Void

◆ RhoAir()

void AirDC::RhoAir ( int  mode)

Calculates the Air Density

Parameters
ModeIndicates the calculation method. 1 is Basic Air Data default http://www.basicairdata.eu/calculation-routines.html
Returns
Void

◆ TAS()

void AirDC::TAS ( int  mode)

◆ Viscosity()

void AirDC::Viscosity ( int  mode)

Calculates Air Viscosity

Parameters
Mode1 Calculate viscosity in Pas with Sutherland's formula
Mode2 Calculate viscosity 10-6*Pas with Sutherland's formula
Returns
Void

Member Data Documentation

◆ _AOA

double AirDC::_AOA

Angle of Attack, rads

◆ _AOAdot

double AirDC::_AOAdot

Time derivate of AOA rad/s

◆ _AOS

double AirDC::_AOS

Angle of Sideslip, rads

◆ _AOSdot

double AirDC::_AOSdot

Time derivate of AOS rad/s

◆ _c

double AirDC::_c

Probe calibration factor

◆ _CAS

double AirDC::_CAS

Calibrated Air Speed m/s

◆ _d

double AirDC::_d

Reference length for Re number calculation

◆ _dataout

double AirDC::_dataout[25]

◆ _datasel

char AirDC::_datasel[25] ={'0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','\0'}

Data selection vector see communication protocol msg #9

◆ _DpZeroMeas

double AirDC::_DpZeroMeas

Sensor count value when zero differential pressure is applied

◆ _GainDp

double AirDC::_GainDp

Sensor gain

◆ _h

double AirDC::_h

Altitude m

◆ _IAS

double AirDC::_IAS

Indicated Air speed m/s

◆ _Ip

double AirDC::_Ip

Pitch rate

◆ _Iq

double AirDC::_Iq

Roll rate

◆ _Ir

double AirDC::_Ir

yaw rate

◆ _logfile

char AirDC::_logfile[15] =DEFAULT_LOG_FILE

Defines the active log file name

◆ _M

double AirDC::_M

Mach number

◆ _mu

double AirDC::_mu

Dynamic Viscosity Pas

◆ _p

double AirDC::_p

Static pressure Pa

◆ _pid

int AirDC::_pid

Class ID

◆ _PitotXcog

double AirDC::_PitotXcog

Distance along x body axes of the Pitot tip from center of gravity

◆ _PitotYcog

double AirDC::_PitotYcog

Distance along y body axes of the Pitot tip from center of gravity

◆ _PitotZcog

double AirDC::_PitotZcog

Distance along z body axes of the Pitot tip from center of gravity

◆ _pRaw

double AirDC::_pRaw

Static pressure raw sensor value

◆ _pSeaLevel

double AirDC::_pSeaLevel

Value of pressure at sea level Pa

◆ _qc

double AirDC::_qc

Differential pressure at Pitot, Pascal

◆ _qcRaw

double AirDC::_qcRaw

Raw sensor value of differential pressure at Pitot, Impact pressure minus static pressure Pa

◆ _Re

double AirDC::_Re

Reynolds Number

◆ _RH

double AirDC::_RH

Relative Humidity

◆ _Rho

double AirDC::_Rho

Air Density kg/m^3

◆ _status

char AirDC::_status[11]

Hardware Status vector see communication protocol msg #5

◆ _T

double AirDC::_T

Temperature K

◆ _Tabsp

double AirDC::_Tabsp

Temperature at absolute p sensor

◆ _TabspRaw

double AirDC::_TabspRaw

Raw temperature at absolute p sensor

◆ _TAS

double AirDC::_TAS

True Air Speed m/s

◆ _TASPCorrected

double AirDC::_TASPCorrected

True Air Speed, corrected m/s

◆ _TAT

double AirDC::_TAT

Total Air Temperature K

◆ _Tdeltap

double AirDC::_Tdeltap

Temperature at deltap sensor

◆ _TdeltapRaw

double AirDC::_TdeltapRaw

Raw temperature at deltap sensor

◆ _TRaw

double AirDC::_TRaw

Temperature sensor counts

◆ _uCAS

double AirDC::_uCAS

CAS uncertainty

◆ _uh

double AirDC::_uh

Altitude uncertainty

◆ _uIAS

double AirDC::_uIAS

IAS uncertainty

◆ _up

double AirDC::_up

Pressure uncertainty Pa

◆ _uqc

double AirDC::_uqc

Differential pressure uncertainty Pa

◆ _uRH

double AirDC::_uRH

Relative Humidity uncertainty

◆ _uRho

double AirDC::_uRho

Air density uncertainty kg/^3

◆ _uT

double AirDC::_uT

Temperature uncertainty Pa

◆ _uTAS

double AirDC::_uTAS

TAS uncertainty

◆ _uTAT

double AirDC::_uTAT

TAT uncertainty


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