From 0bafa43055403a163879ffc541e1d66a48773afa Mon Sep 17 00:00:00 2001 From: Otto Winter Date: Fri, 1 Jun 2018 18:44:15 +0200 Subject: [PATCH] Add update_interval note --- esphomeyaml/components/dallas.rst | 2 +- esphomeyaml/components/sensor/adc.rst | 2 +- esphomeyaml/components/sensor/ads1115.rst | 2 ++ esphomeyaml/components/sensor/bh1750.rst | 2 +- esphomeyaml/components/sensor/bme280.rst | 2 +- esphomeyaml/components/sensor/bme680.rst | 2 +- esphomeyaml/components/sensor/bmp085.rst | 2 +- esphomeyaml/components/sensor/dht.rst | 2 +- esphomeyaml/components/sensor/dht12.rst | 1 + esphomeyaml/components/sensor/hdc1080.rst | 1 + esphomeyaml/components/sensor/htu21d.rst | 1 + esphomeyaml/components/sensor/index.rst | 17 +++++++++++++++++ esphomeyaml/components/sensor/max6675.rst | 1 + esphomeyaml/components/sensor/mpu6050.rst | 1 + esphomeyaml/components/sensor/pulse_counter.rst | 1 + esphomeyaml/components/sensor/sht3xd.rst | 2 +- esphomeyaml/components/sensor/template.rst | 2 +- esphomeyaml/components/sensor/tsl2561.rst | 2 +- esphomeyaml/components/sensor/ultrasonic.rst | 2 +- esphomeyaml/index.rst | 2 ++ 20 files changed, 38 insertions(+), 11 deletions(-) diff --git a/esphomeyaml/components/dallas.rst b/esphomeyaml/components/dallas.rst index 558693333..8ffe08df0 100644 --- a/esphomeyaml/components/dallas.rst +++ b/esphomeyaml/components/dallas.rst @@ -28,7 +28,7 @@ Configuration variables: - **pin** (**Required**, number): The pin the sensor bus is connected to. - **update_interval** (*Optional*, :ref:`config-time`): The interval that the sensors should be checked. - Defaults to 15 seconds. + Defaults to 15 seconds. See :ref:`sensor-default_filter`. - **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation. See Also diff --git a/esphomeyaml/components/sensor/adc.rst b/esphomeyaml/components/sensor/adc.rst index 2c25f95a5..6d95ee3c5 100644 --- a/esphomeyaml/components/sensor/adc.rst +++ b/esphomeyaml/components/sensor/adc.rst @@ -27,7 +27,7 @@ Configuration variables: - **attenuation** (*Optional*): Only on ESP32. Specify the ADC attenuation to use. See :ref:`adc-esp32_attenuation`. - **update_interval** (*Optional*, :ref:`config-time`): The interval - to check the sensor. Defaults to ``15s``. + to check the sensor. Defaults to ``15s``. See :ref:`sensor-default_filter`. - **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation. - All other options from :ref:`Sensor ` and :ref:`MQTT Component `. diff --git a/esphomeyaml/components/sensor/ads1115.rst b/esphomeyaml/components/sensor/ads1115.rst index 09354daf0..6eab105e1 100644 --- a/esphomeyaml/components/sensor/ads1115.rst +++ b/esphomeyaml/components/sensor/ads1115.rst @@ -45,6 +45,8 @@ Configuration variables: - **name** (**Required**, string): The name for this sensor. - **ads1115_id** (*Optional*, :ref:`config-id`): Manually specify the ID of the :doc:`ADS1115 Hub ` you want to use this sensor. +- **update_interval** (*Optional*, :ref:`config-time`): The interval + to check the sensor. Defaults to ``15s``. See :ref:`sensor-default_filter`. - **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation. Multiplexer And Gain diff --git a/esphomeyaml/components/sensor/bh1750.rst b/esphomeyaml/components/sensor/bh1750.rst index cac741813..ee9960f28 100644 --- a/esphomeyaml/components/sensor/bh1750.rst +++ b/esphomeyaml/components/sensor/bh1750.rst @@ -34,7 +34,7 @@ Configuration variables: - **resolution** (*Optional*, string): The resolution of the sensor in lx. One of ``4.0``, ``1.0``, ``0.5``. Defaults to ``0.5`` (the maximum resolution). - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the - sensor. Defaults to ``15s``. + sensor. Defaults to ``15s``. See :ref:`sensor-default_filter`. - **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation. - All other options from :ref:`Sensor ` and :ref:`MQTT Component `. diff --git a/esphomeyaml/components/sensor/bme280.rst b/esphomeyaml/components/sensor/bme280.rst index d5df1d317..cf65631fe 100644 --- a/esphomeyaml/components/sensor/bme280.rst +++ b/esphomeyaml/components/sensor/bme280.rst @@ -64,7 +64,7 @@ Configuration variables: - **iir_filter** (*Optional*): Set up an Infinite Impulse Response filter to increase accuracy. One of ``OFF``, ``2x``, ``4x``, ``16x``. Defaults to ``OFF``. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the - sensor. Defaults to ``15s``. + sensor. Defaults to ``15s``. See :ref:`sensor-default_filter`. .. _bme280-oversampling: diff --git a/esphomeyaml/components/sensor/bme680.rst b/esphomeyaml/components/sensor/bme680.rst index d54b7ddb3..c4b54bb98 100644 --- a/esphomeyaml/components/sensor/bme680.rst +++ b/esphomeyaml/components/sensor/bme680.rst @@ -75,7 +75,7 @@ Configuration variables: - **iir_filter** (*Optional*): Set up an Infinite Impulse Response filter to increase accuracy. One of ``OFF``, ``2x``, ``4x``, ``16x``. Defaults to ``OFF``. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the - sensor. Defaults to ``15s``. + sensor. Defaults to ``15s``. See :ref:`sensor-default_filter`. .. _bme680-oversampling: diff --git a/esphomeyaml/components/sensor/bmp085.rst b/esphomeyaml/components/sensor/bmp085.rst index 044ee7482..ca01c1036 100644 --- a/esphomeyaml/components/sensor/bmp085.rst +++ b/esphomeyaml/components/sensor/bmp085.rst @@ -51,7 +51,7 @@ Configuration variables: - **address** (*Optional*, int): Manually specify the i^2c address of the sensor. Defaults to ``0x77``. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the - sensor. Defaults to ``15s``. + sensor. Defaults to ``15s``. See :ref:`sensor-default_filter`. See Also ^^^^^^^^ diff --git a/esphomeyaml/components/sensor/dht.rst b/esphomeyaml/components/sensor/dht.rst index 2f14fa465..9c5ca6d5c 100644 --- a/esphomeyaml/components/sensor/dht.rst +++ b/esphomeyaml/components/sensor/dht.rst @@ -57,7 +57,7 @@ Configuration variables: one of ``AUTO_DETECT``, ``DHT11``, ``DHT22``, ``AM2303``, ``RHT03`` and helps with some connection issues. Defaults to ``AUTO_DETECT``. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the - sensor. Defaults to ``15s``. + sensor. Defaults to ``15s``. See :ref:`sensor-default_filter`. .. note:: diff --git a/esphomeyaml/components/sensor/dht12.rst b/esphomeyaml/components/sensor/dht12.rst index 864bad742..7aac19bde 100644 --- a/esphomeyaml/components/sensor/dht12.rst +++ b/esphomeyaml/components/sensor/dht12.rst @@ -45,6 +45,7 @@ Configuration variables: - All other options from :ref:`Sensor ` and :ref:`MQTT Component `. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the sensor. Defaults to ``15s``. + See :ref:`sensor-default_filter`. See Also ^^^^^^^^ diff --git a/esphomeyaml/components/sensor/hdc1080.rst b/esphomeyaml/components/sensor/hdc1080.rst index bcff7251c..0aedf7cd3 100644 --- a/esphomeyaml/components/sensor/hdc1080.rst +++ b/esphomeyaml/components/sensor/hdc1080.rst @@ -47,6 +47,7 @@ Configuration variables: - All other options from :ref:`Sensor ` and :ref:`MQTT Component `. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the sensor. Defaults to ``15s``. + See :ref:`sensor-default_filter`. Currently, the platform doesn’t support activating the built-in heater, as it seems to only be rarely of use. If you need it, please open an diff --git a/esphomeyaml/components/sensor/htu21d.rst b/esphomeyaml/components/sensor/htu21d.rst index be3cec119..c59aa4297 100644 --- a/esphomeyaml/components/sensor/htu21d.rst +++ b/esphomeyaml/components/sensor/htu21d.rst @@ -47,6 +47,7 @@ Configuration variables: - All other options from :ref:`Sensor ` and :ref:`MQTT Component `. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the sensor. Defaults to ``15s``. + See :ref:`sensor-default_filter`. See Also ^^^^^^^^ diff --git a/esphomeyaml/components/sensor/index.rst b/esphomeyaml/components/sensor/index.rst index 29fca86f2..25960cda0 100644 --- a/esphomeyaml/components/sensor/index.rst +++ b/esphomeyaml/components/sensor/index.rst @@ -162,6 +162,23 @@ fahrenheit. - lambda: x * (9.0/5.0) + 32.0 unit_of_measurement: "°F" +.. _sensor-default_filter: + +Default Filter +^^^^^^^^^^^^^^ + +By default, esphomelib takes an average over the last 15 values before publishing updates. +This was done in order to automatically decrease sensor noise. +Therefore if you have an ``update_interval`` of 15 seconds, you will only see the values +every 3 and a half minutes or so. To disable the default filter and publish all raw values +directly, put an empty ``filters:`` block in your configuration: + +.. code:: yaml + + sensor: + - platform: ... + filters: + Sensor Automation ^^^^^^^^^^^^^^^^^ diff --git a/esphomeyaml/components/sensor/max6675.rst b/esphomeyaml/components/sensor/max6675.rst index 043387ac7..13c91bc88 100644 --- a/esphomeyaml/components/sensor/max6675.rst +++ b/esphomeyaml/components/sensor/max6675.rst @@ -39,6 +39,7 @@ Configuration variables: - **pin_clock** (**Required**): The Clock pin of the SPI interface. - **pin_miso** (**Required**): The Master-In/Slave-Out pin of the SPI interface. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the sensor. Defaults to ``15s``. + See :ref:`sensor-default_filter`. - **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for codegeneration. - All other options from :ref:`Sensor ` and :ref:`MQTT Component `. diff --git a/esphomeyaml/components/sensor/mpu6050.rst b/esphomeyaml/components/sensor/mpu6050.rst index 31cc63cfa..88b0cf75a 100644 --- a/esphomeyaml/components/sensor/mpu6050.rst +++ b/esphomeyaml/components/sensor/mpu6050.rst @@ -65,6 +65,7 @@ Configuration variables: - **temperature** (*Optional*): Use the internal temperature of the sensor. All options from :ref:`Sensor ` and :ref:`MQTT Component `. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the sensor. Defaults to ``15s``. + See :ref:`sensor-default_filter`. - **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation. See Also diff --git a/esphomeyaml/components/sensor/pulse_counter.rst b/esphomeyaml/components/sensor/pulse_counter.rst index 8807fa826..d53963c04 100644 --- a/esphomeyaml/components/sensor/pulse_counter.rst +++ b/esphomeyaml/components/sensor/pulse_counter.rst @@ -43,6 +43,7 @@ Configuration variables: Pulses `__ for more information. Defaults to the max value 1023 or about 13 µs. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the sensor. Defaults to ``15s``. + See :ref:`sensor-default_filter`. - **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation. - All other options from :ref:`Sensor ` and :ref:`MQTT Component `. diff --git a/esphomeyaml/components/sensor/sht3xd.rst b/esphomeyaml/components/sensor/sht3xd.rst index 20c8e71c5..ba04f24db 100644 --- a/esphomeyaml/components/sensor/sht3xd.rst +++ b/esphomeyaml/components/sensor/sht3xd.rst @@ -58,7 +58,7 @@ Configuration variables: - **accuracy** (*Optional*, string): The accuracy of the sensor. One of ``low``, ``medium`` and ``high``. Defaults to ``high``. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the - sensor. Defaults to ``15s``. + sensor. Defaults to ``15s``. See :ref:`sensor-default_filter`. See Also ^^^^^^^^ diff --git a/esphomeyaml/components/sensor/template.rst b/esphomeyaml/components/sensor/template.rst index 7fb187bbd..e282e9623 100644 --- a/esphomeyaml/components/sensor/template.rst +++ b/esphomeyaml/components/sensor/template.rst @@ -32,7 +32,7 @@ Configuration variables: - **lambda** (*Optional*, :ref:`lambda `): Lambda to be evaluated every update interval to get the new value of the sensor - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the - sensor. Defaults to ``15s``. + sensor. Defaults to ``15s``. See :ref:`sensor-default_filter`. - **id** (*Optional*,:ref:`config-id`): Manually specify the ID used for code generation. - All other options from :ref:`Binary Sensor ` and :ref:`MQTT Component `. diff --git a/esphomeyaml/components/sensor/tsl2561.rst b/esphomeyaml/components/sensor/tsl2561.rst index 6c7bfd937..c039da44d 100644 --- a/esphomeyaml/components/sensor/tsl2561.rst +++ b/esphomeyaml/components/sensor/tsl2561.rst @@ -44,7 +44,7 @@ Configuration variables: formula for calculating the illuminance in lx. Set this to ``true`` if you're working with a CS package. Defaults to ``false``. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the - sensor. Defaults to ``15s``. + sensor. Defaults to ``15s``. See :ref:`sensor-default_filter`. - **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation. - All other options from :ref:`Sensor ` and :ref:`MQTT Component `. diff --git a/esphomeyaml/components/sensor/ultrasonic.rst b/esphomeyaml/components/sensor/ultrasonic.rst index c002a493b..dd64011cf 100644 --- a/esphomeyaml/components/sensor/ultrasonic.rst +++ b/esphomeyaml/components/sensor/ultrasonic.rst @@ -50,7 +50,7 @@ Configuration variables: the timeout. Use either this or ``timeout_meter``. Defaults to 11662µs. - **update_interval** (*Optional*, :ref:`config-time`): The interval to check the - sensor. Defaults to ``15s``. + sensor. Defaults to ``15s``. See :ref:`sensor-default_filter`. - **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation. - All other options from :ref:`Sensor ` and :ref:`MQTT Component `. diff --git a/esphomeyaml/index.rst b/esphomeyaml/index.rst index cdb718755..b3bcfd8a9 100644 --- a/esphomeyaml/index.rst +++ b/esphomeyaml/index.rst @@ -490,6 +490,8 @@ Misc Components Cookbook ^^^^^^^^ +This list contains items that are technically already supported by other components. + ================================================== ================================================== ================================================== |Garage Door|_ |PIR Sensor|_ |Relay|_ -------------------------------------------------- -------------------------------------------------- --------------------------------------------------