04-27-2010 07:00 AM
That's the idea..
See how great minds think alike.. It is possible to make a Global WORM, call it a CONSTant.
<punt ON>
Would it be referred to as "Global WORMing?"
<punt OFF>
04-27-2010 07:33 AM
Isn't this kind of easy to do with LVOOP?
A write function which allows only a single execution, otherwise returning an error?
Shane
04-27-2010 07:49 AM
Intaris wrote:Isn't this kind of easy to do with LVOOP?
A write function which allows only a single execution, otherwise returning an error?
Shane
I don't remeber which thread I posted this image too but YES!
Ben
04-27-2010 09:08 AM
Time for a Nugget guys....
04-27-2010 09:23 AM
Ray.R wrote:Time for a Nugget guys....
Owww!
Are you writing one?
BTW: Shared Variables have a single writer option.
Ben
04-27-2010 10:31 AM
Although I like the LVOOP idea, Globals as they are satisfy my need for constants, so I won't go through the trouble of creating a WORM Globabl using LVOOP. Well I might one day when I have some time on my hands (like next week). For me its OK the way it is because I am keenly aware of the troubles of misusing Globals. I have disciplined myself to never write to a Global in a block diagram.
But I like the idea of a WORM Global because I would be able to load the Globals from an ini file at the beginning of each program. This would really be a great feature.
04-27-2010 10:31 AM
Ben wrote:
BTW: Shared Variables have a single writer option.
Then that's the way to go if you want to do this.
BTW. How about a new feature where Local and Global variables can not be placed on the block diagram until you have two years of LabVIEW experience?
04-27-2010 10:41 AM
Broken Arrow wrote:
Ben wrote:
BTW: Shared Variables have a single writer option.
Then that's the way to go if you want to do this.
BTW. How about a new feature where Local and Global variables can not be placed on the block diagram until you have two years of LabVIEW experience?
![]()
There was an early version of LV where NI tried a "just in time help" function that was borderline as anoying as Clippy from MS.
I think that there should be a EULA associated with every instance of a write global that we have to agree to and Ni keeps on file.
Ben
04-29-2010 04:41 AM
I like these WORM globals. Two implementations come into my mind.
* LV2Global with the First Call prim to load the values from a ini file
* Using a SEQ with an enqueue as write (with timeout 0) but a preview for read
But I must confess, that I really do use those evil globals to pass data around. It's duct tape I use to fix things in the field. And I am very happy if I have the time back home and remove them again...
Felix
04-29-2010 05:28 AM