LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Data acquisition from an oscilloscope

Hi,

 

I am trying to build a program in Labview in order to acquire the data presented in the waveform of my oscilloscope. I am using a Rigol oscilloscope which is connected to the pc through a usb cable. I am trying to connect the oscilloscope to Labview via Visa. Moreover, the aim of my program is to first present in Labview the waveform depicted in the oscilloscope and secondly to acquire and save the data of the waveform. As I am relatively new to Labview could you please help me build up this program?

 

Thanks in advance!

0 Kudos
Message 1 of 13
(6,148 Views)

Hi John,

 

The first step would be to get your scope to communicate with the computer using a software provided by Rigol. 

 

Hopefully you can find some drivers for your Rigol instrument on the instrument drivers page or from Rigol's website. Once you get those, you will copy them your "instr.lib" folder, and then they will appear in the palettes.

 

Many drivers follow a similar pattern of Open Instrument -> Do Stuff -> Close Instrument. Try to search through the VI Tree and see if you can find the ones you need to do the stuff you want to do.

 

Once you have your data, there are a variety of ways to write it to a file. I find "Write Delimited Spreadsheet" works a lot of the time for me.

 

When you get stuck, post your code here (the VI, or a zip folder of VIs) and we will help you get unstuck. Good luck!

0 Kudos
Message 2 of 13
(6,140 Views)

Take a look at these links:

http://sine.ni.com/apps/utf8/niid_web_display.download_page?p_id_guid=88AF154718E95366E04400144FB7D2...

https://rigol.desk.com/customer/en/portal/articles/2272653-labview-2011-general-example-vi-for-ds-os...

 

It is usually good to start to search Google with a part number, manufacturer and LabVIEW or LabVIEW drivers.  There should also be a communication manual that will explain how to talk with the equipment you are interested in if it is available.  The manufacturer vi's may not be the best, but they are usually a good start.

Message 3 of 13
(6,139 Views)

Thank you for the helpful info. As I have started building the block diagram I have seen that many people use the following component (see picture) for acquiring data. Do you know where I can find it?

0 Kudos
Message 4 of 13
(6,136 Views)

Also if anybody knows where I could find these 2 components (see picture) it would be extremely helpful!

0 Kudos
Message 5 of 13
(6,134 Views)

That's a waveform chart or graph. They both work similarly- one maintains a history and the other only shows the data presented at its terminal.

 

Get those on your front panel by right clicking, selecting the Graphs palette, then Waveform Chart (or Graph, depending on your needs).

Message 6 of 13
(6,122 Views)

Hi John,

The first picture is a waveform indicator. It has nothing to do with the actual acquisition of the data, but is just a container for it, and a display on the front panel.

The second picture uses the Fract/exp string to number function to convert a string to a number. 

If you go to the top of the LabVIEW forums page you will find LabVIEW Training Resources which will teach you some of the basics. LabVIEW is a programming environment by the way. So just like you wouldn't expect to be able to write a program in C without any prior knowledge, same goes for LabVIEW.

Message 7 of 13
(6,117 Views)

@Gregory wrote:

Hi John,

The first picture is a waveform indicator. It has nothing to do with the actual acquisition of the data, but is just a container for it, and a display on the front panel.

The second picture uses the Fract/exp string to number function to convert a string to a number. 

If you go to the top of the LabVIEW forums page you will find LabVIEW Training Resources which will teach you some of the basics. LabVIEW is a programming environment by the way. So just like you wouldn't expect to be able to write a program in C without any prior knowledge, same goes for LabVIEW.


The caveat here is that LabVIEW makes it a whole lot easier to write bad code because the beginner can intuit just enough to get themselves into some real trouble.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
Message 8 of 13
(6,058 Views)

once you donwload the code from the Rigol LabVIEW example from the webpage you will have a starting point to start programming your vi. 

Run the example and understand what is being doing. That's pretty straight forward.

RKO
0 Kudos
Message 9 of 13
(6,054 Views)

@ROtake wrote:

 

Run the example and understand what is being doing. That's pretty straight forward.


After a while it may become second nature, but that's not particularly helpful for someone brand new to LabVIEW. The best way to become acquainted with the features of the development environment is to go through some training first.

Message 10 of 13
(6,043 Views)