Zigbee2mqtt unable to set temperature calibration

I’m a bit confused about the documentation regarding setting device specific configuration.
To be exact, i seem unable to set the temperature_calibration for the Xiaomi device.

The device in question: Xiaomi WSDCGQ11LM
And the documentation regarding the device specific config: Configuration | zigbee2mqtt.io

I ended up in devices.yaml as the devices and groups are split from the configuration.yaml by default.
So i did this:

'0x00158d0006ed8cc5':
  friendly_name: Woonkamer Sensor
  temperature_calibration: -1
  debounce: 0.5
  optimistic: true
  retain: true

But after a restart and blowing on it to trigger a change, It will report the higher temp from my breath and then settle back down to the original temp without the calibration applied…
Also tried just adding 1 but still the same values.

Now the documentation mentions this part:

# Optional: see 'Device specific configuration' below
device_options: {}

But either i’m overlooking this but i can find no example how to use this.

Edit: Even more confused, it seems the calibration line gets deleted after a restart
O wonderfull, it happens whenever i go and look at the device in zigbee2mqtt.

'0x00158d0006ed8cc5':
  friendly_name: Woonkamer Sensor
  debounce: 0.5
  optimistic: true
  retain: true

It works, I have such calibration. Just remember to restart zigbee2mqtt after adding the line.

I tried to add in the devices.yaml file the following line below the id of my sensor but it does not work

  temperature_calibration: -1

Who can help me ?

This is what I used :

  '0x00158d00034ce4e1':
    friendly_name: aquara1
    retain: false
    temperature_calibration: -4

(Zigbee2MQTT 1.21.2)

Thank you francisp

I tried with exactly your values in my devices.yaml file but without success

'0x00158d0005724e1e':
  friendly_name: TempBureau
  retain: false
  temperature_calibration: -4

I can see my Zigbee2MQTT is older than yours (Current version: 1.18.1-1) but it does not propose any update (I have an automatic check)
image

Then you are still using the deprecated daniel welch add-on. Switch to the official add-on :

Thank you I will do it

Thank you francisp: it works
but…

I wanted to change the “-4” in “+1” and it is not taken into account.
However I can see 5 degrees of difference between 2 values:


There is probably some memory cache somewhere…
I reboot several times without any changes…
Any idea ?

Use 1.22.0

  • #9110 Allow to manage device options in frontend

2 Likes

Merci / Thank you
it works

O, thats nice. For some reason the GUI kept deleting my calibration line in the devices.yaml