In this course, we will study different programming languages used, assembly language, its advantages, its disadvantages, the instruction set of intel 8085, machine language, and the difference between the two.
There are various programming languages that can be used for writing programs and applications. They are:
The CPU can only understand the language of ones and zeroes that is machine language. It is the first generation of programming languages. It was used in ancient times but it was hard to memorize and modify.
So the second generation of programming languages was developed, that is assembly language, the assembly language consists of English mnemonics. The assembly language was much easier to understand and memorize. Modification in the language can be done more easily. The assembly language is converted into machine language using a compiler.
Further, the third generation of programming languages was developed named the high-level language. It is completely English language and easy to understand and memorize. The high-level language is converted into assembly language with the help of an interpreter.
The assembly language acts as the intermediate language between the two-machine language and high-level programming languages. Assembly language is easier to comprehend and use as compared with the machine language; however, it is more complex than high-level programming languages.
ADD r - add
ADD M -add to the memory
ADC r -add with carry
Add M -add with carry to memory
LDI -load immediate
LDA -load accumulator direct
SLA -shift contents of the register one place to the left
MOV -move data
MOV M A -move result from memory to register A
STA -store on the register
STA a -store to the accumulator
SUB r -subtract
SUB M -subtract memory
The machine language comprises the bits. As we all know that for computers to understand the commands provided in high-level languages the instructions have to be converted in machine language that comprises bits. The compiler or interpreter does the conversion of a high-level language to machine language.
|Assembly language||Machine language|
|It is an intermediate programming language.||It is a low-level language.|
|Assembly language uses English syntax and hence it is easier to understand.||Machine language uses zeroes and ones and is not that much easier to understand.|
|This language is easily understandable by the programmers but not by the CPU.||This language is harder to be understood by the programmer and can be easily understood by the CPU.|
|They are second-generation programming languages.||They are first-generation programming languages.|
|The codes and instructions can be easily memorized by the user.||The binary codes can’t be easily memorized.|
|Modification can be done very easily.||Modification can not be done easily.|
|They are not platform dependent.||They are platform-dependent and their features vary accordingly.|
|There is a need for a compiler for executing commands.||There is no need for any sort of compiler for executing commands.|