Page 1 of 1

Tasmota + bme280 + Domoticz on windows weather prediction problem.

Posted: Wednesday 15 January 2020 19:31
by ribolov
Hi,
first of all sorry if I overlooked and someone already had this problem but I`m trying to figure out this for days, and did not find similar surroundings.
So I have ESP8266 with BME280 and I added it to Domoticz as temp+hym+baro device.
Everything works like a charm except, I have a temperature, pressure, and humidity readings. There is even a dew point prediction displayed, but weather prediction is Unknown all the time.
esp outside.JPG
esp outside.JPG (20.79 KiB) Viewed 1675 times
My Domoticz in the last windows version and tasmota is also the last version (7.1.2) if it means anything.
I'm a quite new to Domoticz so sorry if a question is repeated, or dumb but as I said I`m googling for days with no luck, still dont know what to look for.
Only thing that might have anything to do with this that I found is in folder C:\Program Files (x86)\Domoticz\dzVents\runtime\device-adapters\
a file named temperature_humidity_barometer_device.lua
and it has:
local constMapping = {
['noinfo'] = 0,
['sunny'] = 1,
['partlycloudy'] = 2,
['cloudy'] = 3,
['rain'] = 4
}
What I cant find out is from where should this values come ....
Can anyone help with shedding some light on this subject, please?
With Kindest regards,
Sasa

Re: Tasmota + bme280 + Domoticz on windows weather prediction problem.

Posted: Monday 20 January 2020 15:58
by erem
Hi,

i have the same issue with a BME280 and ESPEasy.
The previous sensor in that spot was a BMP280, and the prediction would populate
When i changed the sensor to a BME280, the prediction was always Unknown.
I traced this back to the device in database table DeviceStatus, wherethe field svalue hold the latest incoming values from ESPEasy.
i see the incoming svalue as 20.18;51.14;1;1021.72;0, temp; hum; press; unknown value, i suspect this is the prediction.

thus i concluded the issue was the BME280 or the BME280 handler code in ESPEasy, outside my control.
and i gave up..... :oops:

Re: Tasmota + bme280 + Domoticz on windows weather prediction problem.

Posted: Monday 20 January 2020 19:22
by ribolov
Hi Erem,
you sure did some research.
I just checked the same thing and in my case, svalue in DeviceStatus table for this particular sensor looks like this: 1.70;74.4;3;1030;5, so if I get this right I should at least have a different result than you since I have 5 at the end but what I`m missing is why 5 values when sensor read only 3 and one is for weather prediction... where is the catch? So what is the third value if the fifth is for weather prediction? ....
And do not give up, we will figure this out :D

Re: Tasmota + bme280 + Domoticz on windows weather prediction problem.

Posted: Monday 20 January 2020 19:40
by ribolov
I just figure out that this third value could be "dry" or wet or something like that, numbers based on humidity ... but why the hell is weather prediction than not working that is a million $ question.....

Re: Tasmota + bme280 + Domoticz on windows weather prediction problem.

Posted: Thursday 23 January 2020 13:34
by ribolov
Another update,
it seams that the problem is not with Domoticz but with Tasmota in my case.
Here is how mqtt message from Tasmota looks like:
2020-01-23 13:25:29.212 MQTT: Topic: domoticz/in, Message: {"idx":148,"nvalue":0,"svalue":"3.2;66.3;1;1019.5;5","Battery":100,"RSSI":5}
Se the last data piece in svalue is 5, and here is mapping from Domoticz documentation:
nValue: 0, sValue: "pressure;forecast"
Forecast:
0 - Stable
1 - Clear/Sunny
2 - Cloudy/Rain
3 - Not stable
4 - Thunderstorm
5 - Unknown

So Domoticz is doing exactly what it should, he gets 5 and he displays Unknown. So what I have learned from this is that algorithm for calculation weather prediction must be on Tasmota or any other device sending data to Domoticz. So now I will try to figure this out with Tasmota.

Re: Tasmota + bme280 + Domoticz on windows weather prediction problem.

Posted: Thursday 23 January 2020 14:30
by ribolov
Thinking more about my last conclusion that Tasmota is making calculations for weather prediction is a little unlikely, it has no db or something to put data in, so how it would store barometric data for some time and from that data calculate weather prediction.... I mean it is possible but not so logical. On the other hand, all other data that we gathered suggest that Domoticz just displays data that is served from a device like Tasmota ....
Now I have no idea .............

Re: Tasmota + bme280 + Domoticz on windows weather prediction problem.

Posted: Sunday 26 January 2020 14:34
by ribolov
OK, I found a solution, it`s done with lua script.
Here is it explained in details.
https://techestigate.com/domoticz-weath ... n-unknown/
Cheers