Looking for simple relocatable example

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Looking for simple relocatable example

Jump to solution
3,970 Views
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 Kudos
Reply
1 Solution
3,928 Views
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

 

View solution in original post

0 Kudos
Reply
6 Replies
3,967 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi e_taylor,

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

 

Thanks

Jun Zhang

0 Kudos
Reply
3,963 Views
e_taylor
Contributor III

Hello ZhangJennie,

Thank you for your prompt response!

9S12XDP512 and CW 5.2

Thank you again!

Ed

0 Kudos
Reply
3,956 Views
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 Kudos
Reply
3,951 Views
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 Kudos
Reply
3,929 Views
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 Kudos
Reply
3,920 Views
e_taylor
Contributor III

Thank you !

Have a wonderful day!

Ed

0 Kudos
Reply