Fix sd_status comparison
Co-Authored-By: perkmeister <perkmeister@users.noreply.github.com>
This commit is contained in:
parent
80c51ea572
commit
96c1721eeb
@ -5129,10 +5129,10 @@ void lcd_update() {
|
|||||||
|
|
||||||
#if ENABLED(SDSUPPORT) && PIN_EXISTS(SD_DETECT)
|
#if ENABLED(SDSUPPORT) && PIN_EXISTS(SD_DETECT)
|
||||||
|
|
||||||
const bool sd_status = IS_SD_INSERTED;
|
const uint8_t sd_status = (uint8_t)IS_SD_INSERTED;
|
||||||
if (sd_status != lcd_sd_status && lcd_detected()) {
|
if (sd_status != lcd_sd_status && lcd_detected()) {
|
||||||
|
|
||||||
bool old_sd_status = lcd_sd_status; // prevent re-entry to this block!
|
uint8_t old_sd_status = lcd_sd_status; // prevent re-entry to this block!
|
||||||
lcd_sd_status = sd_status;
|
lcd_sd_status = sd_status;
|
||||||
|
|
||||||
if (sd_status) {
|
if (sd_status) {
|
||||||
|
Loading…
Reference in New Issue
Block a user