PoisonWaffle

Garage Display ESPHome

Nov 27th, 2023 (edited)
301
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.79 KB | None | 0 0
  1. esphome:
  2. name: garage-door-indicator
  3.  
  4. esp32:
  5. board: esp32dev
  6. framework:
  7. type: arduino
  8.  
  9. sensor:
  10. - platform: homeassistant
  11. id: garage_temp
  12. entity_id: sensor.garage_temp
  13. - platform: homeassistant
  14. id: outside_temp
  15. entity_id: sensor.outside_temp_hum_temperature
  16.  
  17. font:
  18. - file: "arial.ttf"
  19. id: arial_med
  20. size: 40
  21. - file: "arial.ttf"
  22. id: arial_sm
  23. size: 14
  24.  
  25. i2c:
  26. sda: GPIO4
  27. scl: GPIO15
  28. frequency: 800kHz
  29.  
  30. display:
  31. - platform: ssd1306_i2c
  32. model: "SSD1306 128x64"
  33. reset_pin: GPIO16
  34. address: 0x3C
  35. lambda: |-
  36. it.printf(0, 0, id(arial_med), "%.0f", id(garage_temp).state);
  37. it.printf(it.get_width(), 0, id(arial_med), TextAlign::TOP_RIGHT, "%3.0f", id(outside_temp).state);
  38. it.print(0, 47, id(arial_sm), "Garage °F");
  39. it.print(78, 47, id(arial_sm), "Outside");
  40.  
  41. light:
  42. - platform: neopixelbus
  43. type: GRBW
  44. variant: SK6812
  45. pin: GPIO17
  46. num_leds: 27
  47. name: "Garage Door Indicator"
  48. effects:
  49. - addressable_color_wipe:
  50. name: Opening
  51. colors:
  52. - red: 100%
  53. green: 0%
  54. blue: 0%
  55. white: 0%
  56. num_leds: 27
  57. - red: 0%
  58. green: 100%
  59. blue: 0%
  60. white: 0%
  61. num_leds: 27
  62. add_led_interval: 300ms
  63. reverse: false
  64. - addressable_color_wipe:
  65. name: Closing
  66. colors:
  67. - red: 0%
  68. green: 100%
  69. blue: 0%
  70. white: 0%
  71. num_leds: 27
  72. - red: 100%
  73. green: 0%
  74. blue: 0%
  75. white: 0%
  76. num_leds: 27
  77. add_led_interval: 300ms
  78. reverse: true
Advertisement
Add Comment
Please, Sign In to add comment