Skip to content

Commit 54db232

Browse files
committed
Fixed values being exposed as the wrong name, fixes #16
1 parent 9f63645 commit 54db232

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/input.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -89,11 +89,11 @@ void create_rapi_json(String &data)
8989
if (volt > 0) {
9090
doc["volt"] = volt;
9191
}
92-
doc["pilot"] = watthour_total;
93-
doc["wh"] = temp1;
94-
doc["temp1"] = temp2;
95-
doc["temp2"] = temp3;
96-
doc["temp3"] = pilot;
92+
doc["pilot"] = pilot;
93+
doc["wh"] = watthour_total;
94+
doc["temp1"] = temp1;
95+
doc["temp2"] = temp2;
96+
doc["temp3"] = temp3;
9797
doc["state"] = state;
9898
doc["freeram"] = HAL.getFreeHeap();
9999
doc["divertmode"] = divertmode;
@@ -268,7 +268,7 @@ update_rapi_values() {
268268
}
269269

270270
void
271-
handleRapiRead()
271+
handleRapiRead()
272272
{
273273
Profile_Start(handleRapiRead);
274274

@@ -382,7 +382,7 @@ handleRapiRead()
382382

383383
void on_rapi_event()
384384
{
385-
if(!strcmp(rapiSender.getToken(0), "$ST"))
385+
if(!strcmp(rapiSender.getToken(0), "$ST"))
386386
{
387387
const char *val = rapiSender.getToken(1);
388388
DBUGVAR(val);

0 commit comments

Comments
 (0)