List of Figures

Figure 1.1 Simplified representation of a computer system 4

Figure 1.2 Stages of a typical compilation sequence 6

Figure 1.3 Tables used for converting between binary, octal, and hex 14

Figure 1.4 Four different representations for binary integers 16

Figure 1.5 Complement tables for bases ten and two 17

Figure 1.6 A section of memory 29

Figure 1.7 Typical memory layout for a program with a 32-bit address space 30

Figure 2.1 Equivalent static variable declarations in assembly and C 42

Figure 3.1 The ARM processor architecture 54

Figure 3.2 The ARM user program registers 56

Figure 3.3 The ARM process status register 57

Figure 5.1 ARM user program registers 112

Figure 6.1 Binary tree of word frequencies 151

Figure 6.2 Binary tree of word frequencies with index added 157

Figure 6.3 Binary tree of word frequencies with sorted index 158

Figure 7.1 In signed 8-bit math, 110110012 is −3910 179

Figure 7.2 In unsigned 8-bit math, 110110012 is 21710 179

Figure 7.3 Multiplication of large numbers 180

Figure 7.4 Longhand division in decimal and binary 181

Figure 7.5 Flowchart for binary division 183

Figure 8.1 Examples of fixed-point signed arithmetic 232

Figure 9.1 ARM integer and vector floating point user program registers 267

Figure 9.2 Bits in the FPSCR 268

Figure 10.1 ARM integer and NEON user program registers 300

Figure 10.2 Pixel data interleaved in three doubleword registers 302

Figure 10.3 Pixel data de-interleaved in three doubleword registers 303

Figure 10.4 Example of vext.8 d12,d4,d9,#5 313

Figure 10.5 Examples of the vrev instruction. (A) vrev16.8 d3,d4; (B) vrev32.16 d8,d9; (C) vrev32.8 d5,d7 315

Figure 10.6 Examples of the vtrn instruction. (A) vtrn.8 d14,d15; (B) vtrn.32 d31,d15 316

Figure 10.7 Transpose of a 3 × 3 matrix 317

Figure 10.8 Transpose of a 4 × 4 matrix of 32-bit numbers 318

Figure 10.9 Example of vzip.8 d9,d4 320

Figure 10.10 Effects of vsli.32 d4,d9,#6 334

Figure 11.1 Typical hardware address mapping for memory and devices 366

Figure 11.2 GPIO pins being used for input and output. (A) GPIO pin being used as input to read the state of a push-button switch. (B) GPIO pin being used as output to drive an LED 378

Figure 11.3 The Raspberry Pi expansion header location 383

Figure 11.4 The Raspberry Pi expansion header pin assignments 384

Figure 11.5 Bit-to-pin assignments for PIO control registers 388

Figure 11.6 The pcDuino header locations 390

Figure 11.7 The pcDuino header pin assignments 391

Figure 12.1 Pulse density modulation 396

Figure 12.2 Pulse width modulation 397

Figure 13.1 Typical system with a clock management device 406

Figure 13.2 Transmitter and receiver timings for two UARTS. (A) Waveform of a UART transmitting a byte. (B) Timing of UART receiving a byte 411

Figure 14.1 The ARM process status register 433

Figure 14.2 Basic exception processing 436

Figure 14.3 Exception processing with multiple user processes 437