Skip to content

Commit 23dd488

Browse files
authored
Merge branch 'next' into lvgl-containers
2 parents d6ad4a8 + 6f076dd commit 23dd488

File tree

6 files changed

+61
-17
lines changed

6 files changed

+61
-17
lines changed

content/automations/actions.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -460,7 +460,21 @@ on_...:
460460

461461
- **condition** (**Required**, [condition](#config-condition)): The condition to check.
462462

463-
{{< anchor "lambda_condition" >}}
463+
### `component.is_idle` Condition
464+
465+
This condition checks if a given component is idle. A component is considered to be idle if it has completed
466+
setup, has not been marked as failed, and is not currently being called by the loop task. This is useful for
467+
synchronizing actions with the state of the component, for example, an e-paper display component that requires
468+
a significant amount of time to update the display panel.
469+
470+
```yaml
471+
on_...:
472+
then:
473+
- if:
474+
condition:
475+
component.is_idle: some_component
476+
# ...
477+
```
464478

465479
### `lambda` Condition
466480

content/components/display/epaper_spi.md

Lines changed: 18 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -15,28 +15,34 @@ better integration with ESPHome's async architecture.
1515
The communication method uses 4-wire [SPI](#spi), so you need to have an `spi:` section in your
1616
configuration.
1717

18+
The driver supports a number of displays and there are also specific configurations for ESP32 boards with integrated displays.
19+
For those boards the predefined configuration will set the correct pins and dimensions for the display.
20+
1821
```yaml
1922
display:
2023
- platform: epaper_spi
21-
cs_pin: GPIOXX
22-
dc_pin: GPIOXX
23-
busy_pin: GPIOXX
24-
reset_pin: GPIOXX
25-
model: 7.3in-spectra-e6
24+
model: Seeed-reTerminal-E1002
2625
lambda: |-
2726
it.filled_circle(it.get_width() / 2, it.get_height() / 2, 50, Color::BLACK);
2827
```
2928
30-
## Configuration variables
29+
## Supported displays
3130
32-
- **cs_pin** (**Required**, [Pin Schema](#config-pin_schema)): The CS pin.
33-
- **dc_pin** (**Required**, [Pin Schema](#config-pin_schema)): The DC pin.
34-
- **model** (**Required**): The model of the ePaper display. Currently supported:
31+
| Model name | Manufacturer | Product Description |
32+
|------------------------|--------------|------------------------------------------------------------|
33+
| Spectra-E6 | Eink | <https://www.eink.com/brand/detail/Spectra6> |
34+
| Seeed-reTerminal-E1002 | Seeed Studio | <https://www.seeedstudio.com/reTerminal-E1002-p-6533.html> |
35+
36+
## Configuration variables
3537
36-
- `7.3in-spectra-e6` - 7.3" Spectra E6 6-color display (800×480 pixels)
38+
When using a model defining an integrated ESP32 display board most of the configuration such as the pins and dimensions will be set by default,
39+
but can be overridden if needed.
3740
38-
- **busy_pin** (*Optional*, [Pin Schema](#config-pin_schema)): The BUSY pin. Defaults to not connected.
39-
- **reset_pin** (*Optional*, [Pin Schema](#config-pin_schema)): The RESET pin. Defaults to not connected.
41+
- **model** (**Required**): The model of the ePaper display. See the table above for options.
42+
- **cs_pin** (**Required**, [Pin Schema](#config-pin_schema)): The CS pin. Predefined for integrated boards.
43+
- **dc_pin** (**Required**, [Pin Schema](#config-pin_schema)): The DC pin. Predefined for integrated boards.
44+
- **busy_pin** (*Optional*, [Pin Schema](#config-pin_schema)): The BUSY pin, if used.
45+
- **reset_pin** (*Optional*, [Pin Schema](#config-pin_schema)): The RESET pin, if used.
4046
Make sure you pull this pin high (by connecting it to 3.3V with a resistor) if not connected to a GPIO pin.
4147
4248
- **rotation** (*Optional*): Set the rotation of the display. Everything you draw in `lambda:` will be rotated

content/components/display/mipi_spi.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ boards and chips, but the driver is also designed to be customisable in YAML for
2929
## Supported boards and driver chips
3030

3131
The driver supports a number of display driver chips, and can be configured for custom displays. As well as support for
32-
driver chips, there are also specific configurations for several ESP32 boards with integrated displays. For tbose boards
32+
driver chips, there are also specific configurations for several ESP32 boards with integrated displays. For those boards
3333
the predefined configuration will set the correct pins and dimensions for the display.
3434

3535
For custom displays, the driver can be configured with the correct pins and dimensions, and the driver chip can be

content/components/esp32.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,10 @@ esp32:
148148
- **enable_idf_experimental_features** (*Optional*, boolean): Can be set to `true` to enable experimental features. Use of
149149
experimental features may cause instability or other issues.
150150

151+
- **loop_task_stack_size** (*Optional*, int): Loop task stack size in bytes. Increase if experiencing stack overflow
152+
errors (e.g., with complex code or deep recursion). Higher values reduce heap availability. Valid range is 8192-32768
153+
bytes. Defaults to 8192 bytes.
154+
151155
**LWIP Optimization Options (ESP-IDF only):**
152156

153157
The following options are available under the `advanced` section when using the ESP-IDF framework to optimize

content/components/i2c.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ params:
99

1010
{{< anchor "i2c" >}}
1111

12-
This component sets up the I²C bus for your ESP32 or ESP8266. In order for these components
12+
This component sets up the I²C bus for your ESP32, ESP8266, RP2040 or NRF52. In order for these components
1313
to work correctly, you need to define the I²C bus in your configuration. Please note the ESP
1414
will enable its internal 10kΩ pullup resistors for these pins, so you usually don't need to
1515
put on external ones. You can use multiple devices on one I²C bus as each device is given a
@@ -39,7 +39,8 @@ i2c:
3939
Defaults to `true`.
4040

4141
- **frequency** (*Optional*, float): Set the frequency the I²C bus should operate on.
42-
Defaults to `50kHz`. Values are `10kHz`, `50kHz`, `100kHz`, `200kHz`, ... `800kHz`
42+
Defaults to `50kHz`. Default for NRF52 is `100kHz`. Values are `10kHz`, `50kHz`, `100kHz`, `200kHz`, ... `800kHz`.
43+
NRF52 supports only `100kHz` and `400kHz`.
4344

4445
- **timeout** (*Optional*, [Time](#config-time)): Set the I²C bus timeout.
4546
Defaults to the framework defaults (`100us` on `esp32` with `esp-idf`, `50ms` on `esp32` with `Arduino`,

content/components/lvgl/_index.md

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,10 @@ embedded graphics library to create beautiful UIs for any MCU, MPU and display t
1616

1717
To use LVGL with a [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.
1818

19-
The graphic display should be configured with `auto_clear_enabled: false` and should not have any `lambda` set. The LVGL component will take care of the display rendering. For most displays, the `update_interval` should be set to `never`, but note that some displays such as OLED and ePaper will need the update interval set to a suitable value.
19+
The graphic display should be configured with `auto_clear_enabled: false` and should not have any `lambda` set.
20+
The LVGL component will take care of the display rendering. For most displays, the `update_interval` should be
21+
set to `never`, but note that some displays such as OLED and e-paper will need the update interval set to a suitable
22+
interval, or make use of the [`on_draw_end`](#on_draw_end) trigger to manually update the display.
2023

2124
For interactivity, a {{< docref "/components/touchscreen/index" "Touchscreen" >}} (capacitive highly preferred), a {{< docref "/components/sensor/rotary_encoder" >}} or a custom keypad made up from discrete {{< docref "/components/binary_sensor/index" "Binary Sensors" >}} can be used.
2225

@@ -827,6 +830,22 @@ This [trigger](#lvgl-automation-triggers) is triggered when LVGL is resumed. Thi
827830

828831
This [trigger](#lvgl-automation-triggers) is triggered after LVGL has been setup. It is also available on any widget, but the timing is the same.
829832

833+
### `on_draw_start`
834+
835+
This [trigger](#lvgl-automation-triggers) is executed before each LVGL drawing operation.
836+
837+
### `on_draw_end`
838+
839+
This [trigger](#lvgl-automation-triggers) is executed after LVGL has completed drawing all updated screen elements. It
840+
may be used for example to trigger an update of a display component like an e-paper screen that requires the buffer
841+
to be sent to the display for it to be updated.
842+
843+
```yaml
844+
lvgl:
845+
on_draw_end:
846+
component.update: my_display_id
847+
```
848+
830849
## See Also
831850

832851
- {{< docref "/cookbook/lvgl" "LVGL Examples in the Cookbook" >}}

0 commit comments

Comments
 (0)