Welcome to the Cumulus Support forum.

Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024

Cumulus MX V4 beta test release 4.0.0 (build 4018) - 28 March 2024

Legacy Cumulus 1 release v1.9.4 (build 1099) - 28 November 2014 (a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)

Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki

Ambient Weather WS-2902A

A Forum to archive Cumulus MX development suggestions that have been rejected or solved by other means.
User avatar
mcrossley
Posts: 12691
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Ambient Weather WS-2902A / WS-2902C

Post by mcrossley »

Hunter362 wrote: Sun 08 Aug 2021 1:11 am I'm looking at the WS-2902C as a replacement for my current WS-2080 which has served me faithfully for 10 years now.
Is it easier / better to use the GW-1000 I see you guys talking about? or are you sending the data via the console to ambientweather, then your pulling it back via the API to update your own site? I think I'm lost here?
The GW-1000 would plug into the computer like my current setup, pick up the data from the sensors and MX would pull it directly the way it currently is now from the WS-2080 console, correct? This sounds like the way to go then.

Thanks
Bill
Cumulus pulls the data direct from the GW1000, it cannot pull from AmbientWeather.com

The GW1000 connects via WiFi, it does not have to be plugged into your computer - it just uses the USB connector for power.

The next release of Cumulus MX will have direct (possibly experimental) support for newer Ambient consoles that have the ability to configure a Custom upload server.
User avatar
Trasd
Posts: 3
Joined: Wed 06 Jan 2021 12:11 pm
Weather Station: Ambient Weather WS-2902c
Operating System: Windows 10

Re: Ambient Weather WS-2902A / WS-2902C

Post by Trasd »

mcrossley wrote: Mon 09 Aug 2021 8:11 am The next release of Cumulus MX will have direct (possibly experimental) support for newer Ambient consoles that have the ability to configure a Custom upload server.
Any info on this feature? I noticed Ambient added a new screen to its setup - a "Customized" server. As I'm not totally internet protocol literate, I don't know if this helps those of us with the WS-2902(C).

Here is some of the fields that can be filled in:

Protocol Type Same As: Ambient Weather, Wunderground
Server IP / Hostname :
Path : /weatherstation/updateweatherstation.php?
Station ID:
Station Key:
Port: 80
Upload Interval: 60 Seconds
"Any sufficiently advanced technology is indistinguishable from magic." A.C.C.

"I'll tell you this, no eternal reward will forgive us now for wasting the dawn." J.M.
User avatar
mcrossley
Posts: 12691
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2/WLL
Operating System: Bullseye Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Ambient Weather WS-2902A

Post by mcrossley »

Yes, that feature was added quite some time ago. The station type is HTTP Ambient - from memory.

Select that station type in the config and it will tell you how to configure the console.
User avatar
Trasd
Posts: 3
Joined: Wed 06 Jan 2021 12:11 pm
Weather Station: Ambient Weather WS-2902c
Operating System: Windows 10

Re: Ambient Weather WS-2902A

Post by Trasd »

mcrossley wrote: Tue 19 Jul 2022 6:58 pm Yes, that feature was added quite some time ago. The station type is HTTP Ambient - from memory.

Select that station type in the config and it will tell you how to configure the console.
You are a scholar and a gentleman, Mark!

Really, thank you for adding the support.
"Any sufficiently advanced technology is indistinguishable from magic." A.C.C.

"I'll tell you this, no eternal reward will forgive us now for wasting the dawn." J.M.
User avatar
mstrandbo
Posts: 28
Joined: Wed 26 Dec 2012 12:42 pm
Weather Station: WS-2902
Operating System: Ubuntu 22.04
Location: Norway

Re: Ambient Weather WS-2902A

Post by mstrandbo »

I've had a WS-2902 since release, and wanted to use Cumulus since I was already using it. Didn't care for ambientweather's user interface and presentation.
Since it only delivered the data to their own website (and WU, WeatherCloud), I ended up using their API to extract the data needed, converting some numbers and putting them into a easyweather.dat-file.
Using a powershell script that runs every minutes to fetch and convert the latest data. Been working great with Cumulus1 for the last ... 4 years? Can't remember when I bought the station now.
Recently I migrated ovewr to using CumulusMX, and since it's the same "source" - the easyweather.dat-file, it it was a painless migration.

