Can wview still archive without the datalogger for Davis Vantage Vue?

287 views
Skip to first unread message

Tyler

unread,
Sep 17, 2011, 9:51:34 AM9/17/11
to wview
First off, allow me extend a huge appreciation towards Dekay and his
blog at <a href="http://www.google.com/url?sa=D&q=http://
madscientistlabs.blogspot.com/2011/01/alternative-davis-vp2-
console.html&usg=AFQjCNHV1PFsBxk6-efBWSyI2XSAuVOVHQ">Madscientist Labs
at blogspot</a>. I am a senior meteorology student at Texas A&M
University, and absolutely love my Vantage Vue, but there was no way I
could justify to myself spending another $150 for a piece of silly
hardware. With his directions and guidance, I was successfully able to
build an interface that is working fantastically! Big round of
applause. Secondly, thank you Mark Teel for developing such a solid
software to do all the grunt work, and for free. I can not appreciate
it enough. Once again, software was gonna be another big hit in the
pocket book, and building open source software to do this for me was a
huge help. Ok so enough with the sucking up (No seriously though,
thanks).

Wview is doing a superb job of reading the current conditions and
building html/images, FTPing and all that good stuff. You can view the
site at <a href="http://www.tantonweather.com/
wview">www.TantonWeather.com</a>. However, it is not building the
charts, or as far as I can tell, anything that would rely on the
archive. After playing with sqlite3 and digging further, I cannot see
where the archive is working at all. They syslog is also giving me the
classy "vproRunState: retrying archive record..." error. Now, it
should be noted, that the interface I use is a home built interface,
NOT the davis datalogger. It communicates great with the device, but
does not have an archive buffer between the console and my computer. I
understand the reasoning for having it etc. But my main goal is have
my home server just digest the data 24/7 and build that archive.

Is there anyway to tell wview to stop looking for the archive, and
simply build its own from scratch using just the current conditions?
From what I've read, this is what wview does with some of the other
stations that lack a logger. That would be ideal for my application.
Any help at all would be greatly appreciated. Thanks!

Wowzer

unread,
Sep 17, 2011, 1:40:10 PM9/17/11
to wview
I've been playing around with the non-archiving data logger too,
http://www.wxforum.net/index.php?topic=12432.0 . I can say that it
works well in both Linux and Windows. My main setup does use the Davis
USB data logger and an Envoy.

I'm building a replacement laptop, which is what I've been using for
testing. I noticed last night that the current condition graphs update
but that the historical graphs were not updating, just as you have
noticed.

I suspect a some modifications to vproInterface.c would be needed to
turn of the searching for archive records. Maybe then htmlgend would
continue with building graphs. Any data loss between the PC and
console will leave gaps in the chart lines.

That is my 2¢.

David

Tyler

unread,
Sep 18, 2011, 1:00:29 PM9/18/11
to wview
I plan to search through the vprointerface.c and compare it to that of
the other interfaces for consoles that don't have a logger and see if
I can mend it. I have a fair understanding of coding etc... BUT, do
you know if the vprointerface.c only get referenced when wview is
built or configured or upon opening the program? Right now the only
file of such that I could find was in the /usr/src directory, which
I'm not sure if its accessed by the program when ran. Maybe I will
have to rebuild and install the program after adjusting the
vprointerface.c

On Sep 17, 12:40 pm, Wowzer <davidba...@gmail.com> wrote:
> I've been playing around with the non-archiving data logger too,http://www.wxforum.net/index.php?topic=12432.0. I can say that it

Wowzer

unread,
Sep 18, 2011, 10:15:17 PM9/18/11
to wview
Tyler,
I got it to work with two line changes and a recompile.

I install wview from the APT package, as usual. I downloaded the
latest source to my home directory. I ran "./configure --prefix=/ --
bindir=/usr/bin --sysconfdir=/etc --localstatedir=/var/lib --libdir=/
usr/lib" to set up the paths to match the APT package. From there "cd
stations/VantagePro" then make the changes below.

File: vproInterface.c

Change line 107 from:
work->stationGeneratesArchives = TRUE;
to:
work->stationGeneratesArchives = FALSE;

