LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Two column csv to waveform graph

Solved!
Go to solution

icemaker wrote:

I converted my 24hr time to seconds. I tried two things, wiring as seen in picture below. And also tried converting to time stamp as you suggested. When I make it a timestamp I get a broken wire when I put it into the array.


What I actually said was that if you use a timestamp datatype then you need to use the To Double Precision Float function to convert the timestamp to seconds.

Message 11 of 19
(2,318 Views)
Well that is my question. If I have it in seconds already why or how do I convert it back to a format for the chart. I parse it to seconds and what I understand you as saying is go from seconds to time stamp then use the double precision float an wire that to the chart. But that does not work.
0 Kudos
Message 12 of 19
(2,313 Views)

You're still not reading what I'm saying: to go from timestamp to seconds use the To Double Precision Float. 

 timestamp_to_seconds.png

 

I never said anything about going from seconds to timestamp. It makes no sense to go from seconds to timestamp and try to wire that into a Build Array.

Message 13 of 19
(2,302 Views)
Solution
Accepted by topic author icemaker

Here is one way to parse the string using relative time. I used an XY chart. The x-axis of the chart is configured for relative time. The format string for the Scan From String function is %<%H:%M>t in case it's hard to tell from the picture. 

 

 

 

Message Edited by smercurio_fc on 09-09-2009 03:53 PM
Message 14 of 19
(2,295 Views)
That looks great. I have one question about it. What is the block that you have before the graph, the one that looks like it makes the waveform by joining the two streams. I cannot find anything similar and have been searching for a while.
0 Kudos
Message 15 of 19
(2,276 Views)
That's an Index and Bundle Cluster Array function. It's in the Cluster & Variant palette.
Message 16 of 19
(2,273 Views)

The one place I did not look! Now it is working. Once last question. I have played with the graph for a while now but cannot get the time to display along the bottom. It only shows the stat time 00:00 and the finish time, but nothing in between. It also goes to 26:00, which is odd but not a big deal because it appears to be laying out the data correctly. Thanks for all the help.

 

graph.JPG

0 Kudos
Message 17 of 19
(2,264 Views)

Change the formatting of you x-axis. You currently have the style set to not show anything between the first and last major ticks.

 

As for it starting at zero, you should check to make sure you're not reading any lines with zeros. I read the file you posted earlier.

Message 18 of 19
(2,257 Views)
Thanks again for all the help sir. Do you think this could be the problem with my axis as well? The axis is not very important at this time and everything else works excellent.
0 Kudos
Message 19 of 19
(2,216 Views)