variable mapping

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

variable mapping

跳至解决方案
2,802 次查看
leroynash
Contributor I
I ran out of space in SRAM_DTC and need to map some arrays to SRAM_OC (RAM3) the line: __DATA(RAM3) double g_F_k[NSTATE][NSTATE] = {{0.0}}; results in: ../source/filter/src/tight_coupling.c:30:1: warning: return type defaults to 'int' [-Wimplicit-int] 30 | __DATA(RAM3) double g_F_k[NSTATE][NSTATE] = {{0.0}}; // State Transition Matrix | ^~~~~~ ../source/filter/src/tight_coupling.c: In function '__DATA': ../source/filter/src/tight_coupling.c:30:1: error: parameter 'g_F_k' is initialized ../source/filter/src/tight_coupling.c:30:1: warning: braces around scalar initializer ../source/filter/src/tight_coupling.c:30:1: note: (near initialization for 'g_F_k') any ideas? Thanks Leroy
0 项奖励
回复
1 解答
2,788 次查看
jeremyzhou
NXP Employee
NXP Employee

Him
Thank you for your interest in NXP Semiconductor products and for the opportunity to serve you.
To place data item into a specific memory region, it should add the below code in the code project prior to using the __DATA macro.

#include <cr_section_macros.h>


TIC

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

在原帖中查看解决方案

0 项奖励
回复
3 回复数
2,789 次查看
jeremyzhou
NXP Employee
NXP Employee

Him
Thank you for your interest in NXP Semiconductor products and for the opportunity to serve you.
To place data item into a specific memory region, it should add the below code in the code project prior to using the __DATA macro.

#include <cr_section_macros.h>


TIC

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 项奖励
回复
2,773 次查看
leroynash
Contributor I

That simple, thanks

0 项奖励
回复
2,790 次查看
crist_xu
NXP Employee
NXP Employee

Try to use __attribute__() instead? 

0 项奖励
回复