What is the correct way to assign a variable to a specific address with CW 10.xx?  In classic CW the following works "  int    variable name    @0x0070;  "  Importing the project into CW10 give syntax errors

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

What is the correct way to assign a variable to a specific address with CW 10.xx?  In classic CW the following works "  int    variable name    @0x0070;  "  Importing the project into CW10 give syntax errors

Jump to solution
1,405 Views
ISUEE
Contributor I

I am importing a project from classic CW to CW 10.  With classic CW the following assigns a global variable to a designated address

 

#pragma   DATA_SEG  RAM

int     variable_name      @0x0070;

 

The CW 10.  gives syntax errors and bad character sequence encountered: @

 

What is the correct method of assigning a variable to a specific address with CW 10.

 

Thanks in advance.

Labels (1)
Tags (3)
0 Kudos
Reply
1 Solution
1,165 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

which CW10 version do you work with? if you use CW10.4 with 8/16bit MCU, this will not produce this message.

and is CW10.4 is our recommendation. here is the 10.4 webpage and download:

https://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=CW-MICROCONTROLLERS

View solution in original post

0 Kudos
Reply
5 Replies
1,166 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

which CW10 version do you work with? if you use CW10.4 with 8/16bit MCU, this will not produce this message.

and is CW10.4 is our recommendation. here is the 10.4 webpage and download:

https://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=CW-MICROCONTROLLERS

0 Kudos
Reply
1,165 Views
ISUEE
Contributor I

Thanks to all for the help and responses.  Updated to version 10.4 from 10.2 and the errors are gone.

0 Kudos
Reply
1,165 Views
TICS_Fiona
NXP Employee
NXP Employee

This code is built well in my CW10.4. What's the your CodeWarrior version? Could you please attach a simple project to help us reproudce this error? Thanks!

1,165 Views
JimDon
Senior Contributor III

What MCU is it?

0 Kudos
Reply
1,165 Views
JimDon
Senior Contributor III

Try generating a project for that MCU then see how interrupt vectors are places.

0 Kudos
Reply