Muutke küpsiste eelistusi

ARM Assembly Language: Fundamentals and Techniques [Kõva köide]

(Consultant, Austin, Texas, USA)
  • Formaat: Hardback, 372 pages, kõrgus x laius: 234x156 mm, kaal: 612 g, less than 10; 34 Tables, black and white; 91 Illustrations, black and white
  • Ilmumisaeg: 13-Mar-2009
  • Kirjastus: CRC Press Inc
  • ISBN-10: 1439806101
  • ISBN-13: 9781439806104
Teised raamatud teemal:
  • Kõva köide
  • Hind: 101,79 €*
  • * saadame teile pakkumise kasutatud raamatule, mille hind võib erineda kodulehel olevast hinnast
  • See raamat on trükist otsas, kuid me saadame teile pakkumise kasutatud raamatule.
  • Kogus:
  • Lisa ostukorvi
  • Tasuta tarne
  • Lisa soovinimekirja
  • Formaat: Hardback, 372 pages, kõrgus x laius: 234x156 mm, kaal: 612 g, less than 10; 34 Tables, black and white; 91 Illustrations, black and white
  • Ilmumisaeg: 13-Mar-2009
  • Kirjastus: CRC Press Inc
  • ISBN-10: 1439806101
  • ISBN-13: 9781439806104
Teised raamatud teemal:
"Providing a solid introduction to assembly language and embedded systems, this second edition continues to support the popular ARM7TDMI but also addresses the latest architectures from ARM. These include the Cortex-A, Cortex-R, and Cortex-M processors, all of which have slightly different instruction sets, programmer's models, and exception handling. This edition features three new chapters, a new appendix, and expanded coverage of the ARM7. It also tackles IEEE 754 floating-point arithmetic and discusses both Keil MDK-ARM and Texas Instruments Code Composer Studio"--

Hohl has been with Austin, Texas-based ARM for 12 years, where he was responsible for designing parts of the ARM1020 microprocessor, and is currently the company's university relations manager, directing its worldwide academic program. He presents a text for second- or third-year undergraduate students with some background of digital logic, high-level programming and digital arithmetic, suitable as both a textbook for new programmers and as a reference throughout their degrees. Coverage includes an overview of computing systems; the ARM7TDME programmer's model; first programs; assembler rules and directives; loads, stores, and addressing; constants and literal pools; logic and arithmetic; loops and branches; tables; subroutines and stacks; exception handling; memory-mapped peripherals; THUMB; and mixing C and assembly. Annotation ©2009 Book News, Inc., Portland, OR (booknews.com)

Written by the director of ARM’s worldwide academic program, this volume gives computer science professionals and students an edge, regardless of their preferred coding language. For those with some basic background in digital logic and high-level programming, the book examines code relevant to hardware and peripherals found on today's microcontrollers and looks at situations all programmers will eventually encounter.

The book’s carefully chosen examples teach easily transferrable skills that will help readers optimize routines and significantly streamline coding, especially in the embedded space.

This book is easily adaptable for classroom use. Instructors can access features that include a solutions manual, assembly language basics, problems, and actual code. The book also provides access to a fully functional evaluation version of the RealView Microcontroller Development Kit from Keil.

While it is still an important skill, getting good instruction in assembly language is not easy. The availability of languages such as C and Java foster the belief that engineers and programmers need only address problems at the highest levels of a program's operation. Yet, even modern coding methods, when done well, require an understanding of basic assembly methods such as those gained by learning ARM. Certain features that are the product of today’s hardware, such as coprocessors or saturated math operations, can be accessed only through the hardware’s native instructions. For that matter, any programmer wishing to achieve results as exact as his or her intentions needs to possess a mastery of machine code basics as taught in the pages of this book.

Of the 13 billion microprocessor-based chips shipped in the last year, nearly 3 billion were ARM-based, making operational knowledge of ARM an essential component of any programmer’s tool kit. That it can be applied with most any language makes it invaluable.

