Git Product home page Git Product logo

Comments (5)

 avatar commented on June 5, 2024

Here is my configuration for the fan:

fan:
  - platform: template
    fans:
      study_fan:
        friendly_name: "Study Fan"
        value_template: "{{ states('light.study_fan_state_light') }}"
        speed_template: "{{ states('input_select.study_fan_speed') }}"
        turn_on:
          service: light.turn_on
          data_template:
            entity_id: >
              {% if speed == 'High' %}
                light.study_fan_high_light
              {% elif speed == 'Medium' %}
                light.study_fan_medium_light
              {% elif speed == 'Low' %}
                light.study_fan_low_light
              {% else %}
                light.study_fan_low_light
              {% endif %}
        turn_off:
          service: script.study_fan_off
        set_speed:
          service: light.turn_on
          data_template:
            entity_id: >
              {% if speed == 'High' %}
                light.study_fan_high_light
              {% elif speed == 'Medium' %}
                light.study_fan_medium_light
              {% elif speed == 'Low' %}
                light.study_fan_low_light
              {% else %}
                light.study_fan_low_light
              {% endif %}
        speeds:
          - 'High'
          - 'Medium'
          - 'Low'

from homebridge-homeassistant.

schmittx avatar schmittx commented on June 5, 2024

What does the fan entity look like in Home Assistant? Does it show all 3 speeds and do all 3 speeds function as intended within Home Assistant?

from homebridge-homeassistant.

 avatar commented on June 5, 2024

Yes, In Home Assistant I am able to select Low, Medium and High and it functions as intended.
img_0124

from homebridge-homeassistant.

schmittx avatar schmittx commented on June 5, 2024

I haven't dug into this too much, but try inverting your speed_list definition:

speeds:
  - 'Low'
  - 'Medium'
  - 'High'

Can you also paste a screenshot of the states/attributes screen for this entity?

from homebridge-homeassistant.

 avatar commented on June 5, 2024

I tried inverting my speed list but that didn’t work. Here is a screenshot of the states/attributes:
img_0125

from homebridge-homeassistant.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.