Re: NI-6251: configuring PFI to behave like standard DIO

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Friday 08 June 2007 07:34 am, Matthieu Roussel wrote:
> My project requires reading and writing from the 3 digital subdevices found
> on the NI-6251. In that respect I modified the available Simulink blocks to
> get the possibility of choosing the subdevice that I want to interact with.
> This works fine with the first subdevice, P0. However, the other two
> subdevices are PFI X/P1.X and PFI X/P2.X and seem to behave natively in a
> different way: I can read, but not write, on P1.X, and I dont seem to be
> able to do anything with P2.X.
> Seeing as these subdevices are not simple DIO, is there a special
> configuration (besides comedi_dio_config() ) to make them behave like
> normal DIO subdevices? or at least DI?

There is INSN_CONFIG_SET_ROUTING.  Try using it on the pfi subdevice (7).  The 
cvs version of comedilib/include/comedi.h has various constants that can be 
used to select a source with INSN_CONFIG_SET_ROUTING, you probably want 
NI_PFI_OUTPUT_PFI_DO.  There is also a comedilib/demo/choose_routing demo 
program. 

The driver's third dio subdevice is not PFI, it is RTSI.

- -- 
Frank
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFGbZS05vihyNWuA4URAgP0AKDcZOBLXb6+VP08OnAQJ++VS2IsMwCfYKxP
CCxlER4HFY2nzU/ufEs0gGE=
=G3mi
-----END PGP SIGNATURE-----

Received on 2007-06-11Z17:30:09