Update var description (#1834)

* Update var description

* Update description
This commit is contained in:
Fabian Affolter 2017-01-24 19:54:54 +01:00 committed by GitHub
parent 6c3df542ae
commit fa0ca7f802
2 changed files with 13 additions and 13 deletions

View File

@ -10,6 +10,7 @@ footer: true
logo: arest.png logo: arest.png
ha_category: Sensor ha_category: Sensor
ha_iot_class: "Local Polling" ha_iot_class: "Local Polling"
ha_release: pre 0.7
--- ---
@ -19,8 +20,9 @@ To use your aREST enabled device in your installation, add the following to your
```yaml ```yaml
# Example configuration.yaml entry # Example configuration.yaml entry
sensor:
- platform: arest - platform: arest
resource: http://10.100.0.117 resource: http://IP_ADDRESS
monitored_variables: monitored_variables:
temperature: temperature:
name: temperature name: temperature
@ -34,13 +36,15 @@ Configuration variables:
- **resource** (*Required*): IP address and schema of the device that is exposing an aREST API, e.g. http://192.168.1.10. - **resource** (*Required*): IP address and schema of the device that is exposing an aREST API, e.g. http://192.168.1.10.
- **name** (*Optional*): Let you overwrite the the name of the device. By default *name* from the device is used. - **name** (*Optional*): Let you overwrite the the name of the device. By default *name* from the device is used.
- **monitored_variables** array (*Optional*): List of exposed variables. - **monitored_variables** array (*Optional*): List of exposed variables.
- **name** (*Required*): The name of the variable you wish to monitor. - **[variable]** (*Required*): Name of the variable to monitor.
- **unit_of_measurement** (*Optional*): Defines the units of measurement of the sensor, if any. - **name** (*Optional*): The name to use for the frontend.
- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload. - **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.
- **pins** array (*Optional*): List of pins to monitor. Analog pins need a leading **A** for the pin number. - **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. - **[pin]** (*Required*): Pin number to use.
- **unit_of_measurement** (*Optional*): Defines the unit of measurement of the sensor, if any. - **name** (*Required*): The name of the variable you wish to monitor.
- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload. - **unit_of_measurement** (*Optional*): Defines the unit of measurement of the sensor, if any.
- **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. 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.

View File

@ -25,8 +25,6 @@ switch:
pins: pins:
11: 11:
name: Fan name: Fan
12:
name: Light Desk
``` ```
If you want to use custom functions, then add the following to your `configuration.yaml` file: If you want to use custom functions, then add the following to your `configuration.yaml` file:
@ -39,8 +37,6 @@ switch:
name: Office name: Office
functions: functions:
function1: function1:
name:
function2:
name: Light Desk name: Light Desk
``` ```
@ -48,12 +44,12 @@ Configuration variables:
- **resource** (*Required*): IP address and schema of the device that is exposing an aREST API, eg. http://192.168.1.10 (no-trailing slash) - **resource** (*Required*): IP address and schema of the device that is exposing an aREST API, eg. http://192.168.1.10 (no-trailing slash)
- **name** (*Optional*): Let you overwrite the the name of the device. By default *name* from the device is used. - **name** (*Optional*): Let you overwrite the the name of the device. By default *name* from the device is used.
- **pins** array (*Required*): An array with all used pins. - **pins** array (*Optional*): An array with all used pins.
- **name** (*Required*): The name of the pin to use in the frontend. - **name** (*Required*): The name of the pin to use in the frontend.
or or
- **functions** array (*Required*): An array with all used functions. - **functions** array (*Optional*): An array with all used functions.
- **name** (*Required*): The name to use in the frontend. - **name** (*Required*): The name to use in the frontend.
You can still switch your pins with a web browser or a command line tool. Use the URL http://192.168.1.10/digital/8/1 to set pin 8 to high/on, the JSON response will give you the feedback. You can still switch your pins with a web browser or a command line tool. Use the URL http://192.168.1.10/digital/8/1 to set pin 8 to high/on, the JSON response will give you the feedback.