Anda di halaman 1dari 1

LABORATORIO 10

1.
2.
3.
4.

Dentro del programa, ingresar su nombre y apellidos en NOMBRE Y SU PRIMER APELLIDO


Mostrar los valores iniciales del registro segmento DS, antes de ejecutar el programa.
Mostrar los valores finales en el registro segmento DS, despus de ejecutar el programa
Mostrar los valores que toman los registros antes y despus de ejecutar cada instruccin.

clave = 200
data segment
mensaje db 'NOMBRE'
valor=($-mensaje)
variable1 db 'APELLIDOS'
valor1 = ($-variable1)
variable2 db valor1 dup()
dato1 db -10,20h,30,40
dato2 dw 10,20,30h,8,9
dato3 dd 12,61001934h,5556h,78
dato4 dw ?,?
dato5 db 'Electronica Digital II'
data ends
code segment
assume cs:code,ds:data
inicio:
mov ax,data ; 0710
mov ds,ax
mov cx,valor
shr cx,1
cmp cl,5
jae x_1
x_1:mov cl,4
mov si,offset mensaje
l1: and byte ptr mensaje [si],0Cfh
inc si
loop l1
sub cx,cx
sub si,si
mov bx, valor1

and bx,00fh
shl bx,1
mov di,si
l2: xor variable1 [si],clave
mov ah,variable1[si]
xor variable1 [di],clave
mov variable2[di],ah
inc di
inc si
dec bx
cmp bx,0
jnz l2
mov ah,dato1
mov bh,byte ptr dato2
add ah,bh
mov byte ptr dato4,ah
mov bl,byte ptr dato3
add byte ptr dato4,bl
mov cx,offset variable1
not cx
code ends
end inicio

Anda mungkin juga menyukai