共享中断的问题

AD only need to move data to internal memory, needn’t calculation.

In fact, my style is sample.
Sample is beautiful.
I even make a software to generate code for realtime control.
It’s Funny.
But I don’t know how to upload image to bbs.
What’s real time OS? This is a funny question.
But windows NT Embeded is cuted from comercial Windows version. So no difference to commercial version.

http://f2.pg.photos.yahoo.com/david_li20002000
This software can generate code for WINDOWS and QNX and AD Sharc 21161 Motorola DSP56807 and mitsubishi m16c
You only need to put component to the drawing, and then it is ready to run.
:open_mouth:

I totally lost your point.

:laughing:

Could you tell me sample seep of your AD CARD and How many chennels
If you have 72 chennels. and sample speed is 4800
How many bytes per second?

72

  • 2 = 144
  • 4800 = 691,200 bytes per second

The original PCI bus was designed to operate with a 33MHz clock, to provide data transfer speeds up to 132 Mbytes/sec. These 32-bit adapters can use multiplexing to achieve 64-bit data transfers. (Later versions of PCI enable true 64-bit data transfers using up to a 133MHz clock to enable transfer speeds of up to 1066 Mbytes/sec.)

You if you run full time speed access to PCI. You only use about .5 percent.

In hardware design, The DI input only need to transfer the shift status. It will help to decrease the interrupt time. Of course with time stump.

The OS will emurate shared ISR one by one, Each ISR connected to the IQR will decide whether the request sponsed by it’s hardware. If so, it will handle it, otherwise just leave it.

Usually, PCI matchmaker have a FIFO. If I design this Addon card. I will use a dual port memory or fifo the interface with the AD. If you use DPRAM, use a soft FIFO in DPRAM. If you use FIFO, It will provide a QUEUE IN hardware.
In software, you also need a queue between your ISR and calculation program.
Do you remeber the serial and socket, they have a buffer. This will help you from error.

Only two member can access the queue.
One side only put new element.
Other side remove old element.

在openqnx的这个帖子里,很多人参加了这个问题的讨论。大致结论是,如果你要共享中断,除非你对所有的设备都能自己控制(自己的设备驱动),否则系统无法保证实时性(执行时间可确定性)。

楼主原贴的直接解决办法有几个,或者是调整(BIOS设定)使A/D卡单独享有中断,或者是使A/D卡与显卡共享中断,因QNX显卡驱动不使用中断。

If you have free time, Windows DDK will give you a lot of help.

Windows DDK designer’s guide. It’s a good book.

我自己设计的硬件,都要保证有足够的队列。时间的要求是相对的。对他的应用可以有5ms的计算延迟。因此实时不是关键,数据完整是他最优先保证的目标。

我是高级工程师了 :laughing:

“实时"并不是"快”.