Skip to content

feat: add controllable switch for AC screen display#269

Closed
OoKyleoO wants to merge 1 commit into
banto6:masterfrom
OoKyleoO:feature/screen-display-switch
Closed

feat: add controllable switch for AC screen display#269
OoKyleoO wants to merge 1 commit into
banto6:masterfrom
OoKyleoO:feature/screen-display-switch

Conversation

@OoKyleoO

Copy link
Copy Markdown

你好,本人的卡萨帝空调有屏显按钮,仓库里没有,已经测试没问题,申请pr
screenDisplayStatus is reported read-only by the digital model and only produces a binary_sensor. Generate an extra switch (data_key aliased) so the display can be toggled while keeping the sensor for state reading.

@banto6

banto6 commented Jul 13, 2026

Copy link
Copy Markdown
Owner

感谢贡献,这个功能需求本身是合理的。不过我认为目前这个实现方式不是一个合适的解决方案。

这个问题的根因是 Haier 服务器返回的设备模型不正确:实际可控制的属性被描述成了只读属性。通过新增 _ctrl switch 的方式是在集成层修复错误数据,会导致未来越来越多类似的特殊处理。

我觉得更合理的方式应该是自行本地修正对应 device JSON,或者增加一个通用的数据修正功能,让系统能够正确处理这类属性的读写能力。

Haier server sometimes reports writable attributes as read-only, so the
screen display only shows up as a read-only binary_sensor. Instead of
adding a special _ctrl entity in the integration layer, introduce a
generic ATTRIBUTE_SPEC_FIXES table applied before parsing. Corrected
attributes flow through the normal parser and yield proper controllable
entities. screenDisplayStatus is corrected to writable.
@OoKyleoO
OoKyleoO force-pushed the feature/screen-display-switch branch from 3e88db8 to 13cc630 Compare July 13, 2026 03:10
@OoKyleoO

Copy link
Copy Markdown
Author

感谢贡献,这个功能需求本身是合理的。不过我认为目前这个实现方式不是一个合适的解决方案。

这个问题的根因是 Haier 服务器返回的设备模型不正确:实际可控制的属性被描述成了只读属性。通过新增 _ctrl switch 的方式是在集成层修复错误数据,会导致未来越来越多类似的特殊处理。

我觉得更合理的方式应该是自行本地修正对应 device JSON,或者增加一个通用的数据修正功能,让系统能够正确处理这类属性的读写能力。

好的 我重新修复一版~

@OoKyleoO OoKyleoO closed this Jul 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants