rtl433  UNKNOWN
RTL-433 utility
fineoffset.c File Reference

Fine Offset Electronics sensor protocol. More...

Functions

static r_devicefineoffset_WH2_create (char *arg)
 
static int fineoffset_WH2_callback (r_device *decoder, bitbuffer_t *bitbuffer)
 Fine Offset Electronics WH2 Temperature/Humidity sensor protocol, also Agimex Rosenborg 66796 (sold in Denmark), collides with WH5, also ClimeMET CM9088 (Sold in UK), also TFA Dostmann/Wertheim 30.3157 (Temperature only!) (sold in Germany). More...
 
static int fineoffset_WH24_callback (r_device *decoder, bitbuffer_t *bitbuffer)
 
static int fineoffset_WH0290_callback (r_device *decoder, bitbuffer_t *bitbuffer)
 Fine Offset Electronics WH0290 Wireless Air Quality Monitor Also: Ambient Weather PM25. More...
 
static int fineoffset_WH25_callback (r_device *decoder, bitbuffer_t *bitbuffer)
 Fine Offset Electronics WH25 / WH32B Temperature/Humidity/Pressure sensor protocol. More...
 
static int alecto_ws1200v1_callback (r_device *decoder, bitbuffer_t *bitbuffer)
 Alecto WS-1200 V1.0 decoder by Christian Zuckschwerdt, documentation by Andreas Untergasser, help by curlyel. More...
 
static int alecto_ws1200v2_dcf_callback (r_device *decoder, bitbuffer_t *bitbuffer)
 Alecto WS-1200 V2.0 DCF77 decoder by Christian Zuckschwerdt, documentation by Andreas Untergasser, help by curlyel. More...
 
static int alecto_ws1200v2_callback (r_device *decoder, bitbuffer_t *bitbuffer)
 Alecto WS-1200 V2.0 decoder by Christian Zuckschwerdt, documentation by Andreas Untergasser, help by curlyel. More...
 
static int fineoffset_WH0530_callback (r_device *decoder, bitbuffer_t *bitbuffer)
 Fine Offset Electronics WH0530 Temperature/Rain sensor protocol, also Agimex Rosenborg 35926 (sold in Denmark). More...
 

Variables

r_device fineoffset_WH2
 
static char * output_fields []
 
static char * output_fields_WH25 []
 
static char * output_fields_WH0530 []
 
r_device fineoffset_WH25
 
r_device fineoffset_WH0530
 

Detailed Description

Fine Offset Electronics sensor protocol.

Copyright (C) 2017 Tommy Vestermark Enhanced (C) 2019 Christian W. Zuckschwerdt zany@.nosp@m.triq.nosp@m..net

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

Function Documentation

◆ alecto_ws1200v1_callback()

static int alecto_ws1200v1_callback ( r_device decoder,
bitbuffer_t bitbuffer 
)
static

Alecto WS-1200 V1.0 decoder by Christian Zuckschwerdt, documentation by Andreas Untergasser, help by curlyel.

A Thermometer with clock and wireless rain unit with temperature sensor.

Manual available at https://www.alecto.nl/media/blfa_files/WS-1200_manual_NL-FR-DE-GB_V2.2_8712412532964.pdf

Data layout:

1111111 FFFFIIII IIIIB?TT TTTTTTTT RRRRRRRR RRRRRRRR 11111111 CCCCCCCC
  • 1: 7 bit preamble of 1's
  • F: 4 bit fixed message type (0x3)
  • I: 8 bit random sensor ID, changes at battery change
  • B: 1 bit low battery indicator
  • T: 10 bit temperature in Celsius offset 40 scaled by 10
  • R: 16 bit (little endian) rain count in 0.3 mm steps, absolute with wrap around at 65536
  • C: 8 bit CRC-8 poly 0x31 init 0x0 for 7 bytes

Format string:

PRE:7b TYPE:4b ID:8b BATT:1b ?:1b T:10d R:<16d ?:8h CRC:8h

References bitbuffer::bb, bitbuffer_extract_bytes(), bitrow_printf(), bitbuffer::bits_per_row, emontx::crc, crc8(), DATA_DOUBLE, DATA_FORMAT, DATA_INT, data_make(), DATA_STRING, decoder_output_data(), and r_device::verbose.

Referenced by fineoffset_WH0530_callback().

◆ alecto_ws1200v2_callback()

static int alecto_ws1200v2_callback ( r_device decoder,
bitbuffer_t bitbuffer 
)
static

Alecto WS-1200 V2.0 decoder by Christian Zuckschwerdt, documentation by Andreas Untergasser, help by curlyel.

