8086 assembly code

  1. Hi!
    I am new to assembly language.
    I wrote for a simple program for complementing the content of address 0300:0 and save it in address 0300:1.

    Here is my program

    OUTPUT 2500AD
    ORG 2000H
    MOV DX,0FFE6H
    MOV AX,82H
    OUT DX,AL
    NEXT:MOV AX,3000H
    MOV BX,0000H
    CALL DISP
    NOT AL
    MOV 3001H,AL
    MOV BX,0100H
    CALL DISP
    JMP SHORT NEXT
    DISP:PUSH AX
    MOV CX,1
    CALL FAR 0FF00:0B12H
    POP AX
    RET
    END
    I am using 8086 trainer kit to test it.But this program takes the 3000H as the data and shows on the data display.The result that complemented is 30FFH on address display.Can someone tell me what goes wrong in my program?
    I had initially loaded 20H as the 1 byte data in address 3000H.
    Thanks!
     
  2. jcsd
Know someone interested in this topic? Share this thead via email, Google+, Twitter, or Facebook

Have something to add?

0
Draft saved Draft deleted