mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-29 05:36:39 +00:00
Add support for HDC1080
Add support for HDC1080 Temperature and Humidity sensor by Luis Teixeira (#7888)
This commit is contained in:
parent
af1e2f73a5
commit
5235ad1757
@ -117,3 +117,4 @@ The following binary downloads have been compiled with ESP8266/Arduino library c
|
||||
- Add support for MaxBotix HRXL-MaxSonar ultrasonic range finders by Jon Little (#7814)
|
||||
- Add support for Romanian language translations by Augustin Marti
|
||||
- Add HAss Discovery support for Button and Switch triggers by Federico Leoni (#7901)
|
||||
- Add support for HDC1080 Temperature and Humidity sensor by Luis Teixeira (#7888)
|
||||
|
@ -3,6 +3,7 @@
|
||||
### 8.1.0.11 20200313
|
||||
|
||||
- Add HAss Discovery support for Button and Switch triggers by Federico Leoni (#7901)
|
||||
- Add support for HDC1080 Temperature and Humidity sensor by Luis Teixeira (#7888)
|
||||
|
||||
### 8.1.0.10 20200227
|
||||
|
||||
|
@ -494,10 +494,9 @@
|
||||
// #define USE_DS1624 // [I2cDriver42] Enable DS1624, DS1621 temperature sensor (I2C addresses 0x48 - 0x4F) (+1k2 code)
|
||||
// #define USE_AHT1x // [I2cDriver43] Enable AHT10/15 humidity and temperature sensor (I2C address 0x38) (+0k8 code)
|
||||
// #define USE_WEMOS_MOTOR_V1 // [I2cDriver44] Enable Wemos motor driver V1 (I2C addresses 0x2D - 0x30) (+0k7 code)
|
||||
// #define USE_HDC1080 // [I2cDriver92] Enable HDC1080 temperature/humidity sensor
|
||||
|
||||
// #define WEMOS_MOTOR_V1_ADDR 0x30 // Default I2C address 0x30
|
||||
// #define WEMOS_MOTOR_V1_FREQ 1000 // Default frequency
|
||||
// #define USE_HDC1080 // [I2cDriver45] Enable HDC1080 temperature/humidity sensor (I2C address 0x40) (+1k5 code)
|
||||
|
||||
// #define USE_DISPLAY // Add I2C Display Support (+2k code)
|
||||
#define USE_DISPLAY_MODES1TO5 // Enable display mode 1 to 5 in addition to mode 0
|
||||
|
@ -323,6 +323,7 @@ void GetFeatures(void)
|
||||
#ifdef USE_TM1638
|
||||
feature_sns1 |= 0x80000000; // xsns_28_tm1638.ino
|
||||
#endif
|
||||
|
||||
/*********************************************************************************************/
|
||||
|
||||
feature_sns2 = 0x00000000;
|
||||
@ -538,7 +539,9 @@ void GetFeatures(void)
|
||||
#ifdef USE_SONOFF_D1
|
||||
feature6 |= 0x00000004; // xdrv_37_sonoff_d1.ino
|
||||
#endif
|
||||
// feature6 |= 0x00000008;
|
||||
#ifdef USE_HDC1080
|
||||
feature6 |= 0x00000008; // xsns_65_hdc1080.ino
|
||||
#endif
|
||||
|
||||
// feature6 |= 0x00000010;
|
||||
// feature6 |= 0x00000020;
|
||||
|
@ -182,12 +182,10 @@ extern "C" void custom_crash_callback(struct rst_info * rst_info, uint32_t stack
|
||||
#define USE_DHT12 // Add I2C code for DHT12 temperature and humidity sensor (+0k7 code)
|
||||
#define USE_DS1624 // Add I2C code for DS1624, DS1621 sensor
|
||||
//#define USE_AHT1x // Enable AHT10/15 humidity and temperature sensor (I2C address 0x38) (+0k8 code)
|
||||
//#define USE_HDC1080 // Enable HDC1080 temperature/humidity sensor
|
||||
|
||||
|
||||
#define USE_WEMOS_MOTOR_V1 // Enable Wemos motor driver V1 (I2C addresses 0x2D - 0x30) (+0k7 code)
|
||||
#define WEMOS_MOTOR_V1_ADDR 0x30 // Default I2C address 0x30
|
||||
#define WEMOS_MOTOR_V1_FREQ 1000 // Default frequency
|
||||
//#define USE_HDC1080 // Enable HDC1080 temperature/humidity sensor
|
||||
|
||||
#define USE_MHZ19 // Add support for MH-Z19 CO2 sensor (+2k code)
|
||||
#define USE_SENSEAIR // Add support for SenseAir K30, K70 and S8 CO2 sensor (+2k3 code)
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
xsns_92_hdc1080.ino - Texas Instruments HDC1080 temperature and humidity sensor support for Tasmota
|
||||
xsns_65_hdc1080.ino - Texas Instruments HDC1080 temperature and humidity sensor support for Tasmota
|
||||
|
||||
Copyright (C) 2020 Luis Teixeira
|
||||
|
||||
@ -238,7 +238,7 @@ bool HdcRead(void) {
|
||||
|
||||
void HdcDetect(void) {
|
||||
if (I2cActive(HDC1080_ADDR)) {
|
||||
AddLog_P2(LOG_LEVEL_DEBUG, PSTR("HdcDetect: Address = 0x%02X already in use."), HDC1080_ADDR);
|
||||
// AddLog_P2(LOG_LEVEL_DEBUG, PSTR("HdcDetect: Address = 0x%02X already in use."), HDC1080_ADDR);
|
||||
|
||||
return;
|
||||
}
|
||||
@ -309,7 +309,7 @@ void HdcShow(bool json) {
|
||||
bool Xsns65(uint8_t function)
|
||||
{
|
||||
if (!I2cEnabled(XI2C_45)) {
|
||||
AddLog_P(LOG_LEVEL_DEBUG, PSTR("Xsns65: I2C driver not enabled for this device."));
|
||||
// AddLog_P(LOG_LEVEL_DEBUG, PSTR("Xsns65: I2C driver not enabled for this device."));
|
||||
|
||||
return false;
|
||||
}
|
||||
|
@ -198,7 +198,7 @@ a_features = [[
|
||||
"USE_NRF24","USE_MIBLE","USE_HM10","USE_LE01MR",
|
||||
"USE_AHT1x","USE_WEMOS_MOTOR_V1","USE_DEVICE_GROUPS","USE_PWM_DIMMER"
|
||||
],[
|
||||
"USE_KEELOQ","USE_HRXL","USE_SONOFF_D1","",
|
||||
"USE_KEELOQ","USE_HRXL","USE_SONOFF_D1","USE_HDC1080",
|
||||
"","","","",
|
||||
"","","","",
|
||||
"","","","",
|
||||
@ -239,7 +239,7 @@ else:
|
||||
obj = json.load(fp)
|
||||
|
||||
def StartDecode():
|
||||
print ("\n*** decode-status.py v20200305 by Theo Arends and Jacek Ziolkowski ***")
|
||||
print ("\n*** decode-status.py v20200314 by Theo Arends and Jacek Ziolkowski ***")
|
||||
|
||||
# print("Decoding\n{}".format(obj))
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user