Browse Source

Merge pull request #5951 from DonLakeFlyer/CalFixes

Calibration fixes
QGC4.4
Don Gagne 7 years ago committed by GitHub
parent
commit
c08104b757
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 30
      src/AutoPilotPlugins/PX4/SensorsSetup.qml
  2. 2
      src/FactSystem/ParameterManager.cc

30
src/AutoPilotPlugins/PX4/SensorsSetup.qml

@ -42,9 +42,9 @@ Item { @@ -42,9 +42,9 @@ Item {
readonly property string boardRotationText: qsTr("If the orientation is in the direction of flight, select ROTATION_NONE.")
readonly property string compassRotationText: qsTr("If the orientation is in the direction of flight, select ROTATION_NONE.")
readonly property string compassHelp: qsTr("For Compass calibration you will need to rotate your vehicle through a number of positions. Click Ok to start calibration.")
readonly property string gyroHelp: qsTr("For Gyroscope calibration you will need to place your vehicle on a surface and leave it still. Click Ok to start calibration.")
readonly property string accelHelp: qsTr("For Accelerometer calibration you will need to place your vehicle on all six sides on a perfectly level surface and hold it still in each orientation for a few seconds. Click Ok to start calibration.")
readonly property string compassHelp: qsTr("For Compass calibration you will need to rotate your vehicle through a number of positions.\n\nClick Ok to start calibration.")
readonly property string gyroHelp: qsTr("For Gyroscope calibration you will need to place your vehicle on a surface and leave it still.\n\nClick Ok to start calibration.")
readonly property string accelHelp: qsTr("For Accelerometer calibration you will need to place your vehicle on all six sides on a perfectly level surface and hold it still in each orientation for a few seconds.\n\nClick Ok to start calibration.")
readonly property string levelHelp: qsTr("To level the horizon you need to place the vehicle in its level flight position and press OK.")
readonly property string airspeedHelp: qsTr("For Airspeed calibration you will need to keep your airspeed sensor out of any wind and then blow across the sensor. Do not touch the sensor or obstruct any holes during the calibration.")
@ -177,15 +177,10 @@ Item { @@ -177,15 +177,10 @@ Item {
Column {
anchors.fill: parent
spacing: ScreenTools.defaultFontPixelWidth / 2
QGCLabel {
width: parent.width
wrapMode: Text.WordWrap
text: preCalibrationDialogHelp
}
spacing: ScreenTools.defaultFontPixelHeight
Column {
width: parent.width
spacing: 5
visible: !_sensorsHaveFixedOrientation
@ -194,14 +189,13 @@ Item { @@ -194,14 +189,13 @@ Item {
width: parent.width
wrapMode: Text.WordWrap
visible: (preCalibrationDialogType != "airspeed") && (preCalibrationDialogType != "gyro")
text: boardRotationText
text: qsTr("Set autopilot orientation before calibrating.")
}
Column {
visible: boardRotationHelp.visible
QGCLabel {
text: qsTr("Autopilot Orientation:")
}
QGCLabel { text: qsTr("Autopilot Orientation:") }
FactComboBox {
id: boardRotationCombo
@ -211,6 +205,12 @@ Item { @@ -211,6 +205,12 @@ Item {
}
}
}
QGCLabel {
width: parent.width
wrapMode: Text.WordWrap
text: preCalibrationDialogHelp
}
}
}
}
@ -394,7 +394,7 @@ Item { @@ -394,7 +394,7 @@ Item {
id: levelButton
width: _buttonWidth
text: qsTr("Level Horizon")
indicatorGreen: sens_board_x_off.value != 0 || sens_board_y_off != 0 | sens_board_z_off != 0
indicatorGreen: sens_board_x_off.value != 0 || sens_board_y_off.value != 0 | sens_board_z_off.value != 0
enabled: cal_acc0_id.value != 0 && cal_gyro0_id.value != 0
visible: QGroundControl.corePlugin.options.showSensorCalibrationLevel && showSensorCalibrationLevel

2
src/FactSystem/ParameterManager.cc

@ -837,6 +837,8 @@ void ParameterManager::_tryCacheHashLoad(int vehicleId, int componentId, QVarian @@ -837,6 +837,8 @@ void ParameterManager::_tryCacheHashLoad(int vehicleId, int componentId, QVarian
});
ani->start(QAbstractAnimation::DeleteWhenStopped);
} else {
qCInfo(ParameterManagerLog) << "Parameters cache match failed" << qPrintable(QFileInfo(cache_file).absoluteFilePath());
}
}

Loading…
Cancel
Save