03-18-2023 09:47 AM
Hello everyone, I am still leaning data acquisition. I want my program to store voltage data while display the voltage curve on the waveform. Since I didn't connect my DAQ to the voltmeter, the output result will be very similar to zero volt.
As you can see, I use write delimited spreadsheet.vi to store my data into file. However, I find it weird when I open it with Excel.
The number of samples was set to 2000 while the sample rate was set to 4000. In the excel, the stored data has 2000 per row and two column for a second which makes it 4000 data per second. However, the way it display is really weird. Can anyone help me with this problem! Thank you so much.
Noted that I have two voltage channel input, so I think another question will be did I get the right data out of the 1D array? And sorry if there are some mistakes to the grammar of this article, English is not my first language. I tried really hard to express my problems.
Thanks a lot for reading and responding to this article.
Solved! Go to Solution.
03-18-2023 12:31 PM
Modify this part of the code out of the loop, it doesn't need to be run every time. Now, note that at every iteration of the loop, the function gives you 2000 points every line of the spreadsheet.
03-18-2023 12:32 PM - edited 03-18-2023 12:33 PM
Hi Billy,
@Billy90 wrote:
Noted that I have two voltage channel input, so I think another question will be did I get the right data out of the 1D array?
Why do you convert your DBL array to string array using the ToDecimalString? Did you read the help for that function to learn it will convert INTEGER values?
Other items:
03-28-2023 10:19 PM
Thank you for your response and the problem was solved!
03-28-2023 10:27 PM
WOW those are some really good questions. Since I am still new to LabVIEW, I don't know how to answer some of your questions. With that being said, I think I am still able to answer some of your problems. The reason I use string to be the input to control the sample rate and NumOfSamples is because I want UI to look better in the front panel (Weird reason). If I use I32 control, there will be a triangular selector next to it which I find it annoying. The next thing is that Why I don't use AutoCleanup. The reason is because I think auto cleanup makes it harder for people to understand the connections between elements. But thanks for the advice, I am learning a lot here.
03-29-2023 12:48 AM
Hi Billy,
@Billy90 wrote:
The reason I use string to be the input to control the sample rate and NumOfSamples is because I want UI to look better in the front panel (Weird reason). If I use I32 control, there will be a triangular selector next to it which I find it annoying.
Right-click the numeric control and look what hides behind the "Visible items" submenu…