Relocating .rodata

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 
1,080件の閲覧回数
Nik
Contributor III

I need to relacate constant data like:

 

 

const byte geh_interface[18] = { 18, 0x3, 'H',0, 'I',0, 'D',0, '-',0, 'L',0, 'E',0, 'D',0, 's',0 };

 

and I see that it places it:
geh_interface                             862B      12      18       1   .rodata

 

How can I relocate read only data?

 

Thanks,

Robert

ラベル(1)
タグ(1)
0 件の賞賛
返信
1 解決策
850件の閲覧回数
Nik
Contributor III

I may have answerd this myself:

 

in SECTIONS

 

Bootloader               =   READ_ONLY    0xD000 TO 0xFFAD;


in Placement

Bootloader_CONST INTO  Bootloader;

 

In code:

#pragma CONST_SEG Bootloader_CONST

 

 

元の投稿で解決策を見る

0 件の賞賛
返信
1 返信
851件の閲覧回数
Nik
Contributor III

I may have answerd this myself:

 

in SECTIONS

 

Bootloader               =   READ_ONLY    0xD000 TO 0xFFAD;


in Placement

Bootloader_CONST INTO  Bootloader;

 

In code:

#pragma CONST_SEG Bootloader_CONST

 

 

0 件の賞賛
返信