wifi-densepose/firmware/esp32-csi-node/main
ruv 7994af8221 feat(firmware): wire temporal_task.c + Kconfig + ruv_temporal component (Phase 6, #513)
Phase 6 of #513: C-side wiring for the on-device temporal head. Builds
cleanly with feature OFF (default); 8MB binary delta is +96 bytes vs
v0.6.4-esp32 — that's the no-op shim path. Feature ON depends on the
Rust component (Phase 5, currently blocked by upstream esp-rs nightly).

Files:

- main/temporal_task.{c,h} — owns the FreeRTOS task lifecycle. Per
  ADR-095 §3.3 the task has its own 16 KB stack pinned to Core 1 and
  is fed via a 32-deep FreeRTOS queue. With feature OFF the .c file
  collapses to three ESP_ERR_NOT_SUPPORTED stubs so callers don't
  need #ifdefs at every call site.
- main/temporal_task.h — defines rv_temporal_pkt_t (40 bytes,
  magic 0xC5110007 — next free in the existing 0xC5110001..0006
  family) and the task lifecycle API. Build-time _Static_assert
  pins the wire format.
- main/Kconfig.projbuild — new menu "On-device temporal head
  (ADR-095, #513)" with CONFIG_CSI_TEMPORAL_HEAD_ENABLED (default n)
  plus four runtime-tuneable knobs: TEMPORAL_INPUT_DIM (16),
  TEMPORAL_WINDOW_LEN (256), TEMPORAL_N_CLASSES (4), and
  TEMPORAL_CLASSIFY_PERIOD_MS (1000).
- main/CMakeLists.txt — adds temporal_task.c to SRCS unconditionally
  (the .c file feature-gates internally), and adds ruv_temporal to
  REQUIRES only when the feature is enabled so default builds don't
  pull in the Rust component.
- main/adaptive_controller.c — fast_loop_cb now extracts the 9
  feature floats from the pkt it just built and pushes them into
  temporal_task_push_frame after the existing stream_sender_send.
  Non-blocking; queue-full drops are coalesced and logged 1/sec.
- main/main.c — temporal_task_start() called right after
  adaptive_controller_init(). Wrapped in #ifdef so feature-off
  builds don't reference the (no-op-anyway) function.
- components/ruv_temporal/CMakeLists.txt — restructured. Top-level
  Kconfig guard registers an empty component when the feature is
  off (avoids running cargo without a working toolchain).
  add_custom_command moved AFTER idf_component_register so it
  doesn't fire in script mode (required by ESP-IDF v5.4).

Validation:
- Firmware builds clean with default config (feature OFF) on
  ESP-IDF v5.4 / esp32s3 target. Binary 1062 KiB / 2 MiB partition,
  48 % free.
- Static assertion catches wire-format drift (rv_temporal_pkt_t size).
- Host-side `cargo test -p wifi-densepose-temporal` still 5/5 from
  the earlier commit (no regression, this commit only touches
  firmware/).

Phase 7 (flash to COM8 + soak) deferred this iteration — board is
currently not enumerating on COM8; will pick up next iteration when
the ESP32 is reattached.

Co-Authored-By: claude-flow <ruv@ruv.net>
2026-05-08 11:28:11 -04:00
..
CMakeLists.txt feat(firmware): wire temporal_task.c + Kconfig + ruv_temporal component (Phase 6, #513) 2026-05-08 11:28:11 -04:00
Kconfig.projbuild feat(firmware): wire temporal_task.c + Kconfig + ruv_temporal component (Phase 6, #513) 2026-05-08 11:28:11 -04:00
adaptive_controller.c feat(firmware): wire temporal_task.c + Kconfig + ruv_temporal component (Phase 6, #513) 2026-05-08 11:28:11 -04:00
adaptive_controller.h ADR-081: Implement 5-layer adaptive CSI mesh firmware kernel (#404) 2026-04-20 10:38:23 -04:00
adaptive_controller_decide.c ADR-081: Implement 5-layer adaptive CSI mesh firmware kernel (#404) 2026-04-20 10:38:23 -04:00
csi_collector.c fix(firmware): SPI cache crash fix + node_id/filter_mac defensive copies + esptool v5 (rebased #397) 2026-04-28 08:41:49 -04:00
csi_collector.h fix(firmware): SPI cache crash fix + node_id/filter_mac defensive copies + esptool v5 (rebased #397) 2026-04-28 08:41:49 -04:00
display_hal.c docs: update README with ADR-045–048, Observatory, adaptive classifier, AMOLED display 2026-03-05 10:20:48 -05:00
display_hal.h docs: update README with ADR-045–048, Observatory, adaptive classifier, AMOLED display 2026-03-05 10:20:48 -05:00
display_task.c fix: remove unsafe exec() in display_task.c 2026-03-26 04:08:00 +00:00
display_task.h docs: update README with ADR-045–048, Observatory, adaptive classifier, AMOLED display 2026-03-05 10:20:48 -05:00
display_ui.c fix(firmware): defensive node_id capture prevents runtime clobber (#390) 2026-04-15 13:47:34 -04:00
display_ui.h docs: update README with ADR-045–048, Observatory, adaptive classifier, AMOLED display 2026-03-05 10:20:48 -05:00
edge_processing.c fix(firmware): SPI cache crash fix + node_id/filter_mac defensive copies + esptool v5 (rebased #397) 2026-04-28 08:41:49 -04:00
edge_processing.h feat: ADR-069 ESP32 CSI → Cognitum Seed RVF pipeline (v0.5.4-esp32) 2026-04-02 19:32:18 -04:00
idf_component.yml docs: update README with ADR-045–048, Observatory, adaptive classifier, AMOLED display 2026-03-05 10:20:48 -05:00
lv_conf.h docs: update README with ADR-045–048, Observatory, adaptive classifier, AMOLED display 2026-03-05 10:20:48 -05:00
main.c feat(firmware): wire temporal_task.c + Kconfig + ruv_temporal component (Phase 6, #513) 2026-05-08 11:28:11 -04:00
mmwave_sensor.c feat: ADR-063/064 mmWave sensor fusion + multimodal ambient intelligence (#269) 2026-03-15 16:10:10 -04:00
mmwave_sensor.h feat: ADR-063/064 mmWave sensor fusion + multimodal ambient intelligence (#269) 2026-03-15 16:10:10 -04:00
mock_csi.c feat: QEMU ESP32-S3 testing platform + swarm configurator (ADR-061/062) (#260) 2026-03-14 13:39:51 -04:00
mock_csi.h feat: QEMU ESP32-S3 testing platform + swarm configurator (ADR-061/062) (#260) 2026-03-14 13:39:51 -04:00
nvs_config.c feat: happiness scoring pipeline + ESP32 swarm with Cognitum Seed (#285) 2026-03-20 18:46:34 -04:00
nvs_config.h feat: happiness scoring pipeline + ESP32 swarm with Cognitum Seed (#285) 2026-03-20 18:46:34 -04:00
ota_update.c fix: security hardening — replace fake HMAC, add path traversal protection, OTA auth (ADR-050) 2026-03-06 13:11:04 -05:00
ota_update.h feat: complete vendor repos, add edge intelligence and WASM modules 2026-03-02 23:53:25 -05:00
power_mgmt.c feat: complete vendor repos, add edge intelligence and WASM modules 2026-03-02 23:53:25 -05:00
power_mgmt.h feat: complete vendor repos, add edge intelligence and WASM modules 2026-03-02 23:53:25 -05:00
rv_feature_state.c ADR-081: Implement 5-layer adaptive CSI mesh firmware kernel (#404) 2026-04-20 10:38:23 -04:00
rv_feature_state.h ADR-081: Implement 5-layer adaptive CSI mesh firmware kernel (#404) 2026-04-20 10:38:23 -04:00
rv_mesh.c ADR-081: Implement 5-layer adaptive CSI mesh firmware kernel (#404) 2026-04-20 10:38:23 -04:00
rv_mesh.h ADR-081: Implement 5-layer adaptive CSI mesh firmware kernel (#404) 2026-04-20 10:38:23 -04:00
rv_radio_ops.h ADR-081: Implement 5-layer adaptive CSI mesh firmware kernel (#404) 2026-04-20 10:38:23 -04:00
rv_radio_ops_esp32.c ADR-081: Implement 5-layer adaptive CSI mesh firmware kernel (#404) 2026-04-20 10:38:23 -04:00
rv_radio_ops_mock.c ADR-081: Implement 5-layer adaptive CSI mesh firmware kernel (#404) 2026-04-20 10:38:23 -04:00
rvf_parser.c feat: complete vendor repos, add edge intelligence and WASM modules 2026-03-02 23:53:25 -05:00
rvf_parser.h feat: complete vendor repos, add edge intelligence and WASM modules 2026-03-02 23:53:25 -05:00
stream_sender.c fix: rate-limit CSI sends and add ENOMEM backoff to prevent crash (#132) 2026-03-03 16:00:40 -05:00
stream_sender.h fix(docker): Update Dockerfile paths from src/ to v1/src/ 2026-02-28 13:38:21 -05:00
swarm_bridge.c feat: happiness scoring pipeline + ESP32 swarm with Cognitum Seed (#285) 2026-03-20 18:46:34 -04:00
swarm_bridge.h feat: happiness scoring pipeline + ESP32 swarm with Cognitum Seed (#285) 2026-03-20 18:46:34 -04:00
temporal_task.c feat(firmware): wire temporal_task.c + Kconfig + ruv_temporal component (Phase 6, #513) 2026-05-08 11:28:11 -04:00
temporal_task.h feat(firmware): wire temporal_task.c + Kconfig + ruv_temporal component (Phase 6, #513) 2026-05-08 11:28:11 -04:00
wasm_runtime.c fix(firmware): defensive node_id capture prevents runtime clobber (#390) 2026-04-15 13:47:34 -04:00
wasm_runtime.h feat: complete vendor repos, add edge intelligence and WASM modules 2026-03-02 23:53:25 -05:00
wasm_upload.c fix: security hardening — replace fake HMAC, add path traversal protection, OTA auth (ADR-050) 2026-03-06 13:11:04 -05:00
wasm_upload.h feat: complete vendor repos, add edge intelligence and WASM modules 2026-03-02 23:53:25 -05:00