LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Can somebody please tell me the steps to Program USB 6211 with C. Will I get the software to program the device along with the drivers CD that I got when I purchased the Device?

Solved!
Go to solution

Hey Diya,

 

You had mentioned that you wanted to run it without CVI.

 

The second paragraph of the solution states:

If you do not have LabWindows/CVI, this KnowledgeBase contains the Borland C import library for various versions of NI-DAQmx. If you are using NI-DAQmx, you should be able to compile your applications against the NIDAQmx.h header file and link against the appropriate version of the import library.

Our devices are made to run with LabVIEW or LabWindows/CVI, but also work for other environments, even though it may be a little less straight-forward. 

 

If you have the DAQmx 9.0 driver, you can use the .zip file included in the Knowledgebase article associated with that specific driver.

Regards,
Jake G.
National Instruments
Applications Engineer
0 Kudos
Message 11 of 30
(2,039 Views)

Hi Jake,

Thankyou for the Reply.

Could you please help me in fixing this programming issue :

this is the program I wrote.(I've attached the C code)

COuld you please let me know what should I do , if I want the pulse that I'm creating in the file to be outputted only once but not continuously??

Here I see the pulse is oputputted continuously as a pulse train where as I just want it to be outputted once for every "Run" of the Program.

 

Thankyou

Diya

 

 

0 Kudos
Message 12 of 30
(2,019 Views)
Solution
Accepted by topic author Diya13

Diya,

 

Thanks for using the forums.  I am glad that you have been able to get this going.  Hopefully we can get you the rest of the way.  From looking at your code it looks like you used a continous anolog example.  If you would like to have the voltage update once, I would consider using the Mult Volt Updates-Int Clk.  This will generate a finite number of samples rather than using continuous samples.

 

I hope that helps,

 

Brian P. 

Applications Engineer
National Instruments
0 Kudos
Message 13 of 30
(2,005 Views)

Hi Brian,

I've tried executing this, but I dont see any output on my scope.

Please let me know if there is some thing wrong in my code. 

Thanks,

Diya

0 Kudos
Message 14 of 30
(1,985 Views)

Diya,

 

As a test, if you were to run that example code, do you see data on your scope, this will help us to narrow down if it is the example code that is not working, or the differences between your code and the example code that is not working.

 

Regards,

 

Brian P.

Applications Engineer
National Instruments
0 Kudos
Message 15 of 30
(1,964 Views)

Hi Brain,

Neither the example code nor my code is giving any output that I can see on the scope.

Thanks,

Diya

0 Kudos
Message 16 of 30
(1,958 Views)

Diya,

 

I was able to run the example code on a 621x device and the code ran great, so there could be a problem with you device.  A great test that you could do would be to wire the ao0 to ai0, and the ao gnd to ai gnd.  Then open a test panel in Measurement and Automation Explorer.  Change the sampling mode to continuous and the input configuration to RSE.  Then click start and uncheck the AutoScale Chart.

 

1) Wire the ao0 to ai0, and the ao gnd to ai gnd.  

2) Wire ao gnd to ai gnd.

3) Open a test panel in Measurement and Automation Explorer.

4) Change the sampling mode to continuous and the input configuration to RSE.

5) Then click Start and uncheck the AutoScale Chart.

6) Finally run the example code and see if it updates on the test panel.

 

I ran this exact test to check the example code and the device.

 

Regards,

 

Brian P.

Applications Engineer
National Instruments
0 Kudos
Message 17 of 30
(1,876 Views)

Hi Brain,

I checked with the example code and I saw it running properly on the test panels.

But for some reason I dont see an output on my scope, when I change it from finite to continous samples ;I see the output coming out on my scope. But no out put in Finite mode.

 

Regards,

Diya

0 Kudos
Message 18 of 30
(1,870 Views)

Diya,

 

I am sorry that you are still not seeing the signal.  I am assuming that you are using a benchtop scope, it could be a setting on your scope, where you are either zoomed in too far, and you are catching a continuous signal but not a finite signal.  But if you are reading that signal back correctly with the card then it is for sure outputting that signal.

 

If you do that test with the test panels, does your DAQ output the correct signal that you are trying to create?

 

Regards,

 

Brian P. 

Applications Engineer
National Instruments
0 Kudos
Message 19 of 30
(1,856 Views)

Hi Brain,

There was a small bug in my code with regards to the sampling rate of the board and the output signal.I managed to fix it. 

Thanks a lot for your help.

Regards,

Diya

0 Kudos
Message 20 of 30
(1,836 Views)