feat: add CYD ThermoPro bridge firmware skeleton
Add PlatformIO project for the ESP32-2432S028R that: - Reads ThermoPro BLE BBQ thermometers via NimBLE-Arduino - Exposes /api/health, /api/latest, and /api/settings HTTP endpoints - Serves a captive-portal setup UI and touch dashboard - Persists WiFi/BLE/settings in NVS via Preferences Builds cleanly with pio run.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
#include "SettingsManager.hpp"
|
||||
#include <ArduinoJson.h>
|
||||
#include <Preferences.h>
|
||||
#include <vector>
|
||||
|
||||
namespace cyd {
|
||||
|
||||
@@ -75,7 +76,8 @@ bool SettingsManager::load() {
|
||||
settings_.apiEndpoint = doc["apiEndpoint"] | "";
|
||||
settings_.apiToken = doc["apiToken"] | "";
|
||||
settings_.pollIntervalSec = doc["pollIntervalSec"] | 15;
|
||||
settings_.unit = doc["unit"] | "F";
|
||||
String unit = doc["unit"] | "F";
|
||||
settings_.unit = unit.length() > 0 ? unit.charAt(0) : 'F';
|
||||
settings_.deviceId = doc["deviceId"] | "cyd-smoker";
|
||||
|
||||
JsonArray names = doc["probeNames"].as<JsonArray>();
|
||||
|
||||
Reference in New Issue
Block a user