Page 1 of 1

Interrupt Handlers

Posted: Sun Mar 30, 2003 12:00 am
by Nima
How I can set my own interrupt handler?
Thank you whoever you are.

RE:Interrupt Handlers

Posted: Tue Apr 01, 2003 12:00 am
by prasikumbhare
u need to setup idt first.. well if r writing a kernel ,u may like to set it up in C. for handler routines in C, u first write asm wrapper routines that in turn call C routines. the asm routine should end with 'iret' instructions.

for irq handling u also need to send End of interrupt signal at PIC port 0x20 as below :
outportb(0x20,0x20);

Go through to some OS source codes on this site... Alexfru OS seems to be good one for study. This is what I studied first.
Also check out my post ... 'setting up IF flag restarts' on this message board for demo code. At present I am also facing some problems about int handling.