1
0
Fork 0
mirror of https://github.com/EdgeTX/edgetx.git synced 2025-07-26 09:45:16 +03:00

#1876 fixed. Still needs tests on Taranis (I only tested on Taranis+)

This commit is contained in:
bsongis 2015-01-09 12:50:03 +01:00
parent fac4ff10c3
commit 62ea9c2648
8 changed files with 69 additions and 9 deletions

View file

@ -123,6 +123,29 @@ QString FirmwareInterface::seekLabel(const QString & label)
return seekString(label + ":");
}
QString FirmwareInterface::getFlavour() const
{
if (flavour == "opentx-x9dp")
return "opentx-taranis-plus";
else if (flavour == "opentx-x9d")
return "opentx-taranis";
else
return flavour;
}
bool FirmwareInterface::isHardwareCompatible(const FirmwareInterface &previousFirmware) const
{
QString newFlavour = getFlavour();
if (newFlavour.isEmpty())
return true;
QString previousFlavour = previousFirmware.getFlavour();
if (previousFlavour.isEmpty())
return true;
return (newFlavour == previousFlavour);
}
bool FirmwareInterface::SeekSplash(QByteArray splash)
{
int start = flash.indexOf(splash);