Merge branch 'current' into next

# Conflicts:
#	Makefile
#	esphomeyaml/changelog/v1.10.0.rst
#	esphomeyaml/devices/sonoff_basic.rst
#	esphomeyaml/index.rst
This commit is contained in:
Otto Winter 2019-02-07 18:22:22 +01:00
commit 6ecc76ba80
No known key found for this signature in database
GPG Key ID: DB66C0BE6013F97E
788 changed files with 2127 additions and 10669 deletions

2
.gitignore vendored
View File

@ -1,8 +1,6 @@
_doxyxml
_build
.python-version
__pycache__/
*.py[cod]
*$py.class
esphomeyaml/.DS_Store

View File

@ -22,7 +22,6 @@ RUN pip3 install --no-cache-dir --no-binary :all: \
sphinx \
breathe
VOLUME /data/esphomedocs
EXPOSE 8000
WORKDIR /data/esphomedocs

22
Doxygen
View File

@ -32,13 +32,13 @@ DOXYFILE_ENCODING = UTF-8
# title of most generated pages and in a few other places.
# The default value is: My Project.
PROJECT_NAME = "esphomelib"
PROJECT_NAME = "ESPHome"
# The PROJECT_NUMBER tag can be used to enter a project or revision number. This
# could be handy for archiving the generated documentation or if some version
# control system is used.
PROJECT_NUMBER = 1.9.3
PROJECT_NUMBER = 1.10.1
# Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a
@ -76,7 +76,7 @@ CREATE_SUBDIRS = NO
# U+3044.
# The default value is: NO.
ALLOW_UNICODE_NAMES = NO
ALLOW_UNICODE_NAMES = YES
# The OUTPUT_LANGUAGE tag is used to specify the language in which all
# documentation generated by doxygen is written. Doxygen will use this
@ -436,7 +436,7 @@ LOOKUP_CACHE_SIZE = 0
# normally produced when WARNINGS is set to YES.
# The default value is: NO.
EXTRACT_ALL = NO
EXTRACT_ALL = YES
# If the EXTRACT_PRIVATE tag is set to YES, all private members of a class will
# be included in the documentation.
@ -462,7 +462,7 @@ EXTRACT_STATIC = NO
# for Java sources.
# The default value is: YES.
EXTRACT_LOCAL_CLASSES = YES
EXTRACT_LOCAL_CLASSES = NO
# This flag is only useful for Objective-C code. If set to YES, local methods,
# which are defined in the implementation section but not in the interface are
@ -791,7 +791,7 @@ WARN_LOGFILE =
# spaces. See also FILE_PATTERNS and EXTENSION_MAPPING
# Note: If this tag is empty the current directory is searched.
INPUT = $(ESPHOMELIB_PATH)/src
INPUT = $(ESPHOME_CORE_PATH)/src
# This tag can be used to specify the character encoding of the source files
# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses
@ -908,7 +908,7 @@ EXCLUDE_SYMBOLS =
# that contain example code fragments that are included (see the \include
# command).
EXAMPLE_PATH = $(ESPHOMELIB_PATH)/examples
EXAMPLE_PATH = $(ESPHOME_CORE_PATH)/examples
# If the value of the EXAMPLE_PATH tag contains directories, you can use the
# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp and
@ -997,7 +997,7 @@ USE_MDFILE_AS_MAINPAGE =
# also VERBATIM_HEADERS is set to NO.
# The default value is: NO.
SOURCE_BROWSER = NO
SOURCE_BROWSER = YES
# Setting the INLINE_SOURCES tag to YES will include the body of functions,
# classes and enums directly into the documentation.
@ -1105,7 +1105,7 @@ IGNORE_PREFIX =
# If the GENERATE_HTML tag is set to YES, doxygen will generate HTML output
# The default value is: YES.
GENERATE_HTML = NO
GENERATE_HTML = YES
# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. If a
# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of
@ -1113,7 +1113,7 @@ GENERATE_HTML = NO
# The default directory is: html.
# This tag requires that the tag GENERATE_HTML is set to YES.
HTML_OUTPUT = html
HTML_OUTPUT = _build/html/api
# The HTML_FILE_EXTENSION tag can be used to specify the file extension for each
# generated HTML page (for example: .htm, .php, .asp).
@ -1937,7 +1937,7 @@ MAN_LINKS = NO
# captures the structure of the code including all documentation.
# The default value is: NO.
GENERATE_XML = YES
GENERATE_XML = NO
# The XML_OUTPUT tag is used to specify where the XML pages will be put. If a
# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of

View File