Change line 1008 from:
(*ArchiveIndicator) (&archivePkt);
to:
(*ArchiveIndicator) (NULL);

In the same directory I ran "make", no reason to compile the whole
app.

I copied the new wviewd_vpro over the existing /usr/bin/wviewd_vpro
file after making a backup of it.

Logs went from:
Sep 18 18:57:45 updraft wviewd[17916]: <1316390265850> :
vproRunState: retrying archive record...
to:
Sep 18 20:35:04 updraft wviewd[22218]: <1316396104761> : storing
record for 2011-09-18 20:35

The historical graphs are updating every five minutes as expected.
Since this is on my test machine I do not have the generated files
published for you to see.

If the plan is to run long term just remember that the same steps will
need to be followed for each new version. Maybe if enough people build
or buy the low cost serial connectors, we could ask for an enhancement
to wview to flip the bits via the station configuration page.

David

Mark Teel

unread,
Sep 18, 2011, 10:21:23 PM9/18/11
to wv...@googlegroups.com
David,

Well done! I was thinking that should be all that is required but
haven't had time to confirm it.

If you don't mind, enter a new issue in the Mantis database for this
enhancement. I will add a check box for "Auto-Generate Archive Records"
on the station config page of wviewmgmt. That way I won't forget it when
I have some time to do the next release.

Thanks for your efforts,
Mark

Wowzer

unread,
Sep 19, 2011, 10:41:44 AM9/19/11
to wview
You're welcome Mark. I added a new issue to the Mantis database per
your request.

Cheers,
David

Tyler

unread,
Sep 21, 2011, 3:32:38 PM9/21/11
to wview
David,
Thank you so much for the help! I have followed your instructions
above and they have worked like a charm. I cannot thank you enough. My
box is recording high resolution (every 15s!) data now happily.


I have one other problem though now that its recording happily. I'm
not sure if its associated or not, though I didnt get the error before
hand (its possible it was too busy with the other error). htmlgend is
no longer producing an index file. Previously, it had done so no
problem, just lacked any archive data (worked great for current
conditions). Now it has all the archive data a man could want, but
wont produce the index.


syslog output: Everything in the startup goes perfectly until
Sep 21 08:20:13 wxhome htmlgend[1524]: <1316611213872> : htmlmgrInit: /
etc/wview/images.conf does not exist!
Sep 21 08:20:13 wxhome htmlgend[1524]: <1316611213872> : htlmgrInit
failed!

..and from there on htmlgend only reports:
Sep 21 08:23:04 wxhome htmlgend[1524]: <1316611384519> :
htmlErrorState: received stimulus 2


I have done as much reading and research as I can about this error.
From what I understand, the stimulus 2 error is just basically saying
there was a previous error. Well that part is easy enough. But I can
figure out whats causing the htlmgrInit fail. I have checked
permissions directory path integrities, and I can't come up with
anything. Any further light to shed if you can would be super. If you
can't think of anything, no big worries, at least I'm getting my
archive data, and you made a huge help with that.

Tyler

Wowzer

unread,
Sep 21, 2011, 4:49:01 PM9/21/11
to wview
Tyler,
You are welcome glad to help.

The error states that /etc/wview/images.conf is missing. There should
be a copy of one in /etc/wview/html/ that you can copy up one
directory. Then restart.

There are also canned versions of images.conf for the template you may
be running. I think you are running chrome standard. Check /etc/wview/
html/chrome/standard/images.conf. You could also copy that one too.

There may be backed up versions too in /etc/wview/html-2011xxxxxxxx/
directories. The have the date and time stamp on the directory name.
Wview creates them when you switch templates.

The command "find /etc/wview -name images.conf" will show all of them.

David

Tyler

unread,
Sep 22, 2011, 11:06:50 PM9/22/11
to wview
I apologize for taking a while to get back to you. I have had quite
the schedule for the last day or so now. Ok so I was thinking along
the same lines of needing to redo the build, from a clean source. So I
wiped the board and started from the ground and headed up. Things seem
better now, but still aren't working. Though I feel very close (or
perhaps still a false sense of hope haha!). I'm still getting the same
broken pipe error:

Sep 22 21:50:10 wxhome radmrouted[1791]: <1316746210250> :
radQueueSend: write failed on fd 7: Broken pipe

But Ive come to notice this is just a looping error AFTER a much
bigger error, and likely the cause:

Sep 22 21:50:04 wxhome wviewd[1795]: <1316746204409> : storing record
for 2011-09-22 21:50
Sep 22 21:50:04 wxhome wviewd[1795]: <1316746204411> : radsqliteQuery:
sqlite3_prepare(): error 1 (no such column: nan)
Sep 22 21:50:04 wxhome wviewd[1795]: <1316746204412> : radsqliteQuery:
query failed: INSERT INTO archive
(dateTime,usUnits,interval,barometer,pressure,altimeter,inTemp,outTemp,inHumidity,outHumidity,windSpeed,windGust,rainRate,rain,windchill,heatindex,ET,radiation,UV,rxCheckPercent,hail,hailRate,heatingTemp,heatingVoltage,supplyVoltage,referenceVoltage,windBatteryStatus,rainBatteryStatus,outTempBatteryStatus,inTempBatteryStatus)
VALUES (1316746200,1,5,0.000000,0.000000,-nan,
0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000)


It would seem to me that for some reason now, the data is getting
smudged between the station console and the sql database. Its trying
to write in the data stream, but obviously the values are bogus. Man
its killing me. Here were my steps of installation as well:

sudo apt-get purge wview (yes to remove ALL config and data)

sudo apt-get install wview

download source to local directory and unpack

run ./configure --prefix=/ --bindir=/usr/bin --sysconfdir=/etc --
localstatedir=/var/lib --libdir=/usr/lib to match the wview apt
package

changed the lines in vproInterface.c (within /stations/VantagePro) to
allow it to communicate without have the data logger

ran sudo make in the same directory (VantagePro)

Copied the new wviewd_vpro over the one established by the apt package
(after making a back up copy)


and points to remember: At some point in the last 5 days, wview has
successfully:
logged data into the archive every 1 minute. (simultaneously reporting
to wunderground)
generated html files and images properly and uploaded them.

IT HAS NOT done these two points simultaneously. Everytime I get one
to work, the other fails.


Also, at one point I attempted to install from the source code I
downloaded, and couldnt get it install happily, so I said forget it
and went back to the apt package. Is it possibly there are remnants of
that attempted install interfering with the new installation running?

Thanks for all your help again man!

Tyler

unread,
Sep 23, 2011, 9:32:31 AM9/23/11
to wview
OK I got it to work! I'm so stinkin' excited. I've been working
incessantly for the last week getting all sorts of errors, its so nice
that is finally just working. I got it working late last night (2am
CDT, ugh). Heres what I did:

I believe there were interfering components from when I attempted to
build from source, so I went back to that directory and ran a sudo
make uninstall. Then I reinstalled the apt package after purging, and
copied the new wviewd_vpro binary over the apt's version. NOTE: I am
not sure if it would affect it, but I made sure that all the building
and configuring of the custom wviewd_vpro was done before I installed
the apt package, so all I had to do was transfer the binary file. I
easily could be wrong, but feared the building some how interfered
with the existing installation. Regardless, it works now! Thanks so
much for all of y'alls help! I couldn't have gotten it done without
you.

Tyler
> > > > > >>> David...
>
> read more »

PiP

unread,
Oct 29, 2011, 7:16:50 PM10/29/11
to wview
I am trying to run wview on a vantage vue without a data logger too.

I edited the File: vproInterface.c (as stated above)
After that I entered "sudo make" in the same directory. I get error
back "make: *** No targets specified and no makefile found. Stop" Can
someone tell me what else I'm suppose to enter with the make command?
Thanks,
> > > > > > >> you know if the vprointerface.c only get referenced...
>
> read more »

PiP

unread,
Dec 28, 2011, 4:06:52 PM12/28/11
to wview
I got it working thanks!

My problem above was because I was ignoring the errors I had during
configure (I had to install libcurl and libgd2-xpm-dev).

Also this sounds obvious but FALSE has to be in all caps.

Thanks again for all the help!
> > > > > > > > If...
>
> read more »
Reply all
Reply to author
Forward
0 new messages