From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
07-02-2014 03:40 PM
Hello,
i am developing PXI 6341 DAQ DIO Read/Write functions.
i like to support similar ones in DAQmx interfaces:
DAQmxWriteDigitalU8()
DAQmxReadDigitalU8()
DAQmxWriteDigitalLines()
DAQmxReadDigitalLines()
i am looking into
\nimhddk\nixseries\Examples:
Digital Input
dioex1.cpp—Single-point on-demand digital input and output on ports 0, 1, and 2
dioex2.cpp—Finite hardware-timed digital input <<<<<<<<<<<<<<<<<<<<
dioex3.cpp—Finite hardware-timed digital input with change detection
dioex4.cpp—C ontinuous hardware-timed digital input with optimized DMA
Digital Output
dioex5.cpp—C ontinuous hardware-timed digital output with regeneration <<<<<<<<<<<<<<<<<<<<<
dioex6.cpp—C ontinuous hardware-timed digital output with the Watchdog Timer
We have three exmaples for Digital Inout and two for Output as above.
i am thinking of using
(1) DIO_Write - dioex5.cpp
(2) DIO_Read – dioex2.cpp 0r dioex4.cpp
Can anyone confirm or give some comments?
07-07-2014 01:18 PM
What operating system are you using? From what you described, if you are unable to use the DAQmx driver, it looks like you are going in the right direction with those particular C++ examples in the NI-MHDDK. Have you tried implementing any of the functions already? Let us know if you run into difficulty.
07-07-2014 01:27 PM
OS - Linux - Fedora 15.
i think i was looking at wrong examples - again i am tring to accomplish setBits and resetBits of NI 6341 24 DIO lines.
i believe the correct example i should be using is
nimhddk\nixseries\Examples\dioex1
Appreciate if this can be confirmed.
i am in the middle of impelementing - dio fuctions: setBits(), resetBits(), ReadPort().
thank you,
su jung,
07-08-2014 01:52 PM
On X Series devices, dioex1.cpp performs Single-point on-demand digital input and output on ports 0, 1, and 2. If this is what you are looking to do, this is the correct example. I have included the Readme for the NI-MHDDK below for your reference.
http://download.ni.com/evaluation/labview/ekit/other/downloader/readme.html#examples_nixseries
Any other information you can give me about your system would help us determine if this is the correct example you should be using.
07-10-2014 12:40 PM
Hello,
i find below in the example dioex1.
Would you expaline what does the setTristate true mean? i noticed that it resets upon exit.
when do you set true or set false?
//
// Create subsystem helpers
//
tBoolean tristateOnExit = kTrue;
nNISTC3::dioHelper dioHelper(device.DI, device.DO, status);
dioHelper.setTristate(tristateOnExit, status);
dioHelper::~dioHelper()
{
if (_tristate || _exampleStatus.isFatal())
{
nMDBG::tStatus2 status;
reset(NULL, 0, status); <<<<
}
}
07-10-2014 02:12 PM
Hi,
I've included a link to a community webpage for the Driver Development Kit. This forum has active members who work with this software. I would recommend posting here!
http://forums.ni.com/t5/Driver-Development-Kit-DDK/bd-p/90
Thanks!