text:"Clicking Apply will save the changes you have made to your aiframe configuration. "+
"Your vehicle will also be rebooted in order to complete the process. "+
"After your vehicle reboots, you can reconnect it to QGroundControl."
}
}
functionaccept(){
controller.changeAutostart()
applyRestartDialog.hideDialog()
}
Rectangle{
anchors.fill:parent
QGCPalette{id:qgcPal;colorGroupEnabled:true}
color:qgcPal.window
QGCLabel{
id:header
width:parent.width
font.pointSize:ScreenTools.largeFontPointSize
text:"AIRFRAME CONFIG"
}
Item{
id:headingSpacer
anchors.top:header.bottom
height:20
width:20
QGCLabel{
anchors.fill:parent
wrapMode:Text.WordWrap
text:"Clicking Apply will save the changes you have made to your aiframe configuration. "+
"Your vehicle will also be rebooted in order to complete the process. "+
"After your vehicle reboots, you can reconnect it to QGroundControl."
}
}
}
QGCViewPanel{
id:panel
anchors.fill:parent
QGCLabel{
id:header
width:parent.width
font.pointSize:ScreenTools.largeFontPointSize
text:"AIRFRAME CONFIG"
}
Item{
id:headingSpacer
anchors.top:header.bottom
height:20
width:20
}
QGCLabel{
anchors.top:headingSpacer.bottom
width:parent.width-applyButton.width-5
text:"Select your airframe type and specific vehicle bellow. Click 'Apply and Restart' when ready and your vehicle will be disconnected, rebooted to the new settings and re-connected."
wrapMode:Text.WordWrap
}
QGCButton{
id:applyButton
anchors.top:headingSpacer.bottom
anchors.right:parent.right
text:"Apply and Restart"
onClicked:showDialog(applyRestartDialogComponent,"Apply and Restart",50,StandardButton.Apply|StandardButton.Cancel)
}
Item{
id:lastSpacer
anchors.top:applyButton.bottom
height:20
width:10
}
ScrollView{
id:scroll
anchors.top:lastSpacer.bottom
anchors.bottom:parent.bottom
width:parent.width
horizontalScrollBarPolicy:Qt.ScrollBarAlwaysOff
Flow{
width:scroll.width
spacing:10
ExclusiveGroup{
id:airframeTypeExclusive
}
QGCLabel{
anchors.top:headingSpacer.bottom
width:parent.width-applyButton.width-5
text:"Select your airframe type and specific vehicle bellow. Click 'Apply and Restart' when ready and your vehicle will be disconnected, rebooted to the new settings and re-connected."
wrapMode:Text.WordWrap
}
Repeater{
model:controller.airframeTypes
QGCButton{
id:applyButton
anchors.top:headingSpacer.bottom
anchors.right:parent.right
text:"Apply and Restart"
// Outer summary item rectangle
Rectangle{
readonlypropertyrealtitleHeight:30
readonlypropertyrealinnerMargin:10
onClicked:panel.showDialog(applyRestartDialogComponent,"Apply and Restart",50,StandardButton.Apply|StandardButton.Cancel)
onOldFirmware:showMessage("ESC Calibration","QGroundControl cannot perform ESC Calibration with this version of firmware. You will need to upgrade to a newer firmware.",StandardButton.Ok)
onNewerFirmware:showMessage("ESC Calibration","QGroundControl cannot perform ESC Calibration with this version of firmware. You will need to upgrade QGroundControl.",StandardButton.Ok)
onBatteryConnected:showMessage("ESC Calibration","Performing calibration. This will take a few seconds..",0)
onCalibrationSuccess:showMessage("ESC Calibration","Calibration complete. You can disconnect your battery now if you like.",StandardButton.Ok)
onConnectBattery:showMessage("ESC Calibration","WARNING: Props must be removed from vehicle prior to performing ESC calibration.\n\nConnect the battery now and calibration will begin.",0)
onDisconnectBattery:showMessage("ESC Calibration failed","You must disconnect the battery prior to performing ESC Calibration. Disconnect your battery and try again.",StandardButton.Ok)
onOldFirmware:showMessage("ESC Calibration","QGroundControl cannot perform ESC Calibration with this version of firmware. You will need to upgrade to a newer firmware.",StandardButton.Ok)
onNewerFirmware:showMessage("ESC Calibration","QGroundControl cannot perform ESC Calibration with this version of firmware. You will need to upgrade QGroundControl.",StandardButton.Ok)
onBatteryConnected:showMessage("ESC Calibration","Performing calibration. This will take a few seconds..",0)
onCalibrationSuccess:showMessage("ESC Calibration","Calibration complete. You can disconnect your battery now if you like.",StandardButton.Ok)
onConnectBattery:showMessage("ESC Calibration","WARNING: Props must be removed from vehicle prior to performing ESC calibration.\n\nConnect the battery now and calibration will begin.",0)
onDisconnectBattery:showMessage("ESC Calibration failed","You must disconnect the battery prior to performing ESC Calibration. Disconnect your battery and try again.",StandardButton.Ok)
}
Column{
anchors.fill:parent
spacing:10
QGCLabel{
text:"POWER CONFIG"
font.pointSize:ScreenTools.largeFontPointSize
}
QGCLabel{
text:"Battery"
color:palette.text
font.pointSize:ScreenTools.mediumFontPointSize
}
Rectangle{
width:parent.width
height:120
color:palette.windowShade
Rectangle{
width:parent.width
height:120
color:palette.windowShade
Column{
id:batteryColumn
spacing:10
anchors.verticalCenter:parent.verticalCenter
x:(parent.x+20)
Column{
id:batteryColumn
Row{
spacing:10
anchors.verticalCenter:parent.verticalCenter
x:(parent.x+20)
Row{
Column{
id:voltageCol
spacing:10
Column{
id:voltageCol
Row{
spacing:10
Row{
spacing:10
QGCLabel{text:"Number of Cells (in Series)";width:firstColumnWidth;anchors.baseline:cellsField.baseline}
FactTextField{
id:cellsField
width:textEditWidth
fact:battNumCells
showUnits:true
}
}
Row{
id:battHighRow
spacing:10
QGCLabel{text:"Full Voltage (per cell)";width:firstColumnWidth;anchors.baseline:battHighField.baseline}
FactTextField{
id:battHighField
width:textEditWidth
fact:battHighVolt
showUnits:true
}
QGCLabel{text:"Number of Cells (in Series)";width:firstColumnWidth;anchors.baseline:cellsField.baseline}
FactTextField{
id:cellsField
width:textEditWidth
fact:battNumCells
showUnits:true
}
Row{
id:battLowRow
spacing:10
QGCLabel{text:"Empty Voltage (per cell)";width:firstColumnWidth;anchors.baseline:battLowField.baseline}
FactTextField{
id:battLowField
width:textEditWidth
fact:battLowVolt
showUnits:true
}
}
Row{
id:battHighRow
spacing:10
QGCLabel{text:"Full Voltage (per cell)";width:firstColumnWidth;anchors.baseline:battHighField.baseline}
FactTextField{
id:battHighField
width:textEditWidth
fact:battHighVolt
showUnits:true
}
}
Canvas{
id:arrows
height:voltageCol.height
width:40
antialiasing:true
Connections{
target:ScreenTools
onRepaintRequestedChanged:{
arrows.requestPaint();
}
Row{
id:battLowRow
spacing:10
QGCLabel{text:"Empty Voltage (per cell)";width:firstColumnWidth;anchors.baseline:battLowField.baseline}