Merge pull request #4243 from esphome/bump-2024.9.0b1

2024.9.0b1
This commit is contained in:
Jesse Hills 2024-09-11 20:53:11 +12:00 committed by GitHub
commit d267ea62c2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
54 changed files with 1648 additions and 86 deletions

View File

@ -38,7 +38,7 @@ PROJECT_NAME = "ESPHome"
# could be handy for archiving the generated documentation or if some version
# control system is used.
PROJECT_NUMBER = 2024.8.3
PROJECT_NUMBER = 2024.9.0b1
# 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

View File

@ -1,5 +1,5 @@
ESPHOME_PATH = ../esphome
ESPHOME_REF = 2024.8.3
ESPHOME_REF = 2024.9.0b1
PAGEFIND_VERSION=1.1.0
PAGEFIND=pagefind
NET_PAGEFIND=../pagefindbin/pagefind

Binary file not shown.

After

Width:  |  Height:  |  Size: 196 KiB

View File

@ -1 +1 @@
2024.8.3
2024.9.0b1

181
changelog/2024.9.0.rst Normal file
View File

@ -0,0 +1,181 @@
ESPHome 2024.9.0 - 18th September 2024
======================================
.. seo::
:description: Changelog for ESPHome 2024.9.0.
:image: /_static/changelog-2024.9.0.png
:author: Jesse Hills
:author_twitter: @jesserockz
.. imgtable::
:columns: 3
UDP, components/udp, udp.svg
StatsD, components/statsd, connection.svg
BL0906, components/sensor/bl0906, bl0906.png
CH422G, components/ch422g, ch422g.svg
BMP280 SPI, components/sensor/bmp280, bmp280.jpg
LTR501 & LTR301 & LTR558, components/sensor/ltr501, ltr501.jpg
Full list of changes
--------------------
New Components
^^^^^^^^^^^^^^
- Add support for BL0906 energy meter :esphomepr:`7339` by :ghuser:`tarontop` (new-integration)
- [udp] Implement UDP sensor broadcast :esphomepr:`6865` by :ghuser:`clydebarrow` (new-integration)
- CH422G support :esphomepr:`7356` by :ghuser:`jesterret` (new-integration)
- Add StatsD component :esphomepr:`6642` by :ghuser:`Links2004` (new-integration)
- Add support for using BMP280 with SPI :esphomepr:`7053` by :ghuser:`ademuri` (new-integration) (breaking-change)
- LTR-501, LTR-301, LTR-558 Series of Lite-On Light (ALS) and Proximity(PS) sensors :esphomepr:`6262` by :ghuser:`latonita` (new-integration)
Breaking Changes
^^^^^^^^^^^^^^^^
- [ili9xxx] Make `invert_colors` required :esphomepr:`7292` by :ghuser:`gvdhoven` (breaking-change)
- Add support for using BMP280 with SPI :esphomepr:`7053` by :ghuser:`ademuri` (new-integration) (breaking-change)
- Move I2S config settings the the base i2sAudio files. Phase 1 :esphomepr:`7183` by :ghuser:`nielsnl68` (breaking-change)
- [i2s_audio] Add more options to speakers and microphones :esphomepr:`7306` by :ghuser:`pyos` (breaking-change)
All changes
^^^^^^^^^^^
- [code-quality] fix performance-unnecessary-value-param :esphomepr:`7274` by :ghuser:`tomaszduda23`
- [code-quality] fix clang-tidy prometheus :esphomepr:`7284` by :ghuser:`tomaszduda23`
- [code-quality] fix clang-tidy ota :esphomepr:`7282` by :ghuser:`tomaszduda23`
- [code-quality] fix clang-tidy e131 :esphomepr:`7281` by :ghuser:`tomaszduda23`
- [code-quality] fix clang-tidy wireguard :esphomepr:`7287` by :ghuser:`tomaszduda23`
- [code-quality] fix clang-tidy improv_serial :esphomepr:`7283` by :ghuser:`tomaszduda23`
- [code-quality] fix clang-tidy captive_portal :esphomepr:`7280` by :ghuser:`tomaszduda23`
- Add HMAC-MD5 support for authenticating OTA updates :esphomepr:`7200` by :ghuser:`dwmw2` (new-integration)
- [const] Add UNIT_LITRE :esphomepr:`7317` by :ghuser:`Roving-Ronin`
- [code-quality] fix clang-tidy socket :esphomepr:`7285` by :ghuser:`tomaszduda23`
- [code-quality] fix clang-tidy cstddef :esphomepr:`7324` by :ghuser:`tomaszduda23`
- Add output source priority "hybrid" :esphomepr:`7322` by :ghuser:`syssi`
- Enable verbose mode from env ESPHOME_VERBOSE or --verbose :esphomepr:`6987` by :ghuser:`ptr727`
- Tuya Number: allow to set hidden datapoints :esphomepr:`7024` by :ghuser:`szupi-ipuzs`
- feat: Expand ByteBuffer :esphomepr:`7316` by :ghuser:`Rapsssito`
- [ledc] Tweak fix in #6997 :esphomepr:`7336` by :ghuser:`kbx81`
- [ledc] Fix maximum brightness on ESP-IDF 5.1 :esphomepr:`7342` by :ghuser:`clydebarrow`
- [lvgl] Bug fixes: :esphomepr:`7341` by :ghuser:`clydebarrow`
- [const] Move ``CONF_LINE_FREQUENCY`` to const.py :esphomepr:`7351` by :ghuser:`jesserockz`
- bl0942: Fix init sequence, add address and line_frequency options :esphomepr:`7250` by :ghuser:`dwmw2`
- Add supported formats to media player :esphomepr:`7318` by :ghuser:`synesthesiam`
- Add reset to esp32_rmt_led_strip :esphomepr:`7354` by :ghuser:`angelnu`
- [ili9xxx] Make `invert_colors` required :esphomepr:`7292` by :ghuser:`gvdhoven` (breaking-change)
- Add WS2811 to esp32_rmt_led_strip :esphomepr:`7353` by :ghuser:`angelnu`
- [lvgl] Add lvgl.widget.focus action and related triggers. :esphomepr:`7315` by :ghuser:`clydebarrow`
- esp32_can: suppress compiler warning :esphomepr:`7372` by :ghuser:`mrk-its`
- Add support for BL0906 energy meter :esphomepr:`7339` by :ghuser:`tarontop` (new-integration)
- [platformio] Add environments for ESP-IDF 5.3 for development :esphomepr:`7371` by :ghuser:`clydebarrow`
- [lvgl] Bug fixes :esphomepr:`7370` by :ghuser:`clydebarrow`
- [bytebuffer] Use existing bit_cast operations. :esphomepr:`7374` by :ghuser:`clydebarrow`
- Bump actions/setup-python from 5.1.0 to 5.2.0 :esphomepr:`7375` by :ghuser:`dependabot[bot]`
- Bump actions/setup-python from 5.1.1 to 5.2.0 in /.github/actions/restore-python :esphomepr:`7376` by :ghuser:`dependabot[bot]`
- [gt911] Add reset pin config :esphomepr:`7373` by :ghuser:`clydebarrow`
- [st7701s] Add delay feature in init sequences :esphomepr:`7343` by :ghuser:`clydebarrow`
- Add now required `invert_colors` option to test files referencing ili9xxx :esphomepr:`7367` by :ghuser:`clydebarrow`
- esp32_can: make queue lengths configurable :esphomepr:`7361` by :ghuser:`mrk-its`
- [code-quality] fix clang-tidy web_server and web_server_base :esphomepr:`7286` by :ghuser:`tomaszduda23`
- Update MiCS Values :esphomepr:`7173` by :ghuser:`TrevorSchirmer`
- Tuya Number: allow restoring value of hidden datapoints :esphomepr:`7346` by :ghuser:`szupi-ipuzs`
- [udp] Implement UDP sensor broadcast :esphomepr:`6865` by :ghuser:`clydebarrow` (new-integration)
- update logs for bluetooth proxy :esphomepr:`7382` by :ghuser:`tomaszduda23`
- [font] Make display an auto-load, not a dependency :esphomepr:`7366` by :ghuser:`clydebarrow`
- CH422G support :esphomepr:`7356` by :ghuser:`jesterret` (new-integration)
- [rpi_dpi_rgb] Add enable_pin and reset_display method to driver :esphomepr:`7383` by :ghuser:`lboue`
- Bump actions/upload-artifact from 4.3.4 to 4.4.0 :esphomepr:`7379` by :ghuser:`dependabot[bot]`
- Fix build for esp32h2 using esp-idf 5.3 :esphomepr:`7393` by :ghuser:`mrene`
- Bump mDNS and follow ruff's suggestions :esphomepr:`7308` by :ghuser:`HeMan`
- Bump rp2040 Arduino platform and framework :esphomepr:`7134` by :ghuser:`HeMan`
- [gree] Add support for YX1FF remote :esphomepr:`7298` by :ghuser:`dangreco`
- [modbus_controller] Allow duplicate command config :esphomepr:`7311` by :ghuser:`0x3333`
- Better support for task blocking ring buffer reads and writes :esphomepr:`7390` by :ghuser:`kahrendt`
- Bump pypa/gh-action-pypi-publish from 1.9.0 to 1.10.0 :esphomepr:`7395` by :ghuser:`dependabot[bot]`
- [api] Remove id from ``MediaPlayerSupportedFormat`` :esphomepr:`7406` by :ghuser:`jesserockz`
- Drop max BLE client connections limitation :esphomepr:`7088` by :ghuser:`syssi`
- [bl0942] loop and overflow cleanup :esphomepr:`7358` by :ghuser:`dwmw2`
- Bump peter-evans/create-pull-request from 6.1.0 to 7.0.0 :esphomepr:`7405` by :ghuser:`dependabot[bot]`
- Bump pypa/gh-action-pypi-publish from 1.10.0 to 1.10.1 :esphomepr:`7404` by :ghuser:`dependabot[bot]`
- Voice assist improvement - configurable conversation_id timeout :esphomepr:`7385` by :ghuser:`jeffc`
- Support BL0942 calibration :esphomepr:`7299` by :ghuser:`dwmw2`
- [micro_wake_word] Remove duplicated download code :esphomepr:`7401` by :ghuser:`jesserockz`
- Add StatsD component :esphomepr:`6642` by :ghuser:`Links2004` (new-integration)
- [homeassistant-switch] Support different entity domains :esphomepr:`7331` by :ghuser:`jesserockz`
- Add support for using BMP280 with SPI :esphomepr:`7053` by :ghuser:`ademuri` (new-integration) (breaking-change)
- Add voice assistant announce :esphomepr:`7377` by :ghuser:`synesthesiam`
- [lvgl] Msgbox fixes and enhancements :esphomepr:`7380` by :ghuser:`clydebarrow`
- libretiny: Allow specifying version of explicitly imported sources :esphomepr:`7408` by :ghuser:`dwmw2`
- [libretiny] Report version 1.7.0 for 'dev' and 'latest' :esphomepr:`7415` by :ghuser:`dwmw2`
- LTR-501, LTR-301, LTR-558 Series of Lite-On Light (ALS) and Proximity(PS) sensors :esphomepr:`6262` by :ghuser:`latonita` (new-integration)
- Fix armv7 container builds :esphomepr:`7426` by :ghuser:`jesserockz`
- [gh-actions] Don't produce docker build summaries :esphomepr:`7430` by :ghuser:`jesserockz`
- Add BK72xx support to require_framework_version() :esphomepr:`7409` by :ghuser:`dwmw2`
- Switch IPv6 platform check to use require_framework_version() :esphomepr:`7410` by :ghuser:`dwmw2`
- [bl0942] Improve energy reporting :esphomepr:`7428` by :ghuser:`dwmw2`
- [rpi_dpi_rgb] Add bounce_buffer config for ESP-IDF 5.x :esphomepr:`7423` by :ghuser:`clydebarrow`
- [LVGL] Add color gradients :esphomepr:`7427` by :ghuser:`clydebarrow`
- [dsmr] Add internal 'telegram' text_sensor to support bridging :esphomepr:`6841` by :ghuser:`marcovaneck`
- Pull in new AsyncTCP for IPv6 on BK72xx :esphomepr:`7431` by :ghuser:`dwmw2`
- Bump LibreTiny recommended version to 1.7.0 :esphomepr:`7432` by :ghuser:`dwmw2`
- Enable IPv6 support for BK72xx :esphomepr:`7398` by :ghuser:`dwmw2`
- Move I2S config settings the the base i2sAudio files. Phase 1 :esphomepr:`7183` by :ghuser:`nielsnl68` (breaking-change)
- Implement all supported thermocouple types for MAX31856 :esphomepr:`7218` by :ghuser:`ArkanStasarik`
- [i2s_audio] Add more options to speakers and microphones :esphomepr:`7306` by :ghuser:`pyos` (breaking-change)
- [uponor_smatrix] Modifies sending algorithm :esphomepr:`7326` by :ghuser:`skasi7`
- User configurable frame buffer. :esphomepr:`7360` by :ghuser:`ajwahab`
- [Modbus Controller] Added preference to change command retries :esphomepr:`7312` by :ghuser:`0x3333`
Past Changelogs
---------------
- :doc:`2024.8.0`
- :doc:`2024.7.0`
- :doc:`2024.6.0`
- :doc:`2024.5.0`
- :doc:`2024.4.0`
- :doc:`2024.3.0`
- :doc:`2024.2.0`
- :doc:`2023.12.0`
- :doc:`2023.11.0`
- :doc:`2023.10.0`
- :doc:`2023.9.0`
- :doc:`2023.8.0`
- :doc:`2023.7.0`
- :doc:`2023.6.0`
- :doc:`2023.5.0`
- :doc:`2023.4.0`
- :doc:`2023.3.0`
- :doc:`2023.2.0`
- :doc:`2022.12.0`
- :doc:`2022.11.0`
- :doc:`2022.10.0`
- :doc:`2022.9.0`
- :doc:`2022.8.0`
- :doc:`2022.6.0`
- :doc:`2022.5.0`
- :doc:`2022.4.0`
- :doc:`2022.3.0`
- :doc:`2022.2.0`
- :doc:`2022.1.0`
- :doc:`2021.12.0`
- :doc:`2021.11.0`
- :doc:`2021.10.0`
- :doc:`2021.9.0`
- :doc:`2021.8.0`
- :doc:`v1.20.0`
- :doc:`v1.19.0`
- :doc:`v1.18.0`
- :doc:`v1.17.0`
- :doc:`v1.16.0`
- :doc:`v1.15.0`
- :doc:`v1.14.0`
- :doc:`v1.13.0`
- :doc:`v1.12.0`
- :doc:`v1.11.0`
- :doc:`v1.10.0`
- :doc:`v1.9.0`
- :doc:`v1.8.0`
- :doc:`v1.7.0`

View File

@ -2,7 +2,7 @@ Changelog
=========
.. redirect::
:url: /changelog/2024.8.0.html
:url: /changelog/2024.9.0.html
.. toctree::
:glob:

View File

@ -0,0 +1,49 @@
UDP Binary Sensor
=================
.. seo::
:description: Instructions for setting up a UDP binary sensor.
:image: udp.svg
The ``udp`` binary sensor platform allows you to receive binary sensor data directly from another ESPHome node.
.. code-block:: yaml
# Example configuration entry
binary_sensor:
- platform: udp
id: switch_status
provider: light-switch
remote_id: light_switch
Configuration variables
-----------------------
- **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation.
- **provider** (**Required**, string): The name of the provider node.
- **remote_id** (*Optional*, :ref:`config-id`): The ID of the original binary sensor in the provider device. If not specified defaults to the ID configured with ``id:``.
- **name** (*Optional*, string): The name of the binary sensor.
- **internal** (*Optional*, boolean): Whether the sensor should be exposed via API (e.g. to Home Assistant.) Defaults to ``true`` if name is not set, required if name is provided.
- All other options from :ref:`Binary Sensor <config-binary_sensor>`.
At least one of ``id`` and ``remote_id`` must be configured.
Publishing to Home Assistant
----------------------------
Typically this type of binary sensor would be used for internal automation purposes rather than having it published back to
Home Assistant, since it would be a duplicate of the original sensor.
If it *is* desired to expose the binary sensor to Home Assistant, then the ``internal:`` configuration setting needs to be explicitly
set to ``false`` and a name provided.
Only the state (i.e. binary value) of the remote sensor is received by the consumer, so any other attributes must be explicitly
configured.
See Also
--------
- :doc:`/components/udp`
- :doc:`/components/sensor/index`
- :ref:`automation`
- :apiref:`udp/udp_component.h`
- :ghedit:`Edit`

