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

Add support for 7 segment displays #61

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

guillempages
Copy link

@guillempages guillempages commented Nov 11, 2023

Add support for 7 segment displays to the hk16t33 component, in addition to the 14 segment alphanumeric displays.

In order to use the 7 segment, an extra type needs to be used on the yaml file.

display:
  - platform: ht16k33_alpha
    id: clock_display
    type: 7Segment
    lambda: |-
      auto time = id(time_sensor).now();
      it.strftime("%H%M", time);
      // use "%H:%M" instead if you want to have the colon lit.

Allow showing or hiding the colon separator via a lambda call.
Also update the README
@guillempages guillempages force-pushed the 7_segment branch 4 times, most recently from 89eb4ec to 06c3aa0 Compare November 13, 2023 20:53
In ESPHome 2023.12.0 the "register_display" call automatically implies
"register_component". Calling it twice causes a compilation error.
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.

1 participant