Nintendo 1504166 Programming Manual - Page 159
System-Allocated Area in Work RAM, By changing each CPU Mode SP Initial-value
View all Nintendo 1504166 manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 159 highlights
AGB Programming Manual Interrupt Control 15.1 System-Allocated Area in Work RAM Controlling interrupts entails, along with clearing the IF register and setting the IE register, first writing an interrupt jump address at addresses $7FFC-$7FFF (total of 32 bits; see figure below) in the system allocated area of Work RAM. Processing is executed in 32-bit mode for the user interrupt. To return control from the interrupt routine to the user program, the instruction "BX LR" is used. 32 bit 03007FFC Interrupt Address 03007FF8 Allocated Area * Interrupt Check Flag 03007FF4 Allocated Area 03007FF0 Sound BufferAddress Allocated Area 03007FE0 LR_SVC (formerly IBPC) R12 R11 SPSR_SVC (formerly CPSR) 03007FA0 LR_IRQ (formerly PC) R12 R3 R2 R1 R0 03007F00 SP_svc System Call Stack (4 words/1 time) SP_irq Interrupt Stack (6 words/1 time) SP_usr User Stack * Specify where to return for SoftReset( ) System Call If 0h:08000000h If not 0h:02000000h By changing each CPU Mode SP Initial-value, they can be set to an arbitrary memory map. ©1999 - 2001 Nintendo of America Inc. 159 D.C.N. AGB-06-0001-002B4