Turbo C Interrupt Question

News Administrator news at heitis1.uucp
Wed Oct 17 03:50:04 AEST 1990


In article <32905 at nigel.ee.udel.edu> shearer at cis.udel.edu (Rob Shearer) writes:
>of the REAL Clock no matter what...).  Can you Gurus inform me how to
>detect if the interrupt was hardware or software driven??  It is all

I had to work around this same problem once upon a time.  My solution was to
actually use 2 routines.  I called a non-interrupt specific routine from the
actual interrupt routine.  This way, all interrupt specific tricks could be
handled for me.  And if I decided to call the routine manually, I simply
called the non-interrupt machine from elsewhere in my code.  The only problem
with this method is if you are in a very timing critical portion of the code,
in which case I would suggest having parallel routines for the same function,
its not elegant, but it will work.

	brian



More information about the Comp.lang.c mailing list