LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Display Chart/Graph of ascii numerical data?

I am reading an ascii serial numerical input, and I need to display that data (numbers corresponding to a voltage) on a chart.. If I connect the "Data from port", which displays OK when running (4 digits of data ####) to any type of a chart or graph, LV tells me wrong kind of data. Surely this has to be easy to do, so what am I missing here!
Thanks in advance!! Newbie here!
0 Kudos
Message 1 of 3
(3,156 Views)
Convert the text to numeric. There are a number of conversion functions in the conversion subpalette of the text palette.

Also, get yourself a copy of "LabVIEW for Everyone" and/or take LabVIEW Basics I and II (or get the course CDs). These are the best and easiest way to learn LabVIEW. Also, don't forget about the examples that shipped with LabVIEW. They are probably the best way to learn thigs like this in LabVIEW.
0 Kudos
Message 2 of 3
(3,156 Views)
DaveF wrote in message news:<50650000000800000089510000-1023576873000@exchange.ni.com>...
> I am reading an ascii serial numerical input, and I need to display
> that data (numbers corresponding to a voltage) on a chart.. If I
> connect the "Data from port", which displays OK when running (4 digits
> of data ####) to any type of a chart or graph, LV tells me wrong kind
> of data. Surely this has to be easy to do, so what am I missing here!
> Thanks in advance!! Newbie here!

Hi Dave,
which .vi are you using that contains the "Data from port" output
terminal?
I'm guessing here, that your display FPTerm is pink - as in the data
it is displaying is text - you say it's ascii serial data, which would
normally be text. If so, you need to convert it to an ac
tual number,
rather than its text representation. (I could be wrong here, so please
correct if necessary).
Have a look at the strings functions sub palette. On there you'll find
a few sub .vi's designed for this purpose within the string/number
conversion sub palette. If it's just 4 digits, you can probably get
away with Decimal String to Number. With this number, you can wire it
onto a chart to add a point.
If you want to use a graph, it expects all the data at once, so you'd
have to build up an array of data to pass to it. I think the chart
seems to be what you're after.

Hope that helps

S.
Message 3 of 3
(3,156 Views)