Pumpkin, Inc.

Pumpkin User Forums

RAM Memory Clash

For issues specific to TI's MSP430 line of ultra-low-power microcontrollers, including compilers (e.g. Quadravox AQ430), IDEs (e.g. IAR Embedded Workbench) and development tools (e.g. TI MSP-FET430 Flash Emulation Tool).

RAM Memory Clash

Postby Syed Akbar » Fri Nov 11, 2005 1:26 am

Hi Sayed.

(Oops -- I accidentally edited your post instead of replying to it. Your question asked how to prevent Salvo (and C code) from accessing the same areas of RAM that existing assembly code uses ...)

In order to mix Assembly language and C, you (as the programmer) have to ensure that the C code places its variables in an area that is not used by your Assembly code.

All of Salvo's variables are prefixed by "OS", and they are all declared in Salvo's mem.c.

Probably the simplest thing for you to do is to create a custom linker file for your particular compiler and target MSP430, which restricts the amount of RAM available and its location(s) to the compiler. Then, you have to place your assembly-language variables so that they do not overlap those that the compiler will use.

This is really a question for your compiler vendor -- "How to I prevent the compiler from accessing certain areas of RAM memory?" or "How to exclude certain areas of RAM from use by the compiler / linker?"

[This message has been edited by aek (edited November 11, 2005).]

[This message has been edited by aek (edited November 11, 2005).]

Syed Akbar
Posts: 13
Joined: Sun May 22, 2005 11:00 pm
Location: Bremen, Bremen, Germany

Return to TI's MSP430

Who is online

Users browsing this forum: No registered users and 1 guest