View File

@ -26,6 +26,8 @@ Configuration variables:
- **rx_pin** (**Required**, :ref:`Pin <config-pin>`): Receive pin.
- **tx_pin** (**Required**, :ref:`Pin <config-pin>`): Transmit pin.
- **rx_queue_len** (**Optional**, int): Length of RX queue.
- **tx_queue_len** (**Optional**, int): Length of TX queue, 0 to disable.
- All other options from :ref:`Canbus <config-canbus>`.
.. _esp32-can-bit-rate:

67
components/ch422g.rst Normal file
View File

@ -0,0 +1,67 @@
CH422G I/O Expander
====================
.. seo::
:description: Instructions for setting up CH422G digital port expanders in ESPHome.
:image: ch422g.svg
The CH422G component allows you to use the **CH422G** I/O expander in ESPHome.
It uses an :ref:`I²C Bus <i2c>` for communication.
Once configured, you can use any of the 8 available GPIO pins for your projects.
Within ESPHome they can be used in place of internal GPIO pins in many of ESPHome's components such as the GPIO Binary Sensor or GPIO Switch. They are not usable for PWM or other situations requiring an internal GPIO pin.
.. note::
This I/O Expander chip is used in the *Waveshare ESP32-S3-Touch-LCD-4.3*
.. code-block:: yaml
# Example configuration entry
ch422g:
- id: ch422g_hub
address: 0x24
# Individual outputs
switch:
- platform: gpio
name: CH422G Pin 0
pin:
ch422g: ch422g_hub
number: 0
mode:
output: true
inverted: false
Configuration variables:
************************
- **id** (**Required**, :ref:`config-id`): The id to use for this ``ch422g`` component.
- **address** (*Optional*, int): The I²C address of the driver.
Defaults to ``0x24``.
- **restore_value** (*Optional*, boolean): Writes default flags on setup, overriding values from chips cache.
Defaults to ``false``.
Pin configuration variables:
****************************
- **ch422g** (**Required**, :ref:`config-id`): The id of the ``ch422g`` component of the pin.
- **number** (**Required**, int): The pin number. Valid numbers are 0-7.
- **inverted** (*Optional*, boolean): If all read and written values
should be treated as inverted. Defaults to ``false``.
- **mode** (*Optional*, string): A pin mode to set the pin at. One of ``INPUT`` or ``OUTPUT``.
See Also
--------
- :ref:`i2c`
- :doc:`switch/gpio`
- :doc:`binary_sensor/gpio`
- `CH422G datasheet <https://www.wch-ic.com/downloads/file/315.html?time=2024-07-29%2002:02:32&code=Fxex1sTRHysGLS6ALgh7PTOOZnAACY6KTQx05vzD>`__
- :apiref:`ch422g/ch422g.h`
- :ghedit:`Edit`

View File

