16 bit - Assembly , Move an 8 bit register to a 16 bit Register , how? -
what want know said on topic. have problem moving 8 bit register 16 bit register . i'm trying , divide number permanently 10 til gets lower 10 , , , within each division time , try move out remained part of division out ah register , add 48 it, have ascii code , try show digit got , on screen . here code :
num1 dw 255 division : cmp num1,10 jl divend mov ax,10 div num1 mov num1,al ;* add ah,48 mov dl,ah; mov ah,02h int 21h jmp division
but , when im trying assemble , says , operand types not match on line indicated * . im using turbo assembler v4.1 ... should ?
did mean that?
mov bx, offset num1 mov [bx], al
the error because declare word adress byte. if did num1 db works.
tested tasm 4.1
Comments
Post a Comment