Author Topic: I need help to get my PWS dat from wundeground or weathercloud on my website  (Read 6201 times)

0 Members and 1 Guest are viewing this topic.

Offline zakhooi

  • Member
  • *
  • Posts: 19
Hi,

I have one simple question.
I'd like to have all data of my PWS on wunderground displayed on my personal website (without the need of a PC running).
I own a Alecto WS-5500 which can send it's data directly to Wunderground and Weathercloud without the use of a meteobridge.
So all I need is a template that allows me to read the data of my PWS from one of these two website and present it in a nice way.
I've checked out Saratoga, Meteotemplate, Cumulus and none of them seems to do what I'd like to have without the use of a meteobrigde.

Has anyone done this already? If so could you please direct me to the proper howto's to get there?
I guess I just need to read out the data using the wunderground API but I need templates that can do that.

Thanks in advance.
« Last Edit: April 06, 2019, 03:31:27 PM by zakhooi »

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
Hi,

I have one simple question.
I'd like to have all data of my PWS on wunderground displayed on my personal website (without the need of a PC running).
. . . shortened . . .
Has anyone done this already? If so could you please direct me to the proper howto's to get there?
I guess I just need to read out the data using the wunderground API but I need templates that can do that.
Thanks in advance.

This template does exactly what you want: https://www.wxforum.net/index.php?topic=36261.0
You do not need a weather-program, the data of your weather-station is loaded from WU as is the forecast if you want to use the WU forecast.
For the current data and the forecast you need a WU-API key which can be obtained from your WU device list when logged in at WU.

Success, if yo have questions or run into problems, just ask. But I am at Europe/Amsterdam time = UTC+2, answering can take some time based on your  timezone.

Wim



« Last Edit: April 06, 2019, 04:13:48 PM by wvdkuil »

Offline PaulMy

  • Forecaster
  • *****
  • Posts: 5519
    • KomokaWeather
In follow up to Wim's comment, I have now set up www.komokaweather.com/pws-wu to use my Weather Underground IONTARIO226.


Enjoy,
Paul



Offline zakhooi

  • Member
  • *
  • Posts: 19
I tried that before, but it shows 'offline' for quite some of the blocks:
https://pws.gravedecayband.com/
Yours is showing 'online' everywhere.

I though it didn't work for me, am I wrong?

The station is IALMEL1 by the way.

Offline PaulMy

  • Forecaster
  • *****
  • Posts: 5519
    • KomokaWeather
When I look at https://pws.gravedecayband.com/ everything seems complete. 

Enjoy,
Paul

Offline the beteljuice

  • the beteljuice
  • Forecaster
  • *****
  • Posts: 316
    • test site
All his station data 'updated' advisories show . Offline, although all his graphs are current.
Imagine what you will KNOW tomorrow !

Offline PaulMy

  • Forecaster
  • *****
  • Posts: 5519
    • KomokaWeather
Oops, I missed the fine print :oops:

Comparing the current data to the IALMEL1 WU station the data seems current so that part seems to be working. 

Enjoy,
Paul
« Last Edit: April 06, 2019, 11:38:20 PM by PaulMy »

Offline zakhooi

  • Member
  • *
  • Posts: 19
It’s not working. The forcast is from January and one of the blocks says update time is 17:17 a
None of the data is ok (hence the offline marker).
The only data that is correct is the time.
So why isn’t it working?

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
It’s not working. The forcast is from January and one of the blocks says update time is 17:17 a
None of the data is ok (hence the offline marker).
The only data that is correct is the time.
So why isn’t it working?
You have set the template to use "WeatherDisplay" as your data-source, probably you installed the standard version of the template, not the beta one. The datasource  is shown in the left corner in the footer (bottom).

Compare that with https://www.weerstation-herent.be/pwsWU/  which shows "WeatherUnderground"

