Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qgroundcontrol
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
ea6c6a91
Commit
ea6c6a91
authored
Feb 05, 2015
by
dogmaphobic
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reworking the layout of the "Return Home" Safety Dialog.
parent
c152d257
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
67 additions
and
32 deletions
+67
-32
SafetyComponent.qml
src/AutoPilotPlugins/PX4/SafetyComponent.qml
+67
-32
No files found.
src/AutoPilotPlugins/PX4/SafetyComponent.qml
View file @
ea6c6a91
...
...
@@ -10,35 +10,74 @@ Rectangle {
width
:
600
height
:
400
color
:
palette
.
window
property
var
leftColWidth
:
350
Column
{
anchors.fill
:
parent
spacing
:
20
spacing
:
40
//-----------------------------------------------------------------
//-- Return Home Triggers
Column
{
spacing
:
10
Label
{
text
:
"
Return to Land setup
"
;
color
:
palette
.
windowText
;
font.pointSize
:
20
}
spacing
:
18
Label
{
text
:
"
Triggers For Return Home
"
;
color
:
palette
.
windowText
;
font.pointSize
:
20
}
Row
{
Label
{
text
:
"
Climb to minimum altitude of
"
;
color
:
palette
.
windowText
;
anchors.baseline
:
climbField
.
baseline
}
FactTextField
{
id
:
climbField
;
fact
:
autopilot
.
parameters
[
"
RTL_RETURN_ALT
"
];
showUnits
:
true
}
FactCheckBox
{
id
:
telemetryLossCheckbox
fact
:
autopilot
.
parameters
[
"
COM_DL_LOSS_EN
"
]
width
:
leftColWidth
checkedValue
:
1
uncheckedValue
:
0
text
:
"
Telemetry signal timeout - Return Home After
"
anchors.baseline
:
telemetryLossField
.
baseline
}
FactTextField
{
id
:
telemetryLossField
fact
:
autopilot
.
parameters
[
"
NAV_DLL_N
"
];
showUnits
:
true
}
}
Row
{
Label
{
text
:
"
When Home is reached, descend to altitude of
"
;
color
:
palette
.
windowText
;
anchors.baseline
:
descendField
.
baseline
}
FactTextField
{
id
:
descendField
;
fact
:
autopilot
.
parameters
[
"
RTL_DESCEND_ALT
"
];
showUnits
:
true
}
Label
{
width
:
leftColWidth
text
:
"
RC Transmitter signal loss - Return Home After
"
color
:
palette
.
windowText
anchors.baseline
:
rcLossField
.
baseline
}
FactTextField
{
id
:
rcLossField
fact
:
autopilot
.
parameters
[
"
COM_RC_LOSS_T
"
]
showUnits
:
true
}
}
}
//-----------------------------------------------------------------
//-- Return Home Options
Column
{
spacing
:
18
Label
{
text
:
"
Return Home Options
"
;
color
:
palette
.
windowText
;
font.pointSize
:
20
}
Row
{
Label
{
width
:
leftColWidth
text
:
"
Climb to minimum altitude of
"
color
:
palette
.
windowText
anchors.baseline
:
climbField
.
baseline
}
FactTextField
{
id
:
climbField
fact
:
autopilot
.
parameters
[
"
RTL_RETURN_ALT
"
]
showUnits
:
true
}
}
Row
{
CheckBox
{
id
:
homeLoiterCheckbox
property
Fact
fact
:
autopilot
.
parameters
[
"
RTL_LAND_DELAY
"
]
width
:
leftColWidth
checked
:
fact
.
value
>
0
text
:
"
Loiter at Home altitude for
"
onClicked
:
{
fact
.
value
=
checked
?
60
:
-
1
}
style
:
CheckBoxStyle
{
label
:
Text
{
color
:
palette
.
windowText
...
...
@@ -50,38 +89,33 @@ Rectangle {
fact
:
autopilot
.
parameters
[
"
RTL_LAND_DELAY
"
];
showUnits
:
true
anchors.baseline
:
homeLoiterCheckbox
.
baseline
enabled
:
homeLoiterCheckbox
.
checked
==
true
}
}
}
Column
{
spacing
:
10
Label
{
text
:
"
Return to Land Triggers
"
;
color
:
palette
.
windowText
;
font.pointSize
:
20
}
//-------------------------------------------------------------
//-- Visible only if loiter above is checked
// TODO The "enabled" property could be used instead but it
// would have to handle a different "disabled" palette.
Row
{
FactCheckBox
{
id
:
telemetryLossCheckbox
fact
:
autopilot
.
parameters
[
"
COM_DL_LOSS_EN
"
]
checkedValue
:
1
uncheckedValue
:
0
text
:
"
Telemetry signal timeout - Return to Land
"
anchors.baseline
:
telemetryLossField
.
baseline
Label
{
width
:
leftColWidth
;
text
:
"
When Home is reached, loiter at an altitude of
"
;
color
:
palette
.
windowText
;
anchors.baseline
:
descendField
.
baseline
visible
:
homeLoiterCheckbox
.
checked
==
true
}
Label
{
text
:
"
after
"
;
color
:
palette
.
windowText
;
anchors.baseline
:
telemetryLossField
.
baseline
}
FactTextField
{
id
:
telemetryLossField
fact
:
autopilot
.
parameters
[
"
NAV_DLL_N
"
];
id
:
descendField
;
fact
:
autopilot
.
parameters
[
"
RTL_DESCEND_ALT
"
];
visible
:
homeLoiterCheckbox
.
checked
==
true
showUnits
:
true
}
}
Row
{
Label
{
text
:
"
RC Transmitter signal loss - Return to Land after
"
;
color
:
palette
.
windowText
;
anchors.baseline
:
rcLossField
.
baseline
}
FactTextField
{
id
:
rcLossField
;
fact
:
autopilot
.
parameters
[
"
COM_RC_LOSS_T
"
];
showUnits
:
true
}
}
}
Text
{
width
:
parent
.
width
font.pointSize
:
14
text
:
"
Warning: You have an advanced safety configuration set using the NAV_RCL_OBC parameter. The above settings may not apply.
"
;
visible
:
autopilot
.
parameters
[
"
NAV_RCL_OBC
"
].
value
==
1
color
:
palette
.
windowText
...
...
@@ -89,6 +123,7 @@ Rectangle {
}
Text
{
width
:
parent
.
width
font.pointSize
:
14
text
:
"
Warning: You have an advanced safety configuration set using the NAV_DLL_OBC parameter. The above settings may not apply.
"
;
visible
:
autopilot
.
parameters
[
"
NAV_DLL_OBC
"
].
value
==
1
color
:
palette
.
windowText
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment