mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-01-18 03:52:11 +01:00
OP-1635 Remove QuadH in config tab - AirframeType
This commit is contained in:
parent
4245db7b31
commit
6da3c99af2
@ -304,7 +304,6 @@ FrameType_t GetCurrentFrameType()
|
||||
switch ((SystemSettingsAirframeTypeOptions)airframe_type) {
|
||||
case SYSTEMSETTINGS_AIRFRAMETYPE_QUADX:
|
||||
case SYSTEMSETTINGS_AIRFRAMETYPE_QUADP:
|
||||
case SYSTEMSETTINGS_AIRFRAMETYPE_QUADH:
|
||||
case SYSTEMSETTINGS_AIRFRAMETYPE_HEXA:
|
||||
case SYSTEMSETTINGS_AIRFRAMETYPE_OCTO:
|
||||
case SYSTEMSETTINGS_AIRFRAMETYPE_OCTOX:
|
||||
|
@ -893,7 +893,7 @@ Item {
|
||||
|
||||
Text {
|
||||
text: ["FixedWing", "FixedWingElevon", "FixedWingVtail", "VTOL", "HeliCP", "QuadX", "QuadP",
|
||||
"QuadH", "Hexa+", "Octo+", "Custom", "HexaX", "HexaH", "OctoV", "OctoCoaxP", "OctoCoaxX", "OctoX", "HexaCoax",
|
||||
"Hexa+", "Octo+", "Custom", "HexaX", "HexaH", "OctoV", "OctoCoaxP", "OctoCoaxX", "OctoX", "HexaCoax",
|
||||
"Tricopter", "GroundVehicleCar", "GroundVehicleDiff", "GroundVehicleMoto"][SystemSettings.AirframeType]
|
||||
anchors.right: parent.right
|
||||
color: "white"
|
||||
|
@ -24,10 +24,10 @@ Item {
|
||||
property variant thrustmodeColors : ["green", "grey", "grey", "grey", "grey", "grey", "grey", "grey",
|
||||
"green", "green", "green", "cyan"]
|
||||
|
||||
// SystemSettings.AirframeType 3 - 18 : VtolPathFollower, check ThrustControl
|
||||
// SystemSettings.AirframeType 3 - 17 : VtolPathFollower, check ThrustControl
|
||||
|
||||
property var thrust_mode: FlightStatus.FlightMode < 7 ? StabilizationDesired.StabilizationMode_Thrust :
|
||||
FlightStatus.FlightMode > 6 && SystemSettings.AirframeType > 2 && SystemSettings.AirframeType < 19
|
||||
FlightStatus.FlightMode > 6 && SystemSettings.AirframeType > 2 && SystemSettings.AirframeType < 18
|
||||
&& VtolPathFollowerSettings.ThrustControl == 1 ? 11 :
|
||||
FlightStatus.FlightMode > 6 && SystemSettings.AirframeType < 3 ? 11: 0
|
||||
|
||||
|
@ -154,7 +154,7 @@ ConfigMultiRotorWidget::ConfigMultiRotorWidget(QWidget *parent) :
|
||||
m_aircraft->quadShape->setScene(scene);
|
||||
|
||||
QStringList multiRotorTypes;
|
||||
multiRotorTypes << "Tricopter Y" << "Quad +" << "Quad X" << "Quad H" << "Hexacopter" << "Hexacopter X" << "Hexacopter H"
|
||||
multiRotorTypes << "Tricopter Y" << "Quad +" << "Quad X" << "Hexacopter" << "Hexacopter X" << "Hexacopter H"
|
||||
<< "Hexacopter Y6" << "Octocopter" << "Octocopter X" << "Octocopter V" << "Octo Coax +" << "Octo Coax X";
|
||||
m_aircraft->multirotorFrameType->addItems(multiRotorTypes);
|
||||
|
||||
@ -195,12 +195,6 @@ void ConfigMultiRotorWidget::setupUI(QString frameType)
|
||||
m_aircraft->mrRollMixLevel->setValue(50);
|
||||
m_aircraft->mrPitchMixLevel->setValue(50);
|
||||
setYawMixLevel(50);
|
||||
} else if (frameType == "QuadH" || frameType == "Quad H") {
|
||||
setComboCurrentIndex(m_aircraft->multirotorFrameType, m_aircraft->multirotorFrameType->findText("Quad H"));
|
||||
|
||||
m_aircraft->mrRollMixLevel->setValue(50);
|
||||
m_aircraft->mrPitchMixLevel->setValue(70);
|
||||
setYawMixLevel(50);
|
||||
} else if (frameType == "QuadP" || frameType == "Quad +") {
|
||||
setComboCurrentIndex(m_aircraft->multirotorFrameType, m_aircraft->multirotorFrameType->findText("Quad +"));
|
||||
|
||||
@ -296,8 +290,6 @@ void ConfigMultiRotorWidget::setupEnabledControls(QString frameType)
|
||||
enableComboBoxes(this, CHANNELBOXNAME, 4, true);
|
||||
} else if (frameType == "QuadP" || frameType == "Quad +") {
|
||||
enableComboBoxes(this, CHANNELBOXNAME, 4, true);
|
||||
} else if (frameType == "QuadH" || frameType == "Quad H") {
|
||||
enableComboBoxes(this, CHANNELBOXNAME, 4, true);
|
||||
} else if (frameType == "Hexa" || frameType == "Hexacopter") {
|
||||
enableComboBoxes(this, CHANNELBOXNAME, 6, true);
|
||||
} else if (frameType == "HexaX" || frameType == "Hexacopter X") {
|
||||
@ -445,12 +437,6 @@ void ConfigMultiRotorWidget::refreshWidgetsValues(QString frameType)
|
||||
setComboCurrentIndex(m_aircraft->multiMotorChannelBox2, multi.VTOLMotorNE);
|
||||
setComboCurrentIndex(m_aircraft->multiMotorChannelBox3, multi.VTOLMotorSE);
|
||||
setComboCurrentIndex(m_aircraft->multiMotorChannelBox4, multi.VTOLMotorSW);
|
||||
} else if (frameType == "QuadH") {
|
||||
// Motors 1/2/3/4 are: NW / NE / SE / SW
|
||||
setComboCurrentIndex(m_aircraft->multiMotorChannelBox1, multi.VTOLMotorNW);
|
||||
setComboCurrentIndex(m_aircraft->multiMotorChannelBox2, multi.VTOLMotorNE);
|
||||
setComboCurrentIndex(m_aircraft->multiMotorChannelBox3, multi.VTOLMotorSE);
|
||||
setComboCurrentIndex(m_aircraft->multiMotorChannelBox4, multi.VTOLMotorSW);
|
||||
} else if (frameType == "Hexa") {
|
||||
// Motors 1/2/3 4/5/6 are: N / NE / SE / S / SW / NW
|
||||
setComboCurrentIndex(m_aircraft->multiMotorChannelBox1, multi.VTOLMotorN);
|
||||
@ -564,9 +550,6 @@ QString ConfigMultiRotorWidget::updateConfigObjectsFromWidgets()
|
||||
} else if (m_aircraft->multirotorFrameType->currentText() == "Quad X") {
|
||||
airframeType = "QuadX";
|
||||
setupQuad(false);
|
||||
} else if (m_aircraft->multirotorFrameType->currentText() == "Quad H") {
|
||||
airframeType = "QuadH";
|
||||
setupQuad(false);
|
||||
} else if (m_aircraft->multirotorFrameType->currentText() == "Hexacopter") {
|
||||
airframeType = "Hexa";
|
||||
setupHexa(true);
|
||||
@ -840,8 +823,6 @@ void ConfigMultiRotorWidget::updateAirframe(QString frameType)
|
||||
elementId = "quad-x";
|
||||
} else if (frameType == "QuadP" || frameType == "Quad +") {
|
||||
elementId = "quad-plus";
|
||||
} else if (frameType == "QuadH" || frameType == "Quad H") {
|
||||
elementId = "quad-h";
|
||||
} else if (frameType == "Hexa" || frameType == "Hexacopter") {
|
||||
elementId = "quad-hexa";
|
||||
} else if (frameType == "HexaX" || frameType == "Hexacopter X") {
|
||||
|
@ -85,7 +85,6 @@ QStringList ConfigVehicleTypeWidget::getChannelDescriptions()
|
||||
case SystemSettings::AIRFRAMETYPE_TRI:
|
||||
case SystemSettings::AIRFRAMETYPE_QUADX:
|
||||
case SystemSettings::AIRFRAMETYPE_QUADP:
|
||||
case SystemSettings::AIRFRAMETYPE_QUADH:
|
||||
case SystemSettings::AIRFRAMETYPE_OCTOV:
|
||||
case SystemSettings::AIRFRAMETYPE_OCTOCOAXX:
|
||||
case SystemSettings::AIRFRAMETYPE_OCTOCOAXP:
|
||||
@ -316,8 +315,7 @@ int ConfigVehicleTypeWidget::frameCategory(QString frameType)
|
||||
|| frameType == "Elevon" || frameType == "FixedWingVtail" || frameType == "Vtail") {
|
||||
return ConfigVehicleTypeWidget::FIXED_WING;
|
||||
} else if (frameType == "Tri" || frameType == "Tricopter Y" || frameType == "QuadX" || frameType == "Quad X"
|
||||
|| frameType == "QuadP" || frameType == "Quad +" || frameType == "Quad H" || frameType == "QuadH"
|
||||
|| frameType == "Hexa" || frameType == "Hexacopter"
|
||||
|| frameType == "QuadP" || frameType == "Quad +" || frameType == "Hexa" || frameType == "Hexacopter"
|
||||
|| frameType == "HexaX" || frameType == "Hexacopter X" || frameType == "HexaCoax"
|
||||
|| frameType == "HexaH" || frameType == "Hexacopter H" || frameType == "Hexacopter Y6"
|
||||
|| frameType == "Octo" || frameType == "Octocopter"
|
||||
|
@ -1,7 +1,7 @@
|
||||
<xml>
|
||||
<object name="SystemSettings" singleinstance="true" settings="true" category="System">
|
||||
<description>Select airframe type. Currently used by @ref ActuatorModule to choose mixing from @ref ActuatorDesired to @ref ActuatorCommand</description>
|
||||
<field name="AirframeType" units="" type="enum" elements="1" options="FixedWing,FixedWingElevon,FixedWingVtail,VTOL,HeliCP,QuadX,QuadP,QuadH,Hexa,Octo,Custom,HexaX,HexaH,OctoV,OctoCoaxP,OctoCoaxX,OctoX,HexaCoax,Tri,GroundVehicleCar,GroundVehicleDifferential,GroundVehicleMotorcycle" defaultvalue="QuadX"/>
|
||||
<field name="AirframeType" units="" type="enum" elements="1" options="FixedWing,FixedWingElevon,FixedWingVtail,VTOL,HeliCP,QuadX,QuadP,Hexa,Octo,Custom,HexaX,HexaH,OctoV,OctoCoaxP,OctoCoaxX,OctoX,HexaCoax,Tri,GroundVehicleCar,GroundVehicleDifferential,GroundVehicleMotorcycle" defaultvalue="QuadX"/>
|
||||
<field name="VehicleName" units="char" type="uint8" elements="20" defaultvalue="0"/>
|
||||
<field name="ThrustControl" units="" type="enum" elements="1" options="Throttle,Collective,None" defaultvalue="Throttle" />
|
||||
<!-- Which way the vehicle controls its thrust. Can be through
|
||||
|
Loading…
x
Reference in New Issue
Block a user