Purple Air and WeeWx-Purple extension

152 views
Skip to first unread message

Dan Hinckley

unread,
Jan 10, 2025, 2:40:59 PMJan 10
to weewx...@googlegroups.com
When I access my PA unit directly, the readings I see are different from the one generated by the John Kline extension.

When I check right after WeeWx has generated new files on each loop, direct access to the PA shows this:


And the WeeWx-Purple displays this:


I don't know enough about how the AQI is calculated to know if this discrepancy is normal or is something else.

Chuck Rhode

unread,
Jan 10, 2025, 4:41:49 PMJan 10
to weewx...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Santa Claus brought me a new-in-the-box, really-old-model AcuRite
02064C to replace an Ambient WS2095 that has been in service at least
seven years. Both are USB tethered, so I'm confident about my
hardware config, although it's viability remains to be seen. (The
*weectl device* utility DOES NOT support the AcuRite although there is
a *weewx* driver.)

Both stations are operating. I've resisted the temptation to try to
switch WeeWX to monitoring the AcuRite because there are discrepancies
between the readings displayed on the indoor consoles. I don't know
why I expected them to be identical, and I don't know how much
precision to expect. It may well be that the discrepancies are within
the limits of accuracy for this class of devices.

I report to AWEKAS, CWOP, PWSWeather, WOW, and Wunderground, so I
think I ought to exercise some care with my calibration in order not
to contribute unnecessarily to public perceptions of Anthropogenic
Global Warming (AGW). In fact I'm motivated to replace the Ambient
station because the wind direction sensor failed in Aug 2023.

> reading Ambient AcuRite KSBM
> ---------------- ---------- ---------- ---------
> outdoor temp 26.2°F 26°F 26.1°F
> outdoor humidity 53% 83% 80%
> pressure 29.24 inHg 29.84 inHg
> barometer 29.56 inHg

Right now the outdoor temp is the same on a cloudy day, but I've seen
the AcuRite 2°F higher and 2°F lower. It has a small solar panel and
is aspirated, so it may be more reliable. It's just merely possible
that its humidity is much more nearly correct, too, because it IS
CLOSE to what the Sheboygan, WI, airport is reporting.

According to the WeeWX hardware pages, both stations report "pressure"
so I assume that the contradiction is in the labeling on their
consoles and not in what they think they are measuring. Again the
AcuRite is more nearly correct, according the airport. Goodness knows
how the actual altitude differs but it can't be more than a couple
orders of magnitude in feet.

... so my questions are:

Q1: Is this level of obsession justified?

Q2: Should I attempt any calibration of the AcuRite station?

Q3: Or should I just let it fly without providing any smoothing
between old and new readings?

Q4: Do I need to have youinses change the WeeWX map, or will my
station model populate automagically?

- --
.. Be Seeing You,
.. Chuck Rhode, Sheboygan, WI, USA
.. Weather: https://LacusVeris.com/Wx
.. 25° — Wind WSW at 7 mph. Sky overcast; light snow; mist.
-----BEGIN PGP SIGNATURE-----

iF0EARECAB0WIQT+MY/5I/LMPSswTbVg2/xipKOWUgUCZ4FNnQAKCRBg2/xipKOW
UkuiAJ434hOrwrf28Y3opzagIUl4MFm0gQCbB+WApkcJSJRg+pCa/Vgu8hiLhHc=
=TNQQ
-----END PGP SIGNATURE-----

John Kline

