13.07.2015 Views

Cortex-M0+ Devices Generic User Guide - Keil

Cortex-M0+ Devices Generic User Guide - Keil

Cortex-M0+ Devices Generic User Guide - Keil

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

The <strong>Cortex</strong>-<strong>M0+</strong> ProcessorTable 2-2 Core register set summary (continued)Name Type a Reset value DescriptionEPSR RO Unknown b Execution Program Status Register on page 2-6PRIMASK RW 0x00000000 Priority Mask Register on page 2-7CONTROL RW 0x00000000 CONTROL register on page 2-8a. Describes access type during program execution in Thread mode and Handler mode. Debugaccess can differ.b. Bit[24] is the T-bit and is loaded from bit[0] of the reset vector.General-purpose registersR0-R12 are 32-bit general-purpose registers for data operations.Stack PointerThe Stack Pointer (SP) is register R13. In Thread mode, bit[1] of the CONTROL registerindicates the stack pointer to use:• 0 = Main Stack Pointer (MSP). This is the reset value.• 1 = Process Stack Pointer (PSP).On reset, the processor loads the MSP with the value from address 0x00000000.Link RegisterThe Link Register (LR) is register R14. It stores the return information for subroutines, functioncalls, and exceptions. On reset, the LR value is Unknown.Program CounterThe Program Counter (PC) is register R15. It contains the current program address. On reset,the processor loads the PC with the value of the reset vector, that is at address 0x00000004. Bit[0]of the value is loaded into the EPSR T-bit at reset and must be 1.Program Status RegisterThe Program Status Register (PSR) combines:• Application Program Status Register (APSR)• Interrupt Program Status Register (IPSR)• Execution Program Status Register (EPSR).These registers are mutually exclusive bitfields in the 32-bit PSR. The PSR bit assignments are:31 30 29 28 2725 24 23650APSRN Z C VReservedIPSRReservedException numberEPSR Reserved TReservedARM DUI 0662A Copyright © 2012 ARM. All rights reserved. 2-4ID041812Non-Confidential

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!