home-assistant.io/source/_components/cover.opengarage.markdown
Klaas Schoute c6402dac5c Update Opengarage component configuration variable #6603 (#6668)
Update style of Opengarage component documentation to follow new configuration variables description.
Related to #6385.
2018-10-11 17:48:44 +02:00

3.3 KiB

layout title description date sidebar comments sharing footer logo ha_category ha_release
page OpenGarage Cover Instructions on how to integrate OpenGarage.io covers within Home Assistant. 2017-04-07 14:25 true false true true opengarage.png DIY 0.44

The opengarage cover platform lets you control the open-source OpenGarage.io device through Home Assistant.

{% linkable_title Configuration %}

To enable OpenGarage Covers in your installation, add the following to your configuration.yaml file:

# Example configuration.yaml entry
cover:
  platform: opengarage
  covers:
      garage:
        host:  192.168.1.12
        device_key: opendoor
        name:  Left Garage Door
      garage2:
        host:  192.168.1.13
        device_key: opendoor
        name:  Right Garage Door

{% configuration %} covers: description: List of your doors. required: true type: map keys: identifier: description: Name of the cover as slug. Multiple entries are possible. required: true type: map keys: host: description: IP address of device. required: true type: string port: description: HTTP Port. required: false default: 80 type: integer device_key: description: Access key to control device. required: true default: opendoor type: string name: description: Name to use in the Frontend. If not provided, it will use name configured in device. required: false type: string {% endconfiguration %}

Example with more detail:

# Related configuration.yaml entry
cover:
  platform: opengarage
  covers:
      garage:
        host: 192.168.1.12
        device_key: opendoor
        name: honda

sensor:
  platform: template
  sensors:
    garage_status:
      friendly_name: 'Honda Door Status'
      value_template: {% raw %}'{% if states.cover.honda %}
          {% if states.cover.honda.attributes["door_state"] == "open" %}
            Open
          {% elif states.cover.honda.attributes["door_state"] == "closed" %}
            Closed
          {% elif states.cover.honda.attributes["door_state"] == "opening" %}
            Opening
          {% elif states.cover.honda.attributes["door_state"] == "closing" %}
            Closing
          {% else %}
            Unknown
          {% endif %}
          {% else %}
          n/a
          {% endif %}'{% endraw %}
    garage_car_present:
      friendly_name: 'Honda in Garage'
      value_template: {% raw %}'{% if states.cover.honda %}
          {% if states.cover.honda.state == "open" %}
            n/a
          {% elif ((states.cover.honda.attributes["distance_sensor"] > 40) and (states.cover.honda.attributes["distance_sensor"] < 100)) %}
            Yes
          {% else %}
            No
          {% endif %}
          {% else %}
          n/a
          {% endif %}'

group:
  garage:
    name: Garage
    entities:
      - cover.honda
      - sensor.garage_status
      - sensor.garage_car_present

customize:
  cover.honda:
    friendly_name: Honda
    entity_picture: /local/honda.gif
  sensor.garage_car_present:
    icon: mdi:car

{% endraw %}