I have had a go at creating the parser as follows: -


class FOWH32BPacket(Packet):
    # time      : 2019-04-08 00:48:02
        # model     : Fineoffset-WH32B                       
    # ID        : 146
    # Temperature: 17.5 C      
    # Humidity  : 60 %          
    # Pressure  : 1001.2 hPa    
    # Battery   : OK            
    # Integrity : CHECKSUM
_

    # This is for a WH32B which is the indoors sensor array for an Ambient 
Weather
    # WS-2902A. The same sensor array is used for several models.

    # {time      : 2019-04-08 00:49:02
model     : Fineoffset-WH32B                       ID        : 146
Temperature: 17.5 C      Humidity  : 60 %          Pressure  : 1001.2 hPa    
Battery   : OK            Integrity : CHECKSUM}
    

IDENTIFIER = "Fineoffset-WH32B"

    @staticmethod
    def parse_json(obj):
        pkt = dict()
        pkt['dateTime'] = Packet.parse_time(obj.get('time'))
        pkt['usUnits'] = weewx.METRIC
        pkt['station_id'] = obj.get('id')
        pkt['temperature'] = Packet.get_float(obj, 'temperature_C')
        pkt['humidity'] = Packet.get_float(obj, 'humidity')
        pkt['pressure'] = Packet.get_float(obj, 'pressure_hPa')
        pkt['battery'] = 0 if obj.get('battery') == 'OK' else 1
        return FOWH32BPacket.insert_ids(pkt)
      
      

    @staticmethod
    def insert_ids(pkt):
        station_id = pkt.pop('station_id', '0000')
        pkt = Packet.add_identifiers(pkt, station_id, FOWH32BPacket.__name__)
        return pkt
      
   

> On 8 Apr 2019, at 01:01, mwall <[email protected]> wrote:
> 
> On Sunday, April 7, 2019 at 6:44:00 PM UTC-4, steepleian wrote:
> However, thus far, I have not been able to map the packets correctly with the 
> sdr.py driver. Has anybody else had a chance to look at this yet and come to 
> any conclusions?
> 
> please post the rtl_433 JSON output so that i can add the WH32B parser.  just 
> run sdr.py directly, something like this:
> 
> cd /home/weewx
> PYTHONPATH=bin python bin/user/sdr.py --cmd="rtl_433 -M utc -F json -R 78"
> 
> adjust the paths as needed, depending on where/how you installed weewx and 
> rtl_433
> 
> i won't be able to test with my WH32B for a few weeks...
> 
> m 
> 
> -- 
> 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 [email protected] 
> <mailto:[email protected]>.
> For more options, visit https://groups.google.com/d/optout 
> <https://groups.google.com/d/optout>.

-- 
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 [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to