Skip to contentSkip to conversation

Interrupt Problem.

Xenomai-help shailesh joshi 2 participants 4 messages Aug 3, 2006 – Aug 4, 2006

lore
Share & tools
lore
#0 lore raw

Hello,

I am trying to interfce a DAQ board to a PC via a PCI card. I am facing the following problem:

I am trying to send an interrupt from the Board to the PC. However, the interrupt is only registered in the PCI cards internal registers and not by Xenomai, ie. the /proc/xenomai/ interface registers interrupt 10 in the list (namely, handler is being installed) but the count for both cpus remains at 0.

To give a hint of the code, i am using a modified version of the RTDM driver example from captain.at. The only parts i haven't incorporated are those for MMAP, else the code is fast the same. Could anyone suggest what i might be doing wrong here??

Regards,
Shailesh Joshi

---------------------------------
Talk is cheap. Use Yahoo! Messenger to make PC-to-Phone calls. Great rates starting at 1¢/min.

#1 lore raw
Quoted 7 lines · shailesh joshi

Hello,

I am trying to interfce a DAQ board to a PC via a PCI card. I am facing the following problem:

I am trying to send an interrupt from the Board to the PC. However, the interrupt is only registered in the PCI cards internal registers and not by Xenomai, ie. the /proc/xenomai/ interface registers interrupt 10 in the list (namely, handler is being installed) but the count for both cpus remains at 0.

To give a hint of the code, i am using a modified version of the RTDM driver example from captain.at. The only parts i haven't incorporated are those for MMAP, else the code is fast the same. Could anyone suggest what i might be doing wrong here??

Do you happen to have some standard Linux driver for your DAQ board? Does it work on your target? Are you sure you correctly initialise and enable IRQ delivery on the board?

BTW, already tried the irqbench the comes with recent Xenomai? Does it work on your box (yet another IRQ delivery test, and it's RTDM based)?

Jan

#2 lore raw

The board is custom made, the PCI card is of the make ADLink but has no Linux support. However, the same card worked for RTLinux, however, we had to drop the Idea for latency reasons.

i am guessing i am doing something wrong while initialising the handler. Like i said, the Card is generatimg the interript signal but linux is not acknowledging it, aka, the code does not enter the handler....I am using a sleep function in the user application but i guess that does not affect the RT code oder?? I am a beginner so I might be sounding very stupid. I request you to bare with me for the time being till i sharpen up.

Regards,
Shailesh.

P.S: I am initialising the handler with rtdm_irq_request. Have also tried rthal_irq_request. Any suggestions there??

Jan Kiszka <[email protected]> wrote:

Quoted 7 lines · shailesh joshi

Hello,

I am trying to interfce a DAQ board to a PC via a PCI card. I am facing the following problem:

I am trying to send an interrupt from the Board to the PC. However, the interrupt is only registered in the PCI cards internal registers and not by Xenomai, ie. the /proc/xenomai/ interface registers interrupt 10 in the list (namely, handler is being installed) but the count for both cpus remains at 0.

To give a hint of the code, i am using a modified version of the RTDM driver example from captain.at. The only parts i haven't incorporated are those for MMAP, else the code is fast the same. Could anyone suggest what i might be doing wrong here??

Do you happen to have some standard Linux driver for your DAQ board? Does it work on your target? Are you sure you correctly initialise and enable IRQ delivery on the board?

BTW, already tried the irqbench the comes with recent Xenomai? Does it work on your box (yet another IRQ delivery test, and it's RTDM based)?

Jan

---------------------------------
Do you Yahoo!?
Next-gen email? Have it all with the all-new Yahoo! Mail Beta.

#3 lore raw
Quoted 8 lines · shailesh joshi

The board is custom made, the PCI card is of the make ADLink but has no Linux support. However, the same card worked for RTLinux, however, we had to drop the Idea for latency reasons.

i am guessing i am doing something wrong while initialising the handler. Like i said, the Card is generatimg the interript signal but linux is not acknowledging it, aka, the code does not enter the handler....I am using a sleep function in the user application but i guess that does not affect the RT code oder?? I am a beginner so I might be sounding very stupid. I request you to bare with me for the time being till i sharpen up.

Regards,
Shailesh.

P.S: I am initialising the handler with rtdm_irq_request. Have also tried rthal_irq_request. Any suggestions there??

rtdm_irq_request is the way to go, followed by rtdm_irq_enable. See also the existing examples like Hannes code or irqbench. If still unsure, post code so that we can have a look.

Jan