From 7d9fed1b7a9ab95f373807caf0307bac105c5c9a Mon Sep 17 00:00:00 2001 From: Tim Pehla Date: Mon, 11 Nov 2024 18:50:31 +0100 Subject: [PATCH] Corrected formatting --- .../waveshare_epaper/waveshare_epaper.cpp | 26 +++++++++---------- .../waveshare_epaper/waveshare_epaper.h | 12 ++++----- 2 files changed, 19 insertions(+), 19 deletions(-) diff --git a/esphome/components/waveshare_epaper/waveshare_epaper.cpp b/esphome/components/waveshare_epaper/waveshare_epaper.cpp index 38e8b213f5..dc3209aeef 100644 --- a/esphome/components/waveshare_epaper/waveshare_epaper.cpp +++ b/esphome/components/waveshare_epaper/waveshare_epaper.cpp @@ -2649,7 +2649,7 @@ bool WaveshareEPaper7P5InV2P::wait_until_idle_() { return false; } App.feed_wdt(); - delay(10); // NOLINT + delay(10); // NOLINT } return true; } @@ -2657,17 +2657,17 @@ bool WaveshareEPaper7P5InV2P::wait_until_idle_() { void WaveshareEPaper7P5InV2P::reset_() { if (this->reset_pin_ != nullptr) { this->reset_pin_->digital_write(true); - delay(20); // NOLINT + delay(20); // NOLINT this->reset_pin_->digital_write(false); - delay(2); // NOLINT + delay(2); // NOLINT this->reset_pin_->digital_write(true); - delay(20); // NOLINT + delay(20); // NOLINT } } void WaveshareEPaper7P5InV2P::turn_on_display_() { this->command(0x12); - delay(100); // NOLINT + delay(100); // NOLINT this->wait_until_idle_(); } @@ -2690,7 +2690,7 @@ void WaveshareEPaper7P5InV2P::initialize() { // COMMAND POWER DRIVER HAT UP this->command(0x04); - delay(100); // NOLINT + delay(100); // NOLINT this->wait_until_idle_(); // COMMAND PANEL SETTING @@ -2734,7 +2734,7 @@ void HOT WaveshareEPaper7P5InV2P::display() { ESP_LOGI(TAG, "Power on the display and hat"); this->command(0x04); - delay(200); // NOLINT + delay(200); // NOLINT this->wait_until_idle_(); if (this->full_update_every_ == 1) { @@ -2762,21 +2762,21 @@ void HOT WaveshareEPaper7P5InV2P::display() { this->command(0x92); this->command(0x10); - delay(2); // NOLINT + delay(2); // NOLINT for (uint32_t i = 0; i < buf_len; i++) { this->data(~(this->buffer_[i])); } - delay(100); // NOLINT + delay(100); // NOLINT this->wait_until_idle_(); this->command(0x13); - delay(2); // NOLINT + delay(2); // NOLINT for (uint32_t i = 0; i < buf_len; i++) { this->data(this->buffer_[i]); } - delay(100); // NOLINT + delay(100); // NOLINT this->wait_until_idle_(); this->turn_on_display_(); @@ -2803,12 +2803,12 @@ void HOT WaveshareEPaper7P5InV2P::display() { this->data(0x01); this->command(0x13); - delay(2); // NOLINT + delay(2); // NOLINT for (uint32_t i = 0; i < buf_len; i++) { this->data(this->buffer_[i]); } - delay(100); // NOLINT + delay(100); // NOLINT this->wait_until_idle_(); this->turn_on_display_(); diff --git a/esphome/components/waveshare_epaper/waveshare_epaper.h b/esphome/components/waveshare_epaper/waveshare_epaper.h index 6d9bf1229c..7a66e7694e 100644 --- a/esphome/components/waveshare_epaper/waveshare_epaper.h +++ b/esphome/components/waveshare_epaper/waveshare_epaper.h @@ -699,12 +699,12 @@ class WaveshareEPaper7P5InV2P : public WaveshareEPaper { void dump_config() override; void deep_sleep() override { - // COMMAND POWER OFF - this->command(0x02); - this->wait_until_idle_(); - // COMMAND DEEP SLEEP - this->command(0x07); - this->data(0xA5); // check byte + // COMMAND POWER OFF + this->command(0x02); + this->wait_until_idle_(); + // COMMAND DEEP SLEEP + this->command(0x07); + this->data(0xA5); // check byte } void set_full_update_every(uint32_t full_update_every);