LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Extract/Scan for numbers from multiple lines of strings

Solved!
Go to solution

Attached here is the VI in LV 2012 ! 

0 Kudos
Message 11 of 16
(1,145 Views)

The data acquired will be kept refreshing :

 

$#pressure 12
!@temperature 99
#voltage 1.4

 

$#pressure 13
!@temperature 100
#voltage 1.2

 

$#pressure 12
!@temperature 99
#voltage 1.4

 

and so on....

0 Kudos
Message 12 of 16
(1,138 Views)
Solution
Accepted by topic author pokerprof

OK, this will do it:

 

original.png

 

You just need to use \n\n (two newlines) as your stop string/start new string point.

 

Cameron

 

To err is human, but to really foul it up requires a computer.
The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
Profanity is the one language all programmers know best.
An expert is someone who has made all the possible mistakes.

To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):

LabVIEW Unit 1 - Getting Started</ a>
Learn to Use LabVIEW with MyDAQ</ a>
Message 13 of 16
(1,133 Views)

@pokerprof wrote:

The data acquired will be kept refreshing :

use a shift register to store your values......

0 Kudos
Message 14 of 16
(1,121 Views)

Or, if the frequency of updates is slow enough, you could just throw the array (single data point) directly into a spreadsheet (CSV) file after it's generated. Wouldn't even have to take the step to convert strings to numbers (see my last post here) first if you don't need them for something else.

 

(Sure, it's not as efficient as putting them in as a single array, but I'm talking about if you have all the time in the world (10 msec ?) between each data point. And it's safer if there is a chance your PC or program will die before the run is finished, you'll at least have the data to that point stored.)

 

Cameron

 

 

 

To err is human, but to really foul it up requires a computer.
The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
Profanity is the one language all programmers know best.
An expert is someone who has made all the possible mistakes.

To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):

LabVIEW Unit 1 - Getting Started</ a>
Learn to Use LabVIEW with MyDAQ</ a>
0 Kudos
Message 15 of 16
(1,117 Views)

Hi guys,

 

Here is the final block diagram that I've came up with. Modified from cameron's and also included shift register so that new data can be appended to the array.

 

Thank you for your help guys ! 

 

Cheers.

Royal Flush

0 Kudos
Message 16 of 16
(1,091 Views)