Add Tuya ZS-300TF / ZS-301 soil fertility sensor quirk - #5276
Open
zichul wants to merge 1 commit into
Open
Conversation
Add support for the Excellux ZS-300TF (sold as ZS-301) Tuya TS0601 soil fertility sensor, matched on both the clean (_TZE284_hdml1aav) and the corrupted (_TZE2841000000_hdml1aav) manufacturer ID. Exposes soil moisture (DP 3), temperature (DP 5, /10), humidity (DP 101), illuminance (DP 102, raw lux), electrical conductivity / soil fertility (DP 112) and battery (DP 15). Datapoint map sourced from the Zigbee2MQTT converter for the same device (zigbee-herdsman-converters, model ZS-300TF, vendor Excellux).
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## dev #5276 +/- ##
=======================================
Coverage 92.60% 92.60%
=======================================
Files 424 424
Lines 14667 14668 +1
=======================================
+ Hits 13582 13583 +1
Misses 1085 1085 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a quirk for the Excellux ZS-300TF Tuya TS0601 soil fertility sensor (commonly sold as the ZS-301). The device pairs with ZHA but exposes no entities without a quirk, because its datapoints are only mapped by a Zigbee2MQTT converter, not by zha-quirks.
The device reports a corrupted manufacturer ID (
_TZE2841000000_hdml1aav), so the quirk matches both the clean (_TZE284_hdml1aav) and corrupted form, following the same pattern already used for the Giex GX04.Exposed entities
Notes
zigbee-herdsman-converters, modelZS-300TF, vendorExcellux), seetuya.tsfingerprint["_TZE284_hdml1aav", "_TZE2841000000_hdml1aav"].lambda x: x) converter rather than thetuya_illuminancelog10 default, because this device reports actual lux (matching the Z2Mtuya.valueConverter.rawconverter for DP 102).Verification
Tested on Home Assistant Yellow (Core 2026.8.x, ZHA). After enabling the quirk and reconfiguring the device, the data-query spell produced real values on cluster 0xEF00:
pytest tests/test_tuya_sensor.py tests/test_quirks_v2.py tests/test_quirks_v2_builder.pypasses (81 tests), andruff check/ruff format --checkare clean.Refs: zigbee2mqtt#32196, home-assistant discussion #2172.