10-11-2011 02:40 AM
hi there friends...
I want to plot my data at real time..
Baud rate is 57600..
Hyperterminal data is in the format like
212 121
43 24
186 144
34 53
means column 1 for my ADC channel 1 and column 2 for ADC channel 2
I have tried another software but since baudrate is high, data captured by hyperterminal is too fast therefore cant plot real time..
So please could you people guide me that is this possible through Labview..
I hope really good from this software...
thank You guys...
10-12-2011 10:45 AM
Hi C3,
It should be possible assuming your CPU is fast enough. With a Baud rate of 57600 if my calculations are correct it looks like you will need to take a sample every ~17.36us which should be easily achievable using modern processors. Using the "Wait Until Next ms Multiple" function you should be able to control the timing of each iteration of a while loop. I am not familiar with Hyperterminal, but it appears to be using a serial interface. If you are using this setup there are VISA serial communication VIs available within Labview that can be used to access serial data. The connection must be set up an then the data can be read from the port. There are several serial examples available in the example finder which should give you a good starting point. After the data is read each iteration it can be plotted using the Waveform Chart.
10-14-2011 09:17 AM
hi thank you for the reply..
I have started with the basic serial read and wite example..
I am getting data from COMM port in this format..
134 0
132 0
131 0
because I have some voltages on Ch0 of ADC and 0 voltages on ch1 of ADC...
Now the data is in string format ..
Using Decimal string to Number and then futher passing it from (DBL) double precison float I connected the wire with waveform chart this is merging my both columns means plotting at 134 then 0 and so on,,
Now the problm is that I want to plot 1st columnn seprately as a channel and 2nd column seprately as a channel could you please guide me how to do that in labview...
In another software I have done this using reshape/resize array..
Thank you...
10-14-2011 11:40 AM
Hey C3,
I set up a little example for you that I think should accomplish the task at hand. It splits that string and then plots it as 2 separate plots on a Waveform Graph.
10-14-2011 11:46 AM
Try:
Transpose an 2D Array
Programming>Array>transpose 2D
@C3-C4 wrote:
hi thank you for the reply..
I have started with the basic serial read and wite example..
I am getting data from COMM port in this format..
134 0
132 0
131 0
because I have some voltages on Ch0 of ADC and 0 voltages on ch1 of ADC...
Now the data is in string format ..
Using Decimal string to Number and then futher passing it from (DBL) double precison float I connected the wire with waveform chart this is merging my both columns means plotting at 134 then 0 and so on,,
Now the problm is that I want to plot 1st columnn seprately as a channel and 2nd column seprately as a channel could you please guide me how to do that in labview...
In another software I have done this using reshape/resize array..
Thank you...
array.
10-15-2011 02:36 AM
hi Justin and Mark..
I am going to implement this...
Thank you for the help...
10-15-2011 03:41 AM - edited 10-15-2011 03:41 AM
Hey Justin which block do you use after Decimal String to Number blocks..?
10-15-2011 05:02 PM
Okay I got it 🙂 but there is one problem that my serial data coming from port is string but in your example you have 1D array of string ..
It means I have to convert my serial string data into 1D array of string data Am I rite...?
10-15-2011 05:18 PM
I think Justin was assuming that each string you read from the serial port contains the two data values separated by a space character. Then the loop which contains the Read function has an autoindexing output so that the array of strings is generated automatically.
If you are doing it differently or need to interpret the data while the Reads are continuing, you will need to use parallel loops and a queue or functional global VI to transfer the data.
Show us what you have tried.
Lynn
10-17-2011 07:11 AM
Hi, Thank you Guys 🙂
Specially Justin 🙂
Okay now I am getting data of my two columns serialand plotting on wave form graph , problem is that I want to move my x axis means my data is compressing on the same window of waveform graph which i dont want so how to move x axis (updating) that data should not compressed on the same window... ?
Thank you.........!