Quantcast
Channel: Digital I/O topics
Viewing all articles
Browse latest Browse all 2147

NI653x data transfer

$
0
0

Hi,

 

We have been using the NI6534 card for moving data from our system into a PC. It is working on both traditional driver and DAQmx. We are using handshanking timing for data transfering. Recently, we want to raise the data transfering speed and need to change the timing from handshaking to sample clock timing(pattern IO in traditional version). We got it work by using traditional driver, but not by DAQmx. I always get an error code when trying to start data aquiring. Error code -89129 - Terminal is not valid for the device. Here is C code for configure  and start the card:

 

    DAQmxCreateTask("",&m_taskHandle);
    DAQmxCreateDIChan(m_taskHandle,"Dev3/port0_32","",DAQmx_Val_ChanForAllLines);
    m_numofSampletoRead = 2000000;

 

// continue generating samples until stop.
    bRet = DAQmxErrChk(DAQmxCfgSampClkTiming(m_taskHandle,"Dev3/PFI2",20000,DAQmx_Val_Falling,DAQmx_Val_ContSamps,m_numofSampletoRead));
    // specify the buffer size
    bRet &= DAQmxErrChk(DAQmxCfgInputBuffer(m_taskHandle, BUFFER_SIZE));

 

 

once it passed the configuration and after the function DAQmxStopTask(m_taskHandle) got called, it returned that error code I mentioned above.

 

As for traditional version, I just added a call to funtion below and it worked fine.

if (!(status = DIG_Block_PG_Config( m_deviceNumber,
                                                m_group,
                                                1,            /* Enable pattern generation using REQ edge latching */
                                                1,            /* REQ source - External REQ */
                                                -3,            /* timebase - 50ns this is for internal clock */
                                                1,            /* REQ interval */
                                                (i16) 0)))    /* enable or disable external gating */

 

Can you help me how to make it run with DAQmx? Thanks.


Viewing all articles
Browse latest Browse all 2147

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>