Arm Cortex-M

Revision as of 2022-10-09T18:58:47 by Kai (talk | contribs) (Moves section about Arm GCC to the Arm main page.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

100%

Programming

Armv6-M Programming Model

The programming model used in Cortex-M processors with low power consumption. For example, Cortex-M0.

Armv7-M Programming Model

This is the programming model used in Cortex-M processors with higher performance. For example, Cortex-M4.

CMSIS

Arm specifies a standard C interface for programming Cortex-M processors, the Cortex-M Standard Interface (CMSIS). The Arm licensees are strongly encouraged to provide the CMSIS functions as part of their microcontroller programming SDK. Third-party software libraries usually rely on CMSIS availability.

Intrinsic Functions

Functions that generate instructions not provided by ISO/IEC C
Instruction CMSIS intrinsic function
CPSIE I void __enable_irq(void)
CPSID I void __disable_irq(void)
ISB void __ISB(void)
DSB void __DSB(void)
DMB void __DMB(void)
NOP void __NOP(void)
REV uint32_t __REV(uint32_t int value)
REV16 uint32_t __REV16(uint32_t int value)
REVSH uint32_t __REVSH(uint32_t int value)
SEV void __SEV(void)
WFE void __WFE(void)
WFI void __WFI(void)
Functions for accessing special registers
Register CMSIS read function CMSIS write function
PRIMASK uint32_t __get_PRIMASK (void) void __set_PRIMASK (uint32_t value)
CONTROL uint32_t __get_CONTROL (void) void __set_CONTROL (uint32_t value)
MSP uint32_t __get_MSP (void) void __set_MSP (uint32_t TopOfMainStack)
PSP uint32_t __get_PSP (void) void __set_PSP (uint32_t TopOfProcStack)



Processor Cores

ARM's family of Cortex-M processors (notably M0, M0+, M3, M4) are designed for use as energy-efficient microcontrollers, where M0+ is the cheapest and most efficient, and M4 is the fastest and most capable (offering DSP functions and a floating point unit).

Reference Manuals

Cortex-M0+

Cortex-M4


Development Boards


Software Development Tools


Tutorials