Files
qtalker---/firmware/esp32p4-sensor-node/main/CMakeLists.txt
Indiana f09e077199 firmware: add I2S MEMS microphone driver; fix missing essence migration
Mic: confirmed via its pinout (L/R, WS, SCK, SD, VCC, GND) that the third
target module is a standard I2S digital MEMS mic (INMP441-family). Added
mems_mic.c/h using ESP-IDF's current driver/i2s_std.h API — reports RMS
audio level in dBFS as sensor_type "evp" rather than attempting on-device
voice-band FFT (the browser EVP mode's approach); the backend's existing
statistical anomaly detector handles spike detection from the raw level,
same as it already does for temperature/pressure/presence.

Also fixes a real gap Workstream B's report flagged: User.essence (a live
model column used throughout merged code — /auth/me, inventory purchases,
summon trickle) had no migration line in main.py's lifespan, which would
have broken on the actual production Postgres database.
2026-07-24 21:52:03 +00:00

40 lines
1.3 KiB
CMake

# Quantumancy sensor node — main component.
#
# device_config.h is intentionally NOT listed as a source: it's a header the
# seeker generates locally (see device_config.h.example + README.md) and is
# gitignored. If it's missing, the build will fail on the #include in
# app_main.c with a clear "file not found" — that's deliberate, it's the
# signal to go copy the example file and fill it in.
idf_component_register(
SRCS
"app_main.c"
"wifi_manager.c"
"telemetry_client.c"
"sensor_registry.c"
"bmp280.c"
"rd03e.c"
"mems_mic.c"
INCLUDE_DIRS
"."
REQUIRES
esp_wifi
esp_netif
esp_event
nvs_flash
esp_http_client
driver
json
esp_timer
log
)
# Note (unverified): recent ESP-IDF versions (v5.3+) split the old
# monolithic "driver" component into per-peripheral components
# (esp_driver_i2c, esp_driver_uart, esp_driver_i2s, ...); "driver" is kept
# as a backward-compatible umbrella that still pulls those in, which is why
# a plain REQUIRES driver is used above. If a real build against your exact
# IDF version complains it can't find driver/i2c_master.h, driver/uart.h,
# or driver/i2s_std.h, add esp_driver_i2c / esp_driver_uart / esp_driver_i2s
# explicitly to REQUIRES.