unread,
Jan 10, 2025, 4:52:20 PMJan 10
to weewx...@googlegroups.com, weewx...@googlegroups.com
There are two reasons these can differ.  One, the PurpleAir map you are showing is a 2m average while the weewx-purple loop packets are the most recent reading.  Also, the EPA has updated the AQI calculation (see: https://www.epa.gov/system/files/documents/2024-02/pm-naaqs-air-quality-index-fact-sheet.pdf ).  Weewx-purple has been updated with the new AQI calculation while the PurpleAir map has not been.

A third reason could be if the PurpleAir map is not using the EPA correction (which corrects pm2_5)—see https://www.epa.gov/sites/default/files/2021-05/documents/toolsresourceswebinar_purpleairsmoke_210519b.pdf .  I cannot tell if this is so from your screenshot.

On Jan 10, 2025, at 6:40 AM, Dan Hinckley <d...@suiattle.org> wrote:

When I access my PA unit directly, the readings I see are different from the one generated by the John Kline extension.

When I check right after WeeWx has generated new files on each loop, direct access to the PA shows this:

<Screen Shot 2025-01-10 at 09.37.37.png>

And the WeeWx-Purple displays this:

<Screen Shot 2025-01-10 at 09.37.56.png>

I don't know enough about how the AQI is calculated to know if this discrepancy is normal or is something else.

--
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 weewx-user+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/weewx-user/C40F997E-F8DC-452D-9D30-3C8307C08AB1%40suiattle.org.

p q

unread,
Jan 10, 2025, 5:09:13 PMJan 10
to weewx...@googlegroups.com
I have an Acurite station, different model. The all in one sensor unit with the rain, wind, and temp measurement is kind of cool, but it doesn't work well, at least for me. I was unable to find a place with clear sky overhead for the rain gauge, clear area around it for the wind gauge, and in the shade for the thermometer. The solar panel and fan doesn't do enough, at least for me in northern California. So, I gave up on the thermometer and mounted it on my roof, where the temperatures are easily 10 degrees warmer than ground level or 5 degrees colder on clear nights.

To deal with this, I've built my own temperature sensor and mounted it elsewhere and send the data via wifi and MQTT. I hacked the acurite driver to accept this data through overcomplicated means. If I were doing it again, I'd use the MQTT drivers that have been developed since I started.

Also, I've also had to replace the rain gauge after 8 years of operation. It's become unreliable. We don't get very much rain here, so it might last longer someplace where it's not sitting for 9 months without any rain and being subject to 115 deg temperatures. I don't fault Acurite for this, things wear out.

In terms of the barometer, mine is in the display unit, not the sensor. I have no idea how accurate it is. It appears to track my local airport pretty well. What matters for me is more changes in pressure than the absolute value, so if it's off by a couple of percent, it doesn't bother me.

Good luck with it!

--
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 weewx-user+...@googlegroups.com.


--
Peter Quinn
(415)794-2264

Alex Vanuxem

unread,
Jan 10, 2025, 5:16:20 PMJan 10
to weewx...@googlegroups.com

Hi

How did you build your temp sensor? What is the accuracy?  Very interested in this case. How about humidity? 
Thanks


Op vr 10 jan. 2025 18:09 schreef p q <peterq...@gmail.com>:

Dan Hinckley

unread,
Jan 10, 2025, 5:24:44 PMJan 10
to weewx...@googlegroups.com
I thought it might be something along those lines. How would I tell is the PA unit is using the new correction?

My unit appears here on the PA map, and the page displaying your extension output is here.

John Kline

unread,
Jan 10, 2025, 6:03:07 PMJan 10
to weewx...@googlegroups.com, weewx...@googlegroups.com
The following settings in the purpleair web app will help you, but you can’t get the correct AQI because PurpleAir hasn’t implemented it.

If you want to be sure weewx-purple is showing you a correct AQI, you need to take a current reading from the sensor, apply the pm2_5 correction (one of the two links I previously sent) and then use the other link to compute the AQI.  That is what should agree with weewx-purple’s AQI.  AQI will show higher in the green range in weewx-purple since the EPA made that range more stringent in the new calculation (among other changes).

image0.png

On Jan 10, 2025, at 9:24 AM, Dan Hinckley <d...@suiattle.org> wrote:

I thought it might be something along those lines. How would I tell is the PA unit is using the new correction?

Chuck Rhode

unread,
Jan 11, 2025, 3:28:27 PMJan 11
to weewx...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Fri, 10 Jan 2025 09:08:52 -0800
p q <peterq...@gmail.com> wrote:

> I have an Acurite station, different model. ... I've built my own
> temperature sensor and mounted it elsewhere and send the data via
> wifi and MQTT.

Thanks for replying to my post in the wrong thread.

> I've also had to replace the rain gauge after 8 years of
> operation. ... I don't fault Acurite for this, things wear out.

My sentiments about Ambient, too....

> In terms of the barometer, mine is in the display unit, not the
> sensor. I have no idea how accurate it is. It appears to track my
> local airport pretty well. What matters for me is more changes in
> pressure than the absolute value, so if it's off by a couple of
> percent, it doesn't bother me.

That is correct: Pressure sensor is in the indoor unit.

I guess that I will try to switch to AcuRite sometime today. I
appreciate your feedback.

- --
.. Be Seeing You,
.. Chuck Rhode, Sheboygan, WI, USA
.. Weather: https://LacusVeris.com/Wx
.. 26° — Wind WNW at 9 mph. Sky clear.
-----BEGIN PGP SIGNATURE-----

iF0EARECAB0WIQT+MY/5I/LMPSswTbVg2/xipKOWUgUCZ4KN8AAKCRBg2/xipKOW
UnY7AJsGIYmgEsoKKUko1GBiKw06zKwwDACfbFkNJaJwyz94ETvrIeZPUbQ5UgM=
=YCUB
-----END PGP SIGNATURE-----

Dan Hinckley

unread,
Jan 11, 2025, 4:21:36 PMJan 11
to weewx...@googlegroups.com
Thanks John, did the map settings, and will experiment with your links. I guess there isn't a way to do that correction in the weewx.conf file then?

On 10 Jan, 2025, at 13:02, 'John Kline' via weewx-user <weewx...@googlegroups.com> wrote:

The following settings in the purpleair web app will help you, but you can’t get the correct AQI because PurpleAir hasn’t implemented it.

If you want to be sure weewx-purple is showing you a correct AQI, you need to take a current reading from the sensor, apply the pm2_5 correction (one of the two links I previously sent) and then use the other link to compute the AQI.  That is what should agree with weewx-purple’s AQI.  AQI will show higher in the green range in weewx-purple since the EPA made that range more stringent in the new calculation (among other changes).

John Kline

unread,
Jan 11, 2025, 10:33:46 PMJan 11
to weewx...@googlegroups.com, weewx...@googlegroups.com
Hi Dan,

Please explain how weewx.conf entries could fix the AQI displayed on the PurpleAir website?

The AQI you are seeing from my purple extension has the correct pm2_5_cf_1 EPA correction (computed from the average of the two pm2_5_cf_1 readings of the two sensors as well as the current_humidity returned in the purple air reading).  The AQI is calculated using the new EPA AQI formula.  There is nothing more you to do with this number.

I was telling you to look at the documents so that you can manually verify the AQI the Purple extension is showing.  I did this because you are questioning if it is correct.  I don’t know any other way for you to know for sure without you going through the steps yourself.

If you satisfy yourself that the Purple extension AQI is correct, then you can take this up with PurpleAir as to why it is incorrect on their map.  When I last looked at this, PurpleAir was not giving a date for using the new AQI index.

John

On Jan 11, 2025, at 8:21 AM, Dan Hinckley <d...@suiattle.org> wrote:

Thanks John, did the map settings, and will experiment with your links. I guess there isn't a way to do that correction in the weewx.conf file then?

Dan Hinckley

unread,
Jan 11, 2025, 10:38:58 PMJan 11
to weewx...@googlegroups.com
Thanks John, I am still wrapping my head around this AQI calculation, and will check it as you describe. For the moment, I am satisfied to know that Whew-Purple is likely to be accurate.

p q

unread,
Jan 20, 2025, 7:16:06 PMJan 20
to weewx...@googlegroups.com
Sorry for the delayed response - The email was in my spam folder and I just noticed it.

I didn't do a great job of documenting this project. For the first sensor, I used UDP, not MQTT, though if I have to do maintenance on it, I'll make the switch. The code is here: https://github.com/PeterQuinn925/Arduino/tree/master/esp8266_wifiplustemp_lowpower
For the outdoor one, I bought a cheap solar panel for power and an adafruit lithium battery for night time. https://www.amazon.com/gp/product/B01MCXZJ8Y?ie=UTF8&psc=1. It's been reliable for the last five or six years.

I have a daemon running on the PI that's running Weewx. It looks for UDP data and writes a text file. My bastardized Accurite driver gets the temp from the file rather than the Accurite station. There's a little logic to handle stale data. If I was to start over, I would create my own driver from a copy of the Accurite driver rather than directly edit it - the reason being is that my driver gets overwritten on every update, so I need to copy it over afterwards.

I'm doing this just for fun, so I didn't do anything to calibrate it. To be honest, where I put it in the yard seemed to have more of an effect on the recorded temperature than any calibration errors we're likely to have.

I did another one for indoors with a display that does use MQTT. https://github.com/PeterQuinn925/Arduino/tree/master/epd2in13_time_temp




--
Peter Quinn
(415)794-2264
Reply all
Reply to author
Forward
0 new messages