Date: Thu, 29 Jun 1995 14:58:28 +0300 To: djgpp AT sun DOT soe DOT clarkson DOT edu From: ere AT sci DOT fi (Petri Ehonsalo) Subject: Lost with interrupts Hi! i've been desperately tryed to convert following source to djgpp but i'm totally lost! Can somebody help me? #include #include #ifdef __cplusplus #define INTARG ... #else #define INTARG void #endif volatile int counter1,counter2; void interrupt (*old)(INTARG); void interrupt my_own(INTARG) { counter1++; old(); } int main(void) { counter1=counter2=0; old=getvect(0x1C); setvect(0x1C,my_own); cprintf("\r\nWaiting"); while(counter1<50) { if (counter1!=counter) { counter2=counter1; cprintf("."); } } setvect(0x1C,old); return(0); } Thanks to all, Petri