24 lines
671 B
C
24 lines
671 B
C
#pragma once
|
|
#include <stdbool.h>
|
|
#include <stdint.h>
|
|
#include "esp_err.h"
|
|
#include "detector.h"
|
|
#include "feature_params.h"
|
|
|
|
typedef struct {
|
|
uint32_t frames;
|
|
uint32_t proc_avg_us; // exponential moving average of features+match time
|
|
uint32_t proc_max_us;
|
|
float last_rms, last_score;
|
|
bool last_match;
|
|
det_state_t state;
|
|
uint32_t triggers;
|
|
uint32_t last_trigger_s; // uptime seconds of the last trigger, 0 = never
|
|
} proc_stats_t;
|
|
|
|
esp_err_t processing_start(void);
|
|
void processing_get_stats(proc_stats_t *out);
|
|
void processing_get_last_fp(float fp[NUM_BANDS]);
|
|
void processing_set_monitor(bool on);
|
|
bool processing_get_monitor(void);
|