Interrupts in .c program ported to .C donot not work, Help!!

Hello,

I am using the DY4 hardware in my project for data acquitision.
The hardware supplier has provided the sample source code in .c files. In
their programs they are using some interrupt service routine. Here is the
sample codes

adc16DatIsr(IO_Channel *pChan)
{
// This is the isr which reads the adc data
}

There is a function which installs this ISR as
Return_Status ioIntrInstall(IO_Channel *pChan, INT intrEvent, INT
(*isrUserFunc)() );

In one of their sample program they have used this function like
ioIntrInstall(pChan, ADC16_EVENT_AVALABLE, adc16DatIsr);

When I complie their sample programs, it compiles without any error.

Now I have to use this functions in my project which uses all .C (c++)
extension files, and when I compile my project with ‘cc’ it gives me several
errors for this function like the 3rd parameter is not matching. I have also
used several compiler options which are given in the manuals.

I think there is some problem to use this isr routine in C++ instead of c
files or the method may be different.

Please, can anybody tell me what I have to do to convert this isr routine
from .c to .C programs
In short how to use these Isr in .C (cpp) programs. I requested the hardware
supplier, but they said they can not support for QNX help.

Ok

Thanks in advance.

Sunil Warke

Answered in qdn.public.qnx, please do not cross post.

“Sunil Warke” <sunil@bnftech.com> wrote in message
news:aepmu7$n7m$1@inn.qnx.com

Hello,

I am using the DY4 hardware in my project for data acquitision.
The hardware supplier has provided the sample source code in .c files. In
their programs they are using some interrupt service routine. Here is the
sample codes

adc16DatIsr(IO_Channel *pChan)
{
// This is the isr which reads the adc data
}

There is a function which installs this ISR as
Return_Status ioIntrInstall(IO_Channel *pChan, INT intrEvent, INT
(*isrUserFunc)() );

In one of their sample program they have used this function like
ioIntrInstall(pChan, ADC16_EVENT_AVALABLE, adc16DatIsr);

When I complie their sample programs, it compiles without any error.

Now I have to use this functions in my project which uses all .C (c++)
extension files, and when I compile my project with ‘cc’ it gives me
several
errors for this function like the 3rd parameter is not matching. I have
also
used several compiler options which are given in the manuals.

I think there is some problem to use this isr routine in C++ instead of c
files or the method may be different.

Please, can anybody tell me what I have to do to convert this isr routine
from .c to .C programs
In short how to use these Isr in .C (cpp) programs. I requested the
hardware
supplier, but they said they can not support for QNX help.

Ok

Thanks in advance.

Sunil Warke