Comments (16)
@sussex1
I think I have this fixed. It passes the unit tests, but I don’t have functional tests yet. A prerelease is here https://github.com/bellrichm/WeeWX-MQTTSubscribe/releases/tag/v1.5.0-rc02
If you could give it a try and let me know how it goes, that would be greatly appreciated. If you run into problems, attaching the log is appreciated.
Thanks for your help! Rich
from weewx-mqttsubscribe.
rich
Do I need to make any changes to weewx.config?
windDir is no longer showing in the record packets. windRaw is appearing in the loop packets and not translating to windSpeed so I assume label_map is no longer working.
How should [fields] be used with individual records?
Ian
LOOP: 2020-01-23 15:55:13 AEDT (1579755313) dateTime: 1579755313.01, maxSolarRad: None, outTemp: 39.37, rainRate: 24.072, usUnits: 17 LOOP: 2020-01-23 15:55:13 AEDT (1579755313) dateTime: 1579755313.04, maxSolarRad: None, outHumidity: 21.52, rainRate: 24.072, usUnits: 17 LOOP: 2020-01-23 15:55:13 AEDT (1579755313) dateTime: 1579755313.05, maxSolarRad: None, rainRate: 24.072, usUnits: 17, windDir: 331.0 LOOP: 2020-01-23 15:55:13 AEDT (1579755313) dateTime: 1579755313.05, maxSolarRad: None, rain: 0.034, rainRate: 24.208, usUnits: 17 LOOP: 2020-01-23 15:55:13 AEDT (1579755313) dateTime: 1579755313.05, maxSolarRad: None, rainRate: 24.208, usUnits: 17, windRaw: 66.0 LOOP: 2020-01-23 15:55:17 AEDT (1579755317) bmp_temp: 40.1, dateTime: 1579755317.92, maxSolarRad: None, rainRate: 24.208, usUnits: 17 REC: 2020-01-23 15:55:00 AEDT (1579755300) baro_mb: 995.184, bmp_temp: 40.3316666667, cloudbase: 3291.1497146, dateTime: 1579755300.0, dewpoint: 13.2052561403, ET: None, heatindex: 39.5516666667, humidex: 42.4619539575, interval: 5, maxSolarRad: None, outHumidity: 21.1243333333, outTemp: 39.5516666667, rain: 2.04, rainRate: 24.208, usUnits: 17, windRaw: 111.65
from weewx-mqttsubscribe.
Ian,
Although I am phasing out label_map, it should still work. In rc 03 I fixed a bug such that the label_map would not work if you had something like this
[[[label_map]]]
windRaw = windSpeed
[[[fields]]]
[[[[windRaw]]]]
conversion_type = float
But, I also think you have a typo in the config you posted. The windRaw is missing a ']'
[[[[windRaw]]]
Using just fields, this should essentially be what you want
[[[fields]]]
[[[[windRaw]]]]
name = windSpeed
[[[[baro_mb]]]]
name = barometer
[[[[rainTotal]]]]
name = rain # I didn't check what the WeeWX name really is
contains_total = True
I really appreciate all of your help. -rich
from weewx-mqttsubscribe.
Thanks rich
The extra ] was a big help ;) the fields are mapping properly .
Going by the log output cumulative rain is working but is 3am here so am not going out to spray water on the roof mounted rain gauge hihi.
There is wind blowing atm but windDir is still not making it through to the archive records, not sure if you had a fix for that in rc3.
Ian
from weewx-mqttsubscribe.
Ian,
Drat, I thought I had fixed the windDir bug. Could you post the log with rc03 and the MQTTSubscribe config section?
Thanks. - rich
from weewx-mqttsubscribe.
Ian,
On second thought, hold off. I think I want to revamp the handling of wind data to make it more robust. And if you are up for testing the new implementation, that would be a big help.
- rich
from weewx-mqttsubscribe.
Darn. I thought i could leverage the WeeWX accumulator for the wind data. But, it expects the wind data to be together - the whole reason I wrote the Collector in the first place....
from weewx-mqttsubscribe.
Ok you write it and ill test it. I have looked through the code and is well beyond my python abilities so cant contribute to that.
from weewx-mqttsubscribe.
from weewx-mqttsubscribe.
Ian,
If you are up for a bit more testing, I’d like to get the individual record windDir working. Turns out my approach in rc03 seems to be the best. This should put windSpeed and WindDir in the same loop packet. It works in my test, but that is not real world. Could you try and pos the log? No hurry, I have some other things that I need to do in the next couple of days.
And yeah, it is probably a bit over engineered (meaning complicated), but my goal was/is a service and driver that could handle many different MQTT formats. And even more, a chance to really learn WeeWX and MQTT.
Thanks. rich
from weewx-mqttsubscribe.
rich
No worries. here is the logs
ian
weewx_log_100026012020.txt
from weewx-mqttsubscribe.
Ian,
In weewx_log_100026012020.txt at line 417, it looks like it was running with rc01 to me. Could you double check? If it is easier to just grab from master that is fine for this test.
Thanks. rich
from weewx-mqttsubscribe.
rich
OOps You are right, must have filezillered the wrong one over. Got a new copy from master loaded now but the arduino that publishes is in the bench to sort out some extra rain gauge tips, probably RF getting in so decoupling caps may fix. Will get it all back together later today hopefully.
Ian
from weewx-mqttsubscribe.
Ian,
No worries. Believe me, I get it.
No hurry. Again, thanks for your help. - rich
from weewx-mqttsubscribe.
rich
Have put the publisher back on the roof temporarily. From what i can see rc04 looks to be doing exactly what it should with the windDir and rainTotals, thanks for the help.
Hopefully 1 more bug squashed;). Log attached
ian
weewx_log_150729012020.txt
from weewx-mqttsubscribe.
Ian,
It looks good to me. Once I wrap up some test prototyping , I’ll package it up in a 1.5.0 release.
Thanks for your help in testing and debugging. - rich
from weewx-mqttsubscribe.
Related Issues (20)
- Error with date fields HOT 6
- expires_after = None is ignored HOT 1
- Unsubscribed Topics HOT 8
- Need to migrate off of nose HOT 2
- Int Values Stored As Floats in DB HOT 29
- Possible problem with rain and contains_total HOT 2
- problem while installing... HOT 4
- problem reading values... HOT 7
- WeeWX crashes because MQTTSubscribe fails network connect on cold start or reboot HOT 3
- expires_after does not always work HOT 3
- MQTT problems cause WeeWX consuming all the CPU HOT 13
- MessageCallbackProvider on_message_json failed with <class 'user.MQTTSubscribe.ConversionError'> HOT 1
- Gaps in WeeWx data HOT 26
- Parse more complex json messages HOT 2
- Deprecate [[message_callback]] HOT 4
- Refactor the validate function so that it can used when running under WeeWX HOT 1
- Cleanup WeeWX stubs and mocks
- Support paho mqtt v2
- V3 to dos
- Error in Debian 12 with python 3.11 - AttributeError: 'Client' object has no attribute '_sock' HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from weewx-mqttsubscribe.