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

Fix for issue 15, use the new display.time_to_refresh #16

Merged
merged 1 commit into from
Sep 25, 2023

Conversation

pedasmith
Copy link

This is a fairly minimal set of changes to switch the timeout value from the old value (hardcoded to be 120, or 2 minutes) to the newer "display.time_to_refresh" which is set to be 180 (3 minutes).

I don't just wait the exact amount of time. My experience with other operating systems is that "sleep" times are often modified: the OS might choose to wake either earlier or later. Later isn't a problem, but earlier is a very bad: presumably the developer is about to call refresh() and that will throw if the time is a little early. Since we have to wait for 180 seconds anyway, five extra seconds shouldn't be a deal breaker.

I also updated the code to have an infinite loop at the end -- otherwise the code will fully exit and the display might be reset (I've seen the display reset several times while doing my testing).

Copy link
Member

@tannewt tannewt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@tannewt tannewt merged commit d515fa7 into adafruit:main Sep 25, 2023
adafruit-adabot added a commit to adafruit/Adafruit_CircuitPython_Bundle that referenced this pull request Sep 30, 2023
Updating https://github.com/adafruit/Adafruit_CircuitPython_SSD1680 to 1.1.4 from 1.1.3:
  > Merge pull request adafruit/Adafruit_CircuitPython_SSD1680#18 from makermelissa/main
  > Merge pull request adafruit/Adafruit_CircuitPython_SSD1680#16 from pedasmith/Issue15Timeout

Updating https://github.com/adafruit/Adafruit_CircuitPython_Bundle/circuitpython_library_list.md to NA from NA:
  > Updated download stats for the libraries
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

Successfully merging this pull request may close these issues.

3 participants