I am trying to compile a simple sketch for Arduino Nano and Uno (Atmega328), but I'm getting the same error for both these boards. I included 3 libraries and the dynamic memory usage jumped up to 155%!.
Now I know that these libraries are not that large, so what may be wrong in my setup? I am not getting this error with my SAMD21 board.
I have tried updating my Arduino AVR Boards to version 1.6.23 but that didn't fix the problem.
#include <SPI.h>
#include <nRF24L01.h>
#include <RF24.h>
RF24 radio(7, 8); // CE, CSN
const byte address[6] = "00001";
void setup() {
}
void loop() {
}
The Compiler output:
Sketch uses 6266 bytes (19%) of program storage space. Maximum is 32256 bytes.
Global variables use 3183 bytes (155%) of dynamic memory, leaving -1135 bytes for local variables. Maximum is 2048 bytes.
Not enough memory; see http://www.arduino.cc/en/Guide/Troubleshooting#size for tips on reducing your footprint.
Error compiling for board Arduino/Genuino Uno.