MC9S12XDT512: Large array in the flash.

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

MC9S12XDT512: Large array in the flash.

3,475 次查看
IgorN
Contributor II
Hi,
I'm working on the project created in CodeWarrior IDE v5.7.0 using the Project Wizard.
Now I need to define a array greated than 1 flash page size. Wich way I can to do it?
 
标签 (1)
0 项奖励
回复
8 回复数

874 次查看
CrasyCat
Specialist III
Hello
 
When you say your array is bigger than 1 flash page do you mean it is bigger than 16K or bigger than 64K?
What is your array size actually?
 
CrasyCat
0 项奖励
回复

874 次查看
IgorN
Contributor II
and may be 450K.
0 项奖励
回复

874 次查看
CrasyCat
Specialist III
Hello
 
CodeWarrior for HC12 does not allow to allocate an object across a page boundary.
If you are using global addresses in the .prm file you can have object up to 64K.
 
But you cannot have object with size bigger than this.
 
You will have to split your big data structure in portion which are not bigger than 64K.
 
If you decide to allocate an object across page boundary you will have to manage the page switch yourself.
The compiler will not do it for you.
 
CrasyCat 
0 项奖励
回复

874 次查看
IgorN
Contributor II
Did you can to take me any link or any document name(*.pdf etc) there it is wroten?
And where I can to read about global addresses definition in a *.prm file? I'm seeking for it but not found yet.
Just lot of thanks for your previos responce.
0 项奖励
回复

874 次查看
CrasyCat
Specialist III
Hello
 
You can define a global address in the .prm file using the suffix 'G.
 
For example
       RAM_BANKED = NO_INIT 0xF9000'G TO 0xF9FFF'G;
 
I would look in the Linker section of the Build_Tools_Utilities.pdf for more information.
 
CrasyCat
0 项奖励
回复

874 次查看
IgorN
Contributor II
Where can I to found this document. Google brings nothing:smileysad: by this name.
Is this suffix correct for EEPROM and flesh too? Wich kind of addresses must be there - phisical or logical?
0 项奖励
回复

874 次查看
allawtterb
Contributor IV
The pdf CrasyCat is referring to should already be on your computer.  Go to the folder where CodeWarrior was installed and it is under \Help\PDF.  Hope this helps. 
0 项奖励
回复

874 次查看
CrasyCat
Specialist III
Hello
 
In the example I provided, the addresses are global addresses (address in global address space).
 
CrasyCat
0 项奖励
回复