This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Incorrect scatterloading!!!

Hi,I'm using AT91SAM9260-EK to develop prototype of a Thermal Printer.
I'm using the MDK3.50 & ARM-RL3.50 and AT91SAM9260-EK code example as framework of my project. The problem is with the scatter-loading or variable initialization.
When code size(including const data like fonts etc) is less then the scatter-loading works fine but when I increase the size of code adding some more function, big arrays of constant data etc then the scatter-loading malfunctions. Since the scatter-loading, variable initialization, copying data from ROM to RAM all are done by library functions I don't have control over it and can't able to debug where is the mistake..

Pls suggest me what should I do in such situation.
Thanks

Parents Reply Children
  • > when I increase the size of code adding some more function, big arrays of constant data etc then the scatter-loading malfunctions.

    If ignore the above, and only focus on the below.

    > The problem arises when I uses lot of const data array(ie when I add more numbers of fonts to my printer code).

    Program execute properly till BL __main (in AT91SAM9.s), after that it could not reach to int main(void), rather it reach to sys_exit() in Retraget.c.

    (I don't know much about this.)

    Just another shot in the dark:

    It sounds like a Stack/Heap Size problem to me. Please make sure you provide enough space for your Stack/Heap.

  • On some chips, you can get into troubles with the watchdog - if it is activated in the startup file, it may take too long to reach main().