Add support for Hydreon RG-15 Solid State Rain sensor

Add support for Hydreon RG-15 Solid State Rain sensor (#12974)
This commit is contained in:
Theo Arends 2021-08-25 17:25:11 +02:00
parent dff83c1dfa
commit d4f444a85a
35 changed files with 68 additions and 62 deletions

View File

@ -9,6 +9,7 @@ All notable changes to this project will be documented in this file.
- Support for IEM3155 Wattmeter (#12940)
- Berry support for vararg
- Command ``Subscribe2 ...`` to subscribe to a MQTT topic without appended "/#" (#12858)
- Support for Hydreon RG-15 Solid State Rain sensor (#12974)
### Changed
- Shelly EM template needs to use GPIO ADE7953_IRQ_2

View File

@ -122,6 +122,7 @@ The latter links can be used for OTA upgrades too like ``OtaUrl http://ota.tasmo
- Inital support for Wi-Fi extender [#12784](https://github.com/arendst/Tasmota/issues/12784)
- Command ``Subscribe2 ...`` to subscribe to a MQTT topic without appended "/#" [#12858](https://github.com/arendst/Tasmota/issues/12858)
- Support for IEM3155 Wattmeter [#12940](https://github.com/arendst/Tasmota/issues/12940)
- Support for Hydreon RG-15 Solid State Rain sensor [#12974](https://github.com/arendst/Tasmota/issues/12974)
### Changed
- Move firmware binaries to https://github.com/arendst/Tasmota-firmware/tree/main/release-firmware

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -835,8 +835,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "Effetto hall"
#define D_SENSOR_EPD_DATA "EPD - Dati"
#define D_SENSOR_MCP2515_CS "MCP2515 - CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "Efekt Halla"
#define D_SENSOR_EPD_DATA "EPD Dane"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "Efeito Hall"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "Efeito Hall"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "А"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "А"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "A"

View File

@ -836,8 +836,8 @@
#define D_SENSOR_HALLEFFECT "HallEffect"
#define D_SENSOR_EPD_DATA "EPD Data"
#define D_SENSOR_MCP2515_CS "MCP2515 CS"
#define D_SENSOR_HRG15_RX "HRG15 RX"
#define D_SENSOR_HRG15_TX "HRG15 TX"
#define D_SENSOR_HRG15_RX "HRG15 Rx"
#define D_SENSOR_HRG15_TX "HRG15 Tx"
// Units
#define D_UNIT_AMPERE "安培"

View File

@ -743,6 +743,7 @@
//#define USE_AS608 // Add support for AS608 optical and R503 capacitive fingerprint sensor (+3k code)
// #define USE_AS608_MESSAGES // Add verbose error messages (+0k4 code)
//#define USE_TFMINIPLUS // Add support for TFmini Plus (TFmini, TFmini-S) LiDAR modules via UART interface (+0k8)
//#define USE_HRG15 // Add support for Hydreon RG-15 Solid State Rain sensor (+1k5 code)
// -- Power monitoring sensors --------------------
#define USE_ENERGY_SENSOR // Add support for Energy Monitors (+14k code)

View File

@ -762,8 +762,9 @@ void ResponseAppendFeatures(void)
#ifdef USE_INFLUXDB
feature8 |= 0x00000800; // xdrv_59_influxdb.ino
#endif
// feature8 |= 0x00001000;
#ifdef USE_HRG15
feature8 |= 0x00001000; // xsns_90_hrg15.ino
#endif
// feature8 |= 0x00002000;
// feature8 |= 0x00004000;
// feature8 |= 0x00008000;

View File

@ -188,6 +188,7 @@
// #define USE_PROJECTOR_CTRL_OPTOMA // Use codes for OPTOMA
//#define USE_AS608 // Add support for AS608 optical and R503 capacitive fingerprint sensor (+3k4 code)
//#define USE_TFMINIPLUS // Add suppoer for TFmini Plus (TFmini, TFmini-S) LiDAR modules via UART interface
//#define USE_HRG15 // Add support for Hydreon RG-15 Solid State Rain sensor (+1k5 code)
#define USE_ENERGY_SENSOR // Add energy sensors (-14k code)
#define USE_PZEM004T // Add support for PZEM004T Energy monitor (+2k code)

View File

@ -476,6 +476,7 @@
// #define USE_PROJECTOR_CTRL_OPTOMA // Use codes for OPTOMA
//#define USE_AS608 // Add support for AS608 optical and R503 capacitive fingerprint sensor (+3k4 code)
//#define USE_TFMINIPLUS // Add support for TFmini Plus (TFmini, TFmini-S) LiDAR modules via UART interface
//#define USE_HRG15 // Add support for Hydreon RG-15 Solid State Rain sensor (+1k5 code)
#define USE_ENERGY_SENSOR // Add energy sensors (-14k code)
#define USE_PZEM004T // Add support for PZEM004T Energy monitor (+2k code)

View File

@ -170,7 +170,7 @@ enum UserSelectablePins {
GPIO_I2S_IN_DATA, GPIO_I2S_IN_CLK, GPIO_I2S_IN_SLCT,
GPIO_INTERRUPT,
GPIO_MCP2515_CS, // MCP2515 Chip Select
GPIO_HRG15_RX, GPIO_HRG15_TX, // Hydreon RG-15 rain sensor serial interface
GPIO_HRG15_TX, GPIO_HRG15_RX, // Hydreon RG-15 rain sensor serial interface
GPIO_SENSOR_END };
enum ProgramSelectablePins {
@ -361,7 +361,7 @@ const char kSensorNames[] PROGMEM =
D_SENSOR_I2S_IN_DATA "|" D_SENSOR_I2S_IN_CLK "|" D_SENSOR_I2S_IN_SLCT "|"
D_SENSOR_INTERRUPT "|"
D_SENSOR_MCP2515_CS "|"
D_SENSOR_HRG15_RX "|" D_SENSOR_HRG15_TX
D_SENSOR_HRG15_TX "|" D_SENSOR_HRG15_RX
;
const char kSensorNamesFixed[] PROGMEM =
@ -794,8 +794,8 @@ const uint16_t kGpioNiceList[] PROGMEM = {
AGPIO(GPIO_AS608_RX),
#endif
#ifdef USE_HRG15
AGPIO(GPIO_HRG15_RX),
AGPIO(GPIO_HRG15_TX),
AGPIO(GPIO_HRG15_RX),
#endif
/*-------------------------------------------------------------------------------------------*\

View File

@ -1,7 +1,7 @@
/*
xsns_90-hrg15.ino - Hydreon RG-15 support for Tasmota
Copyright (c) 2021 Wouter Breukink
Copyright (c) 2021 Wouter Breukink
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
@ -93,7 +93,7 @@ bool Rg15Poll(void) {
while (HydreonSerial->available()) {
Rg15ReadLine(rg15_buffer);
AddLog(LOG_LEVEL_DEBUG_MORE,PSTR("%s:" D_JSON_SERIALRECEIVED " = %s"),"HRG", rg15_buffer);
Rg15Process(rg15_buffer);
}
@ -127,7 +127,7 @@ bool Rg15ReadLine(char* buffer)
}
void Rg15Process(char* buffer) {
// Process payload, example: Acc 0.01 mm, EventAcc 2.07 mm, TotalAcc 54.85 mm, RInt 2.89 mmph
Rg15.received = 1;
Rg15.acc = Rg15Parse(buffer, "Acc");

View File

@ -256,7 +256,7 @@ a_features = [[
"USE_MPU_ACCEL","USE_TFMINIPLUS","USE_CSE7761","USE_BERRY",
"USE_BM8563","USE_ENERGY_DUMMY","USE_AM2320","USE_T67XX",
"USE_MCP2515","USE_TASMESH","USE_WIFI_RANGE_EXTENDER","USE_INFLUXDB",
"","","","",
"USE_HRG15","","","",
"","","","",
"","","","",
"","","","",
@ -288,7 +288,7 @@ else:
obj = json.load(fp)
def StartDecode():
print ("\n*** decode-status.py v20210812 by Theo Arends and Jacek Ziolkowski ***")
print ("\n*** decode-status.py v20210825 by Theo Arends and Jacek Ziolkowski ***")
# print("Decoding\n{}".format(obj))