Enable SolarXiao Room Server power profiles and late-detection history

This commit is contained in:
mikecarper committed 2026-10-21 17:02:01 -07:00
1 parent ad15f2ea08
commit 9aa7974567
9 files changed
+625 -9

No files matched your search

+2 -1
View File
@@ -146,7 +146,8 @@ void addTelemetry(CayenneLPP& lpp) {
for (unsigned i=0;i<3;++i) lpp.addGenericSensor(11+i,s.alerts[i]);
}
uint8_t voltageChannels(uint8_t* channels,uint8_t capacity) {
if (!selection.nativeAllowed()) return 0;
// History allocates its schema once at boot, before Auto can verify MPPT.
// Reserve stable IDs without I/O; inactive/unavailable samples stay missing.
const uint8_t count=capacity<4 ? capacity : 4;
for (uint8_t i=0;channels && i<count;++i) channels[i]=2+i;
return count;
+2
View File
@@ -12,6 +12,8 @@ void service();
bool handleCommand(const char* command, char* reply, size_t capacity, bool local);
void addTelemetry(CayenneLPP& telemetry);
uint8_t voltageChannels(uint8_t* channels, uint8_t capacity);
// The channel list reserves history schema without I/O; only queryVoltages
// returns measured samples, and remains gated by the active power profile.
uint8_t queryVoltages(SensorManager::VoltageSensorReading* readings, uint8_t capacity);
}}
#endif