diff --git a/src/main.cpp b/src/main.cpp index cf45ef2..4eea5be 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -44,6 +44,8 @@ static const char* TAG = "MAIN"; WiFiMulti wifiMulti; GxEPD2_BW display(GxEPD2_213_B72(/*CS=SS*/ TFT_CS, /*DC=*/ TFT_DC, /*RST=*/ TFT_RST, /*BUSY=*/ -1)); // GDEH0213B72 +static constexpr uint8_t y_offset = 8; + Adafruit_BME280 bme280; // I2C (also available: hardware SPI Adafruit_BME680 bme680; // I2C (also available: hardware SPI //HardwareSerial Serial2(2); @@ -223,7 +225,6 @@ void receiveMqtt(const char* topic, const char* data) { void displayValues() { - static constexpr uint8_t y_offset = 8; display.setRotation(1); display.setFont(NULL); display.setTextColor(GxEPD_BLACK); @@ -610,7 +611,7 @@ void setup() Serial.println("WiFi connected"); Serial.println("IP address: "); Serial.println(WiFi.localIP()); - displayIcoPartial(ico_wifi16, display.width()-20, 0, ico_wifi16_width, ico_wifi16_height); + displayIcoPartial(ico_wifi16, display.width()-20, y_offset+0, ico_wifi16_width, ico_wifi16_height); } ESP_LOGD(TAG, "trying to fetch over-the-air update");