RE: Fwd: Re: NI SCXI and E series boards

On Mon, 14 Oct 2002, Caleb Tennis wrote:

>
> > (Thanks for replying) Ok, so the SCXI 'protocol' is well documented
> > and getting the modules to do what I want shouldn't be too much
> > trouble from comedi, correct?  I just have to do some magic on the DIO
> > lines...
> >
> > Now on to my next question: Multiplexing.  What I understand is that with
> > some of the modules, the idea is that you have something like 32 channels
> > coming in to 1 channel on your DAQ board.  You then have to demultiplex
> > these channels in software.  Is that correct?  How is synchronization
> > between the DAQ device's sampling of the 1 channel and the SCXI hardware's
> > multiplexer guaranteed?  The timer on the NI board? Is it possible to use
> > this system for control, and not just measurement?
>
> Heh.  Well, it is well documented, but it's very convoluted.  Naming
> conventions seem to be all aflutter and I find it a bit hard to understand.
> In Windows (with Labview, at least) it's just a matter of using pre written

Well, to my own discredit I have never used Labview.  We were never big
Windows people here and after discovering Comedi I decided to stick to
C in (realtime) linux kernel modules with comedi. :/

> VIs.  In Linux with comedi, it's just a matter of using some pre written
> code.  I'd be happy to give you my stuff coupled with the scxi patch for
> comedi if that would be helpful.  I basically wrote some wrapper functions
> that do something akin to "ModuleSelect(int channel)".  Theoretically you
> can do control with them; in fact there are some old modules that were

I would be _extremely_ grateful for that.  It isn't useful yet, but if
you send it now, at least I can take a look at the code and see how one
goes about talking to these modules.  It would be great actually! :)

We haven't yet gone out and bought an SCXI system, we are still doing a
feasibility study of sorts to figure out what would work well for us.  We
plan on doing mapping of cardiac tissue (a two dimentional 8x8 grid at
first) with a sampling rate sof 1kHz per node on the grid (for a total of
64kS/s).  We figured we could probably get 1 E-series NI board and two of
those SCXI-1100 32-channel modules for signal conditioning.  We also would
need to do control on a per-sample basis.. meaning we need to be able to
react to data in hard realtime and issue 1 or 2 AO signals out again, to
stimulate the tissue.  Is this feasible, in your opinion?

> controller cards, though I don't think they are still in production.  They
> do make a 6 channel Analog Out card, the SCXI-1124.

Wow.  Well that would be cool, although our signal conditioning on AO need
not be so nice.  I think for AO, since there are such few signals for
stimulation (probably 1 or 2, 6 at most), we could just use another device
external to the system -- one triggered by either DIO lines or AO lines
on the DAQ board.

>
> Demultiplexing is done just by sending a serial based command to some
> internal registers in the chassis.  That connects the input line up to
> analog channel 0 on the E series DAQ board.  Synchronization is done via a
> serial clock (1 of the 4 required digital IO lines).  In the Linux case,

So you have to control the synchronization yourself in software?  Hmm.
What's this I read in the NI catalog about using the DAQ board's internal
timer.  Is that doable too?

> it's done via an internal function call that just transitions the clock low,
> does a usleep(), then transitions high again.  Some modules can clock data
> faster than others.

Right -- each module has its own spec with respect to how fast it can
sample.  Hmm.. so what you are telling me is that this is heavily
driver-driven acquisition.  It kind of makes things messy for us, in that
we have to constantly be talking to serial lines to tell the multiplexer
what to do, then quickly grab a sample off the board, then repeat for the
next channel.  Does this involve a lot of comedi_data_read() calls, or
would the asynchronous interface in comedi actually work?

Thanks so much for your thoughts Caleb...

-Calin

Received on 2002-10-14Z16:43:25