move some vectors to psram, fix syslog start/stop

This commit is contained in:
MichaelDvP
2025-12-04 19:57:01 +01:00
parent dd0ab8f962
commit 1d03056784
28 changed files with 3172 additions and 70 deletions

View File

@@ -72,6 +72,9 @@
#include "command.h"
#include "../emsesp_version.h"
#ifndef EMSESP_STANDALONE
#include <esp32-psram.h>
#endif
// Load external modules
class Module {}; // forward declaration
@@ -220,8 +223,11 @@ class EMSESP {
static void scan_devices();
static void clear_all_devices();
#ifndef EMSESP_STANDALONE
static std::vector<std::unique_ptr<EMSdevice>, AllocatorPSRAM<std::unique_ptr<EMSdevice>>> emsdevices;
#else
static std::vector<std::unique_ptr<EMSdevice>> emsdevices;
#endif
// services
static Mqtt mqtt_;
static Modbus * modbus_;
@@ -266,8 +272,11 @@ class EMSESP {
const char * default_name;
uint8_t flags;
};
#ifndef EMSESP_STANDALONE
static std::vector<Device_record, AllocatorPSRAM<Device_record>> device_library_;
#else
static std::vector<Device_record> device_library_;
#endif
static uint16_t watch_id_;
static uint8_t watch_;
static uint16_t read_id_;