SafetyComponentSummary.qml 1.52 KB
Newer Older
1 2
import QtQuick 2.2
import QtQuick.Controls 1.2
3

4
import QGroundControl.FactSystem 1.0
5
import QGroundControl.FactControls 1.0
6
import QGroundControl.Controls 1.0
7

8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
FactPanel {
    anchors.fill: parent

    Fact { id: returnAltFact;   name: "RTL_RETURN_ALT";     onFactMissing: showMissingFactOverlay(name) }
    Fact { id: descendAltFact;  name: "RTL_DESCEND_ALT";    onFactMissing: showMissingFactOverlay(name) }
    Fact { id: landDelayFact;   name: "RTL_LAND_DELAY";     onFactMissing: showMissingFactOverlay(name) }
    Fact { id: commDLLossFact;  name: "COM_DL_LOSS_EN";     onFactMissing: showMissingFactOverlay(name) }
    Fact { id: commRCLossFact;  name: "COM_RC_LOSS_T";      onFactMissing: showMissingFactOverlay(name) }

    Column {
        anchors.fill:       parent
        anchors.margins:    8

        VehicleSummaryRow {
            labelText: "RTL min alt:"
            valueText: returnAltFact.valueString
        }

        VehicleSummaryRow {
            labelText: "RTL home alt:"
            valueText: descendAltFact.valueString
        }

        VehicleSummaryRow {
            labelText: "RTL loiter delay:"
            valueText: landDelayFact.value < 0 ? "Disabled" : landDelayFact.valueString
        }

        VehicleSummaryRow {
            labelText: "Telemetry loss RTL:"
            valueText: commDLLossFact.value != -1 ? "Disabled" : commDLLossFact.valueString
        }

        VehicleSummaryRow {
            labelText: "RC loss RTL (seconds):"
            valueText: commRCLossFact.valueString
        }
45 46
    }
}