Skip to content

Commit

Permalink
20230708 Added SENSOR_TYPE_WEATHER_7IN1 and startup flag
Browse files Browse the repository at this point in the history
  • Loading branch information
matthias-bs committed Jul 8, 2023
1 parent 0439ddc commit 1010ad4
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions examples/BresserWeatherSensorMQTTCustom/src/WeatherSensor.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
// 20230328 Added MSG_BUF_SIZE
// 20230330 Added changes for Adafruit Feather 32u4 LoRa Radio
// 20230412 Added workaround for Professional Wind Gauge / Anemometer, P/N 7002531
// 20230708 Added SENSOR_TYPE_WEATHER_7IN1 and startup flag
//
// ToDo:
// -
Expand All @@ -72,11 +73,12 @@


// Sensor Types
// 0 - Weather Station 5-in-1; PN 7002510..12/7902510..12
// 1 - Weather Station 6-in-1; PN 7002585
// 2 - Thermo-/Hygro-Sensor 6-in-1; PN 7009999
// 4 - Soil Moisture Sensor 6-in-1; PN 7009972
// 9 - Professional Rain Gauge (5-in-1 decoder)
// 0 - Weather Station 5-in-1; PN 7002510..12/7902510..12
// 1 - Weather Station 6-in-1; PN 7002585
// 2 - Thermo-/Hygro-Sensor 6-in-1; PN 7009999
// 4 - Soil Moisture Sensor 6-in-1; PN 7009972
// 9 - Professional Rain Gauge (5-in-1 decoder)
// 11 - Weather Sensor 7-in-1 7-in-1; PN 7003300
// ? - Air Quality Sensor
// ? - Water Leakage Sensor
// ? - Pool Thermometer
Expand All @@ -86,6 +88,7 @@
#define SENSOR_TYPE_THERMO_HYGRO 2 // Thermo-/Hygro-Sensor
#define SENSOR_TYPE_SOIL 4 // Soil Temperature and Moisture (from 6-in-1 decoder)
#define SENSOR_TYPE_RAIN 9 // Professional Rain Gauge (from 5-in-1 decoder)
#define SENSOR_TYPE_WEATHER_7IN1 11 // Weather Sensor 7-in-1


// Sensor specific rain gauge overflow threshold (mm)
Expand Down Expand Up @@ -181,6 +184,7 @@ class WeatherSensor {
uint32_t sensor_id; //!< sensor ID (5-in-1: 1 byte / 6-in-1: 4 bytes)
uint8_t s_type; //!< sensor type (only 6-in1)
uint8_t chan; //!< channel (only 6-in-1)
bool startup = false; //!< startup after reset / battery change
bool valid; //!< data valid (but not necessarily complete)
bool complete; //!< data is split into two separate messages is complete (only 6-in-1 WS)
bool temp_ok = false; //!< temperature o.k. (only 6-in-1)
Expand Down

0 comments on commit 1010ad4

Please sign in to comment.