Refactor: wifi_mgr, net_influx und sen5x_app als eigene Komponenten platziert
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
#pragma once
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
#include "esp_err.h"
|
||||
|
||||
// Schlanke I2C/HAL-Konfiguration (wie zuvor genutzt)
|
||||
typedef struct {
|
||||
uint8_t addr; // 7-bit I2C-Adresse (0x69)
|
||||
int port; // I2C Port (0)
|
||||
int sda; // GPIO SDA
|
||||
int scl; // GPIO SCL
|
||||
bool sda_pullup; // interne Pullups
|
||||
bool scl_pullup; // interne Pullups
|
||||
uint32_t freq; // I2C Takt (Hz, z.B. 400000)
|
||||
} sen5x_i2c_cfg_t;
|
||||
|
||||
// Initialisiert I2C/Treiber/HAL und startet die Messung
|
||||
esp_err_t sen5x_app_init(const sen5x_i2c_cfg_t* cfg);
|
||||
|
||||
// Endlosschleife (Pollt "data ready" und loggt Messwerte); als FreeRTOS-Task nutzbar
|
||||
void sen5x_app_task(void* arg);
|
||||
|
||||
// Stoppt Messung & gibt Ressourcen frei (optional aufzurufen z.B. bei Shutdown)
|
||||
void sen5x_app_deinit(void);
|
||||
Reference in New Issue
Block a user