mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-23 02:36:35 +00:00
fix opentherm json
This commit is contained in:
parent
f77690dd9a
commit
8033917a36
@ -237,7 +237,7 @@ void sns_opentherm_stat(bool json)
|
|||||||
{
|
{
|
||||||
ResponseAppend_P(PSTR(",\"OPENTHERM\":{"));
|
ResponseAppend_P(PSTR(",\"OPENTHERM\":{"));
|
||||||
ResponseAppend_P(PSTR("\"conn\":\"%s\","), statusStr);
|
ResponseAppend_P(PSTR("\"conn\":\"%s\","), statusStr);
|
||||||
ResponseAppend_P(PSTR("\"settings\":%d,"), Settings->ot_flags);
|
ResponseAppend_P(PSTR("\"settings\":%d"), Settings->ot_flags);
|
||||||
sns_opentherm_dump_telemetry();
|
sns_opentherm_dump_telemetry();
|
||||||
ResponseJsonEnd();
|
ResponseJsonEnd();
|
||||||
#ifdef USE_WEBSERVER
|
#ifdef USE_WEBSERVER
|
||||||
|
@ -549,7 +549,6 @@ void sns_opentherm_process_success_response(struct OT_BOILER_STATUS_T *boilerSta
|
|||||||
|
|
||||||
void sns_opentherm_dump_telemetry()
|
void sns_opentherm_dump_telemetry()
|
||||||
{
|
{
|
||||||
bool add_coma = false;
|
|
||||||
for (int i = 0; i < SNS_OT_COMMANDS_COUNT; ++i)
|
for (int i = 0; i < SNS_OT_COMMANDS_COUNT; ++i)
|
||||||
{
|
{
|
||||||
struct OpenThermCommandT *cmd = &sns_opentherm_commands[i];
|
struct OpenThermCommandT *cmd = &sns_opentherm_commands[i];
|
||||||
@ -558,11 +557,8 @@ void sns_opentherm_dump_telemetry()
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
ResponseAppend_P(PSTR("%s\"%s\":"), add_coma ? "," : "", cmd->m_command_name);
|
ResponseAppend_P(PSTR(",\"%s\":"), cmd->m_command_name);
|
||||||
|
|
||||||
cmd->m_ot_appent_telemetry(cmd);
|
cmd->m_ot_appent_telemetry(cmd);
|
||||||
|
|
||||||
add_coma = true;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user