Download presentation

Presentation is loading. Please wait.

1
Introduction to Microprocessors Number Systems and Conversions No. 1-1 9/6/00 Chapter 1: Introduction to 68HC11 The 68HC11 Microcontroller

2
Introduction to Microprocessors Number Systems and Conversions No. 1-2 9/6/00 What is a computer ? Software Hardware Computer Hardware Organization Control unit Arithmetic logic unit Registers common bus memory program storage data storage output unit input unit Figure 1.1 Computer hardware organization

3
Introduction to Microprocessors Number Systems and Conversions No. 1-3 9/6/00 The processor Registers -- storage locations in the processor Arithmetic logic unit Control unit program counter keeps track of the address of the next instruction to be executed status register flags the instruction execution result The microprocessor A processor implemented on a very large scale integration (VLSI) chip Peripheral chips are needed to construct a product The Microcontroller The processor and peripheral functions implemented on one VLSI chip

4
Introduction to Microprocessors Number Systems and Conversions No. 1-4 9/6/00 Features of the 68HC11A8 microcontroller -8-bit CPU -256 bytes SRAM -512 bytes EEPROM -8 KB ROM -3 input capture channels -5 output compare functions -one 8-bit pulse accumulator -one serial communication interface (SCI) -one serial peripheral interface (SPI) -real-time interrupt (RTI) circuit -8-channel 8-bit A/D converter -computer operate properly (COP) watchdog system

5
Introduction to Microprocessors Number Systems and Conversions No. 1-5 9/6/00

6
Introduction to Microprocessors Number Systems and Conversions No. 1-6 9/6/00 Examples of microcontroller applications -Displays -Printers -Keyboards -Modems -Charge card phones -Refrigerators -Washing machines -Microwave ovens -Automobile engine fuel injection -Fax machines -Motor speed control -etc.

7
Introduction to Microprocessors Number Systems and Conversions No. 1-7 9/6/00 Semiconductor memory Random-access memory (RAM): same amount of time is required to access any location on the same chip Read-only memory (ROM): can only be read but not written by the processor ---- Random-access memory - Dynamic random-access memory (DRAM): periodic refresh is required to maintain the contents of a DRAM chip - Static random-access memory (SRAM): no periodic refresh is required Read-only memory - Mask-programmed read-only memory (MROM): programmed when being manufactured - Programmable read-only memory (PROM): the memory chip can be programmed by the end user

8
Introduction to Microprocessors Number Systems and Conversions No. 1-8 9/6/00 - Erasable programmable ROM (EPROM) 1. electrically programmable many times 2. erased by ultraviolet light (through a window) 3. erasable in bulk (whole chip in one erasure operation) - Electrically erasable programmable ROM (EEPROM) 1. electrically programmable many times 2. electrically erasable many times 3. can be erased one location, one row, or whole chip in one operation - Flash memory 1. electrically programmable many times 2. electrically erasable many times 3. can only be erased in bulk

9
Introduction to Microprocessors Number Systems and Conversions No. 1-9 9/6/00 Computer software -Computer programs are known as software -A program is a sequence of instructions Machine instruction -A sequence of binary digits which can be executed by the processor -Hard to understand for human being Assembly language -Defined by assembly instructions -An assembly instruction is a mnemonic representation of a machine instruction -Assembly programs must be translated before it can be executed -- translated by an assembler

10
Introduction to Microprocessors Number Systems and Conversions No. 1-10 9/6/00 High-level language -Syntax of a high-level language is similar to English -A translator is required to translate the program written in a high-level language -- done by a compiler Source code -A program written in assembly or high-level language Object code -The output of an assembler or compiler

11
Introduction to Microprocessors Number Systems and Conversions No. 1-11 9/6/00

12
Introduction to Microprocessors Number Systems and Conversions No. 1-12 9/6/00 Memory Addressing Memory consists of addressable locations A memory location has 2 components: address and contents Data transfer between CPU and memory involves address bus and data bus CPU memory address bus lines data bus lines Figure 1.5 Data transfer between CPU and memory address contents

13
Introduction to Microprocessors Number Systems and Conversions No. 1-13 9/6/00 NUMBER SYSTEMS, CONVERSIONS and CODES

