QGroundControl
Ground Control Station for MAVLink Drones
Loading...
Searching...
No Matches
NTRIPVehicleGgaSource Class Reference

#include <NTRIPVehicleGgaSource.h>

Inheritance diagram for NTRIPVehicleGgaSource:
Collaboration diagram for NTRIPVehicleGgaSource:

Public Member Functions

 NTRIPVehicleGgaSource (RuntimeScheduler *scheduler, QObject *parent=nullptr)
 scheduler stamps receipt times and must outlive this source.
void attach (NTRIPManager *ntrip)
void setVehicle (Vehicle *vehicle)
 Tracks vehicle's reports; reports from before this call are not used.
std::optional< GPSObservation > gpsObservation () const
 The fresh observation from the vehicle's GPS with a fix.
std::optional< GPSObservation > estimateObservation () const
 The fresh observation from the vehicle's GLOBAL_POSITION_INT estimate.

Detailed Description

The active vehicle's GPS and global position estimate as NTRIP's Vehicle GPS and Vehicle EKF GGA sources. Reports only record their receipt; GGA reports, seconds apart, build observations from the latest.

Definition at line 19 of file NTRIPVehicleGgaSource.h.

Constructor & Destructor Documentation

◆ NTRIPVehicleGgaSource()

NTRIPVehicleGgaSource::NTRIPVehicleGgaSource ( RuntimeScheduler * scheduler,
QObject * parent = nullptr )
explicit

scheduler stamps receipt times and must outlive this source.

Definition at line 62 of file NTRIPVehicleGgaSource.cc.

Referenced by attach().

Member Function Documentation

◆ attach()

void NTRIPVehicleGgaSource::attach ( NTRIPManager * ntrip)

Supplies both sources to ntrip, gated on a connected active vehicle, and follows MultiVehicleManager's active vehicle. Must precede NTRIPManager::init().

Definition at line 67 of file NTRIPVehicleGgaSource.cc.

References MultiVehicleManager::activeVehicleChanged(), estimateObservation(), gpsObservation(), MultiVehicleManager::instance(), NTRIPVehicleGgaSource(), NTRIPManager::setGgaPositionProvider(), and setVehicle().

◆ estimateObservation()

std::optional< GPSObservation > NTRIPVehicleGgaSource::estimateObservation ( ) const

The fresh observation from the vehicle's GLOBAL_POSITION_INT estimate.

Definition at line 145 of file NTRIPVehicleGgaSource.cc.

References GPSObservation::Gga.

Referenced by attach().

◆ gpsObservation()

std::optional< GPSObservation > NTRIPVehicleGgaSource::gpsObservation ( ) const

The fresh observation from the vehicle's GPS with a fix.

Definition at line 132 of file NTRIPVehicleGgaSource.cc.

References GPSObservation::fixQuality, GPSObservation::Gga, GPSObservation::horizontalDop, GPSObservation::projected(), and GPSObservation::receiverFixValid.

Referenced by attach().

◆ setVehicle()

void NTRIPVehicleGgaSource::setVehicle ( Vehicle * vehicle)

Tracks vehicle's reports; reports from before this call are not used.

Definition at line 89 of file NTRIPVehicleGgaSource.cc.

References GPSProtocolMath::degreesFromE7(), Vehicle::gpsFactGroup(), Vehicle::mavlinkMessageReceived(), GPSProtocolMath::metersFromMillimeters(), and VehicleGPSFactGroup::positionReported().

Referenced by attach().


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