Esphome not receiving homeassistant state values?

I’ve been using a TTGO T5 2.9" v2.2 device with ESPHome, but I can’t get it to display values from HomeAssistant.

Any ideas?

It seems like this should be possible per the alarm example here:

Or the various folks using it here:

YAML:

esphome:
  name: epaper29

esp32:
  board: esp32dev
  framework:
    type: arduino

# Enable logging
logger:
  level: VERY_VERBOSE
  logs: 
      api: VERY_VERBOSE
      homeassistant: VERY_VERBOSE
      api.service: VERY_VERBOSE
      sensor: VERY_VERBOSE
      scheduler: DEBUG

# Enable Home Assistant API
api:
  encryption:
    key: {REDACTED}

ota:
  password: {REDACTED}

spi:
  clk_pin: 18
  mosi_pin: 23

wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Epaper29 Fallback Hotspot"
    password: {REDACTED}

captive_portal:
    
font:
  # gfonts://family[@weight]
  - file: "gfonts://Roboto"
    id: roboto
    size: 20
# gfonts://family[@weight]
  - file: "gfonts://Roboto"
    id: roboto16
    size: 16
  - file: "gfonts://Roboto"
    id: roboto12
    size: 12
  - file: "gfonts://Roboto"
    id: roboto10
    size: 10
  
time:
  - platform: homeassistant
    id: esptime
  
sensor:
  - platform: homeassistant
    entity_id: sensor.sensi_09efda_current_temperature_2
    id: sensi_temp
  - platform: homeassistant
    entity_id: sensor.zigbee_deep_freeze_110fa523_temperature
    id: deepfreeze_temp
text_sensor:
  - platform: homeassistant
    entity_id: cover.garage_door
    id: garage_door_status
  - platform: homeassistant
    entity_id: alarm_control_panel.abode_alarm
    id: abode_alarm
  - platform: homeassistant
    entity_id: alarm_control_panel.blink_home
    id: blink_status

#dimensions: 296px by 128px
display:
  - platform: waveshare_epaper
    cs_pin: 5
    dc_pin: 19
    busy_pin: 4
    reset_pin: 12
    model: 2.90in
    full_update_every: 60
    rotation: 270
    lambda: |-
      it.print(255,0,id(roboto10), "Testv20");
      it.strftime(242, 115, id(roboto10), "%I:%M:%S%p", id(esptime).now()); 
      if(id(abode_alarm).has_state()) {
        it.printf(0, 0, id(roboto16), "Abode: %s",id(abode_alarm).state.c_str());
      } else {
        it.printf(0, 0, id(roboto16), "Abode: No Status");
      }
      if(id(abode_alarm).has_state()) {
        it.printf(0, 20, id(roboto16), "Blink: %s",id(blink_status).state.c_str());
      } else {
        it.printf(0, 20, id(roboto16), "Blink: No Status");
      }
      if(id(abode_alarm).has_state()) {
        it.printf(0, 40, id(roboto16), "Garage Door: %s",id(garage_door_status).state.c_str());
      } else {
        it.printf(0, 40, id(roboto16), "Garage Door: No Status");
      }
      if(id(abode_alarm).has_state()) {
        it.printf(0, 60, id(roboto16), "Thermostat: %.1f°F",id(sensi_temp).state);
      } else {
        it.printf(0, 60, id(roboto16), "Thermostat: No Status");
      }
      if(id(abode_alarm).has_state()) {
        it.printf(0, 80, id(roboto16), "Deep Freeze: %.1f°F",id(deepfreeze_temp).state);
      } else {
        it.printf(0, 80, id(roboto16), "Deep Freeze: No Status");
      }

Logs:

INFO Reading configuration /config/esphome/epaper29.yaml...
INFO Detected timezone 'America/Chicago'
WARNING GPIO4 is a Strapping PIN and should be avoided.
Attaching external pullup/down resistors to strapping pins can cause unexpected failures.
See https://esphome.io/guides/faq.html#why-am-i-getting-a-warning-about-strapping-pins
WARNING GPIO12 is a Strapping PIN and should be avoided.
Attaching external pullup/down resistors to strapping pins can cause unexpected failures.
See https://esphome.io/guides/faq.html#why-am-i-getting-a-warning-about-strapping-pins
INFO Starting log output from epaper29.local using esphome API
INFO Successfully connected to epaper29.local
[16:54:50][I][app:102]: ESPHome version 2022.6.2 compiled on Jul 17 2022, 16:49:05
[16:54:50][C][wifi:491]: WiFi:
[16:54:50][C][wifi:353]:   Local MAC: 24:0A:C4:2F:98:9C
[16:54:50][C][wifi:354]:   SSID: [redacted]
[16:54:50][C][wifi:355]:   IP Address: {REDACTED}
[16:54:50][C][wifi:357]:   BSSID: [redacted]
[16:54:50][C][wifi:358]:   Hostname: 'epaper29'
[16:54:50][C][wifi:360]:   Signal strength: -27 dB ▂▄▆█
[16:54:50][V][wifi:362]:   Priority: -6.0
[16:54:50][C][wifi:364]:   Channel: 6
[16:54:50][C][wifi:365]:   Subnet: 255.255.255.0
[16:54:50][C][wifi:366]:   Gateway: {REDACTED}
[16:54:50][C][wifi:367]:   DNS1: {REDACTED}
[16:54:50][C][wifi:368]:   DNS2: {REDACTED}
[16:54:50][C][logger:275]: Logger:
[16:54:50][C][logger:276]:   Level: VERY_VERBOSE
[16:54:50][C][logger:277]:   Log Baud Rate: 115200
[16:54:50][C][logger:278]:   Hardware UART: UART0
[16:54:50][C][logger:280]:   Level for 'api': VERY_VERBOSE
[16:54:50][C][logger:280]:   Level for 'homeassistant': VERY_VERBOSE
[16:54:50][C][logger:280]:   Level for 'api.service': VERY_VERBOSE
[16:54:50][C][logger:280]:   Level for 'sensor': VERY_VERBOSE
[16:54:50][C][logger:280]:   Level for 'scheduler': DEBUG
[16:54:50][C][spi:097]: SPI bus:
[16:54:50][C][spi:098]:   CLK Pin: GPIO18
[16:54:50][C][spi:100]:   MOSI Pin: GPIO23
[16:54:50][C][spi:102]:   Using HW SPI: YES
[16:54:50][C][homeassistant.time:010]: Home Assistant Time:
[16:54:50][C][homeassistant.time:011]:   Timezone: 'CST6CDT,M3.2.0,M11.1.0'
[16:54:50][C][waveshare_epaper:221]: Waveshare E-Paper
[16:54:50][C][waveshare_epaper:221]:   Rotations: 270 °
[16:54:50][C][waveshare_epaper:221]:   Dimensions: 296px x 128px
[16:54:50][C][waveshare_epaper:245]:   Model: 2.9in
[16:54:50][C][waveshare_epaper:251]:   Full Update Every: 60
[16:54:50][C][waveshare_epaper:252]:   Reset Pin: GPIO12
[16:54:50][C][waveshare_epaper:253]:   DC Pin: GPIO19
[16:54:50][C][waveshare_epaper:254]:   Busy Pin: GPIO4
[16:54:50][C][waveshare_epaper:255]:   Update Interval: 1.0s
[16:54:50][C][captive_portal:088]: Captive Portal:
[16:54:50][C][mdns:084]: mDNS:
[16:54:50][C][mdns:085]:   Hostname: epaper29
[16:54:50][V][mdns:086]:   Services:
[16:54:50][V][mdns:088]:   - _esphomelib, _tcp, 6053
[16:54:50][V][mdns:090]:     TXT: version = 2022.6.2
[16:54:50][V][mdns:090]:     TXT: mac = 240ac42f989c
[16:54:50][V][mdns:090]:     TXT: platform = ESP32
[16:54:50][V][mdns:090]:     TXT: board = esp32dev
[16:54:50][C][ota:085]: Over-The-Air Updates:
[16:54:50][C][ota:086]:   Address: epaper29.local:3232
[16:54:50][C][ota:089]:   Using Password.
[16:54:50][C][api:138]: API Server:
[16:54:50][C][api:139]:   Address: epaper29.local:6053
[16:54:50][C][api:141]:   Using noise encryption: YES
[16:54:50][C][homeassistant.sensor:030]: Homeassistant Sensor 'sensi_temp'
[16:54:50][C][homeassistant.sensor:030]:   State Class: ''
[16:54:50][C][homeassistant.sensor:030]:   Unit of Measurement: ''
[16:54:50][C][homeassistant.sensor:030]:   Accuracy Decimals: 1
[16:54:50][C][homeassistant.sensor:031]:   Entity ID: 'sensor.sensi_09efda_current_temperature_2'
[16:54:50][C][homeassistant.sensor:030]: Homeassistant Sensor 'deepfreeze_temp'
[16:54:50][C][homeassistant.sensor:030]:   State Class: ''
[16:54:50][C][homeassistant.sensor:030]:   Unit of Measurement: ''
[16:54:50][C][homeassistant.sensor:030]:   Accuracy Decimals: 1
[16:54:50][C][homeassistant.sensor:031]:   Entity ID: 'sensor.zigbee_deep_freeze_110fa523_temperature'
[16:54:50][C][homeassistant.text_sensor:023]: Homeassistant Text Sensor 'garage_door_status'
[16:54:50][C][homeassistant.text_sensor:024]:   Entity ID: 'cover.garage_door'
[16:54:50][C][homeassistant.text_sensor:023]: Homeassistant Text Sensor 'abode_alarm'
[16:54:50][C][homeassistant.text_sensor:024]:   Entity ID: 'alarm_control_panel.abode_alarm'
[16:54:50][C][homeassistant.text_sensor:023]: Homeassistant Text Sensor 'blink_status'
[16:54:50][C][homeassistant.text_sensor:024]:   Entity ID: 'alarm_control_panel.blink_home'
[16:54:52][V][component:199]: Component waveshare_epaper.display took a long time for an operation (0.67 s).
[16:54:52][V][component:200]: Components should block for at most 20-30ms.
[16:54:53][V][component:199]: Component waveshare_epaper.display took a long time for an operation (0.11 s).
[16:54:53][V][component:200]: Components should block for at most 20-30ms.
[16:55:05][VV][api.service:373]: on_ping_request: PingRequest {}
[16:55:05][VV][api.service:043]: send_ping_response: PingResponse {}
[16:55:20][VV][api.service:373]: on_ping_request: PingRequest {}
[16:55:20][VV][api.service:043]: send_ping_response: PingResponse {}
[16:55:35][VV][api.service:373]: on_ping_request: PingRequest {}
[16:55:35][VV][api.service:043]: send_ping_response: PingResponse {}
[16:55:50][VV][api.service:373]: on_ping_request: PingRequest {}
[16:55:50][VV][api.service:043]: send_ping_response: PingResponse {}
[16:55:52][V][component:199]: Component waveshare_epaper.display took a long time for an operation (0.67 s).
[16:55:52][V][component:200]: Components should block for at most 20-30ms.
[16:55:53][V][component:199]: Component waveshare_epaper.display took a long time for an operation (0.11 s).
[16:55:53][V][component:200]: Components should block for at most 20-30ms.
[16:56:05][VV][api.service:373]: on_ping_request: PingRequest {}
[16:56:05][VV][api.service:043]: send_ping_response: PingResponse {}
[16:56:20][VV][api.service:373]: on_ping_request: PingRequest {}
[16:56:20][VV][api.service:043]: send_ping_response: PingResponse {}
[16:56:35][VV][api.service:373]: on_ping_request: PingRequest {}
[16:56:35][VV][api.service:043]: send_ping_response: PingResponse {}
[16:56:50][VV][api.service:373]: on_ping_request: PingRequest {}
[16:56:50][VV][api.service:043]: send_ping_response: PingResponse {}
[16:56:52][V][component:199]: Component waveshare_epaper.display took a long time for an operation (0.67 s).
[16:56:52][V][component:200]: Components should block for at most 20-30ms.
[16:56:53][V][component:199]: Component waveshare_epaper.display took a long time for an operation (0.11 s).
[16:56:53][V][component:200]: Components should block for at most 20-30ms.
[16:57:05][VV][api.service:373]: on_ping_request: PingRequest {}
[16:57:05][VV][api.service:043]: send_ping_response: PingResponse {}
[16:57:21][VV][api.service:373]: on_ping_request: PingRequest {}
[16:57:21][VV][api.service:043]: send_ping_response: PingResponse {}
[16:57:36][VV][api.service:373]: on_ping_request: PingRequest {}
[16:57:36][VV][api.service:043]: send_ping_response: PingResponse {}
[16:57:46][VV][esp-idf:000]: I (476105) wpa: GTK 2 is already in use in entry 3, it may be an attack, ignore it.

[16:57:46][VV][esp-idf:000]: I (476116) wpa: GTK 2 is already in use in entry 3, it may be an attack, ignore it.

[16:57:51][VV][api.service:373]: on_ping_request: PingRequest {}
[16:57:51][VV][api.service:043]: send_ping_response: PingResponse {}
[16:57:52][V][component:199]: Component waveshare_epaper.display took a long time for an operation (0.67 s).
[16:57:52][V][component:200]: Components should block for at most 20-30ms.
[16:57:53][V][component:199]: Component waveshare_epaper.display took a long time for an operation (0.11 s).
[16:57:53][V][component:200]: Components should block for at most 20-30ms.
[16:58:06][VV][api.service:373]: on_ping_request: PingRequest {}
[16:58:06][VV][api.service:043]: send_ping_response: PingResponse {}
[16:58:21][VV][api.service:373]: on_ping_request: PingRequest {}
[16:58:21][VV][api.service:043]: send_ping_response: PingResponse {}
[16:58:36][VV][api.service:373]: on_ping_request: PingRequest {}
[16:58:36][VV][api.service:043]: send_ping_response: PingResponse {}
[16:58:51][VV][api.service:373]: on_ping_request: PingRequest {}
[16:58:51][VV][api.service:043]: send_ping_response: PingResponse {}
[16:58:52][V][component:199]: Component waveshare_epaper.display took a long time for an operation (0.67 s).
[16:58:52][V][component:200]: Components should block for at most 20-30ms.
[16:58:53][V][component:199]: Component waveshare_epaper.display took a long time for an operation (0.11 s).
[16:58:53][V][component:200]: Components should block for at most 20-30ms.
[16:59:06][VV][api.service:373]: on_ping_request: PingRequest {}
[16:59:06][VV][api.service:043]: send_ping_response: PingResponse {}

Picture of what it’s doing:

It does run fine and the display reloads, time runs fine too. It’s just not getting a state from any sensors on Home Assistant. Any help would be greatly appreciated! Thank you

Also, here’s the raw values I’m trying to display as shown in Developer Tools:




I think so? (if this is what you mean)

NICE! It lives! – Thank you!!

1 Like

Hi, what was the missing point to get the values send to the ESP? I have the same issue (values are not available at the ESP). Looks like I’m missing some tiny last bit.

Any update? I have similar issues. Seems like there is a missing post in here…

I fixed mine, as it was not added in the integration page. I was only working on it in the esphome addon page…

Ahh yes sorry forgot to reply. This is the answer. You can configure ESPHome but still need to add it as an integration.