Weather Underground’s Next Frontier: Air Quality

I could still use both sources then…local IP and cloud data (the cloud data to get the other channel 2.5 reading, for use as a back up)
so as to get the other micron data from the local IP data

Indeed, Brian, you could use both URL. But…

I still think that the data from the Thingspeak cloud storage (ie: ‘https://map.purpleair.org/json?show=SENSOR_ID’) should be the default procedure (option) and, true, we would obtain the data for PM2.5 (only), but the data for both channels - we would have a backup channel.

There could be an option to also download a single channel with the data for all three PM (PM2.5, PM1.0 and PM10.0).

That is why in a previous message I was suggesting that the software ‘cronairquality.exe’ had the flexibility to possibly use an external setting file so that the software ‘cronairquality.exe’ could download data from multiple locations/sites without overwriting the saved data file (thanks to its external configuration file).

I do like the idea of not having to mess around with a local IP address and just use the sensor ID that is provided with the sensor
and since it looks like the PM 2.5 value is the important one, and only one needed or the air quality index, then we can get that value (for both channels) via the purpleair.com cloud data

one other advantage of using the cloud data is I could make it where another sensor ID could be monitored (e.g via custom tags)

I do have others interested in this feature in WD (via email and via the WD Facebook page ) :slight_smile:

maybe have it optional to get the data data via the local sensor IP address

this update
http://www.weather-display.com/downloadfiles/weatherdisplaytest.zip

allows to set the sensor ID

and so the PM2.5 value is used from the cloud site (I still need to compare the 2nd channel data and use that if the first channel data is out of range)

and you can set to use the local IP to get the other data (1.0 and 10.0)

also you can set to upload the gauge and graph to your web site (see in the misc setup)
(aqi.gif and aqigraph.gif)

Brian, big, BIG, BIG problem!

I just had a look at the computer running the test version of Weather Display, the one downloading the data from the PurpleAir sensor using the software ‘cronairquality.exe’ and had an unusual Windows error message stating that the computer had run out of memory to run a specific software. I then look at the tasks running and found hundreds (yes, hundreds) of ‘cronairquality.exe’ running. I had to shut off every software running and reboot the computer to clear out the ‘infestation’. I have now deactivate the download of the PurpleAir data.

I have downloaded the latest test version of Weather Display and will check its behaviour…

Brian, the latest versions of Weather Display and the software ‘cronairquality.exe’ have been running for about 30 minutes without ‘infestation’. :wink:

One thing I have noticed is that the setting for the option to ‘Use local data (for 1.0 and 10.0 PM size data)’ does not remain set - if, on the ‘Purpleair Air Quality Sensor’ screen, I set the option to ‘Use local data (for 1.0 and 10.0 PM size data)’, clicked the ‘OK’ button to save the setting and exit the window and then, a few minutes later, I go again on the ‘Purpleair Air Quality Sensor’ screen, the check mark in front of the option to ‘Use local data (for 1.0 and 10.0 PM size data)’ is gone.

ops
try downloading again , same url, re test .zip update, to fix that setting

Brian, can both downloads (ie: from the Thingspeak cloud storage and the local network) be done or is it one or the other but not both?

Might be practical if both downloads could simultaneously be done (take place), if technically possible - both ‘airquality.txt’ (from the local network download) and ‘airquality2.txt’ (from the Thingspeak cloud storage download) could be created/produced at regular intervals and possibly uploaded to the same directory where Weather Display normally uploads its data files (such as for example, ‘clientraw.txt’, etc.).

Having both PurpleAir data files produced and uploaded would allow PHP script developers to process that data and use it on web pages.

they can be both done (they are one at the same time, by the cronairquality.exe)
(one is airquality.txt the other is airquality2.txt)
that is how I have it now, with the latest .zip update

Brian, I just installed/updated the files (‘cronairquality.exe’ and ‘weatherdisplay.exe’) from the latest ZIP (2017-08-22 @ 02:11).

I think you might have misunderstood my previous message. What I was suggesting was that both PurpleAir data files (both ‘airquality.txt’ and ‘airquality2.txt’) be created simultaneously (at the same time) when a check mark is placed in front of the ‘Use local data (for 1.0 and 10.0 PM size data)’.

As I tried to explain, it is my thinking that the priority should be given to the PurpleAir data file downloaded from the Thingspeak cloud storage (the data file might only contain values for the PM2.5, but the data file also contains the PM2.5 values for both channels, so we have data backup for the PM2.5 in case something goes wrong with one of the channels of the PurpleAir unit) - this should be the default download when there is no check mark in front of the ‘Use local data (for 1.0 and 10.0 PM size data)’ - this mean that only the ‘airquality2.txt’ data file is created (this would become the default PurpleAir data file).

When there is a check mark in front of the ‘Use local data (for 1.0 and 10.0 PM size data)’, then, first, the PurpleAir data file is downloaded from the Thingspeak cloud storage, and then, second, the PurpleAir data file is downloaded from the local networked PurpleAir unit - this mean that both the ‘airquality.txt’ and ‘airquality2.txt’ data files are created.

If the weather station operator enters only the basic setting (ie: just the sensor ID and nothing else), then, by default, the PurpleAir data is downloaded from the Thingspeak cloud storage - this would create only the ‘airquality2.txt’ data file.

If the weather station operator enters additional settings (ie: the sensor ID + URL to local networked PurpleAir unit + check mark in from of ‘Use local data (for 1.0 and 10.0 PM size data)’), then, by default, the PurpleAir data would first be downloaded from the Thingspeak cloud storage and then, the PurpleAir data wouldl (second) be downloaded from the local networked PurpleAir unit - this would create both the ‘airquality.txt’ and ‘airquality2.txt’ data files.

they will get created at the same time
as long as you have ticked to use local IP and you have entered a sensor ID number

If the weather station operator enters only the basic setting (ie: just the sensor ID and nothing else), then, by default, the PurpleAir data is downloaded from the Thingspeak cloud storage - this would create only the 'airquality2.txt' data file.
that is now it works now
If the weather station operator enters additional settings (ie: the sensor ID + URL to local networked PurpleAir unit + check mark in from of 'Use local data (for 1.0 and 10.0 PM size data)'), then, by default, the PurpleAir data would first be downloaded from the Thingspeak cloud storage and then, the PurpleAir data wouldl (second) be downloaded from the local networked PurpleAir unit - this would create both the 'airquality.txt' and 'airquality2.txt' data files.
and yes this is how it is working now the only thing I need to do now is to compare the values and use the cloud data if the local data (if available) is out of range

Brian, I have to disagree with you as only one data file (ie: ‘airquality2.txt’) has been produced since I installed the latest test version of ‘weatherdisplay.exe’ (dated: 02:04:41 on 2017-08-22) - in my settings, I have entered the sensor ID number and I have placed a check mark in front of ‘Use local data (for 1.0 and 10.0 PM size data)’! :?

If I look at the creation time of both data files:

  • airquality2.txt - created/updated at 18:23:17 on 2017-08-22
  • airquality.txt - created/updated at 16:38:54 on 2017-08-22

Brian, first, can we agree (you and I) that the data downloaded from the Thingspeak cloud storage (using the sensor ID) will be the default data, meaning that this (the data downloaded from the Thingspeak cloud storage) will be the data (from either channel #2 or channel #2) that will be use by Weather Display to calculate the current air quality index.

As you indicated, from the data downloaded from the Thingspeak cloud storage, the PM2.5 value from channel #1 will have to be compared with the PM2.5 value from channel #2, making sure that neither value is smaller than 0 (zero) or greater than 500. If both PM2.5 values are close to each other, then the PM2.5 value of channel #1 will be used (to calculate the AQI). If there is a discrepancy between the two PM2.5 values, the smallest PM2.5 value should be considered the correct one (to calculate the AQI).

The data download from the local networked PurpleAir unit (when a check mark is placed in front of ‘Use local data (for 1.0 and 10.0 PM size data)’) should be in addition to the data downloaded from the Thingspeak cloud storage.

use this update to fix that
http://www.weather-display.com/downloadfiles/cronairquality.zip

No reason to feel victimized, you can get a 2.5/10 particulate counter suitable for lower temperatures, the e-bam, meets EPA and handles -30 Deg C to 50 Deg C. Starts around $20K.

Nikko Not sure where you get your info about Alaska Temps but we are talking about -40 and greater. I have talked to the local air quality guys in Fairbanks who uses these high price machines and they say the same thing. When the temps drop the data goes kaput as the machine can not do what they have to do when you need the data the most at -40 F, -50 F and -60 F. So why buy an 28K machine that also does not work. By the way Masters was a bit surprise when I mention the operating range to him.

John

John, I do not own (nor can I afford) one of those overly expensive air monitor… :roll:

But I am just so curious as to why an air monitor unit could not include some kind of pre-heater, where the freezing air could be slightly warmed up (without any kind of filtration) before entering the chamber where the laser (or whatever) sensors are located. The complete air monitoring unit could even be insulated to ensure that the temperature of the internal chamber be kept constant no matter how cold the external temperature is. :?

this update
http://www.weather-display.com/downloadfiles/weatherdisplaytest.zip

uses the cloud data for the 2.5 value, and if the first value found there is over 1000 (i.e out of range), then second value in that data is used for the 2.5 value

Brian, latest test update of Weather Display installed and running.

Notice, thought, that if I remove the check mark in front of ‘Use local data (for 1.0 and 10.0 PM size data)’, both data files ‘airquality.txt’ and ‘airquality2.txt’ are still created/produced/updated. For the time being, Brian, please, just leave the creation of both data files (‘airquality.txt’ and ‘airquality2.txt’) as it is…

Will contact you later on.

Okay, so I got the sensor and hooked it up but, I’m stuck trying to connect it to wifi as the instructions are not very clear on exactly how to do that. Any help would be appreciated. Thanks.

http://www.purpleair.com/configure

Also, what ID am I supposed to use here (PAII?)or do I just make one up?

2.Connect WiFi to a network called “AirMonitor_xxxx” where xxxx is specific to the sensor.
NOTE: The “AirMonitor_xxxx” network is only available while the sensor is not connected to WiFi.

Harry, welcome to the world of PurPleAir. :wink:

A few questions before I can give you any advice/assistance…

  • How familiar are you in setting up and managing an internal/local network?
  • Do you have an internal/local network set?
  • If you have a internal/local network set and functioning, what is your starting IP address (by default, the starting IP address is usually 192.168.0.1)?
    [li]If you have a internal/local network set and functioning, other than your computer, do you have any other computers or devices connected to the internal/local network?
    [/li]
  • Is that internal/local network managed by either a router and modem or by a combined all-in-one modem/router?

The reason I ask the above is that it was fairly easy for me to connect the PurpleAir unit to my WiFi network.

So, until I get some answers (mostly) about you knowledge of internal/local network and the type of equipment your network is using, I cannot and do not want to guess a reply… :?

Rob, thanks for the response. Unfortunately, my knowledge of networks pretty minimal.

  • Yes, I have an internal/local network.
  • The starting address sounds about right however, I couldn’t find it in the system summary page at 192.168.1.254.
  • I have lots and lots of stuff connected to the network, another computer, ipad, tablets, iphones, printer, smart TVs, you name it.
  • It is an AT&T Uverse 2Wire all-in-one modem/router with wifi all built in.