You should
1. remove the current pws folder from your pws.gravedecayband.com website
2. Download the beta version from http://wd34.weather-template.com/beta.php
3. Redo your settings and select WeatherUnderground in easyweather-setup as your source, also add your API-key

I used your station-id IALMEL1  with  my WU-API key at https://www.weerstation-herent.be/pwsWU/

It loads the data for your station,
=> check:  https://www.weerstation-herent.be/pwsWU/w34_module_test.php
=> press left button second row it displays your station data {"observations":[{"stationID":"IALMEL1","obsTimeUt
BUT is  the data is correct ?
It displays all data in UTC not in local time for Almelo, but the obsTimeLocal is missing the Z
Code: [Select]
                    [stationID] => IALMEL1
                    [obsTimeUtc] => 2019-04-07T05:59:44Z
                    [obsTimeLocal] => 2019-04-07 05:59:44

So I had to set the time-zone  to London/UK and it displays the correct info, not off-line anymore

Conclusion:
There are two problems to solve
1. Use the beta version for WeatherUnderground until the normal release is available for WU also.
2. Find out why your weather-program is uploading the data with an UTC timestamp

Wim


Offline zakhooi

  • Member
  • *
  • Posts: 19

It displays all data in UTC not in local time for Almelo, but the obsTimeLocal is missing the Z
Code: [Select]
                    [stationID] => IALMEL1
                    [obsTimeUtc] => 2019-04-07T05:59:44Z
                    [obsTimeLocal] => 2019-04-07 05:59:44

So I had to set the time-zone  to London/UK and it displays the correct info, not off-line anymore


This is something I don't understand either, my data is two hours behind (with DTS since last week, before it was one hour behind). I've checked WU settings and my PWS settings and I even logged a ticket with Alecto be they said other dan the timezone setting the are not time settings (I can confirm no other settings are available). I've set the timezone to '1H' on the PWS which is the correct timezone for Amsterdam/Brussels according to the manual.
If you look at my historical data for my PWS on WU you will notice too. I've seen other stations using a WS-5500 with the correct timestamp. I don't know why this is happening.
You say you've changed the timezone, I'd like to know where and how to correct them as for me it's impossible on WU and on the WS-5500. This is my problem I think
I've done a complete powerdown, system reset (I also reset the station outside as well) but nothing helped.
I've configured the PWS also to upload the data to weathercloud: https://app.weathercloud.net/d2992490547#profile
And there it's also missing the last hour.

Please help as I really would like to see this working for me.
Thanks in advance.

btw, I've uploaded the new scripts to the webspace and indeed it shows proper data (only the timezone issue is left).
« Last Edit: April 07, 2019, 02:56:54 AM by zakhooi »

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
. . . shortened . . .
btw, I've uploaded the new scripts to the webspace and indeed it shows better data (still a lot shows 'offline').
It shows off-line as the data contains 2 hours "old" data.
Code: [Select]
[stationID] => IALMEL1
[obsTimeUtc] => 2019-04-07T06:45:04Z
[obsTimeLocal] => 2019-04-07 06:45:04
You and I know that  the local-time is incorrect, but the scripts do not.
To test your problem I reset the time zone in https://www.weerstation-herent.be/pwsWU/ to "Europe/London" and then the "off-line" is not shown anymore, but the correct (UTC) time as downloaded from WU is shown.

Quote
. . . Alecto be they said other dan the timezone setting the are not time settings (I can confirm no other settings are available). I've set the timezone to '1H' which is the correct timezone for Amsterdam/Brussels according to the manual.
When it is not a error-setting in your hardware, the cause of the problem is that your station was probably added after the move to the new dashboard. All dashboards display in the time column "00:04 undefined"
Mine   https://www.wunderground.com/dashboard/pws/IVLAAMSG47/table/2019-04-7/2019-04-7/daily
Yours https://www.wunderground.com/dashboard/pws/IALMEL1/table/2019-04-7/2019-04-7/daily
But at my station the data has the correct time, yours is the 2 hours off.
As we can not check the upload to WU, we have to assume that this error is at the WU side.

I will try to modify the script to have a correction-factor for the local-time.  But probably that will result in other errors between 22:00 CEST - 02:00 CEST.  But i will give it a try today.

Wim

« Last Edit: April 07, 2019, 03:08:48 AM by wvdkuil »

Offline zakhooi

  • Member
  • *
  • Posts: 19
You are right, my PWS was added on april 1st, so with the new dashboard.
I've spend quite some time on fiddling to get this all to work and nobody could see the real issue here with the timezone.
I'm glad you do.

I will try to modify the script to have a correction-factor for the local-time.  But probably that will result in other errors between 22:00 CEST - 02:00 CEST.  But i will give it a try today.
That would be great as that should be a proper workaround for my issue.

Thanks in advance

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
. . . shortened . . .
I will try to modify the script to have a correction-factor for the local-time.  But probably that will result in other errors between 22:00 CEST - 02:00 CEST.  But i will give it a try today.
That would be great as that should be a proper workaround for my issue.

Thanks in advance
It would not be necessary to modify the scripts as the data is already displayed correctly at your site.  The programmers at WU are still working on all these issues.

But I will add a correction factor so that we can cope with these kind of problems in the future.
Wim
« Last Edit: April 07, 2019, 03:34:04 AM by wvdkuil »

Offline zakhooi

  • Member
  • *
  • Posts: 19
Still, I think something is not working properly.
Like 'Huidige Situatie' still says 13 while it's over 20 by now.
Also 'binnen temperatuur' is empty even though I've enabled it in the settings.
So maybe, even though the timestamps of the blocks are current timestamps, the data it is showing might be of a different timestamp. Could you please verify whether this is the correct conclusion?
I'm a bit confused.
Thanks

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
Still, I think something is not working properly.
Like 'Huidige Situatie' still says 13 while it's over 20 by now.
Also 'binnen temperatuur' is empty even though I've enabled it in the settings.
So maybe, even though the timestamps of the blocks are current timestamps, the data it is showing might be of a different timestamp. Could you please verify whether this is the correct conclusion?
I'm a bit confused.
Thanks
So that all readers understand it, I switch to English https://pws.gravedecayband.com/index.php?lang=en
All parts have different refresh times so that not all blocks go to the webserver to update at the same time.
You can check all loads of data at the "debug console"  https://pws.gravedecayband.com/w34_module_test.php
Just click the "load files" button at the bottom of the menu.

Current Conditions => derived from Metar (or DarkSky) every so many minutes but the load files show
Code: [Select]
w34_load_files.php (59) METAR not loaded API=ADD YOUR API KEYTo get current conditions you need to request the Metar key as explained in easyweather setup
=> CheckWX Metar API KEY you need to sign up  => https://www.checkwx.com/signup

Indoor temp is not available with WU-data so you have to disable that in your settings.
You can check all data loaded also at the "debug console"  https://pws.gravedecayband.com/w34_module_test.php
For the calculated data, click "live-data values" button =>and it shows  indoor n/a
You can check the WU supplied data, with the second button on the left
=> select "./jsondata/wucom.txt" and click "list contents"
The data is shown in the bottom part, select "expand as json" for easy reading.

Success, Wim
« Last Edit: April 07, 2019, 09:39:21 AM by wvdkuil »

Offline zakhooi

  • Member
  • *
  • Posts: 19
It's getting really weird now.
I've added the METAR key (registered and requested) and disabled the indoor temperature.
However, it still shows indoor temperature block and current conditions is still wrong.
I checked the debug log and it still shows that indoor n/a but I'm 100% sure I changed that in the settings page (even re-loggin in on the settings page shows it has saved the changes).

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
It's getting really weird now.
I've added the METAR key (registered and requested) and disabled the indoor temperature.
However, it still shows indoor temperature block and current conditions is still wrong.
I checked the debug log and it still shows that indoor n/a but I'm 100% sure I changed that in the settings page (even re-loggin in on the settings page shows it has saved the changes).
Based on your settings, the indoor temp is not displayed in the temperature block.
So the setting works.
The "n/a" for not available was and is  correct. There is no indoor-temp in the WU-data.

Further down in your settings, you will find  the selections for which blocks should be displayed.  Check there what you want (and only display if you have those sensors)

Some users display an extra temp and use a slightly modified indoor temp-block for that.
That block can be displayed also for those who have no real indoor-temp sensor.

===
What is wrong with the METAR? 
This is the pop-up when you click on "Dichtbij" (Dutch for "Nearby")
https://pws.gravedecayband.com/metar_popup.php?script=currentconditionsWD_block.php

=== PLEASE check your settings. 
it seems you selected WD to be used for the current conditions.
Select the MTR current conditions and all will be well

Only you can see your settings. So check them carefully. I can only check the generated HTML to find these omissions and that is a waste of time.
 
Wim
« Last Edit: April 07, 2019, 12:31:59 PM by wvdkuil »

Offline zakhooi

  • Member
  • *
  • Posts: 19
Ok,
I think things are making more sense to me now.
So if I'm right, only the following blocks are read directly from my PWS (via WU): Temperature, Wind, Pressure, Rain and UV. All other blocks are read from other sources such as METAR, Wunderground (forecast), etc.
So the dashboard not only shows data from my PWS but other sources too.
Am I getting this right?

Regarding 'Current condition', I do understand clicking nearby shows proper data of the airport I've configured in settings.
However, the temperature showing in that block is different from what the 'nearby' popup says.
It's on 13 for the whole day already. That's why I thought something is wrong.

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
Ok,
I think things are making more sense to me now.
So if I'm right, only the following blocks are read directly from my PWS (via WU): Temperature, Wind, Pressure, Rain and UV. All other blocks are read from other sources such as METAR, Wunderground (forecast), etc.
So the dashboard not only shows data from my PWS but other sources too.Am I getting this right?
Yes, 1) WU, 2) other sources and 3) calculations by the scripts themselves, such as sun and moon information.
Quote
Regarding 'Current condition', I do understand clicking nearby shows proper data of the airport I've configured in settings.
However, the temperature showing in that block is different from what the 'nearby' popup says.
It's on 13 for the whole day already. That's why I thought something is wrong.
Only the first line, the icon and the description are used from METAR.
The other part start with: "This hour"  / "Dit uur" and it is a 1 hour forecast for the current/next hour.
In your case from WU.

