Commit Graph
22763 Commits
Author SHA1 Message Date
J. Nick Koston 4e09370252 Merge remote-tracking branch 'origin/light-gamma-lut' into integration 2026-02-19 15:09:06 -06:00
J. Nick Koston ffb75eed3d Merge branch 'remove-powf-normalize-accuracy' into integration 2026-02-19 15:09:02 -06:00
J. Nick Koston 71c6a54990 [core] Fix deprecation dates for gamma_correct/gamma_uncorrect
Ships in 2026.3.0, so deprecation starts at 2026.3.0 with
6-month removal window at 2026.9.0.
2026-02-19 15:05:06 -06:00
J. Nick Koston 96f52da647 [light] Fix outdated comment on gamma_tables dict
Only the forward table is stored now; reverse gamma is computed
via binary search on the forward table.
2026-02-19 15:04:41 -06:00
J. Nick Koston 08c193d1d8 [light] Fix clang-format in gamma_table_reverse_search
Add braces to if/else in inline binary search function to
satisfy clang-format requirements.
2026-02-19 15:02:36 -06:00
J. Nick Koston a71d1c8867 [light] Replace powf gamma correction with Python-generated PROGMEM LUTs
Replace runtime powf() calls in light gamma correction with
pre-computed uint16[256] PROGMEM lookup tables generated at
Python codegen time. The gamma value is a compile-time constant,
so the tables can be computed once and shared across all lights
with the same gamma value.

This eliminates powf/ieee754_powf (~2.3KB) from the binary.
Two 512-byte PROGMEM tables (forward + reverse) are shared per
unique gamma value, for a net savings of ~1.3KB flash and zero
RAM impact.

The LUT uses linear interpolation between table entries,
achieving zero PWM errors at both 8-bit and 16-bit resolution
compared to the old powf-based approach.

Breaking change: gamma parameter removed from
LightColorValues::as_*() methods since gamma correction is now
applied externally via LightState::gamma_correct_lut().
gamma_correct() and gamma_uncorrect() in helpers.h are
deprecated (removal in 2026.12.0).
2026-02-19 14:56:10 -06:00
J. Nick Koston d2b7d40716 Clamp accuracy_decimals to -9 to prevent uint32_t overflow 2026-02-19 12:17:19 -06:00
J. Nick Koston 77ef231a3a Merge branch 'remove-powf-normalize-accuracy' into integration 2026-02-19 12:11:28 -06:00
J. Nick Koston 2bb077cb1f [core] Replace powf with integer math in normalize_accuracy_decimals
Replace powf(10.0f, accuracy_decimals) with integer divisor computation
to avoid pulling in __ieee754_powf (~2.2KB) on builds where this is
the only powf call site.

