ESP8266 BSP for larger flash sizes

Sysprogs forums Forums VisualGDB ESP8266 BSP for larger flash sizes

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #7425
    Han Vertegaal
    Participant

    Hi,

    After adding some code to the FreeRTOS HTTPDemo sample, the linker reports that the code no longer fits in the ‘irom0_0_seg’ region. This region is only 240K in the default linker file eagle.app.v6.ld. My 32M ESP12E supports a larger size than that. Overwriting the MEMORY description in eagle.app.v6.ld with the one from eagle.app.v6.new.2048.ld allowed the linker to do it’s work, but then an error occurred during flashing: ‘Failed to start flash operation’ (I believe the message appeared after flashing the boot segment). Finally I tried to add a new MCU entry in the BSP.xml file, pointing to the eagle.app.v6.new.2048.ld file, and with a lager flash size, but that didn’t help because the same flash error occurred.

    What is the correct procedure for increasing the size of the flash memory for my project?

    If I want to create an image without the GDB stub, I need to change the Embedded device settings in the VisualGDB Project Properties. Is there a way to have this done by – for instance – selecting a release build vs a debug build?

     

     

    #7476
    ivanroberto
    Participant

    Hi Han Vertegaal,

    I figured out this issue.
    You need to change the file eagle.app.v6.ld
    It is on the folder ld of your choosen SDK (RTOS or NOOS)
    Choose line 29 to: irom0_0_seg : org = 0x40210000, len = 0x5C000
    Of course you can try another numbers, but look in the documentation (ESP8266 FOTA Introduction) for more information
    Good luck

     

     

    Chees

    #7479
    Han Vertegaal
    Participant

    Thank you ivanroberto! That helped. Now I can flash finally flash my code.

    I’m not sure whether this change is the ‘approved’ method to support a larger device, but for now it works. The original segment length was 240K, and the change you proposed increased that to 368K. For a 4MB device (ESP12E) that is still less than I would expect to be able to use. The file eagle.app.v6.new.2048.ld contains a size of 0xE0000 = 896K, which I will now use to get me some extra space. As my application grows I will eventually find out what the real available length is.

    Thanks again.

     

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.