Wim

P.S. Please correct your settings. I do not think Almelo is part of Brabant in Belgium.
So check the  meteoalarm code for your area. Change it from BE004 to NL016
« Last Edit: April 07, 2019, 03:06:11 PM by wvdkuil »

Offline zakhooi

  • Member
  • *
  • Posts: 19

I will try to modify the script to have a correction-factor for the local-time.  But probably that will result in other errors between 22:00 CEST - 02:00 CEST.  But i will give it a try today.


In the April 9th version of the script I could not find such a setting. Did I miss it or didn't you include it yet in this release? (the changelog didn't mention such a setting).


Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe

I will try to modify the script to have a correction-factor for the local-time.  But probably that will result in other errors between 22:00 CEST - 02:00 CEST.  But i will give it a try today.


In the April 9th version of the script I could not find such a setting. Did I miss it or didn't you include it yet in this release? (the changelog didn't mention such a setting).
I  answered that in https://www.wxforum.net/index.php?topic=36562.msg375781#msg375781
All date/times are correct on your site as this problem seems to be solved by WU.

So what is your problem that you need that?  Where is the data incorrect?

Please also include a link to your site: https://pws.gravedecayband.com/ either in your avatar or in your posts.

Wim

Offline zakhooi

  • Member
  • *
  • Posts: 19

