Problem with vantage.py in 4.5.1 moving from 4.4.0

184 views
Skip to first unread message

bgra...@umw.edu

unread,
Apr 4, 2021, 11:20:18 AM4/4/21
to weewx-user
Hello,
I'm running a VP2+ on Ubuntu and using a Davis #6540 RS232 Weatherlink (streaming data logger for APRS) interface. This has been running successfully since my move from wview about +/- 8 years or so. To avoid a "WeeWxIOError: Max tries exceeded while getting LOOP data" I modified vantage.py:

# on the VP (somewhere around 220).
            for _loop_packet in self.genDavisLoopPackets(2): [changed from 200 in original version]
                yield _loop_packet

When I first got this error, someone in the group suggested this change. It worked for all earlier weewx versions and, so far, I've changed it at each upgrade.

This time, when I upgraded to 4.5.1 (setup.py), I got the usual loop data problem. I then made the vantage.py modification as listed above (200 -> 2).  Upon restarting 4.5.1, I continued to get the loop data problem even with the modified vantage.py.

I saw there was a slight modification of vantage.py from 4.4.x to 4.5.x. Could this have caused the problem?
"Fixed bug that prevented the Vantage driver from waiting before a wakeup retry."

Could I simply move my 4.4.0 version on vantage.py over to 4.5.1? Just wanted to check before I started mixing things up. Thanks in advance for any help.


weewx.log errors:
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.engine: Archive will use data binding wx_binding
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.engine: Record generation will be attempted in 'hardware'
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.engine: Using archive interval of 900 seconds (specified by hardware)
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.restx: StationRegistry: Station will be registered.
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.restx: Wunderground-PWS: Data for station KVAASHLA4 will be posted
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.restx: PWSWeather: Data for station N4MRV will be posted
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.restx: CWOP: Data for station N4MRV-1 will be posted
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.restx: WOW: Data for station 964806001 will be posted
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.restx: AWEKAS: Data will be uploaded for user bgrattan
Apr  3 17:42:10 n4mrv weewx[338554] INFO user.emoncms: service version is 0.17
Apr  3 17:42:10 n4mrv weewx[338554] INFO user.emoncms: node is 0
Apr  3 17:42:10 n4mrv weewx[338554] INFO user.emoncms: Data will be uploaded with token=XXXXXXXXXXXXXXXXXXXXXXXXXXXXb634
Apr  3 17:42:10 n4mrv weewx[338554] INFO __main__: Starting up weewx version 4.5.1
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.engine: Clock error is -0.14 seconds (positive is fast)
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.engine: Using binding 'wx_binding' to database 'weewx.sdb'
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.manager: Starting backfill of daily summaries
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.manager: Daily summaries up to date
Apr  3 17:42:10 n4mrv weewx[338554] INFO weewx.engine: Starting main packet loop.
Apr  3 17:42:20 n4mrv weewx[338554] ERROR weewx.drivers.vantage: LOOP try #1; error: Expected to read 99 chars; got 0 inst
ead
Apr  3 17:42:25 n4mrv weewx[338554] ERROR weewx.drivers.vantage: LOOP try #2; error: Expected to read 99 chars; got 0 inst
ead
Apr  3 17:42:30 n4mrv weewx[338554] ERROR weewx.drivers.vantage: LOOP try #3; error: Expected to read 99 chars; got 0 inst
ead
Apr  3 17:42:35 n4mrv weewx[338554] ERROR weewx.drivers.vantage: LOOP try #4; error: Expected to read 99 chars; got 0 inst
ead
Apr  3 17:42:35 n4mrv weewx[338554] ERROR weewx.drivers.vantage: LOOP max tries (4) exceeded.
Apr  3 17:42:35 n4mrv weewx[338554] INFO weewx.engine: Main loop exiting. Shutting engine down.
Apr  3 17:42:35 n4mrv weewx[338554] CRITICAL __main__: Caught WeeWxIOError: Max tries exceeded while getting LOOP data.
Apr  3 17:42:35 n4mrv weewx[338554] CRITICAL __main__:     ****  Waiting 60 seconds then retrying...
Apr  3 17:43:35 n4mrv weewx[338554] INFO __main__: retrying...
Apr  3 17:43:35 n4mrv weewx[338554] INFO __main__: Using configuration file /home/weewx/weewx.conf
Apr  3 17:43:35 n4mrv weewx[338554] INFO __main__: Debug is 0
Apr  3 17:43:35 n4mrv weewx[338554] INFO weewx.engine: Loading station type Vantage (weewx.drivers.vantage)
Apr  3 17:43:35 n4mrv weewx[338554] INFO user.purple: Service version is 3.0.1.
Apr  3 17:43:35 n4mrv weewx[338554] INFO user.purple: Source 1 for PurpleAir readings: sensor 192.168.1.130:80, proxy: Fal
se, timeout: 15
Apr  3 17:43:35 n4mrv weewx[338554] INFO weewx.engine: StdConvert target unit is 0x1
Apr  3 17:43:35 n4mrv weewx[338554] INFO user.cmon: service version is 0.20
Apr  3 17:43:35 n4mrv weewx[338554] INFO user.cmon: sysinfo: Linux n4mrv 5.4.0-70-generic #78-Ubuntu SMP Fri Mar 19 13:29:



bgra...@umw.edu

unread,
Apr 7, 2021, 12:06:46 PM4/7/21
to weewx-user

Any comments, anyone?
Is it worth dumping the 6540 for a 6510SER? My console is about 50 feet from the computer so that’s why I am using RS232.

Tom Keffer

unread,
Apr 7, 2021, 12:13:02 PM4/7/21
to weewx-user
The difference between the Vantage V4.4.0 and v4.5.1 drivers is trivial, and has to do with enabling retries. All other functionality is identical.

Make sure your console is not in setup mode.

--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/85a6cf94-0e91-4671-a3f2-8688d929f20en%40googlegroups.com.

Greg Troxel

unread,
Apr 7, 2021, 1:18:56 PM4/7/21
to bgra...@umw.edu, weewx-user

As a data point which may or may not be helpful, I have a VP2+ with a
Davis serial data logger, and a prolific USB/serial adaptor in a RPI3
runnineg NetBSD, and it's been working fine since Janury 2018. I just
updated to 4.5.1 (well, git master from 2 days ago) and it's still fine.

I do get occasinal read errors and retries in the log, 2 in the last 27
hours.

Note that I'm still on pyhon 2; next step is to flip to 3.8 now that I'm
up to date.
signature.asc

bgra...@umw.edu

unread,
Apr 7, 2021, 3:39:29 PM4/7/21
to weewx-user
Greg,
Are you using the 6540 serial APRS logger or the #6510SER? My 6540 has been working fine (with the mod in vantage.py I listed above) for many years.
Tom, from the log it looks as if the retries are the problem—it keeps trying to get data but doesn’t. I’ve gone back to 4.4.0 and all works fine.
Thanks

Tom Keffer

unread,
Apr 7, 2021, 5:33:12 PM4/7/21
to weewx...@googlegroups.com
Yes, the retries are the problem --- that's a bit of a tautology. The question is what is causing the continuing retries? One thing that can do this is if the console is in setup mode. Did you check? A long press of the "Done" button will get it out of that mode.

I can think of no reason why V4.4.0 would be any different than V4.5.1. 

--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.

Greg Troxel

unread,
Apr 7, 2021, 6:09:40 PM4/7/21
to bgra...@umw.edu, weewx-user

"bgra...@umw.edu" <bgra...@umw.edu> writes:

> Greg,
> Are you using the 6540 serial APRS logger or the #6510SER? My 6540 has been
> working fine (with the mod in vantage.py I listed above) for many years.
> Tom, from the log it looks as if the retries are the problem—it keeps
> trying to get data but doesn’t. I’ve gone back to 4.4.0 and all works fine.
> Thanks

I am 99% sure it's the 6510SER.
signature.asc

bgra...@umw.edu

unread,
Apr 8, 2021, 9:51:30 AM4/8/21
to weewx-user
Tom,
I tried the console setup mode exit when you first mentioned it, and it made no difference. After upgrading to 4.5.1, and trying both the new vantage.py and then my modification (as listed above), I did a build/install back to 4.4.0 and everything took off perfectly.
At this point, I have decided to order a 6510SER logger to replace my 6540. I’ve needed to modify vantage.py with each weewx upgrade so maybe this will solve the problem once and for all. If not, I will have eliminated a possibility (and have a spare logger!).
Thanks for your help and especially for the software. Also thanks to Greg for his comments. I’ll keep you posted when I install the new logger.
Cheers,
Bob

bgra...@umw.edu

unread,
Apr 8, 2021, 3:04:57 PM4/8/21
to weewx-user
Tom,
FYI, I ran across an earlier discussion of yours (https://groups.google.com/g/weewx-user/c/9djjwjNdfUY/m/b1ZQGWh2xacJ) which talks about problems with the Davis 6540 data-logger. This is where I must have gotten my original modification of vantage.py. It supports my feeling that I should move away from the 6540. Thanks.
Bob

bgra...@umw.edu

unread,
Apr 19, 2021, 11:33:09 AM4/19/21
to weewx-user
FYI:
The change from 6540 to 6510SER worked fine, with no modifications needed now to vantage.py.Thanks all.
Bob

Nate Bargmann

unread,
May 27, 2021, 10:49:11 AM5/27/21
to weewx...@googlegroups.com
* On 2021 07 Apr 11:13 -0500, Tom Keffer wrote:
> The difference between the Vantage V4.4.0 and v4.5.1 drivers is trivial,
> and has to do with enabling retries. All other functionality is identical.

Just this morning I bit the bullet and did the upgrade. Initially,
WeeWx restarted and all was well but since the kernel was updated
(Debian Buster) I rebooted and that is when the "fun" started.

Of course, the thing hung (Olimex OLinuxo Micro) and didn't shut down so
I pulled the power, plugged it back in, and then I got a series of LOOP
errors and wait periods, restarted WeeWX to no effect. I hard booted
again with the same result. I then shut down WeeWX, used wee_device to
clear the logger memory, started WeeWX, and it started quietly and after
about a minute spat out eight LOOP errors and has been running quiet for
the 20 minutes since.

> Make sure your console is not in setup mode.

Not here. I didn't even allow my finger to brush the console let alone
push any buttons!

- Nate

--

"The optimist proclaims that we live in the best of all
possible worlds. The pessimist fears this is true."

Web: https://www.n0nb.us
Projects: https://github.com/N0NB
GPG fingerprint: 82D6 4F6B 0E67 CD41 F689 BBA6 FB2C 5130 D55A 8819

signature.asc
Reply all
Reply to author
Forward
0 new messages