Add meter-reference calibration with saved ADC corrections, checked persistence and rollback. Preserve existing board coefficients and nRF52 voltage policy, and merge the Mini Repeater feature gates. Validation: 69 focused tests, hosted documentation checks, and four firmware builds passed. Mini Repeater retains calibration and its existing filesystem with 376 flash bytes free; earlier Mini Sensor size failures remain documented.
19 lines
780 B
C++
19 lines
780 B
C++
#pragma once
|
|
|
|
#include <MeshCore.h>
|
|
#include <helpers/IdentityStore.h>
|
|
|
|
namespace mesh { namespace power {
|
|
|
|
// Companion and Terminal Chat keep calibration outside their published
|
|
// preference layouts. Infrastructure roles retain their existing ADC field.
|
|
bool beginBatteryCalibrationStore(MainBoard& board, FILESYSTEM* fs);
|
|
bool setStoredAdcMultiplier(MainBoard& board, float multiplier,
|
|
char* reply, size_t capacity);
|
|
bool handleStoredAdcMultiplierCommand(MainBoard& board, const char* command,
|
|
char* reply, size_t capacity);
|
|
bool handleStoredBatteryCalibrationCommand(MainBoard& board, const char* command,
|
|
char* reply, size_t capacity);
|
|
|
|
}} // namespace mesh::power
|