enable remote var
This commit is contained in:
parent
c99348bb72
commit
fa77085e9a
2 changed files with 9 additions and 9 deletions
|
|
@ -12,7 +12,7 @@
|
|||
platform = espressif32
|
||||
board = wt32-eth01
|
||||
framework = arduino
|
||||
lib_deps = siwats/ESPMegaPROR3@^2.2.4
|
||||
lib_deps = siwats/ESPMegaPROR3@^2.2.5
|
||||
monitor_speed = 115200
|
||||
build_flags = -DCORE_DEBUG_LEVEL=5
|
||||
upload_port = COM28
|
||||
|
|
|
|||
16
src/main.cpp
16
src/main.cpp
|
|
@ -1,8 +1,8 @@
|
|||
#include <main.hpp>
|
||||
|
||||
// RemoteVariable pm25_out = RemoteVariable();
|
||||
// RemoteVariable temp_out = RemoteVariable();
|
||||
// RemoteVariable weather = RemoteVariable();
|
||||
RemoteVariable pm25_out = RemoteVariable();
|
||||
RemoteVariable temp_out = RemoteVariable();
|
||||
RemoteVariable weather = RemoteVariable();
|
||||
|
||||
const char *mode_names[] = {"off", "fan_only", "cool"};
|
||||
const char *fan_speed_names[] = {"auto", "high", "medium", "low"};
|
||||
|
|
@ -109,11 +109,11 @@ void setup()
|
|||
// PM2.5 PPM Remote Variable
|
||||
// 12 bytes remote variable, 11 characters + null terminator
|
||||
// Enable value request at /iqair/pm25_request
|
||||
// pm25_out.begin(6, "/aqi/value", espmega.iot, true, "/aqi/value_request");
|
||||
// // Temperature Remote Variable
|
||||
// temp_out.begin(6, "/temp/value", espmega.iot, true, "/weather/temp_request");
|
||||
// // Weather Remote Variable
|
||||
// weather.begin(45, "/weather", espmega.iot, true, "/weather_request");
|
||||
pm25_out.begin(6, "/aqi/value", espmega.iot, true, "/aqi/value_request");
|
||||
// Temperature Remote Variable
|
||||
temp_out.begin(6, "/temp/value", espmega.iot, true, "/weather/temp_request");
|
||||
// Weather Remote Variable
|
||||
weather.begin(45, "/weather", espmega.iot, true, "/weather_request");
|
||||
}
|
||||
|
||||
void loop()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue