Refactor: wifi_mgr, net_influx und sen5x_app als eigene Komponenten platziert

This commit is contained in:
eugen
2026-01-29 15:20:33 +01:00
parent ac7d26eb9c
commit 7a163ec85f
10 changed files with 33 additions and 3 deletions
@@ -0,0 +1,31 @@
#pragma once
#ifdef __cplusplus
extern "C" {
#endif
// Initialisiert NVS, Netif, Eventloop, Wi-Fi, registriert Event-Handler und legt den AP-Auto-Off-Timer an.
void wifi_mgr_init(void);
// Startet AP+STA, HTTP-Server und DNS-Server, und stößt ggf. eine STA-Verbindung an.
void wifi_mgr_start(void);
// vorhandene Funktionen, die du schon hattest
bool wifi_mgr_load_sta_creds(char **out_ssid, char **out_pass);
void wifi_mgr_save_sta_creds_and_reconnect(const char* ssid, const char* pass);
void wifi_mgr_save_device_info(const char* devicename,
const char* token,
const char* bucket,
const char* org);
// NEU: Getter für main.c
EventGroupHandle_t wifi_mgr_get_event_group(void);
EventBits_t wifi_mgr_evt_sta_got_ip(void);
EventBits_t wifi_mgr_evt_sta_fail(void);
esp_netif_t *wifi_mgr_get_ap_netif(void);
#ifdef __cplusplus
}
#endif