Browse Source

pid tuning: show automatic flight mode change only for rate tuning

and stop the plot when enabling the option
QGC4.4
Beat Küng 4 years ago committed by Lorenz Meier
parent
commit
339006bf64
  1. 1
      src/AutoPilotPlugins/PX4/PX4TuningComponentCopterRate.qml
  2. 8
      src/QmlControls/PIDTuning.qml

1
src/AutoPilotPlugins/PX4/PX4TuningComponentCopterRate.qml

@ -150,6 +150,7 @@ Column { @@ -150,6 +150,7 @@ Column {
unit: "deg/s"
axis: [ roll, pitch, yaw ]
chartDisplaySec: 3
showAutoModeChange: true
}
}

8
src/QmlControls/PIDTuning.qml

@ -27,6 +27,7 @@ RowLayout { @@ -27,6 +27,7 @@ RowLayout {
property string title
property var tuningMode
property double chartDisplaySec: 8 // number of seconds to display
property bool showAutoModeChange: false
property real _margins: ScreenTools.defaultFontPixelHeight / 2
property int _currentAxis: 0
@ -293,7 +294,7 @@ RowLayout { @@ -293,7 +294,7 @@ RowLayout {
onClicked: {
dataTimer.running = !dataTimer.running
_last_t = 0
if (autoModeChange.checked) {
if (showAutoModeChange && autoModeChange.checked) {
globals.activeVehicle.flightMode = dataTimer.running ? "Stabilized" : globals.activeVehicle.pauseFlightMode
}
}
@ -301,8 +302,13 @@ RowLayout { @@ -301,8 +302,13 @@ RowLayout {
}
QGCCheckBox {
visible: showAutoModeChange
id: autoModeChange
text: qsTr("Automatic Flight Mode Switching")
onClicked: {
if (checked)
dataTimer.running = false
}
}
Column {

Loading…
Cancel
Save