Highlights
- Published the SDK as the
francescopace/espectrecomponent on the ESP Component Registry. - Added ESP-IDF 6.x support to the SDK, alongside 5.5.3 and later.
- Added the Home Assistant Traffic Generator add-on (#168).
- Improved device discovery and sensing recovery after Wi-Fi roaming.
Added
- ESP-IDF 6.x support in the SDK. Official firmware stays on 5.5.5; see SDK.md.
- Registry packages with a Wi-Fi sensing example, validated by consumer builds before and after publication.
- The SDK API reference on the website, covering every public type.
- The Traffic Generator add-on for 64-bit Home Assistant OS, with an Ingress panel for traffic control and live diagnostics, including ESPHome devices (#168).
- Generator Rate and Traffic RX Rate sensors in Home Assistant (#182).
- Warnings when a runtime loop iteration or a traffic generator send stalls for 100 ms or more, naming the slow steps.
- An NM-CYD-C5 ESPHome example with a touch display, contributed by @RockBase-iot (#166).
BaseDetectorcalibration hookson_startup_calibration_abandoned(),startup_calibration_conclusive(), andcalibration_motion_ceiling(). Defaults keep the previous behavior.RuntimeConfig::persist_runtime_overrides: set it to false when your firmware owns configuration, so live control changes are neither restored nor saved.
Changed
- Breaking: Official ESPHome images use MAC-suffixed hostnames such as
espectre-a1b2c3.local. After the first update, use the new hostname for OTA and update dashboard entity IDs (#179). - Breaking: The SDK exports only its root include directory; use layer-prefixed includes such as
#include "runtime/runtime_config.h". - Breaking:
IEspectreRuntimeis internal.RuntimeConfigandWifiBandPolicymoved toruntime/runtime_config.h, which replacesruntime/runtime_interface.h. - Breaking:
espectre_sdk.hno longer includes the ESPectre Protocol; includeespectre_protocol_sdk.h. Diagnostic JSON helpers moved toruntime/runtime_diagnostics_protocol.h, and diagnostic profiles have named constants. - Breaking:
RuntimeDiagnosticsSnapshotgroups its fields aslink,traffic,csi,platform, andperformance, for examplecsi.accepted_total. Wire names are unchanged. - Breaking: Renamed SDK symbols so each name says what it controls, such as
TrafficGeneratorMode,RuntimeConfig::threshold, andset_threshold(). Wire names, ESPHome YAML keys, and saved settings are unchanged. - Breaking:
traffic_generator_mode: externalreplacescsi_traffic_modein the protocol, ESPHome YAML, Kconfig, and the SDK. The Home Assistant "CSI Traffic Ownership" select is gone; "CSI Traffic Source" gainsexternal. Saved settings migrate; update clients and firmware together. - Breaking:
kNativeLoopPriorityleft the SDK; the Native frontend defines its own. - Breaking: Removed unused SDK API, including
parse_json_array_objects(), twoRawCsiStopReasonvalues, andRawCsiPacketView::wifi_rx_start_ts_ns.publish_frontend_mqtt_message()drops itsconfigargument. - Breaking:
wifi_band_policydefaults toAUTOon every target. A hand-builtRuntimeConfig{}on ESP32-C5 now selects the band automatically. - Traffic diagnostics report internal generation (
generator_pps) and station traffic (traffic_tx_pps,traffic_rx_pps) separately, so the generator rate reads zero when no generator runs (#182). - The SDK requires MQTT and mDNS only when enabled, and no longer requires the HTTP server.
- ESPHome devices no longer run periodic roaming scans, which took the radio off-channel for up to 12 seconds every 5 minutes.
update_sensingreturnsunsupportedfor a threshold the device cannot change.- CLI discovery waits six seconds by default and asks devices to reply directly.
- One
cd.ymlworkflow publishes releases to the production registry andmainanddevelopsnapshots to the staging registry (#178).
Fixed
- Fixed runtime loop stalls from taking the lwIP core lock and from stopping the traffic generator. Firmware that drives
TrafficGeneratorManagerorCsiTrafficServicedirectly must keep callingloop()afterstop(). - Fixed sensing not resuming after roaming with a retained IPv4 address, and startup waiting on a Wi-Fi scan.
- Fixed CSI staying silent on S3 and C5 after switching from
wifi_rawto another traffic source. - Fixed Lightweight calibration: movement no longer pushes the threshold close to 1.0, and quiet rooms no longer drive it to about 0.01. It now stays between 0.095 and 0.987.
- Fixed MOTION and availability flickering during brief CSI coverage dips.
- Fixed
update_sensingapplying some fields before rejecting another. Custom frontends should pass the new optional validator toFrontendCommandEngine::execute(). - Fixed a failed startup calibration dropping the active detector, an unchanged detector losing its threshold, and
shutdown()leaving availability ready. - Fixed
espectre collectignoring its own startup calibration. - Fixed mDNS replies to common query types and browser discovery running out of HTTP connections. See DISCOVERY.md.
- Fixed Native rebooting while checking for OTA updates.
- Fixed
matter qrandmonitor --resetleaving the device in the firmware loader, and Matter reporting its version asunknown. - Fixed standalone Wi-Fi leaking resources, truncating full-length credentials, and giving up on reconnection.
- Fixed source-list builds of the Direct sources missing the mDNS link wrapper; use
ESPECTRE_RUNTIME_ESP_IDF_DIRECT_LINK_OPTIONS. - Fixed the WiFi Channel sensor showing decimals (#181).
Removed
- Breaking: Removed the
traffic_packets_totaldiagnostic; useget_generator_packets_total()orget_packets_received()(#182). - Breaking: Removed
initialize_primary_console(); integrations set up their own console. - Breaking: Removed
wifi_tx_rate.hfrom the services facade; callapply_station_tx_rate()fromnetwork_traffic.h. - Breaking: Removed
ESPECTRE_CORE_INCLUDE_DIRSandESPECTRE_RUNTIME_INCLUDE_DIRS. - Breaking: Removed CSI V7 binary record support. Existing NPZ datasets still load.
- Breaking: Removed
RuntimeProfileand its helpers; settraffic_generator_modeinstead. - Breaking: Removed
RuntimeSubcarrierSourceand the subcarrier snapshot fields; readRuntimeFrontendController::subcarriers(). - Breaking: Removed
csi_traffic_modehelpers,make_runtime_sensing_config(), andvisit_runtime_diagnostics(). Thevalidate_runtime_*()helpers are now internal. - Breaking: Removed the unused raw stream command path, including the last
FrontendCommandEngine::execute()argument. Raw CSI collection opens withGET /csi. - Breaking: Removed
handle_device_config_command()and its types; useparse_espectre_config_command()andparse_espectre_mqtt_config_command(). - Breaking: Removed
ESPECTRE_DIRECT_MAX_REQUEST_ID_SIZEandESPECTRE_DIRECT_MAX_METHOD_SIZE; useESPECTRE_COMMAND_ID_MAX_LENGTH. - Breaking: Removed
BaseDetector::packet_index_; readtotal_packets_.
SDK source migration
Updating C++ code from rc2 is a compile-and-replace pass. Behavior changes only where noted. The external traffic setting also changes on the wire, in Kconfig, and in ESPHome YAML; saved settings migrate on their own.
| rc2 | rc3 |
|---|---|
#include "runtime/runtime_interface.h"
| #include "runtime/runtime_config.h"
|
IEspectreRuntime
| Internal; use RuntimeFrontendController
|
Protocol, JSON, and transport contracts from espectre_sdk.h
| #include "espectre_protocol_sdk.h"; the services and MQTT headers include it
|
Diagnostic JSON and field helpers in runtime/runtime_diagnostics.h
| runtime/runtime_diagnostics_protocol.h
|
Profile masks 1U, 2U, 4U, 7U
| ESPECTRE_DIAGNOSTIC_PROFILE_NATIVE, _BRIDGE, _MICRO, _ALL
|
CsiTrafficMode, config.csi_traffic_mode = EXTERNAL
| config.traffic_generator_mode = TrafficGeneratorMode::EXTERNAL
|
RuntimeTrafficMode
| TrafficGeneratorMode
|
config.csi_capture_profile
| config.csi_capture_policy
|
config.segmentation_threshold
| config.threshold
|
config.segmentation_window_size_ms
| config.window_size_ms
|
RUNTIME_SEGMENTATION_THRESHOLD_DEFAULT
| RUNTIME_THRESHOLD_DEFAULT
|
RUNTIME_SEGMENTATION_WINDOW_SIZE_MS_*
| RUNTIME_WINDOW_SIZE_MS_*
|
set_threshold_runtime(), set_motion_hits_runtime(), set_detection_algorithm_runtime()
| set_threshold(), set_motion_hits(), set_detection_algorithm()
|
set_csi_traffic_mode_runtime(EXTERNAL)
| set_traffic_generator_mode(TrafficGeneratorMode::EXTERNAL)
|
set_traffic_generator_mode_runtime()
| set_traffic_generator_mode()
|
traffic_mode_name(), parse_traffic_mode()
| traffic_generator_mode_name(), parse_traffic_generator_mode()
|
runtime_traffic_mode_valid(), runtime_traffic_mode_supported()
| runtime_traffic_generator_mode_valid(), runtime_traffic_generator_mode_supported()
|
csi_traffic_mode_name(), parse_csi_traffic_mode(), runtime_csi_traffic_mode_valid(), csi_traffic_mode_is_sensing_control()
| Removed; traffic_generator_mode_name() returns external
|
csi_traffic_mode: (ESPHome YAML), CONFIG_ESPECTRE_CSI_TRAFFIC_MODE_EXTERNAL, csi_traffic_mode (protocol)
| traffic_generator_mode: external, CONFIG_ESPECTRE_TRAFFIC_GENERATOR_MODE_EXTERNAL, traffic_generator_mode: "external"
|
make_runtime_sensing_config()
| RuntimeConfig{}
|
snapshot.fixed_subcarriers
| controller.subcarriers()
|
diagnostics.csi_accepted_total, diagnostics.wifi_rssi_dbm
| diagnostics.csi.accepted_total, diagnostics.link.rssi_dbm; see the grouping entry above
|
on_periodic_update(snapshot, packets_received)
| on_periodic_update(snapshot, csi_accepted); same signature
|
RuntimeProfile, RuntimeSubcarrierSource, visit_runtime_diagnostics()
| Removed |
FrontendCommandEngine::execute(..., raw_stream_callback)
| Drop the last argument; raw CSI collection opens with GET /csi
|
handle_device_config_command()
| parse_espectre_config_command(), parse_espectre_mqtt_config_command()
|
ESPECTRE_DIRECT_MAX_REQUEST_ID_SIZE
| ESPECTRE_COMMAND_ID_MAX_LENGTH
|
ESPECTRE_DIRECT_MAX_METHOD_SIZE
| Removed; command names use the canonical registry |
BaseDetector::packet_index_
| total_packets_
|
Two behavior changes need a decision:
- A hand-built
RuntimeConfig{}on ESP32-C5 now usesAUTOband selection. Setwifi_band_policy = WifiBandPolicy::BAND_2Gto keep 2.4 GHz. - If your firmware owns configuration, set
persist_runtime_overrides = falseso saved controls no longer override it.