This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

bootloader ram usage

Hello,

in the current project we use a large array (16kB) in RAM to store data. After a reset we would like to check if the array is not corrupted to continue processing new data.

The problem is that we use a bootloader to make dfu updates, but we don't know how many ram should be available for the application check and so on.

Main goal is to reserve the large array in application and bootloader.

Best regards 

Parents
  • Hi,

    The RAM buffer will get overwritten by the bootloader on startup if the buffer overlaps with bootloader data, which is not unlikely if you're letting the linker place automatically. The easiest solution to avoid is maybe to place the buffer at the end of RAM above your call stack. This must be done for both your bootloader and application project.

    Have you verified that the buffer is retained when you don't have the bootloader present? 

    Best regards,

    Vidar

Reply
  • Hi,

    The RAM buffer will get overwritten by the bootloader on startup if the buffer overlaps with bootloader data, which is not unlikely if you're letting the linker place automatically. The easiest solution to avoid is maybe to place the buffer at the end of RAM above your call stack. This must be done for both your bootloader and application project.

    Have you verified that the buffer is retained when you don't have the bootloader present? 

    Best regards,

    Vidar

Children
No Data
Related