Xinyuan-LilyGO / TTGO_TWatch_Library

MIT License
881 stars 283 forks source link

Please add example for wake up from light sleep from the touch screen on v1. #144

Open YordanYanakiev opened 2 years ago

YordanYanakiev commented 2 years ago

In "TTGO_TWatch_Library/examples/BasicUnit/WakeupFormTouchScreen/WakeupFormTouchScreen.ino" seems like it is more about v3, and not sufficiently clearly speaks about v1 problem. In order to avoid misunderstandings, and misusing :

Thank You in advance.

YordanYanakiev commented 2 years ago

Someone ?

mike-ady commented 2 years ago

Try replacing the call to displaySleep in loop() with the following code:

#if defined(LILYGO_WATCH_2020_V2)||defined(LILYGO_WATCH_2020_V3)
    ttgo->displaySleep();       // Set touchscreen sleep
#else
    ttgo->displayOff();     // Set display off, touch controller to monitor
#endif

That seems to work for me. I also found it helpful to uncomment the following line while experimenting:

` esp_sleep_enable_ext1_wakeup(GPIO_SEL_35,ESP_EXT1_WAKEUP_ALL_LOW);

`