1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2025-01-17 02:52:12 +01:00

OP-974 add bootloader revision info in Uploader gadget's Device Information.

This commit is contained in:
Alessio Morale 2014-02-15 12:42:22 +01:00
parent 15200eafd8
commit 7640f72e1f
4 changed files with 25 additions and 1 deletions

View File

@ -263,6 +263,15 @@ int UAVObjectUtilManager::getBoardModel()
return ret;
}
int UAVObjectUtilManager::getBootloaderRevision()
{
FirmwareIAPObj::DataFields firmwareIapData = getFirmwareIap();
int ret = firmwareIapData.BootloaderRevision;
return ret;
}
/**
* Get the UAV Board CPU Serial Number, for anyone interested. Return format is a byte array
*/

View File

@ -58,6 +58,7 @@ public:
int getGPSPositionSensor(double LLA[3]);
int getBoardModel();
int getBootloaderRevision();
QByteArray getBoardCPUSerial();
quint32 getFirmwareCRC();
QByteArray getBoardDescription();

View File

@ -99,8 +99,9 @@ void RunningDeviceWidget::populate()
QString serial = utilMngr->getBoardCPUSerial().toHex();
myDevice->CPUSerial->setText(serial);
myDevice->lblBLRev->setText(tr("BL version: ") + QString::number(utilMngr->getBootloaderRevision()));
QByteArray description = utilMngr->getBoardDescription();
deviceDescriptorStruct devDesc;
if (UAVObjectUtilManager::descriptionToStructure(description, devDesc)) {
if (devDesc.gitTag.startsWith("RELEASE", Qt::CaseSensitive)) {

View File

@ -95,6 +95,19 @@
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="lblBLRev">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>BlRevision</string>
</property>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>