BreakPoint

取消
显示结果 
搜索替代 
您的意思是: 

Rube Goldberg Code


@altenbach wrote:

 

Edit: Yes, I was right. Just checked my LabVIEW 4.0 installation and it does not have the insert/delete function in the array palette.


Any idea when these functions were introduced?

- Partha ( CLD until Oct 2027 🙂 )
0 项奖励
1591 条消息(共 2,638 条)
13,436 次查看

@crossrulz wrote:

Don't look so surprised.  He also has a copy of LabVIEW 3.


 Haha, ofcourse he does. I should have seen that coming. 🙂

/Y

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 项奖励
1592 条消息(共 2,638 条)
13,409 次查看

@Yamaeda wrote:

@crossrulz wrote:

Don't look so surprised.  He also has a copy of LabVIEW 3.


 Haha, ofcourse he does. I should have seen that coming. 🙂

/Y


No, that's only a demo (See here. Fully functional in windows XP mode, but cannot save anything).

 

 

 

 

OTOH, LabVIEW 4.0 is still installed on the same computer where I learned LabVIEW (Windows 95, Pentium 1). PC is running 24/7 (for almost 20 years!) controlling an instrument via an ISA card AT-MIO-16E-1.

 


@parthabe wrote:
Any idea when these functions were introduced?

 

I wish I remember. Maybe 6.0? (I think that was the first beta I participated). 😄 All upgrade notes are available somewhere, so it would be a matter of looking through them to see what's mentioned about array functions. (Use google to search for specific upgrade notes, the NI search is useless for this :()

 

(I remember that I did not really like some of the unwired behavior, because it was not in line with the typical definitions (e.g. typically an unwired index means element 0, but for "delete from array", it means the last element of the array. This is of course useful but also somewhat confusing.))

 

1593 条消息(共 2,638 条)
13,371 次查看

altenbach wrote:

No, that's only a demo (See here. Fully functional in windows XP mode, but cannot save anything).


My copy came with the upgrade suite.  Have not played with it enough to try anything.  But the lack of the autotool is really annoying.



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 项奖励
1594 条消息(共 2,638 条)
13,367 次查看

@parthabe wrote:
Any idea when these functions were introduced?

Yes, my memory was correct. These functions got introduced in LabVIEW 6i.

 

Looking at the LabVIEW 6i upgrade notes, we find the following statement.

 

Array Function Enhancements

"LabVIEW includes three new functions for manipulating arrays — the Replace Array Subset, Insert Into Array, and Delete From Array functions, available in the Functions»Arrays palette ..."

 

 

0 项奖励
1595 条消息(共 2,638 条)
13,348 次查看
Thank God! I started my career with 6i ! 🙂 Can't imagine life without those 3 array muskateers.

 

- Partha ( CLD until Oct 2027 🙂 )
1596 条消息(共 2,638 条)
13,322 次查看

We haven't seen that kind of useless boolean gymnastics in a while. but look at the code posted here.

 

Here are a few parts in no particular oder. 😄

 

 

 

Lete's look at the middle and bottom case:

  1. If the boolean is true, we go to the true case
  2. in the true case we compare it with TRUE, just to be sure
  3. If it is really true, we abort the VI, so why does it even matter what we wire to the stop condition?
  4. If the boolean is false, we go to the FALSE case.
  5. In the FALSE case, we compare it to FALSE, just to be sure
  6. Since the comparison is guaranteed to returne TRUE, we need to invert in order to not to stop the loop

We would get exactly the same functionality by wiring the control directy to the stop condition (and potentially branch the wire to the abort primitive, but that sounds a bit clumsy ;)) No case structure or boolean gymnastics needed. 😮

0 项奖励
1597 条消息(共 2,638 条)
13,140 次查看

(seen here)

 

How would you change a scalar to an array with one element?

 

Well, "built array" resized to one input would come to mind.....

 

......but wouldn't it be so much better to use a "ptbypt data queue" configured for a queue size of one element?

Well, yes, at least if we are getting paid by the size and complexity of the code! 😄

 

0 项奖励
1598 条消息(共 2,638 条)
13,033 次查看

@altenbach wrote:

 

"ptbypt data queue"


I didn't even know that node existed.

0 项奖励
1599 条消息(共 2,638 条)
13,003 次查看

@Hornless.Rhino wrote:

@altenbach wrote:

 

"ptbypt data queue"


I didn't even know that node existed.


Just to give it some credibility.  My hideous self embarassment yesterday was due to the use of that node.  (As an nZ-Transform)  Delay / dT = n samples in the queue

 

Dont leave dT = 0 you don't have enough memory, trust me ok? 


"Should be" isn't "Is" -Jay
0 项奖励
1600 条消息(共 2,638 条)
12,916 次查看