Xiaomi LYWSD03MMC entities "Unavailable" after update

Hi,

I had an esp32s connected to 2x Xiaomi LYWSD03MMC temperature and humidy sensors. The esp32s died a couple of weeks ago so I replaced it with a new one. This showed up in the dashboard fine once I added the location and disabled the failed unit (not sure how to remove it).

However after some recent updates to Home Assistant and ESPHome all the values show as “Unavailable” both in the dashboard and in a Grafana dashboard.

If I view the logs you can see that it has no problem with retrieving the values:

[08:52:15][D][esp32_ble_tracker:180]: Starting scan…
[08:52:29][D][esp32_ble_tracker:620]: Found device A4:C1:38:D0:71:87 RSSI=-80
[08:52:29][D][esp32_ble_tracker:641]: Address Type: PUBLIC
[08:52:29][D][esp32_ble_tracker:643]: Name: ‘LYWSD03MMC’
[08:52:48][D][xiaomi_ble:313]: Got Xiaomi LYWSD03MMC (A4:C1:38:D0:71:87):
[08:52:48][D][xiaomi_ble:316]: Temperature: 13.2°C
[08:52:48][D][sensor:131]: ‘Temperature #2’: Sending state 13.20000 °C with 1 decimals of accuracy
[08:53:44][D][esp32_ble_tracker:620]: Found device A4:C1:38:48:68:BF RSSI=-76
[08:53:44][D][esp32_ble_tracker:641]: Address Type: PUBLIC
[08:53:44][D][esp32_ble_tracker:643]: Name: ‘LYWSD03MMC’
[08:55:36][D][xiaomi_ble:313]: Got Xiaomi LYWSD03MMC (A4:C1:38:48:68:BF):
[08:55:36][D][xiaomi_ble:319]: Humidity: 86.0%
[08:55:36][D][sensor:131]: ‘Humidity’: Sending state 86.00000 % with 0 decimals of accuracy

Can anyone give this noob some pointers on how to troubleshoot this?

Cheers
David

Look at the home assistant dev-tools | states and see what is there.

Also look in Configuration | devices and tell us what you see for the device.

PS does your username indicate you are in NZ? Always nice to see Kiwis :slight_smile:

Hi Nick,

Thank you for your reply.

dev-tools | states:
The states show as UNKNOWN

Confguration | devices:

ESPHome

Device info

Home Assistant Add-on

by Home Assistant Community Add-ons

Firmware: 1.20.4

Entities

+3 disabled entities

Yes you guessed it I’m in NZ! :slightly_smiling_face:

This is clearer:

I suspect the system is confused by the old device, which you said you couldn’t remove.

To remove it, go to Configuration|Integrations in the HA UI.

Find the esphome panel. Within it are all the esphome devices configured in HA.

Click the one you want to remove. Then click the overflow button (3 vertical dots) and choose Delete.

Hi Nick,

Do you mean this?
image

Will it find the current one again if I do that?

Yes, or you can add it via clicking add integration, then esphome.

Thank yo so much Nick, that did the trick.

Excellent. Enjoy playing with HA during our hopefully short lockdown.