Esphome no connection to ha

Hello people from the internet

I’ve got a hard time setting up my lilygo t s3.
I had that running before, had it unplugged for a couple of weeks and now wanted to re-activate it. Because it would’nt let me do an update I decided to do a fresh flashing but saved the yaml before.
Then problems started…

I tried various ways of setting up (automatic method, manual method with sample yamls, manual method wih my saved yaml…) but encountered different problems. Being able to fash but not to use wifi; seing the new device but not being able to adapt the yaml code; not getting it online within esphome at all.

Long story short: I managed to flash it, to use my old code, to communicate in my wifi network, to be shown “online” within esphome.
The big “but” however is: I don’t get the notification that a new device is available (which I got at some of my various attempts from above), hence there is no connection between ha and esphome. When trying to manually add an esp integration I enter the “esp hostname” at “host” and will get the message that there is no connection possible to the esp and that I am to check that the yaml file contains the ‘api’ line.

esphome:
  name: doorpanel
  friendly_name: doorpanel
  platformio_options:
    board_build.f_flash: 80000000L
    board_build.partitions: default_16MB.csv
    board_build.arduino.memory_type: qio_opi

external_components:
  - source: github://landonr/lilygo-tdisplays3-esphome
    components: [tdisplays3]

esp32:
  board: esp32-s3-devkitc-1
  variant: esp32s3
  framework:
    type: arduino
  flash_size: 16MB

# Enable logging
logger:

# Enable Home Assistant API
api:
  password: "XXXXXX"

ota:
  password: "6ada29f6f41ce1685d29d406efd25fa4"

wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password
  manual_ip:
    static_ip: 192.168.188.49
    gateway: 192.168.188.1
    subnet: 255.255.255.0

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "doorpanel Fallback Hotspot"
    password: "zQ9tuPKIfFMu"


time:
  - platform: homeassistant
    id: ha_time

binary_sensor:
  - platform: gpio
    pin: 
      number: GPIO0
      inverted: true
    name: "Button 1"
  - platform: gpio
    pin: 
      number: GPIO14
      inverted: true
    name: "Button 2"
  - platform: homeassistant
    id: licht
    entity_id: binary_sensor.licht
  - platform: homeassistant
    id: fenster
    entity_id: binary_sensor.windows

output:
  - platform: ledc
    pin: GPIO38
    id: gpio38
    frequency: 2000

light:
  - platform: monochromatic
    output: gpio38
    name: "Backlight"
    restore_mode: RESTORE_DEFAULT_ON

# You can either setup the backlight as a switch like below or make it dimmable using a light output like above
# switch:
#   - platform: gpio
#     pin: GPIO38
#     name: "Backlight"
#     id: backlight
#     internal: true
#     restore_mode: RESTORE_DEFAULT_ON

font:
  - file: "gfonts://Roboto"
    id: roboto
    size: 25

image:
  - file: "images/ceiling-light-multiple.png"
    id: light_off
    resize: 100x100
    type: RGB24
  - file: "images/ceiling-light.png"
    id: light_on
    resize: 100x100
    type: RGB24
  - file: "images/mailbox-outline.png"
    id: mail_off
    resize: 100x100
    type: RGB24
  - file: "images/mailbox-up-outline.png"
    id: mail_on
    resize: 100x100
    type: RGB24
  - file: "images/window-open.png"
    id: window_on
    resize: 100x100
    type: RGB24
  - file: "images/window-closed.png"
    id: window_off
    resize: 100x100
    type: RGB24

display:
  - platform: tdisplays3
    id: disp
    update_interval: 2s
    rotation: 90
    lambda: |-
      if (id(licht).state) {
        it.image(0,25, id(light_on));
      } else {
        it.image(0,25, id(light_off));
      }
       if (id(fenster).state) {
        it.image(110,30, id(window_on));
      } else {
        it.image(110,30, id(window_off));
      }
      it.image(220, 30, id(mail_off));

This is the yaml.
Grateful for any hint.

Rico

Since you have used a static IP address try adding it manually using that.

1 Like

You’re my hero.
Case closed!

1 Like