LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

send .csv file data to analog output

Hello everyone,
I want to send a .csv file data to analog output with a daq to view it in an oscilloscope.
The problem is that the daq does not send the data.

 

 

Download All
0 Kudos
Message 1 of 9
(176 Views)

Your file only has one column, so why are you reading it as 2D array?

Can you explain your code, especially where you read data from an instrument? (I assume you know that both of your "code islands" execute in parallel and there is no way to tell what happens first. Most likely the express VI on the right executes first, because the other express VI is delayed by the file reading)

 

(Sorry, I cannot look at your express VI configurations because I don't have drivers installed here)

0 Kudos
Message 2 of 9
(169 Views)

Hello, thank you for the attention.

I am a newbie, sorry to ask, what do you mean by code islands?

What I wanted to do was outputting the signal, using the DAQ, to an analog filter and receive the filtered signal back to the DAQ. But when I tried watching the output signal in an oscilloscope, it did not show anything (although it showed the original signal from the csv on the left graph).

The first code island (assuming that you mean the leftmost block diagram) reads a column array in a csv file and outputs it to the DAQ. If I change the 2D array into a 1D array using index array, when I change the dynamic data type to 1D array, Error-200802 occurs. The second code island (assuming the one on the right) receives the same signal after passing through the analog filter.

0 Kudos
Message 3 of 9
(106 Views)

There is no "first" or "second" in your code. If the right part should wait until the part on the left has completed, you need to enforce execution order with dataflow principles.

0 Kudos
Message 4 of 9
(93 Views)

The problem is that there is no analog output signal when I am running.

0 Kudos
Message 5 of 9
(74 Views)

@newtrying wrote:

The problem is that there is no analog output signal when I am running.


You are not providing sufficient information to troubleshoot the problem.

0 Kudos
Message 6 of 9
(64 Views)

Hello thank you for your patience.
So I am trying to output the signal from the csv file by daq, however there is no signal when I run.
Now there are 2 columns in the csv: the first one is the signal and the second one is time samples to make a waveform

 

 

0 Kudos
Message 7 of 9
(55 Views)

Sorry, I forgot to send the files.

Download All
0 Kudos
Message 8 of 9
(53 Views)
  • What's the purpose of the while loop? Why would you need to read and process the same file over and over, as fast as the hardware allows?
  • You are not making any waveform anywhere. You are creating dynamic data where each row is a channel. The time is NOT a data channel. You have many rows, but only two columns. At least transpose when reading.
  • To create a waveform, you MUST assume that the timepoints are spaced equally, then form a waveform using t0, dt, and the Y data. Is there a reason t0 is 420000? What are the units? The value of dt seems to be 1
  • Why are you multiplying the time also by 0.1? Does that make any sense?

Overall, there are glaring logical flaws everywhere. You need to figure out what you really want.

 

(Sorry, no drivers installed, so I cannot look at the configuration of your express VI)

 

Here's how you would create a waveform from the two columns. (I left out the multiplication by 0.1 for the data for simplicity)

 

altenbach_0-1748282696821.png

 

0 Kudos
Message 9 of 9
(47 Views)