Micro Oo
Micro Oo
CPU Memory
CPU
Memory
I/O ports
I/O ports
input output
Memory
Inside the microprocessor (made up of 3 main units)
- ALU
- Control Unit
- Register array
I/O
Input / Output
Memory
ROM RAM
RAM 1 4400
Address range of First RAM Chip
Address Range
5FFF
RAM 2 Address range of second RAM Chip
9000
RAM 3 Address range of third RAM Chip
A400
RAM 4 Address range of fourth RAM Chip
FFFF F7FF
Execution of a program:)(آلية التنفيذ للبرامج
1- The user enters instructions in binary into the memory (read) (fetch).
2- The microprocessor reads the instructions. (compile) (decode)
3- The microprocessor executes the instruction then shows the
result in memory or output device. (execute)
The sequence is continued till all of the instructions are performed
Machine language and assembly language are M.P specific & considered
low-level languages.
- Machine language is in binary.
- Assembly language is in English- like words.
- English words are converted into binary languages using compiler (or
interpreter).
- Compiler (or interpreter) : is a program that accepts English-like
statements as its input & converts the input into binary. (the input is
called the source code)
- The compiler translates the source code into machine language. (the
translation is called object code.
- Each M.P needs its own compiler or interpreter for each high level
language.
- the difference between the compiler & interpreter:
the compiler reads the whole program then translates it to object code.
the interpreter reads 1 instruction at a time and translates it to object
code, the it reads the next code and so on.