Add some more debug output to updateBinary().

This commit is contained in:
Gerhard Hoffmann 2023-09-09 14:57:04 +02:00
parent 67c8b2f472
commit cd59a39569

View File

@ -469,20 +469,19 @@ bool Update::downloadBinaryToDC(QString const &bFile) const {
// bootloader is really not running anymore.
*/
bool Update::updateBinary(char const *fileToSendToDC) {
qInfo() << "UPDATING DEVICE CONTROLLER BINARY" << fileToSendToDC;
qInfo() << "UPDATING DEVICE CONTROLLER FIRMWARE BINARY" << fileToSendToDC;
QFile fn(fileToSendToDC);
bool r;
if ((r = fn.exists()) == true) {
QFileInfo fi(fn);
qInfo() << " UPDATING BINARY" << fi.fileName() << "(size=" << fi.size() << ")";
if ((r = updateDC(fileToSendToDC)) == true) {
qCritical() << QString(80, '*');
qInfo() << " UPDATING BINARY" << fi.fileName() << "(size=" << fi.size() << ") DONE";
qCritical() << QString(80, '*');
Utils::printInfoMsg(
QString(" UPDATING BINARY ") + fi.fileName()
+ QString(" (size=%1").arg(fi.size()) + ") DONE");
} else {
qCritical() << QString(80, '*');
qCritical() << " UPDATING BINARY" << fi.fileName() << "(size=" << fi.size() << ") FAILED";
qCritical() << QString(80, '*');
Utils::printCriticalErrorMsg(
QString(" UPDATING BINARY ") + fi.fileName()
+ QString(" (size=%1").arg(fi.size()) + ") FAILED");
}
} else {
qCritical() << QString(80, '*');