mirror of
https://github.com/IoTManagerProject/IoTManager.git
synced 2026-03-27 22:52:19 +03:00
Оптимизация Weather и owmWeather
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
#include <ArduinoJson.h>
|
||||
|
||||
long prevWeatherMillis = millis() - 60001;
|
||||
StaticJsonDocument<JSON_BUFFER_SIZE * 2> Weatherdoc;
|
||||
//StaticJsonDocument<JSON_BUFFER_SIZE * 2> Weatherdoc;
|
||||
|
||||
extern IoTGpio IoTgpio;
|
||||
class Weather : public IoTItem
|
||||
@@ -12,9 +12,9 @@ private:
|
||||
String _location;
|
||||
String _param;
|
||||
// long interval;
|
||||
|
||||
DynamicJsonDocument Weatherdoc;
|
||||
public:
|
||||
Weather(String parameters) : IoTItem(parameters)
|
||||
Weather(String parameters) : Weatherdoc(1024), IoTItem(parameters)
|
||||
{
|
||||
_location = jsonReadStr(parameters, "location");
|
||||
_param = jsonReadStr(parameters, "param");
|
||||
|
||||
Reference in New Issue
Block a user