I've got a question about timing incoming IR signals and decoding them
Here's my story. I've built a device which detects IR signals at 38KhZ
and sends interrupts to the parallel port. Then I created (well, I
didn't write it entirely, but I edited one I found on the internet) a
driver to catch those interrupts and I created a usermode program to
interact with the driver. So far so good, everything seemed to work
fine. I receive interrupts when I press a button on my remote control
or when I just connect a wire between pin 2-9 and 10 of the parallel
But there's also a problem. For some reason, I receive way too few
interrupts when I press a button on my remote control, and the time
between the interrupts always is nearly identical. My only guess is
that for some reason processing an interrupt hasn't finished yet when
the next interrupt arrives and that therefore that interrupt doesn't
get handled. That should also explain why the time between logged
interrupts is nearly identical; it always takes the same time to
complete one interrupt and after that it can handle another. But I
don't get why handling the interrupt would take that long. My pc
should be fast enough to handle it.
Here's my isr and dpc routine and after that the part in DriverEntry
where I connect the interrupt to my driver. When an interrupt occurs,
first the isr gets called and then the dpcroutine.
I hope any of you have an idea why it doesn't handle all interrupts or
what the problem is and how it can be fixed.
Thanks in advance,
Floris van Nee
BOOLEAN hwinterfaceIsr(IN PKINTERRUPT Interrupt, IN OUT PVOID Context)
PDEVICE_OBJECT DeviceObject = Context;
//KdPrint( ("hwinterface.sys: Interrupt Service Routine\n") );
/* We should check if the interrupt comes from us and return */
First of all tell me. Do you have any problem to switch on com port? Printer port has its limitationís. Please read Printer port mode details and select as desired mode in bios. May be you can feel some relief. If you are interested in doing same thing through serial port so I can help you fully.