* repeater and room server: CommonCLI now handles load/save of Prefs. Now sanitise bad prefs values.

This commit is contained in:
Scott Powell
2025-03-05 16:39:45 +11:00
parent 86681364bd
commit 01d84d5d3e
4 changed files with 90 additions and 34 deletions

View File

@@ -1,6 +1,7 @@
#pragma once
#include "Mesh.h"
#include <helpers/IdentityStore.h>
struct NodePrefs { // persisted to file
float airtime_factor;
@@ -54,5 +55,7 @@ public:
CommonCLI(mesh::MainBoard& board, mesh::Mesh* mesh, NodePrefs* prefs, CommonCLICallbacks* callbacks)
: _board(&board), _mesh(mesh), _prefs(prefs), _callbacks(callbacks) { }
void loadPrefs(FILESYSTEM* _fs);
void savePrefs(FILESYSTEM* _fs);
void handleCommand(uint32_t sender_timestamp, const char* command, char* reply);
};