Preface xiii
Acknowledgments xvii
Software Notice xix
Author xxi
Chapter 1 An Overview of Computing Systems 1
1.1 Introduction
1
1.2 History of RISC
2
1.2.1 ARM Begins
5
1.2.2 The Creation of ARM Ltd.
6
1.2.3 ARM Today
9
1.3 The Computing Device
10
1.4 Number Systems
11
1.5 Representations of Numbers and Characters
14
1.5.1 Integer Representations
15
1.5.2 Floating-Point Representations
18
1.5.3 Character Representations
20
1.6 Translating Bits to Commands
21
1.7 The Tools
22
1.8 Exercises
25
Chapter 2 The ARM7TDMI Programmer's Model 29
2.1 Introduction
29
2.2 Data Types
29
2.3 Processor Modes
30
2.4 Registers
31
2.5 Program Status Registers
33
2.5.1 The Control Bits
34
2.5.2 The Mode Bits
34
2.6 The Vector Table
34
2.7 Exercises
35
Chapter 3 First Programs 37
3.1 Introduction
37
3.2 Program 1: Shifting Data
38
3.2.1 Running the Code
39
3.2.2 Examining Register and Memory Contents
40
3.3 Program 2: Factorial Calculation
41
3.4 Program 3: Swapping Register Contents
43
3.5 Programming Guidelines
44
3.6 Exercises
45
Chapter 4 Assembler Rules and Directives 47
4.1 Introduction
47
4.2 Structure of Assembly Language Modules
47
4.3 Predefined Register Names
50
4.4 Frequently Used Directives
51
4.4.1 AREA—Define a Block of Data or Code
51
4.4.2 RN—Register Name Definition
52
4.4.3 EQU—Equate a Symbol to a Numeric Constant
53
4.4.4 ENTRY—Declare an Entry Point
54
4.4.5 DCB, DCW, and DCD—Allocate Memory and Specify Contents
54
4.4.6 ALIGN—Align Data or Code to Appropriate Boundaries
55
4.4.7 SPACE—Reserve a Block of Memory
56
4.4.8 LTORG—Assign Literal Pool Origins
56
4.4.9 END—End of a Source File
57
4.5 Macros
57
4.6 Miscellaneous Assembler Features
59
4.6.1 Assembler Operators
59
4.6.2 Literals
61
4.7 Exercises
61
Chapter 5 Loads, Stores, and Addressing 63
5.1 Introduction
63
5.2 Memory
63
5.3 Loads and Stores—The Instructions
66
5.4 Operand Addressing
69
5.4.1 Pre-Indexed Addressing
69
5.4.2 Post-Indexed Addressing
71
5.5 Endianness
72
5.5.1 Changing Endianness
74
5.5.2 Defining Memory Areas
75
5.6 Exercises
76
Chapter 6 Constants and Literal Pools 79
6.1 Introduction
79
6.2 The ARM Rotation Scheme
79
6.3 Loading Constants into Registers
82
6.4 Loading Addresses into Registers
86
6.5 Exercises
91
Chapter 7 Logic and Arithmetic 93
7.1 Introduction
93
7.2 Flags and Their Use
93
7.2.1 The N Flag
93
7.2.2 The V Flag
94
7.2.3 The Z Flag
95
7.2.4 The C Flag
95
7.3 Comparison Instructions
95
7.4 Data Processing Operations
97
7.4.1 Boolean Operations
97
7.4.2 Shifts and Rotates
98
7.4.3 Addition/Subtraction
104
7.4.4 Multiplication
106
7.4.5 Multiplication by a Constant
107
7.4.6 Division
108
7.5 Fractional Notation
111
7.6 Exercises
115
Chapter 8 Loops and Branches 119
8.1 Introduction
119
8.2 Branching
120
8.3 Looping
123
8.3.1 While Loops
124
8.3.2 For Loops
124
8.3.3 Do...While Loops
128
8.4 More on Flags
128
8.5 Conditional Execution
128
8.6 Straight-Line Coding
131
8.7 Exercises
132
Chapter 9 Tables 135
9.1 Introduction
135
9.2 Lookup Tables
135
9.3 Jump Tables
139
9.4 Binary Searches
140
9.5 Exercises
143
Chapter 10 Subroutines and Stacks 147
10.1 Introduction
147
10.2 The Stack
147
10.2.1 LDM/STM Instructions
148
10.2.2 Full/Empty Ascending/Descending Stacks
150
10.3 Subroutines
152
10.4 Passing Parameters to Subroutines
153
10.4.1 Passing Parameters in Registers
154
10.4.2 Passing Parameters by Reference
156
10.4.3 Passing Parameters on the Stack
158
10.5 The ARM APCS
160
10.6 Exercises
161
Chapter 11 Exception Handling 165
11.1 Introduction
165
11.2 Interrupts
165
11.3 Error Conditions
166
11.4 Processor Exception Sequence
167
11.5 The Vector Table
169
11.6 Exception Handlers
171
11.7 Exception Priorities
172
11.8 Procedures for Handling Exceptions
173
11.8.1 Reset Exceptions
173
11.8.2 Undefined Instructions
174
11.8.3 Interrupts
178
11.8.4 Aborts
187
11.8.5 SWIs
190
11.9 Exercises
191
Chapter 12 Memory-Mapped Peripherals 193
12.1 Introduction
193
12.2 The LPC2104
194
12.2.1 The UART
195
12.2.2 The Memory Map
195
12.2.3 Configuring the UART
197
12.2.4 Writing the Data to the UART
199
12.2.5 Putting the Code Together
199
12.2.6 Running the Code
201
12.3 The LPC2132
202
12.3.1 The D/A Converter
203
12.3.2 The Memory Map
204
12.3.3 Configuring the D/A Converter
204
12.3.4 Generating a Sine Wave
205
12.3.5 Putting the Code Together
206
12.3.6 Running the Code
208
12.4 Exercises
209
Chapter 13 THUMB 211
13.1 Introduction
211
13.2 THUMB Instructions
212
13.3 Differences Between ARM and THUMB
213
13.4 THUMB Implementation and Use
215
13.4.1 Processor Hardware
215
13.4.2 Switching Between ARM and THUMB States
216
13.5 How to Compile for THUMB
218
13.6 Exercises
220
Chapter 14 Mixing C and Assembly 223
14.1 Introduction
223
14.2 Inline Assembler
223
14.2.1 Inline Assembly Syntax
226
14.2.2 Restrictions on Inline Assembly Operations
228
14.3 Embedded Assembler
228
14.3.1 Embedded Assembly Syntax
230
14.3.2 Restrictions on Embedded Assembly Operations
231
14.4 Calling Between C and Assembly
231
14.5 Exercises
233
Appendix A The ARM V4T Instruction Set 235
Appendix B Running Keil Tools 333
B.1 Introduction
333
B.2 Creating a Project and Selecting a Device
333
B.3 Creating Application Code
335
B.4 Building the Project and Running Code
336
Appendix C ASCII Character Codes 339
Glossary 341
References 343
Index 345
ARM, Inc, Austin, TX