QGroundControl
Ground Control Station for MAVLink Drones
Loading...
Searching...
No Matches
TelemetryRSSIIndicator.qml
Go to the documentation of this file.
1import QtQuick
2import QtQuick.Layouts
3
4import QGroundControl
5import QGroundControl.Controls
6
7//-------------------------------------------------------------------------
8//-- Telemetry RSSI
9Item {
10 id: control
11 objectName: "toolbar_telemetryRSSIIndicator"
12 anchors.top: parent.top
13 anchors.bottom: parent.bottom
14 width: telemIcon.width * 1.1
15
16 property bool showIndicator: _hasTelemetry
17
18 property var _activeVehicle: QGroundControl.multiVehicleManager.activeVehicle
19 property var _radioStatus: _activeVehicle.radioStatus
20 property bool _hasTelemetry: _radioStatus.lrssi.rawValue !== 0
21
22 QGCColoredImage {
23 id: telemIcon
24 anchors.top: parent.top
25 anchors.bottom: parent.bottom
26 width: height
27 sourceSize.height: height
28 source: "/qmlimages/TelemRSSI.svg"
29 fillMode: Image.PreserveAspectFit
30 color: qgcPal.buttonText
31 }
32
33 MouseArea {
34 anchors.fill: parent
35 onClicked: mainWindow.showIndicatorDrawer(telemRSSIInfoPage, control)
36 }
37
38 Component {
39 id: telemRSSIInfoPage
40
41 ToolIndicatorPage {
42 showExpand: false
43
44 contentComponent: SettingsGroupLayout {
45 heading: qsTr("Telemetry RSSI Status")
46
47 LabelledLabel {
48 label: qsTr("Local RSSI:")
49 labelText: _radioStatus.lrssi.rawValue + " " + qsTr("dBm")
50 }
51
52 LabelledLabel {
53 label: qsTr("Remote RSSI:")
54 labelText: _radioStatus.rrssi.rawValue + " " + qsTr("dBm")
55 }
56
57 LabelledLabel {
58 label: qsTr("RX Errors:")
59 labelText: _radioStatus.rxErrors.rawValue
60 }
61
62 LabelledLabel {
63 label: qsTr("Errors Fixed:")
64 labelText: _radioStatus.fixed.rawValue
65 }
66
67 LabelledLabel {
68 label: qsTr("TX Buffer:")
69 labelText: _radioStatus.txBuffer.rawValue
70 }
71
72 LabelledLabel {
73 label: qsTr("Local Noise:")
74 labelText: _radioStatus.lNoise.rawValue
75 }
76
77 LabelledLabel {
78 label: qsTr("Remote Noise:")
79 labelText: _radioStatus.rNoise.rawValue
80 }
81 }
82 }
83 }
84}