"Last seen" data - question

Hi.

Does someone know what does “Last seen” in ZHA GUI part ov HA really means for the device?

I have noticed while checking debug mode of ZHA, that all devices seem to communicate way more often than shown in “Last seen section” of GUI.

For example:
AQARA lumi.weather sensor “Last seen status” in GUI shows: Last Seen: 2023-12-17T16:45:26

while debug log shows much more communication to Zigbee gw:

2023-12-17 17:27:50.038 DEBUG (MainThread) [homeassistant.components.zha.core.device] 0xAF8B: Device seen - marking the device available and resetting counter
2023-12-17 17:27:50.039 DEBUG (MainThread) [homeassistant.components.zha.core.device] 0xAF8B: Update device availability - device available: True - new availability: True - changed: False
2023-12-17 17:28:55.039 DEBUG (MainThread) [homeassistant.components.zha.core.device] 0xAF8B: Device seen - marking the device available and resetting counter
2023-12-17 17:28:55.039 DEBUG (MainThread) [homeassistant.components.zha.core.device] 0xAF8B: Update device availability - device available: True - new availability: True - changed: False
2023-12-17 17:30:00.040 DEBUG (MainThread) [homeassistant.components.zha.core.device] 0xAF8B: Device seen - marking the device available and resetting counter
2023-12-17 17:30:00.040 DEBUG (MainThread) [homeassistant.components.zha.core.device] 0xAF8B: Update device availability - device available: True - new availability: True - changed: False

What is the relation between two “last seen” statuses and why is “last seen” status in GUI not updated to current data?

Regards.

Izzi

I think the GUI “last seen” is the last time the device was seen by Home Assistant. The debug last seen will be the last time Zigbee saw the device - devices are constantly checking up on each other to maintain the network. It wouldn’t show up if you didn’t have have debug enabled.

1 Like

I see. I guess debug mode adds network layer of zigbee protocol communication data while GUI show only application layer.

Uh… Yeh… What he said. :confused: