This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

C Globals Initialzation.



 

I have an array that is not initialized to zero when main starts.  Two other integer variables were verified to correctly initialize to both 0, and a non zero value.  The zero initialized variable was explicitly initialed when declared i. e. int x - 6;

I am using a C28346 experimentors board and C code / tools.  I started with a default CCS project. 

  1. Does the runtime libary assumed a fixed range of ram to be for global data.
  2. If so, how can I change this.

My applicaiton has a large need for global variable space so I have greatly increased the size of .ebss as follows:

MEMORY

{

<CLIP>

PAGE 1 :

<CLIP>

RAML2 :

origin = 0x00C000, length = 0x00C000

/* RAML3 : origin = 0x00E000, length = 0x002000 */

/* RAML4 : origin = 0x010000, length = 0x002000 */

/* RAML5 : origin = 0x012000, length = 0x002000 */

/* RAML6 : origin = 0x014000, length = 0x004000 */

 

 

<clip>

}

SECTIONS

{

 

<CLIP>.ebss

: > RAML2, PAGE = 1

<CLIP>