Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rework of advanced view #1028

Merged
merged 1 commit into from
Aug 19, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 25 additions & 19 deletions source/Core/Threads/GUIThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -551,28 +551,27 @@ static void gui_solderingMode(uint8_t jumpToSleep) {
OLED::clearScreen();
// Draw in the screen details
if (systemSettings.detailedSoldering) {
OLED::print(translatedString(Tr->SolderingAdvancedPowerPrompt),
FontStyle::SMALL); // Power:
OLED::printNumber(x10WattHistory.average() / 10, 2, FontStyle::SMALL);
OLED::print(SymbolDot, FontStyle::SMALL);
OLED::printNumber(x10WattHistory.average() % 10, 1, FontStyle::SMALL);
OLED::print(SymbolWatts, FontStyle::SMALL);
gui_drawTipTemp(true, FontStyle::LARGE);

#ifndef NO_SLEEP_MODE
if (systemSettings.sensitivity && systemSettings.SleepTime) {
OLED::print(SymbolSpace, FontStyle::SMALL);
OLED::setCursor(47, 0);
display_countdown(getSleepTimeout());
}
#endif
OLED::setCursor(0, 8);
OLED::print(translatedString(Tr->SleepingTipAdvancedString), FontStyle::SMALL);
gui_drawTipTemp(true, FontStyle::SMALL);

if (boostModeOn) {
OLED::setCursor(54, 8);
OLED::print(SymbolPlus, FontStyle::SMALL);
} else {
OLED::print(SymbolSpace, FontStyle::SMALL);
}

OLED::setCursor(67, 0);
OLED::printNumber(x10WattHistory.average() / 10, 2, FontStyle::SMALL);
OLED::print(SymbolDot, FontStyle::SMALL);
OLED::printNumber(x10WattHistory.average() % 10, 1, FontStyle::SMALL);
OLED::print(SymbolWatts, FontStyle::SMALL);

OLED::setCursor(67, 8);
printVoltage();
OLED::print(SymbolVolts, FontStyle::SMALL);
} else {
Expand Down Expand Up @@ -904,15 +903,22 @@ void startGUITask(void const *argument __unused) {
if (isTipDisconnected()) {
OLED::print(translatedString(Tr->TipDisconnectedString), FontStyle::SMALL);
} else {
OLED::print(translatedString(Tr->IdleTipString), FontStyle::SMALL);
gui_drawTipTemp(false, FontStyle::SMALL);
OLED::print(translatedString(Tr->IdleSetString), FontStyle::SMALL);
OLED::printNumber(systemSettings.SolderingTemp, 3, FontStyle::SMALL);
if (!(systemSettings.coolingTempBlink && (tipTemp > 55) && (xTaskGetTickCount() % 1000 < 300)))
// Blink temp if setting enable and temp < 55°
// 1000 tick/sec
// OFF 300ms ON 700ms
gui_drawTipTemp(true, FontStyle::LARGE); // draw in the temp
OLED::setCursor(73, 0); // top right
OLED::printNumber(systemSettings.SolderingTemp, 3, FontStyle::SMALL); // draw set temp
if (systemSettings.temperatureInF)
OLED::print(SymbolDegF, FontStyle::SMALL);
else
OLED::print(SymbolDegC, FontStyle::SMALL);
}
OLED::setCursor(0, 8);

OLED::print(translatedString(Tr->InputVoltageString), FontStyle::SMALL);
printVoltage();
OLED::setCursor(67, 8); // bottom right
printVoltage(); // draw voltage then symbol (v)
OLED::print(SymbolVolts, FontStyle::SMALL);

} else {
#ifdef OLED_FLIP
Expand Down