BME 680 support: payload converters addes
This commit is contained in:
1 parent
2b96f6e0bf
commit
ddd5764a8b
8 files changed
+72
-23
No files matched your search
@@ -6,7 +6,6 @@
|
||||
#include <Adafruit_Sensor.h>
|
||||
#include "Adafruit_BME680.h"
|
||||
|
||||
extern Adafruit_BME680 bme; // Make bme instance globally availabe
|
||||
extern bmeStatus_t
|
||||
bme_status; // Make struct for storing gps data globally available
|
||||
|
||||
|
||||
+3
-3
@@ -47,10 +47,10 @@ typedef struct {
|
||||
} gpsStatus_t;
|
||||
|
||||
typedef struct {
|
||||
uint16_t temperature; // Temperature * 100 in degrees Centigrade
|
||||
float temperature; // Temperature in degrees Centigrade
|
||||
uint16_t pressure; // Barometic pressure in hecto pascals
|
||||
uint8_t humidity; // Relative humidity in percent
|
||||
uint32_t gas_resistance; // Resistance in Ohms
|
||||
float humidity; // Relative humidity in percent
|
||||
uint16_t gas_resistance; // Resistance in MOhms
|
||||
uint16_t altitude; // Altitude in meters
|
||||
} bmeStatus_t;
|
||||
|
||||
|
||||
+8
-2
@@ -10,19 +10,25 @@
|
||||
#define LPP_BATT_CHANNEL 23
|
||||
#define LPP_BUTTON_CHANNEL 24
|
||||
#define LPP_ADR_CHANNEL 25
|
||||
#define LPP_TEMP_CHANNEL 26
|
||||
#define LPP_TEMPERATURE_CHANNEL 26
|
||||
#define LPP_ALARM_CHANNEL 27
|
||||
#define LPP_MSG_CHANNEL 28
|
||||
#define LPP_HUMIDITY_CHANNEL 29
|
||||
#define LPP_BAROMETER_CHANNEL 30
|
||||
#define LPP_GAS_CHANNEL 31
|
||||
|
||||
#endif
|
||||
|
||||
// MyDevices CayenneLPP types
|
||||
#define LPP_GPS 136 // 3 byte lon/lat 0.0001 °, 3 bytes alt 0.01m
|
||||
#define LPP_TEMPERATURE 103 // 2 bytes, 0.1°C signed
|
||||
#define LPP_TEMPERATURE 103 // 2 bytes, 0.1°C signed MSB
|
||||
#define LPP_DIGITAL_INPUT 0 // 1 byte
|
||||
#define LPP_DIGITAL_OUTPUT 1 // 1 byte
|
||||
#define LPP_ANALOG_INPUT 2 // 2 bytes, 0.01 signed
|
||||
#define LPP_LUMINOSITY 101 // 2 bytes, 1 lux unsigned
|
||||
#define LPP_PRESENCE 102 // 1 byte
|
||||
#define LPP_HUMIDITY 104 // 1 byte, 0.5 % unsigned
|
||||
#define LPP_BAROMETER 115 // 2 bytes, hPa unsigned MSB
|
||||
|
||||
class PayloadConvert {
|
||||
|
||||
|
||||
Reference in new issue
Block a user