Appendix RAMでプログラムを B 動かす ??動後は,命令コードをRAMに配置させて動作させる機器も あります. (筆者) 命令コードをRAMに配置する理由 パソコンのようにソフトウェアを入れ替えながら使うことが ない組み込み機器で,なぜ命令コードをRAMに配置するので ...

  • Published on
    28-May-2018

  • View
    215

  • Download
    0

Transcript

<ul><li><p>Design Wave Magazine 2006 March 99</p><p>ON</p><p>ROM</p><p>RAM</p><p> RAM</p><p>RAM</p><p>ROMRAM</p><p>RAM0</p><p>ROM1</p><p>RAM</p><p>RAM</p><p>ADuC</p><p>7000ROM</p><p>16RAM32</p><p>ARM32</p><p>32ROM</p><p>2RAM1</p><p>RAM</p><p> RAM</p><p>RAMROM</p><p>RAM1</p><p>1ROMROM</p><p>RAM1</p><p>RAM</p><p>1</p><p>ROMRAM</p><p>ROMRAM</p><p>RAM</p><p>ROM0x00000000</p><p>0x00000014ROM</p><p>RAM</p><p>0x00010000</p><p>0x000100140x00000014</p><p>ROM</p><p>ROMRAM</p><p>ROM</p><p>RAM</p><p>2</p><p> ADuC7000</p><p>ADuC70000x00000000</p><p>Appe</p><p>ndix</p><p>B</p><p>RAM</p><p>0xFFFFFFFF</p><p>0x00000000ROM</p><p>ROMRAM</p><p>RAM</p><p>1 RAM</p><p>AppendixB</p><p>RAM</p></li><li><p>100 Design Wave Magazine 2006 March</p><p>REMAP0</p><p>10x00000000ROMRAM</p><p>REMAP0x00008000</p><p>2ADuC7000</p><p>0x00080000ROM</p><p>0x00000000SRAM</p><p>0x000000000x00080000</p><p>10x000000000x00080000</p><p>2REMAP1</p><p>3RAMROMRAM</p><p>40x00000000</p><p>ROM</p><p>0x00080000</p><p>0x00080000</p><p>0x00000000</p><p>0x00000000</p><p> LEDRAM</p><p>62</p><p>LEDRAM</p><p>1ROM</p><p>2RAM</p><p>ROMRAM</p><p>1ROM</p><p>3</p><p>ROMRAM</p><p>_sstart_ram_end</p><p>_sstart_ramRAM</p><p>_end</p><p>MMR0xFFFF00000xFFFFFFFF</p><p>0x4000FFFF</p><p>0x3000FFFF</p><p>0x2000FFFF</p><p>0x1000FFFF</p><p>0x0008FFFF</p><p>0x00011FFF</p><p>0x0000FFFF</p><p>0x40000000</p><p>0x30000000</p><p>0x20000000</p><p>0x10000000</p><p>0x00080000</p><p>0x00001000</p><p>0x00000000</p><p>SRAM</p><p>3</p><p>2</p><p>1</p><p>0</p><p>SRAM</p><p>.text</p><p>.extern main</p><p>.extern _sp_base#===================================================# Initialize vectors### 0x00 Reset## 0x04 Undefined Instruction## 0x08 Software Interrupt## 0x0c Abort(prefetch)## 0x10 Abort(data)## 0x14 Reserved## 0x18 IRQ## 0x1c FIQ#===================================================</p><p># _startup0x00080000B _startup</p><p>.org(0x20)_startup:# ROMRAM# 0x00080000-0x0008FFFF# </p><p>LDR R1, =0xFFFF0220LDR R2, =1STR R2, [R1]</p><p># RAMLDR R1, = _sstart_ramLDR R2, = 0x0LDR R3, = _end</p><p>copy_loop:LDR R4, [R1]STR R4, [R2]ADD R1, R1, #4ADD R2, R2, #4CMP R1, R3bne copy_loop</p><p># 0x00000000RAM# </p><p>b _sstart_ram</p><p>s1startup2.s</p><p>2 </p></li></ul>

Recommended

View more >