out:[u'{"time" : "2020-05-21 02:27:42", "model" : "Acurite-5n1", "subtype" : 49, "id" : 1066, "channel" : "B", "sequence_num" : 0, "battery_ok" : 1, "wind_avg_km_h" : 14.245, "wind_dir_deg" : 112.500, "rain_in" : 28.500, "mic" : "CHECKSUM"}\n', u'{"time" : "2020-05-21 02:27:42", "model" : "Acurite-5n1", "subtype" : 49, "id" : 1066, "channel" : "B", "sequence_num" : 1, "battery_ok" : 1, "wind_avg_km_h" : 14.245, "wind_dir_deg" : 112.500, "rain_in" : 28.500, "mic" : "CHECKSUM"}\n', u'{"time" : "2020-05-21 02:27:42", "model" : "Acurite-5n1", "subtype" : 49, "id" : 1066, "channel" : "B", "sequence_num" : 2, "battery_ok" : 1, "wind_avg_km_h" : 14.245, "wind_dir_deg" : 112.500, "rain_in" : 28.500, "mic" : "CHECKSUM"}\n']
parsed: {'wind_speed.042A.Acurite5n1PacketV2': 14.245, 'model.042A.Acurite5n1PacketV2': u'Acurite-5n1', 'channel.042A.Acurite5n1PacketV2': u'B', 'wind_dir.042A.Acurite5n1PacketV2': 112.5, 'battery.042A.Acurite5n1PacketV2': 1, 'dateTime': 1590028062, 'freq.042A.Acurite5n1PacketV2': None, 'mod.042A.Acurite5n1PacketV2': None, 'snr.042A.Acurite5n1PacketV2': None, 'sequence_num.042A.Acurite5n1PacketV2': 0, 'noise.042A.Acurite5n1PacketV2': None, 'protocol.042A.Acurite5n1PacketV2': None, 'rssi.042A.Acurite5n1PacketV2': None, 'msg_type.042A.Acurite5n1PacketV2': 49, 'usUnits': 1}
I have done a lot of searching on this forum and the web and I understand that there have been many changes to the labeling of rain data on the Acurite 5n1 system. Howerver I just can't figure out where in the code I can make a change that will accept label that my version of the weather station uses for rain.
I have done a fair share of programming and I have the help of my son who is a computer science graduate. I feel quite comfortable messing around in the code
So far the only change in code that I have tried was to change the line in sdr.py
I am running rtl_433 version 20.02-55-gc1d1f9f branch master at 202005162227
thanks for your help
if 'wind_dir_deg' in obj:
pkt['wind_dir'] = Packet.get_float(obj, 'wind_dir_deg')
if 'rain_mm' in obj:
pkt['rain_total'] = Packet.get_float(obj, 'rain_mm') / 25.4
if 'rain_in' in obj:
pkt['rain_total'] = Packet.get_float(obj, 'rain_in')
if 'temperature_F' in obj:
pkt['temperature'] = Packet.get_float(obj, 'temperature_F')
This is how I fixed the first part of the problem where the out data portion of running this file had the rain data, but the parsed portion did not.
Next I updated the file: /etc/weewx/weewx.conf
by adding the highlighted line
[SDR]
# This section is for the software-defined radio driver.
# The driver to use
driver = user.sdr
log_unknown_sensors = True
log_unmapped_sensors = True
#cmd = /usr/local/bin/rtl_433 -M utc -F json
cmd = /usr/local/bin/rtl_433 -q -M UTC -F json
[[sensor_map]]
windDir = wind_dir.042A.Acurite5n1PacketV2
windSpeed = wind_speed.042A.Acurite5n1PacketV2
outTemp = temperature.042A.Acurite5n1PacketV2
outHumidity = humidity.042A.Acurite5n1PacketV2
rain_total = rain_total.042A.Acurite5n1PacketV2
[[Deltas]]
rain = rain_total