QGroundControl
Ground Control Station for MAVLink Drones
Loading...
Searching...
No Matches
GPSReceiverDescriptor.h File Reference
#include <optional>
#include <span>
#include <QtCore/QLatin1StringView>
#include <QtCore/QObject>
#include <QtCore/QString>
#include "GPSType.h"
+ Include dependency graph for GPSReceiverDescriptor.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  GPSReceiverCapabilities
 Software request support, not a guarantee for every physical receiver model or firmware. More...
 
struct  GPSReceiverDescriptor
 Persisted manufacturer IDs are distinct from GPSType values. More...
 
struct  GPSReceiverPresentation
 

Functions

std::span< const GPSReceiverDescriptor > gpsReceiverDescriptors ()
 
const GPSReceiverDescriptor * gpsReceiverDescriptor (GPSType type)
 
const GPSReceiverDescriptor * gpsReceiverDescriptorForManufacturer (int manufacturer)
 
std::optional< GPSType > gpsReceiverTypeForManufacturer (int manufacturer)
 The family a persisted manufacturer selects, GPSType::automatic for GPS_AUTOMATIC_MANUFACTURER; empty when unknown.
 
int gpsReceiverManufacturerForType (GPSType type)
 The persisted manufacturer of type, or GPS_AUTOMATIC_MANUFACTURER when it has none.
 
GPSReceiverCapabilities gpsReceiverCapabilities (GPSType type)
 What type supports, for either role; unknown receiver families support nothing.
 
QString gpsReceiverName (GPSType type)
 The name of type's receiver family as shown to users; empty when no descriptor exists.
 
QString gpsInputProtocolName (GPSType type)
 
const GPSReceiverPresentation & gpsReceiverPresentation (int manufacturer)
 

Variables

constexpr int GPS_AUTOMATIC_MANUFACTURER = 0
 

Function Documentation

◆ gpsInputProtocolName()

QString gpsInputProtocolName ( GPSType  type)

How the protocol a passive input decodes is shown to users: the family and its protocol, such as "u-blox (UBX)", or "NMEA" for GPSType::passive; empty for a family without a protocol of its own.

Definition at line 114 of file GPSReceiverDescriptor.cc.

References gpsReceiverDescriptor(), and gpsReceiverName().

Referenced by GPSReceiver::detectedReceiver().

◆ gpsReceiverCapabilities()

◆ gpsReceiverDescriptor()

◆ gpsReceiverDescriptorForManufacturer()

const GPSReceiverDescriptor * gpsReceiverDescriptorForManufacturer ( int  manufacturer)

◆ gpsReceiverDescriptors()

std::span< const GPSReceiverDescriptor > gpsReceiverDescriptors ( )

Definition at line 97 of file GPSReceiverDescriptor.cc.

◆ gpsReceiverManufacturerForType()

int gpsReceiverManufacturerForType ( GPSType  type)

The persisted manufacturer of type, or GPS_AUTOMATIC_MANUFACTURER when it has none.

Definition at line 141 of file GPSReceiverDescriptor.cc.

References GPS_AUTOMATIC_MANUFACTURER, and gpsReceiverDescriptor().

Referenced by GPSReceiver::capabilitiesFor(), and GPSReceiverSession::manufacturer().

◆ gpsReceiverName()

QString gpsReceiverName ( GPSType  type)

◆ gpsReceiverPresentation()

const GPSReceiverPresentation & gpsReceiverPresentation ( int  manufacturer)

◆ gpsReceiverTypeForManufacturer()

std::optional< GPSType > gpsReceiverTypeForManufacturer ( int  manufacturer)

The family a persisted manufacturer selects, GPSType::automatic for GPS_AUTOMATIC_MANUFACTURER; empty when unknown.

Definition at line 130 of file GPSReceiverDescriptor.cc.

References GPS_AUTOMATIC_MANUFACTURER, and gpsReceiverDescriptorForManufacturer().

Variable Documentation

◆ GPS_AUTOMATIC_MANUFACTURER

constexpr int GPS_AUTOMATIC_MANUFACTURER = 0
inlineconstexpr

The persisted manufacturer that detects the receiver family on every connect (GPSType::automatic). Its settings view combines the editable fields of every family.

Definition at line 26 of file GPSReceiverDescriptor.h.

Referenced by gpsReceiverManufacturerForType(), gpsReceiverPresentation(), and gpsReceiverTypeForManufacturer().