One's compliment of 8- bit number
Aim:-
To find one's complement of an 8-bit number.
Apparatus:-
microprocessor kit.
Data:-
7501-96H
Memory address |
Machine code |
Mnemonics |
Operands |
Comments |
7000 |
3A,01,75 |
LDA |
7501H |
Get data in the accumulator |
7003 |
2F |
CMA |
|
Take its complement |
7004 |
32,02,75 |
STA |
7502 |
Store result in 7502 H |
7007 |
76 |
HLT |
|
HALT |
Procedure:-
1)How to enter the program
Esc->S->CR->CR S.address(7000)->CR->Esc->S->CR->CR->Data->CR
2)How to execute the program
Esc->Go->CR->CR->S.addresss->CR
3)How to check the result
S->CR->CR->address(7502)->CR
Result:-
7502-69H;. 7502-1BH
Comments
Post a Comment
Its not necessary everyone should know everything feel free to ask or tell :)