Xiaomi Temperature & Humidity Sensor Poll Time

Hi,
yes you can make new template sensor that pulls data from yours sensor and add an offset. I’m using that to “calibrate” my Xiaomi temperature sensors like this:

- platform: template
  sensors:
    xiaomi_kuhinja_1_calibrated:
      value_template: >-
        {{ (float(states.sensor.temperature_158d0001fa5de9.state) + 0.3 ) | round(1) }}
      friendly_name: 'Kuhinja'
      icon_template: mdi:thermometer
      unit_of_measurement: "°C"

This adds + 0.3 C to original readings of that sensor. You can modify this and adjust for your needs.
I hope it helps

6 Likes

when i add
force_update: true
i got configuration error

Subscribe, but I don’t think that there is a solution to this.

Could it be possible to fix the poll time using the zigbee2mqtt with the CC2531 instead of Xiaomi Gateway? https://github.com/Koenkk/zigbee2mqtt

If anybody can verify that with this method works fine and you can configure the polling time, I will try to implement it in that way as well

AFAIK the sensor is not polled by the GW. It autonomously decides when to trigger a message to the GW. You would have to hack the sensor to change its behaviour. I suspect Xiaomi went for best balance of data period vs battery life.

Isn’t it possible to ask to the sensor to be updated with the zigbee2mqtt library without hacking the sensor?
Anyway, it’s strange how the sensor update the humidity more frequently than the temperature as you can see here:

I answer to myself:

1 Like

From what I see in the xiaomi app, the temperature gets updated way more often in the app than in HA. Meaning the xiaomi gateway is filtering what is sent to HA.

So using a different gateway could be a solution to have more frequent temperature update ?

Using different gateway doesn’t fix the issue. I use deconz and currently the sensor did not send any update since 9 hours. It doesn’t matter if deconz try to get new data from it.