A Thermometer with clock and wireless rain unit with temperature sensor.

Manual available at https://www.alecto.nl/media/blfa_files/WS-1200_manual_NL-FR-DE-GB_V2.2_8712412532964.pdf

Data layout:

1111111 FFFFIIII IIIIB?TT TTTTTTTT RRRRRRRR RRRRRRRR 11111111 CCCCCCCC AAAAAAAA DDDDDDDD DDDDDDDD DDDDDDDD
  • 1: 7 bit preamble of 1's
  • F: 4 bit fixed message type (0x3)
  • I: 8 bit random sensor ID, changes at battery change
  • B: 1 bit low battery indicator
  • T: 10 bit temperature in Celsius offset 40 scaled by 10
  • R: 16 bit (little endian) rain count in 0.3 mm steps, absolute with wrap around at 65536
  • C: 8 bit CRC-8 poly 0x31 init 0x0 for 7 bytes
  • A: 8 bit checksum (addition)
  • D: 24 bit DCF77 time, all 0 while training for the station connection

Format string:

PRE:7b TYPE:4b ID:8b BATT:1b ?:1b T:10d R:<16d ?:8h CRC:8h MAC:8h DATE:24b

References add_bytes(), alecto_ws1200v2_dcf_callback(), bitbuffer::bb, bitbuffer_extract_bytes(), bitrow_printf(), bitbuffer::bits_per_row, emontx::crc, crc8(), DATA_DOUBLE, DATA_FORMAT, DATA_INT, data_make(), DATA_STRING, decoder_output_data(), and r_device::verbose.

Referenced by fineoffset_WH0530_callback().

◆ alecto_ws1200v2_dcf_callback()

static int alecto_ws1200v2_dcf_callback ( r_device decoder,
bitbuffer_t bitbuffer 
)
static

Alecto WS-1200 V2.0 DCF77 decoder by Christian Zuckschwerdt, documentation by Andreas Untergasser, help by curlyel.

A Thermometer with clock and wireless rain unit with temperature sensor.

Manual available at https://www.alecto.nl/media/blfa_files/WS-1200_manual_NL-FR-DE-GB_V2.2_8712412532964.pdf

Data layout:

1111111 FFFFFFFF IIIIIIII B??????? ..YY..YY ..MM..MM ..DD..DD ..HH..HH ..MM..MM ..SS..SS CCCCCCCC AAAAAAAA
  • 1: 7 bit preamble of 1's
  • F: 8 bit fixed message type (0x52)
  • I: 8 bit random sensor ID, changes at battery change
  • B: 1 bit low battery indicator
  • ?: 7 bit unknown
  • T: 10 bit temperature in Celsius offset 40 scaled by 10
  • R: 16 bit (little endian) rain count in 0.3 mm steps, absolute with wrap around at 65536
  • C: 8 bit CRC-8 poly 0x31 init 0x0 for 10 bytes
  • A: 8 bit checksum (addition)

Format string:

PRE:7b TYPE:8b ID:8b BATT:1b ?:1b ?:8b YY:4d YY:4d MM:4d MM:4d DD:4d DD:4d HH:4d HH:4d MM:4d MM:4d SS:4d SS:4d ?:16b

References add_bytes(), bitbuffer::bb, bitbuffer_extract_bytes(), bitrow_printf(), bitbuffer::bits_per_row, emontx::crc, crc8(), DATA_INT, data_make(), DATA_STRING, decoder_output_data(), and r_device::verbose.

Referenced by alecto_ws1200v2_callback().

◆ fineoffset_WH0290_callback()

static int fineoffset_WH0290_callback ( r_device decoder,
bitbuffer_t bitbuffer 
)
static

Fine Offset Electronics WH0290 Wireless Air Quality Monitor Also: Ambient Weather PM25.

The sensor sends a package each ~10m. The bits are PCM modulated with Frequency Shift Keying.

Data layout: aa 2d d4 42 cc 41 9a 41 ae c1 99 9 FF DD ?P PP ?A AA CC BB

  • F: 8 bit Family Code?
  • D: 8 bit device id?
  • ?: 2 bits ?
  • P: 14 bit PM2.5 reading in ug/m3
  • ?: 2 bits ?
  • A: 14 bit PM10.0 reading in ug/m3
  • ?: 8 bits ?
  • C: 8 bit CRC checksum of the previous 6 bytes
  • B: 8 bit Bitsum (sum without carry, XOR) of the previous 7 bytes

References bitbuffer_extract_bytes(), bitbuffer_printf(), bitbuffer_search(), bitbuffer::bits_per_row, emontx::crc, crc8(), DATA_FORMAT, DATA_INT, data_make(), DATA_STRING, DECODE_ABORT_LENGTH, DECODE_FAIL_MIC, decoder_output_data(), preamble, and r_device::verbose.

Referenced by fineoffset_WH25_callback().

◆ fineoffset_WH0530_callback()

static int fineoffset_WH0530_callback ( r_device decoder,
bitbuffer_t bitbuffer 
)
static

Fine Offset Electronics WH0530 Temperature/Rain sensor protocol, also Agimex Rosenborg 35926 (sold in Denmark).

The sensor sends two identical packages of 71 bits each ~48s. The bits are PWM modulated with On Off Keying. Data consists of 7 bit preamble and 8 bytes.

Data layout: 38 a2 8f 02 00 ff e7 51 FI IT TT RR RR ?? CC AA

  • F: 4 bit fixed message type (0x3)
  • I: 8 bit Sensor ID (guess). Does not change at battery change.
  • B: 1 bit low battery indicator
  • T: 11 bit Temperature (+40*10) (Upper bit is Battery Low indicator)
  • R: 16 bit (little endian) rain count in 0.3 mm steps, absolute with wrap around at 65536
  • ?: 8 bit Always 0xFF (maybe reserved for humidity?)
  • C: 8 bit CRC-8 with poly 0x31 init 0x00
  • A: 8 bit Checksum of previous 7 bytes (addition truncated to 8 bit)

References add_bytes(), alecto_ws1200v1_callback(), alecto_ws1200v2_callback(), bitbuffer::bb, bitbuffer_extract_bytes(), bitrow_printf(), bitbuffer::bits_per_row, emontx::crc, crc8(), DATA_DOUBLE, DATA_FORMAT, DATA_INT, data_make(), DATA_STRING, DECODE_ABORT_EARLY, DECODE_ABORT_LENGTH, DECODE_FAIL_MIC, decoder_output_data(), and r_device::verbose.

◆ fineoffset_WH24_callback()

◆ fineoffset_WH25_callback()

static int fineoffset_WH25_callback ( r_device decoder,
bitbuffer_t bitbuffer 
)
static

Fine Offset Electronics WH25 / WH32B Temperature/Humidity/Pressure sensor protocol.

The sensor sends a package each ~64 s with a width of ~28 ms. The bits are PCM modulated with Frequency Shift Keying.

Example: 22.6 C, 40 %, 1001.7 hPa

[00] {500} 80 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 2a aa aa aa aa aa 8b 75 39 40 9c 8a 09 c8 72 6e ea aa aa 80 10

Data layout:

aa 2d d4 e5 02 72 28 27 21 c9 bb aa
         ?I IT TT HH PP PP CC BB
  • I: 8 bit Sensor ID (based on 2 different sensors). Does not change at battery change.
  • B: 1 bit low battery indicator
  • F: 1 bit invalid reading indicator
  • T: 10 bit Temperature (+40*10), top two bits are flags
  • H: 8 bit Humidity
  • P: 16 bit Pressure (*10)
  • C: 8 bit Checksum of previous 6 bytes (binary sum truncated to 8 bit)
  • B: 8 bit Bitsum (XOR) of the 6 data bytes (high and low nibble exchanged)

WH32B is the same as WH25 but two packets in one transmission of {971} and XOR sum missing. TYPE:4h ID:8d FLAGS:2b TEMP_C:10d HUM:8d HPA:16d CHK:8h

References add_bytes(), bitbuffer_extract_bytes(), bitbuffer_printf(), bitbuffer_search(), bitrow_printf(), bitbuffer::bits_per_row, DATA_DOUBLE, DATA_FORMAT, DATA_INT, data_make(), DATA_STRING, DECODE_ABORT_EARLY, DECODE_ABORT_LENGTH, DECODE_FAIL_MIC, decoder_output_data(), fineoffset_WH0290_callback(), fineoffset_WH24_callback(), preamble, r_device::verbose, and xor_bytes().

◆ fineoffset_WH2_callback()

static int fineoffset_WH2_callback ( r_device decoder,
bitbuffer_t bitbuffer 
)
static

Fine Offset Electronics WH2 Temperature/Humidity sensor protocol, also Agimex Rosenborg 66796 (sold in Denmark), collides with WH5, also ClimeMET CM9088 (Sold in UK), also TFA Dostmann/Wertheim 30.3157 (Temperature only!) (sold in Germany).

The sensor sends two identical packages of 48 bits each ~48s. The bits are PWM modulated with On Off Keying.

The data is grouped in 6 bytes / 12 nibbles.

[pre] [pre] [type] [id] [id] [temp] [temp] [temp] [humi] [humi] [crc] [crc]