14
Introduction to Microprocessors Number Systems and Conversions No. 1-14 9/6/00 Goals Upon Completion Understand Positional Number Systems Convert from one base to another Add, Subtract using Binary Numbers

15
Introduction to Microprocessors Number Systems and Conversions No. 1-15 9/6/00 Chapter Overview Binary Number Representation Sign & Magnitude Ones Complement Twos Complement Codes Binary Addition Using Ones and Twos Complement Using BCD Nines and Tens Complement Binary Subtraction

16
Introduction to Microprocessors Number Systems and Conversions No. 1-16 9/6/00 Binary Weights In Base 10 the weights in positional notation are: a 0 is units weight a 1 is 10 units weight a 2 is 100 units weight or 10 * a 1 weight... In Base 2 the weights in positional notation are: a 0 is units weight a 1 is 2 units weight a 2 is 4 units weight or 2 * a 1 weight...

17
Introduction to Microprocessors Number Systems and Conversions No. 1-17 9/6/00 Positional Notation BASE 10 953.78 10 = 9 x 10 2 + 5 x 10 1 + 3 x 10 0 + 7 x 10 -1 + 8 x 10 -2 BASE 2 1011.11 2 = 1x2 3 + 0x2 2 + 1x2 1 + 1x2 0 + 1x2 -1 + 1x2 -2 = 8 + 0 + 2 + 1 + 1/2 + 1/4 = 11 3/4 = 11.75

18
Introduction to Microprocessors Number Systems and Conversions No. 1-18 9/6/00 Conversion EXAMPLE ( repeated division) Convert 53 10 to binary 2 53 divided by 2 leaves 26 2’s with 1 leftover which forms least significant bit 2 26remainder = 1 = a 0 2 13remainder = 0 = a 1 2 6remainder = 1 = a 2 2 3remainder = 0 = a 3 2 1remainder = 1 = a 4 0 remainder = 1 = a 5 most significant digit 53 base 10 equals 110101 32 + 16 + 4 + 1 = 53

19
Introduction to Microprocessors Number Systems and Conversions No. 1-19 9/6/00 EXAMPLE (fractional portion requires repeated multiplication) Convert.625 10 to binary.625 X 2 = 1.250 a -1 = 1 remainder =.250 after 1.0 subtraction ms digit.250 X 2 = 0.500 a -2 = 0 remainder =.500.500 x 2 = 1.000 a -3 = 1 remainder =.000 Finished - No further multiplication possible!.101 2 =.5 + 0 +.125 =.625 10

20
Introduction to Microprocessors Number Systems and Conversions No. 1-20 9/6/00 EXAMPLE Convert 0.7 10 to binary.700 X 2 = 1.400 a -1 = 1 remainder =.400.400 X 2 = 0.800 a -2 = 0 remainder =.800.800 X 2 = 1.600 a -3 = 1 remainder =.600.600 X 2 = 1.200 a -4 = 1 remainder =.200.200 X 2 = 0.400 a -5 = 0 remainder =.400.400 X 2 = 0.800 a -6 = 0 remainder =.800 Process starts to repeat 0.7 10 = 0.10110011001100.........(base 2)

21
Introduction to Microprocessors Number Systems and Conversions No. 1-21 9/6/00 HEXADECIMAL NUMBERS Code WRITING one’s and zero’s can be error prone when dealing with large numbers. IBM came up with the following method of dealing with these numbers. BASE 16 with digits 0 - 15 in base 10 are represented by the following notation in Hexadecimal. 0 16 = 0000 2 = 0 10 8 16 = 1000 2 = 8 10 1 16 = 0001 2 = 1 10 9 16 = 1001 2 = 9 10 2 16 = 0010 2 = 2 10 A 16 = 1010 2 = 10 10 3 16 = 0011 2 = 3 10 B 16 = 1011 2 = 11 10 4 16 = 0100 2 = 4 10 C 16 = 1100 2 = 12 10 5 16 = 0101 2 = 5 10 D 16 = 1101 2 = 13 10 6 16 = 0110 2 = 6 10 E 16 = 1110 2 = 14 10 7 16 = 0111 2 = 7 10 F 16 = 1111 2 = 15 10

Similar presentations

© 2019 SlidePlayer.com Inc.

All rights reserved.

To make this website work, we log user data and share it with processors. To use this website, you must agree to our Privacy Policy, including cookie policy.

Ads by Google