Commit 7f593de2 authored by huangjian's avatar huangjian

Add X7 support

parent 5af762c1
/****************************************************************************
/****************************************************************************
*
* (c) 2009-2020 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
*
......@@ -55,6 +55,7 @@ public:
static const int boardIDmRoCtrlZeroF7 = 141; ///< mRo Control Zero F7 board, as from USB PID
static const int boardIDModalFCV1 = 41775; ///< ModalAI FC V1 board, as from USB PID
static const int boardIDUVifyCore = 20; ///< UVify Core board, as from USB PID
static const int boardIDCUAVX7 = 1010; ///< CUAV X7(Pro) board, as from USB PID
/// Simulated board id for V3 which is a V2 board which supports larger flash space
/// IMPORTANT: Make sure this id does not conflict with any newly added real board ids
......
/****************************************************************************
/****************************************************************************
*
* (c) 2009-2020 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
*
......@@ -390,6 +390,12 @@ void FirmwareUpgradeController::_initFirmwareHash()
_rgPX4FMUV2Firmware.insert (FirmwareIdentifier(AutoPilotStackPX4, firmwareType, DefaultVehicleFirmware), px4Url.arg(dir).arg("v2"));
}
QString px4CUAVX7Url ("http://px4-travis.s3.amazonaws.com/Firmware/%1/cuav_%2_default.px4");
for (const FirmwareBuildType_t& firmwareType: px4MapFirmwareTypeToDir.keys()) {
QString dir = px4MapFirmwareTypeToDir[firmwareType];
_rgPX4CUAVX7Fireware.insert (FirmwareIdentifier(AutoPilotStackPX4, firmwareType, DefaultVehicleFirmware), px4CUAVX7Url.arg(dir).arg("x7pro"));
}
int size = sizeof(rgAeroCoreFirmwareArray)/sizeof(rgAeroCoreFirmwareArray[0]);
for (int i = 0; i < size; i++) {
const FirmwareToUrlElement_t& element = rgAeroCoreFirmwareArray[i];
......@@ -560,6 +566,9 @@ QHash<FirmwareUpgradeController::FirmwareIdentifier, QString>* FirmwareUpgradeCo
case Bootloader::boardID3DRRadio:
_rgFirmwareDynamic = _rg3DRRadioFirmware;
break;
case Bootloader::boardIDCUAVX7:
_rgFirmwareDynamic = _rgPX4CUAVX7Fireware;
break;
default:
// Unknown board id
break;
......
/****************************************************************************
/****************************************************************************
*
* (c) 2009-2020 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
*
......@@ -224,6 +224,7 @@ private:
QHash<FirmwareIdentifier, QString> _rgUVifyCoreFirmware;
QHash<FirmwareIdentifier, QString> _rgPX4FLowFirmware;
QHash<FirmwareIdentifier, QString> _rg3DRRadioFirmware;
QHash<FirmwareIdentifier, QString> _rgPX4CUAVX7Fireware;
// Hash map for ArduPilot ChibiOS lookup by board name
QHash<FirmwareIdentifier, QString> _rgAPMChibiosReplaceNamedBoardFirmware;
......
{
{
"comment": "AutoConnect usb board info",
"version": 1,
"fileType": "USBBoardInfo",
......@@ -21,7 +21,8 @@
{ "vendorID": 1155, "productID": 41775, "boardClass": "Pixhawk", "name": "PX4 FMU ModalAI FCv1" },
{ "vendorID":12642, "productID": 75, "boardClass": "Pixhawk", "name": "PX4 DurandalV1" },
{ "vendorID": 4104, "productID": 1, "boardClass": "Pixhawk", "name": "PX4 FMU UVify Core" },
{ "vendorID": 12643, "productID": 76, "boardClass": "Pixhawk", "name": "PX4 CUAV X7(PRO)" },
{ "vendorID": 1155, "productID": 22336, "boardClass": "Pixhawk", "name": "ArduPilot ChibiOS" },
{ "vendorID": 4617, "productID": 22336, "boardClass": "Pixhawk", "name": "ArduPilot ChibiOS" },
{ "vendorID": 4617, "productID": 22337, "boardClass": "Pixhawk", "name": "ArduPilot ChibiOS" },
......
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