esphome 2024.6.6__py3-none-any.whl → 2024.7.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- esphome/components/aht10/aht10.cpp +4 -2
- esphome/components/climate/climate.cpp +10 -6
- esphome/components/climate/climate_traits.h +3 -3
- esphome/components/cover/cover.h +2 -2
- esphome/components/esp32_camera/__init__.py +6 -3
- esphome/components/esp32_can/canbus.py +3 -0
- esphome/components/ethernet/ethernet_component.cpp +8 -3
- esphome/components/font/__init__.py +2 -28
- esphome/components/gree/climate.py +1 -0
- esphome/components/gree/gree.cpp +11 -3
- esphome/components/gree/gree.h +5 -1
- esphome/components/haier/binary_sensor/__init__.py +4 -4
- esphome/components/haier/button/__init__.py +1 -1
- esphome/components/haier/climate.py +43 -9
- esphome/components/haier/haier_base.cpp +4 -0
- esphome/components/haier/haier_base.h +11 -1
- esphome/components/haier/hon_climate.cpp +109 -55
- esphome/components/haier/hon_climate.h +7 -1
- esphome/components/haier/hon_packet.h +5 -0
- esphome/components/haier/sensor/__init__.py +5 -5
- esphome/components/haier/smartair2_climate.cpp +1 -0
- esphome/components/haier/text_sensor/__init__.py +4 -4
- esphome/components/heatpumpir/climate.py +12 -5
- esphome/components/heatpumpir/heatpumpir.cpp +11 -0
- esphome/components/heatpumpir/heatpumpir.h +11 -0
- esphome/components/http_request/http_request_arduino.cpp +7 -2
- esphome/components/http_request/update/http_request_update.cpp +6 -7
- esphome/components/http_request/update/http_request_update.h +0 -3
- esphome/components/i2s_audio/__init__.py +10 -0
- esphome/components/i2s_audio/microphone/__init__.py +7 -0
- esphome/components/i2s_audio/microphone/i2s_audio_microphone.cpp +2 -3
- esphome/components/i2s_audio/microphone/i2s_audio_microphone.h +3 -0
- esphome/components/image/__init__.py +2 -29
- esphome/components/improv_serial/improv_serial_component.cpp +9 -8
- esphome/components/ltr390/ltr390.cpp +44 -29
- esphome/components/ltr390/ltr390.h +9 -5
- esphome/components/ltr390/sensor.py +35 -5
- esphome/components/mdns/__init__.py +3 -3
- esphome/components/mdns/mdns_component.cpp +3 -1
- esphome/components/mdns/mdns_component.h +3 -1
- esphome/components/mdns/mdns_esp32.cpp +2 -1
- esphome/components/mdns/mdns_esp8266.cpp +2 -1
- esphome/components/mdns/mdns_host.cpp +2 -1
- esphome/components/mdns/mdns_libretiny.cpp +2 -1
- esphome/components/mdns/mdns_rp2040.cpp +2 -1
- esphome/components/micro_wake_word/__init__.py +205 -56
- esphome/components/micro_wake_word/micro_wake_word.cpp +225 -275
- esphome/components/micro_wake_word/micro_wake_word.h +77 -107
- esphome/components/micro_wake_word/preprocessor_settings.h +20 -0
- esphome/components/micro_wake_word/streaming_model.cpp +189 -0
- esphome/components/micro_wake_word/streaming_model.h +84 -0
- esphome/components/mitsubishi/mitsubishi.cpp +1 -0
- esphome/components/modbus_controller/text_sensor/__init__.py +2 -1
- esphome/components/modbus_controller/text_sensor/modbus_textsensor.cpp +4 -1
- esphome/components/modbus_controller/text_sensor/modbus_textsensor.h +1 -1
- esphome/components/number/__init__.py +2 -0
- esphome/components/ota/ota_backend_arduino_esp32.cpp +22 -7
- esphome/components/ota/ota_backend_arduino_esp8266.cpp +23 -8
- esphome/components/ota/ota_backend_arduino_libretiny.cpp +22 -7
- esphome/components/ota/ota_backend_arduino_rp2040.cpp +22 -7
- esphome/components/pmsa003i/pmsa003i.cpp +9 -0
- esphome/components/qspi_amoled/display.py +16 -4
- esphome/components/qspi_amoled/qspi_amoled.cpp +16 -0
- esphome/components/qspi_amoled/qspi_amoled.h +0 -3
- esphome/components/remote_base/dooya_protocol.cpp +4 -4
- esphome/components/remote_base/rc_switch_protocol.cpp +1 -1
- esphome/components/restart/button/__init__.py +2 -0
- esphome/components/script/__init__.py +1 -1
- esphome/components/sensor/__init__.py +2 -0
- esphome/components/tuya/tuya.cpp +8 -2
- esphome/components/tuya/tuya.h +3 -1
- esphome/components/uart/__init__.py +72 -9
- esphome/components/uart/uart_component_esp32_arduino.cpp +18 -4
- esphome/components/uart/uart_component_esp_idf.cpp +22 -2
- esphome/components/uart/uart_component_host.cpp +295 -0
- esphome/components/uart/uart_component_host.h +38 -0
- esphome/components/uptime/sensor.py +44 -11
- esphome/components/uptime/{uptime_sensor.cpp → uptime_seconds_sensor.cpp} +11 -7
- esphome/components/uptime/{uptime_sensor.h → uptime_seconds_sensor.h} +2 -2
- esphome/components/uptime/uptime_timestamp_sensor.cpp +39 -0
- esphome/components/uptime/uptime_timestamp_sensor.h +30 -0
- esphome/components/veml7700/veml7700.cpp +1 -1
- esphome/components/veml7700/veml7700.h +5 -5
- esphome/components/voice_assistant/voice_assistant.cpp +4 -2
- esphome/components/web_server/server_index_v2.h +42 -41
- esphome/components/web_server/server_index_v3.h +368 -367
- esphome/components/wifi/wifi_component_esp_idf.cpp +1 -1
- esphome/components/wifi/wifi_component_pico_w.cpp +18 -2
- esphome/components/wireguard/__init__.py +1 -1
- esphome/components/x9c/output.py +7 -1
- esphome/const.py +2 -1
- esphome/core/defines.h +1 -0
- esphome/core/helpers.cpp +2 -2
- esphome/core/helpers.h +1 -1
- esphome/external_files.py +26 -0
- {esphome-2024.6.6.dist-info → esphome-2024.7.0.dist-info}/METADATA +1 -1
- {esphome-2024.6.6.dist-info → esphome-2024.7.0.dist-info}/RECORD +101 -95
- esphome/components/micro_wake_word/audio_preprocessor_int8_model_data.h +0 -493
- {esphome-2024.6.6.dist-info → esphome-2024.7.0.dist-info}/LICENSE +0 -0
- {esphome-2024.6.6.dist-info → esphome-2024.7.0.dist-info}/WHEEL +0 -0
- {esphome-2024.6.6.dist-info → esphome-2024.7.0.dist-info}/entry_points.txt +0 -0
- {esphome-2024.6.6.dist-info → esphome-2024.7.0.dist-info}/top_level.txt +0 -0
@@ -757,7 +757,7 @@ void WiFiComponent::wifi_process_event_(IDFWiFiEvent *data) {
|
|
757
757
|
|
758
758
|
WiFiSTAConnectStatus WiFiComponent::wifi_sta_connect_status_() {
|
759
759
|
if (s_sta_connected && this->got_ipv4_address_) {
|
760
|
-
#if USE_NETWORK_IPV6
|
760
|
+
#if USE_NETWORK_IPV6 && (USE_NETWORK_MIN_IPV6_ADDR_COUNT > 0)
|
761
761
|
if (this->num_ipv6_addresses_ >= USE_NETWORK_MIN_IPV6_ADDR_COUNT) {
|
762
762
|
return WiFiSTAConnectStatus::CONNECTED;
|
763
763
|
}
|
@@ -141,13 +141,29 @@ bool WiFiComponent::wifi_scan_start_(bool passive) {
|
|
141
141
|
|
142
142
|
#ifdef USE_WIFI_AP
|
143
143
|
bool WiFiComponent::wifi_ap_ip_config_(optional<ManualIP> manual_ip) {
|
144
|
-
|
145
|
-
|
144
|
+
esphome::network::IPAddress ip_address, gateway, subnet, dns;
|
145
|
+
if (manual_ip.has_value()) {
|
146
|
+
ip_address = manual_ip->static_ip;
|
147
|
+
gateway = manual_ip->gateway;
|
148
|
+
subnet = manual_ip->subnet;
|
149
|
+
dns = manual_ip->static_ip;
|
150
|
+
} else {
|
151
|
+
ip_address = network::IPAddress(192, 168, 4, 1);
|
152
|
+
gateway = network::IPAddress(192, 168, 4, 1);
|
153
|
+
subnet = network::IPAddress(255, 255, 255, 0);
|
154
|
+
dns = network::IPAddress(192, 168, 4, 1);
|
155
|
+
}
|
156
|
+
WiFi.config(ip_address, dns, gateway, subnet);
|
157
|
+
return true;
|
146
158
|
}
|
147
159
|
|
148
160
|
bool WiFiComponent::wifi_start_ap_(const WiFiAP &ap) {
|
149
161
|
if (!this->wifi_mode_({}, true))
|
150
162
|
return false;
|
163
|
+
if (!this->wifi_ap_ip_config_(ap.get_manual_ip())) {
|
164
|
+
ESP_LOGV(TAG, "wifi_ap_ip_config_ failed!");
|
165
|
+
return false;
|
166
|
+
}
|
151
167
|
|
152
168
|
WiFi.beginAP(ap.get_ssid().c_str(), ap.get_password().c_str(), ap.get_channel().value_or(1));
|
153
169
|
|
@@ -132,7 +132,7 @@ async def to_code(config):
|
|
132
132
|
# the '+1' modifier is relative to the device's own address that will
|
133
133
|
# be automatically added to the provided list.
|
134
134
|
cg.add_build_flag(f"-DCONFIG_WIREGUARD_MAX_SRC_IPS={len(allowed_ips) + 1}")
|
135
|
-
cg.add_library("droscy/esp_wireguard", "0.4.
|
135
|
+
cg.add_library("droscy/esp_wireguard", "0.4.2")
|
136
136
|
|
137
137
|
await cg.register_component(var, config)
|
138
138
|
|
esphome/components/x9c/output.py
CHANGED
@@ -27,7 +27,13 @@ CONFIG_SCHEMA = cv.All(
|
|
27
27
|
cv.Optional(CONF_INITIAL_VALUE, default=1.0): cv.float_range(
|
28
28
|
min=0.01, max=1.0
|
29
29
|
),
|
30
|
-
cv.Optional(CONF_STEP_DELAY, default=
|
30
|
+
cv.Optional(CONF_STEP_DELAY, default="1us"): cv.All(
|
31
|
+
cv.positive_time_period_microseconds,
|
32
|
+
cv.Range(
|
33
|
+
min=cv.TimePeriod(microseconds=1),
|
34
|
+
max=cv.TimePeriod(microseconds=100),
|
35
|
+
),
|
36
|
+
),
|
31
37
|
}
|
32
38
|
)
|
33
39
|
)
|
esphome/const.py
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
"""Constants used by esphome."""
|
2
2
|
|
3
|
-
__version__ = "2024.
|
3
|
+
__version__ = "2024.7.0"
|
4
4
|
|
5
5
|
ALLOWED_NAME_CHARS = "abcdefghijklmnopqrstuvwxyz0123456789-_"
|
6
6
|
VALID_SUBSTITUTIONS_CHARACTERS = (
|
@@ -1072,6 +1072,7 @@ DEVICE_CLASS_BUTTON = "button"
|
|
1072
1072
|
DEVICE_CLASS_CARBON_DIOXIDE = "carbon_dioxide"
|
1073
1073
|
DEVICE_CLASS_CARBON_MONOXIDE = "carbon_monoxide"
|
1074
1074
|
DEVICE_CLASS_COLD = "cold"
|
1075
|
+
DEVICE_CLASS_CONDUCTIVITY = "conductivity"
|
1075
1076
|
DEVICE_CLASS_CONNECTIVITY = "connectivity"
|
1076
1077
|
DEVICE_CLASS_CURRENT = "current"
|
1077
1078
|
DEVICE_CLASS_CURTAIN = "curtain"
|
esphome/core/defines.h
CHANGED
esphome/core/helpers.cpp
CHANGED
@@ -78,7 +78,7 @@ static const uint16_t CRC16_1021_BE_LUT_H[] = {0x0000, 0x1231, 0x2462, 0x3653, 0
|
|
78
78
|
|
79
79
|
// STL backports
|
80
80
|
|
81
|
-
#if _GLIBCXX_RELEASE <
|
81
|
+
#if _GLIBCXX_RELEASE < 8
|
82
82
|
std::string to_string(int value) { return str_snprintf("%d", 32, value); } // NOLINT
|
83
83
|
std::string to_string(long value) { return str_snprintf("%ld", 32, value); } // NOLINT
|
84
84
|
std::string to_string(long long value) { return str_snprintf("%lld", 32, value); } // NOLINT
|
@@ -93,7 +93,7 @@ std::string to_string(long double value) { return str_snprintf("%Lf", 32, value)
|
|
93
93
|
// Mathematics
|
94
94
|
|
95
95
|
float lerp(float completion, float start, float end) { return start + (end - start) * completion; }
|
96
|
-
uint8_t crc8(uint8_t *data, uint8_t len) {
|
96
|
+
uint8_t crc8(const uint8_t *data, uint8_t len) {
|
97
97
|
uint8_t crc = 0;
|
98
98
|
|
99
99
|
while ((len--) != 0u) {
|
esphome/core/helpers.h
CHANGED
@@ -155,7 +155,7 @@ template<typename T, typename U> T remap(U value, U min, U max, T min_out, T max
|
|
155
155
|
}
|
156
156
|
|
157
157
|
/// Calculate a CRC-8 checksum of \p data with size \p len.
|
158
|
-
uint8_t crc8(uint8_t *data, uint8_t len);
|
158
|
+
uint8_t crc8(const uint8_t *data, uint8_t len);
|
159
159
|
|
160
160
|
/// Calculate a CRC-16 checksum of \p data with size \p len.
|
161
161
|
uint16_t crc16(const uint8_t *data, uint16_t len, uint16_t crc = 0xffff, uint16_t reverse_poly = 0xa001,
|
esphome/external_files.py
CHANGED
@@ -7,6 +7,7 @@ from datetime import datetime
|
|
7
7
|
import requests
|
8
8
|
import esphome.config_validation as cv
|
9
9
|
from esphome.core import CORE, TimePeriodSeconds
|
10
|
+
from esphome.const import __version__
|
10
11
|
|
11
12
|
_LOGGER = logging.getLogger(__name__)
|
12
13
|
CODEOWNERS = ["@landonr"]
|
@@ -75,3 +76,28 @@ def compute_local_file_dir(domain: str) -> Path:
|
|
75
76
|
base_directory.mkdir(parents=True, exist_ok=True)
|
76
77
|
|
77
78
|
return base_directory
|
79
|
+
|
80
|
+
|
81
|
+
def download_content(url: str, path: Path, timeout=NETWORK_TIMEOUT) -> None:
|
82
|
+
if not has_remote_file_changed(url, path):
|
83
|
+
_LOGGER.debug("Remote file has not changed %s", url)
|
84
|
+
return
|
85
|
+
|
86
|
+
_LOGGER.debug(
|
87
|
+
"Remote file has changed, downloading from %s to %s",
|
88
|
+
url,
|
89
|
+
path,
|
90
|
+
)
|
91
|
+
|
92
|
+
try:
|
93
|
+
req = requests.get(
|
94
|
+
url,
|
95
|
+
timeout=timeout,
|
96
|
+
headers={"User-agent": f"ESPHome/{__version__} (https://esphome.io)"},
|
97
|
+
)
|
98
|
+
req.raise_for_status()
|
99
|
+
except requests.exceptions.RequestException as e:
|
100
|
+
raise cv.Invalid(f"Could not download from {url}: {e}")
|
101
|
+
|
102
|
+
path.parent.mkdir(parents=True, exist_ok=True)
|
103
|
+
path.write_bytes(req.content)
|