Is there a limitation on the usage of static/global objects ?
When instantiating a global object from my local library the board freezes (both stm32f103 & stm32f411)'
Minimal sketch :
Code: Select all
#include "CommandProcessing.h"
CommandHandler* commandHandler = new CommandHandler; -> Fails
CommandHanlder commandHandler; -> Fails
CommandHandler* commandHandler; // + new in setup -> OK.
void setup() {
// commandHandler = new CommandHandler;
pinMode(PC13,OUTPUT);
digitalWrite(PC13,HIGH);
}
void loop() {
delay(500);
digitalToggle(PC13);
}
Did not get into the implementation details as I would like to know the eventual limitations first.