From Saturday, Nov 23rd 7:00 PM CST - Sunday, Nov 24th 7:45 AM CST, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Saturday, Nov 23rd 7:00 PM CST - Sunday, Nov 24th 7:45 AM CST, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
11-02-2006 08:07 AM
I am unsure what "reflect" means but I modified the code to what I think you mean. The Models array can be outside the while loop. It can be updated inside the loop using a local variable and I use a shift register to keep track of the Models data.
As for parsing the text file. Not as straight forward as I thought so I will look at it when I have more time.
David
11-02-2006 09:18 AM
David,
Thanks. You got me right on that one. And I request you to please get back to me if you can figure out a way to parse the simulation file.
Thanks again.
Have a wonderful day.
Shaun
11-02-2006 10:04 AM
Shaun
I am on leave so I won't be around next week. So here is some homework
Here is my first attempt which kind of works. It runs into trouble when reaches aichan_air_brake_press. Hopefully this will give you some ideas to be getting on with when it comes to working with strings. There might be other bugs that I haven't noticed yet. I have another idea which starts the processing at the end of the file and works backwards chopping off the # text id blocks and processing them seperately so avoid the match pattern getting too far ahead of itself.
I haven't had time to comment the code so it should be nice exercising in using execution highlighting and other debug activities
I will catch up with you when I get back from holiday. Have fun.
David
11-13-2006 11:47 AM
Hi Shaun
How are you getting on with the parsing of your file?
David
11-13-2006 01:40 PM
David,
I couldn't work with the VI you posted in your previous post as I'm using labview 8.0 and your example was in 8.2. So, could you kindly post that parsing example in 8.0..? Hope you had a nice vacation.
Is it possilbe to get an array of boolean to just one value ( like either true or false)..?. I want to wire this single boolen output to the select structure.
Thank you
Have a Great Day
11-13-2006 02:15 PM
11-15-2006 01:38 PM
11-15-2006 03:22 PM
Hi Shaun
Good show, you will be looking forward to your holiday. Take a rest from all this labview you are doing
I have attached another version with the "channel" added. Compare this to the previous version and you will see its a pretty easy mod. I have commented the block diagram outlining the changes.
Well, you are going to have to run your other question by me again. You have supplied a vi that scans a string for tokens creating a 1D array and text file with some data in it. I am assuming you want some help to extract some data from this file but you haven't said what.
David
11-15-2006 05:21 PM
Hi David,
Sorry for the unclarity in my question. I should have read the message again before posting it. Thats what happens when you are multitasking..!
Ok, In the txt file attachment that I sent, all the controllers on the left side reside in an 1D array. Each element in this array (controller array) must be parsed in to different sections or columns ( control, plot, type, bit, CH). Since each element happens to be space delimited, I was making use of the "Sdlmtd to array" vi ( with the input being a 1D string through a for loop) for parsing into sections.
With some modifications to it, it is parsing but not in the required format given in the txt file. So I wanted to know the right modifications or an effective sample code that parses the 1D array elements(controllers) in the required format.
Thanks again
Have a Nice Evening..!
Shaun
11-16-2006 03:04 AM
This demonstates using Spreadsheet String to Array using a SPACE at the delimeter. The parsing is controlled by the Controller type.
David