12-31-2013 11:36 AM
How about a little Match Pattern (regex)-containing VI like this one. It doesn't have your "1616 0110 0177" at the beginning of every output string, but you could fix that easily. Just make sure that you have your regex and indicators written in hex form or it'll assume it's ASCII.
Note: Same old browser malfunction - had to change extension from vi to vix to upload.
Cameron
12-31-2013 11:53 AM
Funny, looking at it a bit further, I get 376 bytes in each string (see modified VI attached).
Cameron
12-31-2013 11:55 AM - edited 12-31-2013 12:17 PM
@gEEkPockets wrote:
I have attached the A.xyz & B.xyz which will need to have their extensions changed to .bin to work with the vi.
Why? Your VI (scrub.vi) does not care about extensions. It would work equally well with *.xyz.
Where is "the vi"? Please be more specific!
Looking at "scrub.vi" that you posted earlier, there are a few things quite questionable.
01-01-2014 05:29 AM
Ugh - I have 2011 so I can't open your vi.
01-01-2014 06:00 AM
Altenbach,
Answers to your questions are mainly because I am a newbie. I did fix the reading only 12.5% of file. Thank you.
I hardcoded the paths because I had scrubbed certain things out that I didn't want uploaded so hardcoding the files and paths seemed the easiest fix there.
I fixed the error handler at the beginning.
I had a lot of indicators I was using for debugging purposes (like the refnum things to indicators).
Ya - you're right about the .xyz thing. I sort of got tunnel vision after I started working on this, and overlooked those things. I will post my lastest vi tomorrow so I can ask some questions. Thanks
01-02-2014 08:00 AM
@gEEkPockets wrote:
Ugh - I have 2011 so I can't open your vi.
Mine? You don't say...
But if so, here it is in LV11.
Cameron
01-18-2014 01:04 AM
Thanks for all the help. I forgot to update. I figured it out. I ended up writing a state machine and masking off data and shifting and masking off again until I found what I was looking for (x16x16) - then writing it out the way I wanted it to look. I couldn't really post the exact .vi and data for work reasons - and it's too hard to work on "scrubbing" my actual vi to post on the forum. I learned a lot as this was my first labview coding, so I may be using it more. Kudos to all of you.
01-18-2014 01:06 AM - edited 01-18-2014 01:09 AM
ShisKeBobby: I wish I had seen your post. The format is in my opinion, a misapplication of what was intended, but I figured it out. Thanks!
01-18-2014 06:06 AM
Glad you got it to work. After checking through your posts, i'd probably do a Read from spreadsheet file as U8's, and convert those to boolean arrays, thus you'll have a very long boolean array with all data serialized. Then it should be easy to extract 6 bits at a time until you find your x16 to get the starting point. After that, by extracting groups of 8 you'll automatically get the data back and bit shifted.
How did you solve it?
/Y
01-18-2014 10:13 AM
I forgot that I actually did create the code I talked about back then, just to make sure, and I still have the file. This example shows that the B file is 5 bits out of alignment and that the sequence starts at byte 221: