How to place array in specific bank and align it

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

How to place array in specific bank and align it

跳至解决方案
626 次查看
michaeldkfowler
Contributor IV

Hello,

 I am trying to place an array in a specific memory bank and align it. I tried the following and it didn't work:

 

__BSS(RAM) SDK_ALIGN(static ULONG usb_cached_memory[USBX_MEMORY_SIZE / sizeof(ULONG)], 64);

标记 (1)
0 项奖励
1 解答
522 次查看
michaeldkfowler
Contributor IV

This worked:

__attribute__ ((section(".bss.$NCACHE_REGION"), aligned(8)))static ULONG usb_memory[USBX_MEMORY_SIZE / sizeof(ULONG)];

 

在原帖中查看解决方案

0 项奖励
4 回复数
523 次查看
michaeldkfowler
Contributor IV

This worked:

__attribute__ ((section(".bss.$NCACHE_REGION"), aligned(8)))static ULONG usb_memory[USBX_MEMORY_SIZE / sizeof(ULONG)];

 

0 项奖励
603 次查看
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @michaeldkfowler 

Do you use MCUXpresso IDE? If yes, please refer to <MCUXpresso IDE User Guide> ->

19.13 Placement of specific code/data Items .

 

BR

Alice

0 项奖励
597 次查看
michaeldkfowler
Contributor IV
The guide does not answer my question
0 项奖励
529 次查看
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @michaeldkfowler 

So how do you think I can help you?

How about send a simple project that includes your requirements,  I help you change.

BTW, which MCU do you used?

 

BR

Alice

0 项奖励