03-12-2010 09:08 AM
Ray.R wrote: I'm sure some delay value should be wired to the input.
And even a dely of 0ms has an effect. It causes the thread to release so the CPU looks for other actions to take
03-12-2010 09:34 AM
Ray.R wrote:Not sure what the intent of the code is or why the TRUE constant Boolean. There's no need for the Exclusive OR when using a TRUE constant.
Let's not mention the fact that the loop may run once or forever depending on the initial value for sensor. I always use Express VI's, I'm lovin it. They have increased my Labview skills by several magnitudes
The Boolean gymnastic were perhaps somewhat strange. But the user have set the time delay inside the Express VI to 4 seconds. With Express VIs you click to configure. The Rube code in this was the Express VI it self. All Express VIs are Rube code. And should therefore be deleted
03-12-2010 09:58 AM
I have to agree with you Coq. (or is that M. Rouge?)
Just goes to show how little I've used Express VI's. I think I tried it once and that VI died of loneliness..
I know I'm not the only one in this situation because 2 or 3 years ago, the Champions lost during NI week because they didn't know much about Express VI's. LOL!
(did they loose? Can't remember... but they didn't know Express VI answers) 😉
03-12-2010 10:18 AM
Ray.R wrote:
I know I'm not the only one in this situation because 2 or 3 years ago, the Champions lost during NI week because they didn't know much about Express VI's. LOL!
(did they loose? Can't remember... but they didn't know Express VI answers) 😉
Is it anything to know about them, beside how to delete them. Did the Champions not know that?
03-12-2010 10:29 AM
Coq Rouge a écrit:
Is it anything to know about them, beside how to delete them. Did the Champions not know that?
May be how to remove them from the functions palette ?
03-12-2010 11:33 AM
I was taken down a peg this morning as my potential solution lost out to some RG code. Spotted here. (I shrank a little for snipping purposes)
Well the snippet is allergic to locals. The property node is a local to set the array to all false in case the first iteration is too slow. If we vote for the idea to hide the iteration terminal it could help, no use for that in this VI . Six case structures contain individual boolean array constants. The OP wanted 10 LEDs, perhaps the author figured we got the idea with only 5 in this example (the idea perhaps that there must be a better way).
03-12-2010 11:49 AM
Does Andy work for NI? He has the blue rectangle...
03-12-2010 12:09 PM
Ray.R wrote:Does Andy work for NI? He has the blue rectangle...
That exact thought passed through my mind, I think that is what made me go from taking a double-take at the code to a triple-take. My guess is marketing or upper management.
Certainly not tech support, they really saved my bacon this week so they are spared from all snide comments.
Actually, I have very vague recollections of reading a post once that mentioned that email address that start with '@ni' trigger the blue bars regardless of what completes the address. Maybe that is still true.
04-06-2010 04:53 PM
I found some very nice little Rubes today, here...
First of all, anyone want to guess why we're taking a 1D array (the output of DAQmx Read, N chan N samp, 1D waveform) and resizing it to a....1D array???
Then, we decide we'd better turn it into a cluster, then unbundle it...
...then we take all of our separate data arrays and format them into strings...
...then concatenate the strings.
Now let's look at that case structure. It's the ever popular use-a-boolean-to-select-the-same-boolean-value-contained-in-the-original-wire trick! The "true" case does the same thing, but uses a different number for the "greater or equal" comparison.
Now, we could have written it like this:
But that isn't very much fun.
We also could, perhaps, have used the "2D DBL" instance of DAQmx Read, and skipped all the get-the-data-arrays-out-of-the-waveforms operations, but it looks like he uses at least one of those waveforms for something else so maybe he does need them.
04-06-2010 09:26 PM - edited 04-06-2010 09:28 PM