As for now I'll let it run as it is, it works after all, but I did try to capture the packets from the WS-2902, and it is indeed sending all the information to api.ambientweather.net in cleartext, so I'm thinking in the future I will just capture the packets with the data locally and just forgo the api alltogether.
Image
vr34
Posts: 32
Joined: Wed 13 Jan 2010 12:43 pm
Weather Station: Bresser WLAN 7-in-1 (7003300)
Operating System: Raspberry OS Bullseye, CumulusMX
Location: South of France

Re: Ambient Weather WS-2902A

Post by vr34 »

Hello mstrandbo and Cumulus community,

I recently changed my PWS. My new one is a Bresser 7-in-1 wifi. As yours, my PWS is not in the supported devices list of Cumulus MX.
Thus I added it to WU (stationID = ILESMA30) and made a short python3 script to convert the api.weather.com JSON file to an easyweatherplus.dat file.
My Cumulus MX is installed on a Raspberry. I set crontab to execute my script every minute (* * * * *) to update the dat file.
Here is the py script :

Code: Select all

# -*- coding: utf-8 -*-
# script pour extraire les valeurs de 
# https://api.weather.com/v2/pws/observations/current?stationId=***&format=json&units=m&apiKey=*****

from urllib.request import urlopen
import json

rose = ["N","NNE","NE","ENE","E","ESE","SE","SSE","S","SSW","SW","WSW","W","WNW","NW","NNW","N"]

f = urlopen("https://api.weather.com/v2/pws/observations/current?stationId=ILESMA30&format=json&units=m&apiKey=#####
chain = json.load(f)
#codeStation = chain["observations"][0]["stationID"]
chainDateTime = chain["observations"][0]["obsTimeLocal"]
chainDateTime = chainDateTime.replace(" ",",")
outdoorHum = chain["observations"][0]["humidity"]
outdoorTemp = chain["observations"][0]["metric"]["temp"]
dewPoint = chain["observations"][0]["metric"]["dewpt"] # point de rosée
windChill = chain["observations"][0]["metric"]["windChill"] # refroidissement éolien
pressure = chain["observations"][0]["metric"]["pressure"]
windAverage = chain["observations"][0]["metric"]["windSpeed"] # vitesse moyenne du vent
windGust = chain["observations"][0]["metric"]["windGust"] # rafale de vent # Cumulus displays huge unconsistant windgust far from windGust from this JSON. Why ?!??? 
windDirection = chain["observations"][0]["winddir"] # en degrés
windDirectionText = rose[round(int(windDirection)/22.5)]
rainTotal = chain["observations"][0]["metric"]["precipTotal"] # pluie depuis 00:00 (correct? to be verified)
rainLastHour = chain["observations"][0]["metric"]["precipRate"] # pluie / heure = taux de pluie (correct? to be verified)
lightReading = int(126.6 * float(chain["observations"][0]["solarRadiation"])) # en lux (=lumen/m2)
UVindex = chain["observations"][0]["uv"]
easyweatherplus = "0,0,0," + chainDateTime + ",0,0,0," + str(outdoorHum) + "," + str(outdoorTemp) + "," + str(dewPoint) + "," + str(windChill) + ",0," + str(pressure) + "," + str(windAverage) + ",0," + str(windGust) + ",0," + str(windDirection) + "," + windDirectionText + ",0,0,0," + str(rainLastHour) + ",0,0,0," + str(rainTotal) + "," + str(lightReading) + "," + str(UVindex) 
#print (easyweatherplus)
f = open("/home/pi/CumulusMX/easyweatherplus.dat", "w")
f.write(easyweatherplus)
f.close()
You just have to:
- change the code line starting from "f = urlopen..." with your station ID and API key
- crontab -e to edit the cron tasks list. Add the new line " * * * * * python3 /<path>/<name of the py script> "
- configure the station settings in Cumulus MX. 1) in General Settings: Station type: EasyWether, Log interval: 1 minute ; 2) in EasyWeather File Settings: the full path and name of the py file.
- if your PWS can measure light intensity and UV level, check Extra sensors in Common Options.

Cheers
vr34

EDIT: script Python corrected. Post updated 2022/11/03. Everything ok excepted windgust
Post Reply