B4R Question ESP8266 PROGMEM error

Discussion in 'B4R Questions' started by Mostez, Jun 13, 2019.

  1. Mostez

    Mostez Active Member

    I tried to upload this code example to ESP8266, but I got that error message below, is it about a missing file or is there another method for ESP to include arrays into progmem.


    B4R Version: 2.60
    Parsing code. (0.00s)
    Building folders structure. (0.00s)
    Compiling code. (0.00s)
    Building project (0.00s)
    Compiling & deploying Ino project (Generic ESP8266 Module - COM10) Error
    Loading configuration...
    Initializing packages...
    Preparing boards...
    b4r_main.cpp:20:27: error: avr/pgmspace.h: No such file or directory
    #include <avr/pgmspace.h>
    compilation terminated.
    exit status 1
  2. Erel

    Erel Administrator Staff Member Licensed User

  3. Mostez

    Mostez Active Member

    Thanks so much, worked OK. Sorry if it's a stupid question, data array stored in program memory or RAM?
  4. Erel

    Erel Administrator Staff Member Licensed User

    Both. It is loaded into RAM when the program starts.

    PROGMEM is useful when programming smaller Arduino boards that only have 2k or less RAM.
    Mostez likes this.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice