Coder Social home page Coder Social logo

Comments (9)

bellrichm avatar bellrichm commented on July 18, 2024

Sorry I'm not following you.
I am guessing that you have something like this.

        [[[[rain24_in]]]]
            name = rain
            contains_total = true

And in the Current Conditions section the Rain Today is incrementing by the incoming value in the rain24_in field?

A log file will be needed. Set debug = 1, restart WeeWX and let it run through at least one archive record generation. Double check that no sensitive information is contained in the log.

from weewx-mqttsubscribe.

gary-hammer avatar gary-hammer commented on July 18, 2024

I'm attaching 4 runs with debug set.
rain24_in with total enabled
rain24_in with total disabled
dayrain_in with total enabled
dayrain_in with total disabled.

With total disabled, I get values in the skin, but incorrect.
With total enabled I get 0.00 in the skin.
MQTTInput-debug.zip

from weewx-mqttsubscribe.

bellrichm avatar bellrichm commented on July 18, 2024

Thanks for the logs. I used the debug-dayrain_in log.
Based on the field not changing from .18, it looks like in this archive period you got no rain.
The 'contains total' algorithm is simple. At startup the value in the field, dayrain_in, is stored as the 'previous value'. After the first loop the 'incoming value' is compared to the 'previous value'. If the 'incoming value is greater than the 'previoua value', the 'WeeWX value' is set to 'incoming value' - 'previous value'. In the archive period of the log file, this results in a value of 0 being stored in the DB.
The 'Rain Today' uses the WeeWX '$day.rain.sum' tag. This sums the rain in the DB for the given day. So unless you have some rain values in the DB, the skin will display 0.
So at startup the 'historical' data is lost (or if WeeWX is stopped during a rain event some rain is lost). Without adding a lot of complexity, I don't see a way around this, but I will listen to any ideas.
Net, during the archive period of this log, everything looks to be working as expected.

from weewx-mqttsubscribe.

bellrichm avatar bellrichm commented on July 18, 2024

This discussion maybe of interest
#150

from weewx-mqttsubscribe.

bellrichm avatar bellrichm commented on July 18, 2024

Is this still a problem?

from weewx-mqttsubscribe.

gary-hammer avatar gary-hammer commented on July 18, 2024

I haven't had rain for awhile.
But, to be clear, I could not find a value that shows the amount of rain for the current day.
If I use a logger, I get the rain for the day. WLL, same.
Once it begins raining again, I'll try various options you've outlined on my test install and compare to my in service instance.
Meantime, I'll close this.

from weewx-mqttsubscribe.

gary-hammer avatar gary-hammer commented on July 18, 2024

What would cause a doubling of rain?
Today, we had rain. My production WeeWX shows 0.17"
My test instance using MQTTSubscribe shows 0.34 on any skin installed.

Here's where it is getting the rain value.
[[[[rain_in]]]]
ignore = false # opt back in for this field
name = rain
#contains_total = true

from weewx-mqttsubscribe.

gary-hammer avatar gary-hammer commented on July 18, 2024

I tried both with contains_total set and not set.

from weewx-mqttsubscribe.

gary-hammer avatar gary-hammer commented on July 18, 2024

Got it with contains_total true

from weewx-mqttsubscribe.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.