Skip to content

Commit

Permalink
Merge pull request #112 from Martinius79/BugfixFailingDigitsOnNightTi…
Browse files Browse the repository at this point in the history
…meSwitch

Fix for not correctly refreshing digits after switching to or from night time dimming mode
  • Loading branch information
Martinius79 authored Jan 18, 2025
2 parents c0d3e2e + 79ae57a commit a87c159
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions EleksTubeHAX_pio/src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -887,12 +887,14 @@ void checkDimmingNeeded()
{ // check if it is in the defined night time
Serial.println("Set to night time mode (dimmed)!");
tfts.dimming = TFT_DIMMED_INTENSITY;
tfts.InvalidateImageInBuffer();
backlights.setDimming(true);
}
else
{
Serial.println("Set to day time mode (normal brightness)!");
tfts.dimming = 255; // 0..255
tfts.InvalidateImageInBuffer();
backlights.setDimming(false);
}
updateClockDisplay(TFTs::force); // redraw all the clock digits -> software dimming will be done here
Expand Down

0 comments on commit a87c159

Please sign in to comment.