diff --git a/code/espurna/config/arduino.h b/code/espurna/config/arduino.h index 16c0a58a..d5806215 100644 --- a/code/espurna/config/arduino.h +++ b/code/espurna/config/arduino.h @@ -27,6 +27,8 @@ //#define BLITZWOLF_BWSHPX_V23 //#define BLITZWOLF_BWSHP5 //#define DIGOO_NX_SP202 +//#define EHOMEDIY_WT02 +//#define EHOMEDIY_WT03 //#define ELECTRODRAGON_WIFI_IOT //#define ESPURNA_BASE //#define ESPURNA_CORE diff --git a/code/espurna/config/hardware.h b/code/espurna/config/hardware.h index bd878f4d..d1c381ec 100644 --- a/code/espurna/config/hardware.h +++ b/code/espurna/config/hardware.h @@ -4166,6 +4166,40 @@ #define SENSOR_ENERGY_UNITS ENERGY_KWH #define SENSOR_POWER_UNITS POWER_WATTS + +// ----------------------------------------------------------------------------- +// eHomeDIY WT02 +// https://github.com/eHomeDIY/WT02-hardware +// ----------------------------------------------------------------------------- +#elif defined(EHOMEDIY_WT02) + + // Info + #define MANUFACTURER "EHOMEDIY" + #define DEVICE "WT02" + + #define I2C_SDA_PIN 0 + #define I2C_SCL_PIN 2 + + #define BMX280_SUPPORT 1 + // #define SI7021_SUPPORT 1 + +// ----------------------------------------------------------------------------- +// eHomeDIY WT03 +// https://github.com/eHomeDIY/WT03-hardware +// ----------------------------------------------------------------------------- + +#elif defined(EHOMEDIY_WT03) + + // Info + #define MANUFACTURER "EHOMEDIY" + #define DEVICE "WT03" + + #define I2C_SDA_PIN 2 + #define I2C_SCL_PIN 0 + + #define BMX280_SUPPORT 1 + // #define SI7021_SUPPORT 1 + // ----------------------------------------------------------------------------- // Linksprite R4 // http://linksprite.com/wiki/index.php?title=LinkNode_R4:_Arduino-compatible_WiFi_relay_controller diff --git a/code/platformio.ini b/code/platformio.ini index 4599b33d..0b524e19 100644 --- a/code/platformio.ini +++ b/code/platformio.ini @@ -1702,3 +1702,23 @@ board = ${common.board_4m} build_flags = ${common.build_flags_4m1m} -DLINKSPRITE_LINKNODE_R4 upload_port = ${common.ota_upload_port} upload_flags = ${common.ota_upload_flags} + +[env:ehomediy-wt02] +board = ${common.board_1m} +build_flags = ${common.build_flags_1m0m} -DEHOMEDIY_WT02 + +[env:ehomediy-wt02-ota] +board = ${common.board_1m} +build_flags = ${common.build_flags_1m0m} -DEHOMEDIY_WT02 +upload_port = ${common.ota_upload_port} +upload_flags = ${common.ota_upload_flags} + +[env:ehomediy-wt03] +board = ${common.board_1m} +build_flags = ${common.build_flags_1m0m} -DEHOMEDIY_WT03 + +[env:ehomediy-wt03-ota] +board = ${common.board_1m} +build_flags = ${common.build_flags_1m0m} -DEHOMEDIY_WT03 +upload_port = ${common.ota_upload_port} +upload_flags = ${common.ota_upload_flags}