So how have other people gotten it up and running? Should there be a wiki page with more explicit instructions?
I'm also willing to post my patches if people are interested. Mostly they are to get the graphs working and to enable the wind rose in WeeWX-WD.
If you want to look at what I've done, my site is at http://www.lapseofthought.com/Weather/.
Would appreciate any info on the things that are just plain broke. Can be raised as in issue on bitbucket or posted here if you wish.
Gary
- The instructions aren't all that specific. I'm a sysadmin by day so used to digging around to figure out how to do things, but it took quite a bit of playing to figure out how to get the templates installed and working.
- Out of the box, there are more than a few things that don't work in the Saratoga templates. I've gotten my graphs and wind rose on-line now, but have others fought this same battle and just not mentioned it? I found one or two messages that mentioned problems but that's about it.
As vds mentioned, there are a lot of assumptions made in the instructions about your familiarity with the software. I still didn't know what clientraw and testtags were for until I started digging into the Saratoga php code. The instructions themselves are straight forward enough (although I initially created a user subdirectory in $BIN_ROOT/user, just reading it as copy the bin folder to $BIN_ROOT/user).
It actually took me a while to realize that "WD" was "Weather Display" and that was the version of the Saratoga templates I should download. That was probably the most confusing part for me. It also wasn't clear initially that the Saratoga files (I really shouldn't call them templates since they are just php code) get dumped into the HTML_ROOT, not into the skins directory. Once you know how everything works it makes sense, but it's not a good place for a beginner to start.
How hard would it be to integrate with the weewx setup.py extension installer (not sure how ugly that is to integrate with, I've only used it once).
One thing that might be nice is knowing that you can omit HTML_ROOT altogether if you want this to be your default template.
As for the errors I ran into, let me write those up a bit later, I have to head out to catch the train home.
---
Dan Rich <dr...@employees.org> | http://www.employees.org/~drich/ | "Step up to red alert!" "Are you sure, sir? | It means changing the bulb in the sign..." | - Red Dwarf (BBC)
I've done some editing on the original Saratoga code as well, I'm going to chat with the maintainer and see if he's interested in collaborating on a WeeWX-WD "version" of the templates. I've chatted with him in the past, he and I had shared some ideas at one point about what I was doing with wview (and we only live 20 minutes away from each other after all! :-)
For my site I went ahead and added a WeeWX type in the code so I could get the correct windrose and other graphs. I'm not a big fan of the WD graphs anyway. I find them really hard to read.
The more I think about the documentation issue, the more I think it's just an "assumptions" issue rather than a problem with the docs. I think if it had been clear that WeeWX-WD isn't really a skin but a framework for other skins, most of my confusion wouldn't have happened in the first place.
---
Dan Rich <dr...@employees.org> | http://www.employees.org/~drich/ | "Step up to red alert!" "Are you sure, sir? | It means changing the bulb in the sign..." | - Red Dwarf (BBC)
--
You received this message because you are subscribed to the Google Groups "Weewx user's group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
**** Traceback (most recent call last):
**** File "/home/weewx/bin/weewx/cheetahgenerator.py", line 274, in generate
**** print >> _file, text
**** File "/usr/lib/python2.7/dist-packages/Cheetah/Template.py", line 1005, in __str__
**** rc = getattr(self, mainMethName)()
**** File "_home_weewx_skins_Clientraw_customclientraw_txt_tmpl.py", line 593, in respond
**** NotFound: cannot find 'SkinVersion' while searching for 'Extras.SkinVersion.Version'--
You received this message because you are subscribed to the Google Groups "Weewx user's group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
-- Dan Rich <dr...@employees.org> | http://www.employees.org/~drich/
--
You received this message because you are subscribed to the Google Groups "Weewx user's group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
-- Dan Rich <dr...@employees.org> | http://www.employees.org/~drich/
[Extras]
[[SkinVersion]]
#SteelGauges Version Control String
Version = 11
Yes there is, it's setup in the file ajaxWDwx.js which should be in the folder with all your other Saratoga files. There are a couple of settings early on that cover how often it refreshes and for how long it auto refreshes. Think there is also something in Settings.php that sets the ajaxXXwx.js file to use. Not 100% on these as I am away from my PC.
That being said though, the present weewx-wd architecture is a little limited as the clientraw and testtags files are only generated every archive period. In simple terms, testtags.php contains the data to populate the Saratoga pages and clientraw.txt contains the info to dynamically update certain fields on the Saratoga dashboard (main page). If clientraw.txt is only generated every 5 minutes then updating from it every 10 seconds is not going to do much. If your autoupdating is working you may well see some info changing colour in the top right of the page but as the autoupdate only updates fields that have changed, you will likely not see any activity elsewhere on the page.
I do have a service running that binds to loop records and generates a clientraw.txt manually. It's still rather clunky but works. Probably something we will take forward when we see how multi-database weewx goes - expect that will result In a lot of changes for weewx-wd.
Gary
Gary,
Isn't that just the timing for the ajax data refresh? From a quick look at the page source, it will reload the clientraw data which should refresh the data on the page, but won't refresh any images (such as the thermometer) or other content. Unless there is some javascript somewhere that I didn't find yet that also forces a page refresh periodically. Every 10 seconds is somewhat pointless with WeeWX since it only updates the files every 5 minutes... I just updated mine to every 30. I tried going for every minute (60000), but it completely stopped updating -- I'm wondering if it's a signed short internally in javascript so can't be greater than 32767 (no time to play with numbers this morning to debug it).
Looking at my logs, I do see it pulling clientraw.txt every 30 seconds, but updated time on the page never changes. I think the data may be changing, but it's hard to tell since there is such a minor change from update to update -- even with the flash I don't see anything change.
If you want a full page refresh I think you're going to have to put a meta tag into the Saratoga top.php file. I was playing around with it last night, and added this right after the '<meta name="description"...' line:
<meta http-equiv="Refresh" content="300" />
That would cause your browser to reload the page every 5 minutes.
As an added bit of fun, I put in some code that expires my banner image every 15 minutes. I auto-generate that from a webcam up at Lick Observatory on Mt. Hamliton, so it seems a waste to not force it to update when the page refreshes! :-)
---
Dan Rich <dr...@employees.org> | http://www.employees.org/~drich/ | "Step up to red alert!" "Are you sure, sir? | It means changing the bulb in the sign..." | - Red Dwarf (BBC)
Isn't that just the timing for the ajax data refresh? From a quick look at the page source, it will reload the clientraw data which should refresh the data on the page, but won't refresh any images (such as the thermometer) or other content. Unless there is some javascript somewhere that I didn't find yet that also forces a page refresh periodically.
Every 10 seconds is somewhat pointless with WeeWX since it only updates the files every 5 minutes... I just updated mine to every 30. I tried going for every minute (60000), but it completely stopped updating -- I'm wondering if it's a signed short internally in javascript so can't be greater than 32767 (no time to play with numbers this morning to debug it).
Looking at my logs, I do see it pulling clientraw.txt every 30 seconds, but updated time on the page never changes. I think the data may be changing, but it's hard to tell since there is such a minor change from update to update -- even with the flash I don't see anything change.
If you want a full page refresh I think you're going to have to put a meta tag into the Saratoga top.php file. I was playing around with it last night, and added this right after the '<meta name="description"...' line:
<meta http-equiv="Refresh" content="300" />
That would cause your browser to reload the page every 5 minutes.
As an added bit of fun, I put in some code that expires my banner image every 15 minutes. I auto-generate that from a webcam up at Lick Observatory on Mt. Hamliton, so it seems a waste to not force it to update when the page refreshes! :-)
You wouldn't have seen the image change last night, I had pulled out the meta tag for the refresh while I was playing with the ajax code. Gary is right, there is a camp in the web world who is violently opposed to meta refresh tags (with reason, ajax is a much better way to go).I would much rather do it with ajax, if I have time I'll play with that a bit tonight when I get home.
There's no reason I can't hack some code into the page to refresh the image as well -- in my copious free time...
I really need to get my barometer sensor fixed and relocate my station first so the rain gauge works again (the poll it is on has bent so I don't get any readings currently). Being in northern California, I don't have to worry about rain 'til sometime in Oct or Nov anyway. :-)
---
Dan Rich <dr...@employees.org> | http://www.employees.org/~drich/ | "Step up to red alert!" "Are you sure, sir? | It means changing the bulb in the sign..." | - Red Dwarf (BBC)
--
There is a pair of patches -- one to add the graphs to the graph page, and one to enable the windrose. Let me look those up when I get home tonight. I've been working a P1 outage here at work for the past 4 hours so won't have time to dig up the data 'til I get home.
---
Dan Rich <dr...@employees.org> | http://www.employees.org/~drich/ | "Step up to red alert!" "Are you sure, sir? | It means changing the bulb in the sign..." | - Red Dwarf (BBC)
--
You received this message because you are subscribed to the Google Groups "Weewx user's group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
-- Dan Rich <dr...@employees.org> | http://www.employees.org/~drich/
I went ahead and pulled out my meta refresh, fixing the clientraw path (just removing the leading / since it is in the same directory) got the data refreshing going. That might be a good tip to have in the wiki, I'm not sure I ever would have thought of that!
I'll look at the thermometer code when if I get some time later this evening. I don't really want that reloading every 30 seconds, the temperature had better not be changing that fast! :-) I'm sure I can leverage the same code for reloading my header image.
Thanks again for the pointers!
After you restart weewx it should generate daywindrose.png the
next time it runs. You may have to tweak WD-trends-inc.php to
point it to the right place to find where the generator puts the
image (I have everything in the same directory).
-- Dan Rich <dr...@employees.org> | http://www.employees.org/~drich/
Now to get the lightning counter showing up and there is an issue with my owfs driver in regards to rain rate.