|
QGroundControl
Ground Control Station for MAVLink Drones
|
Used to group Facts together into an object hierarachy. More...
#include <FactGroup.h>
Inheritance diagram for FactGroup:
Collaboration diagram for FactGroup:Signals | |
| void | factNamesChanged () |
| void | factGroupNamesChanged () |
| void | telemetryAvailableChanged (bool telemetryAvailable) |
Public Member Functions | |
| FactGroup (int updateRateMsecs, const QString &metaDataFile, QObject *parent=nullptr, bool ignoreCamelCase=false) | |
| < false: No telemetry for these values has been received | |
| FactGroup (int updateRateMsecs, QObject *parent=nullptr, bool ignoreCamelCase=false) | |
| virtual | ~FactGroup () |
| Q_INVOKABLE bool | factExists (const QString &name) const |
| @ return true: if the fact exists in the group | |
| Q_INVOKABLE Fact * | getFact (const QString &name) const |
| Q_INVOKABLE FactGroup * | getFactGroup (const QString &name) const |
| Q_INVOKABLE void | setLiveUpdates (bool liveUpdates) |
| Turning on live updates will allow value changes to flow through as they are received. | |
| QStringList | factNames () const |
| QStringList | factGroupNames () const |
| bool | telemetryAvailable () const |
| const QMap< QString, FactGroup * > & | factGroups () const |
| virtual void | handleMessage (Vehicle *, const mavlink_message_t &) |
| Allows a FactGroup to parse incoming messages and fill in values. | |
Protected Slots | |
| virtual void | _updateAllValues () |
Protected Member Functions | |
| void | _addFact (Fact *fact, const QString &name) |
| void | _addFact (Fact *fact) |
| void | _addFactGroup (FactGroup *factGroup, const QString &name) |
| void | _addFactGroup (FactGroup *factGroup) |
| void | _loadFromJsonArray (const QJsonArray &jsonArray) |
| void | _setTelemetryAvailable (bool telemetryAvailable) |
Protected Attributes | |
| const int | _updateRateMSecs = 0 |
| Update rate for Fact::valueChanged signals, 0: immediate update. | |
| QMap< QString, Fact * > | _nameToFactMap |
| QMap< QString, FactGroup * > | _nameToFactGroupMap |
| QMap< QString, FactMetaData * > | _nameToFactMetaDataMap |
| QStringList | _factNames |
Used to group Facts together into an object hierarachy.
Definition at line 15 of file FactGroup.h.
|
explicit |
< false: No telemetry for these values has been received
Definition at line 9 of file FactGroup.cc.
References FactMetaData::createMapFromJsonFile().
|
explicit |
Definition at line 19 of file FactGroup.cc.
|
virtual |
Definition at line 28 of file FactGroup.cc.
|
inlineprotected |
Definition at line 61 of file FactGroup.h.
References _addFact(), and Fact::name().
Referenced by _addFact().
|
protected |
Definition at line 116 of file FactGroup.cc.
References _factNames, _nameToFactMap, _nameToFactMetaDataMap, _updateRateMSecs, factNamesChanged(), Fact::setMetaData(), and Fact::setSendValueChangedSignals().
Referenced by BatteryFactGroup::BatteryFactGroup(), EscStatusFactGroup::EscStatusFactGroup(), FactGroupWithId::FactGroupWithId(), RadioStatusFactGroup::RadioStatusFactGroup(), TerrainFactGroup::TerrainFactGroup(), VehicleClockFactGroup::VehicleClockFactGroup(), VehicleDistanceSensorFactGroup::VehicleDistanceSensorFactGroup(), VehicleEFIFactGroup::VehicleEFIFactGroup(), VehicleEstimatorStatusFactGroup::VehicleEstimatorStatusFactGroup(), VehicleFactGroup::VehicleFactGroup(), VehicleGeneratorFactGroup::VehicleGeneratorFactGroup(), VehicleGPSAggregateFactGroup::VehicleGPSAggregateFactGroup(), VehicleGPSFactGroup::VehicleGPSFactGroup(), VehicleHygrometerFactGroup::VehicleHygrometerFactGroup(), VehicleLocalPositionFactGroup::VehicleLocalPositionFactGroup(), VehicleLocalPositionSetpointFactGroup::VehicleLocalPositionSetpointFactGroup(), VehicleRPMFactGroup::VehicleRPMFactGroup(), VehicleSetpointFactGroup::VehicleSetpointFactGroup(), VehicleTemperatureFactGroup::VehicleTemperatureFactGroup(), VehicleVibrationFactGroup::VehicleVibrationFactGroup(), and VehicleWindFactGroup::VehicleWindFactGroup().
|
inlineprotected |
Definition at line 63 of file FactGroup.h.
References _addFactGroup().
Referenced by _addFactGroup().
|
protected |
Definition at line 133 of file FactGroup.cc.
References _nameToFactGroupMap, and factGroupNamesChanged().
Referenced by FactGroupListModel::_findOrAddFactGroupById().
|
protected |
Definition at line 33 of file FactGroup.cc.
References _nameToFactMetaDataMap, and FactMetaData::createMapFromJsonArray().
|
protected |
Definition at line 175 of file FactGroup.cc.
References telemetryAvailable(), and telemetryAvailableChanged().
Referenced by VehicleFactGroup::_handleAltitude(), VehicleFactGroup::_handleAttitude(), VehicleFactGroup::_handleAttitudeQuaternion(), VehicleGPSFactGroup::_handleGpsRawInt(), VehicleGPSFactGroup::_handleHighLatency(), VehicleGPSFactGroup::_handleHighLatency2(), VehicleHygrometerFactGroup::_handleHygrometerSensor(), VehicleFactGroup::_handleNavControllerOutput(), VehicleFactGroup::_handleRangefinder(), VehicleFactGroup::_handleRawImuTemp(), VehicleFactGroup::_handleVfrHud(), VehicleDistanceSensorFactGroup::handleMessage(), VehicleEstimatorStatusFactGroup::handleMessage(), VehicleLocalPositionFactGroup::handleMessage(), VehicleLocalPositionSetpointFactGroup::handleMessage(), VehicleSetpointFactGroup::handleMessage(), and VehicleVibrationFactGroup::handleMessage().
|
protectedvirtualslot |
Definition at line 145 of file FactGroup.cc.
References _nameToFactMap.
| bool FactGroup::factExists | ( | const QString & | name | ) | const |
@ return true: if the fact exists in the group
Definition at line 49 of file FactGroup.cc.
References _nameToFactMap, factExists(), and getFactGroup().
Referenced by factExists(), and VehicleCameraControl::mode().
|
inline |
Definition at line 44 of file FactGroup.h.
References _nameToFactGroupMap.
Referenced by InstrumentValueData::factGroupNames().
|
signal |
Referenced by _addFactGroup().
|
inline |
Definition at line 46 of file FactGroup.h.
References _nameToFactGroupMap.
|
inline |
Definition at line 43 of file FactGroup.h.
References _factNames.
Referenced by InstrumentValueData::factValueNames(), and Vehicle::Vehicle().
|
signal |
Referenced by _addFact().
| Fact * FactGroup::getFact | ( | const QString & | name | ) | const |
Definition at line 72 of file FactGroup.cc.
References _nameToFactMap, getFact(), and getFactGroup().
Referenced by VehicleCameraControl::aperture(), VehicleCameraControl::ev(), VehicleCameraControl::exposureMode(), getFact(), VehicleCameraControl::iso(), VehicleCameraControl::mode(), VehicleCameraControl::shutterSpeed(), Vehicle::Vehicle(), and VehicleCameraControl::wb().
| FactGroup * FactGroup::getFactGroup | ( | const QString & | name | ) | const |
Definition at line 102 of file FactGroup.cc.
References _nameToFactGroupMap.
Referenced by factExists(), InstrumentValueData::factValueNames(), and getFact().
|
inlinevirtual |
Allows a FactGroup to parse incoming messages and fill in values.
Reimplemented in BatteryFactGroup, EscStatusFactGroup, RadioStatusFactGroup, VehicleDistanceSensorFactGroup, VehicleEFIFactGroup, VehicleEstimatorStatusFactGroup, VehicleGeneratorFactGroup, VehicleGPS2FactGroup, VehicleHygrometerFactGroup, VehicleLocalPositionFactGroup, VehicleLocalPositionSetpointFactGroup, VehicleRPMFactGroup, VehicleSetpointFactGroup, VehicleTemperatureFactGroup, VehicleVibrationFactGroup, VehicleWindFactGroup, VehicleFactGroup, and VehicleGPSFactGroup.
Definition at line 49 of file FactGroup.h.
| void FactGroup::setLiveUpdates | ( | bool | liveUpdates | ) |
Turning on live updates will allow value changes to flow through as they are received.
Definition at line 152 of file FactGroup.cc.
References _nameToFactMap.
Referenced by Vehicle::setPIDTuningTelemetryMode().
|
inline |
Definition at line 45 of file FactGroup.h.
Referenced by _setTelemetryAvailable().
|
signal |
Referenced by _setTelemetryAvailable().
|
protected |
Definition at line 72 of file FactGroup.h.
Referenced by _addFact(), and factNames().
|
protected |
Definition at line 70 of file FactGroup.h.
Referenced by _addFactGroup(), factGroupNames(), factGroups(), and getFactGroup().
|
protected |
Definition at line 69 of file FactGroup.h.
Referenced by _addFact(), _updateAllValues(), factExists(), getFact(), and setLiveUpdates().
|
protected |
Definition at line 71 of file FactGroup.h.
Referenced by _addFact(), and _loadFromJsonArray().
|
protected |
Update rate for Fact::valueChanged signals, 0: immediate update.
Definition at line 67 of file FactGroup.h.
Referenced by _addFact().