diff --git a/companion/src/main.cpp b/companion/src/main.cpp index cabf5e6f0..d97592c08 100644 --- a/companion/src/main.cpp +++ b/companion/src/main.cpp @@ -116,14 +116,15 @@ int main(int argc, char *argv[]) current_firmware_variant = GetFirmwareVariant(firmware_id); // qDebug() << current_firmware_variant; + MainWindow mainWin; + if (showSplash) { splash->show(); - splash->showMessage(QObject::tr("")); - sleep(SPLASH_TIME); + QTimer::singleShot(1000*SPLASH_TIME, splash, SLOT(close())); + QTimer::singleShot(1000*SPLASH_TIME, &mainWin, SLOT(show())); + } + else { + mainWin.show(); } - - MainWindow mainWin; - mainWin.show(); - splash->finish(&mainWin); return app.exec(); } diff --git a/companion/src/mainwindow.cpp b/companion/src/mainwindow.cpp index 4f7b85a78..b05a10a54 100644 --- a/companion/src/mainwindow.cpp +++ b/companion/src/mainwindow.cpp @@ -112,9 +112,15 @@ downloadDialog_forWait(NULL) QNetworkProxyFactory::setUseSystemConfiguration(true); setAcceptDrops(true); - // give time to the main windows to open before starting updates, delay 1s - QTimer::singleShot(1000, this, SLOT(doAutoUpdates())); - QTimer::singleShot(1000, this, SLOT(displayWarnings())); + // give time to the splash to disappear and main window to open before starting updates + int updateDelay = 1000; + QSettings settings("companion9x", "companion9x"); + bool showSplash = settings.value("show_splash", true).toBool(); + if (showSplash) + updateDelay += (SPLASH_TIME*1000); + QTimer::singleShot(updateDelay, this, SLOT(doAutoUpdates())); + QTimer::singleShot(updateDelay, this, SLOT(displayWarnings())); + QStringList strl = QApplication::arguments(); QString str; QString printfilename; diff --git a/companion/src/translations/companion9x_sv.ts b/companion/src/translations/companion9x_sv.ts index 463c6e52e..dad124c89 100644 --- a/companion/src/translations/companion9x_sv.ts +++ b/companion/src/translations/companion9x_sv.ts @@ -322,7 +322,7 @@ Gasen reverseras om alternativet väljs. Tomgång ligger då uppåt. Trim och ga Show Splash Screen on Startup - Visa bild vid start av sändare + Visa Startbild @@ -9454,7 +9454,7 @@ Tryck på Avbryt för att avburyta kalibreringen Show Splash Screen - Visa bild vid start av sändare + Visa Startbild diff --git a/radio/src/opentx.cpp b/radio/src/opentx.cpp index af664925e..c5dd5adce 100644 --- a/radio/src/opentx.cpp +++ b/radio/src/opentx.cpp @@ -1419,11 +1419,6 @@ bool getSwitch(int8_t swtch) if (cs->v1 >= MIXSRC_FIRST_TELEM) { if ((!TELEMETRY_STREAMING() && cs->v1 >= MIXSRC_FIRST_TELEM+TELEM_FIRST_STREAMED_VALUE-1) || IS_FAI_FORBIDDEN(cs->v1-1)) return swtch > 0 ? false : true; - -#if defined (PCBTARANIS) - if (cs->v1 == MIXSRC_FIRST_TELEM+TELEM_A2-1 && g_model.moduleData[INTERNAL_MODULE].rfProtocol == RF_PROTO_X16) - return swtch > 0 ? false : true; -#endif y = convertCswTelemValue(cs); diff --git a/radio/src/telemetry/frsky_sport.cpp b/radio/src/telemetry/frsky_sport.cpp index a9552e150..8499cb5f8 100644 --- a/radio/src/telemetry/frsky_sport.cpp +++ b/radio/src/telemetry/frsky_sport.cpp @@ -671,11 +671,11 @@ void telemetryWakeup() } } else if (alarmsCheckStep == 2) { - if (alarmRaised(1, 1) && g_model.moduleData[INTERNAL_MODULE].rfProtocol == RF_PROTO_D8) { + if (alarmRaised(1, 1)) { AUDIO_A2_RED(); alarmsCheckTime = get_tmr10ms() + 300; /* next check in 3seconds */ } - else if (alarmRaised(1, 0) && g_model.moduleData[INTERNAL_MODULE].rfProtocol == RF_PROTO_D8) { + else if (alarmRaised(1, 0)) { AUDIO_A2_ORANGE(); alarmsCheckTime = get_tmr10ms() + 300; /* next check in 3seconds */ } @@ -734,6 +734,7 @@ void FrskyValueWithMinMax::set(uint8_t value) void resetTelemetry() { memclear(&frskyData, sizeof(frskyData)); + telemetryState = TELEMETRY_INIT; #if defined(FRSKY_HUB) frskyData.hub.gpsLatitude_bp = 2;