-
-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
362 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,176 @@ | ||
esphome: | ||
name: "clear-homething" | ||
platform: ESP32 | ||
board: featheresp32 | ||
on_boot: | ||
priority: 600.0 | ||
then: | ||
- delay: 45s | ||
- if: | ||
condition: | ||
not: | ||
- wifi.connected: | ||
then: | ||
- switch.turn_on: sleep_toggle | ||
|
||
wifi: | ||
ssid: !secret wifi_ssid | ||
password: !secret wifi_password | ||
fast_connect: true | ||
id: wifi_id | ||
power_save_mode: HIGH | ||
ap: | ||
ssid: "${friendly_name} Fallback" | ||
password: !secret wifi_fallback_password | ||
|
||
external_components: | ||
- source: | ||
# type: git | ||
# url: https://github.com/landonr/homeThing | ||
# ref: main | ||
# refresh: 0s | ||
type: local | ||
path: components | ||
components: [homeThing] | ||
- source: | ||
# type: git | ||
# url: https://github.com/landonr/esphome-components | ||
# ref: main | ||
# refresh: 0s | ||
type: local | ||
path: ../local_components/components | ||
components: [ | ||
homeassistant_component, | ||
homeassistant_media_player, | ||
media_player_source, | ||
media_player_source_sonos, | ||
media_player_source_spotify, | ||
media_player_source_custom | ||
] | ||
|
||
packages: | ||
device_base: !include common/device_base.yaml | ||
ipod_control_backlight: !include common/ipod/lilygo_tdisplay_ipod_backlight.yaml | ||
ipod_control_battery: !include common/ipod/lilygo_tdisplay_ipod_battery.yaml | ||
ipod_control_binary_sensor: !include common/ipod/lilygo_tdisplay_ipod_binary_sensor.yaml | ||
ipod_control_rotary: !include common/ipod/lilygo_tdisplay_ipod_rotary.yaml | ||
ipod_control_sleep: !include common/ipod/lilygo_tdisplay_ipod_sleep.yaml | ||
home_media_player: !include homeConfig/media_player.yaml | ||
home_text_sensor: !include homeConfig/text_sensor.yaml | ||
home_light: !include homeConfig/light.yaml | ||
home_switch: !include homeConfig/switch.yaml | ||
fonts: !include common/fonts.yaml | ||
icon_fonts: !include common/icon_fonts.yaml | ||
|
||
substitutions: | ||
friendly_name: "clear homething" | ||
|
||
color: | ||
- id: my_primary_accent | ||
red_int: 75 | ||
green_int: 45 | ||
blue_int: 209 | ||
|
||
homeThing: | ||
id: homeThingMenu | ||
settings: | ||
sleep_after: 14400 | ||
sleep_switch: sleep_toggle | ||
backlight: backlight | ||
battery: | ||
battery_percent: battery_percent | ||
charging: charging | ||
media_player_group: media_group_component | ||
display: my_display | ||
on_redraw: | ||
then: | ||
component.update: my_display | ||
display_state: | ||
colors: | ||
accent_primary: my_primary_accent | ||
draw_battery_level: true | ||
font_small: small_font | ||
font_medium: medium_font | ||
font_large: large_font | ||
font_large_heavy: large_heavy_font | ||
font_material_large: material_font_large | ||
font_material_small: material_font_small | ||
font_logo: home_thing_logo | ||
screens: | ||
- name: Desk Screen | ||
entities: | ||
- type: command | ||
name: "desk nudge up" | ||
command: | ||
- homeassistant.service: | ||
service: button.press | ||
data: | ||
entity_id: "button.desk_position_nudge_up" | ||
- type: command | ||
name: "desk nudge down" | ||
command: | ||
- homeassistant.service: | ||
service: button.press | ||
data: | ||
entity_id: "button.desk_position_nudge_down" | ||
- id: light_desk_lamp | ||
type: light | ||
- name: Settings Screen | ||
show_version: True | ||
entities: | ||
- id: backlight | ||
type: light | ||
- id: "restart_switch" | ||
type: switch | ||
- id: wifi_ssid | ||
type: text_sensor | ||
- id: wifi_signal_percent | ||
type: sensor | ||
- id: wifi_ip | ||
type: text_sensor | ||
|
||
spi: | ||
clk_pin: GPIO18 | ||
mosi_pin: GPIO19 | ||
|
||
display: | ||
- platform: st7789v | ||
model: TTGO_TDisplay_135x240 | ||
id: my_display | ||
cs_pin: GPIO5 | ||
dc_pin: GPIO16 | ||
reset_pin: GPIO23 | ||
rotation: 90 | ||
update_interval: 10s | ||
lambda: |- | ||
id(homeThingMenu)->draw_menu_screen(); | ||
return; | ||
text_sensor: | ||
- platform: wifi_info | ||
ip_address: | ||
name: IP Address | ||
internal: True | ||
id: wifi_ip | ||
ssid: | ||
name: SSID | ||
internal: True | ||
id: wifi_ssid | ||
|
||
sensor: | ||
- platform: wifi_signal # Reports the WiFi signal strength/RSSI in dB | ||
name: "WiFi Signal dB" | ||
id: wifi_signal_db | ||
update_interval: 60s | ||
entity_category: "diagnostic" | ||
internal: True | ||
|
||
- platform: copy # Reports the WiFi signal strength in % | ||
source_id: wifi_signal_db | ||
name: "WiFi Signal %" | ||
id: wifi_signal_percent | ||
internal: True | ||
filters: | ||
- lambda: return min(max(2 * (x + 100.0), 0.0), 100.0); | ||
unit_of_measurement: "Signal %" | ||
entity_category: "diagnostic" |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,186 @@ | ||
# set up your name | ||
esphome: | ||
name: "homething-proto" | ||
platform: ESP32 | ||
board: featheresp32 | ||
on_boot: | ||
priority: 600.0 | ||
then: | ||
- delay: 45s | ||
- if: | ||
condition: | ||
not: | ||
- wifi.connected: | ||
then: | ||
- switch.turn_on: sleep_toggle | ||
|
||
wifi: | ||
ssid: !secret wifi_ssid | ||
password: !secret wifi_password | ||
fast_connect: true | ||
id: wifi_id | ||
power_save_mode: HIGH | ||
ap: | ||
ssid: "${friendly_name} Fallback" | ||
password: !secret wifi_fallback_password | ||
|
||
external_components: | ||
- source: | ||
# type: git | ||
# url: https://github.com/landonr/homeThing | ||
# ref: main | ||
# refresh: 0s | ||
type: local | ||
path: components | ||
components: [homeThing] | ||
- source: | ||
# type: git | ||
# url: https://github.com/landonr/esphome-components | ||
# ref: main | ||
# refresh: 0s | ||
type: local | ||
path: ../local_components/components | ||
components: [ | ||
homeassistant_component, | ||
homeassistant_media_player, | ||
media_player_source, | ||
media_player_source_sonos, | ||
media_player_source_spotify, | ||
media_player_source_custom, | ||
homeassistant_cover | ||
] | ||
|
||
packages: | ||
device_base: !include common/device_base.yaml | ||
ipod_control_backlight: !include common/ipod/lilygo_tdisplay_ipod_backlight.yaml | ||
ipod_control_battery: !include common/ipod/lilygo_tdisplay_ipod_battery.yaml | ||
ipod_control_binary_sensor: !include common/ipod/lilygo_tdisplay_ipod_binary_sensor.yaml | ||
ipod_control_rotary: !include common/ipod/lilygo_tdisplay_ipod_rotary.yaml | ||
ipod_control_sleep: !include common/ipod/lilygo_tdisplay_ipod_sleep.yaml | ||
home_media_player: !include homeConfig/media_player.yaml | ||
home_text_sensor: !include homeConfig/text_sensor.yaml | ||
home_light: !include homeConfig/light.yaml | ||
home_switch: !include homeConfig/switch.yaml | ||
fonts: !include common/fonts.yaml | ||
icon_fonts: !include common/icon_fonts.yaml | ||
|
||
substitutions: | ||
friendly_name: "homeThing proto" | ||
|
||
color: | ||
- id: my_primary_accent | ||
red_int: 75 | ||
green_int: 45 | ||
blue_int: 209 | ||
|
||
cover: | ||
- platform: homeassistant_cover | ||
entity_id: "cover.megadesk_cover" | ||
name: "Megadesk" | ||
id: cover_megadesk | ||
|
||
homeThing: | ||
id: homeThingMenu | ||
settings: | ||
sleep_after: 14400 | ||
sleep_switch: sleep_toggle | ||
backlight: backlight | ||
battery: | ||
battery_percent: battery_percent | ||
charging: charging | ||
media_player_group: media_group_component | ||
display: my_display | ||
on_redraw: | ||
then: | ||
component.update: my_display | ||
display_state: | ||
colors: | ||
accent_primary: my_primary_accent | ||
draw_battery_level: true | ||
font_small: small_font | ||
font_medium: medium_font | ||
font_large: large_font | ||
font_large_heavy: large_heavy_font | ||
font_material_large: material_font_large | ||
font_material_small: material_font_small | ||
font_logo: home_thing_logo | ||
screens: | ||
- name: Desk Screen | ||
entities: | ||
- id: cover_megadesk | ||
type: cover | ||
- type: command | ||
name: "desk nudge up" | ||
command: | ||
- homeassistant.service: | ||
service: button.press | ||
data: | ||
entity_id: "button.desk_position_nudge_up" | ||
- type: command | ||
name: "desk nudge down" | ||
command: | ||
- homeassistant.service: | ||
service: button.press | ||
data: | ||
entity_id: "button.desk_position_nudge_down" | ||
- id: light_desk_lamp | ||
type: light | ||
- name: Settings Screen | ||
show_version: True | ||
entities: | ||
- id: backlight | ||
type: light | ||
- id: "restart_switch" | ||
type: switch | ||
- id: wifi_ssid | ||
type: text_sensor | ||
- id: wifi_signal_percent | ||
type: sensor | ||
- id: wifi_ip | ||
type: text_sensor | ||
|
||
spi: | ||
clk_pin: GPIO18 | ||
mosi_pin: GPIO19 | ||
|
||
display: | ||
- platform: st7789v | ||
model: TTGO_TDisplay_135x240 | ||
id: my_display | ||
cs_pin: GPIO5 | ||
dc_pin: GPIO16 | ||
reset_pin: GPIO23 | ||
rotation: 90 | ||
update_interval: 10s | ||
lambda: |- | ||
id(homeThingMenu)->draw_menu_screen(); | ||
return; | ||
text_sensor: | ||
- platform: wifi_info | ||
ip_address: | ||
name: IP Address | ||
internal: True | ||
id: wifi_ip | ||
ssid: | ||
name: SSID | ||
internal: True | ||
id: wifi_ssid | ||
|
||
sensor: | ||
- platform: wifi_signal # Reports the WiFi signal strength/RSSI in dB | ||
name: "WiFi Signal dB" | ||
id: wifi_signal_db | ||
update_interval: 60s | ||
entity_category: "diagnostic" | ||
internal: True | ||
|
||
- platform: copy # Reports the WiFi signal strength in % | ||
source_id: wifi_signal_db | ||
name: "WiFi Signal %" | ||
id: wifi_signal_percent | ||
internal: True | ||
filters: | ||
- lambda: return min(max(2 * (x + 100.0), 0.0), 100.0); | ||
unit_of_measurement: "Signal %" | ||
entity_category: "diagnostic" |
Empty file.