06-29-2010 02:58 PM
One way to increment file numbers.
06-29-2010 02:58 PM
@tanyasue327 wrote:
Also do you know if there is a way i can flip the way the write to spreadsheet data log to do 7 columns(one for each channel) and n rows, for however many time steps. It seems to be doing this backwards
Showing a clip of the drawing sorry for the sloppy explanation with the pen. I can't draw with a mouse.
Take out the transpose 2D array. That should fix it.
06-29-2010 03:02 PM
I guess it would be the same time every value?
Basically if the data records 10 seconds in, I want 7 data points at ten seconds.
Does that make sense?
06-29-2010 03:02 PM
And what happens when you read the timestamp output of the Fieldpoint Read?
Also, you are the one who 'flipped' the data by setting Transpose to True. You also have the Write to Spreadsheet set to create a new file each time it is called.
06-29-2010 03:06 PM
Clearly I'm learning here... I apprciate you pointing out my mistakes but you don't have to be so mean about it. Please don't reply to my posts unless you have something I can work with. It's a waste of my time to come back and check while I'm trying to debug this.
06-29-2010 03:18 PM
You have no idea what mean is and you have no idea about much else it seems. You clearly asked why the data was flipped. I simply told you why. I also noticed a newbie mistake in how you were writing to file. I also noticed that you were not reading the timestamp from the function and you clearly asked why you had no timestamp data. At no point was any of that mean.
06-29-2010 03:22 PM
If I just understood it correctly. You want to take one data point for every second. If that is true then your code should look more like this.
This will take an average of the values that you colect for each channel and average them build a 1D array and add a time stamp for that one row of data. I took out the transpose arry function and remove the opton from your wirte to spreadsheet. I also changed the append the file to true. This will make it so that every time you get new data it will add it to the end of the file. This will creat a running log.
06-29-2010 03:22 PM
My apologies. It's been a 12 hour day for me already... I didn't realize the transpose was on... I fixed that.
I have 7 channels, how am I supposed to get timestamps for all 7? Build another array and wire it to the file? Won't that give me 7 different times in 7 different channels?
Also to get a new file name everytime, how am I supposed to wire that? It's driving me crazy this LabVIEW stuff
Here's my updated .vi
Version 8.6
Thanks
06-29-2010 03:33 PM
No problem.
It was an honest question on my part about the timestamp output. I really don't know exactly what it returns except it is a numeric. What I would suggest is that you create an indicator for one and see what it says. I have little experience with FieldPoint and don't know if it's seconds since some date like the LabVIEW timestamp or something else. All I am suggesting is that it might be something you can use directly. If the timestamps from each FP module vary, you may find it important to record each time in column adjacent to the reading. The first step, hoever, is to see what those timestamp numbers are.
06-30-2010 06:40 AM
I'm totally lost. What I just did was take the time stamp from each FP Read and then convert it to a date/time string with %H%M%S and got a number like 200400.
I'm not looking for a date and time but just the seconds it records. 1,2,3...n.
The time stamp does show that each channel records at a slightly different time, and this is by milliseconds, so I don't believe that matters much... As long as I can get in the timing to the file I'm all set.
Thanks again for any help