Looking for simple relocatable example

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

Looking for simple relocatable example

跳至解决方案
3,969 次查看
e_taylor
Contributor III

Hello, I'm looking for a super simple relocatable assembly code example with a couple of asm files.

Thanks in advance!

Ed

0 项奖励
回复
1 解答
3,927 次查看
ZhangJennie
NXP TechSupport
NXP TechSupport

HI

Please enable "use text based project" , reopen CodeWarrior. then import my demo project again,

ZhangJennie_0-1625810800692.png

 

Have a nice day,

Jun Zhang

 

在原帖中查看解决方案

0 项奖励
回复
6 回复数
3,966 次查看
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi e_taylor,

What's your chip PN and what's your CodeWarrior version?

 

Thanks

Jun Zhang

0 项奖励
回复
3,962 次查看
e_taylor
Contributor III

Hello ZhangJennie,

Thank you for your prompt response!

9S12XDP512 and CW 5.2

Thank you again!

Ed

0 项奖励
回复
3,955 次查看
ZhangJennie
NXP TechSupport
NXP TechSupport

In assembly, we use SECTION directive to declare reloadable section. The syntax is :

<name>:  SECTION [SHORT][<number>]

<name> is the name assigned to the section. Two SECTION directives with the same name specified refer to the same section.

<number> is optional.

I just made a small sample on my side. See enclosed. In main.asm, asm_main is defined in MYASMCODE section, temp_byte is defined in MYASMRAM section. Please also see prm file.

 

Best Regards

Jun Zhang

0 项奖励
回复
3,950 次查看
e_taylor
Contributor III

Hello ZhangJennie,

Thank you for your prompt response again!

I was hoping for an assembly language example. The MCP file opened, but, it was not able to be compiled.

I have attached my test file that I have been trying to learn from.

Thank you very much for your help on this!

Have a wonderful day!

Ed

0 项奖励
回复
3,928 次查看
ZhangJennie
NXP TechSupport
NXP TechSupport

HI

Please enable "use text based project" , reopen CodeWarrior. then import my demo project again,

ZhangJennie_0-1625810800692.png

 

Have a nice day,

Jun Zhang

 

0 项奖励
回复
3,919 次查看
e_taylor
Contributor III

Thank you !

Have a wonderful day!

Ed

0 项奖励
回复