To answer your question, it helps to look at the setup of the standard
processing pipeline:

*StdConvert*
The first step is to convert any data coming off the hardware into the
appropriate unit system.

*StdCalibrate*
Then user-specified corrections are made.

*StdQC*
Set any anomalous data to None.

*StdWXCalculate*
This is probably where the confusion lies. Given the presence of
appropriate values of temperature and altitude, StdWXCalculate can
calculate pressure from barometer, altimeter from pressure, and barometer
 from pressure. Whether it does so depends on the value of the "directive."
If the directive is "hardware," it doesn't touch the value. If it is "
software" it always calculates the value, even if the hardware emitted
something. If it is "prefer_hardware" it calculates a value only if the
value is None, otherwise it doesn't touch it.

Note that for "prefer_hardware" a new value is calculated *only* if the old
value was None. If altimeter is emitted from the dictionary completely, it
won't do anything.

Now to answer your question, you can leave the values at their defaults:

[StdWXCalculate]
    [[Calculations]]
        pressure = prefer_hardware
        altimeter = prefer_hardware
        barometer = prefer_hardware

pressure: Because your driver emits a value for pressure, the directive "
prefer_hardware" tells StdWXCalculate not to touch it.

altimeter: If the driver emits a value of None for altimeter the directive "
prefer_hardware" tells StdWXCalculate to calculate it from the provided
sensor pressure. Because StdWXCalculate appears after StdCalibrate in the
processing pipeline, it will use the corrected value of pressure. If the
driver does emit a value for altimeter, it won't touch it, which means that
you should either apply a correction to altimeter in StdCalibrate, or use a
directive of "software", forcing StdWXCalculate to calculate it from the
corrected sensor pressure. If your driver emits nothing at all for
altimeter then
nothing is done.

barometer: Same as altimeter.

Hope this helps.

-tk



On Tue, Jul 7, 2026 at 2:11 AM 'Tomasz Lewicki' via weewx-user <
[email protected]> wrote:

> Please help me understand the workflow for pressure/barometer calculations
> in Weewx.
>
> Here’s the situation. Let’s say my barometer reads 970 hPa. Setting aside
> how the reduced pressure is calculated, I know that it underestimates the
> pressure by 6 hPa. I’d like to inform Weewx of this without using the
> weather station console—that is, without physically entering corrections
> into the console. In other words, I want to do this in weewx.conf.
>
> I’ve made the following changes:
> [[[Units]]]
>     [[[[Groups]]]]
> group_pressure = hPa
>
> [StdCalibrate]
>     [[Corrections]]
>         pressure = pressure + 6.0
>
> [StdWXCalculate]
>     [[Calculations]]
>         barometer = WHAT SHOULD BE HERE?
>         pressure = AND HERE?
>
> --
> You received this message because you are subscribed to the Google Groups
> "weewx-user" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion visit
> https://groups.google.com/d/msgid/weewx-user/dad98426-2004-4d3e-b1cb-6bd36d59da90n%40googlegroups.com
> <https://groups.google.com/d/msgid/weewx-user/dad98426-2004-4d3e-b1cb-6bd36d59da90n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/weewx-user/CAPq0zEBxaaVR-j3XB9vsJjjpY75%2BUVv8pCJNEVrWNTd8nbpxPQ%40mail.gmail.com.

Reply via email to