Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qgroundcontrol
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
124af659
Commit
124af659
authored
Jul 17, 2017
by
Don Gagne
Committed by
GitHub
Jul 17, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #5457 from DonLakeFlyer/ArduCopter3.5
Update for ArduCopter 3.5 release
parents
e8bb813d
86f4b9a4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
55 additions
and
70 deletions
+55
-70
FirmwareUpgradeController.cc
src/VehicleSetup/FirmwareUpgradeController.cc
+55
-70
No files found.
src/VehicleSetup/FirmwareUpgradeController.cc
View file @
124af659
...
...
@@ -211,12 +211,7 @@ void FirmwareUpgradeController::_initFirmwareHash()
{
AutoPilotStackPX4
,
StableFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/stable/px4fmu-v4_default.px4"
},
{
AutoPilotStackPX4
,
BetaFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/beta/px4fmu-v4_default.px4"
},
{
AutoPilotStackPX4
,
DeveloperFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/master/px4fmu-v4_default.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
QuadFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-quad/ArduCopter-v4.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
X8Firmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-octa-quad/ArduCopter-v4.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
HexaFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-hexa/ArduCopter-v4.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
OctoFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-octa/ArduCopter-v4.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
YFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-tri/ArduCopter-v4.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
Y6Firmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-y6/ArduCopter-v4.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
CopterFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4/ArduCopter-v4.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
HeliFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-heli/ArduCopter-v4.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
PlaneFirmware
,
"http://firmware.ardupilot.org/Plane/stable/PX4/ArduPlane-v4.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
RoverFirmware
,
"http://firmware.ardupilot.org/Rover/stable/PX4/APMrover2-v4.px4"
},
...
...
@@ -232,18 +227,12 @@ void FirmwareUpgradeController::_initFirmwareHash()
};
//////////////////////////////////// PX4FMUV3 firmwares //////////////////////////////////////////////////
// Note: ArduPilot stable does not yet support V3 firmwares, so fall back to V2
FirmwareToUrlElement_t
rgPX4FMV3FirmwareArray
[]
=
{
{
AutoPilotStackPX4
,
StableFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/stable/px4fmu-v3_default.px4"
},
{
AutoPilotStackPX4
,
BetaFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/beta/px4fmu-v3_default.px4"
},
{
AutoPilotStackPX4
,
DeveloperFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/master/px4fmu-v3_default.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
QuadFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-quad/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
X8Firmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-octa-quad/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
HexaFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-hexa/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
OctoFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-octa/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
YFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-tri/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
Y6Firmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-y6/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
HeliFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-heli/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
CopterFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4/ArduCopter-v3.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
HeliFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-heli/ArduCopter-v3.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
PlaneFirmware
,
"http://firmware.ardupilot.org/Plane/stable/PX4/ArduPlane-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
RoverFirmware
,
"http://firmware.ardupilot.org/Rover/stable/PX4/APMrover2-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
SubFirmware
,
"http://firmware.ardupilot.org/Sub/stable/PX4/ArduSub-v2.px4"
},
...
...
@@ -265,12 +254,7 @@ void FirmwareUpgradeController::_initFirmwareHash()
{
AutoPilotStackPX4
,
StableFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/stable/px4fmu-v2_default.px4"
},
{
AutoPilotStackPX4
,
BetaFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/beta/px4fmu-v2_default.px4"
},
{
AutoPilotStackPX4
,
DeveloperFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/master/px4fmu-v2_default.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
QuadFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-quad/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
X8Firmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-octa-quad/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
HexaFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-hexa/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
OctoFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-octa/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
YFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-tri/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
Y6Firmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-y6/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
CopterFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
HeliFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-heli/ArduCopter-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
PlaneFirmware
,
"http://firmware.ardupilot.org/Plane/stable/PX4/ArduPlane-v2.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
RoverFirmware
,
"http://firmware.ardupilot.org/Rover/stable/PX4/APMrover2-v2.px4"
},
...
...
@@ -322,12 +306,7 @@ void FirmwareUpgradeController::_initFirmwareHash()
{
AutoPilotStackPX4
,
StableFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/stable/px4fmu-v1_default.px4"
},
{
AutoPilotStackPX4
,
BetaFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/beta/px4fmu-v1_default.px4"
},
{
AutoPilotStackPX4
,
DeveloperFirmware
,
DefaultVehicleFirmware
,
"http://px4-travis.s3.amazonaws.com/Firmware/master/px4fmu-v1_default.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
QuadFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-quad/ArduCopter-v1.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
X8Firmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-octa-quad/ArduCopter-v1.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
HexaFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-hexa/ArduCopter-v1.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
OctoFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-octa/ArduCopter-v1.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
YFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-tri/ArduCopter-v1.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
Y6Firmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-y6/ArduCopter-v1.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
CopterFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4/ArduCopter-v1.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
HeliFirmware
,
"http://firmware.ardupilot.org/Copter/stable/PX4-heli/ArduCopter-v1.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
PlaneFirmware
,
"http://firmware.ardupilot.org/Plane/stable/PX4/ArduPlane-v1.px4"
},
{
AutoPilotStackAPM
,
StableFirmware
,
RoverFirmware
,
"http://firmware.ardupilot.org/Rover/stable/PX4/APMrover2-v1.px4"
},
...
...
@@ -530,9 +509,9 @@ void FirmwareUpgradeController::_getFirmwareFile(FirmwareIdentifier firmwareId)
if
(
firmwareId
.
firmwareType
==
CustomFirmware
)
{
_firmwareFilename
=
QGCQFileDialog
::
getOpenFileName
(
NULL
,
// Parent to main window
"Select Firmware File"
,
// Dialog Caption
QStandardPaths
::
writableLocation
(
QStandardPaths
::
DocumentsLocation
),
// Initial directory
"Firmware Files (*.px4 *.bin *.ihx)"
);
// File filter
"Select Firmware File"
,
// Dialog Caption
QStandardPaths
::
writableLocation
(
QStandardPaths
::
DocumentsLocation
),
// Initial directory
"Firmware Files (*.px4 *.bin *.ihx)"
);
// File filter
}
else
{
if
(
prgFirmware
->
contains
(
firmwareId
))
{
_firmwareFilename
=
prgFirmware
->
value
(
firmwareId
);
...
...
@@ -774,51 +753,57 @@ void FirmwareUpgradeController::setSelectedFirmwareType(FirmwareType_t firmwareT
QStringList
FirmwareUpgradeController
::
apmAvailableVersions
(
void
)
{
QStringList
list
;
QStringList
list
;
QList
<
FirmwareVehicleType_t
>
vehicleTypes
;
// This allows up to force the order of the combo box display
vehicleTypes
<<
CopterFirmware
<<
HeliFirmware
<<
PlaneFirmware
<<
RoverFirmware
<<
SubFirmware
;
_apmVehicleTypeFromCurrentVersionList
.
clear
();
foreach
(
FirmwareVehicleType_t
vehicleType
,
_apmVersionMap
[
_selectedFirmwareType
].
keys
())
{
QString
version
;
switch
(
vehicleType
)
{
case
QuadFirmware
:
version
=
"Quad - "
;
break
;
case
X8Firmware
:
version
=
"X8 - "
;
break
;
case
HexaFirmware
:
version
=
"Hexa - "
;
break
;
case
OctoFirmware
:
version
=
"Octo - "
;
break
;
case
YFirmware
:
version
=
"Y - "
;
break
;
case
Y6Firmware
:
version
=
"Y6 - "
;
break
;
case
HeliFirmware
:
version
=
"Heli - "
;
break
;
case
CopterFirmware
:
version
=
"MultiRotor - "
;
break
;
case
SubFirmware
:
version
=
"Sub - "
;
break
;
case
PlaneFirmware
:
case
RoverFirmware
:
case
DefaultVehicleFirmware
:
break
;
foreach
(
FirmwareVehicleType_t
vehicleType
,
vehicleTypes
)
{
if
(
_apmVersionMap
[
_selectedFirmwareType
].
contains
(
vehicleType
))
{
QString
version
;
switch
(
vehicleType
)
{
case
QuadFirmware
:
version
=
"Quad - "
;
break
;
case
X8Firmware
:
version
=
"X8 - "
;
break
;
case
HexaFirmware
:
version
=
"Hexa - "
;
break
;
case
OctoFirmware
:
version
=
"Octo - "
;
break
;
case
YFirmware
:
version
=
"Y - "
;
break
;
case
Y6Firmware
:
version
=
"Y6 - "
;
break
;
case
HeliFirmware
:
version
=
"Heli - "
;
break
;
case
CopterFirmware
:
version
=
"MultiRotor - "
;
break
;
case
SubFirmware
:
version
=
"Sub - "
;
break
;
case
PlaneFirmware
:
case
RoverFirmware
:
case
DefaultVehicleFirmware
:
break
;
}
version
+=
_apmVersionMap
[
_selectedFirmwareType
][
vehicleType
];
_apmVehicleTypeFromCurrentVersionList
.
append
(
vehicleType
);
list
<<
version
;
}
version
+=
_apmVersionMap
[
_selectedFirmwareType
][
vehicleType
];
_apmVehicleTypeFromCurrentVersionList
.
append
(
vehicleType
);
list
<<
version
;
}
return
list
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment