08-03-2009 04:30 AM
Hello guys. I'm making a control program to work as one oven control temperarute...my question is: how can i make a plot of several time dependent variables vs time ? i believe i have to create a timestamp but i dont know how.....i have a second problem that is :my Vi is a mess(its a lot of confuse)because i have wires conected instead of variables, and dont know how to substitute all those wires by local/global variables...
many thanks
JOSE
08-03-2009 06:27 AM
If you are using a DAQmx Read, then one of the options is to get a waveform data type which includes a timestamp. Otherwise, you have the functions on the timing palette. If you have a problem, you should post your code.
Never, ever replace wires with local or global variables just because you want to clean up your diagram. You will almost certainly break the program because of race conditions. Use the 'Clean Up Diagra' option on the edit menu.
08-03-2009 08:47 AM
thanks for your prompt anwser....I am using the DAQmx read but cant see were to get the waveform data type ? also tried to find the 'Clean Up Diagram' on the edit menu but there isnt any there 😞 i'm using labview v8.5 can this be because i have one old version?
thanks again
JOSE
08-03-2009 09:05 AM
Ok...i believe i understood...i have to pick up one Build Waveform (Analog Waveform Vi)...is it?
thank you
08-03-2009 09:11 AM - edited 08-03-2009 09:12 AM
On the DAQmx Read, right click choose Select Type>Analog> Single Channel/Multiple Channels>Single Sample/Multiple Sample and you can select a waveform data type.
The block diagram cleanup was introduced with 8.6.
Using the Build Waveform is only correct if you use one of the time functions to create a timestamp and add it to the cluster.
08-03-2009 11:18 AM
Sorry to disturb again...but now i have another problem...after i had selected the waveform option (from the DAQmx Read Vi), i conected the waveform output of the DAQmx Read Vi to one Waveform Graph Vi , but it hapens that when i run it, there is nothing on the graph....and when i go to the graph table , there is only one line at the table.....all the values of my Y variable are beying displayed (on the table) for the same value of the time(X variable)...
how can i solve this?
thanks again
JOSE
08-03-2009 11:27 AM
08-03-2009 11:38 AM
Thanks for help. Here is my code. Please try not to laft because of all the wires .....My problem is on the top left of the diagram on the waveform graph conected to the DAQmx Read vi
thank you again
08-03-2009 01:57 PM
You have the DAQmx Read set for a single point read and you are wiring the data to a graph. A graph is designed for multiple points and each time the read is called, the data is cleared and a new single point is written. For single point reads, you would want to use a chart.
I see other potential problems. You should connect some of the error in/error out clusters to control data flow. As it stands, those different DAQmx Reads will execute in a random order.
08-03-2009 03:15 PM
What i was trying to do was a graph of those single values Vs time but with real time(i mean the graph values are actualized/ploted every loop time)....I've tried several ways but dont know what did wrong...If you could give me some ideas of how to do that ....
thank you once again
JOSE