Mail Archives: djgpp/1996/05/14/08:13:18
On Tue, 14 May 1996, Ralf Suessbrich wrote:
> My proggi compiles fine, but when i am running it,
>i get only one sound (when i press serveral keys on the keyboard).
> After 20 seconds it comes back to a dos prompt, but something went
> wrong with restoring the old vector: the keyboard is still out of
> function.
Try this :
main () {
_go32_dpmi_seginfo old_handler, my_handler;
printf ("Getting old I-Vector !\n");
_go32_dpmi_get_protected_mode_interrupt_vector (9, &old_handler);
my_handler.pm_offset = (int) keyb_handler;
//******Add this line \/
my_handler.pm_selector = _go32_my_cs();
//******Delete this line \/
//******_go32_dpmi_allocate_iret_wrapper (&my_handler);
printf("\nSeting new I-Vector !");
//******And change _go32_dpmi_set... with _go32_dpmi_chain...
_go32_dpmi_chain_protected_mode_interrupt_vector (9, &my_handler);
printf("\nDONE !!\n\nWaiting now 20 seconds for testing.\n");
sleep (20);
_go32_dpmi_set_protected_mode_interrupt_vector (9, &old_handler);
printf("\n\nOld I-Vector restored ;)\nEnd");
return 0;
}
For the solution, just read help file for _go32_dpmi_set... with INFO ;)
Bye
******************
Michael Duval
mduval AT teaser DOT fr
******************
P.S. : Sorry for my faults but i only learn (very little!) english at school !
- Raw text -