Re: Enabling RTSI use in NI PCI-6071-E cards

On Wed, 18 Jun 2003, Colin Sauder wrote:

> Ok, so our problem is this.  We've got these two cards, except the
> internal clocks are not the same, so what happens is that they may start
> in sync but slowly fall otu of sync.  We're trying to set up a 128
> channel EEG rig, so it is essential that the the input from the cards is
> 100% in sync with each other and also the behavioral task.  So, from

You could accomplish this purely in software (no RTSI cable needed) using
real-time linux and comedi.. but whether or not what real-time linux can
do for you is sufficient depends on your requirements.  Namely, what
sampling rate are we talking about, how many channels, and what is your
tolerance for "out of synch-ness"?  10 nanoseconds? 10 microseconds? 1
millisecond?


> reading over all this and some other research, it seems that the only
> way to sync the cards is via the RTSI cable.  Because our clocks aren't
> in sync, we'd want to send the master timebase from card to card just
> like Tim said.  However, we don't know how to talk to the RTSI port
> through the comedi drivers.  Is there any sample code or documentation
> on addressing the port somewhere?  Or am I entirely off the mark here,
> and we need to try and do this some other way.

You aren't entirely off the mark at all.  Ideally we would _want_ comedi
to support such functionality, however it doesn't.  I don't know if
national instruments publishes specifications on specifically _how_ to
talk to these boards to program them so they do RTSI... if it does then
you could invest in writing extensions to comedi and/or the ni_pcimio
driver to support this.  If it does not.. then.. yeah.. we are out of
luck.  :)


However if you have a sufficiently slow sampling rate and a sufficiently
tolerant view of what it means to be synchronized or not, you can get
deterministic, upper-bounded synch-ness through software alone if you use
real-time linux variants with comedi (RTAI and RTLinux are the two big
variants).

-Calin

>
>
> Colin Sauder
> Volen Center for Complex Systems
> Brandeis University
>
> Calin A. Culianu wrote:
>
> >On Wed, 18 Jun 2003 tim.hayles_at_ni.com wrote:
> >
> >>PCI cards linked by RTSI are physically connected to a single  RTSI cable
> >>in a single machine.
> >>
> >>All the signals you need for synchronization are available at the I/O
> >>connector (so you can accomplish it with external wiring) except one: the
> >>20MHz Master Timebase. That can only be sent from board to board via a RTSI
> >>line (RTSI 7 I believe). But, you may be able to accomplish your
> >>application without that signal
> >>
> >
> >I know so little about this it isn't funny.  So basically there is custom
> >hardware on the boards so they can be driven by some clock signal coming
> >in from the outside.. from this 'master timebase' so that they both
> >collect samples at the exact same time or some guaranteed finite time
> >spacing (interleaving?).
> >
> >Ok so do you want to know if this hardware can be enabled and programmed
> >through comedi?  If you get the register-level programming specs for
> >programming the cards to do RTSI, I should imagine it wouldn't be impossible to get comedi
> >to do this.  Although maybe you would need David Schleef to approve and/or
> >suggest where such functionality would fit into comedi...
> >
> >Do you have register specs for this?
> >
> >-Calin
> >
> >>- Tim Hayles
> >>
> >>
> >>
> >>
> >>"Calin A. Culianu" <calin_at_ajvar.org>_at_comedi.org on 06/18/2003 09:05:23 AM
> >>
> >>Sent by:    comedi-admin_at_comedi.org
> >>
> >>
> >>To:    Colin Sauder <csauder_at_brandeis.edu>
> >>cc:    <comedi_at_comedi.org>
> >>
> >>Subject:    Re: Enabling RTSI use in NI PCI-6071-E cards
> >>
> >>
> >>
> >>Physically how are the cards linked in RTSI?  Are they always on the same
> >>machine?  Or are they linked by one pin on two different machines and the
> >>real synch is done in hardware?
> >>
> >>-Calin
> >>
> >>On Thu, 5 Jun 2003, Colin Sauder wrote:
> >>
> >>>Comedi currently does not support RTSI functionality.  I am currently
> >>>attempting to find a way to sync two data collection cards, and would
> >>>prefer to do it via RTSI.  I was wondering if anyone has any hints or
> >>>suggestions to either 1) work around RTSI and sync the cards, or 2)
> >>>enable RTSI in linux.
> >>>
> >>>Thank you,
> >>>Colin Sauder
> >>>Volen Center for Complex Systems
> >>>Waltham, MA
> >>>
> >>>
> >>>_______________________________________________
> >>>comedi mailing list
> >>>comedi_at_comedi.org
> >>>https://cvs.comedi.org/cgi-bin/mailman/listinfo/comedi
> >>>
> >>
> >>_______________________________________________
> >>comedi mailing list
> >>comedi_at_comedi.org
> >>https://cvs.comedi.org/cgi-bin/mailman/listinfo/comedi
> >>
> >>
> >>
> >
>
>
>

Received on 2003-06-18Z20:06:04