Unless you are using a modified version of the the SDR driver it should be .
ProloguePacket not .PrologueTHPacket.
You will likely have to modify the SDR driver code (sdr.py circa line 2278)
as follows so that it will decode your Prologue sensor data:
class ProloguePacket(Packet):
# 2017-03-19 : Prologue Temperature and Humidity Sensor
# {"time" : "2017-03-15 20:14:19", "model" : "Prologue sensor", "id" :
5, "rid" : 166, "channel" : 1, "battery" : "OK", "button" : 0,
"temperature_C" : -0.700, "humidity" : 49}
IDENTIFIER = "Prologue-TH"
@staticmethod
def parse_json(obj):
pkt = dict()
pkt['dateTime'] = Packet.parse_time(obj.get('time'))
pkt['usUnits'] = weewx.METRIC
sensor_id = obj.get('rid')
pkt['temperature'] = Packet.get_float(obj, 'temperature_C')
pkt['humidity'] = Packet.get_float(obj, 'humidity')
pkt['battery'] = 0 if obj.get('battery') == 'OK' else 1
pkt['channel'] = obj.get('channel')
pkt = Packet.add_identifiers(pkt, sensor_id,
ProloguePacket.__name__)
return pkt
Gary
On Thursday, 2 September 2021 at 13:05:33 UTC+10 [email protected] wrote:
> Hi all,
>
> I'm attempting to pull data off two sources at once via the SDR driver -
> an Acurite (which works) and an el-cheapo device for the inside temperature
> & humidity which puts out packets that look like this:
>
> out:[u'{"time" : "2021-09-02 02:57:42", "model" : "Prologue-TH", "subtype"
> : 5, "id" : 70, "channel" : 3, "battery_ok" : 1, "temperature_C" : 22.300,
> "humidity" : 42, "button" : 0}\n', u'{"time" : "2021-09-02 02:57:42",
> "model" : "TFA-TwinPlus", "id" : 10, "channel" : 1, "battery_ok" : 1,
> "temperature_C" : -25.100, "humidity" : 51, "mic" : "CHECKSUM"}\n']
>
> In my [[sensor_map]] entries, I have for this device (Acurite stuff elided)
>
> inTemp = temperature_C.0046.PrologueTHPacket
> inHumidity = humidity.0046.PrologueTHPacket
>
> What am I doing wrong?
>
--
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].
To view this discussion on the web visit
https://groups.google.com/d/msgid/weewx-user/a5fd73e3-d783-4118-af25-275dc294679an%40googlegroups.com.