Mail Archives: djgpp/1998/05/04/02:03:52
From: | "walker" <jsjiang AT cclk400 DOT ccl DOT itri DOT org DOT tw>
|
Newsgroups: | comp.os.msdos.djgpp
|
Subject: | Who can help me?
|
Date: | Mon, 4 May 1998 12:44:20 +0800
|
Organization: | Industtrial Technology Research Institute
|
Lines: | 32
|
Message-ID: | <6ijhft$3tu$1@news.itri.org.tw>
|
NNTP-Posting-Host: | pc104049.ccl.itri.org.tw
|
To: | djgpp AT delorie DOT com
|
DJ-Gateway: | from newsgroup comp.os.msdos.djgpp
|
I have one question about Interrupt.
My Interrupt Handler is written in C, hooking
IRQ 11 (Int vector = 0x73) as interrupt input.
My problem is : when this program is excuted in rhide debugging
environment, my interrupt handler functions normally. But after
leaving rhide, this function can not work anymore. After checking
the memory (using c:\debug), I found the interrupt handler
is not maintained in the memory after leaving rhide. How can I
maintain my code in the memory after leaving rhide? Anybody
can help me solve this problem? Thanks in advance.
Program sampled as follows
void InterruptHandler(void)
{
..................
..................
.....
}
void End_InterruptHandler()
{
}
void Init_InterruptHandler()
{ _go32_dpmi_lock_code(InterruptHandler,(long)End_InterruptHandler
-(long)InterruptHandler);
_go32_dpmi_get_protected_mode_interrupt_vector(0x73,&old_handler);
my_callback.pm_offset = (int)InterruptHandler;
my_callback.pm_selector = _my_cs();
_go32_dpmi_allocate_iret_wrapper(&my_callback);
_go32_dpmi_set_protected_mode_interrupt_vector(0x73,&my_callback);
}
- Raw text -