Upgrade your "xyz" station with an extra GW1000 and some sensors

Based on this user request:
User has a fine weather-station which is not expandable.
Want to use extra sensors AirQuality, lightning, soil without buying a complete new station and scrapping the old one…
Wants to add an “inexpensive” GW1000/DP1500 with only the AirQuality-sensor and / or a lightning sensor.
And then those new sensors should be merged with the current upload.

First solution: Some weather-programs (MB, WD) support this
=> then for use with the PWS_Dashboard: extra-sensor ​upload https://pwsdashboard.com/documentation2012/36_extra_sensors.pdf

Second solution:
Most weather-programs can only use one weather-station.
The PWS_Dashboard always supported the lightning and UV data from an extra WeatherFlow station.
It now also supports a GW1000/DP1500 “custom upload” as a “second” data source for AirQuality and lightning

Example: Davis VUE uses weatherlink.exe upload. A DP1500 + 1 lightning sensor uses “custom-upload”
If needed one can even have two GW1000/DP1500 uploads, the first one for the main sensors, the second one for an AQ and or lightning sensor.

As soon as the “soon to be announced” soil-temp sensors are available, I will add support for those also.

TESTING:
Following scripts are changed:
PWS_livedata.php added code to use an extra ecowitt upload
PWS_easyweathersetup.php added the needed questions on the Devices tab
AQ_station_block.php to test the correct upload time

The lightning_station_small.php block uses the new data, but it needed no changes.

Wim

Edit 2021-04-18: rewrite of unclear text :oops:


ecowitt extra.zip (34.8 KB)

When taking care of another problem, a user with main station via WD-api also uses a separate upload for a lightning sensor

This is the result of the ecowitt upload logfile

Mon, 17 Jan 2022 10:43:10 +0000 = Ecowitt data received:

 Problem-90: Missing item in upload: tempf
 Problem-107: Invalid data: 
    [stationtype] => GW1000B_V1.6.8
    [dateutc] => 2022-01-17 10:43:09
    [tempinf] => 66.6
    [humidityin] => 50
    [baromrelin] => 30.106
    [baromabsin] => 30.106
    [lightning_time] => 1642413745
    [lightning_num] => 7
    [lightning] => 20
    [wh57batt] => 3
    [freq] => 915M
    [model] => GW1000_Pro

A full ecowitt-station upload should have the outside temperature which is sensor tempf in ecowitt naming convention.
If that sensor is not there=> big station problem => data should be discarded.

When there is only a lightning sensor to be uploaded there is no outside temp in the upload
So we have to reset the checking for tempf and change that to a sensor which we really want to have, lightning

Modify . . ./pwsWD/ecowitt/index.php lines 4-6 from

$always_exists  = 'tempf';              # this field should always be in the data ! 
$filter_value   = 0;                    # if above field contents equals the filter value the upload is rejected
#$filter_value   = false;               # remove comment mark if no contents checking is done on the field

to

$always_exists  = 'lightning';              # this field should always be in the data ! 
$filter_value   = 0;                    # if above field contents equals the filter value the upload is rejected
$filter_value   = false;               # remove comment mark if no contents checking is done on the field ​

We changed on line 4 the sensor which should be checked.
And on line 6 we removed the comment mark # so that value checking is not done.

Wim

FYI The numbers in an error message mostly refer to the line in the script.
Problem-90: Missing item in upload: tempf => line 90 checked the item which should be there
Problem-107: Invalid data: => line 107 logged the complete data set which was rejected.

Ecowitt users will see this in their ecowitt log every time a GW1000 is reset after firmware upgrade or battery failure.
So those messages are not important if it is happening now and then.
If you get those messages multiple times f.i. during night-time, check the batteries.

Hi Wim. Here is result of https://lentfoehrden-wetter.de/ecowitt/ecco_stats.txt , two lines 4,6 were changed. Third pic is a test.php. What is wrong? Thanks


There will always be random upload errors once or twice / day
As far I can see the uploaded file is OK
https://lentfoehrden-wetter.de/PWS_listfile.php?file=ecowitt/ecco_lcl.arr&type=arr
The timestamp is in UTC

    [stationtype] => GW1000B_V1.6.8
    [dateutc] => 2022-01-18 11:29:53
    [tempinf] => 68.7
    [humidityin] => 51
    [baromrelin] => 30.481
    [baromabsin] => 30.481
    [lightning_time] => 
    [lightning_num] => 0
    [lightning] => 
    [wh57batt] => 3
    [freq] => 915M
    [model] => GW1000_Pro

Hi wim. Did everithing as discribed, second solution. Still doesnt work, eny idea why? Thanks


Screenshot 1: The location CAN NOT be an http address.
You are talking on the PHP level, not on the browser address level.

Screenshot 2: Correct, normally we use ./ecowitt/eccolocal.arr

Screenshot 3: Is correct.
Please check the uploaded data: . . ./PWS_listfile.php?file=./ecowitt/ecco_lcl.arr&type=arr

    [stationtype] => GW1000B_V1.6.8
    [dateutc] => 2022-01-19 10:42:08
    [tempinf] => 68.4
    [humidityin] => 51
    [baromrelin] => 30.023
    [baromabsin] => 30.023
    [lightning_time] => 
    [lightning_num] => 0
    [lightning] => 
    [wh57batt] => 3
    [freq] => 915M
    [model] => GW1000_Pro

The lightning-device exists and the data is received and uploaded by the gw1000
The lightning-device did not register any lightning yet.
=> all values are zero.

And in computer terms, the date-time with the value zero = 19700101T000000 UTC
Januari 1st at midnight UTC time.

New lightning data it is displayed in the blocks.
As the GW1000 can be reset (power failure or new firmware) the latest value of the lightning is saved in the history file.

So we have to wait until there is lightning displayed.

Use the ws-view app on your phone/tablet and check the values of your GW1000.
There would be an problem if the ws-view app showed different data for lightning.

Wim

Thanks a lot, have a great day !