Skip to content

Commit 336ee28

Browse files
Add support for Oregon Scientific AWR129 BBQ thermometer (#2439)
1 parent 354ffde commit 336ee28

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/devices/oregon_scientific.c

+4-2
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
#define ID_RGR968 0x2d10
2323
#define ID_THR228N 0xec40
2424
#define ID_THN132N 0xec40 // same as THR228N but different packet size
25+
#define ID_AWR129 0xec41 // same as THR228N
2526
#define ID_RTGN318 0x0cc3 // warning: id is from 0x0cc3 and 0xfcc3
2627
#define ID_RTGN129 0x0cc3 // same as RTGN318 but different packet size
2728
#define ID_THGR810 0xf824 // This might be ID_THGR81, but what's true is lost in (git) history
@@ -368,13 +369,14 @@ static int oregon_scientific_v2_1_decode(r_device *decoder, bitbuffer_t *bitbuff
368369
decoder_output_data(decoder, data);
369370
return 1;
370371
}
371-
else if (sensor_id == ID_THR228N && msg_bits == 76) {
372+
else if ((sensor_id == ID_THR228N || sensor_id == ID_AWR129) && msg_bits == 76) {
372373
if (validate_os_v2_message(decoder, msg, 76, msg_bits, 12) != 0)
373374
return 0;
374375
float temp_c = get_os_temperature(msg);
375376
/* clang-format off */
376377
data = data_make(
377-
"model", "", DATA_STRING, "Oregon-THR228N",
378+
"model", "", DATA_COND, sensor_id == ID_THR228N, DATA_STRING, "Oregon-THR228N",
379+
"model", "", DATA_COND, sensor_id == ID_AWR129, DATA_STRING, "Oregon-AWR129",
378380
"id", "House Code", DATA_INT, get_os_rollingcode(msg),
379381
"channel", "Channel", DATA_INT, get_os_channel(msg, sensor_id),
380382
"battery_ok", "Battery", DATA_INT, !get_os_battery(msg),

0 commit comments

Comments
 (0)