Koenkk / Koenkk/zigbee2mqtt

[TS011F_plug_1_1 / Zbeacon] voltage_calibration has no effect

Open
#33,083 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

problem
Dominant language
TypeScript
Stars
15.7k
Forks
2k
Avg merge
18h 55m
Merged PRs (30d)
35

Description

What happened?

voltage_calibration has no effect on my Zbeacon TS011F_plug_1_1.

The plug reports approximately 254 V, while the actual mains voltage measured with another meter is approximately 235 V.

I set voltage_calibration in the device-specific settings. Zigbee2MQTT successfully accepts and stores the option:

z2m: Successfully changed config for device 0xa4c1381bfebb014b

z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/response/device/options',
payload '{"data":{"from":{"voltage_calibration":-7},"id":"0xa4c1381bfebb014b","restart_required":false,"to":{"voltage_calibration":-7.6}},"status":"ok","transaction":"5mmjt-1"}'

However, subsequent reports still contain the original, uncalibrated voltage value:

z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/rozetka2',
payload '{...,"voltage":254}'

New reports are received continuously, so the issue is not caused by waiting for the next report.

What did you expect to happen?

According to the device documentation, voltage_calibration should apply a percentual offset to the voltage value on the next report.

For example:

reported voltage: 254 V
voltage_calibration: -7
expected voltage: ~236 V

Instead, Zigbee2MQTT continues publishing 254 V.

How to reproduce it
  1. Pair a Zbeacon TS011F_plug_1_1.
  2. Observe the reported voltage.
  3. Set voltage_calibration in Settings (specific), e.g. -7.
  4. Wait for new reports.
  5. Observe the published MQTT voltage.

The option is successfully stored, but the published voltage remains unchanged.

Zigbee2MQTT version

2.14.1

Device information
  • Zigbee model: TS011F
  • Manufacturer: Zbeacon
  • Definition: TS011F_plug_1_1 (v0.0.1)
  • Description: Smart plug (with power monitoring)
  • Firmware ID / software build ID: 1.0.5
  • Firmware version: 268449287
  • App: 1.0 build 0
  • Stack: 3.6 build 7

This appears to be the same Zbeacon / firmware variant as #32463, but this issue concerns voltage_calibration not being applied rather than current scaling.

Zigbee2MQTT version

2.14.1

Adapter firmware version

Revision: 7.4.5 [GA]

Adapter

sonoff max

Setup

HA zigbeem2qtt to seral

Device database.db entry

{"id":4,"type":"Router","ieeeAddr":"0xa4c1381bfebb014b","nwkAddr":43297,"manufId":4417,"manufName":"Zbeacon","powerSource":"Mains (single phase)","modelId":"TS011F","epList":[1],"endpoints":{"1":{"profId":260,"epId":1,"devId":81,"inClusterList":[0,3,4,5,6,10,57344,1794,2820,4096,6280],"outClusterList":[25],"clusters":{"genBasic":{"attributes":{"modelId":"TS011F","manufacturerName":"Zbeacon","powerSource":1,"zclVersion":3,"appVersion":112,"stackVersion":2,"hwVersion":0,"swBuildId":"1.0.5\u0000"}},"haElectricalMeasurement":{"attributes":{"rmsVoltage":254,"acCurrentDivisor":1000,"acCurrentMultiplier":1,"acVoltageMultiplier":1,"acVoltageDivisor":1,"acPowerMultiplier":1,"acPowerDivisor":1,"activePower":128,"rmsCurrent":1027}},"seMetering":{"attributes":{"divisor":100,"multiplier":1,"currentSummDelivered":16}},"genOnOff":{"attributes":{"32768":0,"onOff":1,"tuyaBacklightMode":1,"moesStartUpOnOff":2,"onTime":0,"offWaitTime":0}}},"binds":[{"cluster":6,"type":"endpoint","deviceIeeeAddress":"0x54dce9fffee338af","endpointID":1},{"cluster":2820,"type":"endpoint","deviceIeeeAddress":"0x54dce9fffee338af","endpointID":1},{"cluster":1794,"type":"endpoint","deviceIeeeAddress":"0x54dce9fffee338af","endpointID":1}],"configuredReportings":[{"cluster":1794,"attrId":0,"minRepIntval":5,"maxRepIntval":3600,"repChange":257},{"cluster":2820,"attrId":1285,"minRepIntval":5,"maxRepIntval":3600,"repChange":5},{"cluster":2820,"attrId":1288,"minRepIntval":5,"maxRepIntval":3600,"repChange":50}],"meta":{}}},"appVersion":112,"stackVersion":2,"hwVersion":0,"swBuildId":"1.0.5\u0000","zclVersion":3,"interviewCompleted":true,"interviewState":"SUCCESSFUL","meta":{"configured":"0.0.1"},"lastSeen":1788903341292}

Debug log

No response

Notes

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the TS011F_plug_1_1 device definition and trace how the device-specific voltage_calibration option is applied to haElectricalMeasurement rmsVoltage reports. Reproduce the issue using the reported 254 V value and a -7 calibration setting. Done means subsequent MQTT voltage reports reflect the configured calibration for this Zbeacon variant.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.