diff --git a/CO2_Gadget.ino b/CO2_Gadget.ino index 1acfe283..eab8c497 100644 --- a/CO2_Gadget.ino +++ b/CO2_Gadget.ino @@ -295,6 +295,7 @@ void wakeUpDisplay() { #if defined(SUPPORT_OLED) || defined(SUPPORT_TFT) setDisplayBrightness(DisplayBrightness); publishMQTTLogData("Display woken up. Setting display brightness to " + String(DisplayBrightness)); + Serial.println("-->[MAIN] Display woken up. Setting display brightness to " + String(DisplayBrightness)); #endif lastTimeButtonPressed = millis(); } @@ -459,6 +460,7 @@ void adjustBrightnessLoop() { if (actualDisplayBrightness == 0) { setDisplayBrightness(DisplayBrightness); // Exception: When USB connected (just connected) & TFT is OFF -> Turn Display ON publishMQTTLogData("Turning on display on external power. Actual brightness: " + String(actualDisplayBrightness)); + Serial.println("-->[MAIN] Turning on display on external power. Actual brightness: " + String(actualDisplayBrightness)); } return; } diff --git a/CO2_Gadget_TFT.h b/CO2_Gadget_TFT.h index 9d093110..2cb3f463 100644 --- a/CO2_Gadget_TFT.h +++ b/CO2_Gadget_TFT.h @@ -191,9 +191,9 @@ void setElementLocations() { void setDisplayBrightness(uint16_t newBrightness) { #ifdef TTGO_TDISPLAY if (actualDisplayBrightness != newBrightness) { - // Serial.printf("\n-->[TFT ] DisplayBrightness value at %d\n", DisplayBrightness); - // Serial.printf("-->[TFT ] actualDisplayBrightness value at %d\n", actualDisplayBrightness); - // Serial.printf("-->[TFT ] New display brightness value at %d\n", newBrightness); + Serial.printf("\n-->[TFT ] DisplayBrightness value at %d\n", DisplayBrightness); + Serial.printf("-->[TFT ] actualDisplayBrightness value at %d\n", actualDisplayBrightness); + Serial.printf("-->[TFT ] New display brightness value at %d\n", newBrightness); analogWrite(TFT_BACKLIGHT, newBrightness); actualDisplayBrightness = newBrightness; } diff --git a/platformio.ini b/platformio.ini index 75106e03..a6894c50 100644 --- a/platformio.ini +++ b/platformio.ini @@ -42,7 +42,7 @@ build_flags = -D MQTT_BROKER_SERVER="\"192.168.1.145"\" -D CO2_GADGET_VERSION="\"0.12."\" - -D CO2_GADGET_REV="\"012"\" + -D CO2_GADGET_REV="\"015"\" -D CORE_DEBUG_LEVEL=0 -DCACHE_DIR=".pio/build" -DBUZZER_PIN=2 ; ESP32 pin GPIO13 connected to piezo buzzer