The Definitive Guide to the ARM Cortex-M3
eBook - ePub

The Definitive Guide to the ARM Cortex-M3

Joseph Yiu

Share book
  1. 384 pages
  2. English
  3. ePUB (mobile friendly)
  4. Available on iOS & Android
eBook - ePub

The Definitive Guide to the ARM Cortex-M3

Joseph Yiu

Book details
Book preview
Table of contents
Citations

About This Book

This user's guide does far more than simply outline the ARM Cortex-M3 CPU features; it explains step-by-step how to program and implement the processor in real-world designs. It teaches readers how to utilize the complete and thumb instruction sets in order to obtain the best functionality, efficiency, and reuseability. The author, an ARM engineer who helped develop the core, provides many examples and diagrams that aid understanding. Quick reference appendices make locating specific details a snap! Whole chapters are dedicated to:
Debugging using the new CoreSight technology
Migrating effectively from the ARM7
The Memory Protection Unit
Interfaces, Exceptions, Interrupts
...and much more!*The only available guide to programming and using the groundbreaking ARM Cortex-M3 processor *Easy-to-understand examples, diagrams, quick reference appendices, full instruction and Thumb-2 instruction sets are all included *The author, an ARM engineer on the M3 development team, teaches end users how to start from the ground up with the M3, and how to migrate from the ARM7

Frequently asked questions

How do I cancel my subscription?
Simply head over to the account section in settings and click on “Cancel Subscription” - it’s as simple as that. After you cancel, your membership will stay active for the remainder of the time you’ve paid for. Learn more here.
Can/how do I download books?
At the moment all of our mobile-responsive ePub books are available to download via the app. Most of our PDFs are also available to download and we're working on making the final remaining ones downloadable now. Learn more here.
What is the difference between the pricing plans?
Both plans give you full access to the library and all of Perlego’s features. The only differences are the price and subscription period: With the annual plan you’ll save around 30% compared to 12 months on the monthly plan.
What is Perlego?
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 1000+ topics, we’ve got you covered! Learn more here.
Do you support text-to-speech?
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more here.
Is The Definitive Guide to the ARM Cortex-M3 an online PDF/ePUB?
Yes, you can access The Definitive Guide to the ARM Cortex-M3 by Joseph Yiu in PDF and/or ePUB format, as well as other popular books in Diseño & Diseño industrial. We have over one million books available in our catalogue for you to explore.

Information

Publisher
Newnes
Year
2011
ISBN
9780080551432
CHAPTER 1 Introduction
In This Chapter:
What Is the ARM Cortex-M3 Processor?
Background of ARM and ARM Architecture
Instruction Set Development
The Thumb-2 Instruction Set Architecture (ISA)
Cortex-M3 Processor Applications
Organization of This Book
Further Readings

What Is the ARM Cortex-M3 Processor?

The microcontroller market is vast, with over 20 billion devices per year estimated to be shipped in 2010. A bewildering array of vendors, devices, and architectures are competing in this market. The requirement for higher-performance microcontrollers has been driven globally by the industry’s changing needs; for example, microcontrollers are required to handle more work without increasing a product’s frequency or power. In addition, microcontrollers are becoming increasingly connected, whether by Universal Serial Bus (USB), Ethernet, or Wireless Radio, and hence the processing needed to support these communications channels and advanced peripherals is growing. Similarly, general application complexity is on the increase, driven by more sophisticated user interfaces, multimedia requirements, system speed, and convergence of functionalities.
The ARM Cortex-M3 processor, the first of the Cortex generation of processors released by ARM in 2006, was primarily designed to target the 32-bit microcontroller market. The Cortex-M3 processor provides excellent performance at low gate count and comes with many new features previously available only in high-end processors. The Cortex-M3 addresses the requirements for the 32-bit embedded processor market in the following ways:
  • Greater performance efficiency, allowing more work to be done without increasing the frequency or power requirements
  • Low power consumption, enabling longer battery life, especially critical in portable products including wireless networking applications
  • Enhanced determinism, guaranteeing that critical tasks and interrupts are serviced as quickly as possible but in a known number of cycles
  • Improved code density, ensuring that code fits in even the smallest memory footprints
  • Ease of use, providing easier programmability and debugging for the growing number of 8-bit and 16-bit users migrating to 32-bit
  • Lower-cost solutions, reducing 32-bit-based system costs close to those of legacy 8-bit and 16-bit devices and enabling low-end, 32-bit microcontrollers to be priced at less than US$1 for the first time
  • Wide choice of development tools, from low-cost or free compilers to full-featured development suites from many development tool vendors
Microcontrollers based on the Cortex-M3 processor already compete head-on with devices based on a wide variety of other architectures. Designers are increasingly looking at reducing the system cost, as opposed to the traditional device cost. As such, organizations are implementing device aggregation, whereby a single, more powerful device can potentially replace three or four traditional 8-bit devices.
Other cost savings can be achieved by improving the amount of code reuse across all systems. Since Cortex-M3 processor-based microcontrollers can be easily programmed using the C language and are based on a well-established architecture, application code can be ported and reused easily, reducing development time and testing costs.
It is worthwhile highlighting that the Cortex-M3 processor is not the first ARM processor to be used to create generic microcontrollers. The venerable ARM7 processor has been very successful in this market, with partners such as NXP (Philips), Texas Instruments, Atmel, OKI, and many other vendors delivering robust 32-bit Microcontroller Units (MCUs). The ARM7 is the most widely used 32-bit embedded processor in history, with over 1 billion processors produced each year in a huge variety of electronic products, from mobile phones to cars.
The Cortex-M3 processor builds on the success of the ARM7 processor to deliver devices that are significantly easier to program and debug and yet deliver a higher processing capability. Additionally, the Cortex-M3 processor introduces a number of features and technologies that meet the specific requirements of the microcontroller applications, such as nonmaskable interrupts for critical tasks, highly deterministic nested vector interrupts, atomic bit manipulation, and an optional memory protection unit. These factors make the Cortex-M3 processor attractive to existing ARM processor users as well as many new users considering use of 32-bit MCUs in their products.
The Cortex-M3 Processor vs Cortex-M3-Based MCUs
The Cortex-M3 processor is the central processing unit (CPU) of a microcontroller chip. In addition, a number of other components are required for the whole Cortex-M3 processor-based microcontroller. After chip manufacturers license the Cortex-M3 processor, they can put the Cortex-M3 processor in their silicon designs, adding memory, peripherals, input/output (I/O), and other features. Cortex-M3 processor-based chips from different manufacturers will have different memory sizes, types, peripherals, and features. This book focuses on the architecture of the processor core. For details about the rest of the chip, please check the particular chip manufacturer’s documentation.
image
Figure 1.1 The Cortex-M3 Processor vs the Cortex-M3-Based MCU

Background of ARM and ARM Architecture

A Brief History

To help you understand the variations of ARM processors and architecture versions, let’s look at a little bit of ARM history.
ARM was formed in 1990 as Advanced RISC Machines Ltd., a joint venture of Apple Computer, Acorn Computer Group, and VLSI Technology. In 1991, ARM introduced the ARM6 processor family, and VLSI became the initial licensee. Subsequently, additional companies, including Texas Instruments, NEC, Sharp, and ST Microelectronics, licensed the ARM processor designs, extending the applications of ARM processors into mobile phones, computer hard disks, personal digital assistants (PDAs), home entertainment systems, and many other consumer products.
Nowadays ARM partners ship in excess of 2 billion ARM processors each year. Unlike many semiconductor companies, ARM does not manufacture processors or sell the chips directly. Instead, ARM licenses the processor designs to business partners, including a majority of the world’s leading semiconductor companies. Based on the ARM low-cost and power-efficient processor designs, these partners create their processors, microcontrollers, and system-on-chip solutions. This business model is commonly called intellectual property (IP) licensing.
In addition to processor designs, ARM also licenses systems-level IP and various software IP. To support these products, ARM has developed a strong base of development tools, hardware, and software products to enable partners to develop their own products.

Architecture Versions

Over the years, ARM has continued to develop new processors and system blocks. These include the popular ARM7TDMI processor and, more recently, the ARM1176TZ(F)-S processor, which is used in high-end applications such as smart phones. The evolution of features and enhancements to the processors over time has led to successive versions of the ARM architecture. Note that architecture version numbers are independent from processor names. For example, the ARM7TDMI processor is based on the ARMv4T architecture (the T is for Thumb instruction mode support).
The ARMv5E architecture was introduced with the ARM9E processor families, including the ARM926E-S and ARM946E-S processors. This architecture added “Enhanced” Digital Signal Processing (DSP) instructions for multimedia applications.
With the arrival of the ARM11 processor family, the architecture was extended to the ARMv6. New features in this architecture included memory system features and Single Instruction–Multiple Data (SIMD) instructions. Processors based on the ARMv6 architecture include the ARM1136J(F)-S, the ARM1156T2(F)-S, and the ARM1176JZ(F)-S.
Following the introduction of the ARM11 family, it was decided that many of the new technologies, such as the optimized Thumb-2 instruction set, were just as applicable to the lower-cost markets of microcontroller and automotive components. It was also decided that although the architecture needed to be consistent from the lowest MCU to the highest-performance application processor, there was a need to deliver processor architectures that best fit applications, enabling very deterministic and low gate count processors for cost-sensitive markets and feature-rich and high-performance ones for high-end applications.
Over the past several years, ARM extended its product portfolio by diversifying its CPU development, which resulted in the architecture version 7, or v7. In this version, the architecture design is divided into three profiles:
  • The A profile, designed for high-performance open application platforms
  • The R profile, designed for high-end embedded systems in which real-time performance is needed
  • The M profile, designed for deeply embedded microcontroller-type systems
Let’s look at these profiles in a bit more detail:
  • A Profile (ARMv7-A): Application processors required to run complex applications such as high-end embedded operating systems (OSs), such as Symbian, Linux, and Windows Embedded, requiring the highest processing power, virtual memory system support with Memory Management Units (MMUs), and, optionally, enhanced Java support and a secure program execution environment. Example products include high-end mobile phones and electronic wallets for financial transactions.
  • R Profile (ARMv7-R): Real-time, high-performance processors targeted primarily at the higher end of the real-time1 market—those applications, such as high-end breaking systems and hard drive controllers, in which high processing power and high reliability are essential and for which low latency is important.
  • M Profile (ARMv7-M): Processors targeting low-cost applications in which processing efficiency is important and cost, power consumption, low interrupt la...

Table of contents