Unverified Commit 9d68581c authored by Don Gagne's avatar Don Gagne Committed by GitHub

Merge pull request #6773 from DonLakeFlyer/CompassCalReboot

Prompt for Reboot after compass cal
parents f8f4d5ea c2eac21c
......@@ -167,7 +167,7 @@ void SensorsComponentController::_stopCalibration(SensorsComponentController::St
emit resetStatusTextArea();
}
if (_magCalInProgress) {
emit setCompassRotations();
emit magCalComplete();
}
break;
......
......@@ -92,7 +92,7 @@ signals:
void orientationCalSidesRotateChanged(void);
void resetStatusTextArea(void);
void waitingForCancelChanged(void);
void setCompassRotations(void);
void magCalComplete(void);
private slots:
void _handleUASTextMessage(int uasId, int compId, int severity, QString text);
......
......@@ -131,11 +131,11 @@ Item {
onResetStatusTextArea: statusLog.text = statusTextAreaDefaultText
onSetCompassRotations: {
if (!_sensorsHaveFixedOrientation && (showCompass0Rot || showCompass1Rot || showCompass2Rot)) {
onMagCalComplete: {
//if (!_sensorsHaveFixedOrientation && (showCompass0Rot || showCompass1Rot || showCompass2Rot)) {
setOrientationsDialogShowBoardOrientation = false
showDialog(setOrientationsDialogComponent, qsTr("Set Compass Rotation(s)"), qgcView.showDialogDefaultWidth, StandardButton.Ok)
}
showDialog(setOrientationsDialogComponent, qsTr("Compass Calibration Complete"), qgcView.showDialogDefaultWidth, StandardButton.Ok)
//}
}
onWaitingForCancelChanged: {
......@@ -252,6 +252,20 @@ Item {
anchors.top: parent.top
spacing: ScreenTools.defaultFontPixelHeight
QGCLabel {
width: parent.width
wrapMode: Text.WordWrap
text: qsTr("Set your compass orientations below and the make sure to reboot the vehicle prior to flight.")
}
QGCButton {
text: qsTr("Reboot Vehicle")
onClicked: {
controller.vehicle.rebootVehicle()
hideDialog()
}
}
QGCLabel {
width: parent.width
wrapMode: Text.WordWrap
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment