EE180: Microprocessor Systems Lecture Notes 1


Instruction Set- is the list of all possible instructions that a processor can perform

Machine Language – is the set of instructions that a processor can execute directly, along with the rules for using these instructions

Computer Language- use by the programmers to program computers

Classification of Computer Language
a.    High Level Languages – closely resembles human language (easy to read and write). This includes C, C++, Pascal, Basic, Frotran, etc…
b.    Low Level Language - representation of machine language in a form that is easy for us to work with. This includes assembly language.

Note: Computer language must be converted to Machine Language

Machine Language Instruction – the language which the processor understand.
a.    Compilers – used to translate high level language to machine language
b.    Assemblers – used for translate low level language to machine language

Required Understandings in Assembly
a.    The instructions in the instruction set and how to use them
b.    The basic architecture of the machine

Operating System – is the master control program that runs the computer.

Uses of OS for Assembly programmer
a.    To perform: commands to cop[y files, start a program, list a directory, etc…
b.    Call on OS from within our programs to perform certain tasks

Developing an Assembly Program
a.    Editors – is used to enter our program
b.    Assembler - is used to translate our program to machine language
c.    Linker – is used to link our programs to other programs

Importance of Assembly Programming
a.    To do something that is impossible to do with high level language
b.    To speed up programs and reduce size of programs
c.    To understand how the machine operate (for engineers)
d.    For microprocessor-based designs (for engineers)
e.    For programming microcontrollers (for engineers)

Bit – is a digit that can be 0 or 1,
Byte – each group of 8 bit


Groups of Bits for Intel 86 Processor
Number of Bites
Name
8
Byte
16
Word
32
Doubleword
64
Quadword
128
Paragraph
 

 ASCII Code – American Standard Code for Information Interchange. A standard code used to store textual characters in memory, in which each character is represented by a unique 8-bit pattern.

Memory Address
a.    Computer Memory – organized by bytes
b.    All bytes are numbered starting from 0
c.    The number of a bytes is called address

Words, same for other bytes groups, are stored in a way that least significant byte is stored first followed by the most significant byte

Memory
a.    Primary Memory – “Main Memory, Read Write Memory (RWM), Random-Access Memory (RAM)” stores instructions and data while a program is running. The processor can work directly with this memory.
b.    Secondary Memory – resides on the disks. The processor cannot directly access the data in this memory.

Registers - refer to the RWM locations built in to the processor. There are 14 words of register for inter 86.

General Registers
Abbreviation
Name
Description/ Use
AX (AH, AL)
Accumulator
Principal Register used by arithmetic instructions. Often used to accumulate results of calculations
BX (BH, BL)
Base Register
Hold a base address
CX (CH, CL)
Count Register
Certain instructions that perform operations repeatedly. Used to keep track of the number of repetitions of operations
DX (DH, DL)
Data Register
Hold data for general purpose
Offset Register
BP
Base Pointer

IP
Instruction Pointer

SP
Stack Pointer
Contains an offset that points to the top of the stack
DI
Destination Index
Index Register
SI
Source Index
Index Register
Segment Register – it is where the segment address is kept.
DS
Data Segment Register
Part of the program that contains the data
ES
Extra Segment Register
Used to hold data
SS
Stack Segment Register
Holds the stack
CS
Code Segment Register
Contains the actual machine instructions

Stack – is a data structure that allows to store and recall data in last-in, first out manner.
a.    Push – to store data
b.    Pop – to recall the data
Share:

No comments:

Post a Comment

Thanks for Suggestion / Comment!

God Bless!

Our Sponsor

Popular Post

Blog Archive