ISR for QNXRTP!

Hi,

When I wrote driver for COM1 or COM2 with InterruptAttach() function and

ISR Handler separately, they both work fine independently. When I put
two ISRs for both COM1 and COM2 together in each thread, the program
will have Memory Fault
(Core Dump). For COM1, InterruptAttach() and InterruptWait() are in
thread1; while for COM2, InterruptAttach() and InterruptWait() are in
thread2. It seems that kernel mess the event from InterruptWait().
Another thing I did is that in Handler of COM2 the return NULL is always

given, however, the problem is still there. Hence my question is that
whether QNXRTP supports multiple ISR in different threads independently
or in same thread. The answer for me should be positive!

Regards!

YUNCHUN YANG

ISR runs in the context of kernel, it’s just a trick that you can access
global variables which belong to process. Since kernel is not subject to
scheduling there is no applicable notion of threads I suspect.

  • igor

“Yang, Yunchun” wrote:

Hi,

When I wrote driver for COM1 or COM2 with InterruptAttach() function and

ISR Handler separately, they both work fine independently. When I put
two ISRs for both COM1 and COM2 together in each thread, the program
will have Memory Fault
(Core Dump). For COM1, InterruptAttach() and InterruptWait() are in
thread1; while for COM2, InterruptAttach() and InterruptWait() are in
thread2. It seems that kernel mess the event from InterruptWait().
Another thing I did is that in Handler of COM2 the return NULL is always

given, however, the problem is still there. Hence my question is that
whether QNXRTP supports multiple ISR in different threads independently
or in same thread. The answer for me should be positive!

Regards!

YUNCHUN YANG

“Yang, Yunchun” <yyang@ee.ucr.edu> wrote in message
news:3A78B1D2.308C8347@ee.ucr.edu

Hi,

When I wrote driver for COM1 or COM2 with InterruptAttach() function and

ISR Handler separately, they both work fine independently. When I put
two ISRs for both COM1 and COM2 together in each thread, the program
will have Memory Fault
(Core Dump). For COM1, InterruptAttach() and InterruptWait() are in
thread1; while for COM2, InterruptAttach() and InterruptWait() are in
thread2. It seems that kernel mess the event from InterruptWait().
Another thing I did is that in Handler of COM2 the return NULL is always
given, however, the problem is still there. Hence my question is that
whether QNXRTP supports multiple ISR in different threads independently
or in same thread. The answer for me should be positive!

Yes it should be positive. My first guess would be that you are
doing something wrong. Can you post the code?


Regards!

YUNCHUN YANG