|
QGroundControl
Ground Control Station for MAVLink Drones
|
#include <GPSCorrectionManager.h>
Inheritance diagram for GPSCorrectionManager:
Collaboration diagram for GPSCorrectionManager:Classes | |
| struct | Configuration |
| The correction settings as values; the application's settings binding supplies them. More... | |
| struct | UdpInputConfiguration |
| struct | UdpOutputConfiguration |
Public Types | |
| enum class | State { Inactive , Waiting , Fresh } |
| Whether vehicles receive RTK corrections, across NTRIP, UDP input, and the local receiver. More... | |
Signals | |
| void | stateChanged () |
| void | selectedBytesPerSecondChanged () |
| void | vehicleBytesSubmittedChanged () |
| void | udpInputChanged () |
| void | udpOutputChanged () |
Public Member Functions | |
| GPSCorrectionManager (QObject *parent=nullptr, RuntimeScheduler *scheduler=nullptr) | |
| ~GPSCorrectionManager () override | |
| void | shutdown () |
| RTCMMAVLink * | rtcmMavlink () |
| The vehicle output, whose links tests replace with RTCMMAVLink::setOutputProvider(). | |
| void | setConfiguration (const Configuration &configuration) |
| Applies the parts that changed; ignored after shutdown(). | |
| std::unique_ptr< GPSCorrectionSourceHandle > | openSource (GPSCorrectionSettings::CorrectionSource source, const QString &instance) |
| State | state () const |
| As last published with stateChanged(). | |
| GPSCorrectionStream | selectedStream () const |
| quint64 | selectedBytesPerSecond () const |
| Rate of the corrections sent from the selected stream. | |
| quint64 | vehicleBytesSubmitted () const |
| Bytes of the selected streams that vehicle links admitted, from every source since startup. | |
| QString | udpInputError () const |
| Why the enabled UDP input is not listening; empty while it listens or is disabled. | |
| QString | udpOutputError () const |
| Why the enabled UDP output does not forward; empty while it forwards or is disabled. | |
Static Public Member Functions | |
| static Q_INVOKABLE QString | sourceName (int source) |
Friends | |
| class | GPSCorrectionSourceHandle |
Owns the shared MAVLink sequence domain and the UDP correction input and output for all GPS sources. The selected stream goes to vehicles over MAVLink and to UDP forwarding. Receipt times are on the scheduler's clock; producers on worker threads stamp with the steady clock, which the application's QtRuntimeScheduler uses.
Definition at line 45 of file GPSCorrectionManager.h.
|
strong |
Whether vehicles receive RTK corrections, across NTRIP, UDP input, and the local receiver.
| Enumerator | |
|---|---|
| Inactive | No correction source is enabled. |
| Waiting | A source is enabled, but no fresh stream is selected for vehicles. |
| Fresh | A fresh stream is selected for vehicles. |
Definition at line 61 of file GPSCorrectionManager.h.
|
explicit |
Definition at line 58 of file GPSCorrectionManager.cc.
References RuntimeScheduler::nowUs().
|
override |
Definition at line 87 of file GPSCorrectionManager.cc.
References shutdown().
| std::unique_ptr< GPSCorrectionSourceHandle > GPSCorrectionManager::openSource | ( | GPSCorrectionSettings::CorrectionSource | source, |
| const QString & | instance | ||
| ) |
Begins source, which delivers the stream instance, until the returned handle is destroyed. A category has one source at a time, so a replacement opens after the previous handle is gone.
Definition at line 81 of file GPSCorrectionManager.cc.
References GPSCorrectionSourceHandle.
Referenced by GPSReceiverSession::registerCorrections().
|
inline |
The vehicle output, whose links tests replace with RTCMMAVLink::setOutputProvider().
Definition at line 105 of file GPSCorrectionManager.h.
|
inline |
Rate of the corrections sent from the selected stream.
Definition at line 122 of file GPSCorrectionManager.h.
|
signal |
|
inline |
The fresh stream selected for vehicles, as last published with stateChanged(); a HighestPriority source when none is.
Definition at line 119 of file GPSCorrectionManager.h.
| void GPSCorrectionManager::setConfiguration | ( | const Configuration & | configuration | ) |
Applies the parts that changed; ignored after shutdown().
Definition at line 93 of file GPSCorrectionManager.cc.
References GPSCorrectionSelector::configure(), GPSCorrectionManager::UdpInputConfiguration::enabled, RuntimeScheduler::nowMs(), GPSCorrectionManager::Configuration::source, GPSCorrectionManager::Configuration::udpInput, udpInputChanged(), GPSCorrectionManager::Configuration::udpOutput, and udpOutputChanged().
Referenced by GPSSettingsBindings::bindCorrections().
| void GPSCorrectionManager::shutdown | ( | ) |
Definition at line 253 of file GPSCorrectionManager.cc.
References ScheduledTask::cancel(), RTCMMAVLink::setOutputProvider(), GPSCorrectionSelector::shutdown(), RTCMUdpInput::stop(), and UdpForwarder::stop().
Referenced by GPSManager::shutdown(), and ~GPSCorrectionManager().
|
static |
Definition at line 207 of file GPSCorrectionManager.cc.
References GPSCorrectionSettings::HighestPriority, GPSCorrectionSettings::LocalReceiver, GPSCorrectionSettings::Ntrip, and GPSCorrectionSettings::Udp.
|
inline |
As last published with stateChanged().
Definition at line 115 of file GPSCorrectionManager.h.
|
signal |
|
signal |
Referenced by setConfiguration().
|
inline |
Why the enabled UDP input is not listening; empty while it listens or is disabled.
Definition at line 128 of file GPSCorrectionManager.h.
|
signal |
Referenced by setConfiguration().
|
inline |
Why the enabled UDP output does not forward; empty while it forwards or is disabled.
Definition at line 131 of file GPSCorrectionManager.h.
|
inline |
Bytes of the selected streams that vehicle links admitted, from every source since startup.
Definition at line 125 of file GPSCorrectionManager.h.
References RTCMMAVLink::totalBytesSubmitted().
|
signal |
|
friend |
Definition at line 57 of file GPSCorrectionManager.h.
Referenced by openSource().