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

Improve behaviour of Uploader gadget whenever the board does not manage to get into bootloader mode.

git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@3075 ebee16cc-31ac-478f-84a7-5cbb03baadba
This commit is contained in:
edouard 2011-03-26 11:22:31 +00:00 committed by edouard
parent 662a3e5cc8
commit 332cafa8b8

View File

@ -148,6 +148,8 @@ void UploaderGadgetWidget::goToBootloader(UAVObject* callerObj, bool success)
// otherwise we won't find it when we stop the board.
// The board is running, send the 1st IAP Reset order:
fwIAP->getField("Command")->setValue("1122");
fwIAP->getField("BoardRevision")->setDouble(0);
fwIAP->getField("BoardType")->setDouble(0);
connect(fwIAP,SIGNAL(transactionCompleted(UAVObject*,bool)),this,SLOT(goToBootloader(UAVObject*, bool)));
currentStep = IAP_STATE_STEP_1;
clearLog();
@ -226,6 +228,8 @@ void UploaderGadgetWidget::goToBootloader(UAVObject* callerObj, bool success)
delete dfu;
dfu = NULL;
cm->resumePolling();
currentStep = IAP_STATE_READY;
m_config->boardStatus->setText("Bootloader?");
return;
}
dfu->AbortOperation();
@ -235,6 +239,8 @@ void UploaderGadgetWidget::goToBootloader(UAVObject* callerObj, bool success)
delete dfu;
dfu = NULL;
cm->resumePolling();
currentStep = IAP_STATE_READY;
m_config->boardStatus->setText("Bootloader?");
return;
}
//dfu.StatusRequest();