diff --git a/sass/custom/_paulus.scss b/sass/custom/_paulus.scss index e74106df9c3..6720925343b 100644 --- a/sass/custom/_paulus.scss +++ b/sass/custom/_paulus.scss @@ -213,6 +213,11 @@ article.post, article.page, article.listing { text-decoration: none; } } + + h1, h2, h3 { + margin-bottom: 0; + line-height: 1.2; + } } p.note { diff --git a/source/_components/binary_sensor.markdown b/source/_components/binary_sensor.markdown index 48c8dd29afd..d15152753e2 100644 --- a/source/_components/binary_sensor.markdown +++ b/source/_components/binary_sensor.markdown @@ -18,12 +18,12 @@ Most binary sensors support the `SENSOR_CLASSES` which let you specify the type - **None**: Generic on/off - **opening**: Door, window, etc - **motion**: Motion sensor -- **gas'**: CO, CO2, etc -- **smoke'**: Smoke detector +- **gas**: CO, CO2, etc +- **smoke**: Smoke detector - **moisture**: Specifically a wetness sensor - **light**: Lightness threshold - **power**: Power, over-current, etc -- **safety**: Generic on=unsafe, off=safe +- **safety**: On means unsafe, Off means safe - **heat**: On means hot (or too hot) - **cold**: On means cold (or too cold) - **moving**: On means moving, Off means stopped diff --git a/source/_components/binary_sensor.template.markdown b/source/_components/binary_sensor.template.markdown index 5cadc4bad20..abe1160fd45 100644 --- a/source/_components/binary_sensor.template.markdown +++ b/source/_components/binary_sensor.template.markdown @@ -17,11 +17,11 @@ To enable Template binary sensors in your installation, add the following to you ```yaml # Example configuration.yaml entry binary_sensor: - platform: template - sensors: - sun_up: - value_template: {% raw %}'{{ states.sun.sun.attributes.elevation > 0}}'{% endraw %} - friendly_name: 'Sun is up' + - platform: template + sensors: + sun_up: + value_template: {% raw %}'{{ states.sun.sun.attributes.elevation > 0}}'{% endraw %} + friendly_name: 'Sun is up' ``` Configuration variables: @@ -30,8 +30,7 @@ Configuration variables: - **friendly_name** (*Optional*): Name to use in the Frontend. - **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. - - **warnings** (*Optional*): Turn off warnings (useful if the sensor is loaded before devices it depends on). - - **entity_id** (*Optional*): Add a list of entity_ids so the sensor only reacts to state changes of these entities. This will reduce the number of times the sensor will try to update it's state. + - **entity_id** (*Optional*): Add a list of entity IDs so the sensor only reacts to state changes of these entities. This will reduce the number of times the sensor will try to update it's state. ## {% linkable_title Examples %} @@ -43,26 +42,26 @@ This example indicates true if a sensor is above a given threshold. Assuming a s ```yaml sensor: - platform: template - sensors: - furnace_on: - value_template: {% raw %}{{ states.sensor.furnace.state > 2.5 }}{% endraw %} - friendly_name: 'Furnace Running - sensor_class: heat + - platform: template + sensors: + furnace_on: + value_template: {% raw %}{{ states.sensor.furnace.state > 2.5 }}{% endraw %} + friendly_name: 'Furnace Running + sensor_class: heat ``` ### {% linkable_title Switch as sensor %} -Some movement sensors and door/window sensors will apear as a switch. By using a template binary sensor, the switch can be displayed as a binary sensors. The original switch can then be hidden by [customizing.](/getting-started/customizing-devices/) +Some movement sensors and door/window sensors will appear as a switch. By using a template binary sensor, the switch can be displayed as a binary sensors. The original switch can then be hidden by [customizing.](/getting-started/customizing-devices/) ```yaml binary_sensor: - platform: template - sensors: - movement: - value_template: {% raw %}"{{ states.switch.movement.state == 'on' }}"{% endraw %} - sensor_class: motion - door: - value_template: {% raw %}"{{ states.switch.door.state == 'on' }}"{% endraw %} - sensor_class: opening + - platform: template + sensors: + movement: + value_template: {% raw %}"{{ states.switch.movement.state == 'on' }}"{% endraw %} + sensor_class: motion + door: + value_template: {% raw %}"{{ states.switch.door.state == 'on' }}"{% endraw %} + sensor_class: opening ``` diff --git a/source/_components/camera.ffmpeg.markdown b/source/_components/camera.ffmpeg.markdown new file mode 100644 index 00000000000..e7fcaf4326c --- /dev/null +++ b/source/_components/camera.ffmpeg.markdown @@ -0,0 +1,44 @@ +--- +layout: page +title: "FFmpeg Camera" +description: "Instructions how to integrate a Video fees with FFmpeg as cameras within Home Assistant." +date: 2016-08-13 08:00 +sidebar: true +comments: false +sharing: true +footer: true +logo: ffmpeg.png +ha_category: Camera +ha_release: 0.26 +--- + + +The `ffmpeg` platform allows you to use every video feed with [FFmpeg](http://www.ffmpeg.org/) as camera in Home Assistant. + +
+You need a ffmpeg binary in your system path. On debain 8 you can install it from backports. If you want HW support on raspberry you need self build from source. Windows binary are avilable on ffmpeg homepage. +
+ +To enable your FFmpeg feed in your installation, add the following to your `configuration.yaml` file: + +```yaml +# Example configuration.yaml entry +camera: + - platform: ffmpeg + input: FFMPEG_SUPPORTED_INPUT + name: FFmpeg + ffmpeg_bin: /usr/bin/ffmpeg + extra_arguments: -q:v 2 +``` + +Configuration variables: + +- **input** (*Required*): A ffmpeg compatible input file, stream or feet. +- **name** (*Optional*): This parameter allows you to override the name of your camera. +- **ffmpeg_bin** (*Optional*): Default 'ffmpeg'. +- **extra_arguments** (*Optional*): Extra option they will pass to ffmpeg. i.e. image quality or video filter options. + +### {% linkable_title Image quality %} + +You can control the `image quality` with [`extra_arguments`](https://www.ffmpeg.org/ffmpeg-codecs.html#jpeg2000) `-q:v 2-32` or with lossless option `-pred 1`. + diff --git a/source/_components/device_tracker.bluetooth_tracker.markdown b/source/_components/device_tracker.bluetooth_tracker.markdown index 0a98675fbe9..7fb68509c21 100644 --- a/source/_components/device_tracker.bluetooth_tracker.markdown +++ b/source/_components/device_tracker.bluetooth_tracker.markdown @@ -1,7 +1,7 @@ --- layout: page title: "Bluetooth Tracker" -description: "Instructions how to integrate bluetooth tracking within Home Assistant." +description: "Instructions for integrating bluetooth tracking within Home Assistant." date: 2016-04-10 17:24 sidebar: true comments: false @@ -13,11 +13,11 @@ ha_iot_class: "Local Poll" ha_release: 0.18 --- -This tracker discovers new devices on boot and tracks bluetooth devices periodically based on interval_seconds value. It is not requiered to pair the devices with eachother! -Devices discovered are stored with 'bt_' as the prefix for device mac address in `known_devices.yaml`. +This tracker discovers new devices on boot and tracks bluetooth devices periodically based on interval_seconds value. It is not required to pair the devices with each other! +Devices discovered are stored with 'bt_' as the prefix for device mac addresses in `known_devices.yaml`.-Requires PyBluez. If you are on raspbian, make sure you first install `bluetooth` and `libbluetooth-dev` by running `sudo apt install bluetooth libbluetooth-dev` +Requires PyBluez. If you are on Raspbian, make sure you first install `bluetooth` and `libbluetooth-dev` by running `sudo apt install bluetooth libbluetooth-dev`
To use the Bluetooth tracker in your installation, add the following to your `configuration.yaml` file: diff --git a/source/_components/homematic.markdown b/source/_components/homematic.markdown index 446599b16cc..5adb4a24160 100644 --- a/source/_components/homematic.markdown +++ b/source/_components/homematic.markdown @@ -10,7 +10,7 @@ footer: true logo: homematic.png ha_category: Hub ha_iot_class: "Local Push" -featured: true +featured: false --- diff --git a/source/_components/http.markdown b/source/_components/http.markdown index 3d984ed8861..3341d121ace 100644 --- a/source/_components/http.markdown +++ b/source/_components/http.markdown @@ -25,8 +25,8 @@ http: ssl_certificate: /etc/letsencrypt/live/hass.example.com/fullchain.pem ssl_key: /etc/letsencrypt/live/hass.example.com/privkey.pem cors_allowed_origins: - - google.com - - home-assistant.io + - https://google.com + - https://home-assistant.io ``` Configuration variables: @@ -37,7 +37,7 @@ Configuration variables: - **development** (*Optional*): Disable caching and load unvulcanized assets. Useful for Frontend development. - **ssl_certificate** (*Optional*): Path to your TLS/SSL certificate to serve Home Assistant over a secure connection. - **ssl_key** (*Optional*): Path to your TLS/SSL key to serve Home Assistant over a secure connection. -- **cors_allowed_origins** (*Optional*): A list of origin domain names to allow [CORS](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing) requests from. Enabling this will set the `Access-Control-Allow-Origin` header to the Origin header if it is found in the list, and the `Access-Control-Allow-Headers` to `Origin, Accept, X-Requested-With, Content-type, X-HA-access`. +- **cors_allowed_origins** (*Optional*): A list of origin domain names to allow [CORS](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing) requests from. Enabling this will set the `Access-Control-Allow-Origin` header to the Origin header if it is found in the list, and the `Access-Control-Allow-Headers` header to `Origin, Accept, X-Requested-With, Content-type, X-HA-access`. You must provide the exact Origin, i.e. `https://home-assistant.io` will allow requests from `https://home-assistant.io` but __not__ `http://home-assistant.io`. The [Set up encryption using Let's Encrypt](/blog/2015/12/13/setup-encryption-using-lets-encrypt/) blog post gives you details about the encryption of your traffic using free certificates from [Let's Encrypt](https://letsencrypt.org/). diff --git a/source/_components/light.flux_led.markdown b/source/_components/light.flux_led.markdown index 84b3c4283e8..32ab0808cff 100644 --- a/source/_components/light.flux_led.markdown +++ b/source/_components/light.flux_led.markdown @@ -9,7 +9,7 @@ sharing: true footer: true ha_category: Light ha_iot_class: "Local Polling" -featured: true +featured: false ha_release: 0.25 --- diff --git a/source/_components/light.markdown b/source/_components/light.markdown index b2a244da8d2..028e89175d1 100644 --- a/source/_components/light.markdown +++ b/source/_components/light.markdown @@ -36,7 +36,7 @@ Turns one light on or multiple lights on using [groups]({{site_root}}/components | `transition` | yes | Integer that represents the time the light should take to transition to the new state in seconds. *not supported by Wink | `profile` | yes | String with the name of one of the built-in profiles (relax, energize, concentrate, reading) or one of the custom profiles defined in `light_profiles.csv` in the current working directory. Light profiles define a xy color and a brightness. If a profile is given and a brightness or xy color then the profile values will be overwritten. | `xy_color` | yes | A list containing two floats representing the xy color you want the light to be. Two comma seperated floats that represent the color in XY. -| `rgb_color` | yes | A list containing three integers representing the xy color you want the light to be. Three comma seperated integers that represent the color in RGB +| `rgb_color` | yes | A list containing three integers representing the rgb color you want the light to be. Three comma seperated integers that represent the color in RGB | `color_temp` | yes | An INT in mireds representing the color temperature you want the light to be. | `color_name` | yes | A human readable string of a color name, such as `blue` or `goldenrod` or [`chucknorris`](http://stackoverflow.com/questions/8318911/why-does-html-think-chucknorris-is-a-color). If your browser can display it, so can Home Assistant. | `brightness` | yes | Integer between 0 and 255 for how bright the color should be. diff --git a/source/_components/light.mqtt_json.markdown b/source/_components/light.mqtt_json.markdown index 9110e9af525..c749ed53a7a 100755 --- a/source/_components/light.mqtt_json.markdown +++ b/source/_components/light.mqtt_json.markdown @@ -10,6 +10,7 @@ footer: true logo: mqtt.png ha_category: Light ha_iot_class: "Local Push" +ha_release: 0.26 --- diff --git a/source/_components/media_player.firetv.markdown b/source/_components/media_player.firetv.markdown index eead6cfc6dc..bb1a9ae3d59 100644 --- a/source/_components/media_player.firetv.markdown +++ b/source/_components/media_player.firetv.markdown @@ -27,7 +27,7 @@ Steps to configure your Amazon Fire TV stick with Home Assistant: - From the main (Launcher) screen, select Settings. - Select System > About > Network. - `pip install firetv[firetv-server]` into a Python 2.x environment - - If installed on Debian Jessie then the libssl-dev package is needed. Install it with `apt-get install libssl-dev` + - If installed on Debian Jessie then the libssl-dev and python-dev packages are needed. Install them with `apt-get install libssl-dev python-dev` - `firetv-server -dIf you are accessing home Assistant over HTTPS using SSL, you cannot access HTTP sites through an iframe panel.
+ To enable Panel iFrames in your installation, add the following to your `configuration.yaml` file: ```yaml diff --git a/source/_components/pilight.markdown b/source/_components/pilight.markdown new file mode 100644 index 00000000000..a3fdbf8e4ce --- /dev/null +++ b/source/_components/pilight.markdown @@ -0,0 +1,52 @@ +--- +layout: page +title: "Pilight" +description: "Instructions how to setup Pilight within Home Assistant." +date: 2015-08-07 18:00 +sidebar: true +comments: false +sharing: true +footer: true +logo: pilight.png +ha_category: Hub +ha_release: 0.26 +ha_iot_class: Local Push +--- + +[Pilight](https://www.pilight.org/) is a modular and open source solution to communicate with 433 MHz devices and runs on various small form factor computers. A lot of common [protocols](https://wiki.pilight.org/doku.php/protocols) are already available. + +This pilight hub connects to the [pilight-daemon](https://wiki.pilight.org/doku.php/pdaemon) via a socket connection to receive and send codes. Thus home assistant does not have to run on the computer in charge of the RF communication. + +The received and supported RF codes are put on the event bus of home assistant and are therefore directly usable by other components (e.g. automation). Additionally a send service is provided to send RF codes. + +To integrate pilight into Home Assistant, add the following section to your `configuration.yaml` file: + +```yaml +# Example configuration.yaml entry +pilight: + - host: 127.0.0.1 + port: 5000 + whitelist: # optional + protocol: + - daycom + - intertechno + id: + - 42 +``` + +Configuration variables: + +- **host** (*Required*): The IP address of the computer running the pilight-daemon, e.g. 192.168.1.32. +- **port** (*Required*): The network port to connect to. The usual port is [5000](https://www.pilight.org/development/api/). +- **whitelist** (*Optional*): You can define a whitelist to prevent that too many unwanted RF codes (e.g. the neighbours weather station) are put on your HA event bus. All defined subsections have to be matched. A subsection is matched if one of the items are true. + +In this example only received RF codes using a daycom or intertechno protocol are put on the event bus and only when the device id is 42. For more possible settings please look at the receiver section of the pilight [API](https://www.pilight.org/development/api/). + +## {% linkable_title Troubleshooting %} + +- A list of tested RF transceiver hardware is available [here](https://wiki.pilight.org/doku.php/electronics). This might be usefull before buying. +- Sending commands is simple when the protocol is known by pilight, but receiving commands can be rather difficult. It can happend that the code is not correctly recognized due to different timings in the sending hardware or the RF receiver. If this happens follow these steps: + +1. [Install](https://www.pilight.org/get-started/installation/) pilight from source (do not worry that is very easy) and only activate the protocols you are expecting in the pop up menu. This reduces false positives. +2. Check the real timings of your device + RF receiver by running `pilight-debug`. Remember the `pulslen` parameter. +3. Go to the `libs/pilight/protocols/433.92` subfolder of the pilight source code and open the .c file of your protocol. Search for `MIN_PULSE_LENGTH`, `MAX_PULSE_LENGTH ` and `AVG_PULSE_LENGTH`. Change the pulse lengths to match your measured one. Recompile and install pilight by re-running `$ sudo ./setup.sh`. diff --git a/source/_components/sensor.envisalink.markdown b/source/_components/sensor.envisalink.markdown index 5f42edda39f..24f6474f145 100644 --- a/source/_components/sensor.envisalink.markdown +++ b/source/_components/sensor.envisalink.markdown @@ -1,7 +1,7 @@ --- layout: page -title: "Vera Sensor" -description: "Instructions how to integrate Vera sensors into Home Assistant." +title: "Envisalink Sensor" +description: "Instructions how to integrate Envisalink sensors into Home Assistant." date: 2016-07-01 10:00 sidebar: true comments: false diff --git a/source/_components/sensor.fastdotcom.markdown b/source/_components/sensor.fastdotcom.markdown new file mode 100644 index 00000000000..ce85bb17cd2 --- /dev/null +++ b/source/_components/sensor.fastdotcom.markdown @@ -0,0 +1,46 @@ +--- +layout: page +title: "Fast.com" +description: "How to integrate Fast.com within Home Assistant." +date: 2016-08-10 17:30 +sidebar: true +comments: false +sharing: true +footer: true +logo: fastdotcom.png +ha_category: Sensor +featured: false +ha_release: 0.26 +--- + +The `fastdotcom` sensor component uses the [Fast.com](https://fast.com/) web service to measure network bandwidth performance. + +By default, it will run every hour. The user can change the update frequency in the config by defining the minute, hour, and day for a speedtest to run. + +To add a Fast.com sensor to your installation, add the following to your `configuration.yaml` file: + +Once per hour, on the hour (default): + +```yaml +sensor: + platform: fastdotcom +``` + +More examples: + +Every half hour of every day: + +```yaml +sensor: + platform: fastdotcom + minute: + - 0 + - 30 +``` +Configuration variables: + +- **minute** (*Optional*): Specify the minute(s) of the hour to schedule the speedtest. Use a list for multiple entries. Default is 0. +- **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. + +There is also a service named `sensor.update_fastdotcom` that you can use to run a fast.com speedtest on demand. diff --git a/source/_components/sensor.gpsd.markdown b/source/_components/sensor.gpsd.markdown new file mode 100644 index 00000000000..30b30223c13 --- /dev/null +++ b/source/_components/sensor.gpsd.markdown @@ -0,0 +1,58 @@ +--- +layout: page +title: "GPSD" +description: "Instructions how to integrate GPSD into Home Assistant." +date: 2016-07-18 07:00 +sidebar: true +comments: false +sharing: true +footer: true +logo: gpsd.png +ha_category: Sensor +ha_release: 0.26 +--- + +The `gpsd` component is using the GPS information collected by [gpsd](http://catb.org/gpsd/) and a GPS receiver. + +A requirement is that `gpsd` is installed (`$ sudo dnf -y install gpsd` or `$ sudo apt-get install gpsd`). `gpsd` uses the socket activation feature of systemd on recent Linux distributions for USB receivers. This means that if you plug your GPS receiver in, `gpsd` is started. Other GPS device may work too, but this was not tested. + +```bash +$ sudo systemctl status gpsdctl@ttyUSB0.service +● gpsdctl@ttyUSB0.service - Manage ttyUSB0 for GPS daemon + Loaded: loaded (/usr/lib/systemd/system/gpsdctl@.service; static; vendor preset: disabled) + Active: active (exited) since Sat 2016-07-16 09:30:33 CEST; 1 day 23h ago + Process: 5303 ExecStart=/bin/sh -c [ "$USBAUTO" = true ] && /usr/sbin/gpsdctl add /dev/%I || : (code=exited, status=0/SUCCESS) + Main PID: 5303 (code=exited, status=0/SUCCESS) + +Jul 16 09:30:33 laptop019 systemd[1]: Starting Manage ttyUSB0 for GPS daemon... +Jul 16 09:30:33 laptop019 gpsdctl[5305]: gpsd_control(action=add, arg=/dev/ttyUSB0) +Jul 16 09:30:33 laptop019 gpsdctl[5305]: reached a running gpsd +``` + +To check if your setup is working, connect to port 2947 on the host where `gpsd` is running with `telnet`. This may need adjustments to your firewall. + +```bash + +$ telnet localhost 2947 +Trying 127.0.0.1... +Connected to localhost. +Escape character is '^]'. +{"class":"VERSION","release":"3.15","rev":"3.15-2.fc23","proto_major":3,"proto_minor":11} +``` + +To setup a GPSD sensor in your installation, add the following to your `configuration.yaml` file: + +```yaml +# Example configuration.yaml entry +senosr: + - platform: gpsd + host: 127.0.0.1 + port: 2947 + name: GPS USB +``` + +Configuration variables: + +- **host** (*Optional*): The host where GPSD is running. Defaults to `localhost`. +- **port** (*Optional*): The port which GPSD is using. Defaults to 2947. +- **port** (*Optional*): Friendly name to use for the frontend. Default to GPS. diff --git a/source/_components/sensor.mqtt.markdown b/source/_components/sensor.mqtt.markdown index b64ed6d1c48..d1704a7bf07 100644 --- a/source/_components/sensor.mqtt.markdown +++ b/source/_components/sensor.mqtt.markdown @@ -61,3 +61,33 @@ sensor: value_template: {% raw %}'{{ value_json.batt }}'{% endraw %} ``` +### {% linkable_title Get temperature and humidity %} + +If you are using a DHT sensor and a NodeMCU board (esp8266), you can retrieve temperature and humidity with a MQTT sensor. A code example can be found [here](https://github.com/mertenats/open-home-automation/tree/master/ha_mqtt_sensor_dht22). A regular MQTT message from this example looks like this: + +``` +office/sensor1 + { + "temperature": 23.20, + "humidity": 43.70 + } +``` + +Then use this configuration example to extract the data from the payload: + +```yaml +# Example configuration.yml entry +sensor 1: + platform: mqtt + state_topic: 'office/sensor1' + name: 'Temperature' + unit_of_measurement: '°C' + value_template: '{{ value_json.temperature }}' + +sensor 2: + platform: mqtt + state_topic: 'office/sensor1' + name: 'Humidity' + unit_of_measurement: '%' + value_template: '{{ value_json.humidity }}' +``` diff --git a/source/_components/sensor.nzbget.markdown b/source/_components/sensor.nzbget.markdown index 89179741e25..90204ace3d4 100644 --- a/source/_components/sensor.nzbget.markdown +++ b/source/_components/sensor.nzbget.markdown @@ -8,6 +8,7 @@ comments: false sharing: true footer: true ha_category: Sensor +logo: nzbget.png ha_iot_class: "Local Polling" ha_release: 0.17 --- diff --git a/source/_components/sensor.openexchangerates.markdown b/source/_components/sensor.openexchangerates.markdown index 8041e159d56..e237b289b63 100644 --- a/source/_components/sensor.openexchangerates.markdown +++ b/source/_components/sensor.openexchangerates.markdown @@ -23,15 +23,16 @@ To enable this sensor, add the following lines to your `configuration.yaml` file ```yaml # Example configuration.yaml entry sensor: - platform: openexchangerates - api_key: your_api_key - base: USD #optional - quote: EUR - name: USDEUR #optional + - platform: openexchangerates + api_key: YOUR_API_KEY + base: USD + quote: EUR + name: USDEUR ``` Configuration variables: +- **api_key** (*Required*): API Key for [Open Exchange Rates](https://openexchangerates.org). - **name** (*Optional*): Name to use in the frontend. - **base** (*Optional*): The symbol of the base currency. Defaults to USD - **quote** (*Required*): The symbol of the quote or target currency. diff --git a/source/_components/sensor.openweathermap.markdown b/source/_components/sensor.openweathermap.markdown index 01673022dc4..0207c3cc732 100644 --- a/source/_components/sensor.openweathermap.markdown +++ b/source/_components/sensor.openweathermap.markdown @@ -50,7 +50,7 @@ Configuration variables: - **rain**: The rain volume. - **snow**: The snow volume -Details about the API are available in the [OpenWeatherMap documentation](http://bugs.openweathermap.org/projects/api/wiki). +Details about the API are available in the [OpenWeatherMap documentation](http://openweathermap.org/api). Only metric measurements are supported at the moment. diff --git a/source/_components/sensor.particulate_matter.markdown b/source/_components/sensor.particulate_matter.markdown deleted file mode 100644 index f54b03cf0a2..00000000000 --- a/source/_components/sensor.particulate_matter.markdown +++ /dev/null @@ -1,35 +0,0 @@ ---- -layout: page -title: "Particulate matter Sensor" -description: "Instructions how to integrate Particulate matter (PM) sensors within Home Assistant." -date: 2015-08-09 12:00 -sidebar: true -comments: false -sharing: true -footer: true -logo: mqtt.png -ha_category: Sensor -ha_release: 0.26 -ha_iot_class: "Local Push" ---- - - -The `serial_pm` sensor platform allows you to use your Particulate matter (PM) sensors with Home Assistant. - -To use your PM sensor in your installation, add the following to your `configuration.yaml` file: - -```yaml -# Example configuration.yml entry -sensor: - platform: serial_pm - serial_device: /dev/tty.SLAB_USBtoUART - name: Nova - brand: novafitness -``` - -Configuration variables: - -- **serial_device** (*Required*): The port where the sensor is connected. -- **name** (*Optional*): The name of the sensor. -- **brand** (*Required*): The type or brand of the sensor. - diff --git a/source/_components/sensor.serial_pm.markdown b/source/_components/sensor.serial_pm.markdown new file mode 100644 index 00000000000..de4a7f5302f --- /dev/null +++ b/source/_components/sensor.serial_pm.markdown @@ -0,0 +1,42 @@ +--- +layout: page +title: "Particulate matter Sensor" +description: "Instructions on how to integrate particulate matter (dust) sensors with Home Assistant." +date: 2016-08-11 12:00 +sidebar: true +comments: false +sharing: true +footer: true +ha_category: DIY +ha_release: 0.26 +--- + +Particulate matter sensors measure the amount of very small particles in the air. A short introduction how these sensors work can be found on [Open Home Automation](https://www.open-homeautomation.com/2016/07/19/measuring-air-quality/). + +Cheap LED based sensors usually use a GPIO interface that is hard to attach to computers. However, there are a lot of laser LED based sensors on the market that use a serial interface and can be [connected to your Home Assistant system easily with an USB to serial converter](https://www.open-homeautomation.com/2016/07/20/connecting-an-particulate-matter-sensor-to-your-pc-or-mac/). + +At this time, the following sensors are supported: + +* oneair,s3 +* novafitness,sds021 +* novafitness,sds011 +* plantower,pms1003 +* plantower,pms5003 +* plantower,pms7003 +* plantower,pms2003 +* plantower,pms3003 + +To use your PM sensor in your installation, add the following to your `configuration.yaml` file: + +```yaml +sensor: + - platform: serial_pm + serial_device: /dev/tty.SLAB_USBtoUART + name: Nova + brand: novafitness,sds011 +``` + +- **serial_device** (*Required*): The serial port to use. On *nix systems, it can often be identified by `$ ls /dev/tty*` +- **name** (*Optional*): The name displayed in the frontend. +- **brand** (*Required*): Manufacturer and type of the sensor. + diff --git a/source/_components/sensor.systemmonitor.markdown b/source/_components/sensor.systemmonitor.markdown index bfab57abd1d..c3aec6419d8 100644 --- a/source/_components/sensor.systemmonitor.markdown +++ b/source/_components/sensor.systemmonitor.markdown @@ -9,6 +9,7 @@ sharing: true footer: true ha_category: Sensor ha_release: pre 0.7 +ha_iot_class: "Local Push" --- The `systemmonitor` sensor platform to allow you to monitor disk usage, memory usage, CPU usage, and running processes. This platform has superseded the process component which is now considered deprecated. @@ -18,12 +19,12 @@ To add this platform to your installation, add the following to your `configurat ```yaml # Example configuration.yaml entry sensor: - platform: systemmonitor - resources: - - type: disk_use_percent - arg: /home - - type: memory_free - - type: processor_use + - platform: systemmonitor + resources: + - type: disk_use_percent + arg: /home + - type: memory_free + - type: processor_use ``` Configuration variables: @@ -34,7 +35,7 @@ Configuration variables: The table contains types and their argument to use in your `configuration.yaml` file. -| Type (`- type:`) | Argument (`arg:`) | +| Type (`type:`) | Argument (`arg:`) | | :------------------ |:-------------------------| | disk_use_percent | Path, eg. `/` | | disk_use | Path, eg. `/` | diff --git a/source/_components/sensor.template.markdown b/source/_components/sensor.template.markdown index 70f56d15e56..59ff3813524 100644 --- a/source/_components/sensor.template.markdown +++ b/source/_components/sensor.template.markdown @@ -18,14 +18,14 @@ To enable Template sensors in your installation, add the following to your `conf ```yaml # Example configuration.yaml entry sensor: - platform: template - sensors: - solar_angle: - value_template: {% raw %}'{{ states.sun.sun.attributes.elevation }}'{% endraw %} - friendly_name: 'Sun angle' - unit_of_measurement: 'degrees' - sunrise: - value_template: {% raw %}'{{ states.sun.sun.attributes.next_rising }}'{% endraw %} + - platform: template + sensors: + solar_angle: + value_template: {% raw %}'{{ states.sun.sun.attributes.elevation }}'{% endraw %} + friendly_name: 'Sun angle' + unit_of_measurement: 'degrees' + sunrise: + value_template: {% raw %}'{{ states.sun.sun.attributes.next_rising }}'{% endraw %} ``` Configuration variables: @@ -34,8 +34,7 @@ Configuration variables: - **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](/topics/templating/) to extract a value from the payload. - - **warnings** (*Optional*): Turn off warnings (useful if the sensor is loaded before devices it depends on). - - **entity_id** (*Optional*): Add a list of entity_ids so the sensor only reacts to state changes of these entities. This will reduce the number of times the sensor will try to update it's state. + - **entity_id** (*Optional*): Add a list of entity IDs so the sensor only reacts to state changes of these entities. This will reduce the number of times the sensor will try to update it's state. ## {% linkable_title Examples %} @@ -48,12 +47,12 @@ This example shows the sun angle in the frontend. ```yaml sensor: - platform: template - sensors: - solar_angle: - value_template: {% raw %}'{{ "%+.1f"|format(states.sun.sun.attributes.elevation) }}'{% endraw %} - friendly_name: 'Sun Angle' - unit_of_measurement: '°' + - platform: template + sensors: + solar_angle: + value_template: {% raw %}'{{ "%+.1f"|format(states.sun.sun.attributes.elevation) }}'{% endraw %} + friendly_name: 'Sun Angle' + unit_of_measurement: '°' ``` ### {% linkable_title Renaming sensor output %} @@ -62,22 +61,22 @@ If you don't like the wording of a sensor output then the template sensor can he ```yaml sensor: - platform: template - sensors: - sun_state: - value_template: {% raw %}'{% if is_state("sun.sun", "above_horizon") %}up{% else %}down{% endif %}'{% endraw %} - friendly_name: 'Sun state' + - platform: template + sensors: + sun_state: + value_template: {% raw %}'{% if is_state("sun.sun", "above_horizon") %}up{% else %}down{% endif %}'{% endraw %} + friendly_name: 'Sun state' ``` Processes monitored by the [System Monitor sensor](/components/sensor.systemmonitor/) show `on` or `off` if they are running or not. This example shows how the output of a monitored `glances` process can be renamed. ```yaml sensor: - platform: template - sensors: - glances: - value_template: {% raw %}'{% if is_state("sensor.process_glances", "off") %}not running{% else %}running{% endif %}'{% endraw %} - friendly_name: 'Glances' + - platform: template + sensors: + glances: + value_template: {% raw %}'{% if is_state("sensor.process_glances", "off") %}not running{% else %}running{% endif %}'{% endraw %} + friendly_name: 'Glances' ``` By comparing the details published on the [template](/topics/templating/) page the same can be archived with a different approach: @@ -88,31 +87,34 @@ value_template: {% raw %}"{%if states.sensor.ENTITY_ID.state == 'on' %}running{% The [Binary template sensor](/components/binary_sensor.template/) is the one in similar cases if you prefer to see an icon instead of text. -### {% linkable_title Multiline example with an if test (and warnings disabled) %} +### {% linkable_title Multiline example with an if test %} -This example shows a multiple line template with and if test. It looks at a sensing switch and shows on/off in the frontend. It disables warnings to avoid log messages where the switch it depends on isn't loaded yet. +This example shows a multiple line template with and if test. It looks at a sensing switch and shows on/off in the frontend. ```yaml sensor: - platform: template - sensors: - kettle: - friendly_name: 'Kettle' - {% raw %}value_template: >- - {%- if is_state("switch.kettle", "off") %} - off - {% elif states.switch.kettle.attributes.kwh < 1000 %} - standby - {% elif is_state("switch.kettle", "on") %} - on - {% else %} - failed - {%- endif %}{% endraw %} + - platform: template + sensors: + kettle: + friendly_name: 'Kettle' + {% raw %}value_template: >- + {%- if is_state("switch.kettle", "off") %} + off + {% elif states.switch.kettle.attributes.kwh < 1000 %} + standby + {% elif is_state("switch.kettle", "on") %} + on + {% else %} + failed + {%- endif %}{% endraw %} - warnings: Off + next_sensor: + [...] ``` -(please note the blank line to close the multi-line template) ++Please note the blank line to close the multi-line template. +
### {% linkable_title Change the unit of measurment %} @@ -120,15 +122,15 @@ With a template sensor it's easy to convert given values into others if the unit ```yaml sensor: - platform: template - sensors: - transmission_down_speed_kbps: - value_template: {% raw %}'{{ states.sensor.transmission_down_speed.state | multiply(1024) }}'{% endraw %} - friendly_name: 'Transmission Down Speed' - unit_of_measurement: 'kB/s' - transmission_up_speed_kbps: - value_template: {% raw %}'{{ states.sensor.transmission_up_speed.state | multiply(1024) }}'{% endraw %} - friendly_name: 'Transmission Up Speed' - unit_of_measurement: 'kB/s' + - platform: template + sensors: + transmission_down_speed_kbps: + value_template: {% raw %}'{{ states.sensor.transmission_down_speed.state | multiply(1024) }}'{% endraw %} + friendly_name: 'Transmission Down Speed' + unit_of_measurement: 'kB/s' + transmission_up_speed_kbps: + value_template: {% raw %}'{{ states.sensor.transmission_up_speed.state | multiply(1024) }}'{% endraw %} + friendly_name: 'Transmission Up Speed' + unit_of_measurement: 'kB/s' ``` diff --git a/source/_components/sensor.zigbee.markdown b/source/_components/sensor.zigbee.markdown index 45a58641aca..58d436ccd27 100644 --- a/source/_components/sensor.zigbee.markdown +++ b/source/_components/sensor.zigbee.markdown @@ -11,30 +11,45 @@ logo: zigbee.png ha_category: Sensor --- -There are two types of ZigBee sensor available to Home Assistant: +There are two types of [ZigBee](http://www.zigbee.org/) sensor available to Home Assistant: - [Analog input pin](#analog-input-pin) - [Temperature sensor](#temperature-sensor) (XBee Pro) -## {% linkable_title Analog Input Pin %} - -The analog input pins on an XBee (non-Pro) will read 0V to 1.2V. This is translated by the [xbee-helper](https://github.com/flyte/xbee-helper) library into a percentage. The maximum voltage your ZigBee device will read is configurable using the `max_volts` configuration variable. - -To configure an analog input pin sensor, use the following variables: - -- **name** (*Required*): The name you'd like to give the sensor in Home Assistant. -- **platform** (*Required*): Set to `zigbee`. -- **type** (*Required*): Set to `analog`. -- **pin** (*Required*): The number identifying which pin to sample. -- **address**: The long 64bit address of the remote ZigBee device whose analog input pin you'd like to sample. Do not include this variable if you want to sample the local ZigBee device's pins. -- **max_volts**: The maximum voltage which the analog input pin is able to read. Default: `1.2` - -#### Example +To configure an analog input pin sensor, add the following to your `configuration.yaml` file: ```yaml +# Example configuration.yaml entry sensor: - - name: My Analog Input - platform: zigbee + - platform: zigbee + name: My Analog ZigBee Input + type: analog + pin: 0 + address: 0013A2004233D138 +``` + +Configuration variables: + +- **name** (*Required*): The name you would like to give the sensor in Home Assistant. +- **type** (*Required*): Set to `analog` or `temperature`. +- **pin** (*Required*): The number identifying which pin to sample +- **address** (*Optional*): The long 64 bit address of the remote ZigBee device whose pin you would like to sample. Do not include this variable if you want to sample the local ZigBee device's pins. +- **max_volts** (*Optional*): The maximum voltage which the input pin is able to read. Defaults to `1.2` + + +## {% linkable_title Examples %} + +### {% linkable_title Analog Input Pin %} + +The analog input pins on an XBee (non-Pro) will read 0V to 1.2 V. This is translated by the [xbee-helper](https://github.com/flyte/xbee-helper) library into a percentage. The maximum voltage your ZigBee device will read is configurable using the `max_volts` configuration variable. + +To configure an analog input pin sensor, add the following to your `configuration.yaml` file: + +```yaml +## Example configuration.yaml entry +sensor: + - platform: zigbee + name: My Analog ZigBee Input type: analog pin: 0 address: 0013A2004233D138 @@ -44,19 +59,16 @@ See the [Digi knowledge base](http://knowledge.digi.com/articles/Knowledge_Base_ ## {% linkable_title Temperature Sensor %} -The XBee Pro (and perhaps other third party modules) contains a thermometer device which can be read by using the `TP` AT command. To set this up as a temperature sensor device in Home Assistant use the following config variables: +The XBee Pro (and perhaps other third party modules) contains a thermometer device which can be read by using the `TP` AT command. -- **name** (*Required*): The name you'd like to give the temperature sensor in Home Assistant -- **platform** (*Required*): Set to `zigbee` -- **type** (*Required*): Set to `temperature` -- **address**: The long 64bit address of the remote ZigBee device whose temperature sensor you'd like to sample. Do not include this variable if you want to sample the local ZigBee device's temperature. - -#### Example +To configure a temperature sensor device, add the following to your `configuration.yaml` file: ```yaml +# Example configuration.yaml entry sensor: - - name: Living Room Temperature - platform: zigbee + - platform: zigbee + name: Living Room Temperature ZigBee type: temperature address: 0013A20050E752C5 -``` \ No newline at end of file +``` + diff --git a/source/_components/switch.flux.markdown b/source/_components/switch.flux.markdown index b78679e6693..18604e9df07 100644 --- a/source/_components/switch.flux.markdown +++ b/source/_components/switch.flux.markdown @@ -19,7 +19,7 @@ During the day (in between `start time` and `sunset time`), it will fade the lig If you don't wish to have flux update on 30 second intervals, you can leave the switch turned off and use automation rules that call the service `switch.flux_update` whenever you want the lights updated. -To use your TPLink switch in your installation, add the following to your `configuration.yaml` file: +To use the Flux switch in your installation, add the following to your `configuration.yaml` file: ```yaml # Example configuration.yaml entry diff --git a/source/_components/switch.pilight.markdown b/source/_components/switch.pilight.markdown new file mode 100644 index 00000000000..a5d78561509 --- /dev/null +++ b/source/_components/switch.pilight.markdown @@ -0,0 +1,63 @@ +--- +layout: page +title: "Pilight Switch" +description: "Instructions how to have switches using 433 MHz connected to a computer running pilight." +date: 2015-06-10 22:41 +sidebar: true +comments: false +sharing: true +footer: true +logo: pilight.png +ha_category: Switch +ha_release: pre 0.7 +--- + + +A switch platform that issues 433 MHz commands using [pilight](https://www.pilight.org/) to turn a 433 MHz device on or off. The pilight HA hub has to be set up. + +Additionally RF commands can be defined that trigger this switch to turn on and off. This allows you to also use the remote shipped with your 433 MHz switch without mixing up the HA states. You can even define several on/off commands, thus several RF remotes to toggle this switch. + +To be really sure that HA knows the actual state of your device it is recommended to use the RF remote with codes unknown to any of your 433 MHz devices. Thus you use the remote to trigger this switch to send the correct RF code to the device. + +To define a pilight switch, add the following lines to your `configuration.yaml`: + +```yaml +# Example configuration.yaml entry +switch: + platform: pilight + switches: + Bed light: + on_code: + protocol: intertechno_old # protocol has to be defined + unit: 3 # these entries are protocol specific and can differ + id: 4 # these entries are protocol specific and can differ + 'on': 1 # on has to be in apostrophes to be parsed correctly + off_code: + protocol: intertechno_old # protocol has to be defined + unit: 3 # these entries are protocol specific and can differ + id: 4 # these entries are protocol specific and can differ + 'off': 1 # off has to be in apostrophes to be parsed correctly + on_code_receive: # optional + protocol: daycom # protocol has to be defined + systemcode: 14462 # these entries are protocol specific and can differ + unit: 6 # these entries are protocol specific and can differ + id: 34 # these entries are protocol specific and can differ + state: 'on' # off has to be in apostrophes to be parsed correctly + off_code_receive: # optional + protocol: daycom # protocol has to be defined + systemcode: 14462 # these entries are protocol specific and can differ + unit: 6 # these entries are protocol specific and can differ + id: 34 # these entries are protocol specific and can differ + state: 'off' # on has to be in apostrophes to be parsed correctly +``` + +Configuration variables: + +- **switches** (*Required*): The array that contains all command switches. + - **entry** (*Required*): Name of the command switch. Multiple entries are possible. + - **on_code** (*Required*): The code to turn the device on. + - **off_code** (*Required*): The code to turn the device off. + - **on_code_receive** (*Optional*): If given, this command will turn the switch on if it is received by pilight. + - **off_code_receive** (*Optional*): If given, this command will turn the switch off if it is received by pilight. + +For possible code entries look at the [pilight API](https://www.pilight.org/development/api/). All commands allowed by [pilight-send](https://wiki.pilight.org/doku.php/psend) can be used. \ No newline at end of file diff --git a/source/_components/switch.template.markdown b/source/_components/switch.template.markdown index 7ddf487bf16..256c34fa5a3 100644 --- a/source/_components/switch.template.markdown +++ b/source/_components/switch.template.markdown @@ -22,17 +22,17 @@ To enable Template switches in your installation, add the following to your `con ```yaml # Example configuration.yaml entry switch: - platform: template + - platform: template switches: - skylight: - friendly_name: 'Skylight' - value_template: {% raw %}'{{ states.sensor.skylight.state }}'{% endraw %} - turn_on: - service: switch.turn_on - entity_id: switch.skylight_open - turn_off: - service: switch.turn_on - entity_id: switch.skylight_close + skylight: + friendly_name: 'Skylight' + value_template: {% raw %}'{{ is_state('sensor.skylight', 'on') }}'{% endraw %} + turn_on: + service: switch.turn_on + entity_id: switch.skylight_open + turn_off: + service: switch.turn_on + entity_id: switch.skylight_close ``` Configuration variables: @@ -42,7 +42,13 @@ Configuration variables: - **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. - - **entity_id** (*Optional*): Add a list of entity_ids so the sensor only reacts to state changes of these entities. This will reduce the number of times the sensor will try to update it's state. + - **entity_id** (*Optional*): Add a list of entity IDs so the switch only reacts to state changes of these entities. This will reduce the number of times the switch will try to update it's state. + + +## {% linkable_title Considerations %} + +If you are using the state of a platform that takes extra time to load, the template switch may get an 'unknown' state during startup. This results in error messages in your log file until that platform has completed loading. If you use is_state() function in your template, you can avoid this situation. For example, you would replace {% raw %}'{{ states.switch.source.state }}'{% endraw %} with this equivalent that returns true/false and never gives an unknown result: +{% raw %}'{{ is_state('switch.source', 'on') }}'{% endraw %} ## {% linkable_title Examples %} @@ -54,16 +60,16 @@ This example shows a switch that copies another switch. ```yaml switch: - platform: template + - platform: template switches: - copy: - value_template: {% raw %}'{{ states.switch.source.state }}'{% endraw %} - turn_on: - service: switch.turn_on - entity_id: switch.source - turn_off: - service: switch.turn_off - entity_id: switch.source + copy: + value_template: {% raw %}'{{ is_state('switch.source', 'on') }}'{% endraw %} + turn_on: + service: switch.turn_on + entity_id: switch.source + turn_off: + service: switch.turn_off + entity_id: switch.source ```` ### {% linkable_title Toggle switch %} @@ -72,17 +78,17 @@ This example shows a switch that takes its state from a sensor, and toggles a sw ```yaml switch: - platform: template + - platform: template switches: - blind: - friendly_name: 'Blind' - value_template: {% raw %}'{{ state }}'{% endraw %} - turn_on: - service: switch.toggle - entity_id: switch.blind_toggle - turn_off: - service: switch.toggle - entity_id: switch.blind_toggle + blind: + friendly_name: 'Blind' + value_template: {% raw %}'{{ state }}'{% endraw %} + turn_on: + service: switch.toggle + entity_id: switch.blind_toggle + turn_off: + service: switch.toggle + entity_id: switch.blind_toggle ``` ### {% linkable_title Sensor and two switches %} @@ -91,15 +97,16 @@ This example shows a switch that takes its state from a sensor, and uses two mom ```yaml switch: - platform: template + - platform: template switches: - skylight: - friendly_name: 'Skylight' - value_template: {% raw %}'{{ states.sensor.skylight.state }}'{% endraw %} - turn_on: - service: switch.turn_on - entity_id: switch.skylight_open - turn_off: - service: switch.turn_on - entity_id: switch.skylight_close + skylight: + friendly_name: 'Skylight' + value_template: {% raw %}'{{ is_state('sensor.skylight.state', 'on') }}'{% endraw %} + turn_on: + service: switch.turn_on + entity_id: switch.skylight_open + turn_off: + service: switch.turn_on + entity_id: switch.skylight_close ``` + diff --git a/source/_components/thermostat.heat_control.markdown b/source/_components/thermostat.heat_control.markdown index 1ec08330364..4b70cf0649b 100644 --- a/source/_components/thermostat.heat_control.markdown +++ b/source/_components/thermostat.heat_control.markdown @@ -23,6 +23,13 @@ thermostat: min_temp: 15 max_temp: 21 target_temp: 15 + min_cycle_duration: + # At least one of these must be specified: + days: 2 + hours: 1 + minutes: 10 + seconds: 5 + milliseconds: 20 ``` Configuration variables: @@ -34,3 +41,4 @@ Configuration variables: - **max_temp** (*Optional*): Set maximum set point available (default: 35) - **target_temp** (*Required*): Set intital target temperature. Failure to set this variable will result in target temperature being set to null on startup. - **ac_mode** (*Optional*): Set the switch specified in the *heater* option to be treated as a cooling device instead of a heating device. +- **min_cycle_duration** (*Optional*): Set a minimum amount of time that the switch specified in the *heater* option must be in it's current state prior to being switched either off or on. diff --git a/source/_cookbook/custom_panel_using_react.markdown b/source/_cookbook/custom_panel_using_react.markdown index 552eff7c219..a3d8911e88e 100644 --- a/source/_cookbook/custom_panel_using_react.markdown +++ b/source/_cookbook/custom_panel_using_react.markdown @@ -18,19 +18,18 @@ This is a [React](https://facebook.github.io/react/) implementation of [TodoMVC] - It uses the user configuration for the component in the `configuration.yaml` file for rendering. - It allows toggling the sidebar. -All you need is available as a [custom component](https://github.com/home-assistant/home-assistant/tree/dev/config/custom_components/react_panel). +All you need is available as a [custom panel](https://github.com/home-assistant/home-assistant/tree/master/config/panels/react.html). Download the file and save it in `
+
+ Block diagram of schematic
+
+
+ Graph showing the accelerometer data
+
+
+ Status of the dryer and washer in Home Assistant
+
+
+
+
+ NodeMCU connected to MPU-6050 accelerometer.
+
+
+
+
+
+
+
+
+
+
Call a service from a component.
Fire an event on the event bus.
Set the representation of a device within Home Assistant.
This will not communicate with the actual device.
Templates are rendered using the Jinja2 template engine with some Home Assistant specific extensions.
[[processed]]
Developed by a bunch of awesome people.
Published under the MIT license
Source: server — frontend-ui — frontend-core
Built using Python 3, Polymer [[polymerVersion]], NuclearJS [[nuclearVersion]]
Icons by Google and MaterialDesignIcons.com.
The following errors have been logged this session: