diff --git a/_config.yml b/_config.yml index 594037c04d4..6275152702f 100644 --- a/_config.yml +++ b/_config.yml @@ -79,6 +79,8 @@ collections: output: true cookbook: output: true + topics: + output: true # ----------------------- # # 3rd Party Settings # diff --git a/source/_components/alexa.markdown b/source/_components/alexa.markdown index 9922762b632..0cfeb9a1153 100644 --- a/source/_components/alexa.markdown +++ b/source/_components/alexa.markdown @@ -80,7 +80,7 @@ Out of the box, the component will do nothing. You have to teach it about all in You can use [templates] for the values of `speech/text`, `card/title` and `card/content`. -[templates]: /getting-started/templating/ +[templates]: /topics/templating/ Configuring the Alexa component for the above intents would look like this: diff --git a/source/_components/automation.markdown b/source/_components/automation.markdown index 1153e146c0e..6d592a7307c 100644 --- a/source/_components/automation.markdown +++ b/source/_components/automation.markdown @@ -209,7 +209,7 @@ automation: Conditions are an optional part of an automation rule and be used to prevent an action from happening when triggered. Conditions look very familiar to triggers but are very different. A trigger will look at events happening at the system while a condition only looks at how the system looks right now. A trigger can observe that a switch is being turned on. A condition can only see if a switch is on or off. -An automation rule can have mulitiple triggers. By default the action will only fire if all conditions pass. An optional key `condition_type: 'or'` can be set on the automation rule to fire action if any condition matches. In the example below, the automation would trigger if the time is before 05:00 _OR_ after 20:00. +An automation rule can have mulitiple conditions. By default the action will only fire if all conditions pass. An optional key `condition_type: 'or'` can be set on the automation rule to fire action if any condition matches. In the example below, the automation would trigger if the time is before 05:00 _OR_ after 20:00. ```yaml automation: @@ -363,4 +363,4 @@ The Logbook component will show a line entry when an automation is triggered. Y  -[template]: /getting-started/templating/ +[template]: /topics/templating/ diff --git a/source/_components/binary_sensor.command_line.markdown b/source/_components/binary_sensor.command_line.markdown index c34be637491..f00c788d28b 100644 --- a/source/_components/binary_sensor.command_line.markdown +++ b/source/_components/binary_sensor.command_line.markdown @@ -33,7 +33,7 @@ Configuration variables: - **name** (*Optional*): Let you overwrite the the name of the device. By default *name* from the device is used. - **payload_on** (*Optional*): The payload that represents enabled state. Default is "ON". - **payload_off** (*Optional*): The payload that represents disabled state. Default is "OFF". -- **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract a value from the payload. +- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload. ## {% linkable_title Examples %} diff --git a/source/_components/binary_sensor.mqtt.markdown b/source/_components/binary_sensor.mqtt.markdown index 43a3ab06a58..ddb23f9df2e 100644 --- a/source/_components/binary_sensor.mqtt.markdown +++ b/source/_components/binary_sensor.mqtt.markdown @@ -25,6 +25,7 @@ binary_sensor: qos: 0 payload_on: "ON" payload_off: "OFF" + sensor_class: opening value_template: '{% raw %}{{ value.x }}{% endraw %}' ``` @@ -35,7 +36,8 @@ Configuration variables: - **qos** (*Optional*): The maximum QoS level of the state topic. Default is 0. - **payload_on** (*Optional*): The payload that represents on state. Default is "ON". - **payload_off** (*Optional*): The payload that represents state. Default is "OFF". -- **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract a value from the payload. +- **sensor_class** (*Optional*): The [type/class](/components/binary_sensor/) of the sensor to set the icon in the frontend. +- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload. For a quick check you can use the commandline tools shipped with `mosquitto` to send MQTT messages. Set the state of your sensor manually: diff --git a/source/_components/binary_sensor.rest.markdown b/source/_components/binary_sensor.rest.markdown index c9075bbf8cb..e1fac78ddce 100644 --- a/source/_components/binary_sensor.rest.markdown +++ b/source/_components/binary_sensor.rest.markdown @@ -42,7 +42,7 @@ Configuration variables: - **resource** (*Required*): The resource or endpoint that contains the value. - **method** (*Optional*): The method of the request. Default is GET. -- **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract the value. +- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract the value. - **payload** (*Optional*): The payload to send with a POST request. Usualy formed as a dictionary. - **name** (*Optional*): Name of the REST binary sensor. diff --git a/source/_components/binary_sensor.tcp.markdown b/source/_components/binary_sensor.tcp.markdown index d7551c044ac..e328ffb034f 100644 --- a/source/_components/binary_sensor.tcp.markdown +++ b/source/_components/binary_sensor.tcp.markdown @@ -37,7 +37,7 @@ Configuration options for the a TCP Sensor: - **payload** (*Required*): What to send to the host in order to get the response we're interested in. - **value_on** (*Required*): The value returned when the device is "on". - **timeout** (*Optional*): How long in seconds to wait for a response from the service before giving up and disconnecting. Defaults to 10. -- **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract the value. By default it's assumed that the entire response is the value. +- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract the value. By default it's assumed that the entire response is the value. - **unit** (*Optional*): The unit of measurement to use for the value. - **buffer_size** (*Optional*): The size of the receive buffer in bytes. Set this to a larger value if you expect to receive a response larger than the default. Defaults to 1024. diff --git a/source/_components/binary_sensor.template.markdown b/source/_components/binary_sensor.template.markdown index 15477408f00..f325ba4de4d 100644 --- a/source/_components/binary_sensor.template.markdown +++ b/source/_components/binary_sensor.template.markdown @@ -29,7 +29,7 @@ Configuration variables: - **sensors** array (*Required*): List of your sensors. - **friendly_name** (*Optional*): Name to use in the Frontend. - **sensor_class** (*Optional*): Defines the class of the sensor (motion, heat, moisture, etc) - - **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract a value from the payload. + - **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload. ## {% linkable_title Examples %} diff --git a/source/_components/browser.markdown b/source/_components/browser.markdown index 9c5d2385a82..36bb6176789 100644 --- a/source/_components/browser.markdown +++ b/source/_components/browser.markdown @@ -12,7 +12,7 @@ ha_category: Other --- -The browser component provides a service to open urls in the default browser on the host machine. +The `browser` component provides a service to open URLs in the default browser on the host machine. To load this component, add the following lines to your `configuration.yaml`: @@ -21,8 +21,19 @@ To load this component, add the following lines to your `configuration.yaml`: browser: ``` -#### Service `browser/browse_url` +#### {% linkable_title Service `browser/browse_url` %} | Service data attribute | Optional | Description | | ---------------------- | -------- | ----------- | | `url` | no | The url to open + + +### {% linkable_title Usage %} + +To use this service, choose **Call Service** from the **Developer Tools**. Choose the service *browser/browse_url* from the list of **Available services:** and enter the URL into the **Service Data** field and hit **CALL SERVICE**. + +```json +{"url": "http://www.google.com"} +``` + +This will open the given URL on the host machine. diff --git a/source/_components/camera.foscam.markdown b/source/_components/camera.foscam.markdown index 906fb622a1b..40e8924069b 100644 --- a/source/_components/camera.foscam.markdown +++ b/source/_components/camera.foscam.markdown @@ -20,7 +20,7 @@ To enable your Foscam IP camera in your installation, add the following to your # Example configuration.yaml entry camera: platform: foscam - ip: 192.168.0.123 + ip: IP_ADDRESS name: Door Camera port: 88 username: USERNAME @@ -29,12 +29,15 @@ camera: Configuration variables: -- **ip** *Required*: The IP address your camera. -- **port** *Optional*: The port that the camera is running on. The default is 88. -- **name** *Optional*: This parameter allows you to override the name of your camera. -- **username** *Required*: The username for accessing your camera. -- **password** *Required*: The password for accessing your camera. - - **Note**: There seems to be some issues within Foscam with lengthy passwords and passwords containing certain symbols. Be sure to check your camera's documentation. +- **ip** (*Required*): The IP address your camera. +- **port** (*Optional*): The port that the camera is running on. The default is 88. +- **name** (*Optional*): This parameter allows you to override the name of your camera. +- **username** (*Required*): The username for accessing your camera. +- **password** (*Required*): The password for accessing your camera. + +
+There seems to be some issues within Foscam with lengthy passwords and passwords containing certain symbols. Be sure to check your camera's documentation. +
### {% linkable_title Control Foscam PTZ (Pan/Tilt/Zoom) - Home/Away %} Foscam Webcams which support CGI Commands can be controlled by Home Assistant ([Source](http://www.ipcamcontrol.net/files/Foscam%20IPCamera%20CGI%20User%20Guide-V1.0.4.pdf)). For an example of how this can be done, see the [Foscam IP Camera Pan, Tilt, Zoom Control](/cookbook/foscam_away_mode_PTZ/) Cookbook entry. diff --git a/source/_components/device_tracker.nmap_scanner.markdown b/source/_components/device_tracker.nmap_scanner.markdown index e2fad493eaa..de2989900e2 100644 --- a/source/_components/device_tracker.nmap_scanner.markdown +++ b/source/_components/device_tracker.nmap_scanner.markdown @@ -27,6 +27,9 @@ device_tracker: home_interval: 10 ``` -`home_interval` is an optional value set in minutes. This will be the number of minutes nmap will not scan this device, assuming it is home, in order to preserve the device battery. +Configuration variables: + +- **hosts** (*Required*): Thenetwork range to scan in CIDR notation, eg. 192.168.1.1/24 +- **home_interval** (*Optional*): The number of minutes nmap will not scan this device, assuming it is home, in order to preserve the device battery. See the [device tracker component page](/components/device_tracker/) for instructions how to configure the people to be tracked. diff --git a/source/_components/device_tracker.snmp.markdown b/source/_components/device_tracker.snmp.markdown index b61e1f8fad8..9f23170c6e1 100644 --- a/source/_components/device_tracker.snmp.markdown +++ b/source/_components/device_tracker.snmp.markdown @@ -23,6 +23,8 @@ OID examples: - Mikrotik: 1.3.6.1.2.1.4.22.1.2 (confirmed, RouterOS 6.x on RB2011) - Aruba: 1.3.6.1.4.1.14823.2.3.3.1.2.4.1.2 (untested) - BiPAC 7800DXL: 1.3.6.1.2.1.17.7.1.2.2.1.1 (confirmed on firmware 2.32e) +- OpenWrt: 1.3.6.1.2.1.4.22.1.2 (tested on Chaos Calmer 15.05 firmware, need to install snmpd package) +- pfSense: 1.3.6.1.2.1.4.22.1.2 (tested on 2.2.4-RELEASE, need to enable SNMP service) To use the snmp platform in your installation, add the following to your `configuration.yaml` file: diff --git a/source/_components/discovery.markdown b/source/_components/discovery.markdown index 8633fba2c2e..a15d2944401 100644 --- a/source/_components/discovery.markdown +++ b/source/_components/discovery.markdown @@ -37,5 +37,9 @@ If running home-assistant in a docker container use switch `--net=host` to put i If you are developing a new platform, please read [how to make your platform discoverable]({{site_root}}/developers/add_new_platform/#discovery).-There is currently a known issue with running this playform on a 64-bit version of Python. +There is currently a known issue with running this platform on a 64-bit version of Python. +
+ ++If you are on Windows and you're using Python 3.5, download the Netifaces dependency here.
diff --git a/source/_components/group.markdown b/source/_components/group.markdown index 902596f3471..3eb481b314f 100644 --- a/source/_components/group.markdown +++ b/source/_components/group.markdown @@ -15,10 +15,11 @@ Groups allow the user to combine multiple entities into one. A group can be prom Check the **Set State** page from the **Developer Tools** and browse the **Current entities:** listing for all available entities. +By default, every group appears in the HOME tab. If you name a group `default_view` it will REPLACE the contents of the HOME tab so you can customize it as you wish. + ```yaml # Example configuration.yaml entry group: - # If you name an entry default_view it will REPLACE the contents of the "Home" tab default_view: view: yes entities: @@ -42,24 +43,32 @@ group: Configuration variables: +- **view** (*Optional*): If yes then the entry will be shown as a view (tab). - **name** (*Optional*): Name of the group. -- **icon** (*Optional*): An optional icon to show in the Frontend. -- **view** (*Optional*): If yes then the entry will be shown as a view. -- **entities** array or comma delimited string (*Required*): List of entites to group. +- **icon** (*Optional*): If the group is a view, this icon will show at the top in the frontend instead of the name. If it's not a view, then the icon shows when this group is used in another group. +- **entities** (*Required*): array or comma delimited string, list of entities to group.
Example of groups shown as views in the frontend.
Make sure that your topic match exact. `some-topic/` and `some-topic` are different topics. diff --git a/source/_components/mqtt.markdown b/source/_components/mqtt.markdown index de4a8c04912..44bf80f8ba2 100644 --- a/source/_components/mqtt.markdown +++ b/source/_components/mqtt.markdown @@ -125,18 +125,21 @@ Home Assistant will automatically load the correct certificate if you connect to ## {% linkable_title Building on top of MQTT %} + - [MQTT Alarm control panel](/components/alarm_control_panel.mqtt/) + - [MQTT Binary sensor](/components/binary_sensor.mqtt/) - [MQTT Sensor](/components/sensor.mqtt/) - [MQTT Switch](/components/switch.mqtt/) - [MQTT Light](/components/light.mqtt/) + - [MQTT Lock](/components/lock.mqtt/) - [MQTT Device Tracker](/components/device_tracker.mqtt/) - [OwnTracks Device Tracker](/components/device_tracker.owntracks/) - [MQTT automation rule](/components/automation/#mqtt-based-automation) - - [MQTT alarm](/components/alarm_control_panel.mqtt/) + - Integrating it into own component. See the [MQTT example component](/cookbook/python_component_mqtt_basic/) how to do this. ### {% linkable_title Publish service %} -The MQTT component will register the service `publish` which allows publishing messages to MQTT topics. There are two ways of specifiying your payload. You can either use `payload` to hard-code a payload or use `payload_template` to specify a [template](/getting-started/templating/) that will be rendered to generate the payload. +The MQTT component will register the service `publish` which allows publishing messages to MQTT topics. There are two ways of specifiying your payload. You can either use `payload` to hard-code a payload or use `payload_template` to specify a [template](/topics/templating/) that will be rendered to generate the payload. ```json { diff --git a/source/_components/notify.google_voice.markdown b/source/_components/notify.google_voice.markdown index 83676fd3923..aa1a6901e3b 100644 --- a/source/_components/notify.google_voice.markdown +++ b/source/_components/notify.google_voice.markdown @@ -28,7 +28,7 @@ notify: Configuration variables: - **username** (*Required*): Enter your the Google email address you have signed up for Google Voice with. Go to https://www.google.com/voice to setup your Google Voice account. -- **password** (*Required*): Enter the password associated with the above email. Go to https://www.pushbullet.com/ to retrieve your API key. +- **password** (*Required*): Enter the password associated with the above email. - **name** (*Optional*): Setting the optional parameter `name` allows multiple notifiers to be created. The default value is `notify`. The notifier will bind to the service `notify.NOTIFIER_NAME`. ### Usage diff --git a/source/_components/notify.markdown b/source/_components/notify.markdown index f6d4f7b5350..d475db0cb2c 100644 --- a/source/_components/notify.markdown +++ b/source/_components/notify.markdown @@ -37,7 +37,7 @@ Once loaded, the `notify` platform will expose a service that can be called to s The notification component supports specifying [templates] for both the `message` and the `title`. This will allow you to use the current state of Home Assistant in your notifications. -[templates]: /getting-started/templating/ +[templates]: /topics/templating/ ### {% linkable_title Test if it works %} diff --git a/source/_components/rollershutter.mqtt.markdown b/source/_components/rollershutter.mqtt.markdown index b9cbb7d925e..51a840c3a91 100644 --- a/source/_components/rollershutter.mqtt.markdown +++ b/source/_components/rollershutter.mqtt.markdown @@ -42,4 +42,4 @@ Configuration variables: - **payload_up** (*Optional*): The payload to open the rollershutter. Default is "OPEN". - **payload_down** (*Optional*): The payload to close the rollershutter. Default is "CLOSE". - **payload_stop** (*Optional*): The payload to stop the rollershutter. Default is "STOP". -- **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract a value from the payload. +- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload. diff --git a/source/_components/scene.hunterdouglas_powerview.markdown b/source/_components/scene.hunterdouglas_powerview.markdown index 72fb3e46702..d35c4e49ec0 100644 --- a/source/_components/scene.hunterdouglas_powerview.markdown +++ b/source/_components/scene.hunterdouglas_powerview.markdown @@ -8,7 +8,7 @@ comments: false sharing: true footer: true logo: hunter-douglas-powerview.png -ha_category: Organization +ha_category: Rollershutter --- Implements the [Hunter Douglas PowerView](http://www.hunterdouglas.com/operating-systems/powerview-motorization/support) platform scene control. It queries the PowerView Hub and Home Assistant displays them as scenes. @@ -24,4 +24,4 @@ scene: Configuration variables: -- **address** (*Required*): IP address of the PowerView Hub, eg. http://192.168.1.10. +- **address** (*Required*): IP address of the PowerView Hub, eg. 192.168.1.10. diff --git a/source/_components/scene.home_assistant.markdown b/source/_components/scene.markdown similarity index 100% rename from source/_components/scene.home_assistant.markdown rename to source/_components/scene.markdown diff --git a/source/_components/sensor.arest.markdown b/source/_components/sensor.arest.markdown index 08282b75107..40926089f5f 100644 --- a/source/_components/sensor.arest.markdown +++ b/source/_components/sensor.arest.markdown @@ -45,11 +45,11 @@ Configuration variables: - **monitored_variables** array (*Optional*): List of exposed variables. - **name** (*Required*): The name of the variable you wish to monitor. - **unit** (*Optional*): Defines the units of measurement of the sensor, if any. - - **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract a value from the payload. + - **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload. - **pins** array (*Optional*): List of pins to monitor. Analog pins need a leading **A** for the pin number. - **name** (*Optional*): The name of the variable you wish to monitor. - **unit_of_measurement** (*Optional*): Defines the unit of measurement of the sensor, if any. - - **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract a value from the payload. + - **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload. The variables in the `monitored_variables` array must be available in the response of the device. As a starting point you could use the one of the example sketches (eg. [Ethernet](https://raw.githubusercontent.com/marcoschwartz/aREST/master/examples/Ethernet/Ethernet.ino) for an Arduino with Ethernet shield). In those sketches are two variables (`temperature` and `humidity`) available which will act as endpoints. diff --git a/source/_components/sensor.command_line.markdown b/source/_components/sensor.command_line.markdown index 09f655f7b9e..0e26cae696f 100644 --- a/source/_components/sensor.command_line.markdown +++ b/source/_components/sensor.command_line.markdown @@ -31,7 +31,7 @@ Configuration variables: - **command** (*Required*): The action to take to get the value. - **name** (*Optional*): Name of the command sensor. - **unit_of_measurement** (*Optional*): Defines the unit of measurement of the sensor, if any. -- **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract a value from the payload. +- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload. ## {% linkable_title Examples %} diff --git a/source/_components/sensor.mqtt.markdown b/source/_components/sensor.mqtt.markdown index 770ff862e15..7d55875f3f3 100644 --- a/source/_components/sensor.mqtt.markdown +++ b/source/_components/sensor.mqtt.markdown @@ -33,7 +33,7 @@ Configuration variables: - **name** (*Optional*): The name of the sensor. Default is 'MQTT Sensor'. - **qos** (*Optional*): The maximum QoS level of the state topic. Default is 0. - **unit_of_measurement** (*Optional*): Defines the units of measurement of the sensor, if any. -- **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract a value from the payload. +- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload. ## {% linkable_title Examples %} diff --git a/source/_components/sensor.rest.markdown b/source/_components/sensor.rest.markdown index c75a216dac7..5e55cdda28d 100644 --- a/source/_components/sensor.rest.markdown +++ b/source/_components/sensor.rest.markdown @@ -44,7 +44,7 @@ Configuration variables: - **resource** (*Required*): The resource or endpoint that contains the value. - **method** (*Optional*): The method of the request. Default is GET. -- **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract the value. +- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract the value. - **payload** (*Optional*): The payload to send with a POST request. Usualy formed as a dictionary. - **name** (*Optional*): Name of the REST sensor. - **unit_of_measurement** (*Optional*): Defines the unit of measurement of the sensor, if any. diff --git a/source/_components/sensor.speedtest.markdown b/source/_components/sensor.speedtest.markdown index db0fc4ddd87..a2d22c2b205 100644 --- a/source/_components/sensor.speedtest.markdown +++ b/source/_components/sensor.speedtest.markdown @@ -72,4 +72,4 @@ Configuration variables: - **hour** (*Optional*): Specify the hour(s) of the day to schedule the speedtest. Use a list for multiple entries. Default is None. - **day** (*Optional*): Specify the day(s) of the month to schedule the speedtest. Use a list for multiple entries. Default is None. -This component uses [speetest-cli](https://github.com/sivel/speedtest-cli) to gather network performance data from Speedtest.net. Please be aware of the potential [inconsistencies](https://github.com/sivel/speedtest-cli#inconsistency) that this component may display. +This component uses [speedtest-cli](https://github.com/sivel/speedtest-cli) to gather network performance data from Speedtest.net. Please be aware of the potential [inconsistencies](https://github.com/sivel/speedtest-cli#inconsistency) that this component may display. diff --git a/source/_components/sensor.tcp.markdown b/source/_components/sensor.tcp.markdown index b796c5e3b65..a6227a641bf 100644 --- a/source/_components/sensor.tcp.markdown +++ b/source/_components/sensor.tcp.markdown @@ -34,7 +34,7 @@ Configuration options for the a TCP Sensor: - **port** (*Required*): The port to connect to the host on. - **payload** (*Required*): What to send to the host in order to get the response we're interested in. - **timeout** (*Optional*): How long in seconds to wait for a response from the service before giving up and disconnecting. Defaults to `10` -- **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract the value. By default it's assumed that the entire response is the value. +- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract the value. By default it's assumed that the entire response is the value. - **unit** (*Optional*): The unit of measurement to use for the value. - **buffer_size** (*Optional*): The size of the receive buffer in bytes. Set this to a larger value if you expect to receive a response larger than the default. Defaults to `1024`. diff --git a/source/_components/sensor.template.markdown b/source/_components/sensor.template.markdown index da6ec606d69..a792cb1cdae 100644 --- a/source/_components/sensor.template.markdown +++ b/source/_components/sensor.template.markdown @@ -32,7 +32,7 @@ Configuration variables: - **sensors** array (*Required*): List of your sensors. - **friendly_name** (*Optional*): Name to use in the Frontend. - **unit_of_measurement** (*Optional*): Defines the units of measurement of the sensor, if any. - - **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract a value from the payload. + - **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload. ## {% linkable_title Examples %} diff --git a/source/_components/switch.mqtt.markdown b/source/_components/switch.mqtt.markdown index cdd0b023c2a..746b0b26da1 100644 --- a/source/_components/switch.mqtt.markdown +++ b/source/_components/switch.mqtt.markdown @@ -46,7 +46,7 @@ Configuration variables: - **optimistic** (*Optional*): Flag that defines if switch works in optimistic mode. Default is true if no state topic defined, else false. - **qos** (*Optional*): The maximum QoS level of the state topic. Default is 0 and will also be used to publishing messages. - **retain** (*Optional*): If the published message should have the retain flag on or not. -- **value_template** (*Optional*): Defines a [template](/getting-started/templating/) to extract a value from the payload. +- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload.
Make sure that your topic match exact. `some-topic/` and `some-topic` are different topics. diff --git a/source/_components/switch.template.markdown b/source/_components/switch.template.markdown index ab789f34b9e..2f5f627ec29 100644 --- a/source/_components/switch.template.markdown +++ b/source/_components/switch.template.markdown @@ -38,7 +38,7 @@ Configuration variables: - **switches** array (*Required*): List of your switches. - **friendly_name** (*Optional*): Name to use in the Frontend. - - **value_template** (*Required*): Defines a [template](/getting-started/templating/) to set the state of the switch. + - **value_template** (*Required*): Defines a [template](/topics/templating/) to set the state of the switch. - **turn_on** (*Required*): Defines an [action](/getting-started/automation/) to run when the switch is turned on. - **turn_off** (*Required*): Defines an [action](/getting-started/automation/) to run when the switch is turned off. diff --git a/source/_components/tellstick.markdown b/source/_components/tellstick.markdown index 13124b11046..edca85a85b2 100644 --- a/source/_components/tellstick.markdown +++ b/source/_components/tellstick.markdown @@ -12,7 +12,7 @@ ha_category: Hub --- -The `tellstick` component integrates [TellStick](http://www.telldus.se/products/tellstick) devices into Home Assistant. This integration allows users to add switches, lights, and sensors which are communicating with 433 Mhz. There are couple of vendors (Capidi Elro, Intertechno, Nexa, Proove, Sartano, and Viking) how are selling products which works with TellStick. For more details, please check the TellStick [compatibility list](http://telldus.se/products/compability). +The `tellstick` component integrates [TellStick](http://www.telldus.se/products/tellstick) devices into Home Assistant. This integration allows users to add switches, lights, and sensors which are communicating with 433 Mhz. There are a number of vendors (Capidi Elro, Intertechno, Nexa, Proove, Sartano, and Viking) who are selling products that work with TellStick. For more details, please check the TellStick [compatibility list](http://telldus.se/products/compability). To get started, add the devices to your `configuration.yaml` file. diff --git a/source/_components/zwave.markdown b/source/_components/zwave.markdown index 554c8c8c573..d4d33d4d3cd 100644 --- a/source/_components/zwave.markdown +++ b/source/_components/zwave.markdown @@ -22,7 +22,13 @@ To allow Home Assistant to talk to your Z-Wave USB stick you will have to compil Make sure you have the correct dependencies installed before running the script: ```bash -$ apt-get install cython3 libudev-dev python3-sphinx python3-setuptools +$ sudo apt-get install cython3 libudev-dev python3-sphinx python3-setuptools +``` + +Make sure you have at least version 0.23 of cython. + +```bash +$ sudo pip3 install --upgrade cython ``` Then get the OpenZWave files and switch to the `python3` branch: @@ -37,7 +43,7 @@ $ sudo PYTHON_EXEC=`which python3` make install
Instead of `make install`, you can alternatively build your own python-openzwave package which can be easily uninstalled: -`$ sudo PYTHON_EXEC=`which python3` checkinstall --pkgname python-openzwave --pkgversion 1.0 --provides python-openzwave` +```$ sudo PYTHON_EXEC=`which python3` checkinstall --pkgname python-openzwave --pkgversion 1.0 --provides python-openzwave```
diff --git a/source/_cookbook/configuration_yaml_by_brusc.markdown b/source/_cookbook/configuration_yaml_by_brusc.markdown new file mode 100644 index 00000000000..762bf536e65 --- /dev/null +++ b/source/_cookbook/configuration_yaml_by_brusc.markdown @@ -0,0 +1,13 @@ +--- +layout: page +title: "Configuration.yaml by brusc" +description: "" +date: 2016-03-14 11:45 +sidebar: true +comments: false +sharing: true +footer: true +ha_category: Example configuration.yaml +ha_external_link: https://github.com/brusc/Home-Assistant-Configuration +--- + diff --git a/source/_cookbook/configuration_yaml_from_bassclarinetl2 b/source/_cookbook/configuration_yaml_from_bassclarinetl2 new file mode 100644 index 00000000000..91af768b15e --- /dev/null +++ b/source/_cookbook/configuration_yaml_from_bassclarinetl2 @@ -0,0 +1,446 @@ +homeassistant: + # Name of the location where Home Assistant is running + name: example.com + # Location required to calculate the time the sun rises and sets + latitude: 37 + longitude: -121 + # C for Celcius, F for Fahrenheit + temperature_unit: F + # Pick yours from here: http://en.wikipedia.org/wiki/List_of_tz_database_time_zones + time_zone: America/Los_Angeles + customize: + switch.aeon_labs_smart_energy_switch_switch_2: + friendly_name: Mac Switch-Meter + switch.leviton_unknown_type1a02_id0334_switch_3: + friendly_name: W Nightstand + entity_picture: /local/zwvapl.jpg + switch.hub_switch: + friendly_name: Wink Hub Switch + entity_picture: /local/wemoswitch.jpg + switch.leviton_unknown_type1a02_id0334_switch_4: + friendly_name: Christmas Tree + entity_picture: /local/zwvapl.jpg + switch.leviton_unknown_type1a02_id0334_switch_5: + friendly_name: Roof Lights + entity_picture: /local/zwvapl.jpg + + light.w_bedroom_ceiling_: + friendly_name: Will's Bedroom Ceiling Lights (Wink) + entity_picture: /local/casetta.jpg + light.living_room_wall_: + friendly_name: Living Room Couch Lights (Wink) + entity_picture: /local/casetta.jpg + + media_player.my_shield_android_tv: + friendly_name: Dalek (Cast) + entity_picture: /local/shieldtv.jpg + media_player.chromecast: + friendly_name: Jeff chromecast + entity_picture: /local/chromecast.jpg + media_player.kodi: + friendly_name: Tardis-Win7 (Kodi) + entity_picture: /local/kodi.png + media_player.kodi_2: + friendly_name: Dalek (Kodi) + media_player.roku_2_xd__12a18n045363: + friendly_name: Parents Roku + entity_picture: /local/roku2xd.jpg + + sensor.aeon_labs_smart_energy_switch_power_2: + friendly_name: Mac Usage (W) + sensor.aeon_labs_smart_energy_switch_previous_reading_2: + friendly_name: Mac Usage Previous (W) + hidden: true + sensor.aeon_labs_smart_energy_switch_energy_2: + friendly_name: Mac Usage (kWh) + hidden: true + +##################### +## GROUPS +##################### +group: + w_bedroom: + - switch.leviton_unknown_type1a02_id0334_switch_3 + - light.w_bedroom_ceiling_ + christmas: + - switch.leviton_unknown_type1a02_id0334_switch_4 + - switch.leviton_unknown_type1a02_id0334_switch_5 + almanac: + - sensor.date + - sensor.time + - sensor.time_utc + - sun.sun + tracker: + - device_tracker.will_wnexus +# OpenWeatherMap: +# - sensor.weather_temperature +# - sensor.weather_humidity +# - sensor.weather_pressure +# - sensor.weather_rain +# - sensor.weather_wind_speed +# - sensor.weather_cloud_coverage +# - sensor.weather_forecast + Meteobridge: + - sensor.outdoor_temp_meteobridge + - sensor.outdoor_humidity_meteobridge + - sensor.outdoor_dewpoint_meteobridge + - sensor.precip_rate_meteobridge + - sensor.wind_direction_meteobridge + - sensor.wind_gust_meteohub + - sensor.wind_chill_meteobridge + - sensor.wind_speed_meteobridge + - sensor.indoor_dewpoint_meteobridge + - sensor.indoor_humidity_meteobridge + - sensor.indoor_temp_meteobridge + - sensor.precip_change_meteobridge + - sensor.precip_total_meteobridge + - sensor.sea_level_pressure_meteobridge + - sensor.barometric_pressure_meteobridge + +#################### +## ZONES +#################### +zone: + name: Home + latitude: 37 + longitude: -121 + radius: 200 + icon: mdi:home + +zone 2: + name: Barracuda_(SJ) + latitude: 37 + longitude: -121 + radius: 100 + +zone 3: + name: SFC + latitude: 37 + longitude: -122 + radius: 95 + +#################### +## NOTIFICATIONS +#################### + + +#################### +## AUTOMATION +#################### +automation: +#- alias: 'W_at_work' +# trigger: +# - platform: zone +# entity_id: device_tracker.will_wnexus +# zone: zone.barracuda_sj +# event: enter +# - platform: time +# after: '07:15' +# before: '09:00' +# action: +# service: ifttt.trigger +# data: {"event":"hassnotification_dadsms", "value1": "Will's at Work"} +- alias: "Update_Update" + trigger: + platform: state + entity_id: updater.updater + action: + service: ifttt.trigger + data: {"event":"hassnotification_willsms","value1":"HASS has an update"} +- alias: 'Christmas Roof ON' + trigger: + platform: sun + event: sunset + offset: '-01:00:00' + action: + service: homeassistant.turn_on + entity_id: switch.leviton_unknown_type1a02_id0334_switch_5 +- alias: 'Christmas Roof OFF' + trigger: + platform: time + hours: 1 + minutes: 0 + seconds: 0 + action: + service: homeassistant.turn_off + entity_id: switch.leviton_unknown_type1a02_id0334_switch_5 +- alias: 'Christmas Tree ON' + trigger: + platform: time + hours: 8 + minutes: 0 + seconds: 0 + action: + service: homeassistant.turn_on + entity_id: switch.leviton_unknown_type1a02_id0334_switch_4 +- alias: 'Christmas Tree (OFF)' + trigger: + platform: time + hours: 23 + minutes: 0 + seconds: 0 + action: + service: homeassistant.turn_off + entity_id: switch.leviton_unknown_type1a02_id0334_switch_4 +#- alias: test notify +# trigger: +# platform: time +# minutes: '/5' #every 5 min +# action: +# service: notify.pushEtta +# data: +# message: 5 Min Test + + +################################# +### COMPONENTS ### +################################# +#discovery: +sun: +#updater: +history: +#conversation: +frontend: +logbook: + +http: + api_password: Austin12# + server_port: 8123 + ssl_certificate: /etc/letsencrypt/live/example.com/fullchain.pem + ssl_key: /etc/letsencrypt/live/example.com/privkey.pem + +ifttt: + key: gm3dAtxwX8RpbA793mHWbK1bftO1wgScKt0ZHiT9GyC + +media_player 1: + platform: plex +#media_player 2: +# platform: squeezebox +# host: 192.168.2.80 +# port: 9000 +media_player 3: + platform: cast +media_player 4: + platform: kodi + url: http://192.168.2.129:8080/jsonrpc + user: kodi + password: kodi +media_player 5: + platform: plex +media_player 6: + platform: kodi + url: http://192.168.2.165/jsonrpc +media_player 7: + platform: samsungtv + host: 192.168.2.90 + name: Parents TV + +wink: + access_token: cf83448f669cd3acd3b969b063028565 + refresh_token: 6213c8a1d519d864e08b7364c91eaf22 + +zwave: + usb_path: /dev/ttyUSB0 + config_path: /usr/local/share/python-openzwave/config + polling_interval: 10000 + +#zigbee: +# device: /dev/ttyUSB1 +# baud: 115200 + +mqtt: + broker: 127.0.0.1 + port: 8883 + username: hass + password: austin + +device_tracker 1: + platform: owntracks + + track_new_devices: yes + interval_seconds: 40 + consider_home: 120 + +device_tracker 2: + platform: nmap_tracker + hosts: 192.168.2.0/24 + home_interval: 3 + +#sensor: +# platform: openweathermap +# api_key: b693a8bb2f60dcedc7b4bf33649ed4f1 +# forecast: 1 +# monitored_conditions: +# - temperature +# - wind_speed +# - humidity +# - pressure +# - clouds +# - rain + +sensor 2: + platform: time_date + display_options: + - 'time' + - 'date' + - 'time_utc' + +### BEGIN METEO SENSORS ### +sensor 3: + platform: tcp + name: Outdoor Temp (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[2]}}" + unit: C + +sensor 4: + platform: tcp + name: Outdoor Humidity (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[3]}}" + unit: Percent + +sensor 5: + platform: tcp + name: Outdoor Dewpoint (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[4] }}" + unit: C + +sensor 6: + platform: tcp + name: Wind Direction (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[7]}}" + unit: Degrees + +sensor 7: + platform: tcp + name: Wind Gust (Meteohub) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[8]}}" + unit: m/s + +sensor 8: + platform: tcp + name: Wind Speed (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[9]}}" + unit: m/s + +sensor 9: + platform: tcp + name: Wind Chill (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[10]}}" + unit: C + +sensor 10: + platform: tcp + name: Precip Rate (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[13]}}" + unit: mm/hr + +sensor 11: + platform: tcp + name: Precip Total (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[14]}}" + unit: mm + +sensor 12: + platform: tcp + name: Precip Change (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[15]}}" + unit: mm + +sensor 13: + platform: tcp + name: Indoor Temp (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[18]}}" + unit: C + +sensor 14: + platform: tcp + name: Indoor Humidity (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[19]}}" + unit: percent + +sensor 15: + platform: tcp + name: Indoor Dewpoint (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[20]}}" + unit: C + +sensor 16: + platform: tcp + name: Barometric Pressure (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[21]}}" + unit: mb + +sensor 17: + platform: tcp + name: Sea Level Pressure (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[22]}}" + unit: mb + +sensor 18: + platform: steam_online + api_key: [Redact] + accounts: + - 76561198012067051 + +switch: + platform: wemo diff --git a/source/_cookbook/configuration_yaml_from_bassclarinetl2.markdown b/source/_cookbook/configuration_yaml_from_bassclarinetl2.markdown new file mode 100644 index 00000000000..90f2298fa69 --- /dev/null +++ b/source/_cookbook/configuration_yaml_from_bassclarinetl2.markdown @@ -0,0 +1,460 @@ +--- +layout: page +title: "Configuration.yaml by bassclarinetl2" +description: "" +date: 2016-03-24 17:00 +sidebar: true +comments: false +sharing: true +footer: true +ha_category: Example configuration.yaml +--- + +```yaml +homeassistant: + # Name of the location where Home Assistant is running + name: example.com + # Location required to calculate the time the sun rises and sets + latitude: 37 + longitude: -121 + # C for Celcius, F for Fahrenheit + temperature_unit: F + # Pick yours from here: http://en.wikipedia.org/wiki/List_of_tz_database_time_zones + time_zone: America/Los_Angeles + customize: + switch.aeon_labs_smart_energy_switch_switch_2: + friendly_name: Mac Switch-Meter + switch.leviton_unknown_type1a02_id0334_switch_3: + friendly_name: W Nightstand + entity_picture: /local/zwvapl.jpg + switch.hub_switch: + friendly_name: Wink Hub Switch + entity_picture: /local/wemoswitch.jpg + switch.leviton_unknown_type1a02_id0334_switch_4: + friendly_name: Christmas Tree + entity_picture: /local/zwvapl.jpg + switch.leviton_unknown_type1a02_id0334_switch_5: + friendly_name: Roof Lights + entity_picture: /local/zwvapl.jpg + + light.w_bedroom_ceiling_: + friendly_name: Will's Bedroom Ceiling Lights (Wink) + entity_picture: /local/casetta.jpg + light.living_room_wall_: + friendly_name: Living Room Couch Lights (Wink) + entity_picture: /local/casetta.jpg + + media_player.my_shield_android_tv: + friendly_name: Dalek (Cast) + entity_picture: /local/shieldtv.jpg + media_player.chromecast: + friendly_name: Jeff chromecast + entity_picture: /local/chromecast.jpg + media_player.kodi: + friendly_name: Tardis-Win7 (Kodi) + entity_picture: /local/kodi.png + media_player.kodi_2: + friendly_name: Dalek (Kodi) + media_player.roku_2_xd__12a18n045363: + friendly_name: Parents Roku + entity_picture: /local/roku2xd.jpg + + sensor.aeon_labs_smart_energy_switch_power_2: + friendly_name: Mac Usage (W) + sensor.aeon_labs_smart_energy_switch_previous_reading_2: + friendly_name: Mac Usage Previous (W) + hidden: true + sensor.aeon_labs_smart_energy_switch_energy_2: + friendly_name: Mac Usage (kWh) + hidden: true + +##################### +## GROUPS +##################### +group: + w_bedroom: + - switch.leviton_unknown_type1a02_id0334_switch_3 + - light.w_bedroom_ceiling_ + christmas: + - switch.leviton_unknown_type1a02_id0334_switch_4 + - switch.leviton_unknown_type1a02_id0334_switch_5 + almanac: + - sensor.date + - sensor.time + - sensor.time_utc + - sun.sun + tracker: + - device_tracker.will_wnexus +# OpenWeatherMap: +# - sensor.weather_temperature +# - sensor.weather_humidity +# - sensor.weather_pressure +# - sensor.weather_rain +# - sensor.weather_wind_speed +# - sensor.weather_cloud_coverage +# - sensor.weather_forecast + Meteobridge: + - sensor.outdoor_temp_meteobridge + - sensor.outdoor_humidity_meteobridge + - sensor.outdoor_dewpoint_meteobridge + - sensor.precip_rate_meteobridge + - sensor.wind_direction_meteobridge + - sensor.wind_gust_meteohub + - sensor.wind_chill_meteobridge + - sensor.wind_speed_meteobridge + - sensor.indoor_dewpoint_meteobridge + - sensor.indoor_humidity_meteobridge + - sensor.indoor_temp_meteobridge + - sensor.precip_change_meteobridge + - sensor.precip_total_meteobridge + - sensor.sea_level_pressure_meteobridge + - sensor.barometric_pressure_meteobridge + +#################### +## ZONES +#################### +zone: + name: Home + latitude: 37 + longitude: -121 + radius: 200 + icon: mdi:home + +zone 2: + name: Barracuda_(SJ) + latitude: 37 + longitude: -121 + radius: 100 + +zone 3: + name: SFC + latitude: 37 + longitude: -122 + radius: 95 + +#################### +## NOTIFICATIONS +#################### + + +#################### +## AUTOMATION +#################### +automation: +#- alias: 'W_at_work' +# trigger: +# - platform: zone +# entity_id: device_tracker.will_wnexus +# zone: zone.barracuda_sj +# event: enter +# - platform: time +# after: '07:15' +# before: '09:00' +# action: +# service: ifttt.trigger +# data: {"event":"hassnotification_dadsms", "value1": "Will's at Work"} +- alias: "Update_Update" + trigger: + platform: state + entity_id: updater.updater + action: + service: ifttt.trigger + data: {"event":"hassnotification_willsms","value1":"HASS has an update"} +- alias: 'Christmas Roof ON' + trigger: + platform: sun + event: sunset + offset: '-01:00:00' + action: + service: homeassistant.turn_on + entity_id: switch.leviton_unknown_type1a02_id0334_switch_5 +- alias: 'Christmas Roof OFF' + trigger: + platform: time + hours: 1 + minutes: 0 + seconds: 0 + action: + service: homeassistant.turn_off + entity_id: switch.leviton_unknown_type1a02_id0334_switch_5 +- alias: 'Christmas Tree ON' + trigger: + platform: time + hours: 8 + minutes: 0 + seconds: 0 + action: + service: homeassistant.turn_on + entity_id: switch.leviton_unknown_type1a02_id0334_switch_4 +- alias: 'Christmas Tree (OFF)' + trigger: + platform: time + hours: 23 + minutes: 0 + seconds: 0 + action: + service: homeassistant.turn_off + entity_id: switch.leviton_unknown_type1a02_id0334_switch_4 +#- alias: test notify +# trigger: +# platform: time +# minutes: '/5' #every 5 min +# action: +# service: notify.pushEtta +# data: +# message: 5 Min Test + + +################################# +### COMPONENTS ### +################################# +#discovery: +sun: +#updater: +history: +#conversation: +frontend: +logbook: + +http: + api_password: Austin12# + server_port: 8123 + ssl_certificate: /etc/letsencrypt/live/example.com/fullchain.pem + ssl_key: /etc/letsencrypt/live/example.com/privkey.pem + +ifttt: + key: gm3dAtxwX8RpbA793mHWbK1bftO1wgScKt0ZHiT9GyC + +media_player 1: + platform: plex +#media_player 2: +# platform: squeezebox +# host: 192.168.2.80 +# port: 9000 +media_player 3: + platform: cast +media_player 4: + platform: kodi + url: http://192.168.2.129:8080/jsonrpc + user: kodi + password: kodi +media_player 5: + platform: plex +media_player 6: + platform: kodi + url: http://192.168.2.165/jsonrpc +media_player 7: + platform: samsungtv + host: 192.168.2.90 + name: Parents TV + +wink: + access_token: cf83448f669cd3acd3b969b063028565 + refresh_token: 6213c8a1d519d864e08b7364c91eaf22 + +zwave: + usb_path: /dev/ttyUSB0 + config_path: /usr/local/share/python-openzwave/config + polling_interval: 10000 + +#zigbee: +# device: /dev/ttyUSB1 +# baud: 115200 + +mqtt: + broker: 127.0.0.1 + port: 8883 + username: hass + password: austin + +device_tracker 1: + platform: owntracks + + track_new_devices: yes + interval_seconds: 40 + consider_home: 120 + +device_tracker 2: + platform: nmap_tracker + hosts: 192.168.2.0/24 + home_interval: 3 + +#sensor: +# platform: openweathermap +# api_key: b693a8bb2f60dcedc7b4bf33649ed4f1 +# forecast: 1 +# monitored_conditions: +# - temperature +# - wind_speed +# - humidity +# - pressure +# - clouds +# - rain + +sensor 2: + platform: time_date + display_options: + - 'time' + - 'date' + - 'time_utc' + +### BEGIN METEO SENSORS ### +sensor 3: + platform: tcp + name: Outdoor Temp (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[2]}}" + unit: C + +sensor 4: + platform: tcp + name: Outdoor Humidity (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[3]}}" + unit: Percent + +sensor 5: + platform: tcp + name: Outdoor Dewpoint (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[4] }}" + unit: C + +sensor 6: + platform: tcp + name: Wind Direction (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[7]}}" + unit: Degrees + +sensor 7: + platform: tcp + name: Wind Gust (Meteohub) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[8]}}" + unit: m/s + +sensor 8: + platform: tcp + name: Wind Speed (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[9]}}" + unit: m/s + +sensor 9: + platform: tcp + name: Wind Chill (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[10]}}" + unit: C + +sensor 10: + platform: tcp + name: Precip Rate (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[13]}}" + unit: mm/hr + +sensor 11: + platform: tcp + name: Precip Total (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[14]}}" + unit: mm + +sensor 12: + platform: tcp + name: Precip Change (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[15]}}" + unit: mm + +sensor 13: + platform: tcp + name: Indoor Temp (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[18]}}" + unit: C + +sensor 14: + platform: tcp + name: Indoor Humidity (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[19]}}" + unit: percent + +sensor 15: + platform: tcp + name: Indoor Dewpoint (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[20]}}" + unit: C + +sensor 16: + platform: tcp + name: Barometric Pressure (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[21]}}" + unit: mb + +sensor 17: + platform: tcp + name: Sea Level Pressure (Meteobridge) + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[22]}}" + unit: mb + +sensor 18: + platform: steam_online + api_key: [Redact] + accounts: + - 76561198012067051 + +switch: + platform: wemo +``` diff --git a/source/_cookbook/python_component_basic_state.markdown b/source/_cookbook/python_component_basic_state.markdown index 3eca0d8bbab..7a95cec30ad 100644 --- a/source/_cookbook/python_component_basic_state.markdown +++ b/source/_cookbook/python_component_basic_state.markdown @@ -10,34 +10,116 @@ footer: true ha_category: Custom Python Component Examples --- -This is a simple hello world example to show the basics for setting a state. To use this example, create the file `
+
+
Hold your NFC tag against the belly of Garfield to unlock the alarm.
-
+Use the service developer tool in the frontend to discover available services. +
+ +### {% linkable_title The basics %} + +Call the service `homeassistant.turn_on` on the entity `group.living_room`. This will turn all members of `group.living_room` on. You can also omit `entity_id` and it will turn on all possible entities. + +```yaml +automation: +- trigger: + platform: sun + event: sunset + action: + service: homeassistant.turn_on + entity_id: group.living_room +``` + +### {% linkable_title Passing data to the service call %} + +You can also specify other parameters beside the entity to target. For example, the light turn on service allows specifying the brightness. + +```yaml +automation: +- trigger: + platform: sun + event: sunset + action: + service: light.turn_on + entity_id: group.living_room + data: + brightness: 120 + rgb_color: [255, 0, 0] +``` + +### {% linkable_title Use templates to decide which service to call %} + +You can use [templating] support to dynamically choose which service to call. For example, you can call a certain service based on if a light is on. + +```yaml +automation: +- trigger: + platform: sun + event: sunset + action: + service_template: > + {% raw %}{% if states.sensor.temperature | float > 15 %} + switch.turn_on + {% else %} + switch.turn_off + {% endif %}{% endraw %} + entity_id: switch.ac +``` + +### {% linkable_title Use templates to determine the attributes %} + +Templates can also be used for the data that you pass to the service call. + +```yaml +automation: +- trigger: + platform: sun + event: sunset + action: + service_template: thermostat.set_temperature + data_template: + entity_id: > + {% raw %}{% if is_state('device_tracker.paulus', 'home') %} + thermostat.upstairs + {% else %} + thermostat.downstairs + {% endif %}{% endraw %} + temperature: {% raw %}{{ 22 - distance(states.device_tracker.paulus) }}{% endraw %} +``` + +[templating]: /topics/templating/ diff --git a/source/_topics/splitting_configuration.markdown b/source/_topics/splitting_configuration.markdown new file mode 100644 index 00000000000..46dddbdf1d7 --- /dev/null +++ b/source/_topics/splitting_configuration.markdown @@ -0,0 +1,301 @@ +--- +layout: page +title: "Splitting up the configuration" +description: "Splitting the configuration.yaml into several files." +date: 2016-03-25 23:30 +sidebar: false +comments: false +sharing: true +footer: true +--- + +So you've been using Home Assistant (HA, hass, or any number of other abbreviations) for a while now and your configuration.yaml file brings people to tears (https://home-assistant.io/cookbook/configuration_yaml_from_bassclarinetl2/) or you simply want to start off with the distributed approach, here's how to "split the configuration.yaml" into more manageable (read: husmanly readable) pieces. + +First off, several community members have sanitized (read: without api keys/passwords etc) versions of their configurations available for viewing: + +- https://github.com/bassclarinetl2/HASS +- https://github.com/happyleavesaoc/my-home-automation/tree/master/homeassistant + +As commenting code doesn't always happen, please read on for the details. + +Now despite the logical assumption that the configuration.yaml will be replaced by this process it will in fact remain all be it in a much less cluttered form. + +In this lighter version we will still need what could be called the core snippet: + + homeassistant: + # Name of the location where Home Assistant is running + name: My Hass Instance + # Location required to calculate the time the sun rises and sets + latitude: 37 + longitude: -121 + # C for Celcius, F for Fahrenheit + temperature_unit: F + # Pick yours from here: http://en.wikipedia.org/wiki/List_of_tz_database_time_zones + time_zone: America/Los_Angeles + customize: !include customize.yaml + +Note that each line after `homeassistant:` is indented two (2) spaces. Since the configuration files in Home Assistant are based on the YAML "language", indentation and spacing are important. Also note that seemingly strange entry under `customize:`. + +`!include filename.yaml` is the statement that tells Home Assistant to insert the contents of `filename.yaml` at that point. This is how we are going to break a monolithic and hard to read file (when it gets big) into more manageable chunks. + +Now before we start splitting out the different components, let's look at the other components (in our example) that will stay in the base file: + +``` +#discovery: +sun: +#updater: +history: +#conversation: +frontend: +logbook: +http: + api_password: ImNotTelling! + server_port: 8123 + ssl_certificate: /etc/letsencrypt/live/example.com/fullchain.pem + ssl_key: /etc/letsencrypt/live/example.com/privkey.pem + +ifttt: + key: [nope] + +wink: + access_token: [wouldn't you] + refresh_token: [like to know] + +zwave: + usb_path: /dev/ttyUSB0 + config_path: /usr/local/share/python-openzwave/config + polling_interval: 10000 + +#zigbee: +# device: /dev/ttyUSB1 +# baud: 115200 + +mqtt: + broker: 127.0.0.1 + port: 8883 + username: user + password: password +``` +As with the core snippet, indentation makes a difference. The component headers (`mqtt:`) should be fully left aligned (aka no indent), and the parameters (`port:`) should be indented two (2) spaces. + +While some of these components can technically be moved to a separate file they are so small or "one off's" where splitting them off is superfluous. Also, you'll notice the # symbol (hash/pound). This represents a "comment" as far as the commands are interpreted. Put another way, any line prefixed with a `#` will be ignored. This makes breaking up files for human readability really convenient , not to mention turning off features while leaving the entry intact. (Look at the `zigbee:` entry above and the sensors entry further down) + +Now, lets assume that a blank file has been created in the hass configuration directory for each of the following: + + groups.yaml + zones.yaml + automation.yaml + notifications.yaml + sensors.yaml + switches.yaml + scripts.yaml + media_player.yaml + device_tracker.yaml + customize.yaml + +`automation.yaml`will hold all the automation component details +`zones.yaml` will hold the zone component details +and so forth. These files can be called anything but giving them names that match their function will make things easier to keep track of. + +Inside the base configuration file add the following entries: +``` +group: !include groups.yaml +zone: !include zones.yaml +automation: !include automation.yaml +notifications: !include notifications.yaml +sensor: !include sensors.yaml +switch: !include switches.yaml +scripts: !include: scripts.yaml +media_player: !include media_player.yaml +device_tracker: !include device_tracker.yaml +``` +Note that there can only be one `!include:` for each component so chaining them isn't going to work. If that sounds like greek, don't worry about it. + +Alright, so we've got the single components and the include statements in the base file, what goes in those extra files? + +Let's look at the `device_tracker` file from our example: + +``` +### device_tracker.yaml +### +### + +- platform: owntracks +- platform: nmap_tracker + hosts: 192.168.2.0/24 + home_interval: 3 + + track_new_devices: yes + interval_seconds: 40 + consider_home: 120 +``` +This small example illustrates how the "split" files work. In this case, we start with a "comment block" identifying the file followed by two (2) device tracker entries (owntracks and nmap). These files follow "style 2" that is to say a fully left aligned leading entry (`- platform: owntracks`) followed by the parameter entries indented two (2) spaces. + +This (large) sensor configuration gives us another example: +``` +### sensors.yaml +### +### +### +############################################################## +### METEOBRIDGE #### +### http://meteobridge.com/wiki/index.php/Add-On_Services #### +### Live Data as Plain text #### +############################################################## + +- platform: tcp + name: 'Outdoor Temp (Meteobridge)' + host: 192.168.2.82 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[2]}}" + unit: C +- platform: tcp + name: 'Outdoor Humidity (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[3]}}" + unit: Percent +- platform: tcp + name: 'Outdoor Dewpoint (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[4] }}" + unit: C +- platform: tcp + name: 'Wind Direction (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[7]}}" + unit: Degrees +- platform: tcp + name: 'Wind Gust (Meteohub)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[8]}}" + unit: m/s +- platform: tcp + name: 'Wind Speed (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[9]}}" + unit: m/s +- platform: tcp + name: 'Wind Chill (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[10]}}" + unit: C +- platform: tcp + name: 'Precip Rate (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charset=UTF-8\n\n" + value_template: "{{value.split (' ')[13]}}" + unit: mm/hr +- platform: tcp + name: 'Precip Total (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[14]}}" + unit: mm +- platform: tcp + name: 'Precip Change (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[15]}}" + unit: mm +- platform: tcp + name: 'Indoor Temp (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[18]}}" + unit: C +- platform: tcp + name: 'Indoor Humidity (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[19]}}" + unit: percent +- platform: tcp + name: 'Indoor Dewpoint (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[20]}}" + unit: C +- platform: tcp + name: 'Barometric Pressure (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[21]}}" + unit: mb +- platform: tcp + name: 'Sea Level Pressure (Meteobridge)' + host: 192.168.2.82 + port: 5556 + timeout: 6 + payload: "Content-type: text/xml; charaset=UTF-8\n\n" + value_template: "{{value.split (' ')[22]}}" + unit: mb +################################### +#### STEAM FRIENDS #### +################################## + +- platform: steam_online + api_key: [not telling] + accounts: + - 76561198012067051 + +################################## +#### TIME/DATE #### +################################## + +- platform: time_date + display_options: + - 'time' + - 'date' +- platform: worldclock + time_zone: Etc/UTC + name: 'UTC' +- platform: worldclock + time_zone: America/New_York + name: 'Ann Arbor' +- platform: worldclock + time_zone: Europe/Vienna + name: 'Innsbruck' +- platform: worldclock + time_zone: America/New_York + name: 'Ann Arbor' +``` + +You'll notice that this example includes a secondary parameter section (under the steam section) as well as a better example of the way comments can be used to break down files into sections. + +That about wraps it up. + +If you have issues checkout `home-assistant.log` in the configuration directory as well as your indentations. If all else fails, head over to the gitter.im chat and ask away. + diff --git a/source/_topics/state_object.markdown b/source/_topics/state_object.markdown new file mode 100644 index 00000000000..1f1a16425f3 --- /dev/null +++ b/source/_topics/state_object.markdown @@ -0,0 +1,39 @@ +--- +layout: page +title: "State Objects" +description: "Describes all there is to know about state objects in Home Assistant." +date: 2016-03-12 12:00 -0800 +sidebar: false +comments: false +sharing: true +footer: true +--- + +Your devices are represented in Home Assistant as entities. The entities will write their current state to the state machine for other entities/templates/frontend to access. States are a current representation of the entity. + +If you overwrite a state via the states dev tool or the API, it will not impact the actual device. If the device state is being polled, it will overwrite the state in the state machine the next polling. + +All states will always have an entity id, a state and a timestamp when last updated and last changed. + +Field | Description +----- | ----------- +`state.entity_id` | Entity ID. Format: `-This is an advanced feature of Home Assistant. You'll need a basic understanding of the [Home Assistant architecture], especially states. -
+This is an advanced feature of Home Assistant. You'll need a basic understanding of the following things: + + - [Home Assistant architecture], especially states. + - [State object] + [Home Assistant architecture]: /developers/architecture/ +[State object]: /topics/state_object/ Templating is a powerful feature in Home Assistant that allows the user control over information that is going into and out of the system. It is used for: diff --git a/source/_topics/z-wave.markdown b/source/_topics/z-wave.markdown new file mode 100644 index 00000000000..84d15a60c62 --- /dev/null +++ b/source/_topics/z-wave.markdown @@ -0,0 +1,30 @@ +--- +layout: page +title: "Z-Wave" +description: "Extended instructions how to setup Z-Wave." +date: 2016-03-24 08:49 -0700 +sidebar: false +comments: false +sharing: true +footer: true +--- + + + +Z-Wave is a popular home automation protocol that is not always straightforward to setup. This page will try to help you make sense of it all. + +- Note: Upon first run, the z-wave component will take time to initialize entities and entities may appear with incomplete names. Running a network heal may expidite this proccess. + +## {% linkable_title Supported Z-Wave Sticks %} + +| Device | Works on Linux | Works on Windows | Works on OSX | Comments | +|-------------------------|----------------|------------------|--------------|-----------| +| Aeotec Z-Stick Series 2 | X | | | | +| Aeotec Z-Stick Series 5 | X | | | | + + +## {% linkable_title Stick Alternatives %} + +The alternative to a stick is a hub that supports Z-Wave. Home Assistant supports the following hubs with Z-Wave support: + + - [Vera](/components/vera/) diff --git a/source/demo/frontend.html b/source/demo/frontend.html index ceb54a134d8..aa9efcef31f 100644 --- a/source/demo/frontend.html +++ b/source/demo/frontend.html @@ -5581,7 +5581,7 @@ case"touchend":return this.addPointerListenerEnd(t,e,i,n);case"touchmove":return .rendered.error { color: red; - }Templates are rendered using the Jinja2 template engine with some Home Assistant specific extensions.
[[processed]]
Templates are rendered using the Jinja2 template engine with some Home Assistant specific extensions.
[[processed]]