Tested on ESP8266 with web_server: -3.1KB flash, -16 bytes RAM.
2026-02-19 12:10:51 -06:00
J. Nick Koston 7ff3ac59cb Merge remote-tracking branch 'origin/dev' into integration 2026-02-19 11:48:30 -06:00
Jonathan SwobodaandClaude Opus 4.6 f2c98d6126 [safe_mode] Log brownout as reset reason on OTA rollback (#14113)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 17:45:04 +00:00
J. Nick KostonandClaude Opus 4.6 7a5c3cee0d [esp32_ble] Enable CONFIG_BT_RELEASE_IRAM on ESP32-C2 (#14109)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 17:41:00 +00:00
Jonathan SwobodaandClaude Opus 4.6 9aa17984df [pulse_counter] Fix build failure when use_pcnt is false (#14111)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 17:25:26 +00:00
Jonathan SwobodaandClaude Opus 4.6 da616e0557 [ethernet] Improve clk_mode deprecation warning with actionable YAML (#14104)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 17:00:05 +00:00
Kevin Ahrendt d2026b4cd7 [audio] Disable FLAC CRC validation to improve decoding efficiency (#14108) 2026-02-19 11:56:34 -05:00
Jonathan SwobodaandClaude Opus 4.6 ed74790eed [i2c] Remove deprecated stop parameter overloads and readv/writev methods (#14106)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 16:56:06 +00:00
Jonathan SwobodaandClaude Opus 4.6 bf2e22da4f [esp32] Remove deprecated add_idf_component() parameters and IDF component refresh option (#14105)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 16:55:03 +00:00
J. Nick Koston 04268ebe1d Merge remote-tracking branch 'swoboda1337/remove-ethernet-clk-mode-deprecated' into integration 2026-02-19 10:35:53 -06:00
J. Nick Koston fb27b8729e Merge remote-tracking branch 'origin/scheduler-reduce-defer-locks' into integration 2026-02-19 10:35:34 -06:00
Jonathan SwobodaandClaude Opus 4.6 bd50b80882 [opentherm] Remove deprecated opentherm_version config option (#14103)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 11:34:40 -05:00
Jonathan SwobodaandClaude Opus 4.6 a6b5a1e9d0 [ethernet] Improve clk_mode deprecation warning with actionable YAML
Extend the clk_mode deprecation period to 2026.7.0 and improve the
warning message to show the exact replacement YAML the user needs.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 11:32:41 -05:00
Kevin AhrendtandCopilot b11ad26c4f [audio] Support decoding audio directly from flash (#14098)
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-02-19 11:20:19 -05:00
J. Nick Koston 33bef13900 [scheduler] Reduce lock acquisitions in process_defer_queue_
Restructure the defer queue processing loop to merge lock acquisitions.
Previously each item required two separate lock/unlock pairs: one to
move the item out of the queue, and one to recycle it after execution.
This totaled 2N+1 lock acquisitions for N items.

By combining the recycle of each item with the move-out of the next
item under a single lock hold, the total drops to N+1. The callback
still executes without the lock held to prevent deadlocks.

Also adds an early return when the queue is empty to avoid taking
the lock at all in the common case (nothing deferred). The lockless
check is safe because the main loop is the single consumer of
defer_queue_front_, and a stale size() read from a concurrent push
can only cause us to see fewer items — they will be processed on
the next loop iteration.

Additionally outlines the rare defer queue compaction path into a
separate noinline compact_defer_queue_locked_() to keep cold code
out of the hot instruction cache lines.
2026-02-19 10:19:41 -06:00
J. Nick KostonandClaude Opus 4.6 f7459670d3 [core] Optimize WarnIfComponentBlockingGuard::finish() hot path (#14040)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 16:10:22 +00:00
Jonathan SwobodaandClaude Opus 4.6 5304750215 [socket] Fix IPv6 compilation error on host platform (#14101)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 16:00:34 +00:00
J. Nick Koston a8171da003 [web_server] Reduce set_json_id flash and stack usage (#14029) 2026-02-19 09:38:57 -06:00
J. Nick Koston d64b896e7c Merge remote-tracking branch 'upstream/dev' into integration 2026-02-19 09:29:07 -06:00
J. Nick Koston 916cf0d8b7 [e131] Replace std::map with std::vector for universe tracking (#14087) 2026-02-19 09:28:00 -06:00
J. Nick Koston 0484b2852d [e131] Fix E1.31 on ESP8266 and RP2040 by restoring WiFiUDP support (#14086) 2026-02-19 09:27:05 -06:00
J. Nick Koston 41cfe2f9ad Merge remote-tracking branch 'upstream/dev' into integration 2026-02-19 09:17:46 -06:00
J. Nick Koston b5a8e1c94c [ci] Update lint message to recommend constexpr over static const (#14099) 2026-02-19 09:06:46 -06:00
J. Nick Koston 8728c5c4ca Merge remote-tracking branch 'origin/optimize-warn-blocking-guard' into integration 2026-02-19 09:05:00 -06:00
J. Nick KostonandClaude Opus 4.6 a7ca97c279 Merge branch 'dev' into optimize-warn-blocking-guard
Resolve conflict in component.cpp: keep destructor removed (moved
to header as = default) and keep #ifdef USE_SETUP_PRIORITY_OVERRIDE
guard from dev.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 08:57:13 -06:00
dependabot[bot]anddependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> 01a46f665f Bump esptool from 5.1.0 to 5.2.0 (#14058)
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-19 09:42:22 -05:00
J. Nick Koston 535980b9bd [cse7761] Use constexpr for compile-time constants (#14081) 2026-02-19 08:40:41 -06:00
J. Nick Koston b0085e21f7 [core] Devirtualize call_loop() and mark_failed() in Component (#14083) 2026-02-19 08:40:23 -06:00
J. Nick Koston 6daca09794 [logger] Replace LogListener virtual interface with LogCallback struct (#14084) 2026-02-19 08:40:08 -06:00
J. Nick Koston 7b53a98950 [socket] Log error when UDP socket requested on LWIP TCP-only platforms (#14089) 2026-02-19 08:39:44 -06:00
Rodrigo Martín 4cc1e6a910 [esp32_ble_server] add test for lambda characteristic (#14091) 2026-02-19 09:23:22 -05:00
J. Nick Koston 5213aed846 Merge remote-tracking branch 'origin/e131-replace-map-with-vector' into integration 2026-02-19 00:43:03 -06:00
J. Nick Koston fe2af3793f Merge branch 'fix-e131-esp8266-udp' into integration 2026-02-19 00:42:55 -06:00
J. Nick Koston cc56194758 Merge remote-tracking branch 'origin/log-unsupported-udp-socket' into integration 2026-02-19 00:42:48 -06:00
J. Nick Koston d1d3d256a9 [socket] Log error when UDP socket requested on LWIP TCP-only platforms
The LWIP raw socket factory only supports TCP but silently ignored the
type parameter, returning a TCP socket for SOCK_DGRAM requests. This
caused components expecting UDP to fail silently with no indication of
why. Return nullptr with EPROTOTYPE and log an error instead.
2026-02-19 00:37:23 -06:00
J. Nick Koston 76fda4d4a2 [e131] Use uint16_t for consumer refcount
Struct pads to 4 bytes either way due to alignment, so this is free.
2026-02-19 00:34:20 -06:00
J. Nick Koston 1373f6866a [e131] Fix IGMP rejoin after effect stop/start cycle
When leave_() decremented consumers to 0 without removing the entry,
a subsequent join_() would find it, increment 0->1, and return early
without rejoining the IGMP multicast group. Now join_() only skips
the IGMP rejoin when consumers was already > 0.
2026-02-19 00:33:06 -06:00
J. Nick KostonandJ. Nick Koston 4bf13a8143 [e131] Replace std::map with std::vector for universe tracking
Replace std::map<int, int> with std::vector<UniverseConsumer> for
tracking universe reference counts. This eliminates red-black tree
overhead for what is typically 1-10 entries.

Co-Authored-By: J. Nick Koston <nick@koston.org>
2026-02-19 00:11:14 -06:00
J. Nick Koston fe57153938 [e131] Fix E1.31 on ESP8266 and RP2040 by restoring WiFiUDP support
The socket abstraction layer on ESP8266/RP2040 (USE_SOCKET_IMPL_LWIP_TCP)
only supports TCP. When E1.31 was migrated from WiFiUDP to sockets, it
silently broke on these platforms since SOCK_DGRAM requests get TCP sockets
that never receive UDP data.

Restore WiFiUDP as the transport on LWIP_TCP platforms while keeping the
socket-based implementation on BSD/LWIP socket platforms (ESP32, etc.).
This follows the same dual-path pattern used by the udp and wake_on_lan
components.
2026-02-19 00:02:17 -06:00
J. Nick Koston bf30cd9a7f Merge remote-tracking branch 'origin/devirtualize-call-loop-mark-failed' into integration 2026-02-18 23:09:21 -06:00
J. Nick Koston 82e58f75c1 Merge branch 'devirtualize-call-loop-mark-failed' into integration 2026-02-18 23:08:50 -06:00
J. Nick Koston 21659f61e2 Merge branch 'loglistener-to-logcallback' into integration 2026-02-18 23:08:39 -06:00