J. Nick Koston
bca46bce81
Merge remote-tracking branch 'upstream/dev' into cache-lwip-sock-pointers
...
# Conflicts:
# esphome/components/socket/bsd_sockets_impl.cpp
# esphome/components/socket/bsd_sockets_impl.h
# esphome/components/socket/lwip_sockets_impl.cpp
# esphome/components/socket/lwip_sockets_impl.h
# esphome/components/socket/socket.cpp
# esphome/components/socket/socket.h
# esphome/core/application.h
2026-03-02 07:11:40 -10:00
J. Nick Koston
a1d91ac779
[core] Compile-time detection of loop() overrides ( #14405 )
2026-03-02 06:59:23 -10:00
J. Nick Koston
585e195044
[socket] Devirtualize socket abstraction layer ( #14398 )
2026-03-02 06:58:31 -10:00
J. Nick Koston
39572d9628
[light] Resolve effect names to indices at codegen time ( #14265 )
2026-03-02 06:58:15 -10:00
J. Nick Koston
f278250740
[core] Deduplicate ControllerRegistry notify dispatch loop ( #14394 )
2026-03-02 06:57:59 -10:00
J. Nick Koston and Claude Opus 4.6
54f410901f
[web_server] Avoid temporary std::string allocations in request parameter parsing ( #14366 )
...
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com >
2026-03-02 06:57:39 -10:00
J. Nick Koston and Claude Opus 4.6
00242443e1
[light] Replace powf gamma with pre-computed lookup tables (LUT) ( #14123 )
...
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com >
2026-03-02 06:57:23 -10:00
J. Nick Koston
82da4935b6
[core] Auto-wrap static strings in PROGMEM on ESP8266 via TemplatableValue ( #13885 )
2026-03-02 06:57:08 -10:00
J. Nick Koston and Claude Opus 4.6
1c5fd8bbd4
[core] Move millis_64 rollover tracking out of Scheduler ( #14360 )
...
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com >
2026-03-02 06:56:51 -10:00
77a7cbcffd
Use cached files on network errors in external_files ( #14055 )
...
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com >
Co-authored-by: jesserockz <3060199+jesserockz@users.noreply.github.com >
2026-03-02 11:41:20 -05:00
Bonne Eggleston and J. Nick Koston
3160457ca6
Create integration tests for modbus ( #14395 )
...
Co-authored-by: J. Nick Koston <nick@home-assistant.io >
2026-03-01 22:51:27 -10:00
590ee81f7a
[openthread] Disable default enabled OT console build ( #14390 )
...
Co-authored-by: Jonathan Swoboda <154711427+swoboda1337@users.noreply.github.com >
Co-authored-by: J. Nick Koston <nick@koston.org >
2026-03-02 06:16:36 +00:00
J. Nick Koston
9d4357c619
[core] Wake main loop from ISR in enable_loop_soon_any_context() ( #14383 )
2026-03-01 18:20:14 -10:00
J. Nick Koston
80a2acca4f
[ld2410] Add UART mock integration test for LD2410 component ( #14377 )
2026-03-01 18:19:32 -10:00
J. Nick Koston
f68a3ed15d
[api] Remove virtual destructor from ProtoMessage ( #14393 )
2026-03-01 18:09:00 -10:00
schrob
6d3d8970a6
[openthread] Disable default enabled OT diag code ( #14399 )
2026-03-01 22:47:02 -05:00
073ca63f60
[rtttl] improve comments Part 2 ( #13971 )
...
Co-authored-by: Jonathan Swoboda <154711427+swoboda1337@users.noreply.github.com >
Co-authored-by: pre-commit-ci-lite[bot] <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com>
2026-03-01 22:44:02 -05:00
J. Nick Koston and Claude Opus 4.6
0e18e4461e
[time,api] Send pre-parsed timezone struct over protobuf ( #14233 )
...
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com >
2026-03-02 15:52:53 +13:00
J. Nick Koston
5bd7f0ea96
[core] Cache lwip_sock pointers to simplify fast select hot path
...
Cache struct lwip_sock* pointers at socket registration time instead of
looking them up by fd on every iteration. The previous code stored file
descriptors and called lwip_socket_dbg_get_socket(fd) on every loop
iteration to convert each fd back to a pointer — only to read a single
field from it.
- register_socket(lwip_sock*) returns bool and hooks the callback
internally — replaces the separate register_socket_fd + hook dance
- Hot loop iterates struct lwip_sock* directly instead of converting
fds each iteration
- Socket::ready() uses the cached pointer instead of fd lookup
- esphome_lwip_hook_socket() takes struct lwip_sock* directly
- esphome_lwip_socket_has_data() moved to header as static inline
for inlining — uses offset-based access verified by _Static_assert
- Null cached_sock_ on close to prevent post-close dereference
- socket_ready() tolerant of null pointer for safety
2026-03-01 16:46:58 -10:00
J. Nick Koston
3e7424b307
[preferences] Reduce heap churn with small inline buffer optimization ( #13259 )
2026-03-02 14:22:55 +13:00
J. Nick Koston
48b5cae6c4
[api] Use StringRef for user service string arguments ( #13974 )
2026-03-02 10:32:44 +13:00
J. Nick Koston
a1760a1980
[improv_serial] Add missing USE_IMPROV_SERIAL define to fix WiFi scan filtering ( #14359 )
2026-03-02 09:23:10 +13:00
J. Nick Koston
5d9c3a0e71
Fix clang-tidy: use make_unique and fix include order
...
- Replace std::unique_ptr{new ...} with make_unique
- Fix include order to satisfy clang-format
2026-03-01 00:23:05 -10:00
J. Nick Koston
529c79a8a9
Add NOLINT for redundant socket_ready_fd forward declaration
...
clang-tidy flags the forward declaration in application.h as redundant
since socket.h (included earlier via esphome.h) already declares it.
The forward declaration is needed here for the friend declaration.
2026-02-28 23:30:35 -10:00
J. Nick Koston
8cedf8f882
Restore comments from original code to minimize diff
2026-02-28 23:03:53 -10:00
J. Nick Koston
164001b50c
Revert unnecessary socket_ip_loop_monitored rename
...
Keep the original function name since all callers already use it for
listening sockets. Only the return type changes to ListenSocket.
2026-02-28 23:00:32 -10:00
J. Nick Koston
7e119b1cbd
Fix clang-tidy naming violations in lwip_raw_tcp_impl
...
- Rename internal_write/internal_output to internal_write_/internal_output_
(protected methods require trailing underscore)
- Fix getpeername/getsockname parameter name mismatch between .h and .cpp
2026-02-28 22:56:48 -10:00
J. Nick Koston
39bbdbbfce
Revert unrelated IRAM_ATTR change that leaked in from stash
2026-02-28 22:47:32 -10:00
J. Nick Koston and J. Nick Koston
7a2452b3a2
Move LWIP_LOG and inline methods from header to cpp
...
The CI lint rule disallows ESP_LOG* references in header files.
Move LWIP_LOG macro definition and all methods that use it
(destructors, init(), static callbacks) to the .cpp file.
Co-Authored-By: J. Nick Koston <nick@koston.org >
2026-02-28 22:43:24 -10:00
J. Nick Koston and J. Nick Koston
807e786fac
[socket] Devirtualize socket abstraction layer
...
Replace the virtual Socket base class with compile-time type aliases.
Since only one socket implementation is active per build (selected via
#ifdef), virtual dispatch was unnecessary overhead.
Each implementation (BSDSocketImpl, LwIPSocketImpl, LWIPRawImpl) is now
a concrete class in its own header with no virtual methods. socket::Socket
and socket::ListenSocket are type aliases to the active implementation.
For LWIP_TCP (ESP8266/RP2040), the listen socket is a separate type
(LWIPRawListenImpl) sharing a non-virtual LWIPRawCommon base with the
connected socket type (LWIPRawImpl). On BSD/LWIP_SOCKETS, both aliases
resolve to the same type.
This eliminates all vtable overhead, virtual destructors, and indirect
call overhead across all platforms.
Co-Authored-By: J. Nick Koston <nick@koston.org >
2026-02-28 22:39:25 -10:00
J. Nick Koston
19bbd39e33
[uart] Enable wake-on-RX by default on ESP32 ( #14391 )
2026-02-28 21:06:46 -06:00
J. Nick Koston and Copilot
3f97b3b706
[core] Extract set_status_flag_ helper to deduplicate status_set methods ( #14384 )
...
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com >
2026-02-28 14:27:06 -10:00
J. Nick Koston
82e620bcf5
[ld2450] Single-pass zone target counting ( #14387 )
2026-02-28 14:26:55 -10:00
J. Nick Koston
80e0761bf1
[ld2450] Use integer dedup for direction text sensor updates ( #14386 )
2026-02-28 14:26:31 -10:00
J. Nick Koston
c0781d3680
[ld2450] Use atan2f for angle calculation ( #14388 )
2026-02-28 14:26:08 -10:00
J. Nick Koston
b7cb65ec49
[ci] Fix TypeError in ci-custom.py when POST lint checks fail ( #14378 )
2026-02-28 14:23:20 -10:00
J. Nick Koston
fdbfac15db
[uart] Replace wake-on-RX task+queue with direct ISR callback ( #14382 )
2026-03-01 00:21:08 +00:00
J. Nick Koston and Copilot
28424d6acd
[ld2410][ld2412] Fix signed char causing incorrect distance values ( #14380 )
...
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com >
2026-02-28 23:50:12 +00:00
J. Nick Koston
b679b04d14
[core] Move CONF_STOP_BITS, CONF_DATA_BITS, CONF_PARITY to const.py ( #14379 )
2026-02-28 13:27:33 -10:00
Jonathan Swoboda and Copilot
b7d651dd17
[core] Defer entity automation codegen to prevent sibling ID deadlocks ( #14381 )
...
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-02-28 13:10:53 -10:00
J. Nick Koston
757e8d90e6
[core] Inline set_component_state_ and use it in Application ( #14369 )
2026-02-28 07:20:34 -10:00
J. Nick Koston
7d52a9587f
[api] Outline keepalive ping logic from APIConnection::loop() ( #14374 )
2026-02-28 07:20:20 -10:00
J. Nick Koston
067d773aac
[core] Make register_component protected, remove runtime checks ( #14371 )
2026-02-28 07:19:55 -10:00
Clyde Stubbs
089d1e55e7
[mipi_dsi] Fix Waveshare P4 7B board config ( #14372 )
2026-02-28 20:37:04 +11:00
Raymond Richmond
6c0998f220
[gt911] Support for interrupt signal via IO Expander ( #14358 )
2026-02-28 18:26:06 +11:00
J. Nick Koston and Claude Opus 4.6
49cc389bf0
[esp32] Wrap printf/vprintf/fprintf to eliminate _vfprintf_r (~11 KB flash) ( #14362 )
...
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com >
2026-02-27 17:28:05 -10:00
J. Nick Koston
8480e8df9f
[uart] Revert UART0 default pin workarounds (fixed in ESP-IDF 5.5.2) ( #14363 )
2026-02-27 17:27:51 -10:00
J. Nick Koston
e7d4f2608b
[sen6x] Fix test sensor ID collisions with sen5x ( #14367 )
2026-02-27 16:01:17 -10:00
Ryan Wagoner
d1b4813197
[web_server] Add climate preset, fan mode, and humidity support ( #14061 )
2026-02-27 14:20:13 -10:00
Jonathan Swoboda and Copilot
298ee7b92e
[gps] Fix codegen deadlock when automations reference sibling sensors ( #14365 )
...
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com >
2026-02-27 19:08:42 -05:00