• 0

analog discovery2 labview


Question

Excuse me for being busy.
I am a Japanese university student.
This is a question about labview.
There are two problems with the current program.
One is an arbitrary waveform generator with an amplitude of 5V, but on the front panel it is 5V or higher.
It has become. I want you to tell me why.
The other is that the acquisition time is 500ms, but 500ms is not acquired.
Why.
Thank you for your patience.

 

 

スクリーンショット (1).png

スクリーンショット (2).png

Edited by kenken
Link to post
Share on other sites

Recommended Posts

  • 0

Thank you very much.
I was able to understand myself and explain to others.

I have a question about Labview. I'd like to graph the data as Excel at the end. At that time, I would like to make a line once for each sheet.
For example, if you go 5 times, you can have 5 rows per sheet.

Thank you.

Link to post
Share on other sites
  • 0

Hi kenken,

For logging the data in a spreadsheet, please right-click in a LabVIEW block diagram, select "Search" and look for "Write Delimited Spreadsheet". Double click on the search result, and then drag the icon that is highlighted into your block diagram. It should look like in the picture below.

image.png.770173a94f8055e4fe55339fef77a081.png

You then need to connect the data you want to put in a line to the "1D data" input, set the "append to file?" to T and also make sure you connect a constant or control with the file path and name to the "file path" input. This icon will create a CSV (Comma-Separated Values) file, which you can then open and edit in Excel or other similar programs.

Best Regards!

Link to post
Share on other sites
  • 0

Hi kenken,

In the VI you sent, you use two different methods to write to a measurements file: the "Write Delimited Spreadsheet" subVI I mentioned before and an Express VI for writing spreadsheets. You don't need both - any one of them would be enough. Therefore, I removed the Express VI and kept the "Write Delimited Spreadsheet".

Also:

- You did not wire a file path control or constant to the "file path" input, so I added a control for that;

- The waveform data you wanted to wire to the "1D data" input has a red dot next to the connection to the "Write Delimited Spreadsheet". This means some conversion must be done to the data, and this might mean it would not be written correctly to the spreadsheet. In our case, only one value gets written per run. The correct way to fix this is to index the array and take only the first waveform from it.

- Then, from the waveform you obtain, you only want the actual data samples, so you unbundle the data array (1-D) from the waveform; you then connect the result to the "Write Delimited Spreadsheet" 1D data input.

- The delimiter needs to be changed to a comma, so each written value corresponds to one CSV cell.

- If you want to save the waveform values with more digits after the decimal point, you can change the format from the default %.3f to, for example, %.7f.

I made the above changes, and uploaded the edited VI and a generated CSV file.

Best Regards!

datafile.csv 1206_edited.vi

Link to post
Share on other sites
  • 0

Hello.
Thank you very much for answering many questions sincerely. Thanks to you, good experimental results were obtained.

When I conducted an experiment based on the program I received the other day, some questions arose, so I will ask you a question.

In my experiment, I connected the oscilloscope made in Labview in parallel so that it could be displayed on the oscilloscope of the device.

Of these, the same waveform did not appear several times. Can you tell us something about that?

I think it's a timing issue or an issue with the use of Analog Discovery2.

Thank you.

Link to post
Share on other sites
  • 0

Hi @kenken,

I'm not certain what you mean when you say:

On 1/19/2020 at 11:57 PM, kenken said:

In my experiment, I connected the oscilloscope made in Labview in parallel so that it could be displayed on the oscilloscope of the device.

Of these, the same waveform did not appear several times.

Are you attempting to view the oscilloscope through both the WaveForms software and LabVIEW simultaneously?

I also don't understand what your statement of "the same waveform did not appear several times" means. How are you transferring the waveform? Where did the waveform not appear; on LabVIEW or the simultaneous oscilloscope or both? Did the waveform not appear initially or does it not appear intermittently?

Thanks,
JColvin

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now