I use home automation (openHab) and the inside humidity and inside temperature is something I am putting into the home automation so I used that to resend every 2 minutes to weew mqttsubscribe. The openHab keeps the last data it was sent. I use JSON.stringify to make it a json data pakage.
Here is the openhab code (javascript)
var TOPIC="weewx"
temperature=(items.getItem("Zigbee_temperature_bedroom_xiaomi_greg").state)
humidity=(items.getItem("Zigbee_humidity_bedroom_xiaomi_greg").state)
var PAYLOAD=(JSON.stringify({"humidity": humidity, "temperature": temperature}))
result = actions.Exec.executeCommandLine(time.Duration.ofSeconds(5), "/usr/bin/mosquitto_pub","\-h","192.168.1.164","\-t","" + TOPIC,"\-m","" + PAYLOAD);
console.log(JSON.stringify({"humidity": humidity, "temperature": temperature}))
And here is the weew.conf part.
# The second topic to subscribe to.
[[[weewx]]]
#[[[zigbee2mqtt/sensor-xiaomi-greg]]]
ignore = true # opt out of processing fields for this topic by default - override per field
[[[[temperature]]]]
name = inTemp
# True if the incoming data should not be processed into WeeWX.
# Valid values: True, False
# Default is False
ignore = False
# True if the incoming data is cumulative.
# Valid values: True, False
# Default is False
contains_total = False
[[[[humidity]]]]
name = inHumidity
# True if the incoming data should not be processed into WeeWX.
# Valid values: True, False
# Default is False
ignore = False
And here is the data that is being sent:
{"humidity":"47.06","temperature":"23.97"}
Also thanks for the link of the bme280 device I still may get one anyway.
Hopefully now my graphs will look good again!
Thanks again for all the ideas.