Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add fan_mode #27

Closed
thundergreen opened this issue May 31, 2020 · 8 comments · Fixed by #43
Closed

Add fan_mode #27

thundergreen opened this issue May 31, 2020 · 8 comments · Fixed by #43
Labels
enhancement New feature or request

Comments

@thundergreen
Copy link

Hey fella.

really nice stuff. I bought and flashed a BECO Thermostat with mqtt and added it as MQTT Climate to homeassistant. This climate component is only for dummy. It has following attributes:

hvac_modes: heat, cool, auto, fan_only, off
min_temp: 16
max_temp: 32
target_temp_step: 1
fan_modes: auto, low, medium, high
preset_modes: none, away
current_temperature: 24
temperature: 19
fan_mode: low
hvac_action: off
preset_mode: null
friendly_name: Bedroom AC Control
supported_features: 25

My "real" Climate component with which I am actually controlling my Air Conditioners has these attributes:

hvac_modes: cool, heat, dry, auto, fan_only, off
min_temp: 16
max_temp: 32
target_temp_step: 1
fan_modes: low, medium, high, auto
current_temperature: 25
temperature: 30
fan_mode: low
last_hvac_mode: heat
last_fan_mode: low
last_preset_mode: null
friendly_name: Air Conditioner Bedroom
supported_features: 9

So now when I put both in a group of you component I get this error when changing a value either on the dummy climate OR the "real" climate component:

2020-05-31 22:50:51 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 284, in async_update_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 314, in _async_write_ha_state
    attr = self.capability_attributes
  File "/usr/src/homeassistant/homeassistant/components/climate/__init__.py", line 196, in capability_attributes
    data[ATTR_FAN_MODES] = self.fan_modes
  File "/usr/src/homeassistant/homeassistant/components/climate/__init__.py", line 372, in fan_modes
    raise NotImplementedError
NotImplementedError
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 284, in async_update_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 314, in _async_write_ha_state
    attr = self.capability_attributes
  File "/usr/src/homeassistant/homeassistant/components/climate/__init__.py", line 196, in capability_attributes
    data[ATTR_FAN_MODES] = self.fan_modes
  File "/usr/src/homeassistant/homeassistant/components/climate/__init__.py", line 372, in fan_modes
    raise NotImplementedError
NotImplementedError

I guss this means that fan_mode is not implemented yet?

If you could throw an eyee on it ... would be awesome!

@daenny
Copy link
Owner

daenny commented Jun 12, 2020

I made a fix beta release. Can you test it?

@thundergreen
Copy link
Author

I'll test and revert

@thundergreen
Copy link
Author

thundergreen commented Jun 16, 2020

hvac_modes: cool, dry, heat, off, auto, fan_only min_temp: 16 max_temp: 32 preset_modes: away, none current_temperature: 23.2 temperature: 24 hvac_action: off preset_mode: null friendly_name: Bedroom supported_features: 17

apparently there's no fan_mode. WHich version do i have to take? latest should include this fix right?

@daenny
Copy link
Owner

daenny commented Jun 16, 2020

Fan Mode itself is not implemented, it's just that it should not crash anymore.

@thundergreen
Copy link
Author

Well I need fan_mode to control the fan_mode of my climate entity :(

@daenny
Copy link
Owner

daenny commented Jun 18, 2020

It should not be too difficult to add. If you need it, feel free to give it a shot. I do not have any device that supports this. Someone else already implemented "low/high" temperature setpoint, so can take that as example.

@thundergreen
Copy link
Author

any news on this? fan_mode implemented already?

@daenny
Copy link
Owner

daenny commented Aug 27, 2020

As I said above, I do not have any Fan device. Feel free to add this feature and I am happy to review and support.

@daenny daenny added the enhancement New feature or request label Jan 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants