Fineoffset-WHx080 and SDR sensor_map

139 views
Skip to first unread message

Michael Jackson

unread,
Feb 29, 2020, 1:56:44 AM2/29/20
to weewx-user
I'm having some trouble mapping the sensors from my FineOffset WH1081PC via rtl_433 and weewx.  I can get the humidity and temperature but can't seem to map wind, wind direction and rain.

This is the return from xxxxx:

[u'{"time" : "2020-02-29 06:46:12", "model" : "Fineoffset-WHx080", "subtype" : 0, "id" : 104, "battery_ok" : 1, "temperature_C" : 18.200, "humidity" : 63, "wind_dir_deg" : 203, "wind_avg_km_h" : 4.896, "wind_max_km_h" : 7.344, "rain_mm" : 924.300, "mic" : "CRC"}\n', u'{"time" : "2020-02-29 06:46:13", "model" : "Fineoffset-WHx080", "subtype" : 0, "id" : 104, "battery_ok" : 1, "temperature_C" : 18.200, "humidity" : 63, "wind_dir_deg" : 203, "wind_avg_km_h" : 4.896, "wind_max_km_h" : 7.344, "rain_mm" : 924.300, "mic" : "CRC"}\n']

and this is what I have mapped so far:

outTemp = temperature.*.FOWHx080Packet
windSpeed = wind_avg_km_h.*.FOWHx080Packet
windDir = wind_dir_deg.*.FOWHx080Packet
outHumidity = humidity.*.FOWHx080Packet
rain = rain_mm.*.FOWHx080Packet

Should I be editing sdr.py with the results from rtl_433 for the FOWHx080Packet?

mwall

unread,
Feb 29, 2020, 6:22:08 AM2/29/20
to weewx-user
On Saturday, February 29, 2020 at 1:56:44 AM UTC-5, Michael Jackson wrote:
I'm having some trouble mapping the sensors from my FineOffset WH1081PC via rtl_433 and weewx.  I can get the humidity and temperature but can't seem to map wind, wind direction and rain.

it looks like you are getting a "new style" model key ("Fineoffset-WHx080") instead of the "old style" model key ("Fine Offset Electronics WH1080/WH3080 Weather Stations")

please post:

* the version/release/package of rtl_433 that you are using
* the command you use to invoke rtl_433
* the [SDR] section of your weewx configuration file

m

Michael Jackson

unread,
Feb 29, 2020, 7:21:52 PM2/29/20
to weewx-user
Output from rtl_433 -V:

rtl_433 version 20.02-4-g6b5d52b branch master at 202002270803 inputs file rtl_tcp RTL-SDR SoapySDR
Use -h for usage help and see https://triq.org/ for documentation.
Trying conf file at "rtl_433.conf"...
Trying conf file at "/home/pi/.config/rtl_433/rtl_433.conf"...
Trying conf file at "/usr/local/etc/rtl_433/rtl_433.conf"...
Trying conf file at "/etc/rtl_433/rtl_433.conf"...


rtl_433 command:

sudo rtl_433 -M utc -F json

SDR section from weewx:

[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 = sudo rtl_433 -M utc -F json

    [[sensor_map]]
        outTemp = temperature.*.FOWHx080Packet
        windSpeed = wind_speed.*.FOWHx080Packet
        windDir = wind_dir_deg.*.FOWHx080Packet
        outHumidity = humidity.*.FOWHx080Packet
        rain = rain.*.FOWHx080Packet


Thanks for looking into this Max.

mwall

unread,
Feb 29, 2020, 8:18:42 PM2/29/20
to weewx-user
thanks for that.  i will probably have to start supporting both new style and old style model strings.  sigh.

could you confirm by posting the output from running sdr.py directly?  (see the instructions in the weewx-sdr readme)

5-10 lines of sensor data should do

Michael Jackson

unread,
Mar 1, 2020, 8:45:04 PM3/1/20
to weewx-user
Well, the output of sdr.py using the string in the readme (sudo PYTHONPATH=/usr/share/weewx python /usr/share/weewx/user/sdr.py --cmd="rtl_433 -M utc -F json") gives this

out:[u'{"time" : "2020-03-02 01:43:49", "model" : "Fineoffset-WHx080", "subtype" : 0, "id" : 104, "battery_ok" : 1, "temperature_C" : 28.500, "humidity" : 50, "wind_dir_deg" : 45, "wind_avg_km_h" : 8.568, "wind_max_km_h" : 12.240, "rain_mm" : 924.300, "mic" : "CRC"}\n', u'{"time" : "2020-03-02 01:43:49", "model" : "Fineoffset-WHx080", "subtype" : 0, "id" : 104, "battery_ok" : 1, "temperature_C" : 28.500, "humidity" : 50, "wind_dir_deg" : 45, "wind_avg_km_h" : 8.568, "wind_max_km_h" : 12.240, "rain_mm" : 924.300, "mic" : "CRC"}\n']
parsed: {'wind_dir.104.FOWHx080Packet': None, 'wind_gust.104.FOWHx080Packet': None, 'hours.104.FOWHx080Packet': None, 'temperature.104.FOWHx080Packet': 28.5, 'battery.104.FOWHx080Packet': 1, 'msg_type.104.FOWHx080Packet': None, 'dateTime': 1583113429, 'minutes.104.FOWHx080Packet': None, 'month.104.FOWHx080Packet': None, 'day.104.FOWHx080Packet': None, 'wind_speed.104.FOWHx080Packet': None, 'humidity.104.FOWHx080Packet': 50.0, 'seconds.104.FOWHx080Packet': None, 'signal_type.104.FOWHx080Packet': 0, 'usUnits': 16, 'year.104.FOWHx080Packet': None}

Thanks again for any insights.


On Saturday, February 29, 2020 at 7:56:44 PM UTC+13, Michael Jackson wrote:

Michael Jackson

unread,
Mar 2, 2020, 8:23:22 PM3/2/20
to weewx-user
OK, I have the syntax now for what's in sdr.py and mapping sensors to a particular model and have managed to get all the available sensors reporting to the database and html reports, happy days!


On Saturday, February 29, 2020 at 7:56:44 PM UTC+13, Michael Jackson wrote:
Reply all
Reply to author
Forward
0 new messages