So what is your problem that you need that?  Where is the data incorrect?


Well if you click on 'vandaag' in the temperature block it pops up a graph and in there you see the 2-hours-behind issue again. So I think the timestamp in de blocks are the timestamps the block was updated and not the latest timestamp in the graph.
I hope this clarifies the issue.

https://pws.gravedecayband.com

Online wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe

So what is your problem that you need that?  Where is the data incorrect?


Well if you click on 'vandaag' in the temperature block it pops up a graph and in there you see the 2-hours-behind issue again. So I think the timestamp in de blocks are the timestamps the block was updated and not the latest timestamp in the graph.
I hope this clarifies the issue.

https://pws.gravedecayband.com
But our times as displayed on the website are correct. This is the realtime data
Code: [Select]
Array( [observations] => Array ([0] => Array(
                    [stationID] => IALMEL1
                    [obsTimeUtc] => 2019-04-10T15:58:52Z
                    [obsTimeLocal] => 2019-04-10 15:58:52
                    [neighborhood] => Almelo
                    [softwareType] => EasyWeatherV1.3.1
                    [country] => NL
                    [solarRadiation] => 66.31
                    [lon] => 6.62599993
                    [realtimeFrequency] =>
                    [epoch] => 1554911932
                    [lat] => 52.33399963
                    [uv] => 0
                    [winddir] => 31
                    [humidity] => 34
                    [qcStatus] => 1
                    [metric] => Array
                        (
                            [temp] => 11
                            [heatIndex] => 11
                            [dewpt] => -4
                            [windChill] => 11
                            [windSpeed] => 4
                            [windGust] => 5
                            [pressure] => 1018.96
                            [precipRate] => 0
                            [precipTotal] => 0
                            [elev] => 11
                        )
 ) ))
