mirror of https://github.com/arendst/Tasmota.git
fixed wrong display in some case
This commit is contained in:
parent
36288037a8
commit
2098f21775
|
@ -620,8 +620,8 @@ void TInfoShow(bool json)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
char name[32];
|
char name[33];
|
||||||
char value[32];
|
char value[33];
|
||||||
|
|
||||||
if (tinfo_mode==TINFO_MODE_HISTORIQUE ) {
|
if (tinfo_mode==TINFO_MODE_HISTORIQUE ) {
|
||||||
if (getValueFromLabelIndex(LABEL_BASE, value) ) {
|
if (getValueFromLabelIndex(LABEL_BASE, value) ) {
|
||||||
|
@ -670,13 +670,13 @@ void TInfoShow(bool json)
|
||||||
if (getValueFromLabelIndex(LABEL_SMAXSN, value) ) {
|
if (getValueFromLabelIndex(LABEL_SMAXSN, value) ) {
|
||||||
WSContentSend_PD(HTTP_ENERGY_PMAX_TELEINFO, atoi(value));
|
WSContentSend_PD(HTTP_ENERGY_PMAX_TELEINFO, atoi(value));
|
||||||
}
|
}
|
||||||
if (getValueFromLabelIndex(LABEL_LTARF, name) ) {
|
if (getValueFromLabelIndex(LABEL_LTARF, value) ) {
|
||||||
WSContentSend_PD(HTTP_ENERGY_TARIF_TELEINFO, name);
|
WSContentSend_PD(HTTP_ENERGY_TARIF_TELEINFO, value);
|
||||||
}
|
}
|
||||||
if (getValueFromLabelIndex(LABEL_NGTF, name) ) {
|
if (getValueFromLabelIndex(LABEL_NGTF, value) ) {
|
||||||
if (isousc) {
|
if (isousc) {
|
||||||
int percent = (int) ((Energy.current[0]*100.0f) / isousc) ;
|
int percent = (int) ((Energy.current[0]*100.0f) / isousc) ;
|
||||||
WSContentSend_PD(HTTP_ENERGY_CONTRAT_TELEINFO, name, isousc);
|
WSContentSend_PD(HTTP_ENERGY_CONTRAT_TELEINFO, value, isousc);
|
||||||
WSContentSend_PD(HTTP_ENERGY_LOAD_TELEINFO, percent);
|
WSContentSend_PD(HTTP_ENERGY_LOAD_TELEINFO, percent);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue