bigmoby / fglair_for_homeassistant

❄️ FGLair heat pump controller integration
MIT License
51 stars 4 forks source link

Missing 'Fan Mode' - "Quiet" or "Diffuse" #201

Closed Adunite85 closed 1 week ago

Adunite85 commented 2 weeks ago

Checklist

Is your feature request related to a problem? Please describe.

Dear Contributors, Thank you for making this integration an official one!

Current implementation only offers fan modes of "Low", "Medium", "High" and "Auto", but missing one setting that's slower than "Low" that is available in the official app named as "Quiet", and in the previous community made integration as "Diffuse" Screenshot_20241112_174050_FGLair

When set through the app, it shows up as blank on the card, and as an exception if the function is being called via a script. image

Describe the solution you'd like

Please consider reviewing the code to include this setting. Controller is an AP-WF2E module embedded in a ASYG12KPCA.

Describe alternatives you've considered

N/A

Additional context

N/A

fdcastel commented 2 weeks ago

Same here.

Wife complaining... Please send help! 😄😄😄

bigmoby commented 1 week ago

Thank you for making this integration an official one!

Hi @Adunite85 This is not the official Fglair integration, anyway I'll try to analyze how this feature could be implemented. 👍 Regards, Fabio

Adunite85 commented 1 week ago

Thanks Fabio! Please let me know if you need any help with testing, or additional information! BR, Greg

bigmoby commented 1 week ago

Hi @Adunite85 and @fdcastel please could you tell me the version number of the fglair component you have installed?

The quiet or diffuse mode is already implemented for a long time.

    def get_fan_speed_desc(self) -> str:
        """Get the description of the fan speed.

        The supported fan speeds vary from device to device. The available modes are
        read from the Device capability attributes.

        """
        FAN_SPEED_DICT = {0: "Quiet", 1: "Low", 2: "Medium", 3: "High", 4: "Auto"}

        fan_speed = self.get_fan_speed()["value"]
        if fan_speed == 5:
            """For very few AC the resulting value is 5 BUT this value "5" is a not documented value,
            I assume it as the Low value according:
            https://github.com/deiger/AirCon/blob/master/devicetypes/deiger/hisense-air-conditioner.src/hisense-air-conditioner.groovy#L198
            """
            return FAN_SPEED_DICT[1]

        if fan_speed == 7:
            """For very few AC the resulting value is 7 BUT this value "7" is a not documented value,
            I assume it as the High value according:
            https://github.com/deiger/AirCon/blob/master/devicetypes/deiger/hisense-air-conditioner.src/hisense-air-conditioner.groovy#L204
            """
            return FAN_SPEED_DICT[3]

        if fan_speed == 9:
            """For very few AC the resulting value is 9 BUT this value "9" is a not documented value,
            I assume it as the Auto value according:
            https://github.com/deiger/AirCon/blob/master/devicetypes/deiger/hisense-air-conditioner.src/hisense-air-conditioner.groovy#L210
            """
            return FAN_SPEED_DICT[4]

        return FAN_SPEED_DICT[fan_speed]
fdcastel commented 1 week ago

Er... @bigmoby where could I check this? 😅

The integration page (/config/integrations/integration/fujitsu_fglair) doesn't show anything: image

I played with the debug logging (*) for a while but it also doesn't record any version number.

My Home Assistant "about" page says:

Core: 2024.11.1 Frontend: 20241106.2

bigmoby commented 1 week ago

Oooops 😅 I have a "very slight suspicion" that you are using the official home assistant integration! this is my custom integration! ...which I think works much better than the official one, but this is just my humble opinion! 😉

fdcastel commented 6 days ago

Sorry @bigmoby. I'm not sure how I managed to confuse both projects 😞

Thank you for your attention. I would like to try your version but my attempts to use HACS in the past were... less than ideal.

Adunite85 commented 6 days ago

Sorry, and thank you! We both got it confused; I was following a link from under a discussion on the community forums about the "official" integration. It works like a charm, and has all features I was missing. image I wonder if there's a way or possibility to make your integration more visible.

bigmoby commented 6 days ago

No problem at all, @fdcastel @Adunite85 ! 🙌 Please star this project if it's useful for you ⭐️