Avionics
Core avionics package for CURE flight computers
Loading...
Searching...
No Matches
GroundLevelEstimator Class Reference

#include <GroundLevelEstimator.h>

Collaboration diagram for GroundLevelEstimator:
Collaboration graph

Public Member Functions

 GroundLevelEstimator ()
 Constructs a GroundLevelEstimator.
float update (float currentASL_m)
 Updates the ground level estimate or converts ASL to AGL.
void launchDetected ()
 Signals that launch has been detected.
float getEGL () const
 Gets the estimated ground level.

Detailed Description

Definition at line 15 of file GroundLevelEstimator.h.

Constructor & Destructor Documentation

◆ GroundLevelEstimator()

GroundLevelEstimator::GroundLevelEstimator ( )

Constructs a GroundLevelEstimator.

Definition at line 4 of file GroundLevelEstimator.cpp.

Member Function Documentation

◆ getEGL()

float GroundLevelEstimator::getEGL ( ) const

Gets the estimated ground level.

Returns
Altitude above sea level at the launch site in meters.

Definition at line 36 of file GroundLevelEstimator.cpp.

◆ launchDetected()

void GroundLevelEstimator::launchDetected ( )

Signals that launch has been detected.

Stops recording ground level measurements and freezes the EGL. Should be called once when launch is confirmed.

Definition at line 30 of file GroundLevelEstimator.cpp.

◆ update()

float GroundLevelEstimator::update ( float currentASL_m)

Updates the ground level estimate or converts ASL to AGL.

Before launch: Records altitude samples to estimate ground level. After launch: Converts the provided ASL altitude to AGL. *

Parameters
currentASL_mCurrent altitude above sea level in meters.
Returns
Current altitude above ground level in meters.

Definition at line 9 of file GroundLevelEstimator.cpp.


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