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 anchors.top: parent.top
12 anchors.bottom: parent.bottom
13 width: telemIcon.width * 1.1
14
15 property bool showIndicator: _hasTelemetry
16
17 property var _activeVehicle: QGroundControl.multiVehicleManager.activeVehicle
18 property var _radioStatus: _activeVehicle.radioStatus
19 property bool _hasTelemetry: _radioStatus.lrssi.rawValue !== 0
20
21 QGCColoredImage {
22 id: telemIcon
23 anchors.top: parent.top
24 anchors.bottom: parent.bottom
25 width: height
26 sourceSize.height: height
27 source: "/qmlimages/TelemRSSI.svg"
28 fillMode: Image.PreserveAspectFit
29 color: qgcPal.buttonText
30 }
31
32 MouseArea {
33 anchors.fill: parent
34 onClicked: mainWindow.showIndicatorDrawer(telemRSSIInfoPage, control)
35 }
36
37 Component {
38 id: telemRSSIInfoPage
39
40 ToolIndicatorPage {
41 showExpand: false
42
43 contentComponent: SettingsGroupLayout {
44 heading: qsTr("Telemetry RSSI Status")
45
46 LabelledLabel {
47 label: qsTr("Local RSSI:")
48 labelText: _radioStatus.lrssi.rawValue + " " + qsTr("dBm")
49 }
50
51 LabelledLabel {
52 label: qsTr("Remote RSSI:")
53 labelText: _radioStatus.rrssi.rawValue + " " + qsTr("dBm")
54 }
55
56 LabelledLabel {
57 label: qsTr("RX Errors:")
58 labelText: _radioStatus.rxErrors.rawValue
59 }
60
61 LabelledLabel {
62 label: qsTr("Errors Fixed:")
63 labelText: _radioStatus.fixed.rawValue
64 }
65
66 LabelledLabel {
67 label: qsTr("TX Buffer:")
68 labelText: _radioStatus.txBuffer.rawValue
69 }
70
71 LabelledLabel {
72 label: qsTr("Local Noise:")
73 labelText: _radioStatus.lNoise.rawValue
74 }
75
76 LabelledLabel {
77 label: qsTr("Remote Noise:")
78 labelText: _radioStatus.rNoise.rawValue
79 }
80 }
81 }
82 }
83}