Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Screen constantly refreshes when plugged into power #4

Open
cromulus opened this issue Sep 5, 2024 · 3 comments
Open

Screen constantly refreshes when plugged into power #4

cromulus opened this issue Sep 5, 2024 · 3 comments

Comments

@cromulus
Copy link

cromulus commented Sep 5, 2024

Inkplate_6

When plugged into usb power, the screen refreshes once every 5 or 6 seconds.

I can't quite figure out why.

Attached are the logs:
https://gist.github.com/cromulus/b39960e30b028223094091be276e995d

@paviro
Copy link
Owner

paviro commented Sep 9, 2024

It seems like the device correctly goes to deep sleep and then directly wakes up again. Wakeup happens if the bottom button is pressed for example maybe check that your hardware is okay? Also did you setup the required sensors in home assistant? See here.

@cromulus
Copy link
Author

Yes, the correct sensors are setup in home assistant.

I think the problem is that the battery is always reporting "nan", which breaks things. Can't figure out how t get the battery to behave. I might just pull out all of the deep sleep stuff and keep it plugged in.

@jeroenleenarts
Copy link

@cromulus Did you configure a wake-up button to wake the device from deep sleep on demand?

I created a project that uses a LilyGo T5 based on this code.

But I noticed I had the exact same behavior when I used code similar to this project.

It could very well be a stretch and not help at all, since my hardware is different.

But...

It's about this bit of code:

deep_sleep:
  id: deep_sleep_1
  wakeup_pin: 
    number: 36
    allow_other_uses: True
    inverted: true

Instead I now use:

deep_sleep:
  id: deep_sleep_1
  esp32_ext1_wakeup:
    pins: GPIO36
    mode: ALL_LOW
    # allow_other_uses: True - disabled this because I removed a binary sensor referencing the exact same pin.

It could also be that I fixed it by removing this bit:

binary_sensor:
  - platform: gpio
    pin:
      inverted: True
      number: 36
      allow_other_uses: True
    id: wake_up_button
    internal: True
    on_click:
      then:
        - script.execute: update_screen

Note, that ESPHome requires actual code using the pin again in case you use the allow_other_uses: True bit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants