ageurtse
(Arnold)
November 19, 2024, 7:22pm
1
I want to display the state of several persons on a display.
If they are home there name/icon should be bright. if they are away is should be dark.
I think i can handle that part, but i can’t find out how to get te state of a person in esphome
i tryed this
text_sensor:
- platform: homeassistant
id: arnold
entity_id: person.arnold
how can i get the state of person.arnold
ageurtse:
i tryed this
What do you see in the ESPHome logs for that?
During development you can add internal: false
so you can better see what is happening.
You can also try importing it as a binary sensor instead. Maybe person is a boolean under the hood (I’m not sure).
1 Like
ageurtse
(Arnold)
November 19, 2024, 7:58pm
3
It won’t compile some kind of error about a vtable.
Currently not behind my computer so can’t post the error code.
The error must be from another configuration.
text_sensor:
- platform: homeassistant
name: Person
id: person_junior
entity_id: person.junior
internal: false
ageurtse
(Arnold)
November 20, 2024, 5:49am
5
still getting this error
when removing the piece off code it compiles without error’s
/data/cache/platformio/packages/toolchain-xtensa-esp32s3/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld: .pioenvs/wekker/src/main.o:(.literal._Z5setupv+0x2a4): undefined reference to `vtable for esphome::homeassistant::HomeassistantTextSensor'
First thing I would try is update ESPHome and Home Assistant to latest release then clean build files and try again.
Are you using esp-idf or Arduino?
Solution was to change this in my code.
From:
esp32:
board: nodemcu-32s
framework:
type: esp-idf
To:
esp32:
board: nodemcu-32s
framework:
type: arduino
ageurtse
(Arnold)
November 20, 2024, 5:16pm
8
By cleaning the build files and recompiling it works now.
thanks for the help.
For those who whats to know i’m using esp-idf
esp32:
board: esp32s3box
variant: ESP32S3
flash_size: 8MB
framework:
type: esp-idf