25#include "positioning/PositionInfo.h"
26#include "traffic/ConnectionInfo.h"
27#include "traffic/TrafficFactor_DistanceOnly.h"
28#include "traffic/TrafficFactor_WithPosition.h"
29#include "traffic/Warning.h"
196 return m_connectivityStatus;
211 return m_errorString;
218 [[nodiscard]]
virtual QString
icon()
const = 0;
226 return m_positionInfo.value();
235 return &m_positionInfo;
250 return &m_pressureAltitude;
259 return m_receivingHeartbeat.value();
268 return &m_receivingHeartbeat;
283 return m_trafficReceiverRuntimeError.value();
292 return &m_trafficReceiverRuntimeError;
301 return m_trafficReceiverSelfTestError.value();
310 return &m_trafficReceiverSelfTestError;
349 void passwordRequest(
const QString& SSID);
358 void passwordStorageRequest(
const QString& SSID,
const QString& password);
427 virtual void setPassword(
const QString& SSID,
const QString& password)
523 QProperty<QString> m_trafficReceiverRuntimeError;
524 QProperty<QString> m_trafficReceiverSelfTestError;
525 QProperty<Traffic::ConnectionInfo> m_connectionInfo;
536 void processFLARMSentence(
const QString& sentence);
538 void processFLARMMessageGPGGA(
const QStringList& arguments);
539 void processFLARMMessageGPRMC(
const QStringList& arguments);
540 void processFLARMMessagePFLAA(
const QStringList& arguments);
541 void processFLARMMessagePFLAE(
const QStringList& arguments);
542 static void processFLARMMessagePFLAS(
const QStringList& arguments);
543 void processFLARMMessagePFLAU(
const QStringList& arguments);
544 void processFLARMMessagePFLAV(
const QStringList& arguments);
545 void processFLARMMessagePGRMZ(
const QStringList& arguments);
546 static void processFLARMMessagePXCV(
const QStringList& arguments);
547 QString m_FLARMDataBuffer;
550 bool m_canonical {
false};
551 QString m_connectivityStatus;
552 QString m_errorString;
562 QTimer m_trueAltitudeTimer;
566 QProperty<Units::Distance> m_pressureAltitude;
567 QTimer m_pressureAltitudeTimer;
571 QTimer m_heartbeatTimer;
578 QProperty<Positioning::PositionInfo> m_positionInfo;
579 QTimer m_positionInfoTimer;
Connection to a traffic data receiver.
Base class for all traffic receiver data sources.
virtual QString dataFormat() const =0
Getter function for the property with the same name.
Positioning::PositionInfo positionInfo
Position information.
Positioning::PositionInfo positionInfo() const
Getter method for property with the same name.
QString icon
Icon that can be used to represent the connection in a GUI.
bool receivingHeartbeat
Heartbeat indicator.
bool receivingHeartbeat() const
Getter function for the property with the same name.
QString trafficReceiverRuntimeError() const
Getter function for the property with the same name.
void processAPRS(const QString &data)
Process APRS-IS data.
QBindable< Traffic::ConnectionInfo > bindableConnectionInfo() const
Getter function for the property with the same name.
TrafficDataSource_Abstract(bool isCanonical, QObject *parent)
Default constructor.
void errorStringChanged(QString newError)
Notifier signal.
void connectivityStatusChanged(QString newStatus)
Notifier signal.
Traffic::ConnectionInfo connectionInfo() const
Getter function for the property with the same name.
QString trafficReceiverSelfTestError() const
Getter function for the property with the same name.
void processXGPSString(const QByteArray &data)
Process one XGPS string.
QString connectivityStatus() const
Getter function for the property with the same name.
QString dataFormat
Data format.
void setReceivingHeartbeat(bool newReceivingHeartbeat)
Setter method for the property with the same name.
void setErrorString(const QString &newErrorString=QString())
Setter function for the property with the same name.
virtual void setPassword(const QString &SSID, const QString &password)
Set password.
void warning(const Traffic::Warning &warning)
Traffic warning.
bool canonical
Canonicity.
void resetReceivingHeartbeat()
Resetter method for the property with the same name.
Units::Distance pressureAltitude
Pressure altitude.
void processGDLMessage(const QByteArray &message)
Process one GDL90 message.
void trafficReceiverHwVersion(QString result)
Traffic receiver hardware version.
void factorWithPosition(const Traffic::TrafficFactor_WithPosition &factor)
Traffic factor with position.
Units::Distance pressureAltitude() const
Getter method for property with the same name.
void setPositionInfo(const Positioning::PositionInfo &info)
Setter function for the property with the same name.
QString trafficReceiverRuntimeError
String describing the last traffic data receiver runtime error.
void receivingHeartbeatChanged(bool)
Notifier signal.
void dataReceived(QString data)
Indicates new data has arrived, can be used in the GUI for monitoring purposes.
QBindable< QString > bindableTrafficReceiverSelfTestError()
Getter function for the property with the same name.
virtual void connectToTrafficReceiver()=0
Start attempt to connect to traffic receiver.
QBindable< bool > bindableReceivingHeartbeat() const
Getter function for the property with the same name.
void processFLARMData(const QString &data)
Process FLARM/NMEA data.
virtual QString icon() const =0
Getter function for the property with the same name.
Traffic::ConnectionInfo connectionInfo
Connection Info.
QBindable< Units::Distance > bindablePressureAltitude() const
Getter method for property with the same name.
QString connectivityStatus
Connectivity status.
void setPressureAltitude(Units::Distance newPressureAltitude)
Setter function for the property with the same name.
virtual void disconnectFromTrafficReceiver()=0
Disconnect from traffic receiver.
void setConnectivityStatus(const QString &newConnectivityStatus)
Setter function for the property with the same name.
void trafficReceiverSwVersion(QString result)
Traffic receiver software version.
QBindable< Positioning::PositionInfo > bindablePositionInfo() const
Getter method for property with the same name.
QString errorString
String describing the last socket error.
QString errorString() const
Getter function for the property with the same name.
void factorWithoutPosition(const Traffic::TrafficFactor_DistanceOnly &factor)
Traffic factor without position.
QString trafficReceiverSelfTestError
String describing the last traffic data receiver self-test error.
void trafficReceiverObVersion(QString result)
Traffic receiver obstacle database version.
virtual QString sourceName() const =0
Getter function for the property with the same name.
QBindable< QString > bindableTrafficReceiverRuntimeError()
Getter function for the property with the same name.
QString sourceName
Source name.
Traffic factor where only distance is known.
Traffic factor whose precise position is known.
Convenience class for distance computations.
Conversion between units used in aviation.