Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Sync 9215 & 9263 VC++ usage

I am using these 2 modules for a sync analog I/O.  I tried the MultiFunctionSyncAIAO_DigStart example VC++.  The input part is running OK, however I have no voltage output.  My HW setup is very simple. A voltage generator at the input while a multimeter to verify the output.  I looked into the example and it mentioned about enabling the DataTransferMechanism property but I do not know how to use it. Plus, how do I handle the memory if in any case it become full during continuous data transfer or logging.
 
Thanks a bunch,
 
0 Kudos
Message 1 of 8
(3,755 Views)

Hi,


My first advice would be to try one of our analog generation examples, so no synchronization and make sure you are getting the correct output. You can also try generating a DC voltage from MAX.  What do you read if you connect the DMM just to the 9263, making just a analog generation with no synchronization?

I have been able to run the same example in LabVIEW with the same setup you have, and it ran perfectly. The test I made was connecting the analog output 9263 directly to the 9215 analog measurement and I was able to read exactly what I was generating.  I was also able to do the same setup with c# in .NET.

Let me know if you can run this test by reading the output from the 9263. If you do, then your issue is with your DMM.

I hope it helps

Jaime Hoffiz
National Instruments
Product Expert
0 Kudos
Message 2 of 8
(3,743 Views)
Hello Jaime F,
 
Thank you for the pointers.  Prior trying the sync setup, I did verify the individual modules using the MAX at the start.  It generated the expected input and output.
My DMM is ok but today i used the scope so i could see the waveform.  I followed the setup you mentioned and it did worked.  By adjusting the amplitude edit box gives me the corresponding voltage output.
 
I also would like to know how to handle the memory during continuous execution. 
 
Thanks,
Smiley Happy
 
 
0 Kudos
Message 3 of 8
(3,731 Views)

Hi

I’m going to point you to some resources but at the end data is move from onboard memory to RAM (application memory) and from RAM to disk. DAQmx driver controls the memory handle between the chassis and memory RAM.

Take a look at these documents: How Is the DAQmx Buffer Size Allocated for a Finite or Continuous Acquisition? and Read All Available Samples Function Does Not Return All of the Samples for a USB Device.

The code that I ran was in continuous acquisition mode and memory was been handle by the drivers and the development program in this case either LabVIEW, c++, c#.  Why do you need to know how memory is been handle?

I hope it helps

Jaime Hoffiz
National Instruments
Product Expert
0 Kudos
Message 4 of 8
(3,722 Views)
Hello Smiley Happy,
 
I'll browse through the articles later.  I am new to DAQmx so I am acquiring information that i need for future applications.  The continuous acquisition (memory management) is for a burn-in application.  I have no specifics yet at this time but that is one scenario that I have for DAQ usage. 
 
Thank you again.
Regards,
A
0 Kudos
Message 5 of 8
(3,713 Views)
I browsed through the below-mentioned links but they were not quite clear to me because they are in LabView.
Perhaps, if possible is there a VC++ example about buffer management?  Plus, how is the buffer
manipulated or adjusted if want to acquire data continuously.
 
Btw, I am using an 8.1 Measurement studio and a cDAQ0-9172 for my HW.
 
Thanks for any help.
Regards,
A
0 Kudos
Message 6 of 8
(3,649 Views)

Hi

 

The basics are the same for VC++ and for LabVIEW. The way DAQmx handles the buffer is the same for any development environment chosen.  A good point to remember is that the buffer size cannot be change while the task is running so the only management you can do is set the buffer to the right size buffer you start your task.

 

The right size is going to be the enough amount of memory to hold the samples while you are doing processing on the signal. But if you can take the data fast enough from the buffer you might not even need to change this property. You can set the input buffer size by: Using the DAQmx Configure Input Buffer VI in the DAQmx LabVIEW API, Using the DAQmxCfgOutputBuffer function in the DAQmx C API or Setting the Task.Stream.Buffer.InputBufferSize property in the DAQmx .NET API .

 

Since you told me you are new to DAQmx here are a couple of beginner’s articles we have: Learn 10 Functions in NI-DAQmx and Handle 80 Percent of Your Data Acquisition Applications, Answers to Frequently Asked Questions about NI-DAQmx and Traditional NI-DAQ (Legacy) and Using NI-DAQmx in Text Based Programming Environments. Although most of the articles are written for a LabVIEW audience the theory is always the same.

I hope it helps

Jaime Hoffiz
National Instruments
Product Expert
0 Kudos
Message 7 of 8
(3,636 Views)
Smiley Very Happy  Hi  Jaime F
 
Thanks a bunch for the information and it is indeed helpful.
I am browsing at them while creating applications. 
I am incrementally increasing the capability/ features of each program.
I started with 1 output & 1 input and gained a quite understanding.
Furthermore, I have increased my inputs and outputs.  I have a question
related to multiple i/o channels that i posted in a separate thread.
 
 
Thank you and more power.  Robot Very Happy
0 Kudos
Message 8 of 8
(3,615 Views)