Skip to content

Commit

Permalink
When lights are off, shows as zero #231
Browse files Browse the repository at this point in the history
(cherry picked from commit 7701dbd)
  • Loading branch information
Sebazzz committed Apr 25, 2021
1 parent 9b6bdae commit 9986ce0
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Marlin/src/lcd/extui/lib/dgus_creality/DGUSScreenHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1023,6 +1023,11 @@ void DGUSScreenHandler::SendLEDToDisplay(DGUS_VP_Variable &var) {

// The display wants a 16-bit integer
uint16_t val = *(uint8_t*)var.memadr;

if (!leds.lights_on) {
val = 0;
}

rcpy.memadr = &val;

DGUSLCD_SendWordValueToDisplay(rcpy);
Expand Down

0 comments on commit 9986ce0

Please sign in to comment.