@ -162,6 +162,7 @@ The Daikin ARC remotes (``daikin_arc`` climate, ``daikin_arc417``, ``daikin_arc4
- ``yaa``
- ``yac``
- ``yac1fb9``
- ``yx1ff``
.. code-block:: yaml

View File

@ -61,9 +61,8 @@ beyond the basic SPI connections, and a reasonable amount of RAM, it is not well
model: ili9341
dc_pin: GPIOXX
reset_pin: GPIOXX
lambda: |-
it.fill(COLOR_BLACK);
it.print(0, 0, id(my_font), id(my_red), TextAlign::TOP_LEFT, "Hello World!");
invert_colors: false
show_test_card: true
Configuration variables:
************************
@ -101,7 +100,7 @@ Configuration variables:
- **offset_width** (*Optional*, int): Specify an offset for the x-direction of the display, typically used when an LCD is smaller than the maximum supported by the driver chip. Default is 0
- **offset_height** (*Optional*, int): Specify an offset for the y-direction of the display. Default is 0.
- **invert_colors** (*Optional*): With this boolean option you can invert the display colors.
- **invert_colors** (**Required**): Specifies whether the display colors should be inverted. Options are ``true`` or ``false`` - if you are unsure, use ``false`` and change if the colors are not as expected.
- **pixel_mode** (*Optional*): Allows forcing the display into 18 or 16 bit mode. Options are ``18bit`` or ``16bit``. If unspecified, the pixel mode will be determined by the model choice. Not all displays will work in both modes.
- **rotation** (*Optional*): Rotate the display presentation in software. Choose one of ````, ``90°``, ``180°``, or ``270°``. This option cannot be used with ``transform``.
- **transform** (*Optional*): Transform the display presentation using hardware. All defaults are ``false``. This option cannot be used with ``rotation``.
@ -265,6 +264,7 @@ This config rotates the display into landscape mode using the driver chip.
mirror_x: false
mirror_y: true
color_order: bgr
invert_colors: true
data_rate: 80MHz
cs_pin: GPIOXX
dc_pin: GPIO13

View File

@ -77,6 +77,7 @@ Configuration variables:
- **pclk_pin** (**Required**, :ref:`Pin Schema <config-pin_schema>`): The PCLK pin.
- **hsync_pin** (**Required**, :ref:`Pin Schema <config-pin_schema>`): The Horizontal sync pin.
- **vsync_pin** (**Required**, :ref:`Pin Schema <config-pin_schema>`): The Vertical sync pin.
- **enable_pin** (*Optional*, :ref:`Pin Schema <config-pin_schema>`): The ENABLE pin.
- **reset_pin** (*Optional*, :ref:`Pin Schema <config-pin_schema>`): The RESET pin.
- **hsync_pulse_width** (*Optional*, int): The horizontal sync pulse width.
- **hsync_front_porch** (*Optional*, int): The horizontal front porch length.

View File

@ -130,6 +130,8 @@ The ``init_sequence`` requires a list of elements, one of which may be a single
sequence (the default and currently the only sequence is 1), the remainder must be byte arrays providing additional
init commands, each consisting of a command byte followed by zero or more data bytes.
A delay may be specified with ``delay <N>ms``
These will be collected and sent to the display via SPI during initialisation.
Example configurations
@ -165,6 +167,7 @@ Seeed Sensecap Indicator
pclk_pin: 21
init_sequence:
- 1 # select canned init sequence number 1
- delay 5ms
- [ 0xE0, 0x1F ] # Set sunlight readable enhancement
data_pins:
red:

View File

@ -74,6 +74,8 @@ Frame Settings:
Up to 60Hz is possible (with reduced frame sizes), but beware of overheating. Defaults to ``10 fps``.
- **idle_framerate** (*Optional*, float): The framerate to capture images at when no client
is requesting a full stream. Defaults to ``0.1 fps``.
- **frame_buffer_count** (*Optional*, int): The number of frame buffers to use when reading from the camera sensor.
Must be between 1 and 2. Defaults to ``1``.
Image Settings:

View File

@ -13,7 +13,7 @@ configuration to Home Assistant (the native MAC address is not readily available
.. note::
HA will not automatically discover an ESPHome instance running on ``host`` using MDNS, and you will need
HA will not automatically discover an ESPHome instance running on ``host`` using mDNS, and you will need
to add it explicitly using the IP address of your host computer.
Many components, especially those interfacing to actual hardware, will not be available when using ``host``. Do not

View File

@ -34,6 +34,7 @@ Configuration variables
"ESP32-C3", "0, 1"
- **chipset** (**Required**, enum): The chipset to apply known timings from. Not used if specifying the timings manually, see below.
- ``WS2811``
- ``WS2812``
- ``SK6812``
- ``APA106``
@ -67,6 +68,10 @@ please consider adding support to the codebase and add it to the list above.
- **bit0_low** (*Optional*, :ref:`config-time`): The time to hold the data line low for a ``0`` bit.
- **bit1_high** (*Optional*, :ref:`config-time`): The time to hold the data line high for a ``1`` bit.
- **bit1_low** (*Optional*, :ref:`config-time`): The time to hold the data line low for a ``1`` bit.
- **reset_high** (*Optional*, :ref:`config-time`): The time to hold the data line high after writing
the state. Defaults to ``0 us``.
- **reset_low** (*Optional*, :ref:`config-time`): The time to hold the data line low after writing
the state. Defaults to ``0 us``.
See Also
--------

View File

@ -10,7 +10,7 @@ embedded graphics library to create beautiful UIs for any MCU, MPU and display t
.. figure:: /components/lvgl/images/lvgl_main_screenshot.png
To use LVGL with a :ref:`display <display-hw>` in ESPHome, you'll need an ESP32 or supported ESP32 variant. PSRAM is not a strict requirement but it is generally recommended, especially for color displays with resolutions larger than approximately 240x240 pixels.
To use LVGL with a :ref:`display <display-hw>` in ESPHome, you'll need an ESP32 or RP2040. PSRAM is not a strict requirement but it is generally recommended, especially for large color displays.
The graphic display should be configured with ``auto_clear_enabled: false`` and ``update_interval: never``, and should not have any ``lambda`` set.
@ -113,6 +113,7 @@ The following configuration variables apply to the main ``lvgl`` component, in o
- **disp_bg_image** (*Optional*, :ref:`image <display-image>`): The ID of an existing image configuration, to be used as background wallpaper. To change the image at runtime use the ``lvgl.update`` action. Also see :ref:`lvgl-widget-image` for a note regarding supported image formats.
- **default_font** (*Optional*, ID): The ID of the :ref:`font <lvgl-fonts>` used by default to render the text or symbols. Defaults to LVGL's internal ``montserrat_14`` if not specified.
- **style_definitions** (*Optional*, list): A batch of style definitions to use in LVGL widget's ``styles`` configuration. See :ref:`below <lvgl-theme>` for more details.
- **gradients** (*Optional*, list): A list of gradient definitions to use in *bg_grad* styles. See :ref:`below <lvgl-gradients>` for more details.
- **theme** (*Optional*, list): A list of styles to be applied to all widgets. See :ref:`below <lvgl-theme>` for more details.
- **widgets** (*Optional*, list): A list of :doc:`/components/lvgl/widgets` to be drawn on the root display. May not be used if ``pages`` (below) is configured.
- **pages** (*Optional*, list): A list of page IDs. Each page acts as a parent for widgets placed on it. May not be used with ``widgets`` (above). Options for each page:
@ -243,6 +244,7 @@ You can adjust the appearance of widgets by changing their foreground, backgroun
**Styling variables:**
- **bg_color** (*Optional*, :ref:`color <lvgl-color>`): Color for the background of the widget. Defaults to ``0xFFFFFF`` (white).
- **bg_grad** (*Optional*, :ref:`gradient <lvgl-gradients>`): A gradient to apply to the background.
- **bg_grad_color** (*Optional*, :ref:`color <lvgl-color>`): Color to make the background gradually fade to. Defaults to ``0`` (black).
- **bg_dither_mode** (*Optional*, dict): Set dithering of the background gradient. One of ``NONE``, ``ORDERED``, ``ERR_DIFF``. Defaults to ``NONE``.
- **bg_grad_dir** (*Optional*, dict): Choose the direction of the background gradient: ``NONE``, ``HOR``, ``VER``. Defaults to ``NONE``.
@ -519,6 +521,46 @@ Values for use with ``grid_column_align``, ``grid_row_align``, ``grid_cell_x_ali
To visualize real, calculated sizes of transparent widgets you can temporarily set ``outline_width: 1`` on them.
.. _lvgl-gradients:
Gradients
*********
A gradient is a sequence of colors which can be applied to an object using the ``bg_grad`` style option. Gradients are defined in the *gradients* section of the LVGL configuration by providing two or more color stop points.
Each entry has the following options:
- **id** (**Required**, :ref:`config-id`): The ID with which you will be able to reference the gradient later.
- **direction** (*Optional*, string): The direction of the gradient. Possible options are ``none`` (the default) ``hor`` or ``ver``.
- **dither** (*Optional*, string): A dithering selection. Possible options are ``none`` (the default) ``err_diff`` or ``ordered``.
- **stops** (**Required**, list): A list of at least 2 color stop points. Each stop point has the following options:
- **color** (**Required**, :ref:`Color <lvgl-color>`): The color of the stop point.
- **position** (**Required**, float): The position of the stop point. Must be a float between 0.0 and 1.0, a percentage between 0% and 100%, or an integer between 0 and 255.
.. code-block:: yaml
# Example gradient showing full hue range.
gradients:
- id: color_bar
direction: hor
dither: none
stops:
- color: 0xFF0000
position: 0
- color: 0xFFFF00
position: 42
- color: 0x00FF00
position: 84
- color: 0x00FFFF
position: 127
- color: 0x0000FF
position: 169
- color: 0xFF00FF
position: 212
- color: 0xFF0000
position: 255
Widgets
*******
@ -635,6 +677,56 @@ This :ref:`action <actions-action>` shows a specific page (including pages with
then:
- lvgl.page.show: secret_page # shorthand version
.. _lvgl-widget-focus-action:
``lvgl.widget.focus``
*********************
This :ref:`action <actions-action>` moves the input focus to the nominated widget. Used mainly with encoder inputs
to select a specific widget to receive input events. It may also allow the focus to be frozen on that widget,
or can be used to move the focus to the next or previous widget in the focus group.
The required config options take one of several forms:
- **id** (**Required**): The ID of the widget to be given focus.
- **freeze** (*Optional*, boolean): If true will lock the focus to this widget.
- **editing** (*Optional*, boolean): Sets the editing mode of the widget, i.e. encoder rotation will change the value
of the widget, not move the focus. Defaults to false.
or
- **action** (**Required**): Should be one of ``next``, ``previous``, ``mark`` or ``restore``.
- **group** (*Optional*): The ID of the group within which to move the focus. The default group will be used if not specified
- **freeze** (*Optional*, boolean): If true will lock the focus to the now selected widget.
The ``next`` and ``previous`` actions will move the focus to the next or previous widget within the group.
The ``mark`` action will save the currently focused widget within the group, and restore it when the ``restore`` action is triggered.
.. code-block:: yaml
on_...:
then:
- lvgl.widget.focus:
id: my_button
freeze: true
on_...:
then:
- lvgl.widget.focus: my_button
on_...:
then:
- lvgl.widget.focus:
group: encoder_group
direction: next
freeze: true
on_...:
then:
- lvgl.widget.focus: previous
.. _lvgl-conditions:
Conditions

View File

@ -40,7 +40,7 @@ The properties below are common to all widgets.
- ``"ACTIVE"``: Show scroll bars while a widget is being scrolled.
- ``"AUTO"``: Show scroll bars when the content is large enough to be scrolled (default).
- **align** (*Optional*, dict): Alignment of the of the widget relative to the parent. A child widget is clipped to its parent boundaries. One of the values *not* starting with ``OUT_`` (see picture below).
- **align** (*Optional*, enum): Alignment of the of the widget relative to the parent. A child widget is clipped to its parent boundaries. One of the values *not* starting with ``OUT_`` (see picture below).
- **align_to** (*Optional*, list): Alignment of the of the widget relative to another widget on the same level:
- **id** (**Required**): The ID of a widget *to* which you want to align.
- **align** (**Required**, string): Desired alignment (one of the values starting with ``OUT_``).
@ -116,6 +116,40 @@ In addition to visual styling, each widget supports some boolean **flags** to in
LVGL only supports **integers** for numeric ``value``. Visualizer widgets can't display floats directly, but they allow scaling by 10s.
.. _lvgl-widget-parts:
Widget parts
------------
Widgets can have multiple parts, each of which can be styled independently. For example, a checkbox has a *main* part that styles the background and text label, and an *indicator* part that styles the tick box. All widgets have a *main* part, the available parts for other widgets are specified in the widget description.
The possible parts are:
- **main** (*Optional*, dict): The main part of the widget, i.e. the background. Any style properties applied at the top level of the widget are assumed to apply to this part, but may also be specified under the *main* config key.
- **scrollbar** (*Optional*, dict): The scrollbar styles.
- **indicator** (*Optional*, dict): The indicator part of the widget. The indicator part may be used to show tick boxes or other visual indicators in slider, bar or arc.
- **knob** (*Optional*, dict): The knob part of the widget e.g. a draggable item in slider, bar or arc.
- **selected** (*Optional*, dict): The currently selected part of the widget, e.g. text or the selected item in a roller.
- **items** (*Optional*, dict): The items part of the widget, e.g. the items in a roller.
- **ticks** (*Optional*, dict): Ticks on scales for a meter.
- **cursor** (*Optional*, dict): The cursor part of the widget, e.g. the cursor in a spinbox.
.. code-block:: yaml
# Example slider with knob and indicator styling
- slider:
# main (background) styles
bg_opa: cover
bg_grad: color_bar
radius: 0
indicator:
bg_opa: transp # Makes the indicator part invisible
knob:
radius: 1
width: 4
height: 10%
bg_color: 0x000000
Widget-specific properties
--------------------------
@ -776,8 +810,8 @@ For styling, the ``keyboard`` widget uses the same settings as :ref:`lvgl-widget
**Configuration variables:**
- **textarea** (*Optional*): The ID of the ``textarea`` from which to receive the keystrokes.
- **mode** (*Optional*, dict): Keyboard layout to use. Each ``TEXT_`` layout contains a button to allow the user to iterate through the ``TEXT_`` layouts.
- **textarea** (*Optional*): The ID of a ``textarea`` to associate with the keyboard. If provided, all key entries are recorded in the ``textarea``.
- **mode** (*Optional*, enum): Keyboard layout to use. Each ``TEXT_`` layout contains a button to allow the user to iterate through the ``TEXT_`` layouts.
- ``TEXT_LOWER``: Display lower case letters (default).
- ``TEXT_UPPER``: Display upper case letters.
- ``TEXT_SPECIAL``: Display special characters.
@ -785,9 +819,9 @@ For styling, the ``keyboard`` widget uses the same settings as :ref:`lvgl-widget
**Actions:**
- ``lvgl.keyboard.update`` :ref:`action <actions-action>` updates the widget styles and properties from the specific options above, just like the :ref:`lvgl.widget.update <lvgl-automation-actions>` action is used for the common styles, states or flags.
- **id** (**Required**): The ID or a list of IDs of keyboard widgets which you want update.
- Widget styles or properties from the specific options above, which you want update.
- ``lvgl.keyboard.update`` :ref:`action <actions-action>` updates the properties from the specific options above, plus any from :ref:`lvgl.widget.update <lvgl-automation-actions>`.
- **id** (**Required**): The ID or a list of IDs of keyboard widgets which you want to update.
- Styles or properties to be updated.
**Triggers:**
@ -851,7 +885,7 @@ A label is the basic widget type that is used to display text.
- **recolor** (*Optional*, boolean): Enable recoloring of button text with ``#``. This makes it possible to set the color of characters in the text individually by prefixing the text to be re-colored with a ``#RRGGBB`` hexadecimal color code followed by a *space*, and finally closed with a single hash ``#`` tag. For example: ``Write a #FF0000 red# word``.
- **scrollbar** (*Optional*, list): Settings for the indicator *part* to show the value. Supports a list of :ref:`styles <lvgl-styling>` and state-based styles to customize. The scroll bar that is shown when the text is larger than the widget's size.
- **selected** (*Optional*, list): Settings for the the style of the selected text. Only ``text_color`` and ``bg_color`` style properties can be used.
- **text_align** (*Optional*, dict): Alignment of the text in the widget - it doesn't align the object itself, only the lines inside the object. One of ``LEFT``, ``CENTER``, ``RIGHT``, ``AUTO``. Inherited from parent. Defaults to ``AUTO``, which detects the text base direction and uses left or right alignment accordingly.
- **text_align** (*Optional*, enum): Alignment of the text in the widget - it doesn't align the object itself, only the lines inside the object. One of ``LEFT``, ``CENTER``, ``RIGHT``, ``AUTO``. Inherited from parent. Defaults to ``AUTO``, which detects the text base direction and uses left or right alignment accordingly.
- **text_color** (*Optional*, :ref:`color <lvgl-color>`): Color to render the text in. Inherited from parent. Defaults to ``0`` (black).
- **text_decor** (*Optional*, list): Choose decorations for the text: ``NONE``, ``UNDERLINE``, ``STRIKETHROUGH`` (multiple can be specified as YAML list). Inherited from parent. Defaults to ``NONE``.
- **text_font**: (*Optional*, :ref:`font <lvgl-fonts>`): The ID of the font used to render the text or symbol. Inherited from parent.
@ -1050,6 +1084,9 @@ The meter widget can visualize data in very flexible ways. It can use arcs, need
- **width**: Tick line width in pixels. Defaults to ``5``.
- Style options from :ref:`lvgl-styling` for the tick *lines* and *labels* using the :ref:`lvgl-widget-line` and :ref:`lvgl-widget-label` text style properties.
- Style options from :ref:`lvgl-styling` for the background of the meter, using the typical background properties.
- **ticks** (*Optional*, dict): Styling options for the ticks *part*, which will be applied to the tick lines and labels using standard *line* and *label* styles.
- **indicator** (*Optional*, dict): Styling options for the indicator *part*, which will be applied to the needle line or image using standard *line* and *image* styles.
- **items** (*Optional*, dict): Settings for the items *part*, which will be applied to arcs.
.. note::
@ -1116,7 +1153,7 @@ The text will be broken into multiple lines automatically and the height will be
**Configuration variables:**
- **msgboxes** (*Optional*, dict): A list of message boxes to use. This option has to be added to the top level of the LVGL component configuration.
- **msgboxes** (*Optional*, list): A list of message boxes to use. This option is available only at the top level of the LVGL component configuration. Each list entry may have the following options:
- **title** (**Required**, string): A string to display at the top of the message box.
- **body** (*Optional*, dict): The content of the body of the message box:
- **text** (*Optional*, :ref:`text-property`): The text to display in the body of the message box.
@ -1124,11 +1161,12 @@ The text will be broken into multiple lines automatically and the height will be
- **buttons** (*Optional*, list): A list of buttons to show at the bottom of the message box:
- **text** (*Optional*, :ref:`text-property`): Text to display on the button.
- See :ref:`lvgl-widget-buttonmatrix` for other options for the buttons.
- **close_button** (*Optional*, boolean): Controls the appearance of the close button to the top right of the message box.
- **button_style** (*Optional*, dict): A style to apply to the buttons. Uses all the typical style properties. Buttons cannot be individually styled since they are part of a ``buttonmatrix``.
- **close_button** (*Optional*, boolean): Controls the presence of the close button to the top right of the message box. Defaults to true
**Actions:**
The configured message boxes are hidden by default. One can show them with ``lvgl.widget.show`` and ``lvgl.widget.hide`` :ref:`actions <lvgl-automation-shorthands>`.
The configured message boxes are hidden by default. They can be shown and hidden using ``lvgl.widget.show`` and ``lvgl.widget.hide`` respectively :ref:`actions <lvgl-automation-shorthands>`.
**Example:**
@ -1203,7 +1241,7 @@ Roller allows you to simply select one option from a list by scrolling.
**Configuration variables:**
- **anim_time** (*Optional*, :ref:`Time <config-time>`): When the Roller is scrolled and doesn't stop exactly on an option it will scroll to the nearest valid option automatically in this amount of time.
- **mode** (*Optional*, dict): Option to make the roller circular. ``NORMAL`` or ``INFINITE``, defaults to ``NORMAL``.
- **mode** (*Optional*, enum): Option to make the roller circular. ``NORMAL`` or ``INFINITE``, defaults to ``NORMAL``.
- **options** (**Required**, list): The list of available options in the roller.
- **selected_index** (*Optional*, int8): The index of the item you wish to be selected.
- **selected** (*Optional*, list): Settings for the selected *part* to show the value. Supports a list of :ref:`styles <lvgl-styling>` and state-based styles to customize. The selected option in the middle. Besides the typical background properties it uses the :ref:`lvgl-widget-label` text style properties to change the appearance of the text in the selected area.
@ -1507,14 +1545,14 @@ The tabs are indexed (zero-based) in the order they appear in the configuration
**Configuration variables:**
- **position** (*Optional*, string): Position of the tab selector buttons. One of ``TOP``, ``BOTTOM``, ``LEFT``, ``RIGHT``. Defaults to ``TOP``.
- **position** (*Optional*, enum): Position of the tab selector buttons. One of ``TOP``, ``BOTTOM``, ``LEFT``, ``RIGHT``. Defaults to ``TOP``.
- **size** (*Optional*, percentage): The height (in case of ``TOP``, ``BOTTOM``) or width (in case of ``LEFT``, ``RIGHT``) tab buttons. Defaults to ``10%``.
- **tabs** (**Required**, list): A list with (any number of) tabs to be added to tabview.
- **name** (**Required**): The text to be shown on the button corresponding to the tab.
- **id** (*Optional*): An ID for the tab itself.
- **widgets** (**Required**, list): A list of :doc:`/components/lvgl/widgets` to be drawn on the tab, as children.
- **tab_style** (*Optional*): Style settings for the tabs.
- **items** (*Optional*, list): Settings for the items *part*, the buttons all use the text and typical background style properties except translations and transformations.
- **items** (*Optional*, dict): Settings for the items *part*, the buttons all use the text and typical background style properties except translations and transformations.
**Actions:**
@ -1807,9 +1845,15 @@ ESPHome implements as universal triggers the following interaction events genera
- ``on_scroll``: The widget was scrolled.
- ``on_focus``: The widget is focused.
- ``on_defocus``: The widget is unfocused.
- ``on_all_events``: Will be triggered on any event sent to the widget - this is useful for debugging.
These triggers can be applied directly to any widget in the LVGL configuration, *given that the widget itself supports generating such events*. For the widgets having a value, the triggers return the current value in variable ``x``; this variable may be used in lambdas defined within those triggers.
Each trigger also deliver an ``event`` parameter, which is a pointer to the LVGL C type ``lv_event_t``. This may be used in lambdas defined within those triggers. Refer to the `LVGL documentation <https://docs.lvgl.io/8.4/overview/event.html/>`_ for more information.
There are additional triggers for pages - each page may have an ``on_load`` and ``on_unload`` trigger. These will be called
when the page becomes active or inactive respectively.
.. code-block:: yaml
# Example triggers:

View File

@ -40,13 +40,14 @@ Configuration variables:
- ``external``: Use an external ADC connected to the I²S bus.
- ``internal``: Use the internal ADC of the ESP32. Only supported on ESP32, no variant support.
- **channel** (*Optional*, enum): The channel of the microphone. One of ``left`` or ``right``. Defaults to ``right``.
- **channel** (*Optional*, enum): The channel of the microphone. One of ``left``, ``right``, or ``stereo``. If ``stereo``, the output data will
be twice as big, with each right sample followed by a left sample. Defaults to ``right``.
- **sample_rate** (*Optional*, positive integer): I2S sample rate. Defaults to ``16000``.
- **bits_per_sample** (*Optional*, enum): The bit depth of the audio samples. Note that while set to ``32bit``, the samples
will be scaled down to 16bit before being forwarded.
One of ``16bit`` or ``32bit``. Defaults to ``32bit``.
- **bits_per_sample** (*Optional*, enum): The bit depth of the audio samples. Note that while set to ``24bit`` or ``32bit``, the samples
will be scaled down to 16bit before being forwarded. One of ``8bit``, ``16bit``, ``24bit``, or ``32bit``. Defaults to ``32bit``.
- **bits_per_channel** (*Optional*, enum): The bit depth of the audio channels. See the datasheet of your I2S device for details. Defaults to ``bits_per_sample``.
- **use_apll** (*Optional*, boolean): I2S using APLL as main I2S clock, enable it to get accurate clock. Defaults to ``false``.
- **i2s_mode** (*Optional*, enum): The I²S mode to use. One of ``primary`` or ``secondary``. Defaults to ``primary``.
- **i2s_mode** (*Optional*, enum): The I²S mode to use. One of ``primary`` (clock driven by the host) or ``secondary`` (clock driven by the attached device). Defaults to ``primary``.
- **i2s_audio_id** (*Optional*, :ref:`config-id`): The ID of the :ref:`I²S Audio <i2s_audio>` you wish to use for this microphone.
- All other options from :ref:`Microphone <config-microphone>`
@ -54,7 +55,7 @@ External ADC
------------
- **i2s_din_pin** (**Required**, :ref:`Pin Schema <config-pin_schema>`): The GPIO pin to use for the I²S ``DIN/SDIN`` *(Data In)* signal, also referred to as ``SD/SDATA`` *(Serial Data)* or ``ADCDAT`` *(Analog to Digital Converter Data)*.
- **pdm** (**Required**, boolean): Set this to ``true`` if your external ADC uses PDM (Pulse Density Modulation) instead of I²S.
- **pdm** (*Optional*, boolean): Set this to ``true`` if your external ADC uses PDM (Pulse Density Modulation) instead of I²S. Defaults to ``false``.
.. note::

View File

@ -54,7 +54,9 @@ Configuration variables:
- **modbus_id** (*Optional*, :ref:`config-id`): Manually specify the ID of the ``modbus`` hub.
- **address** (**Required**, :ref:`config-id`): The Modbus address of the slave device
- **address** (**Required**, :ref:`config-id`): The Modbus address of the slave device.
- **allow_duplicate_commands** (*Optional*, boolean): Whether to allow duplicate commands in the queue. Defaults to ``false``.
- **command_throttle** (*Optional*, :ref:`config-time`): minimum time in between 2 requests to the device. Default is ``0ms``.
Some Modbus slave devices limit the rate of requests from the master, so this allows the interval between requests to be altered.
@ -67,6 +69,8 @@ Configuration variables:
slaves, this avoids waiting for timeouts allowing to read other slaves in the same bus. When the slave
responds to a command, it'll be marked online again.
- **max_cmd_retries** (*Optional*, integer): How many times a command will be retried if no response is received. It doesn't include the initial transmition. Defaults to 4.
- **server_registers** (*Optional*): A list of registers that are responded to when acting as a server.
- **address** (**Required**, integer): start address of the first register in a range
- **value_type** (*Optional*): datatype of the mod_bus register data. The default data type for ModBUS is a 16 bit integer in big endian format (MSB first)

View File

@ -61,6 +61,27 @@ For instance, assume we have a pH sensor that reads from 0.00 to 15.00 with a sc
max_value: 15.00
multiply: 100
Hidden datapoints:
------------------
The above configurations will work fine as long as Tuya device publishes the datapoint value (along with its type) at initialization.
However this is not always the case. To be able to use such "hidden" datapoints as Number, you need to specify additional ``datapoint_hidden`` configuration block.
This block allows to specify the missing datapoint type and, optionally, the value that should be written to the datapoint at initialization.
TuyaMCU restores the state of all its datapoints after reboot, but with the hidden datapoints there is no way to know what their values are.
Therefore there is also an option to store them on the ESPHome side and they will be set at initialization. To use this feature, set the ``restore_value`` yaml key to True.
.. code-block:: yaml
- platform: "tuya"
name: "Alarm at maximum"
number_datapoint: 116
min_value: 0
max_value: 100
datapoint_hidden:
datapoint_type: int
initial_value: 85
restore_value: yes
Configuration variables:
------------------------
@ -69,6 +90,11 @@ Configuration variables:
- **max_value** (**Required**, float): The maximum value this number can be.
- **step** (*Optional*, float): The granularity with which the number can be set. Defaults to 1.
- **multiply** (*Optional*, float): multiply the new value with this factor before sending the requests.
- **datapoint_hidden** (*Optional*): Specify information required for hidden datapoints.
- **datapoint_type** (**Required**, string): The datapoint type, one of *int*, *uint*, *enum*.
- **initial_value** (*Optional*, float): The value to be written at initialization. Must be between ``min_value`` and ``max_value``.
- **restore_value** (*Optional*, boolean): Saves and loads the state to RTC/Flash. Defaults to ``false``.
- All other options from :ref:`Number <config-number>`.

View File

@ -242,6 +242,8 @@ Not all possible switches are exposed as they lead to the possibility to make se
name: inverter0_output_source_priority_solar
output_source_priority_battery:
name: inverter0_output_source_priority_battery
output_source_priority_hybrid:
name: inverter0_output_source_priority_hybrid
input_voltage_range:
name: inverter0_input_voltage_range
pv_ok_condition_for_parallel:
@ -256,6 +258,7 @@ All sensors are normal text sensors... so all text sensor variables are working
- **output_source_priority_utility** (*Optional*): output source priority utility
- **output_source_priority_solar** (*Optional*): output source priority solar
- **output_source_priority_battery** (*Optional*): output source priority battery
- **output_source_priority_hybrid** (*Optional*): output source priority hybrid
- **input_voltage_range** (*Optional*): input voltage range
- **pv_ok_condition_for_parallel** (*Optional*): pv ok condition for parallel
- **pv_power_balance** (*Optional*): pv power balance

View File

@ -67,7 +67,7 @@ Configuration variables:
- **phase_b** (*Optional*): The configuration options for the 2nd phase. Same options as 1st phase.
- **phase_c** (*Optional*): The configuration options for the 3rd phase. Same options as 1st phase.
- **frequency** (*Optional*): Use the frequenycy value calculated by the meter. All options from
- **frequency** (*Optional*): Use the frequency value calculated by the meter. All options from
:ref:`Sensor <config-sensor>`.
- **peak_current_signed** (*Optional*, boolean): Control the peak current output as signed or absolute. Defaults to ``false``.
- **chip_temperature** (*Optional*): Use the chip temperature value. All options from
@ -79,6 +79,31 @@ Configuration variables:
- **update_interval** (*Optional*, :ref:`config-time`): The interval to check the sensor. Defaults to ``60s``.
- **spi_id** (*Optional*, :ref:`config-id`): Manually specify the ID of the :ref:`SPI Component <spi>` if you want
to use multiple SPI buses.
- **enable_offset_calibration** (*Optional*, boolean): If true it enables fine grained offset noise 0 level calibration for voltage and
current sensors. Buttons are required to operate the calibration feature. With multiple atm90e32 sensors each one is enabled
individually and it's buttons are mapped using an id value pair. e.g. ``id: chip1`` when more than one is defined. Offset calibration should only be used
when DC supply noise causes non 0 current or voltage readings. Calibration can only be performed when all voltage and current inputs are at a 0 value.
Button
------
.. code-block:: yaml
button:
- platform: atm90e32
id: chip1
run_offset_calibration:
name: "Chip1 - Run Offset Calibration"
clear_offset_calibration:
name: "Chip1 - Clear Offset Calibration"
Configuration variables:
- **id** (*Optional*, :ref:`config-id`): The ID of the atm90e32 defined above. Required if there are multiple atm90e32 configured.
- **run_offset_calibration** (*Optional*): A button to run the offset calibration.
All options from :ref:`Button <config-button>`.
- **clear_offset_calibration** (*Optional*): A button to clear the offset calibration.
All options from :ref:`Button <config-button>`.
Calibration
-----------
@ -155,7 +180,7 @@ Active Energy
The ATM90E32 chip has a high-precision built-in ability to count the amount of consumed energy on a per-phase basis.
For each phase both the Forward and Reverse active energy is counted in watt-hours.
Forward Active Energy is used to count consumed energy, whereas Reverse Active Energy is used to count exported energy
(e.g. with solar pv installations).
(e.g. with solar PV installations).
The counters are reset every time a given active energy value is read from the ATM90E32 chip.
Current implementation targets users who retrieve the energy values with a regular interval and store them in
@ -179,24 +204,24 @@ a time-series-database, e.g. InfluxDB.
id: ct1RAWattHours
state_topic: ${disp_name}/ct1/reverse_active_energy
If the power, power_factor, reactive_power, forward_active_energy, or reverse_active_energy configuraion variables
If the power, power_factor, reactive_power, forward_active_energy, or reverse_active_energy configuration variables
are used, care must be taken to ensure that the line ATM90E32's voltage is from is the same phase as the current
transformer is installed on. This is significant in split-phase or multi phase installations. On a house with 240
split-phase wiring (very common in the US), one simple test is to reverse the orentation of the current transformer
split-phase wiring (very common in the US), one simple test is to reverse the orientation of the current transformer
on a line. If the power factor doesn't change sign, it is likely that the voltage fed to the ATM90E32 is from the other
phase.
The CircuitSetup Expandable 6 channel board can easilly handle this situation by cutting the jumpers JP12/13 to
allow a seperate VA2 to be input on the J3 pads. Make sure that current taps connected to CT 1-3 are on the phase
The CircuitSetup Expandable 6 channel board can easily handle this situation by cutting the jumpers JP12/13 to
allow a separate VA2 to be input on the J3 pads. Make sure that current taps connected to CT 1-3 are on the phase
from which VA is fed (the barrel jack) and the taps connected to CT3-6 are on the phase from which VA2 is fed. See
the CicuitSetup repo for more details on this.
If a mulit board stack is being used, remember to cut JP12/13 on all boards and to feed VA2 to each board. VA is
If a multi board stack is being used, remember to cut JP12/13 on all boards and to feed VA2 to each board. VA is
fed to all boards through the stacking headers. Another detail is that each voltage transformer needs to have the
same polarity; getting this backwards will be just like having it on the wrong phase.
Note that the current measurement is the RMS value so is always positive. They only way to determine directon is to
look at the power factor. If there are only largly resistive loads and no power sources, (PF almost 1), it is simpler
Note that the current measurement is the RMS value so is always positive. They only way to determine direction is to
look at the power factor. If there are only largely resistive loads and no power sources, (PF almost 1), it is simpler
to just create a template sensor that computes power from Irms*Vrms and ignore all these details. On the other
hand, one might be surprised how reactive some loads are and the CirciuitSetup designs are able to
handle these situations well.
@ -258,6 +283,7 @@ Additional Examples
sensor:
- platform: atm90e32
cs_pin: 5
id: chip1 #Optional
phase_a:
voltage:
name: "EMON Line Voltage A"
@ -287,8 +313,10 @@ Additional Examples
current_phases: 3
gain_pga: 1X
update_interval: 60s
enable_offset_calibration: True
- platform: atm90e32
cs_pin: 4
id: chip2 #Optional
phase_a:
current:
name: "EMON CT4 Current"
@ -315,6 +343,14 @@ Additional Examples
gain_pga: 1X
update_interval: 60s
button:
- platform: atm90e32
id: chip1
run_offset_calibration:
name: "Chip1 - Run Offset Calibration"
clear_offset_calibration:
name: "Chip1 - Clear Offset Calibration"
.. code-block:: yaml
@ -468,7 +504,7 @@ Harmonic Power
Harmonic power in AC systems refers to deviations from the ideal sinusoidal waveform, caused by multiples of the
fundamental frequency. It results from non-linear loads and can lead to issues like voltage distortion, equipment
overheating, and misoperation of protective devices. The ATM90E32 can output advanced harmonic power measurements
overheating, and miss operation of protective devices. The ATM90E32 can output advanced harmonic power measurements
providing important analysis data for monitoring power anomalies on the bus.
**Harmonic Power Example:**
@ -503,8 +539,8 @@ Peak Current
Peak current in AC systems refers to the maximum value of the alternating current waveform. It signifies the highest
magnitude reached during each cycle of the sinusoidal waveform. Peak current is relevant for sizing components and
assessing the capacity of electrical equipment in the system. This advanced measurement is avaiable from the ATM90E32.
Peak current can be displayed in signed or unsigned format using a bolean parameter which spans all phases.
assessing the capacity of electrical equipment in the system. This advanced measurement is available from the ATM90E32.
Peak current can be displayed in signed or unsigned format using a boolean parameter which spans all phases.
The default is false which is unsigned.
**Peak Current Example:**

View File

@ -0,0 +1,207 @@
Belling BL0906 Energy Monitor
=============================
.. seo::
:description: Instructions for setting up BL0906 energy monitor for the Athom Energy Meter
:image: bl0906.png
:keywords: bl0906, Athom EM2 Energy Meter, Athom EM6 Energy Meter, Athom Energy Meter, ESP32C3 Energy Meter Main Board, Split Single Phase Real Time Whole House Energy Meter
The ``bl0906`` sensor platform allows you to use your BL0906 voltage/current/power and energy
sensors with ESPHome. This sensor is commonly found in `Athom EM2 Energy Meter <https://www.athom.tech/blank-1/2-ch-energy-meter-made-for-esphome>`__ and `Athom EM6 Energy Meter <https://www.athom.tech/blank-1/6-ch-energy-meter-made-for-esphome>`__
.. note::
The current ratio of the current CT clamp must be 2000:1
As the communication with the BL0906 done using UART, you need
to have an :ref:`UART bus <uart>` in your configuration with the ``tx_pin`` and ``rx_pin`` connected to the BL0906.
Additionally, you need to set the baud rate to 19200.
The `Athom EM2 Energy Meter <https://www.athom.tech/blank-1/2-ch-energy-meter-made-for-esphome>`__ can read 1 voltage channel and 2 Current channels.
.. figure:: images/athom-em2.png
:align: center
:width: 20.0%
Athom Single Phase 2 channels Real Time Whole House Energy Meter.
The `Athom EM6 Energy Meter <https://www.athom.tech/blank-1/6-ch-energy-meter-made-for-esphome>`__ can read 1 voltage channel and 6 Current channels.
.. figure:: images/athom-em6.png
:align: center
:width: 30.0%
Athom Single Phase 6 channels Real Time Whole House Energy Meter.
Configuration variables:
------------------------
- **frequency** (*Optional*): The AC line frequency of the supply voltage. All options from
:ref:`Sensor <config-sensor>`.
- **temperature** (*Optional*): Chip internal temperature. All options from
:ref:`Sensor <config-sensor>`.
- **voltage** (*Optional*): Use the voltage value of the sensor in V. All options from
:ref:`Sensor <config-sensor>`.
- **channel_1** (*Optional*): Use channel 1.
- **current** (*Optional*): The current value of the channel 1 in amperes. All options from
:ref:`Sensor <config-sensor>`.
- **power** (*Optional*): The Power value of the channel 1 in watts. All options from
:ref:`Sensor <config-sensor>`.
- **energy** (*Optional*): The energy value of the channel 1 in kWh. All options from
:ref:`Sensor <config-sensor>`.
- **channel_2** (*Optional*): Use channel 2.
- **current** (*Optional*): The current value of the channel 2 in amperes. All options from
:ref:`Sensor <config-sensor>`.
- **power** (*Optional*): The Power value of the channel 2 in watts. All options from
:ref:`Sensor <config-sensor>`.
- **energy** (*Optional*): The energy value of the channel 2 in kWh. All options from
:ref:`Sensor <config-sensor>`.
- **channel_3** (*Optional*): Use channel 3.
- **current** (*Optional*): The current value of the channel 3 in amperes. All options from
:ref:`Sensor <config-sensor>`.
- **power** (*Optional*): The Power value of the channel 3 in watts. All options from
:ref:`Sensor <config-sensor>`.
- **energy** (*Optional*): The energy value of the channel 3 in kWh. All options from
:ref:`Sensor <config-sensor>`.
- **channel_4** (*Optional*): Use channel 4.
- **current** (*Optional*): The current value of the channel 4 in amperes. All options from
:ref:`Sensor <config-sensor>`.
- **power** (*Optional*): The Power value of the channel 4 in watts. All options from
:ref:`Sensor <config-sensor>`.
- **energy** (*Optional*): The energy value of the channel 4 in kWh. All options from
:ref:`Sensor <config-sensor>`.
- **channel_5** (*Optional*): Use channel 5.
- **current** (*Optional*): The current value of the channel 5 in amperes. All options from
:ref:`Sensor <config-sensor>`.
- **power** (*Optional*): The Power value of the channel 5 in watts. All options from
:ref:`Sensor <config-sensor>`.
- **energy** (*Optional*): The energy value of the channel 5 in kWh. All options from
:ref:`Sensor <config-sensor>`.
- **channel_6** (*Optional*): Use channel 6.
- **current** (*Optional*): The current value of the channel 6 in amperes. All options from
:ref:`Sensor <config-sensor>`.
- **power** (*Optional*): The Power value of the channel 6 in watts. All options from
:ref:`Sensor <config-sensor>`.
- **energy** (*Optional*): The energy value of the channel 6 in kWh. All options from
:ref:`Sensor <config-sensor>`.
- **total_energy** (*Optional*): The total energy value of all channels in kWh. All options from
:ref:`Sensor <config-sensor>`.
- **total_power** (*Optional*): The total power value of all channels in watts. All options from
:ref:`Sensor <config-sensor>`.
- **update_interval** (*Optional*, :ref:`config-time`): The interval to check the
sensor. Defaults to ``60s``.
- **uart_id** (*Optional*, :ref:`config-id`): Manually specify the ID of the :ref:`UART Component <uart>` if you want
to use multiple UART buses.
Example configuration
---------------------
2 Channel
^^^^^^^^^^^^^^^^^^
.. code-block:: yaml
# Example configuration entry
sensor:
- platform: bl0906
frequency:
name: 'Frequency'
temperature:
name: 'Temperature'
voltage:
name: 'Voltage'
channel_1:
current:
name: 'Current_1'
power:
name: 'Power_1'
energy:
name: 'Energy_1'
channel_2:
current:
name: 'Current_2'
power:
name: 'Power_2'
energy:
name: 'Energy_2'
total_energy:
name: 'Total_Energy'
total_power:
name: 'Total_Power'
6 Channel
^^^^^^^^^^^^^^^^^^
.. code-block:: yaml
# Example configuration entry
sensor:
- platform: bl0906
frequency:
name: 'Frequency'
temperature:
name: 'Temperature'
voltage:
name: 'Voltage'
channel_1:
current:
name: 'Current_1'
power:
name: 'Power_1'
energy:
name: 'Energy_1'
channel_2:
current:
name: 'Current_2'
power:
name: 'Power_2'
energy:
name: 'Energy_2'
channel_3:
current:
name: 'Current_3'
power:
name: 'Power_3'
energy:
name: 'Energy_3'
channel_4:
current:
name: 'Current_4'
power:
name: 'Power_4'
energy:
name: 'Energy_4'
channel_5:
current:
name: 'Current_5'
power:
name: 'Power_5'
energy:
name: 'Energy_5'
channel_6:
current:
name: 'Current_6'
power:
name: 'Power_6'
energy:
name: 'Energy_6'
total_energy:
name: 'Total_Energy'
total_power:
name: 'Total_Power'
See Also
--------
- :ref:`sensor-filters`
- :doc:`cse7761`
- :doc:`bl0939`
- :doc:`bl0940`
- :apiref:`bl0906/bl0906.h`
- :ghedit:`Edit`

View File

@ -16,31 +16,18 @@ to some pins on your board and the baud rate set to 4800 with 1 stop bit.
.. code-block:: yaml
# Example configuration entry
uart:
id: uart_bus
tx_pin: TX
rx_pin: RX
baud_rate: 4800
stop_bits: 1
sensor:
- platform: bl0942
uart_id: uart_bus
voltage:
name: 'BL0942 Voltage'
current:
name: 'BL0942 Current'
power:
name: 'BL0942 Power'
filters:
multiply: -1
energy:
name: 'BL0942 Energy'
frequency:
name: "BL0942 Frequency"
accuracy_decimals: 2
update_interval: 60s
Configuration variables:
------------------------
@ -49,7 +36,7 @@ Configuration variables:
All options from :ref:`Sensor <config-sensor>`.
- **current** (*Optional*): The current value of the sensor in Amperes. All options from
:ref:`Sensor <config-sensor>`.
- **power** (*Optional*): The (active) power value of the sensor in Watts. Note that some power meters will report this in negative values (probably wired backwards), so you may want to use a filter to multiply it by -1. All options from :ref:`Sensor <config-sensor>`.
- **power** (*Optional*): The (active) power value of the sensor in Watts. Note that some power meters will report this in negative values (probably wired backwards), so you may want to use a filter to multiply it by -1. All options from :ref:`Sensor <config-sensor>`.
- **energy** (*Optional*): Use the energy value of the sensor in kWh.
All options from :ref:`Sensor <config-sensor>`.
- **frequency** (*Optional*): The frequency value of the sensor in Hertz. All options from
@ -59,6 +46,75 @@ Configuration variables:
sensor. Defaults to ``60s``.
- **uart_id** (*Optional*, :ref:`config-id`): Manually specify the ID of the :ref:`UART Component <uart>` if you want
to use multiple UART buses.
- **line_frequency** (*Optional*, string): The nominal AC line frequency of the supply voltage. One of ``50Hz``, ``60Hz``. Defaults to ``50Hz``.
- **address** (*Optional*, int): The address of the BL0942 from its strapping pins. Defaults to ``0``.
- **reset** (*Optional*, boolean): Whether to reset the BL0942 chip on startup, resetting all internal counters. Defaults to ``true``.
- **current_reference** (*Optional*, float): The calibration parameter for current readings. Defaults to ``251213.46469622``.
- **voltage_reference** (*Optional*, float): The calibration parameter for voltage readings. Defaults to ``15873.35944299``.
- **power_reference** (*Optional*, float): The calibration parameter for power readings. Defaults to ``596.0`` unless either ``current_reference`` or ``voltage_reference`` are explicitly set, in which case it is calculated. See :ref:`bl0942-calibration` for more details.
- **energy_reference** (*Optional*, float): The calibration parameter for cumulative energy readings. Defaults to ``3304.61127328`` unless any of ``current_reference``, ``voltage_reference`` or ``power_reference`` are explicitly set, in which case it is calculated. See :ref:`bl0942-calibration` for more details.
.. _bl0942-calibration:
Calibration
-----------
There are two fundamental calibration parameters which are dependent on the hardware: ``voltage_reference`` and ``current_reference``. These can be determined by using an accurate voltage and current meter with a simple resistive load.
The ``power_reference`` value can be derived from those, and will be roughly ``voltage_reference`` * ``current_reference`` * 3537 / (305978 * 73989).
The ``energy_reference`` value can be derived as roughly ``power_reference`` * 3600000 / 419430.4.
For compatibility with existing configurations, if no reference values are set then the original defaults will be used, despite the power and energy calibration not being entirely consistent.
If converting Tuya devices, the factory calibration values can often be obtained from the original firmware. For example, they may be found in DPS parameters 22-25, or the `voltage_coe` and related options.
An example from a Tongou DIN rail power meter unit. The result from ``tinytuya wizard`` included:
.. code-block:: json
{
"code": "voltage_coe",
"value": 15968
},
{
"code": "electric_coe",
"value": 12418
},
{
"code": "power_coe",
"value": 3091
},
{
"code": "electricity_coe",
"value": 2653
},
Noting that the ``electric_coe`` value (DPS 23) should be multiplied by ten, and the ``power_coe`` value should be divided by ten, this results in the following configuration:
.. code-block:: yaml
voltage_reference: 15968 # DPS 21
current_reference: 124180 # DPS 22 * 10
power_reference: 309.1 # DPS 23 / 10
energy_reference: 2653 # DPS 24
Alternatively, the values may be found on the flash of the unit without obtaining
the Tuya keys for local communication. They can be found in the "key value store"
partition. The same device as in the above example had the following (before
flashing ESPHome) at offset ``0x001d5000``:
.. code-block::
001d5000 60 3e 00 00 82 30 00 00 13 0c 00 00 5d 0a 00 00 |`>...0......]...|
The hex values 0x3e60, 0x3082, 0xc13 and 0xa5d seen there correspond to the four
DPS values reported by the running Tuya firmware.
The formulas above for deriving ``power_reference`` and ``energy_reference`` can be
used as a sanity check for the values found from the firmware.
See Also
--------

View File

@ -66,13 +66,22 @@ Configuration variables:
See :ref:`Oversampling Options <bme280-oversampling>`.
- All other options from :ref:`Sensor <config-sensor>`.
- **address** (*Optional*, int): Manually specify the I²C address of
the sensor. Defaults to ``0x77``. Another address can be ``0x76``.
- **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 ``60s``.
I²C Configuration variables:
- **address** (*Optional*, int): Manually specify the I²C address of
the sensor. Defaults to ``0x77``. Another address can be ``0x76``.
SPI Configuration variables:
- **cs_pin** (*Optional*, :ref:`Pin Schema <config-pin_schema>`): The CS pin of the BME280 sensor.
.. _bme280-oversampling:
Oversampling Options

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 3.5 KiB

View File

@ -8,7 +8,7 @@ BMP280 Temperature+Pressure Sensor
The ``bmp280`` sensor platform allows you to use your BMP280
(`datasheet <https://cdn-shop.adafruit.com/datasheets/BST-BMP280-DS001-11.pdf>`__,
`Adafruit`_) temperature and pressure sensors with ESPHome. The :ref:`I²C <i2c>` is
`Adafruit`_) temperature and pressure sensors with ESPHome. The :ref:`I²C <i2c>` or :ref:`SPI <spi>` is
required to be set up in your configuration for this sensor to work.
.. figure:: images/bmp280-full.jpg
@ -21,9 +21,9 @@ required to be set up in your configuration for this sensor to work.
.. code-block:: yaml
# Example configuration entry
# Example configuration entry I2C
sensor:
- platform: bmp280
- platform: bmp280_i2c
temperature:
name: "Outside Temperature"
oversampling: 16x
@ -32,6 +32,17 @@ required to be set up in your configuration for this sensor to work.
address: 0x77
update_interval: 60s
# Example configuration entry SPI
sensor:
- platform: bmp280_spi
temperature:
name: "Outside Temperature"
oversampling: 16x
pressure:
name: "Outside Pressure"
cs_pin: GPIO5
update_interval: 60s
Configuration variables:
------------------------
@ -48,13 +59,22 @@ Configuration variables:
See :ref:`Oversampling Options <bmp280-oversampling>`.
- All other options from :ref:`Sensor <config-sensor>`.
- **address** (*Optional*, int): Manually specify the I²C address of
the sensor. Defaults to ``0x77``. Another address can be ``0x76``.
- **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 ``60s``.
I²C Configuration variables:
- **address** (*Optional*, int): Manually specify the I²C address of
the sensor. Defaults to ``0x77``. Another address can be ``0x76``.
SPI Configuration variables:
- **cs_pin** (*Optional*, :ref:`Pin Schema <config-pin_schema>`): The CS pin of the BMP280 sensor.
.. figure:: images/bmp280-full.jpg
:align: center
:width: 60.0%

Before

Width:  |  Height:  |  Size: 2.7 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB

View File

@ -256,6 +256,11 @@ Configuration variables:
- All options from :ref:`Text Sensor <config-text_sensor>`.
- **telegram** (*Optional*): The (decrypted) unparsed telegram, marked as internal sensor.
Can also be used to trigger an action based on the last values.
- All other options from :ref:`Text Sensor <config-text_sensor>`.
Belgium
- **p1_version_be** (*Optional*): DSMR Version Belgium
@ -384,6 +389,42 @@ actually make it work, serial logging must be disabled to keep the hardware UART
pin: GPIO13
baud_rate: 115200
Bridging support / raw telegram logging
---------------------------------------
You can use another uart to supply another P1 receiver with the same telegram. See configuration sample as used for bridging.
.. code-block:: yaml
# define multiple uart's
uart:
- id: p1_uart
rx_pin:
number: 4
inverted: true
baud_rate: 115200
rx_buffer_size: 1700
- id: p1_bridge_uart
tx_pin:
number: 10
baud_rate: 115200
# link input uart to dsmr
dsmr:
uart_id: p1_uart
max_telegram_length: 1700
# log the telegram and pass telegram to p1_bridge_uart
text_sensor:
- platform: dsmr
telegram:
name: "telegram"
on_value:
then:
- lambda: |-
ESP_LOGV("dsrm", "telegram: %s", x.c_str());
p1_bridge_uart->write_str(x.c_str());
See Also
--------

Binary file not shown.

After

Width:  |  Height:  |  Size: 274 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 278 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.7 KiB

View File

@ -60,7 +60,7 @@ Configuration variables:
sensor. Defaults to ``60s``. Not applicable in mode 1.
- **uart_id** (*Optional*, :ref:`config-id`): The ID of the :ref:`UART bus <uart>` you wish to use for this sensor.
Use this if you want to use multiple UART buses at once.
- **model** (*Optional*): Sensor model. Available options: ``jsn_sr04t`` (default) and ``aj_sr04t``.
- **model** (*Optional*): Sensor model. Available options: ``jsn_sr04t`` (default) and ``aj_sr04m``.
- All other options from :ref:`Sensor <config-sensor>`.
See Also

View File

@ -0,0 +1,193 @@
Lite-On Ambient Light & Proximity Sensors
=========================================
.. seo::
:description: Instructions for setting up LTR301, LTR501, LTR558 ambient light sensors/proximity sensors with ESPHome.
:image: ltr501.jpg
:keywords: LTR-301, LTR-501, LTR-558
.. figure:: images/ltr501-full.jpg
:align: center
:width: 60.0%
LTR-501 on a breadboard from Olimex
.. figure:: images/ltr501-ui.png
:align: center
:width: 60.0%
LTR-501 Sensor in Home Assistant UI.
The ``ltr501`` sensor platform allows you to use a range of LiteOn ambient light and proximity sensors
with ESPHome.
The supported family of sensors includes:
- Ambient Light Sensor **LTR-301ALS**
- Integrated Ambient Light and Proximity Sensors **LTR-501ALS** and **LTR-558ALS**
The LTR-501 device is available on a breakout board from `Olimex`_.
The sensors are very similar and share the same datasheet. The :ref:`I²C Bus <i2c>` is required to be set up in your
configuration for this sensor to work. I²C address is ``0x23``.
Proximity sensors are the same sort of sensors that you find in phones and tablets to disable the screen when you hold
the device up to your ear. They might be useful for automated turning on or off of displays and control panels.
.. _Olimex: https://www.olimex.com/Products/Modules/Sensors/MOD-LTR-501ALS/open-source-hardware
Ambient light sensing
---------------------
These sensors have a linear response over a wide dynamic range from 0.01 lux to 64k lux and are well suited
to applications under high ambient brightness. There are two gain settings (1X, 150X) available for use.
Use higher gain for dimmer areas.
These devices consist of two photodiodes: a *CH0* diode that is sensitive to both visible and infrared light and
a *CH1* diode that is sensitive only to infrared light.
**Note**: These sensors do not have internal data checking and do not indicate any errors if
data is not reliable. The sensors can be easily saturated if the gain is too high or the integration time is too long. In this
case, readings can be very strange. It's recommended to use automatic mode with a starting gain of 1X (default) and a starting
integration time of 100ms (default) or even 50ms (if the sensor is in a very bright environment). Automatic mode with starting
gain of 150X is not recommended; use it only if you are sure brightness will never exceed 200-300 lx.
Ambient light illuminance calculation
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Excerpt from the datasheet:
.. code-block::
RATIO = CH1/(CH0+CH1)
IF (RATIO < 0.45)
ALS_LUX = (1.7743 * CH0 + 1.1059 * CH1) / ALS_GAIN / ALS_INT
ELSEIF (RATIO < 0.64 && RATIO >= 0.45)
ALS_LUX = (3.7725 * CH0 1.3363 * CH1) / ALS_GAIN / ALS_INT
ELSEIF (RATIO < 0.85 && RATIO >= 0.64)
ALS_LUX = (1.6903 * CH0 - 0.1693 * CH1) / ALS_GAIN / ALS_INT
ELSE
ALS_LUX = 0
END
where:
- ``CH0`` and ``CH1`` are the sensor values (measurement counts) for Visible + IR (Ch0) and IR only (Ch1) sensors respectively.
- ``ALS_GAIN`` is the gain multiplier
- ``ALS_INT`` is the integration time in ms/100
ALS Gain levels
^^^^^^^^^^^^^^^
The table lists gain values and corresponding illuminance range:
========= ================================
Gain Illuminance range
========= ================================
``1X`` 2 lux to 64k lux (default)
``150X`` 0.01 lux to 320 lux
========= ================================
This Wikipedia `article <https://en.wikipedia.org/wiki/Lux>`__ has a table of some lux values for comparison.
The following table lists possible gain and integration time combinations:
================== ======== =============== ======== ========
Gain / Int.time 50 ms 100 ms 200 ms 400 ms
================== ======== =============== ======== ========
``1X`` ✓ ✓ (default)
``150X`` ✓ ✓ ✓
================== ======== =============== ======== ========
Proximity sensing
-----------------
The proximity sensor has a built-in emitter and detector. The sensor detects reflected IR light from the emitter and
gives a raw count value inversely exponential to the distance. A decrease in the count value means an object is getting
further away from the sensor (and vice-versa). Neither of the datasheets provide any information on how to convert
the raw count value to distance. The only way to do so is to test the sensor yourself and select the threshold
according to your needs and environment. Exact values will depend on the type of the object, its color and
reflectivity.
Example configuration
---------------------
.. code-block:: yaml
sensor:
- platform: ltr501
type: ALS_PS # .. or ALS or PS
ambient_light: "Ambient light"
# PS only section
ps_cooldown: 5 s
ps_high_threshold: 500
on_ps_high_threshold:
then:
- .... # do something - light up the screen for example
ps_counts:
name: "Proximity counts"
Configuration variables
-----------------------
- **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation.
- **address** (*Optional*, int): Manually specify the I²C address of the sensor. Default is ``0x23``.
- **type** (*Optional*, string): The type of the sensor. Valid values are ``ALS_PS`` *(default)* for
integrated sensors, ``ALS`` for ambient light only or ``PS`` for proximity only devices.
- **auto_mode** (*Optional*, boolean): Automatic gain and integration time selection. Defaults to True.
- **gain** (*Optional*, string): The gain the device will use. Higher values are better in low-light conditions.
Valid values are ``1X`` *(default)*, ``150X``.
- **integration_time** (*Optional*, :ref:`config-time`):
The amount of time sensors are exposed. Longer means more accurate values.
Valid values are: ``50ms``, ``100ms`` *(default)*, ``200ms``, ``400ms``.
- **glass_attenuation_factor** (*Optional*, float): The attenuation factor of glass if it's behind some glass
or plastic facia. Default is ``1.0`` means ``100%`` transmissivity. ``2`` means ``50%`` transmissivity etc.
- **update_interval** (*Optional*, :ref:`config-time`): The interval for checking the sensors.
Defaults to ``60s``.
- **ps_cooldown** (*Optional*, :ref:`config-time`): The "cooldown" period after the proximity sensor is triggered.
Helps to avoid multiple calls. Defaults to ``5s``.
- **ps_gain** (*Optional*, string): The gain the device will use for proximity sensor. Higher values are better in low-light conditions.
Valid values are ``1X`` *(default)*, ``4X``, ``8X``, ``16X``.
- **ps_high_threshold** (*Optional*, int): The threshold for the proximity sensor to trigger on object getting closer.
Defaults to ``65535``, which implies it will never be triggered.
- **ps_low_threshold** (*Optional*, int): The threshold for the proximity sensor to trigger on object getting further away.
Defaults to ``0``, which implies it will never be triggered.
- **on_ps_high_threshold** (*Optional*): Actions to perform when the proximity sensor is triggered
on object getting closer.
- **on_ps_low_threshold** (*Optional*): Actions to perform when the proximity sensor is triggered
on object getting further away.
Sensors
^^^^^^^
This component offers five sensors for ALS-equipped devices and one sensor for PS-equipped devices.
You can configure all or any subset of these sensors. Each configured sensor is reported separately
on each ``update_interval``. Each is an ESPHome :ref:`sensor <config-sensor>` and may be configured
accordingly; if you dont need to configure additional :ref:`sensor <config-sensor>` variables, you
may simply use the shorthand syntax for the sensor. For example: ``ambient_light: "Ambient light"``
- **ambient_light** (*Optional*): Illuminance of ambient light, close to human eye spectre, lx.
- **infrared_counts** (*Optional*): Sensor counts from the IR-sensitive sensor (*CH1*), counts.
- **full_spectrum_counts** (*Optional*): Sensor counts from the sensor sensitive to both visible light and IR (*CH0*), counts.
- **actual_gain** (*Optional*): Gain value used to measure data, multiplier. Particularly useful when "auto_mode" is selected.
- **actual_integration_time** (*Optional*): Integration time used to measure data, ms. Particularly useful when "auto_mode" is selected.
- **ps_counts** (*Optional*) - Raw 11-bit reading from proximity sensor, counts.
See Also
--------
- `LTR-501ALS datasheet <https://github.com/latonita/datasheets-storage/blob/main/sensors/LTR-501ALS-01.pdf>`__
- `LTR-558ALS datasheet <https://github.com/latonita/datasheets-storage/blob/main/sensors/ltr-558als-01%20LITE-S-A0000286415-1.pdf>`__
- `LTR-301ALS datasheet <https://github.com/latonita/datasheets-storage/blob/main/sensors/LTR-301ALS-01_PrelimDS_ver1.pdf>`__
- :apiref:`ltr501/ltr501.h`
- :ghedit:`Edit`

View File

@ -5,7 +5,7 @@ LVGL Sensor
:description: Instructions for setting up an LVGL widget sensor component.
:image: ../images/lvgl_c_num.png
The ``lvgl`` sensor platform creates a semsor component from an LVGL widget
The ``lvgl`` sensor platform creates a sensor component from an LVGL widget
and requires :doc:`LVGL </components/lvgl/index>` to be configured.
Supported widgets are :ref:`lvgl-widget-arc`, :ref:`lvgl-widget-bar`, :ref:`lvgl-widget-slider` and :ref:`lvgl-widget-spinbox`. A single sensor supports only a single widget; in other words, it's not possible to have multiple widgets associated with a single ESPHome sensor.
@ -27,7 +27,7 @@ Example:
.. note::
Widget-specific actions (``lvgl.arc.update``, ``lvgl.bar.update``, ``lvgl.slider.update``, ``lvgl.spinbox.update``, ``lvgl.spinbox.decrement``, ``lvgl.spinbox.increment``) will trigger correspponding component updates to be sent to Home Assistant.
Widget-specific actions (``lvgl.arc.update``, ``lvgl.bar.update``, ``lvgl.slider.update``, ``lvgl.spinbox.update``, ``lvgl.spinbox.decrement``, ``lvgl.spinbox.increment``) will trigger corresponding component updates to be sent to Home Assistant.
See Also
--------

View File

@ -45,6 +45,7 @@ Configuration variables:
- **cs_pin** (**Required**, :ref:`Pin Schema <config-pin_schema>`): The Chip Select pin of the SPI interface.
- **update_interval** (*Optional*, :ref:`config-time`): The interval to check the sensor. Defaults to ``60s``.
- **mains_filter** (*Optional*, string): The mains power frequency to reject (``50 Hz`` or ``60 Hz``). Defaults to ``60 Hz``.
- **thermocouple_type** (*Optional*, string): The type of thermocouple used. MAX31856 supports: B, E, J, K, N, R, S, and T . Defaults to ``K``.
- **spi_id** (*Optional*, :ref:`config-id`): Manually specify the ID of the :ref:`SPI Component <spi>` if you want to use multiple SPI buses.
- All other options from :ref:`Sensor <config-sensor>`.

49
components/sensor/udp.rst Normal file
View File

@ -0,0 +1,49 @@
UDP Sensor
==========
.. seo::
:description: Instructions for setting up a UDP sensor.
:image: udp.svg
The ``udp`` sensor platform allows you to receive numeric sensor data directly from another ESPHome node.
.. code-block:: yaml
# Example configuration entry
sensor:
- platform: udp
id: temperature_id
provider: thermometer
remote_id: temp_id
Configuration variables
-----------------------
- **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation.
- **provider** (**Required**, string): The name of the provider node.
- **remote_id** (*Optional*, :ref:`config-id`): The ID of the original sensor in the provider node. If not specified defaults to the ID configured with ``id:``.
- **name** (*Optional*, string): The name of the sensor.
- **internal** (*Optional*, boolean): Whether the sensor should be exposed via API (e.g. to Home Assistant.) Defaults to ``true`` if name is not set, required if name is provided.
- All other options from :ref:`Sensor <config-sensor>`.
At least one of ``id`` and ``remote_id`` must be configured.
Publishing to Home Assistant
----------------------------
Typically this type of sensor would be used for internal automation purposes rather than having it published back to
Home Assistant, since it would be a duplicate of the original sensor.
If it *is* desired to expose the sensor to Home Assistant, then the ``internal:`` configuration setting needs to be explicitly
set to ``false`` and a name provided.
Only the state (i.e. numeric value) of the remote sensor is received by the consumer, so any other attributes must be explicitly
configured.
See Also
--------
- :doc:`/components/udp`
- :doc:`/components/binary_sensor/index`
- :ref:`automation`
- :apiref:`udp/udp_component.h`
- :ghedit:`Edit`

View File

@ -24,7 +24,6 @@ This platform only works on ESP32 based chips.
- platform: i2s_audio
dac_type: external
i2s_dout_pin: GPIOXX
mode: mono
Configuration variables:
------------------------
@ -34,12 +33,21 @@ Configuration variables:
- ``external``: Use an external DAC, for example the NS4168, or UDA1334A.
- ``internal``: Use the internal DAC
- **channel** (*Optional*, enum): The channel of the speaker. One of ``left``, ``right``, ``mono``, or ``stereo``. If ``stereo``, the input data should be twice as big,
with each right sample followed by a left sample. ``left`` and ``right`` mute the unused channel, while ``mono`` plays the same samples on both. Defaults to ``mono``.
- **sample_rate** (*Optional*, positive integer): I2S sample rate. Defaults to ``16000``.
- **bits_per_sample** (*Optional*, enum): The bit depth of the audio samples. Note that while set to ``24bit`` or ``32bit``, the samples
will be scaled up from 16bit before being forwarded. One of ``8bit``, ``16bit``, ``24bit``, or ``32bit``. Defaults to ``16bit``.
- **bits_per_channel** (*Optional*, enum): The bit depth of the audio channels. See the datasheet of your I2S device for details. Defaults to ``bits_per_sample``.
- **use_apll** (*Optional*, boolean): I2S using APLL as main I2S clock, enable it to get accurate clock. Defaults to ``false``.
- **i2s_mode** (*Optional*, enum): The I²S mode to use. One of ``primary`` (clock driven by the host) or ``secondary`` (clock driven by the attached device). Defaults to ``primary``.
- **i2s_audio_id** (*Optional*, :ref:`config-id`): The ID of the :ref:`I²S Audio <i2s_audio>` you wish to use for this speaker.
- **timeout** (*Optional*, :ref:`config-time`): How long to wait after finishing playback before releasing the bus. Defaults to ``100ms``.
External DAC
************
- **i2s_dout_pin** (**Required**, :ref:`Pin Schema <config-pin_schema>`): The GPIO pin to use for the I²S DOUT (Data Out) signal.
- **mode** (*Optional*, string): The mode of the I²S bus. Can be ``mono`` or ``stereo``. Defaults to ``mono``.
- **i2s_audio_id** (*Optional*, :ref:`config-id`): The ID of the :ref:`I²S Audio <i2s_audio>` you wish to use for this speaker.
For best results, keep the wires as short as possible.

53
components/statsd.rst Normal file
View File

@ -0,0 +1,53 @@
.. _statsd:
StatsD
========
.. seo::
:description: Instructions for setting up a StatsD
:keywords: StatsD, metrics
StatsD is a `protocol <https://github.com/statsd/statsd/blob/master/docs/metric_types.md>`_ to send metrics to a Daemon to store and aggregate them.
Today there are many monitoring solutions that support receiving metrics via the StatsD protocol.
.. code-block:: yaml
# Example configuration entry
statsd:
host: REPLACEME
sensors:
id: some_sensor
name: test1.sensor
sensor:
platform: ...
id: some_sensor
This example will generate a metric named `test1.sensor` with the value of the `some_sensor` sensor.
Configuration variables:
------------------------
- **host** (**Required**, ip): The Host IP of your StatsD Server.
- **post** (*Optional*, uint16): The Port of your StatsD Server. Defaults to ``8125``.
- **prefix** (*Optional*, string): The prefix to automatically prepend every metric with. Defaults to ``""``.
- **update_interval** (*Optional*, uint16): How often to send the metrics. Defaults to ``10s``.
- **sensor** (*Optional*, :ref:`sensors`): A list of sensors to generate metrics for.
- **binary_sensor** (*Optional*, :ref:`sensors`): A list of binary sensors to generate metrics for.
.. _sensors:
Sensor list
-----------
- **id** (**Required**, :ref:`config-id`): The ID of the sensor.
- **name** (**Required**, name): The Name of the metric the sensor value is send as. (Prefix is added to this name).
See Also
--------
- :apiref:`statsd/statsd.h`
- :ghedit:`Edit`

View File

@ -22,6 +22,20 @@ Configuration variables:
- **entity_id** (**Required**, string): The entity ID to import / control from Home Assistant.
- All other options from :ref:`Switch <config-switch>`.
Supported domains
-----------------
The following entity domains from Home Assistant are supported by this platform.
- ``automation``
- ``fan``
- ``humidifier``
- ``input_boolean``
- ``light``
- ``remote``
- ``siren``
- ``switch``
See Also
--------

View File

@ -34,6 +34,7 @@ Configuration variables:
- **id** (*Optional*, :ref:`config-id`): Manually set the ID of this touchscreen.
- **interrupt_pin** (*Optional*, :ref:`Pin Schema <config-pin_schema>`): The touch detection pin.
- **reset_pin** (*Optional*, :ref:`Pin Schema <config-pin_schema>`): The reset pin.
- All other options from :ref:`Touchscreen <config-touchscreen>`.

View File

@ -140,5 +140,6 @@ See Also
- :doc:`/components/binary_sensor/tuya`
- :doc:`/components/sensor/tuya`
- :doc:`/components/text_sensor/tuya`
- :doc:`/components/number/tuya`
- :apiref:`tuya/tuya.h`
- :ghedit:`Edit`

300
components/udp.rst Normal file
View File

@ -0,0 +1,300 @@
.. _udp:
UDP Component
=============
.. seo::
:description: Instructions for setting up a UDP component on ESPHome
:image: udp.svg
:keywords: UDP
The purpose of this component is to allow ESPHome nodes to directly communicate with each over an IP network.
It permits the state of sensors and binary sensors to be broadcast via UDP packets
to other nodes on the same LAN, or to specific IP addresses (which may be in remote, but reachable networks).
Nodes may be *providers* which broadcast sensor data, or *consumers* which receive sensor data from one or more
providers. A node may be both a provider and a consumer. Optional security is provided by one or more of:
- encryption using a shared secret key
- a rolling code
- a challenge-response (ping-pong) key
.. code-block:: yaml
# Example configuration entry
udp:
update_interval: 5s
encryption: "REPLACEME"
rolling_code_enable: true
binary_sensors:
- binary_sensor_id1
sensors:
- sensor_id1
- id: sensor_id2
broadcast_id: different_id
providers:
- name: some-device-name
encryption: "REPLACEME with some key"
sensor:
- platform: udp
provider: some-device-name
id: local_sensor_id
remote_id: some_sensor_id
binary_sensor:
- platform: udp
provider: unencrypted-device
id: other_binary_sensor_id # also used as remote_id
Configuration variables:
------------------------
- **id** (*Optional*, :ref:`config-id`): Manually specify the ID used for code generation.
- **update_interval** (*Optional*, :ref:`config-time`): Interval between full broadcasts. Defaults to 15s.
- **port** (*Optional*, int): The destination UDP port number to use. Defaults to ``18511``.
- **addresses** (*Optional*, list of IPv4 addresses): One or more IP addresses to broadcast data to. Defaults to ``255.255.255.255``
which is the local network broadcast address.
- **sensors** (*Optional*, list): A list of sensor IDs to be broadcast. Each entry may be just the sensor id, or may set a different id to be broadcast.
- **id** (**Required**, :ref:`config-id`): The id of the sensor to be used
- **broadcast_id** (*Optional*, string): The id to be used for this sensor in the broadcast. Defaults to the same as the internal id.
- **binary_sensors** (*Optional*, list): A list of binary sensor IDs to be broadcast.
- **id** (**Required**, :ref:`config-id`): The id of the binary sensor to be used
- **broadcast_id** (*Optional*, string): The id to be used for this binary sensor in the broadcast. Defaults to the same as the internal id.
- **encryption** (*Optional*, string): The encryption key to use when broadcasting. Default is no encryption. This may be
any string, and will be hashed to form a 256 bit key.
- **rolling_code_enable** (*Optional*, boolean): Enables a rolling code to be included in all broadcasts. Requires ``encryption`` to be set. Defaults to ``false``. Can be set only on the provider side.
- **ping_pong_enable** (*Optional*, boolean): When set, requires encrypted providers to include a *nonce* generated by this device in broadcasts. Defaults to ``false``. Can be set only on the consumer side.
- **ping_pong_recycle_time** (*Optional*, :ref:`config-time`): Controls how often the ping-pong key is regenerated. Requires ``ping_pong_enable`` to be set. Defaults to 10 minutes. Can be set only on the consumer side.
- **providers** (*Optional*, list): A list of provider device names and optionally their secret encryption keys.
- **name** (**Required**, string): The device name of the provider.
- **encryption** (*Optional*, string): The provider's encryption key.
Wherever a provider name is required, this should be the node name configured in the ``esphome:`` block.
This component supports multiple configurations, making it possible to differentiate between consumers when providing data to them.
When receiving data in such a configuration, sensors need an ``udp_id`` configuration item to know where to expect data to come from.
Reliability
-----------
UDP, like any other network protocol, does not provide a guarantee that data will be delivered, but unlike TCP it does not
even provide any indication whether data has been successfully delivered or not. When any of the configured sensors changes state,
the component will broadcast that sensor's state, but since this may not be delivered to a consumer, the UDP component
also broadcasts *all* sensor data on a timed schedule, set by ``update_interval``. Even this does not guarantee
delivery, but in practice unless the network has failed, updates will eventually be delivered, albeit possibly after
some delay.
Security
--------
By default there is no security - all data is transmitted in clear text on the network. This would be appropriate
for non-sensitive sensor data or perhaps on a fully secured wired network. For other cases the data can be encrypted
by providing an encryption key, which is shared between the provider and consumer.
Encryption alone ensures that data cannot be read in transit and protects against spoofing of data, but does not protect
against replay attacks (where a threat actor records a transmission and replays it later, e.g. to repeat an action.)
A rolling code can be enabled which mitigates replay attacks - each transmission contains a 64 bit value which is
guaranteed to monotonically increase, so the consumer will reject any data which contains a rolling code
already seen. The rolling code also ensures that the data in every packet is different, which makes brute-force
attacks on the encryption much more difficult. This is enabled in the provider configuration and adds minor overhead.
.. note::
The rolling code's upper 32 bit field is incremented and written to flash *once* at reboot on the provider node.
It's also incremented and written to flash when the lower 32 bit field overflows, which can only happen after
a very long time. The consumer side does not store the d rolling codes in flash.
For further protection a ``ping-pong`` (or challenge-response) facility is available, which can be enabled in the
consumer configuration. The consumer periodically generates a 32 bit random number (a *nonce* aka "Number used Once")
and broadcasts it as a *ping*. Any provider receiving this nonce will include it in any future encrypted broadcasts as
*pong*. The consumer expects to get back its most recently transmitted *ping* in any packets it receives, and will reject
any that do not contain it.
Use of the ping-pong feature will add to network traffic and the size of the transmitted packets (a single packet may
include up to 4 nonces from different devices) but provides a high level of protection against replay attacks. It does
require a 2-way network connection, and it only works on local networks because the consumer can only *broadcast* the
nonce to the providers.
.. note::
Occasionally a ``Ping key not seen`` warning message may appear in the device log. This is expected, because it may
happen that while the consumer has regenerated the *ping* key, it subsequently received a *pong* with the previous key,
most likely because the messages crossed in transit. In such a case, the message will be rejected, but the next message
will contain the correct *pong*.
Because of this, ``ping-pong`` is only recommended to be used for state transmissions, which are updated periodically
at ``update_interval``.
**Security considerations**
The encryption used is `XXTEA <https://en.wikipedia.org/wiki/XXTEA>`_ which is fast and compact. Although XXTEA is known
to be susceptible to a chosen-plaintext attack, such an attack is not possible with this application, and it otherwise
has no published weaknesses [#f1]_. The implementation used here has been modified slightly to use a 256 bit key which
will strengthen security compared to the original 128 bit key.
When encryption is used, all data is encrypted except the sender node name, and the initial request for a ping-pong key.
Broadcasting names does not compromise security, since this information would already be available via mDNS.
Requesting a key in clear text does not reduce the security of the key, since it is the ability to encrypt this key
with the shared secret key that provides the security assurance.
This does mean however that there is a possible Denial of Service attack by a malicious node overwriting a valid
ping-pong key, which will result in packets being rejected by the legitimate consumer.
Configuration examples
----------------------
This example couples two light switches in two different devices, so that switching either one on or off will cause
the other to follow suit. In each case a template binary_sensor is used to mirror the switch state.
.. code-block:: yaml
# Device 1
esphome:
name: device-1
udp:
binary_sensors:
- relay1_sensor
switch:
- platform: gpio
pin: GPIO6
id: relay1
name: "Device 1 switch"
binary_sensor:
- platform: template
id: relay1_sensor
lambda: "return id(relay1).state;"
- platform: udp
provider: device-2
id: relay2_sensor
on_press:
switch.turn_on: relay1
on_release:
switch.turn_off: relay1
# Device 2
esphome:
name: device-2
udp:
binary_sensors:
- relay2_sensor
switch:
- platform: gpio
pin: GPIO6
id: relay2
name: "Device 2 switch"
binary_sensor:
- platform: template
id: relay2_sensor
lambda: "return id(relay2).state;"
- platform: udp
provider: device-1
id: relay1_sensor
on_press:
switch.turn_on: relay2
on_release:
switch.turn_off: relay2
The following example shows a device using encryption to read a sensor and two binary sensors from two different
devices, one with encryption and ping-pong and one without. It also rebroadcasts one of those binary sensors with its own
encryption and a rolling code to a remote host.
.. code-block:: yaml
udp:
update_interval: 60s
addresses: ["10.87.135.110"]
ping_pong_enable: true
rolling_code_enable: true
encryption: "Muddy Waters"
binary_sensors:
- tick_tock
providers:
- name: st7735s
encryption: "Blind Willie Johnson"
# - name: room-lights # Not required here since no encryption
binary_sensor:
- platform: udp
provider: st7735s
id: tick_tock
- platform: udp
provider: room-lights
id: relay1_sensor
sensor:
- platform: udp
provider: st7735s
id: wifi_signal_sensor
The example below shows a provider device separating data sent to different consumers. There are two provider confgurations, with different IDs.
The ``udp_internal`` provider broadcasts the selected sensor states in plain every 10 seconds to all the network members, while the ``udp_external``
provider sends other sensors data to an external IP address and port, with encryption. The node also listens to data from a ``remote-node`` through
the port specified in the ``udp_external`` configuration:
.. code-block:: yaml
udp:
- id: udp_internal
update_interval: 10s
sensors:
- temp_outdoor
- temp_rooma
- temp_roomb
- temp_roomc
- temp_garage
- temp_water
- humi_rooma
- humi_roomb
- humi_roomc
- id: udp_external
update_interval: 60s
encryption: "Muddy Waters"
ping_pong_enable: true
rolling_code_enable: true
port: 38512
addresses:
- 10.87.135.110
binary_sensors:
- binary_sensor_door
sensors:
- temp_outdoor
binary_sensor:
- platform: udp
id: binary_sensor_unlock
udp_id: udp_external
provider: remote-node
remote_id: binary_sensor_unlock_me
on_press:
- lambda: |-
ESP_LOGI("main", "d command to binary_sensor_unlock");
.. [#f1] As known in 2024.06.
See Also
--------
- :doc:`/components/binary_sensor/udp`
- :doc:`/components/sensor/udp`
- :ref:`automation`
- :apiref:`udp/udp_component.h`
- :ghedit:`Edit`

View File

@ -37,6 +37,8 @@ Configuration:
- **media_player** (*Optional*, :ref:`config-id`): The :doc:`media_player </components/media_player/index>` to use
to output the response. Cannot be used with ``speaker`` above.
- **use_wake_word** (*Optional*, boolean): Enable wake word on the assist pipeline. Defaults to ``false``.
- **conversation_timeout** (*Optional*, :ref:`config-time`): How long to wait before resetting the ``conversation_id``
sent to the voice assist pipeline, which contains the context of the current assist pipeline. Defauls to ``300s``.
- **on_intent_start** (*Optional*, :ref:`Automation <automation>`): An automation to perform when intent processing starts.
- **on_intent_end** (*Optional*, :ref:`Automation <automation>`): An automation to perform when intent processing ends.
- **on_listening** (*Optional*, :ref:`Automation <automation>`): An automation to

View File

@ -67,9 +67,9 @@ author = "ESPHome"
# built documents.
#
# The short X.Y version.
version = "2024.8"
version = "2024.9"
# The full version, including alpha/beta/rc tags.
release = "2024.8.3"
release = "2024.9.0b1"
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.

View File

@ -39,6 +39,7 @@ ESPHome's command line interface always has the following format
.. option:: -v|--verbose
Enable verbose esphome logs.
Can also be enabled via environment variable ``ESPHOME_VERBOSE=true``.
``--quiet`` Option
------------------

View File

@ -455,30 +455,89 @@ check fails, please look at the Github Actions log and fix all errors that appea
**When will my PR be reviewed/merged?**
ESPHome is a big project; we encourage everybody to test, review and comment on PRs. Despite this, reviews can (and
often do) take some time.
ESPHome is a big project; :ref:`we encourage everybody to test, review and comment on PRs.<can_i_help_review>` Despite
this, reviews can (and often do) take some time.
**But howwww looonnnggg???**
Small PRs are easier to review and are often reviewed first. If you want your PR to be reviewed (and merged) quickly,
here are some tips:
- We would rather review ten ten-line PRs than one 100-line PR.
- Be sure to follow all :ref:`codebase_standards` as you make changes -- when reviewers have to spend time
commenting on/correcting your PR because you didn't name variables correctly or didn't prefix member variable
accesses with ``this->``, it wastes time we could be using to review other PRs which *do* follow the standards.
- *Keep PRs as small and as focused as possible.* Smaller PRs tend to be easier to understand and take less time to
review. Large PRs (many hundreds or thousands of lines) by their nature (of being large) tend to keep changing which
means reviewers have to revisit them over and over as they evolve. This isn't a tenable practice for project
maintainers. Break your work into multiple, smaller PRs and link these PRs together with comments in the description
so reviewers can follow the work more easily.
- The above bullet paraphrased: *we would rather review ten ten-line PRs than one 100-line PR.*
- *Be sure to follow all* :ref:`codebase_standards`. When reviewers have to spend time commenting on/correcting your PR
because you didn't name variables correctly or didn't prefix member variable accesses with ``this->``, it wastes time
we could be using to review other PRs which *do* follow the standards.
- If you wish to take on a big project, such as refactoring a substantial section of the codebase or integrating
another open source project with ESPHome, please discuss this with us on `Discord <https://discord.gg/KhAMKrd>`__ or
`create a discussion on GitHub <https://github.com/esphome/esphome/discussions>`__ **before** you do all the work and
attempt to submit a massive PR.
- While we realize it's not *always* possible, avoid submitting PRs which are thousands of lines in size. Such PRs are
simply too complex and take excessive amounts of time to review. Break your work into multiple, smaller PRs to make
the changes more tenable for reviewers.
- If you are not sure about how you should proceed with some changes, **please**
`discuss it with us on Discord <https://discord.gg/KhAMKrd>`__ before you go do a bunch of work that we can't (for
`discuss it with us on Discord <https://discord.gg/KhAMKrd>`__ *before* you go do a bunch of work that we can't (for
whatever reason) accept...and then you have to go back and re-do it all to get your PR merged. It's easier to make
corrections early-on -- and we want to help you!
.. _can_i_help_review:
Can I Help Review PRs?
**********************
**YES! PLEASE!!!**
While only maintainers can *merge* PRs, we value feedback from the community and it *is considered* as we review them.
Put another way, when a PR has several "This worked for me!" comments on it, we know that the author's work is doing
what it's supposed to, even if some other, underlying aspects might still need some fine-tuning to be consistent with
the rest of the codebase.
Testing
^^^^^^^
Often, the easiest way to help review PRs is by testing. Many (but not all) PRs can be used as
:doc:`/components/external_components` and can easily be added into your configuration for testing, like this:
.. code-block:: yaml
external_components:
- source: github://pr#2639
components: [ rtttl ]
...you just need to update the PR number and component name(s) in the YAML accordingly.
If you test a PR, please *share your results by leaving a comment on the PR!* If it doesn't work, be sure to include
any messages from the compiler and/or device logs so the author can troubleshoot the issue. *Comments which state no
more than "it doesn't work" are not helpful!*
Code Review
^^^^^^^^^^^
Beyond basic functionality (*"does it work?"*), here are a few other items we check for when reviewing PRs:
- Are file names & paths appropriate for/consistent with the codebase?
- Are namespace names consistent with the component/platform?
- Do all ``#define`` macro names match the namespace?
- Are all :ref:`codebase_standards` adhered to?
- Are there any calls to ``delay()`` with a duration longer than 10 milliseconds?
- Are any class methods doing work that they shouldn't be? For example, let's consider the ``dump_config()`` method:
- This method is intended to do **nothing** other than *print values* that were retrieved earlier (in ``setup()``).
- If this method has (for example) a ``this->read(...)`` call in it, it does not pass review and needs to be changed.
- Is the component/platform doing *exactly what it's supposed to*? Consider the example of a new serial bus interface a
contributor has implemented:
- The author has implemented this component with an action called ``superbus.send``.
- The author has concerns about too much traffic on the bus, so they have implemented a check in this action which
blocks duplicate message transmissions on the bus. The effect is that, if ``superbus.send`` is called repeatedly
with the same message, only the first call will actually send the message on the bus.
This behavior is not consistent with what ESPHome users expect. If the action ``superbus.send`` is called, it should
*always* send the message, regardless of the content. If there are concerns about (in this example) bus
utilization, perhaps messages can be queued instead of dropped/ignored.
.. _prs-are-being-drafted-when-changes-are-needed:
Why Was My PR was Marked as a Draft?
@ -563,7 +622,7 @@ Note that you can use this procedure for other branches, too, such as ``next`` o
Using ``git rebase`` will result in your changes having to be *force-pushed* back up to GitHub.
**Do not force-push** your branch once your PR is being reviewed; GitHub allows reviewers to mark files a "viewed"
**Do not force-push** your branch once your PR is being reviewed; GitHub allows reviewers to mark files as "viewed"
and, when you force-push, this history **is lost**, forcing your reviewer to re-review files they may have already
reviewed!
@ -750,6 +809,8 @@ the provided methods.
Finally, your component must have a ``dump_config`` method that prints the complete user configuration.
.. _delays_in_code:
A Note About Delays in Code
***************************
@ -818,8 +879,8 @@ ESPHome's maintainers work hard to maintain a high standard for its code. We try
- Components should dump their configuration using ``ESP_LOGCONFIG`` at startup in ``dump_config()``.
- ESPHome uses a unified formatting tool for all source files (but this tool can be difficult to install).
When creating a new PR in GitHub, see the Github Actions output to see what formatting needs to be changed
and what potential problems are detected.
When creating a new PR in GitHub, be sure to check the Github Actions output to see what formatting needs to be
changed and what potential problems are detected.
- Use of external libraries should be kept to a minimum:
- If the component you're developing has a simple communication interface, please consider implementing the library
@ -834,6 +895,12 @@ ESPHome's maintainers work hard to maintain a high standard for its code. We try
- Components **must** use the provided abstractions like ``sensor``, ``switch``, etc. Components specifically should
**not** directly access other components -- for example, to publish to MQTT topics.
- Implementations for new devices should contain reference links for the datasheet and other sample implementations.
- If you have used ``delay()`` or constructed code which blocks for a duration longer than ten milliseconds, be sure to
read :ref:`delays_in_code`.
- Comments in code should be used as appropriate, such as to help explain some complexity or to provide a brief summary
of what a class, method, etc. is doing. PRs which include large blocks of commented-out code will not be accepted.
Single lines of commented code may be useful from time to time (for example, to call out something which was
deliberately omitted for some reason) but should generally be avoided.
- Please test your changes :)
.. note::

Binary file not shown.

Before

Width:  |  Height:  |  Size: 42 KiB

After

Width:  |  Height:  |  Size: 54 KiB

View File

@ -49,6 +49,7 @@ Contributors
- `Chris Byrne (@adapt0) <https://github.com/adapt0>`__
- `Attila Darazs (@adarazs) <https://github.com/adarazs>`__
- `ADeadPixel (@ADeadPixel) <https://github.com/ADeadPixel>`__
- `Adam DeMuri (@ademuri) <https://github.com/ademuri>`__
- `adezerega (@adezerega) <https://github.com/adezerega>`__
- `Eugen (@Adminius) <https://github.com/Adminius>`__
- `Andrea Donno (@adonno) <https://github.com/adonno>`__
@ -141,6 +142,7 @@ Contributors
- `arantius (@arantius) <https://github.com/arantius>`__
- `Ryan DeShone (@ardichoke) <https://github.com/ardichoke>`__
- `Ariff Saad (@arffsaad) <https://github.com/arffsaad>`__
- `ArkanStasarik (@ArkanStasarik) <https://github.com/ArkanStasarik>`__
- `arturo182 (@arturo182) <https://github.com/arturo182>`__
- `arunderwood (@arunderwood) <https://github.com/arunderwood>`__
- `Arya (@Arya11111) <https://github.com/Arya11111>`__
@ -198,6 +200,7 @@ Contributors
- `Ben Hoff (@benhoff) <https://github.com/benhoff>`__
- `Benoît Leforestier (@Benichou34) <https://github.com/Benichou34>`__
- `Benjamin Aigner (@benjaminaigner) <https://github.com/benjaminaigner>`__
- `benklop (@benklop) <https://github.com/benklop>`__
- `benniju (@benniju) <https://github.com/benniju>`__
- `Benno Pütz (@bennop) <https://github.com/bennop>`__
- `Benny H (@benny-aus) <https://github.com/benny-aus>`__
@ -260,6 +263,7 @@ Contributors
- `brianrjones69 (@brianrjones69) <https://github.com/brianrjones69>`__
- `Ben Brooks (@brooksben11) <https://github.com/brooksben11>`__
- `brtchip-tuannguyen (@brtchip-tuannguyen) <https://github.com/brtchip-tuannguyen>`__
- `Vaclav (@bruxy70) <https://github.com/bruxy70>`__
- `buddydvd (@buddydvd) <https://github.com/buddydvd>`__
- `bulburDE (@bulburDE) <https://github.com/bulburDE>`__
- `Justin Bunton (@Bunton33) <https://github.com/Bunton33>`__
@ -583,6 +587,7 @@ Contributors
- `Daniel Dunn (@EternityForest) <https://github.com/EternityForest>`__
- `EtienneMD (@EtienneMD) <https://github.com/EtienneMD>`__
- `etzisim (@etzisim) <https://github.com/etzisim>`__
- `EvanC-Au (@EvanC-Au) <https://github.com/EvanC-Au>`__
- `Evan Coleman (@evandcoleman) <https://github.com/evandcoleman>`__
- `Clemens Kirchgatterer (@everslick) <https://github.com/everslick>`__
- `Everything Smart Home (@EverythingSmartHome) <https://github.com/EverythingSmartHome>`__
@ -680,6 +685,7 @@ Contributors
- `git2212 (@git2212) <https://github.com/git2212>`__
- `GitforZhangXL (@GitforZhangXL) <https://github.com/GitforZhangXL>`__
- `github-actions[bot] (@github-actions[bot]) <https://github.com/github-actions[bot]>`__
- `GitJRS (@GitJRS) <https://github.com/GitJRS>`__
- `gitolicious (@gitolicious) <https://github.com/gitolicious>`__
- `The Gitter Badger (@gitter-badger) <https://github.com/gitter-badger>`__
- `Frederik Gladhorn (@gladhorn) <https://github.com/gladhorn>`__
@ -843,6 +849,7 @@ Contributors
- `JasperPlant (@JasperPlant) <https://github.com/JasperPlant>`__
- `Jas Strong (@jasstrong) <https://github.com/jasstrong>`__
- `Alex Boyd (@javawizard) <https://github.com/javawizard>`__
- `JayElDubya (@JayElDubya) <https://github.com/JayElDubya>`__
- `Jay Greco (@jaygreco) <https://github.com/jaygreco>`__
- `Jay Newstrom (@JayNewstrom) <https://github.com/JayNewstrom>`__
- `Jeff (@jazzmonger) <https://github.com/jazzmonger>`__
@ -978,6 +985,7 @@ Contributors
- `kghandi (@kghandi) <https://github.com/kghandi>`__
- `Khoi Hoang (@khoih-prog) <https://github.com/khoih-prog>`__
- `AngeloGioacchino Del Regno (@kholk) <https://github.com/kholk>`__
- `Albert Gouws (@KiLLeRRaT) <https://github.com/KiLLeRRaT>`__
- `Kilowatt (@Kilowatt-W) <https://github.com/Kilowatt-W>`__
- `kimonm (@kimonm) <https://github.com/kimonm>`__
- `Kip (@kipwittchen) <https://github.com/kipwittchen>`__
@ -990,6 +998,7 @@ Contributors
- `Kevin Lewis (@kll) <https://github.com/kll>`__
- `kmoulton (@kmoulton) <https://github.com/kmoulton>`__
- `KNXBroker (@KNXBroker) <https://github.com/KNXBroker>`__
- `KodinLanewave (@KodinLanewave) <https://github.com/KodinLanewave>`__
- `KoenBreeman (@KoenBreeman) <https://github.com/KoenBreeman>`__
- `Koen Vervloesem (@koenvervloesem) <https://github.com/koenvervloesem>`__
- `kokangit (@kokangit) <https://github.com/kokangit>`__
@ -1461,6 +1470,7 @@ Contributors
- `probonopd (@probonopd) <https://github.com/probonopd>`__
- `Gary Morris (@progrmr) <https://github.com/progrmr>`__
- `Mike Lynch (@Prow7) <https://github.com/Prow7>`__
- `Prowler2 (@Prowler2) <https://github.com/Prowler2>`__
- `Peter Sarossy (@psarossy) <https://github.com/psarossy>`__
- `Peter Stuifzand (@pstuifzand) <https://github.com/pstuifzand>`__
- `Peter Tatrai (@ptatrai) <https://github.com/ptatrai>`__
@ -1872,6 +1882,7 @@ Contributors
- `Vishnu Mohanan (@vishnumaiea) <https://github.com/vishnumaiea>`__
- `VitaliyKurokhtin (@VitaliyKurokhtin) <https://github.com/VitaliyKurokhtin>`__
- `voed (@voed) <https://github.com/voed>`__
- `James Vogel (@voglster) <https://github.com/voglster>`__
- `voibit (@voibit) <https://github.com/voibit>`__
- `Xuming Feng (@voicevon) <https://github.com/voicevon>`__
- `Manuel Bichler (@votacom) <https://github.com/votacom>`__
@ -1943,6 +1954,7 @@ Contributors
- `yousaf465 (@yousaf465) <https://github.com/yousaf465>`__
- `Jevgeni Kiski (@yozik04) <https://github.com/yozik04>`__
- `YuanL.Lee (@yuanl) <https://github.com/yuanl>`__
- `Cj Fraser (@yuniq-neko) <https://github.com/yuniq-neko>`__
- `Yuval Aboulafia (@yuvalabou) <https://github.com/yuvalabou>`__
- `Z3LIFF (@z3liff) <https://github.com/z3liff>`__
- `ZabojnikM (@ZabojnikM) <https://github.com/ZabojnikM>`__
@ -1950,6 +1962,7 @@ Contributors
- `zaluthar (@zaluthar) <https://github.com/zaluthar>`__
- `david reid (@zathras777) <https://github.com/zathras777>`__
- `Zebble (@Zebble) <https://github.com/Zebble>`__
- `Wojciech Zelek (@zelo) <https://github.com/zelo>`__
- `Brynley McDonald (@ZephireNZ) <https://github.com/ZephireNZ>`__
- `ZJY (@zhangjingye03) <https://github.com/zhangjingye03>`__
- `San (@zhujunsan) <https://github.com/zhujunsan>`__
@ -1967,4 +1980,4 @@ Contributors
- `Christian Zufferey (@zuzu59) <https://github.com/zuzu59>`__
- `Zynth-dev (@Zynth-dev) <https://github.com/Zynth-dev>`__
*This page was last updated September 3, 2024.*
*This page was last updated September 11, 2024.*

BIN
images/bl0906.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

1
images/ch422g.svg Normal file
View File

@ -0,0 +1 @@
<svg viewBox="0 0 120 25" id="svg5" xmlns="http://www.w3.org/2000/svg" xmlns:svg="http://www.w3.org/2000/svg"><defs id="defs9"/><path d="M5 0H115a5 5 0 015 5v15a5 5 0 01-5 5H5a5 5 0 01-5-5V5a5 5 0 015-5z" style="fill:#000" id="path2"/><g aria-label="CH422G" id="component-text" style="font-weight:900;font-size:25px;font-family:Montserrat;letter-spacing:1.1px;fill:#fffffc"><path d="m15.475 21.4q-2.1.0-3.9-.65-1.775-.675-3.1-1.9-1.3-1.225-2.025-2.9-.725-1.675-.725-3.7t.725-3.7q.725-1.675 2.025-2.9 1.325-1.225 3.1-1.875 1.8-.675 3.9-.675 2.575.0 4.55.9 2 .9 3.3 2.6L19.6 9.925q-.775-.975-1.725-1.5-.925-.55-2.1-.55-.925.0-1.675.3t-1.3.875q-.525.575-.825 1.4-.3.8-.3 1.8t.3 1.825q.3.8.825 1.375.55.575 1.3.875t1.675.3q1.175.0 2.1-.525.95-.55 1.725-1.525l3.725 3.325q-1.3 1.675-3.3 2.6-1.975.9-4.55.9z" id="path11"/><path d="m37.474987 3.5h5.9V21h-5.9zm-5.45 17.5h-5.9V3.5h5.9zm5.85-6.45h-6.25V9.7h6.25z" id="path13"/><path d="m46.475009 18v-3.75l7.425-10.75h6.05l-7.15 10.75-2.75-.825h13.55V18zm9.075 3v-3l.175-4.575V10.75h5.55V21z" id="path15"/><path d="m65.500007 21v-3.625l6.325-5.85q.6-.575.875-1 .3-.425.4-.75.1-.35.1-.65.0-.65-.425-1-.425-.375-1.275-.375-.775.0-1.475.425-.7.4-1.1 1.2l-4.45-2.225q.95-1.8 2.85-2.925 1.9-1.125 4.725-1.125 2.075.0 3.675.675t2.5 1.9q.9 1.225.9 2.9.0.85-.225 1.7-.2.85-.85 1.8-.65.925-1.925 2.075l-4.75 4.325-.925-2.05h9.075V21z" id="path17"/><path d="m81.799998 21v-3.625l6.325-5.85q.6-.575.875-1 .3-.425.4-.75.1-.35.1-.65.0-.65-.425-1-.425-.375-1.275-.375-.775.0-1.475.425-.7.4-1.1 1.2l-4.45-2.225q.95-1.8 2.85-2.925 1.9-1.125 4.725-1.125 2.075.0 3.675.675t2.5 1.9q.9 1.225.9 2.9.0.85-.225 1.7-.2.85-.85 1.8-.65.925-1.925 2.075l-4.75 4.325-.925-2.05h9.075V21z" id="path19"/><path d="m107.89999 21.4q-2.125.0-3.925-.65-1.775-.675-3.1-1.9-1.299996-1.225-2.024996-2.9-.725-1.675-.725-3.7t.725-3.7q.725-1.675 2.049996-2.9 1.325-1.225 3.125-1.875 1.825-.675 4-.675 2.6.0 4.625.875 2.05.875 3.375 2.5l-3.775 3.325q-.825-.95-1.8-1.425-.95-.5-2.125-.5-.975.0-1.775.3-.775.3-1.325.875t-.85 1.375-.3 1.825q0 .975.3 1.8.3.8.85 1.375t1.3.9q.775.3 1.725.3 1 0 1.95-.325.95-.35 2.025-1.175l3.3 4.05q-1.6 1.075-3.65 1.65-2.05.575-3.975.575zm2.5-2.975v-6.65h5.125v7.4z" id="path21"/></g></svg>

After

Width:  |  Height:  |  Size: 2.2 KiB

BIN
images/ltr501.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

1
images/udp.svg Normal file
View File

@ -0,0 +1 @@
<svg viewBox="0 0 69 25" id="svg5" xmlns="http://www.w3.org/2000/svg" xmlns:svg="http://www.w3.org/2000/svg"><defs id="defs9"/><path d="M5 0H64a5 5 0 015 5v15a5 5 0 01-5 5H5a5 5 0 01-5-5V5a5 5 0 015-5z" style="fill:#000" id="path2"/><g aria-label="UDP" id="component-text" style="font-weight:900;font-size:25px;font-family:Montserrat;letter-spacing:1.1px;fill:#fffffc"><path d="m14.8 21.4q-4.025.0-6.275-2.175t-2.25-6.1V3.5h5.9v9.45q0 2 .725 2.85.725.825 1.95.825 1.25.0 1.95-.825.725-.85.725-2.85V3.5h5.8v9.625q0 3.925-2.25 6.1Q18.825 21.4 14.8 21.4z" id="path11"/><path d="M27.12501 21V3.5h8.625q2.925.0 5.15 1.075 2.225 1.05 3.475 3t1.25 4.65q0 2.725-1.25 4.7-1.25 1.95-3.475 3.025-2.225 1.05-5.15 1.05zm5.9-4.6h2.475q1.25.0 2.175-.475.95-.475 1.475-1.4.525-.95.525-2.3.0-1.325-.525-2.25t-1.475-1.4q-.925-.475-2.175-.475h-2.475z" id="path13"/><path d="M48.875016 21V3.5h8.425q2.45.0 4.225.8 1.8.8 2.775 2.3.975 1.475.975 3.5t-.975 3.5q-.975 1.475-2.775 2.3-1.775.8-4.225.8h-5.15l2.625-2.525V21zm5.9-6.175-2.625-2.675h4.775q1.225.0 1.8-.55.6-.55.6-1.5t-.6-1.5q-.575-.55-1.8-.55h-4.775l2.625-2.675z" id="path15"/></g></svg>

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

@ -204,6 +204,8 @@ Network Protocols
HTTP Request, components/http_request, connection.svg, dark-invert
mDNS, components/mdns, radio-tower.svg, dark-invert
WireGuard, components/wireguard, wireguard_custom_logo.svg
StatsD, components/statsd, connection.svg
UDP, components/udp, udp.svg
Bluetooth/BLE
-------------
@ -224,6 +226,7 @@ Management and Monitoring
Debug, components/debug, bug-report.svg, dark-invert
Logger, components/logger, file-document-box.svg, dark-invert
Prometheus, components/prometheus, prometheus.svg
StatsD, components/statsd, connection.svg
Safe Mode, components/safe_mode, restart-alert.svg
Web Server, components/web_server, http.svg, dark-invert
ESP32 Camera Web Server, components/esp32_camera_web_server, camera.svg, dark-invert
@ -266,6 +269,7 @@ I/O Expanders/Multiplexers
.. imgtable::
CH422G, components/ch422g, ch422g.svg
MAX6956 - I²C Bus, components/max6956, max6956.jpg
MCP230XX - I²C Bus, components/mcp230xx, mcp230xx.svg
MCP23SXX - SPI Bus, components/mcp23Sxx, mcp230xx.svg
@ -401,6 +405,7 @@ Electricity
ADE7953, components/sensor/ade7953, ade7953.svg, Power
ATM90E26, components/sensor/atm90e26, atm90e26.jpg, Voltage & Current & Power
ATM90E32, components/sensor/atm90e32, atm90e32.jpg, Voltage & Current & Power
BL0906, components/sensor/bl0906, bl0906.png, Voltage & Current & Power & Energy
BL0939, components/sensor/bl0939, bl0939.png, Voltage & Current & Power & Energy
BL0940, components/sensor/bl0940, bl0940.png, Voltage & Current & Power
BL0942, components/sensor/bl0942, bl0942.png, Voltage & Current & Power
@ -504,11 +509,14 @@ Light
APDS9960, components/sensor/apds9960, apds9960.jpg, Colour & Gesture
AS7341, components/sensor/as7341, as7341.jpg, Spectral Color Sensor
BH1750, components/sensor/bh1750, bh1750.jpg, Lux
LTR301, components/sensor/ltr501, ltr501.jpg, Lux
LTR303, components/sensor/ltr_als_ps, ltr303.jpg, Lux
LTR329, components/sensor/ltr_als_ps, ltr329.jpg, Lux
LTR390, components/sensor/ltr390, ltr390.jpg, Lux & UV
LTR501, components/sensor/ltr501, ltr501.jpg, Lux & Proximity
LTR553, components/sensor/ltr_als_ps, ltr-ps.jpg, Lux & Proximity
LTR556, components/sensor/ltr_als_ps, ltr-ps.jpg, Lux & Proximity
LTR558, components/sensor/ltr501, ltr501.jpg, Lux & Proximity
LTR559, components/sensor/ltr_als_ps, ltr559.jpg, Lux & Proximity
LTR659, components/sensor/ltr_als_ps, ltr-ps.jpg, Proximity
MAX44009, components/sensor/max44009, max44009.svg, Lux
@ -1155,7 +1163,6 @@ Cookbook
Sonoff Fishpond Pump, cookbook/sonoff-fishpond-pump, cookbook-sonoff-fishpond-pump.jpg
Arduino Port Extender, cookbook/arduino_port_extender, arduino_logo.svg
EHMTX a matrix status/text display, cookbook/ehmtx, ehmtx.jpg
Share data directly between ESPHome nodes, cookbook/http_request_sensor, connection.svg, dark-invert
Do you have other awesome automations or cool setups? Please feel free to add them to the
documentation for others to copy. See :doc:`Contributing </guides/contributing>`.