Skip to content

Light sensor is not detected on Gree Clivia #390

@fstancu

Description

@fstancu

Describe the bug

I am using the custom Gree Climate integration with a Gree Clivia air conditioner (GWH12AUCXD-K6DNA1C). Everything seems to work well, except the light sensor is never detected by the integration and therefore the light sensor switch is always shown as unavailable in Home Assistant.
Independent of the custom integration, the light sensor is properly working when activated using the AC remote control.

Also, the patch below, which skips the real detection of the light sensor, results with the light sensor switch available and properly working: on line 509 of climate.py, "if light_sensor:" is replaced with "if True:".

Enabling the debugging log for the integration produces the related log entries below:

�[36m2025-11-10 22:35:43.523 DEBUG (MainThread) [custom_components.gree.climate] Attempt to check whether device has a built-in light sensor�[0m
�[36m2025-11-10 22:35:43.524 DEBUG (MainThread) [custom_components.gree.gree_protocol] Fetching device at: 192.168.100.243:7000, data sent: {"cid":"app","i":0,"pack":
,"t":"pack","tcid":"580d0d827442","uid":0,"tag" : "Rn4v+7iLM6uCnXWFV1xaPw=="})�[0m
�[36m2025-11-10 22:35:43.539 DEBUG (MainThread) [custom_components.gree.gree_protocol] Successfully received response on attempt 1�[0m
�[36m2025-11-10 22:35:43.540 DEBUG (MainThread) [custom_components.gree.climate] Device has no built-in light sensor�[0m

To Reproduce
Steps to reproduce the behavior:

  1. Install or reload the HA integration
  2. Check the state of entity switch.gree_clivia_light_sensor
  3. State is "Unavailable"

Expected behavior
Entity switch.gree_clivia_light_sensor is available after integration installation / reload.

Platform:
Home Assistant OS
Core 2025.11.1
Supervisor 2025.11.1
Operating System 16.3
Frontend 20251105.0
Browser: Chrome 142.0.7444.134

Logs
�[36m2025-11-10 22:35:43.523 DEBUG (MainThread) [custom_components.gree.climate] Attempt to check whether device has a built-in light sensor�[0m
�[36m2025-11-10 22:35:43.524 DEBUG (MainThread) [custom_components.gree.gree_protocol] Fetching device at: 192.168.100.243:7000, data sent: {"cid":"app","i":0,"pack":
,"t":"pack","tcid":"580d0d827442","uid":0,"tag" : "Rn4v+7iLM6uCnXWFV1xaPw=="})�[0m
�[36m2025-11-10 22:35:43.539 DEBUG (MainThread) [custom_components.gree.gree_protocol] Successfully received response on attempt 1�[0m
�[36m2025-11-10 22:35:43.540 DEBUG (MainThread) [custom_components.gree.climate] Device has no built-in light sensor�[0m

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions