mirror of https://github.com/arendst/Tasmota.git
Fix MQTT heatindex calculation
This commit is contained in:
parent
9cacf2f609
commit
d678666ef0
|
@ -1356,7 +1356,7 @@ int ResponseAppendTHD(float f_temperature, float f_humidity) {
|
|||
Settings->flag2.humidity_resolution, &f_humidity,
|
||||
Settings->flag2.temperature_resolution, &dewpoint);
|
||||
#ifdef USE_HEAT_INDEX
|
||||
float heatindex = CalcTemHumToHeatIndex(TasmotaGlobal.temperature_celsius, TasmotaGlobal.humidity);
|
||||
float heatindex = CalcTemHumToHeatIndex(f_temperature, f_humidity);
|
||||
int len2 = ResponseAppend_P(PSTR(",\"" D_JSON_HEATINDEX "\":%*_f"),
|
||||
Settings->flag2.temperature_resolution, &heatindex);
|
||||
return len + len2;
|
||||
|
|
|
@ -190,12 +190,12 @@ typedef struct Lora_t {
|
|||
int (* Receive)(char*);
|
||||
bool (* Send)(uint8_t*, uint32_t, bool);
|
||||
LoraSettings_t settings; // Persistent settings
|
||||
uint32_t receive_time;
|
||||
volatile uint32_t receive_time;
|
||||
float rssi;
|
||||
float snr;
|
||||
uint8_t packet_size; // Max is 255 (LORA_MAX_PACKET_LENGTH)
|
||||
volatile bool received_flag; // flag to indicate that a packet was received
|
||||
bool send_flag;
|
||||
volatile bool send_flag;
|
||||
bool raw;
|
||||
#ifdef USE_LORAWAN_BRIDGE
|
||||
uint32_t device_address;
|
||||
|
|
Loading…
Reference in New Issue