On Friday, 29 March 2019 15:50:41 UTC-3, Paul Anderson wrote:
>
> It is a pretty old VP2 from April of 2006.
>

Paul,

For the few samples I got from you I have found a formula. 
I don't understand the logic of the formula, but it works for these 
samples. :-)  I need more data to be sure.
Could you please change the parsing section of humidity in your rtldavis.py 
with the following?

=======================================================================
elif message_type == 0xA:
# outside humidity
# message examples:
# A0 00 00 80 85 00 3E 1F (old model vantage pro)
# A0 00 00 C9 3D 00 2A 87 (new model vantage pro)
# A1 00 DB 00 03 00 47 C7 (no sensor)
humidity_raw = ((pkt[4] >> 4) << 8) + pkt[3]
if humidity_raw != 0:
# valid humidity value
if pk[4] == 0x85:
# format of old model Vantage Pro2
humidity = (680 - pkt[3]) / 10.0
else:
# format of new model Vantage Pro2
humidity = humidity_raw / 10.0
if data['channel'] == th1_ch:
data['humid_1'] = humidity
elif data['channel'] == th2_ch:
data['humid_2'] = humidity
else:
data['humidity'] = humidity
dbg_parse(2, "humidity_raw=0x%03x value=%s" %
  (humidity_raw, humidity))
=======================================================================

Then let the program run over night and send me by mail the zipped syslog 
and syslog.1 files tomorrow
Also I would like a list of the 5-minute averages in the weewx database 
over the same period.

Thanks in advance.

To kobuki: the hex-code is checked both in protocol.go and rtldavis.py for 
crc-errors. Both programs didn't complain.

Luc
 

Reply via email to