HWS-template (WD34) July version available

Don’t forget to let us know next time there’s a “happening”, Wim :smiley:

I need the URL to your WD34 website to check what is happening. Without that I can not do anything.

Wim

Thanks folks & Wim for the camera advice.

I now have it working. Blue Iris is uploading a jpeg every 30 seconds to my website for my backyard camera. It’s fairly uninteresting but, hey, it works!

Last night, while trying to get it to work, an adolescent skunk walked onto the patio. My wife and I watched it rooting for insects. I’m glad I didn’t step outside just then for a smoke break :smiley:

I’m playing with the text colors on the image, trying to get a good day/night readability mix.

Appreciate it,
Mort

https://www.m82a1.us/pwsWD/index.php

Poslato sa SNE-LX1 pomoću Tapatoka

You are using WeatherUnderground which is very unreliable the last months.
So, yes it can happen that there is no month or year data.
This is the link for your month data:
https://www.wunderground.com/weatherstation/WXDailyHistory.asp?ID=ISERBIAK2&graphspan=month&year&month&format=1

At this moment it returns an empty file.

Readme: http://wd34.weather-template.com/documentation/WD34-questions-2019-07.pdf
=> Historical data: Use WU or your webserver
At time of writing it is still not clear if WU will allow us to continue to use the .CSV files of our data.
You can select to store the weather-data on the webserver, you need to run the station-cron then also.

Wait a few days to see if it improves. otherwise switch to store your own data for the graphs.

Wim

How about:

%maxavgspd% …maximum average wind speed
%maxavgspdt% …time this occurred

Searching the tagslist file is a nightmare: e.g. Find “dewpoint” only returns one result, but there are a lot of “dew point” entries :?

I saw those as well. I’m not sure if I want to use averages. I would prefer to use actual readings.

Template uses clientraw 113 ( max average wind speed) for “max wind speed”. . . see w34_livedata.php

I was just looking through clientrawdescription.txt and don’t see “%maxavgspdt% …time this occurred” . I must be blind…

%maxavgspdt% is there in the clientrawdescription
open that file with notepad
then use the find function

I think you mean taglist.txt?

Nope
clientrawdescription.txt
Its in C:\wdisplay

We’re all at cross purposes here: I’m talking about tagslist.txt, which shows the tags I mentioned. I use these in customtext.txt to get extra data for w34 template.

Brian is talking about tags in clientrawdescription.txt but, as niko says, he means tagslist.txt.

Blainec is looking at clientrawdescription.txt, which does not show tags at all.

Quite happy to share the code for using tags in customtext in w34 if it would be of interest.

I would live to see the code you use.
Can you email it to me?

Don’t think Wim will mind if I do it here, others might be interested.

Build your WD customtext.txt file with all the tags you want and get the resulting customtextout.txt uploaded to the same place as clientraw.txt (for simplicity). Then edit w34_livedata.php:


#  load clientraw
    $file_live      = file_get_contents($livedata);
    $wd             = explode(" ", $file_live);
#  load customtextout
    $file_live2 = file_get_contents('../customtextout.txt');
    $customtext = explode(" ", $file_live2);

The first three lines (101-3) already exist, just add the next three and then you can define the data from your tags like so:


	$weather["barometer_max"]       = convert_baro ($wd[131],$from,$to);
	$weather["barometer_max_time"]  = $customtext[10];   # tag %highbarot% - was 'n/a'; # clientrawextra 799
	$weather["barometer_min"]       = convert_baro ($wd[132],$from,$to);
	$weather["barometer_min_time"]  = $customtext[9];    # tag %lobarot% - was 'n/a'; # clientrawextra 800

or


        $weather['temp_garden']         = convert_temp ($wd[20],$from,$to);
		$num			= heatIndex($wd[20], $wd[26]);
	$weather['temp_garden_feel']	= convert_temp ($num,$from,$to);
	$weather["temp_garden_low"]     = convert_temp ($customtext[0],$from,$to);	# tag %wmr918/68extratemplow%
	$weather["temp_garden_high"]    = convert_temp ($customtext[2],$from,$to);	# tag %wmr918/68extratemphigh%
	$weather["lowgtemptime"]        = $customtext[1];	# tag %wmr918/68templowtime%
	$weather["maxgtemptime"]        = $customtext[3];	# tag %wmr918/68temphightime%

where I have renamed Wim’s $weather[‘extra_tmp1’] and added a few extra things (some of which have not made it to the /pwsnew/ version yet but can be seen at the original url, as left).

If I was starting out afresh I’d choose a shorter name for the array than $customtext - means less typing :slight_smile:

Using a customtextout.txt file seems more efficient than “exploding” clientrawextra.txt for a few extra items.

P.S. The tag %rainlasthourmm% (or imperial equivalent) is useful, it means “rain last hour” isn’t shown as “negative rain yesterday” just after midnight:


#	$value                          = (float) $wd[109] - (float) $wd[100];  # 2019-01-14 -21
#	$weather["rain_lasthour"]       = convert_precip ($value ,$from,$to);   # 2019-01-14
	$weather["rain_lasthour"]       = convert_precip ($customtext[8],$from,$to);	# tag %rainlasthourmm%

Hi!
Have switched to using WDapi, See that there are a couple of errors in the file.
It’s about last hour’s rainfall, having the same value as today rain.
and 10 minutes of average wind has the same value as the last 10 minutes of wind direction.
Is uncertain whether avg wind as displayed is 10 minutes avg wind?

                                -- [40] => --
                             SOLAR [41] => 292.0
               avg ten minute wind [42] => 330
        rain total last 60 minutes [43] => 4.2
                                -- [44] => --
                                 0 [45] => 1
                                -- [46] => --

10 avg wind direction last ten minutes [47] => 330
– [48] => –

Link http://regnskvett.com/pwsWD/

Torjan

Yes, there are some improvements needed and also additional fields f.i. soil/moist.
But that is true for other weather-programs / upload files also.
I postponed that to the 2019-12/2020-01 version as I thought it was far more important to get the scripts error-free and user-maintainable.

FYI I attach all documentation about the API I have so far.
The fields such as +avtenwinddir+ are the internal WD field-tags, not the tags as used in templates a.s.o.

Wim


wd-descriptionapi.txt (2.72 KB)

WDapi_fields.txt (1.05 KB)

Working.
However, I had to change it to comma delimited file do to a space between time and AM/PM

Thanks very much

Hi!
What I can see is that precipitation last hour and average wind is wrong otherwise it looks okay. Good idea and get soil info in the package.
I now have clientraw as live data with charts from chartsmydata, it seems to work, I think.
Must let it roll for a few days to see if everything is ok.

Torjan

Is there not a join() function somewhere that could have put them back together? Say, if $str1 was time and $str2 was AM/PM, then


$str3=join(" ", $str1,$str2)

You’ll have to ask a better programmer than me :slight_smile: