esphome: name: ${device_name} friendly_name: ${friendly_name} platformio_options: board_build.mcu: esp32s3 board_build.name: "LilyGO T-Embed ESP32-S3" board_build.upload.flash_size: "16MB" board_build.upload.maximum_size: 16777216 board_build.vendor: "LilyGO" on_boot: priority: 800 then: - lambda: |- id(disp).enable(); id(disp).transfer_byte(0x11); id(disp).disable(); - switch.turn_on: power_on - light.turn_on: id: ${device_id}_backlight brightness: 50% external_components: - source: type: local path: components esp32: board: esp32-s3-devkitc-1 variant: esp32s3 framework: type: arduino wifi: ssid: !secret MyFi_SSID password: !secret MyFi_Pass ap: ssid: "${friendly_name} Hotspot" password: !secret ESP_FallBack_Pass logger: api: password: !secret HA_API_Pass ota: password: !secret HA_ESP_OTApass substitutions: device_name: "t-embed" friendly_name: "T Embed Display" device_id: "t_embed_disp" time: - platform: homeassistant id: "${device_id}_time" #script: # - id: ${device_id}_boot_script # then: # - light.turn_on: # id: ${device_id}_backlight # brightness: 50% sensor: - platform: rotary_encoder filters: - throttle: 0.01s name: "Rotary Encoder" pin_a: number: 02 mode: input: true pullup: true pin_b: number: 01 mode: input: true pullup: true id: ${device_id}_rotary on_clockwise: logger.log: turned clockwise on_anticlockwise: logger.log: turned anti clockwise - platform: adc pin: 4 attenuation: 11db name: "vccadc" update_interval: 60s id: ${device_id}_vcc_adc text_sensor: - platform: template name: template text sensor id: temp_text_sensor - platform: wifi_info ip_address: name: ${friendly_name} IP Address id: ${device_id}_ip entity_category: diagnostic icon: mdi:fingerprint ssid: name: ${friendly_name} ESP Connected SSID bssid: name: ${friendly_name} ESP Connected BSSID mac_address: name: ${friendly_name} ESP Mac Wifi Address scan_results: name: ${friendly_name} ESP Latest Scan Results binary_sensor: - platform: status name: "${friendly_name} Node Status" id: "${device_id}_system_status" - platform: gpio pin: number: 0 inverted: true mode: input: true pullup: true id: "${device_id}_press_sel" name: "${friendly_name} Press Select" # on_click: # min_length: 5ms # max_length: 350ms # then: # - logger.log: Press Select # on_multi_click: # - timing: # - ON for at least 0.5s # then: # - logger.log: Press Select Hold on_press: - voice_assistant.start: on_release: - voice_assistant.stop: - platform: gpio id: ${device_id}_usb_detect name: ${friendly_name} USB Power Connected pin: number: 46 switch: - platform: gpio pin: number: 46 mode: output: true name: "Power On" id: power_on restore_mode: RESTORE_DEFAULT_ON - platform: gpio pin: number: 48 mode: output: true name: "Mic On" id: mic_switch output: - platform: ledc pin: GPIO15 id: ${device_id}_gpio15 color: - id: my_red red: 100% green: 0% blue: 0% - id: my_yellow red: 100% green: 100% blue: 0% - id: my_green red: 0% green: 100% blue: 0% - id: my_blue red: 0% green: 0% blue: 100% - id: my_gray red: 50% green: 50% blue: 50% font: - file: 'Oswald-Regular.ttf' id: font1 size: 16 light: - platform: monochromatic output: ${device_id}_gpio15 name: "${friendly_name} Backlight" id: ${device_id}_backlight - platform: fastled_spi chipset: APA102 clock_pin: GPIO45 data_pin: GPIO42 num_leds: 7 rgb_order: BGR name: "FastLED SPI Light" effects: - addressable_rainbow: name: Rainbow Effect With Custom Values speed: 10 width: 50 - addressable_scan: name: Scan Effect With Custom Values move_interval: 100ms scan_width: 1 - pulse: name: "Fast Pulse" transition_length: 0.5s update_interval: 0.5s - pulse: name: "Slow Pulse" transition_length: 1s update_interval: 2s - random: name: Random Effect With Custom Values transition_length: 5s update_interval: 7s - strobe: name: Strobe Effect With Custom Values colors: - state: true brightness: 100% red: 100% green: 90% blue: 0% duration: 500ms - state: false duration: 250ms - state: true brightness: 100% red: 0% green: 100% blue: 0% duration: 500ms - flicker: name: Flicker Effect With Custom Values alpha: 95% intensity: 1.5% - addressable_color_wipe: name: Color Wipe Effect With Custom Values colors: - red: 100% green: 100% blue: 100% num_leds: 1 - red: 0% green: 0% blue: 0% num_leds: 1 add_led_interval: 100ms reverse: false - addressable_twinkle: name: Twinkle Effect With Custom Values twinkle_probability: 5% progress_interval: 4ms - addressable_random_twinkle: name: Random Twinkle Effect With Custom Values twinkle_probability: 5% progress_interval: 32ms - addressable_fireworks: name: Fireworks Effect With Custom Values update_interval: 32ms spark_probability: 10% use_random_color: false fade_out_rate: 120 spi: clk_pin: GPIO12 mosi_pin: GPIO11 display: - platform: st7789v model: CUSTOM id: disp cs_pin: GPIO10 dc_pin: GPIO13 reset_pin: GPIO9 height: 320 width: 170 offset_height: 35 offset_width: 0 rotation: 270 eightbitcolor: false lambda: |- it.printf(5, 5, id(font1), id(my_blue), TextAlign::TOP_LEFT, "Burkey has two dogs"); media_player: - platform: i2s_audio name: "${friendly_name} Media Player" id: ${device_id}_media_player dac_type: external i2s_dout_pin: GPIO6 mode: mono i2s_audio_id: i2s_amp microphone: - platform: i2s_audio id: t_embed_mic i2s_din_pin: GPIO14 adc_type: external pdm: true i2s_audio_id: i2s_mic voice_assistant: microphone: t_embed_mic i2s_audio: - id: i2s_mic i2s_lrclk_pin: GPIO21 i2s_bclk_pin: GPIO47 - id: i2s_amp i2s_lrclk_pin: GPIO05 i2s_bclk_pin: GPIO07 i2c: sda: GPIO18 scl: GPIO08 scan: true #i2c - SDA IO18, CLK IO08 #APA102: CLK IO45, DI IO42 #ES7210: BCLK IO47, LRCK IO21, DIN IO14, MCLK IO48 (https://uploadcdn.oneyac.com/attachments/userfile/68/63/1629167664244_5904.pdf) #SD: CS IO39, SCK IO40, MOSI IO41, MISO IO38 #https://community.home-assistant.io/t/did-anyone-already-trying-to-get-esphome-to-work-on-lilygo-t-embed/491154/23 #https://www.lilygo.cc/products/t-embed