Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

C++ program to read from NI cDAQ-9191

I am trying to write a simple program in C++ that will be able to read temperatures in temperatures from the DAQ, (We are using NI 9213 24-bit Thermocouple Input modules). I have the NIDAQmx.h header file but it will take me a while to read through it just to understand how to simply get the temperature readings to the computer. If there's anyone who has already done this or knows an easy way to go about doing this, any help would be appreciated.

 

Thank you,

 

Tim

0 Kudos
Message 1 of 3
(4,927 Views)

Haven't you looked at the examples that come with the driver?

p.s. In the future, please post to the multifunction DAQ board.

0 Kudos
Message 2 of 3
(4,917 Views)

Hi Tim,

 

Unfortunately, the C++ DAQmx API is no longer supported. We do have C and C# DAQmx APIs. You can use the C API with C++ but you might want to consider C# as it is better suited for the Windows environment (if you are using Windows).

 

You will also need to install the DAQmx Driver to use its functionality in an application. Also, make sure to install the C/C# examples options in the installer. Please see below for more information.

Using NI-DAQmx in Text Based Programming Environments

https://www.ni.com/en/support/documentation/supplemental/21/using-ni-daqmx-in-text-based-programming...

Text Based NI-DAQmx Data Acquisition Examples

https://www.ni.com/en/support/documentation/supplemental/20/examples-included-with-ni-software-produ...

NI-DAQmx 14.2

https://www.ni.com/en/support/downloads/drivers/download.ni-daq-mx.html

0 Kudos
Message 3 of 3
(4,845 Views)