@ -1,41 +1,43 @@
# Minimal makefile for Sphinx documentation
#
ESPHOME_CORE_PATH = ../esphome-core
ESPHOME_CORE_TAG = v1.10.1
# You can set these variables from the command line.
SPHINXOPTS =
SPHINXBUILD = sphinx-build
SPHINXPROJ = esphomelib
SOURCEDIR = .
BUILDDIR = _build
ESPHOMELIB_PATH = ../esphomelib
ESPHOMELIB_TAG = v1.10.0b1
.PHONY: html cleanhtml deploy help webserver Makefile netlify netlify-api api netlify-dependencies svg2png copy-svg2png
.PHONY: html cleanhtml doxyg cleandoxyg deploy help webserver Makefile $(ESPHOMELIB_PATH)
html:
sphinx-build -M html . _build $(O)
html: _doxyxml
$(SPHINXBUILD) -M html "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
cleanhtml:
rm -rf "_build/html/*"
cleanhtml: cleandoxyg
rm -rf "$(BUILDDIR)/html/*"
doxyg: cleandoxyg _doxyxml
cleandoxyg:
rm -rf _doxyxml
_doxyxml:
ESPHOMELIB_PATH=$(ESPHOMELIB_PATH) doxygen Doxygen
$(ESPHOMELIB_PATH):
@if [ ! -d "$(ESPHOMELIB_PATH)" ]; then \
git clone --branch $(ESPHOMELIB_TAG) https://github.com/OttoWinter/esphomelib.git $(ESPHOMELIB_PATH); \
fi
convertimages:
svg2png:
python3 svg2png.py
help:
$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
sphinx-build -M help . _build $(O)
api:
mkdir -p _build/html/api
@if [ ! -d "$(ESPHOME_CORE_PATH)" ]; then \
git clone --branch $(ESPHOME_CORE_TAG) https://github.com/esphome/esphome-core.git $(ESPHOME_CORE_PATH); \
fi
ESPHOME_CORE_PATH=$(ESPHOME_CORE_PATH) doxygen Doxygen
netlify-api: netlify-dependencies
mkdir -p _build/html/api
@if [ ! -d "$(ESPHOME_CORE_PATH)" ]; then \
git clone --branch $(ESPHOME_CORE_TAG) https://github.com/esphome/esphome-core.git $(ESPHOME_CORE_PATH); \
fi
ESPHOME_CORE_PATH=$(ESPHOME_CORE_PATH) ../doxybin/doxygen Doxygen
netlify-dependencies:
mkdir -p ../doxybin
curl -L https://github.com/esphome/esphome-docs/releases/download/v1.10.1/doxygen-1.8.13.xz | xz -d >../doxybin/doxygen
chmod +x ../doxybin/doxygen
copy-svg2png:
cp svg2png/*.png _build/html/_images/
netlify: netlify-dependencies netlify-api html copy-svg2png
webserver: html
cd "$(BUILDDIR)/html" && python3 -m http.server
@ -43,4 +45,4 @@ webserver: html
# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
sphinx-build -M $@ . _build $(O)

View File

@ -2,4 +2,4 @@
The source for https://esphomelib.com/
For contributing, please see https://esphomelib.com/esphomeyaml/guides/contributing.html#contributing-to-esphomedocs
For contributing, please see https://esphomelib.com/guides/contributing.html#contributing-to-esphomedocs

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.6 KiB

After

Width:  |  Height:  |  Size: 3.7 KiB

View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<browserconfig>
<msapplication>
<tile>
<square150x150logo src="/_static/mstile-150x150.png"/>
<TileColor>#dfdfdf</TileColor>
</tile>
</msapplication>
</browserconfig>

Binary file not shown.

After

Width:  |  Height:  |  Size: 56 KiB

BIN
_static/favicon-16x16.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 695 B

BIN
_static/favicon-32x32.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.8 KiB

BIN
_static/mstile-150x150.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

View File

@ -0,0 +1 @@
<svg version="1.0" xmlns="http://www.w3.org/2000/svg" width="1066.667" height="1066.667" viewBox="0 0 800 800"><path d="M266.5 149.6c-12.4 3.1-19.4 8.1-24.5 17.5l-3.5 6.4-.3 17.6-.4 17.6-4.3.6c-6.1.9-11.1 4.2-14.3 9.6l-2.7 4.6-.3 160.2L216 544H94v-15h49c34.4 0 49.6-.3 51.4-1.1 5-2.3 5.7-6.1 5.4-27.4l-.3-19.5-2.8-2.7-2.7-2.8-50-.3-50-.3V460h99l3.2-2.9 3.3-2.9V412l-2.8-2.7-2.7-2.8-50-.3-50-.3v-14.8l50-.3 50-.3 2.7-2.8 2.8-2.7v-42.2l-3.3-2.9-3.2-2.9H94v-99.8l-2.6-3.1c-3.6-4.3-9.3-4.4-13.5-.2l-2.9 2.9v113.4l2.9 2.9 2.9 2.9H180v16H80.8l-2.9 2.9-2.9 2.9v41.4l2.9 2.9 2.9 2.9H180v16H80.8l-2.9 2.9-2.9 2.9v41l2.6 3.1 2.6 3.1H180v16H81.1l-2.8 2.4-2.8 2.4-.3 21-.3 21 3 3.4 2.9 3.3 67.5.3 67.5.2.7 4.3c.4 2.3 1.3 5.3 2 6.7 2.8 5.4 10.1 10 15.9 10h3.5l.3 19.7c.3 19 .4 20 3 25.5 5.4 11.6 15.2 18.1 28.3 18.6 9.8.5 17.1-1.9 23.7-7.7 9.3-8.2 11.8-17 11.8-41.4V585h12v15.3c0 8.4.5 18 1.1 21.3 2.2 11.9 9.9 21.4 20.8 25.5 7.8 2.9 19.4 2.4 26.6-1.3 6.4-3.4 12.8-10 15.7-16.3 2.1-4.6 2.3-6.7 2.6-24.8l.4-19.7h12.6l.4 19.7c.3 17.7.6 20.3 2.5 24.5 2.9 6.3 9.7 13.4 15.8 16.6 7.2 3.7 18.8 4.2 26.6 1.3 7.9-3 14.1-8.8 18.1-16.9l3.3-6.7.3-19.3.4-19.3 6.1.3 6.2.3.5 20c.5 19.5.6 20.1 3.3 25.3 3.5 6.7 9 12.2 15.3 15.3 4.1 2 6.4 2.4 14.4 2.4 8.1 0 10.3-.4 14.5-2.4 6.3-3.2 12.4-9.3 15.6-15.6 2.2-4.7 2.4-6.3 2.9-25l.5-20 6.1-.3 6.2-.3.3 19.3.4 19.3 3.3 6.7c4 8.1 10.2 13.9 18.1 16.9 7.8 2.9 19.4 2.4 26.6-1.3 6.1-3.2 12.9-10.3 15.8-16.6 2-4.2 2.2-6.7 2.5-24.5l.4-19.7h12.6l.4 19.7c.3 22.6 1.3 26.1 9.1 34.1 6.4 6.7 12.7 9.5 22.2 10 9.8.5 17-1.9 23.7-7.7 9.2-8.2 11.8-17 11.8-41.2v-14.6l4.5-.5c5.4-.7 10.2-3.7 13.6-8.7l2.4-3.6.3-173c.2-121 0-174.1-.8-176.7-2.1-7.2-10.2-13.7-17.1-13.8h-2.6l-.5-16.9c-.4-16.6-.5-17-3.6-23.4-5.9-12-16.9-19-29.6-19-13.6 0-24.8 7-30.4 19.1-2.5 5.4-2.7 6.7-3 22.9l-.4 17.3H623v-15.3c0-17.2-1.1-22.4-6.1-30.1-6.5-9.7-20.5-15.8-31.9-13.8-11.9 2.1-20.7 8.9-25.7 19.7-2.6 5.6-2.7 7-3.1 22.7l-.4 16.8H543v-16.5c0-14.1-.3-17.2-2-21.9-2.9-7.6-8.8-13.9-16.6-17.7-5.7-2.8-7.6-3.3-14.4-3.3-6.8 0-8.7.5-14.4 3.3-7.1 3.5-12.2 8.6-15.8 16-2.1 4.2-2.3 6.3-2.6 22.3l-.4 17.8h-12.6l-.4-16.8c-.6-19.7-1.7-23.7-8.8-31.5-8.6-9.5-20.5-13.2-32.1-10.2-10.5 2.6-18.2 9-22.8 18.5-2.4 5.1-2.6 6.6-2.9 22.7l-.4 17.3H384v-15.3c0-17.2-1.1-22.4-6.1-30.1-6.5-9.7-20.5-15.8-31.9-13.8-11.9 2.1-20.7 9-25.8 20.1-2.4 5.1-2.6 7-3 22.3l-.5 16.8H305v-12.3c0-21.3-2.8-30.7-11.3-38.4-7-6.2-20-10.4-27.2-8.7zm11.5 20.9c1.5.8 3.8 3 4.9 4.8 1.9 3.1 2.1 4.9 2.1 18.6V209h-28v-13.9c0-7.7.5-15.2 1.1-16.8 1.3-3.4 4.7-7.2 7.4-8.3 3.2-1.4 9.4-1.1 12.5.5zm81.6 1.6c4.6 4.2 5.4 7.6 5.4 22.9v14h-28v-15c0-16.9.8-19.6 6.3-23.1 4.5-2.8 12.7-2.2 16.3 1.2zm77.5-1.6c6 3.1 6.9 6.3 6.9 23.2V209h-28.2l.4-15.3c.2-12.7.6-15.8 2.1-18 4-6.1 12.4-8.4 18.8-5.2zm80.4.5c5.5 3.4 6.5 6.9 6.5 23.4V209h-28v-14.6c0-13 .2-15 2.1-18.3 1.1-2.1 3.3-4.5 4.7-5.4 3.7-2.3 10.7-2.2 14.7.3zm81.5 1.5c4.1 4 5 7.9 5 23.2V209h-28v-15c0-16.9.8-19.6 6.3-23.1 4.8-3 12.7-2.2 16.7 1.6zm77.1-2c6 3.1 6.9 6.3 6.9 23.2V209h-28v-13.9c0-7.7.5-15.2 1.1-16.8 1.3-3.4 4.7-7.2 7.4-8.3 3.3-1.4 9.4-1.1 12.6.5zm26.7 226.7l-.3 166.3-232.2.3-232.3.2V231h465l-.2 166.2zM285 602.3c0 14.8-.3 17.7-1.8 20.6-3.7 6.8-12.9 9.1-19.3 4.8-6.1-4-6.9-7.1-6.9-26V585h28v17.3zm79.5.7c0 19.5-.5 21.2-6.8 25-6.4 3.9-15.4 1.5-18.9-5.1-1.5-2.9-1.8-5.8-1.8-20.7v-17.3l13.8.3 13.7.3V603zm79.5-.3c0 15.7-.2 18.2-1.9 20.9-3.7 6.1-13.4 8.1-19.6 4-5-3.3-6-6.8-6.3-23.9-.2-8.7-.1-16.4.2-17.2.4-1.2 3.2-1.5 14.1-1.5H444v17.7zm80-.5c0 15.5-.2 17.6-2 20.6-4.3 7-12.8 9.2-19.1 4.9-6.1-4-6.9-7.1-6.9-26V585h28v17.2zm79.5.8c0 19.5-.5 21.2-6.8 25-6.1 3.8-14.9 1.7-18.7-4.5-1.8-2.9-2-4.9-2-20.9v-17.7l13.8.3 13.7.3V603zm79.5-.7c0 14.8-.3 17.7-1.8 20.6-3.7 6.8-12.9 9.1-19.3 4.8-6-4-6.9-7.1-6.9-25.3 0-8.8.3-16.4.7-16.7.3-.4 6.6-.7 14-.7H683v17.3z"/><path d="M413.7 359.8c-39.5 39.5-53.7 54.3-53.7 56 0 3.5 2.8 8.1 5.3 8.7 1.2.3 6.3.6 11.2.8l9 .2.5 32.3.5 32.4 2.4 1.9c2.2 1.8 5.1 1.9 82.1 1.9s79.9-.1 82.1-1.9l2.4-1.9.5-32.4.5-32.3 9-.2c11.8-.4 13.2-.8 15-4.3 2.8-5.4 2.1-6.6-11.5-20.5l-13-13.2v-22.4c-.1-16-.4-22.9-1.3-24-2.4-3.1-5.6-3.9-15.7-3.9-9.9 0-10.2.1-13.1 2.9-2.4 2.5-2.9 3.7-2.9 8 0 2.8-.3 5.1-.8 5.1-.4 0-11.3-10.6-24.2-23.5-21.8-21.8-23.7-23.5-27-23.5-3.3 0-6.6 3.1-57.3 53.8z"/></svg>

After

Width:  |  Height:  |  Size: 4.1 KiB

20
_static/site.webmanifest Normal file
View File

@ -0,0 +1,20 @@
{
"name": "ESPHome",
"short_name": "ESPHome",
"icons": [
{
"src": "/_static/android-chrome-192x192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "/_static/android-chrome-512x512.png",
"sizes": "512x512",
"type": "image/png"
}
],
"theme_color": "#dfdfdf",
"background_color": "#dfdfdf",
"start_url": "https://esphome.io/",
"display": "standalone"
}

View File

@ -1 +1 @@
1.9.3
1.10.1

View File

@ -1,12 +1,29 @@
{% extends 'alabaster/layout.html' %}
{%- block extrahead %}
{{ super() }}
<link rel="apple-touch-icon" sizes="180x180" href="/_static/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/_static/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="/_static/favicon-16x16.png">
<link rel="manifest" href="/_static/site.webmanifest">
<link rel="mask-icon" href="/_static/safari-pinned-tab.svg" color="#646464">
<link rel="shortcut icon" href="/_static/favicon.ico">
<meta name="apple-mobile-web-app-title" content="ESPHome">
<meta name="application-name" content="ESPHome">
<meta name="msapplication-TileColor" content="#dfdfdf">
<meta name="msapplication-config" content="/_static/browserconfig.xml">
<meta name="theme-color" content="#dfdfdf">
<meta name="HandheldFriendly" content="True">
<meta name="MobileOptimized" content="320">
{% endblock %}
{% block footer %}
<div class="footer">
<a href="/misc/privacy.html">Privacy Policy</a>
</div>
<div id="upgrade-footer">
A new version has been release since you last visited this page: {{ release }} 🎉
<a id="upgrade-footer-changelog" href="/esphomeyaml/changelog/index.html">View Changelog</a>
<a id="upgrade-footer-changelog" href="/changelog/index.html">View Changelog</a>
</div>
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-113203480-2"></script>

View File

@ -1,31 +0,0 @@
ESP32 Touch Binary Sensor
=========================
Example Usage
-------------
.. code-block:: cpp
auto *touch = App.make_esp32_touch_component();
touch->set_setup_mode(true);
touch->set_iir_filter(1000);
App.register_binary_sensor(touch_hub->make_touch_pad("ESP32 Touch Pad 9", TOUCH_PAD_NUM9, 1000));
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_esp32_touch_component`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: binary_sensor::ESP32TouchComponent
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::ESP32TouchBinarySensor
:members:
:protected-members:
:undoc-members:

View File

@ -1,26 +0,0 @@
GPIO Binary Sensor
==================
Example Usage
-------------
.. code-block:: cpp
// Basic
App.make_gpio_binary_sensor("Window Open", 36);
// Custom pinMode
App.make_gpio_binary_sensor("Window Open", GPIOInputPin(36, INPUT_PULLUP));
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_gpio_binary_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: binary_sensor::GPIOBinarySensorComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,131 +0,0 @@
Binary Sensor
=============
.. cpp:namespace:: binary_sensor
In esphomelib, every component that exposes a binary state, is a :cpp:class:`BinarySensor`.
To create your own binary sensor, simply subclass :cpp:class:`BinarySensor` and call
:cpp:func:`BinarySensor::publish_state` to tell the frontend that you have a new state.
Inversion is automatically done for you when publishing state and can be changed by the
user with :cpp:func:`BinarySensor::set_inverted`.
Supported Binary Sensors
------------------------
.. toctree::
:glob:
*
Example Usage
-------------
.. code-block:: cpp
// Basic
App.register_binary_sensor(custom_binary_sensor);
// GPIO Binary Sensor
App.make_gpio_binary_sensor("Window Open", 36);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::register_binary_sensor` and :cpp:func:`Application::make_gpio_binary_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
BinarySensor
************
.. doxygenclass:: binary_sensor::BinarySensor
:members:
:protected-members:
:undoc-members:
MQTTBinarySensorComponent
*************************
.. doxygenclass:: binary_sensor::MQTTBinarySensorComponent
:members:
:protected-members:
:undoc-members:
Filters
*******
.. doxygenclass:: binary_sensor::Filter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::DelayedOnFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::DelayedOffFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::HeartbeatFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::InvertFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::LambdaFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::UniqueFilter
:members:
:protected-members:
:undoc-members:
Triggers
********
.. doxygenclass:: binary_sensor::PressTrigger
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::ReleaseTrigger
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::ClickTrigger
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::DoubleClickTrigger
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::MultiClickTrigger
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::BinarySensorCondition
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::CustomBinarySensorConstructor
:members:
:protected-members:
:undoc-members:

View File

@ -1,19 +0,0 @@
PN532 NFC/RFID Controller
=========================
See :cpp:func:`Application::make_pn532_component`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: binary_sensor::PN532Component
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::PN532BinarySensor
:members:
:protected-members:
:undoc-members:

View File

@ -1,19 +0,0 @@
RDM6300 NFC/RFID Controller
===========================
See :cpp:func:`Application::make_rdm6300_component`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: binary_sensor::RDM6300Component
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: binary_sensor::RDM6300BinarySensor
:members:
:protected-members:
:undoc-members:

View File

@ -1,112 +0,0 @@
Remote Receiver
===============
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_remote_receiver_component` and
:cpp:func:`Application::register_binary_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: remote::RemoteReceiverComponent
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::RemoteReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::RemoteReceiveDumper
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::LGReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::LGDumper
:members:
:protected-members:
:undoc-members:
.. doxygenfunction:: remote::decode_lg
.. doxygenclass:: remote::NECReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::NECDumper
:members:
:protected-members:
:undoc-members:
.. doxygenfunction:: remote::decode_nec
.. doxygenclass:: remote::PanasonicReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::PanasonicDumper
:members:
:protected-members:
:undoc-members:
.. doxygenfunction:: remote::decode_panasonic
.. doxygenclass:: remote::SonyReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::SonyDumper
:members:
:protected-members:
:undoc-members:
.. doxygenfunction:: remote::decode_sony
.. doxygenclass:: remote::RawReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::RawDumper
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::SamsungReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::RCSwitchRawReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::RCSwitchTypeAReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::RCSwitchTypeBReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::RCSwitchTypeCReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::RCSwitchTypeDReceiver
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: remote::RCSwitchDumper
:members:
:protected-members:
:undoc-members:

View File

@ -1,26 +0,0 @@
Node Status Binary Sensor
=========================
This binary sensor platform allows you to create a switch that uses the birth and last will
messages by the MQTT client to show an ON/OFF state of the node.
Example Usage
-------------
.. code-block:: cpp
App.make_status_binary_sensor("Livingroom Node Status");
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_status_binary_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: binary_sensor::StatusBinarySensor
:members:
:protected-members:
:undoc-members:

View File

@ -1,16 +0,0 @@
Template Binary Sensor
======================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_template_binary_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: binary_sensor::TemplateBinarySensor
:members:
:protected-members:
:undoc-members:

View File

@ -1,38 +0,0 @@
Application
===========
.. cpp:namespace:: nullptr
The :cpp:class:`Application` class has two objectives: 1. handle all of
your :cpp:class:`Component`\ s and 2. provide helper methods to simplify creating a component.
.. cpp:namespace:: Application
In itself, an Application instance doesn't do and store very much. It mostly only keeps track of all Components
(using an internal :cpp:func:`std::vector` containing pointers), so that when the user calls the :cpp:func:`setup` or
:cpp:func:`loop` methods, it can relay those calls to the components.
In order for the Application to know about your components, each one of them should be registered using the
:cpp:func:`register_component` call. And for subclasses of MQTTComponent, :cpp:func:`register_mqtt_component`
shall be used.
Apart from the helpers, only one function is really necessary for setting up the Application instance:
:cpp:func:`set_name`. The name provided by this is used throughout the code base to construct various strings
such as MQTT topics or WiFi hostnames. Additionally, some one-time-setup components such as MQTT or WiFi can be
initialized with the `init_` calls. Next, this class provides a bunch of helper methods to create and
register components easily using the `make_` calls.
Each component can tell the Application with which *priority* it wishes to be called using the `get_loop_priority()`
and `get_setup_priority()` overrides. The Application will then automatically order the components before execution.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: Application
:members:
:protected-members:
:undoc-members:
.. doxygenvariable:: App

View File

@ -1,7 +0,0 @@
Automation
==========
API Reference
-------------
.. doxygenfile:: esphomelib/automation.h

View File

@ -1,34 +0,0 @@
Component
=========
.. cpp:namespace:: Component
Every object that should be handled by the Application instance and receive :cpp:func:`setup` and
:cpp:func:`loop` calls must be a subclass of :cpp:class:`Component`.
API Reference
-------------
.. cpp:namespace:: nullptr
Component
*********
.. doxygenclass:: Component
:members:
:protected-members:
:undoc-members:
PollingComponent
****************
.. doxygenclass:: PollingComponent
:members:
:protected-members:
:undoc-members:
Setup Priorities
****************
.. doxygennamespace:: setup_priority

View File

@ -1,23 +0,0 @@
Controller
==========
API Reference
-------------
.. cpp:namespace:: nullptr
Controller
**********
.. doxygenclass:: Controller
:members:
:protected-members:
:undoc-members:
StoringController
*****************
.. doxygenclass:: StoringController
:members:
:protected-members:
:undoc-members:

View File

@ -1,27 +0,0 @@
Deep Sleep
==========
.. cpp:namespace:: DeepSleepComponent
API Reference
-------------
.. cpp:namespace:: nullptr
DeepSleepComponent
******************
.. doxygenclass:: DeepSleepComponent
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: EnterDeepSleepAction
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: PreventDeepSleepAction
:members:
:protected-members:
:undoc-members:

View File

@ -1,74 +0,0 @@
Helpers
=======
esphomelib uses a bunch of helpers to make the library easier to use.
API Reference
-------------
helpers.h
*********
.. doxygenfile:: esphomelib/helpers.h
util.h
******
.. doxygenfile:: esphomelib/uil.h
optional.h
**********
.. doxygenfile:: esphomelib/optional.h
ESPPreferences
**************
.. doxygenclass:: ESPPreferences
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: ESPPreferenceObject
:members:
:protected-members:
:undoc-members:
.. doxygenvariable:: global_preferences
esphal.h
********
This header should be used whenever you want to access some `digitalRead`, `digitalWrite`, ... methods.
.. doxygenclass:: GPIOPin
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: GPIOOutputPin
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: GPIOInputPin
:members:
:protected-members:
:undoc-members:
ESPOneWire
**********
esphomelib has its own implementation of OneWire, because the implementation in the Arduino libraries
seems to have lots of timing issues with the ESP8266/ESP32. That's why ESPOneWire was created.
.. doxygenclass:: ESPOneWire
:members:
:protected-members:
:undoc-members:
defines.h
*********
.. doxygenfile:: esphomelib/defines.h

View File

@ -1,20 +0,0 @@
I2CComponent
============
To make i2c devices easier to implement in esphomelib, there's a special I2CComponent implementing
a bunch of i2c helper functions on top of the Arduino Wire library. It is also the preferred way
of using i2c peripherals since it implements timeouts, verbose logs for debugging issues, and
for the ESP32 the ability to have multiple i2c busses in operation at the same time.
API Reference
-------------
.. doxygenclass:: I2CComponent
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: I2CDevice
:members:
:protected-members:
:undoc-members:

View File

@ -1,23 +0,0 @@
Core
====
.. toctree::
:maxdepth: 1
Application <application>
Component <component>
WiFi <wifi>
MQTT Client <mqtt>
Over-The-Air Updates <ota>
Helpers <helpers>
Logging Engine <log>
Power Supply <power-supply>
Controller <controller>
Web Server <web-server>
Deep Sleep <deep-sleep>
I2C <i2c>
Automation <automation>
Time <time>
SPI Bus <spi>
UART Bus <uart>
Native API for Home Assistant <native-api>

View File

@ -1,15 +0,0 @@
Logging Engine
==============
esphomelib will by default log to both Serial (with baud rate 115200).
API Reference
-------------
LogComponent
************
.. doxygenclass:: LogComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,96 +0,0 @@
MQTT Client
===========
.. cpp:namespace:: mqtt
API Reference
-------------
.. cpp:namespace:: nullptr
MQTTClientComponent
*******************
.. doxygenclass:: mqtt::MQTTClientComponent
:members:
:protected-members:
:undoc-members:
.. doxygentypedef:: mqtt::mqtt_callback_t
.. doxygentypedef:: mqtt::mqtt_json_callback_t
.. doxygenstruct:: mqtt::MQTTMessage
:members:
:protected-members:
:undoc-members:
.. doxygenstruct:: mqtt::MQTTSubscription
:members:
:protected-members:
:undoc-members:
.. doxygenstruct:: mqtt::MQTTCredentials
:members:
:protected-members:
:undoc-members:
.. doxygenstruct:: mqtt::Availability
:members:
:protected-members:
:undoc-members:
.. doxygenstruct:: mqtt::MQTTDiscoveryInfo
:members:
:protected-members:
:undoc-members:
.. doxygenvariable:: mqtt::global_mqtt_client
MQTTComponent
*************
.. doxygenclass:: mqtt::MQTTComponent
:members:
:protected-members:
:undoc-members:
.. doxygenstruct:: mqtt::SendDiscoveryConfig
:members:
:protected-members:
:undoc-members:
Triggers
********
.. doxygenclass:: mqtt::MQTTMessageTrigger
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: mqtt::MQTTJsonMessageTrigger
:members:
:protected-members:
:undoc-members:
Actions
*******
.. doxygenclass:: mqtt::MQTTPublishAction
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: mqtt::MQTTPublishJsonAction
:members:
:protected-members:
:undoc-members:
.. _api-custom_mqtt_device:
CustomMQTTDevice
****************
.. doxygenclass:: mqtt::CustomMQTTDevice
:members:
:protected-members:
:undoc-members:

View File

@ -1,19 +0,0 @@
Native API
==========
See :cpp:func:`Application::init_api_server`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenfile:: esphomelib/api/api_message.h
.. doxygenfile:: esphomelib/api/api_server.h
.. doxygenfile:: esphomelib/api/basic_messages.h
.. doxygenfile:: esphomelib/api/command_messages.h
.. doxygenfile:: esphomelib/api/list_entities.h
.. doxygenfile:: esphomelib/api/service_call_message.h
.. doxygenfile:: esphomelib/api/subscribe_logs.h
.. doxygenfile:: esphomelib/api/subscribe_state.h
.. doxygenfile:: esphomelib/api/util.h

View File

@ -1,33 +0,0 @@
Over-The-Air Updates
====================
Example Usage
-------------
.. code-block:: cpp
// Setup basic OTA
App.init_ota();
// Enable safe mode.
App.init_ota()->start_safe_mode();
// OTA password
auto *ota = App.init_ota();
ota->set_auth_plaintext_password("VERY_SECURE");
ota->start_safe_mode();
// OTA MD5 password
auto *ota = App.init_ota();
ota->start_safe_mode();
API Reference
-------------
.. cpp:namespace:: nullptr
OTAComponent
************
.. doxygenclass:: OTAComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,25 +0,0 @@
Power Supply
============
Example Usage
-------------
.. code-block:: cpp
// Basic
auto *power_supply = App.make_power_supply(12);
// Inverted, for ATX
auto *atx = App.make_power_supply(GPIOOutputPin(12, OUTPUT, true));
API Reference
-------------
.. cpp:namespace:: nullptr
PowerSupplyComponent
********************
.. doxygenclass:: PowerSupplyComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,15 +0,0 @@
SPI Bus
=======
API Reference
-------------
.. doxygenclass:: SPIComponent
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: SPIDevice
:members:
:protected-members:
:undoc-members:

View File

@ -1,9 +0,0 @@
Time
====
API Reference
-------------
.. doxygenfile:: esphomelib/time/rtc_component.h
.. doxygenfile:: esphomelib/time/sntp_component.h
.. doxygenfile:: esphomelib/time/homeassistant_time.h

View File

@ -1,20 +0,0 @@
UART Bus
========
API Reference
-------------
.. doxygenclass:: UARTComponent
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: UARTDevice
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: ESP8266SoftwareSerial
:members:
:protected-members:
:undoc-members:

View File

@ -1,17 +0,0 @@
Web Server
==========
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: WebServer
:members:
:protected-members:
:undoc-members:
.. doxygenstruct:: UrlMatch
:members:
:protected-members:
:undoc-members:

View File

@ -1,20 +0,0 @@
WiFi
====
Example Usage
-------------
.. code-block:: cpp
App.init_wifi("YOUR_SSID", "YOUR_PASSWORD");
API Reference
-------------
.. cpp:namespace:: nullptr
WiFiComponent
*************
.. doxygenfile:: esphomelib/wifi_component.h
.. doxygenfile:: esphomelib/ethernet_component.h

View File

@ -1,53 +0,0 @@
Cover
=====
Supported Covers
----------------
.. toctree::
:glob:
*
Example Usage
-------------
See :cpp:func:`Application::register_cover`.
API Reference
-------------
.. cpp:namespace:: nullptr
Cover
*****
.. doxygenclass:: cover::Cover
:members:
:protected-members:
:undoc-members:
.. doxygenenum:: cover::CoverState
.. doxygenclass:: cover::OpenAction
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: cover::CloseAction
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: cover::StopAction
:members:
:protected-members:
:undoc-members:
MQTTCoverComponent
******************
.. doxygenclass:: cover::MQTTCoverComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,16 +0,0 @@
Template Cover
==============
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_template_cover`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: cover::TemplateCover
:members:
:protected-members:
:undoc-members:

View File

@ -1,59 +0,0 @@
Display
=======
Supported Displays
------------------
.. toctree::
:glob:
*
API Reference
-------------
.. cpp:namespace:: nullptr
.. _display-buffer:
DisplayBuffer
*************
.. doxygenclass:: display::DisplayBuffer
:members:
:protected-members:
:undoc-members:
.. doxygenvariable:: COLOR_OFF
.. doxygenvariable:: COLOR_ON
TextAlign
*********
.. doxygenenum:: TextAlign
Font
****
.. doxygenclass:: display::Font
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: display::Glyph
:members:
:protected-members:
:undoc-members:
Image
*****
.. doxygenclass:: display::Image
:members:
:protected-members:
:undoc-members:
DisplayRotation
***************
.. doxygenenum:: display::DisplayRotation

View File

@ -1,30 +0,0 @@
LCD Display
===========
API Reference
-------------
.. cpp:namespace:: nullptr
.. _api-display-lcd_display:
LCDDisplay
**********
.. doxygenclass:: display::LCDDisplay
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: display::GPIOLCDDisplay
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: display::PCF8574LCDDisplay
:members:
:protected-members:
:undoc-members:
.. doxygentypedef:: lcd_writer_t

View File

@ -1,19 +0,0 @@
MAX7219 7-Segment Display
=========================
API Reference
-------------
.. cpp:namespace:: nullptr
.. _api-display-max7219:
MAX7219Component
^^^^^^^^^^^^^^^^
.. doxygenclass:: display::MAX7219Component
:members:
:protected-members:
:undoc-members:
.. doxygentypedef:: max7219_writer_t

View File

@ -1,21 +0,0 @@
Nextion Display
===============
.. _api-display-nextion:
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: display::Nextion
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: display::NextionTouchComponent
:members:
:protected-members:
:undoc-members:
.. doxygentypedef:: nextion_writer_t

View File

@ -1,24 +0,0 @@
SSD1306 OLED Display
====================
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: display::SSD1306
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: display::SPISSD1306
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: display::I2CSSD1306
:members:
:protected-members:
:undoc-members:
.. doxygenenum:: SSD1306Model

View File

@ -1,36 +0,0 @@
Waveshare E-Paper Display
=========================
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: display::WaveshareEPaper
:members:
:protected-members:
:undoc-members:
.. doxygenenum:: WaveshareEPaperTypeAModel
.. doxygenclass:: display::WaveshareEPaperTypeA
:members:
:protected-members:
:undoc-members:
.. doxygenenum:: WaveshareEPaperTypeBModel
.. doxygenclass:: display::WaveshareEPaper2P7In
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: display::WaveshareEPaper4P2In
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: display::WaveshareEPaper7P5In
:members:
:protected-members:
:undoc-members:

View File

@ -1,80 +0,0 @@
Fan
====
.. cpp:namespace:: fan
Fans in esphomelib are implemented like lights. Both the hardware and the MQTT frontend
access a combined :cpp:class:`FanState` object and use only that to set state and receive
state updates.
Example Usage
-------------
.. code-block:: cpp
// Basic
auto fan = App.make_fan("Fan");
fan.output->set_binary(App.make_gpio_output(34));
// Speed
auto speed_fan = App.make_fan("Speed Fan");
fan.output->set_speed(App.make_ledc_output(34));
// Oscillation
auto oscillating_fan = App.make_fan("Oscillating Fan");
oscillating_fan.output->set_binary(App.make_gpio_output(34));
oscillating_fan.output->set_oscillation(App.make_gpio_output(35));
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_fan`.
API Reference
-------------
.. cpp:namespace:: nullptr
FanState
********
.. doxygenclass:: fan::FanState
:members:
:protected-members:
:undoc-members:
FanTraits
*********
.. doxygenclass:: fan::FanTraits
:members:
:protected-members:
:undoc-members:
BasicFanComponent
*****************
.. doxygenclass:: fan::BasicFanComponent
:members:
:protected-members:
:undoc-members:
MQTTFanComponent
****************
.. doxygenclass:: fan::MQTTFanComponent
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: fan::ToggleAction
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: fan::TurnOnAction
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: fan::TurnOffAction
:members:
:protected-members:
:undoc-members:

View File

@ -1,17 +0,0 @@
API Reference
=============
.. toctree::
:maxdepth: 2
Core <core/index>
Sensor <sensor/index>
Binary Sensor <binary_sensor/index>
Output <output/index>
Fan <fan/index>
Light <light/index>
Switch <switch/index>
Cover <cover/index>
Display <display/index>
Text Sensors <text_sensor/index>
Miscellaneous <misc/index>

View File

@ -1,12 +0,0 @@
Addressable Lights
==================
API Reference
-------------
.. doxygenfile:: esphomelib/light/addressable_light.h
Addressable Light Effects
*************************
.. doxygenfile:: esphomelib/light/addressable_light_effect.h

View File

@ -1,24 +0,0 @@
FastLED Light Output
====================
Since version 1.5.0 esphomelib supports many types of addressable LEDs using the FastLED
library.
Example Usage
-------------
.. code-block:: cpp
// Binary
auto fast_led = App.make_fast_led_light("Fast LED Light");
// 60 NEOPIXEL LEDS on pin GPIO23
fast_led.fast_led->add_leds<NEOPIXEL, 23>(60);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_fast_led_light`.
API Reference
-------------
.. doxygenfile:: esphomelib/light/fast_led_light_output.h

View File

@ -1,72 +0,0 @@
Light
=====
.. cpp:namespace:: light
Lights in esphomelib are implemented like fans. Both the hardware and the MQTT frontend
access a combined :cpp:class:`LightState` object and use only that to set state and receive
state updates.
.. toctree::
:glob:
*
Example Usage
-------------
.. code-block:: cpp
// Binary
App.make_binary_light("Desk Lamp", App.make_gpio_output(15));
// Brightness-only
App.make_monochromatic_light("Kitchen Lights", App.make_ledc_output(16));
// RGB, see output for information how to setup individual channels.
App.make_rgb_light("RGB Lights", red, green, blue);
App.make_rgbw_light("RGBW Lights", red, green, blue, white);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_binary_light`, :cpp:func:`Application::make_monochromatic_light`,
:cpp:func:`Application::make_rgb_light`, :cpp:func:`Application::make_rgbw_light`.
API Reference
-------------
.. cpp:namespace:: nullptr
LightColorValues
****************
.. doxygenfile:: esphomelib/light/light_color_values.h
LightEffect
***********
.. doxygenfile:: esphomelib/light/light_effect.h
LightOutput
***********
.. doxygenfile:: esphomelib/light/light_output.h
LightState
**********
.. doxygenfile:: esphomelib/light/light_state.h
LightTraits
***********
.. doxygenfile:: esphomelib/light/light_traits.h
LightTransformer
****************
.. doxygenfile:: esphomelib/light/light_transformer.h
MQTTJSONLightComponent
**********************
.. doxygenfile:: esphomelib/light/mqtt_json_light_component.h

View File

@ -1,24 +0,0 @@
Neopixelbus Lights
==================
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenenum:: light::ESPNeoPixelOrder
.. doxygenclass:: light::NeoPixelBusLightOutputBase
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: light::NeoPixelRGBLightOutput
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: light::NeoPixelRGBWLightOutput
:members:
:protected-members:
:undoc-members:

View File

@ -1,23 +0,0 @@
Debug Component
===============
Example Usage
-------------
.. code-block:: cpp
App.make_debug_component();
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_debug_component`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: DebugComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,16 +0,0 @@
ESP32 Bluetooth Low Energy Beacon
=================================
See :cpp:func:`Application::make_esp32_ble_beacon`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: ESP32BLEBeacon
:members:
:protected-members:
:undoc-members:
.. doxygenvariable:: global_esp32_ble_beacon

View File

@ -1,60 +0,0 @@
ESP32 Bluetooth Low Energy Tracker
==================================
Example Usage
-------------
.. code-block:: cpp
auto *tracker = App.make_esp32_ble_tracker();
// MAC address AC:37:43:77:5F:4C
App.register_binary_sensor(tracker->make_device("ESP32 Bluetooth Beacon", {
0xAC, 0x37, 0x43, 0x77, 0x5F, 0x4C
}));
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_esp32_ble_tracker`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: ESP32BLETracker
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: ESP32BLEPresenceDevice
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: ESP32BLERSSISensor
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: XiaomiSensor
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: XiaomiDevice
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: ESPBTDevice
:members:
:protected-members:
:undoc-members:
.. doxygenvariable:: global_esp32_ble_tracker
.. doxygenvariable:: semaphore_scan_end
.. doxygenclass:: ESPBTUUID
:members:
:protected-members:
:undoc-members:

View File

@ -1,7 +0,0 @@
Miscellaneous Components
========================
.. toctree::
:glob:
*

View File

@ -1,44 +0,0 @@
PCF8574 I/O Expander
====================
The PCF8574 component allows you to use PCF8574 and PCF8575 I/O port expanders with many of
esphomelib's components. With most components, you are able to specify GPIOOutputPin or
GPIOInputPin for internal pins. The PCF8574 component subclasses those types.
Example Usage
-------------
.. code-block:: cpp
auto *pcf8574 = App.make_pcf8574_component(0x21);
App.make_gpio_binary_sensor("PCF pin 0 sensor", pcf8574->make_input_pin(0, PCF8574_INPUT));
App.make_gpio_binary_sensor("PCF pin 0 sensor", 0);
App.make_gpio_switch("PCF pin 1 switch", pcf8574->make_output_pin(1));
auto *out = App.make_gpio_output(pcf8574->make_output_pin(2));
App.make_binary_light("PCF pin 2 light", out);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_pcf8574_component`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenenum:: io::PCF8574GPIOMode
.. doxygenclass:: io::PCF8574Component
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: io::PCF8574GPIOInputPin
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: io::PCF8574GPIOOutputPin
:members:
:protected-members:
:undoc-members:

View File

@ -1,16 +0,0 @@
Status LED
==========
See :cpp:func:`Application::make_status_led`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: StatusLEDComponent
:members:
:protected-members:
:undoc-members:
.. doxygenvariable:: global_status_led

View File

@ -1,12 +0,0 @@
Stepper Component
=================
.. cpp:namespace:: nullptr
API Reference
-------------
.. doxygenfile:: esphomelib/stepper/stepper.h
.. doxygenfile:: esphomelib/stepper/a4988.h
.. doxygenfile:: esphomelib/stepper/uln2003.h

View File

@ -1,37 +0,0 @@
ESP8266 Software PWM
====================
Software PWM for the ESP8266. Warning: This is a *software* PWM and therefore can have noticeable flickering.
Additionally, this software PWM can't output values higher than 80%. That's a known limitation.
.. _esp8266_pwm-example_usage:
Example Usage
-------------
.. code-block:: cpp
// Basic
auto *output = App.make_esp8266_pwm_output(D2);
// Create a brightness-only light with it:
App.make_monochromatic_light("Desk Lamp", output);
// Advanced: Setting a custom frequency globally
analogWriteFreq(500);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_esp8266_pwm_output`.
API Reference
-------------
.. cpp:namespace:: nullptr
ESP8266PWMOutput
****************
.. doxygenclass:: output::ESP8266PWMOutput
:members:
:protected-members:
:undoc-members:

View File

@ -1,29 +0,0 @@
GPIO Binary Output
==================
Example Usage
-------------
.. code-block:: cpp
// Create a binary output, *not a switch*
App.make_gpio_output(33);
// Custom pinMode
App.make_gpio_output(GPIOOutputPin(33, OUTPUT_OPEN_DRAIN));
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_gpio_output` (and :cpp:func:`Application::make_gpio_switch`).
API Reference
-------------
.. cpp:namespace:: nullptr
GPIOBinaryOutputComponent
*************************
.. doxygenclass:: output::GPIOBinaryOutputComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,45 +0,0 @@
Output
======
The `output` namespace contains all peripheral output components.
.. toctree::
:glob:
*
API Reference
-------------
.. cpp:namespace:: nullptr
BinaryOutput
************
.. doxygenclass:: output::BinaryOutput
:members:
:protected-members:
:undoc-members:
FloatOutput
***********
.. doxygenclass:: output::FloatOutput
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: output::TurnOnAction
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: output::TurnOffAction
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: output::SetLevelAction
:members:
:protected-members:
:undoc-members:

View File

@ -1,31 +0,0 @@
ESP32 LEDC Output
=================
Example Usage
-------------
.. code-block:: cpp
// Basic
App.make_ledc_output(33);
// Custom Frequency
App.make_ledc_output(33, 2000.0);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_ledc_output`.
API Reference
-------------
.. cpp:namespace:: nullptr
LEDCOutputComponent
*******************
.. doxygenclass:: output::LEDCOutputComponent
:members:
:protected-members:
:undoc-members:
.. doxygenvariable:: output::next_ledc_channel

View File

@ -1,30 +0,0 @@
MY9231/MY9291 Output
====================
FloatOutput support for an MY9231/MY9291 LED driver chain.
Example Usage
-------------
.. code-block:: cpp
// Create the MY9231 Output hub connected to GPIO12 (DI pin) and
// GPIO14 (DCKI pin).
auto *pmy9231 = App.make_my9231_component(12, 14);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_my9231_component`.
API Reference
-------------
.. cpp:namespace:: nullptr
MY9231OutputComponent
**********************
.. doxygenclass:: output::MY9231OutputComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,31 +0,0 @@
PCA9685 PWM
===========
FloatOutput support for an `PCA9695 16-Channel PWM Driver`_.
Example Usage
-------------
.. code-block:: cpp
// Create the PCA9685 Output hub with frequency 500Hz.
auto *pca9685 = App.make_pca9685_component(500.0f);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_pca9685_component`.
API Reference
-------------
.. cpp:namespace:: nullptr
PCA9685OutputComponent
**********************
.. doxygenclass:: output::PCA9685OutputComponent
:members:
:protected-members:
:undoc-members:
.. _PCA9695 16-Channel PWM Driver: https://www.adafruit.com/product/815

View File

@ -1,31 +0,0 @@
ADC Sensor
==========
Example Usage
-------------
.. code-block:: cpp
// Basic
App.make_adc_sensor("Analog Voltage", 13);
// Custom update interval 30 seconds
App.make_adc_sensor("Analog Voltage", 13, 30000);
// Custom pinMode
App.make_adc_sensor("Analog Voltage", GPIOInputPin(13, INPUT_PULLUP));
// ESP32: Attenuation
auto adc = App.make_adc_sensor("Analog Voltage", 13);
adc.adc.set_attenuation(ADC_11db);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_adc_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::ADCSensorComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,60 +0,0 @@
ADS1115 ADC Component
=====================
.. cpp:namespace:: input
This class allows using ADS1115 Analog to Digital converters (`datasheet`_, `adafruit`_) devices with esphomelib.
Doing so requires some steps:
.. _datasheet: http://www.ti.com/lit/ds/symlink/ads1115.pdf
.. _adafruit: https://www.adafruit.com/product/1085
.. cpp:namespace:: sensor::ADS1115Component
1. Initialize the i2c bus with the pins you have SDA and SCL connected to:
.. code-block:: cpp
// inside setup()
App.init_i2c(SDA_PIN, SCL_PIN);
2. Create the "hub" or the ADS1115 device itself. The parameter you pass in here is the i2c
address of the ADS1115. See :cpp:func:`set_address` for possible other addresses.
.. code-block:: cpp
// after init_i2c
auto *ads1115 = App.make_ads1115_component(0x48);
This will create an ADS1115 component which you can now use to create individual sensors.
3. Create the sensors, you can have multiple of these. Do so by calling :cpp:func:`get_sensor` with
the multiplexer channel you want (essentially between which pins you want to measure voltage) and
the gain for that sensor and register that sensor.
.. code-block:: cpp
auto *sensor = ads1115->get_sensor("ADS1115 Voltage #1", sensor::ADS1115_MULTIPLEXER_P0_N1, sensor::ADS1115_GAIN_6P144);
App.register_sensor(sensor);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_ads1115_component`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenenum:: sensor::ADS1115Multiplexer
.. doxygenenum:: sensor::ADS1115Gain
.. doxygenclass:: sensor::ADS1115Component
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::ADS1115Sensor
:members:
:protected-members:
:undoc-members:

View File

@ -1,9 +0,0 @@
APDS9960 Sensor
===============
See :cpp:func:`Application::make_apds9960`.
API Reference
-------------
.. doxygenclass:: esphomelib/sensor/apds9960.h

View File

@ -1,34 +0,0 @@
BH1750 Ambient Light Sensor
===========================
The BH1750 sensor allows you to use your BH1750 i2c-enabled ambient light sensor with
esphomelib (`datasheet <http://www.mouser.com/ds/2/348/bh1750fvi-e-186247.pdf>`__).
It requires i2c to be setup to work.
Example Usage
-------------
.. code-block:: cpp
// Basic
auto bh1750 = App.make_bh1750_sensor("BH1750 Illuminance");
// Advanced settings
// default resolution is 0.5 LX
bh1750.bh1750->set_resolution(sensor::BH1750_RESOLUTION_1P0_LX);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_bh1750_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::BH1750Sensor
:members:
:protected-members:
:undoc-members:
.. doxygenenum:: sensor::BH1750Resolution

View File

@ -1,47 +0,0 @@
BME280 Temperature/Pressure/Humidity Sensor
===========================================
The BME280 sensor allows you to use your BME280 i2c-enabled temperature+pressure+humidity sensor with
esphomelib (`datasheet <https://cdn-shop.adafruit.com/datasheets/BST-BME280_DS001-10.pdf>`__,
`adafruit <https://www.adafruit.com/product/2652>`__). It requires i2c to be setup to work.
Example Usage
-------------
.. code-block:: cpp
// Basic
auto bme280 = App.make_bme280_sensor("BME280 Temperature", "BME280 Pressure", "BME280 Humidity");
// Advanced settings
// set infinite impulse response filter, default is OFF.
bme280.bme280->set_iir_filter(sensor::BME280_IIR_FILTER_4X);
// set over value sampling, default is 16x
bme280.bme280->set_temperature_oversampling(sensor::BME280_OVERSAMPLING_16X);
bme280.bme280->set_humidity_oversampling(sensor::BME280_OVERSAMPLING_4X);
bme280.bme280->set_pressure_oversampling(sensor::BME280_OVERSAMPLING_16X);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_bme280_sensor`.
API Reference
-------------
.. doxygenclass:: sensor::BME280Component
:members:
:protected-members:
:undoc-members:
.. doxygenenum:: sensor::BME280Oversampling
.. doxygenenum:: sensor::BME280IIRFilter
.. doxygentypedef:: sensor::BME280TemperatureSensor
.. doxygentypedef:: sensor::BME280PressureSensor
.. doxygentypedef:: sensor::BME280HumiditySensor
.. doxygenstruct:: sensor::BME280CalibrationData
:members:
:protected-members:
:undoc-members:

Before

Width:  |  Height:  |  Size: 1.5 KiB

View File

@ -1,48 +0,0 @@
BME680 Temperature/Pressure/Humidity/Gas Sensor
===============================================
The BME680 sensor allows you to use your BME680 i2c-enabled temperature+pressure+humidity+gas
sensor with esphomelib (`datasheet <https://cdn-shop.adafruit.com/product-files/3660/BME680.pdf>`__,
`adafruit <https://www.adafruit.com/product/3660>`__). It requires i2c to be setup to work.
Example Usage
-------------
.. code-block:: cpp
// Basic
auto bme680 = App.make_bme680_sensor("BME680 Temperature",
"BME680 Pressure",
"BME680 Humidity",
"BME680 Gas Resistance");
// default is no iir filter
bme680.bme680->set_iir_filter(sensor::BME680_IIR_FILTER_15X);
// set heater to 200°C for 100ms, default is off
bme680.bme680->set_heater(200, 100);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_bme680_sensor`.
API Reference
-------------
.. doxygenclass:: sensor::BME680Component
:members:
:protected-members:
:undoc-members:
.. doxygenenum:: sensor::BME680Oversampling
.. doxygenenum:: sensor::BME680IIRFilter
.. doxygentypedef:: sensor::BME680TemperatureSensor
.. doxygentypedef:: sensor::BME680PressureSensor
.. doxygentypedef:: sensor::BME680HumiditySensor
.. doxygentypedef:: sensor::BME680GasResistanceSensor
.. doxygenstruct:: sensor::BME680CalibrationData
:members:
:protected-members:
:undoc-members:

Before

Width:  |  Height:  |  Size: 1.5 KiB

View File

@ -1,36 +0,0 @@
BMP085 Pressure/Temperature Sensor
==================================
The BMP085 component allows you get the temperature and pressure from your BMP085
(`datasheet BMP085 <https://www.sparkfun.com/datasheets/Components/General/BST-BMP085-DS000-05.pdf>`_,
`adafruit BMP085 <https://www.adafruit.com/product/391>`_), BMP180
(`datasheet BMP180 <https://cdn-shop.adafruit.com/datasheets/BST-BMP180-DS000-09.pdf>`_,
`adafruit BMP180 <https://www.adafruit.com/product/1603>`_) and BMP280
(`datasheet BMP280 <https://cdn-shop.adafruit.com/datasheets/BST-BMP280-DS001-11.pdf>`_,
`adafruit BMP280 <https://www.adafruit.com/product/2651>`_) sensors with esphomelib. To use these
i2c-based devices, first initialize the i2c bus using the pins you have for SDA and SCL and
then create the sensors themselves as in below example.
Example Usage
-------------
.. code-block:: cpp
// inside setup()
App.init_i2c(SDA_PIN, SCL_PIN); // change these values for your pins.
// create sensors
App.make_bmp085_sensor("Outside Temperature", "Outside Pressure");
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_bmp085_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::BMP085Component
:members:
:protected-members:
:undoc-members:

Before

Width:  |  Height:  |  Size: 1.3 KiB

View File

@ -1,26 +0,0 @@
BMP280 Temperature/Pressure Sensor
==================================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_bmp280_sensor`.
API Reference
-------------
.. doxygenclass:: sensor::BMP280Component
:members:
:protected-members:
:undoc-members:
.. doxygenenum:: sensor::BMP280Oversampling
.. doxygenenum:: sensor::BMP280IIRFilter
.. doxygentypedef:: sensor::BMP280TemperatureSensor
.. doxygentypedef:: sensor::BMP280PressureSensor
.. doxygenstruct:: sensor::BMP280CalibrationData
:members:
:protected-members:
:undoc-members:

Before

Width:  |  Height:  |  Size: 575 B

View File

@ -1,22 +0,0 @@
CSE7766 Power Sensor
====================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_cse7766`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::CSE7766Component
:members:
:protected-members:
:undoc-members:
.. doxygentypedef:: sensor::CSE7766VoltageSensor
.. doxygentypedef:: sensor::CSE7766CurrentSensor
.. doxygentypedef:: sensor::CSE7766PowerSensor

View File

@ -1,45 +0,0 @@
Dallas Component
================
.. cpp:namespace:: input
This class allows using Dallas (DS18b20) devices with esphomelib. You first have to
create a hub or bus where all sensors are connected to (:cpp:class:`DallasComponent`).
.. cpp:namespace:: sensor::DallasComponent
Next, use :cpp:func:`get_sensor_by_address` and :cpp:func:`get_sensor_by_index` to get
individual sensors. You can get the addresses of dallas sensors by observing the log output
at startup time.
Example Usage
-------------
.. code-block:: cpp
// Bus setup
auto *dallas = App.make_dallas_component(15);
// By address
App.register_sensor(dallas->get_sensor_by_address("Ambient Temperature", 0xfe0000031f1eaf29));
// By index
App.register_sensor(dallas->get_sensor_by_index("Ambient Temperature", 0));
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_dallas_component` and :cpp:func:`Application::register_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::DallasComponent
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::DallasTemperatureSensor
:members:
:protected-members:
:undoc-members:

View File

@ -1,24 +0,0 @@
DHT Temperature/Humidity Sensor
===============================
Example Usage
-------------
.. code-block:: cpp
// Basic
App.make_dht_sensor("Outside Temperature", "Outside Humidity", 12);
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_dht_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::DHTComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,27 +0,0 @@
DHT12 Temperature/Humidity Sensor
=================================
Example Usage
-------------
.. code-block:: cpp
// Basic
App.make_dht12_sensor("Outside Temperature", "Outside Humidity");
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_dht12_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygentypedef:: sensor::DHT12TemperatureSensor
.. doxygentypedef:: sensor::DHT12HumiditySensor
.. doxygenclass:: sensor::DHT12Component
:members:
:protected-members:
:undoc-members:

View File

@ -1,16 +0,0 @@
Duty Cycle Sensor
=================
See :cpp:func:`Application::make_duty_cycle_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::DutyCycleSensor
:members:
:protected-members:
:undoc-members:
.. doxygenvariable:: sensor::duty_cycle_sensors

View File

@ -1,14 +0,0 @@
ESP32 Hall Sensor
=================
See :cpp:func:`Application::make_esp32_hall_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::ESP32HallSensor
:members:
:protected-members:
:undoc-members:

View File

@ -1,32 +0,0 @@
HDC1080 Temperature/Humidity Sensor
===================================
The HDC1080 component allows you get accurate temperature and humidity readings from your HDC1080
(`datasheet <http://www.ti.com/lit/ds/symlink/hdc1080.pdf>`_,
`adafruit <https://www.adafruit.com/product/2635>`_) sensors with esphomelib. To use these
i2c-based devices, first initialize the i2c bus using the pins you have for SDA and SCL and
then create the sensors themselves as in below example.
Example Usage
-------------
.. code-block:: cpp
// inside setup()
App.init_i2c(SDA_PIN, SCL_PIN); // change these values for your pins.
// create sensors
App.make_hdc1080_sensor("Outside Temperature", "Outside Humidity");
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_hdc1080_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::HDC1080Component
:members:
:protected-members:
:undoc-members:

View File

@ -1,28 +0,0 @@
HLW8012 Power Sensor
====================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_hlw8012`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::HLW8012Component
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::HLW8012VoltageSensor
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::HLW8012CurrentSensor
:members:
:protected-members:
:undoc-members:
.. doxygentypedef:: HLW8012PowerSensor

View File

@ -1,20 +0,0 @@
HMC5883L Magnetometer
=====================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_hmc5883l`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::HMC5883LComponent
:members:
:protected-members:
:undoc-members:
.. doxygenenum:: sensor::HMC5883LRange
.. doxygentypedef:: sensor::HMC5883LFieldStrengthSensor
.. doxygentypedef:: sensor::HMC5883LHeadingSensor

View File

@ -1,32 +0,0 @@
HTU21D Temperature/Humidity Sensor
==================================
The HTU21D component allows you get accurate temperature and humidity readings from your HTU21D
(`datasheet <https://cdn-shop.adafruit.com/datasheets/1899_HTU21D.pdf>`_,
`adafruit <https://www.adafruit.com/product/1899>`_) sensors with esphomelib. To use these
i2c-based devices, first initialize the i2c bus using the pins you have for SDA and SCL and
then create the sensors themselves as in below example.
Example Usage
-------------
.. code-block:: cpp
// inside setup()
App.init_i2c(SDA_PIN, SCL_PIN); // change these values for your pins.
// create sensors
App.make_htu21d_sensor("Outside Temperature", "Outside Humidity");
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_htu21d_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::HTU21DComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,18 +0,0 @@
HX711 Load Cell Amplifier
=========================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_hx711_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::HX711Sensor
:members:
:protected-members:
:undoc-members:

View File

@ -1,20 +0,0 @@
INA219 DC Current Sensor
========================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_ina219`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::INA219Component
:members:
:protected-members:
:undoc-members:
.. doxygentypedef:: INA219VoltageSensor
.. doxygentypedef:: INA219CurrentSensor
.. doxygentypedef:: INA219PowerSensor

View File

@ -1,20 +0,0 @@
INA3221 3-Channel DC Current Sensor
===================================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_ina3221`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::INA3221Component
:members:
:protected-members:
:undoc-members:
.. doxygentypedef:: INA3221VoltageSensor
.. doxygentypedef:: INA3221CurrentSensor
.. doxygentypedef:: INA3221PowerSensor

View File

@ -1,140 +0,0 @@
Sensor
======
The `sensor` namespace contains all sensors.
.. cpp:namespace:: nullptr
See :cpp:func:`Application::register_sensor`.
.. toctree::
:glob:
*
API Reference
-------------
.. cpp:namespace:: nullptr
Sensor
******
.. doxygenclass:: sensor::Sensor
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::PollingSensorComponent
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::EmptySensor
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::EmptyPollingParentSensor
:members:
:protected-members:
:undoc-members:
.. doxygenvariable:: sensor::ICON_EMPTY
.. doxygenvariable:: sensor::ICON_WATER_PERCENT
.. doxygenvariable:: sensor::ICON_GAUGE
.. doxygenvariable:: sensor::ICON_FLASH
.. doxygenvariable:: sensor::ICON_SCREEN_ROTATION
.. doxygenvariable:: sensor::ICON_BRIEFCASE_DOWNLOAD
.. doxygenvariable:: sensor::UNIT_C
.. doxygenvariable:: sensor::UNIT_PERCENT
.. doxygenvariable:: sensor::UNIT_HPA
.. doxygenvariable:: sensor::UNIT_V
.. doxygenvariable:: sensor::UNIT_DEGREES_PER_SECOND
.. doxygenvariable:: sensor::UNIT_M_PER_S_SQUARED
Filter
******
.. doxygenclass:: sensor::Filter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::SlidingWindowMovingAverageFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::ExponentialMovingAverageFilter
:members:
:protected-members:
:undoc-members:
.. doxygentypedef:: sensor::lambda_filter_t
.. doxygenclass:: sensor::LambdaFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::OffsetFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::MultiplyFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::FilterOutValueFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::FilterOutNANFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::ThrottleFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::HeartbeatFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::DebounceFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::DeltaFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::OrFilter
:members:
:protected-members:
:undoc-members:
.. doxygenclass:: sensor::UniqueFilter
:members:
:protected-members:
:undoc-members:
MQTTSensorComponent
*******************
.. doxygenclass:: sensor::MQTTSensorComponent
:members:
:protected-members:
:undoc-members:

View File

@ -1,16 +0,0 @@
MAX31855 K-Type Thermocouple Temperature Sensor
===============================================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_max31855_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::MAX31855Sensor
:members:
:protected-members:
:undoc-members:

View File

@ -1,16 +0,0 @@
MAX6675 K-Type Thermocouple Temperature Sensor
==============================================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_max6675_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::MAX6675Sensor
:members:
:protected-members:
:undoc-members:

View File

@ -1,19 +0,0 @@
MH-Z19 CO_2 and Temperature Sensor
==================================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_mhz19_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::MHZ19Component
:members:
:protected-members:
:undoc-members:
.. doxygentypedef:: MHZ19CO2Sensor
.. doxygentypedef:: MHZ19TemperatureSensor

View File

@ -1,43 +0,0 @@
MPU6050 Accelerometer/Gyroscope Component
=========================================
The MPU6050 allows you to use your MPU6050 i2c-enabled accelerometers/gyroscopes with
esphomelib (`datasheet <https://www.invensense.com/wp-content/uploads/2015/02/MPU-6000-Datasheet1.pdf>`__,
`Sparkfun <https://www.sparkfun.com/products/11028>`__). It requires i2c to be setup to work.
This component only supports reading in the measurements directly from the registers of the chip
at the moment. If you do need some more complicated signal processing and/or configuration options,
I would recommend copying the code over and creating your own custom component, as supporting every
single possible configuration is not esphomelib's ultimate goal with a chip that supports such a
variety of options.
Example Usage
-------------
.. code-block:: cpp
// inside setup()
App.init_i2c(SDA_PIN, SCL_PIN); // change these values for your pins.
// create sensors
auto *mpu6050 = App.make_mpu6050_sensor();
App.register_sensor(mpu6050->make_accel_x_sensor("MPU6050 Accel X"));
App.register_sensor(mpu6050->make_accel_y_sensor("MPU6050 Accel Y"));
App.register_sensor(mpu6050->make_accel_z_sensor("MPU6050 Accel Z"));
App.register_sensor(mpu6050->make_gyro_x_sensor("MPU6050 Gyro X"));
App.register_sensor(mpu6050->make_gyro_y_sensor("MPU6050 Gyro Y"));
App.register_sensor(mpu6050->make_gyro_z_sensor("MPU6050 Gyro Z"));
App.register_sensor(mpu6050->make_temperature_sensor("MPU6050 Temperature"));
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_mpu6050_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::MPU6050Component
:members:
:protected-members:
:undoc-members:

View File

@ -1,16 +0,0 @@
MQTT Subscribe Sensor
=====================
.. cpp:namespace:: nullptr
See :cpp:func:`Application::make_mqtt_subscribe_sensor`.
API Reference
-------------
.. cpp:namespace:: nullptr
.. doxygenclass:: sensor::MQTTSubscribeSensor
:members:
:protected-members:
:undoc-members:

Some files were not shown because too many files have changed in this diff Show More