Xinyuan-LilyGO / T-Wristband

DIY Programmable Bracelet
311 stars 98 forks source link

display in sleep mode #17

Closed biccius closed 3 years ago

biccius commented 3 years ago

I would like to try to restore the screen display after a deep sleep as quickly as possible without do a full re-initialization of the display.

Following commands works if called sequentially in setup() for example


        digitalWrite(TFT_BL, LOW);
        tft.writecommand(ST7735_SLPIN);

            digitalWrite(TFT_BL, HIGH);     
        tft.writecommand(ST7735_SLPOUT);

But after a deep sleep of ESP32 the "SLEEP OUT" commands of display seems never work. I think becase the display is reset from ESP32's reset pin (IO26?) asserted LOW when the mcu is in deep sleep. So a re-initialization via SPI seems to be necessary.

Is there any way to keep the buffer display preserved after a ESP32 deep sleep without change the hardware?

Thanks