I try to declare a 2 dimensional Array at runtime:
class my_LOG
{
public:
private:
byte *linePointer;
String *message;
};
void my_LOG::begin(byte NumberOfLogs, byte NumberOfLines)
{
linePointer = new byte[NumberOfLogs]; \\ this works
message = new String[NumberOfLogs][NumberOfLines]; \\ this don´t work
}
How can this be done?
And further: How can this allocated to PSRAM?
Ive tried to do this with std::vector but this used all of RAM1.
class my_LOG
{
public:
private:
byte *linePointer;
String *message;
};
void my_LOG::begin(byte NumberOfLogs, byte NumberOfLines)
{
linePointer = new byte[NumberOfLogs]; \\ this works
message = new String[NumberOfLogs][NumberOfLines]; \\ this don´t work
}
How can this be done?
And further: How can this allocated to PSRAM?
Ive tried to do this with std::vector but this used all of RAM1.