There is an extra, unidentified 7th byte in WH2A packages.

  • pre is always 0xFF
  • type is always 0x4 (may be different for different sensor type?)
  • id is a random id that is generated when the sensor starts
  • temp is 12 bit signed magnitude scaled by 10 celsius
  • humi is 8 bit relative humidity percentage

Based on reverse engineering with gnu-radio and the nice article here: http://lucsmall.com/2012/04/29/weather-station-hacking-part-2/

References bitbuffer::bb, bitbuffer_extract_bytes(), bitbuffer::bits_per_row, crc8(), DATA_DOUBLE, DATA_FORMAT, DATA_INT, data_make(), DATA_STRING, DECODE_ABORT_LENGTH, r_device::decode_ctx, DECODE_FAIL_MIC, DECODE_FAIL_SANITY, decoder_output_data(), emontx::temp, and r_device::verbose.

◆ fineoffset_WH2_create()

static r_device* fineoffset_WH2_create ( char *  arg)
static

Variable Documentation

◆ fineoffset_WH0530

r_device fineoffset_WH0530
Initial value:
= {
.name = "Fine Offset Electronics, WH0530 Temperature/Rain Sensor",
.modulation = OOK_PULSE_PWM,
.short_width = 504,
.long_width = 1480,
.reset_limit = 1200,
.sync_width = 0,
.tolerance = 160,
.disabled = 0,
}
Pulse Width Modulation with precise timing parameters.
Definition: r_device.h:13
static char * output_fields_WH0530[]
Definition: fineoffset.c:834
static int fineoffset_WH0530_callback(r_device *decoder, bitbuffer_t *bitbuffer)
Fine Offset Electronics WH0530 Temperature/Rain sensor protocol, also Agimex Rosenborg 35926 (sold in...
Definition: fineoffset.c:746

◆ fineoffset_WH2

r_device fineoffset_WH2
Initial value:
= {
.name = "Fine Offset Electronics, WH2, WH5, Telldus Temperature/Humidity/Rain Sensor",
.modulation = OOK_PULSE_PWM,
.short_width = 500,
.long_width = 1500,
.reset_limit = 1200,
.tolerance = 160,
.decode_fn = &fineoffset_WH2_callback,
.create_fn = &fineoffset_WH2_create,
.disabled = 0,
.fields = output_fields,
}
static char * output_fields[]
Definition: fineoffset.c:800
static r_device * fineoffset_WH2_create(char *arg)
Definition: fineoffset.c:18
Pulse Width Modulation with precise timing parameters.
Definition: r_device.h:13
unsigned disabled
Definition: r_device.h:55
static int fineoffset_WH2_callback(r_device *decoder, bitbuffer_t *bitbuffer)
Fine Offset Electronics WH2 Temperature/Humidity sensor protocol, also Agimex Rosenborg 66796 (sold i...
Definition: fineoffset.c:54

◆ fineoffset_WH25

r_device fineoffset_WH25
Initial value:
= {
.name = "Fine Offset Electronics, WH25, WH32B, WH24, WH65B, HP1000 Temperature/Humidity/Pressure Sensor",
.modulation = FSK_PULSE_PCM,
.short_width = 58,
.long_width = 58,
.reset_limit = 20000,
.decode_fn = &fineoffset_WH25_callback,
.disabled = 0,
.fields = output_fields_WH25,
}
static char * output_fields_WH25[]
Definition: fineoffset.c:809
static int fineoffset_WH25_callback(r_device *decoder, bitbuffer_t *bitbuffer)
Fine Offset Electronics WH25 / WH32B Temperature/Humidity/Pressure sensor protocol.
Definition: fineoffset.c:416
FSK, Pulse Code Modulation.
Definition: r_device.h:19

◆ output_fields

char* output_fields[]
static
Initial value:
= {
"model",
"id",
"temperature_C",
"humidity",
"mic",
NULL,
}

◆ output_fields_WH0530

char* output_fields_WH0530[]
static
Initial value:
= {
"model",
"id",
"temperature_C",
"rain",
"rain_mm",
"battery",
"radio_clock",
"mic",
NULL,
}

◆ output_fields_WH25

char* output_fields_WH25[]
static
Initial value:
= {
"model",
"id",
"temperature_C",
"humidity",
"pressure_hPa",
"wind_dir_deg",
"wind_speed_ms",
"gust_speed_ms",
"wind_avg_m_s",
"wind_max_m_s",
"rainfall_mm",
"rain_mm",
"uv",
"uvi",
"light_lux",
"pm2_5_ug_m3",
"pm10_0_ug_m3",
"battery",
"mic",
NULL,
}