It is their data-times in text format which are invalid as they assume you are in UTC.
So I use the correct epoch-time and the correct time-zone and discard the wrong text-times for the realtime data.
But when loading the .csv with the history (as used in the graphs) we have to accept the data as is as it is all text.

WU is constantly working on getting all errors out.
Please give them some time to iron out all problems.

Wim
You seem very unhappy. Not even clicked once a "like" button on the help in multiple answers you got.
I will for now stop answering the same question again and again.
« Last Edit: April 10, 2019, 12:16:04 PM by wvdkuil »

Offline zakhooi

  • Member
  • *
  • Posts: 19
I'm not unhappy, I'm just new to all this and need to ask questions.
I'm am grateful for all support like yours, sorry for not liking replies (I liked them just now).
I guess I have to wait for WU to solve this issue then.

Thanks again

Offline zakhooi

  • Member
  • *
  • Posts: 19
Sorry to bother you again @wvdkuil but I think I need to ask your support for one more time.
I know it's not necessary to have it running but I wanted to test it anyway, the use of mysql.
I've setup my database properly and it's accepting data successfully.
THe problem however is that two of the three cronjobs is failing.
I've setup the cronjobs properly (user 'php' is executing the scripts) and the 10 min script (w34_cron_stationcron.php) is putting realtime measurements succesfully in ./chartsmysql/result.csv.
However the two other scripts (w34_cron_empty.php and w34_cron_addtoyear.php) are not working.
I'm sure cron triggers those scripts (I've set it to confirm it my email) and I'm sure user 'php' has the proper rights to execute the scripts, but they fail..
w34_cron_addtoyear.php reports: Couldn not write headers to chartsmysql/2019_04.csv
w34_cron_empty.php does not clean result.csv and reports: success 1-2
The csv files as well as it's directory chartsmysql have write permissions to all users so that not the point either (otherwise none of the scripts would work).
The testscript w34_module_test.php does not give any clues.
Url: https://pws.gravedecayband.com/

Do you have any clue what the problem can be?

Thanks in advance for your help, I appreciate that.

Do you have

 

anything