diff --git a/components/sensor/ags10.rst b/components/sensor/ags10.rst new file mode 100644 index 000000000..eaef0ecde --- /dev/null +++ b/components/sensor/ags10.rst @@ -0,0 +1,121 @@ +AGS10 Volatile Organic Compound (VOC) Sensor +============================================ + +.. seo:: + :description: Instructions for setting up AGS10 VOC sensors with ESPHome + :image: ags10.jpg + :keywords: AGS10 + +The ``ags10`` sensor platform VOC sensor allows you to use your ASAIR AGS10 +(`datasheet `__, +`ASAIR`_ ) sensors with +ESPHome. The :ref:`I²C Bus ` is +required to be set up in your configuration for this sensor to work. + +.. note:: + + The sensor supports up to 15kHz operation, so you should specify up to ``frequency: 15kHz`` in your ``i2c`` configuration. + + +.. _ASAIR: http://www.aosong.com/en/products-86.html + +.. figure:: images/ags10.jpg + :align: center + :width: 30.0% + + AGS10 VOC Sensor + +.. code-block:: yaml + + # Example configuration entry + sensor: + - platform: ags10 + tvoc: + name: TVOC + +Configuration variables: +------------------------ + +- **tvoc** (**Required**): The information for the total Volatile Organic Compounds sensor. + All options from :ref:`Sensor `. +- **address** (*Optional*, int): Manually specify the I²C address of + the sensor. Defaults to ``0x1A``. +- **update_interval** (*Optional*, :ref:`config-time`): The interval to check the + sensor. Defaults to ``60s``. +- **version** (*Optional*): The firmware version of the sensor. + All options from :ref:`Sensor `. +- **resistance** (*Optional*): The initial value of the sensor resistance. + All options from :ref:`Sensor `. + +Actions: +-------- + +.. _sensor-AGS10SetZeroPointAction: + +``ags10.set_zero_point`` Action +------------------------------- + +Zero-point of AGS10 has been calibrated before leaving factory. User can re-calibrate the zero-point as +needed. + +.. code-block:: yaml + + # Example configuration entry + sensor: + - platform: ags10 + id: ags10_1_id + # ... + + # in some trigger + on_...: + - ags10.set_zero_point: + id: ags10_1_id + mode: CURRENT_VALUE + +Configuration option: + +- **id** (**Required**, :ref:`config-id`): The ID of the AGS10 sensor. +- **mode** (**Required**, enum): One of supported modes: + + - ``FACTORY_DEFAULT`` - reset to the factory zero-point + - ``CURRENT_VALUE`` - set zero-point calibration with current resistance + - ``CUSTOM_VALUE`` - set zero-point calibration with resistance pointed with ``value`` option + +- **value** (**Optional**, int): nominated resistance value to set (unit: 0.1 kΩ). + + +.. _sensor-AGS10NewI2cAddressAction: + +``ags10.new_i2c_address`` Action +-------------------------------- + +I2C address of AGS10 can be modified, and it is possible to use multiple AGS10 sensors on one bus. +After sending the command for address changing, the new address is saved and takes effect immediately even +after power-off. + +.. code-block:: yaml + + # Example configuration entry + sensor: + - platform: ags10 + id: ags10_1_id + # ... + + # in some trigger + on_...: + - ags10.new_i2c_address: + id: ags10_1_id + address: 0x1E + +Configuration options: + +- **id** (**Required**, :ref:`config-id`): The ID of the AGS10 sensor. +- **address** (**Required**, int): New I2C address. + + +See Also +-------- + +- :ref:`sensor-filters` +- :apiref:`ags10/ags10.h` +- :ghedit:`Edit` diff --git a/components/sensor/images/ags10.jpg b/components/sensor/images/ags10.jpg new file mode 100644 index 000000000..93301b4f9 Binary files /dev/null and b/components/sensor/images/ags10.jpg differ diff --git a/images/ags10.jpg b/images/ags10.jpg new file mode 100644 index 000000000..272f28647 Binary files /dev/null and b/images/ags10.jpg differ diff --git a/index.rst b/index.rst index 6021c5fc0..65037d6c7 100644 --- a/index.rst +++ b/index.rst @@ -179,6 +179,7 @@ Air Quality *********** .. imgtable:: + AGS10, components/sensor/ags10, ags10.jpg, Volatile Organic Compound Sensor AirThings BLE, components/sensor/airthings_ble, airthings_logo.png, Radon, CO2, Volatile organics CCS811, components/sensor/ccs811, ccs811.jpg, CO2 & Volatile organics EE895, components/sensor/ee895, EE895.png, CO2 & Temperature & Pressure