Experiment 1
Experiment 1
Theory:
1- MOV:
MOV REG,REG
MOV REG,MEM
MOV MEM, REG
REG could be 8 bit [AL, AH, BL, BH, CL, CH, DL, DH] or 16 bit [AX, BX, CX, DX, SP,
BP, SI, DI]
2- ADD
ADD REG, Value : value should be same as REG size
ADD REG,REG
ADD REG,MEM
ADD MEM, REG
3- LODSW
LODSW is one of Load string commands [LODS/LODSB/LODSW/LODSD]
LODSB ;AL:= Memory(DS:SI) then depending on the Direction flag
incrementing/decrementing the SI. (default increment)
LODSW ; AX = Memory(DS:SI)
4- STOSW
STOSW is one of Store string commands [STOS/STOSB/STOSW/STOSD]
STOSSB; Memory(DS:DI) :=AL then depending on the Direction flag
incrementing/decrementing the DI. (default increment)
STOSW; Memory(DS:DI) :=AX
Assembly Program
Procedure
Discussion