Quantcast
Channel: x86 Assembly - Programmers Heaven
Viewing all articles
Browse latest Browse all 152

assembly help

$
0
0
im trying ot write a small program that replces the mouse interrupt hanlder wiht my own. im using nasm. my problem is putting the address of my handler, into the address of the interrupt hanlder. heres my source:

;that address of my handler si in es:bx while the address of
;the interrupt handler is 00:33h
jmp main

handler: ;this is my handler
;empty body of now
iret

main:
les bx, handler
xor ax, ax
mov fs, ax
mov ax, 33h
mov [fs:ax], es:bx

i dont know how wrong the rest of the code is, or if im even using the right addresses, i might have to use 32bit adress instead of 16, but i know that the last line wont compile. why?


Viewing all articles
Browse latest Browse all 152

Trending Articles