Re: Generic UI question

2004-06-22 Thread Paul F. Sullivan
Xavier,
You wrote:
...I have tried to update my LV Vi design style to keep up with the new
functionalities like User Event Handling...
I have a main Vi (call it TopLevel.vi) that dynamically launches subVis
on user demand (call them subViN.vi, N=1,2, etc). The user plays with
the subVi, and one action requires the main Vi to be updated somehow ...
I thought initially that the dynamic event registration feature would
help me do this in a more elegant way, but I can't figure out how, so
maybe I am just wrong. What I would need is some sort of event
registration in the TopLevel.vi that would be fired in the subVis. But
since the subVis are not started until possibly very late in the
execution process, this cannot be done at launch time in the
TopLevel.vi...
Can't you create and register a user event (or multiple user events) 
in the main VI and pass the appropriate user event reference to each 
subVI as it is launched? Each subVI then generates the appropriate 
user event at the appropriate time and the event structure in the 
main VI responds.

--
EnWirementally,
        Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




RE: [M] Val(Sgnl) Works in 7.1 but not in 7.0

2004-06-21 Thread Paul F. Sullivan
At 11:18 AM -0400 6/21/04, Heverly, Bryan C. (Newport News) wrote:
What type of a control are you pulling the value signaling property off of?
If it is a Boolean, I have found that the latching (bottom row) of
mechanical actions will change the data type of the property node to be a
variant.  I have yet to get this to work.
and
At 8:41 AM -0700 6/21/04, PJ M wrote:
Value signaling does not work on type def (strict or
not) control in 7.0 (This is a bug). NI might have
fixed this in 7.1 (I have not tried it yet).
My control is a Boolean, but not of the latching variety. It is in a 
(strict) type def control. Disconnecting it from the type def makes 
it work fine in 7.0, so that is the problem. And, yes, it is fixed in 
7.1.

Thanks for the help. It's good to know I'm not stupid or crazy (at 
least, not for this reason)!

--
EnWirementally,
        Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




[M] Val(Sgnl) Works in 7.1 but not in 7.0

2004-06-21 Thread Paul F. Sullivan
LabVIEWers,
My first attempt at using Val(Sgnl) to cause an event didn't work in 
a somewhat unusual VI-subVI arrangement. Simplifying the arrangement 
to a simple, single VI configuration still didn't work even though I 
could see anything wrong. My 7.1 disks had arrived (a week or two 
ago) but not yet been installed. I didn't expect it to help but, just 
in case, I installed 7.1, copied the simple and then the complex VIs, 
and they all ran fine.

Does Val(Sgnl) not work under OS X? Is there some setting I might 
have wrong under 7.0? (7.1 seems to have copied all my 7.0 settings, 
though.)

--
EnWirementally,
    Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




Re: Wanted: #define

2004-06-16 Thread Paul F. Sullivan
George,
You wrote:
 From my days as a C programmer (shudder) I have to say I do miss the
#define...
It seems to me that there was a discussion of #define here a couple 
of years ago, but I find nothing in my snippets collection. Maybe 
SearchVIEW will find it for you.

and in another posting:
...These are not values that the
user would ever want to mess with... things that are currently just
constants scattered around the application, like the string for the title
bar or the number of times to try doing some low level operation before
giving up.  Stuff that will probably never change, but is easily forgotten
about and lost in the pile of vis.  Back in the days of C it was extremely
rare to find a constant in my code... all that stuff just got #defined and
moved to the tops of the files... and that is sort of what I am hoping for
here...
This "remove all constants from your code" is one of the practices 
advocated by Conway and Watts in "A Software Engineering Approach to 
LabVIEW", so you are certainly not alone. They use config files. 
Maybe you could put the data the user might change in a standard 
config file and the immutable stuff in the encrypted file that Conway 
and Watts describe, or at least have them in different files.

Im probably to lazy to do anything about it in the app I am working on
right now... just something I am thinking about for the next time around.
John Brohan's package would let you be lazy and still get your result.
--
    EnWirementally,
Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




Re: Fw: Keystrokes

2004-06-15 Thread Paul F. Sullivan
Nuno asked:
... any help on sending keystrokes to other application?
I'm attaching (private email only) my collection of snippets from 
this forum about capturing and forwarding keystrokes.

--
    Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




RE: Bird's Eye View 1.5.0 Available

2004-06-10 Thread Paul F. Sullivan
Stephen,
You wrote:
The thing that I find most encouraging about the dual development of this
same feature by OpenG and by NI is the fact that OpenG was able to develop
it at all... Have any of you used the sizing dialog from LV7.0?
Yes, and I had previously developed the same functionality in LV6 for 
the Edit Panel Elements OpenG project (ongoing). A working version of 
the Edit Panel Elements package has long been available from my web 
site. (Of course, I couldn't make a tool button for it.)

--
EnWirementally,
    Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




Re: Labview date and time to Julian and seconds after midnight gmt

2004-06-10 Thread Paul F. Sullivan
Arsineh,
You asked:
...does anyone has a vi that changes the time stamp to seconds after 
midnight of
current day GMT?
Back in Y2k, Will Maynard posted:
Subject: Re: [A] time and time zones, take 2
From: "Will Maynard" <[EMAIL PROTECTED]>
Date: Thu, 24 Feb 2000 09:17:14 -0500
At 1:56 PM -0700 2/23/2000, McLaughlin, Scott wrote:
 >...why isn't there an
 >option or a function that gives me the option of using the UTC time as the
 >timebase/epoch?...
I modified a vi to do just that a while back. Check it out from the
info-labview ftp site:
ftp://labview.pica.army.mil/pub/labview/vi/lv4/y2k_plus.zip
It will return you the current time in either the local time zone,
UTC, or Julian Date. (Check out the sub vi, GMT Delta.vi (by Stepan
Rhia), to see how to get the local time zone offset from UTC.)
Will Maynardemail:[EMAIL PROTECTED]
Code 554FAX:  (301)286-1750
Goddard Space Flight Center Phone:(301)286-5626
Greenbelt, MD  20771
I haven't tried it, but from the descriptions it looks like the 
combination of Will's and Stepan's packages may do what you want. I'm 
also including (private email only) my entire collection of time zone 
snippets from this forum (from which I retrieved the above) in case 
there are other hints there of use to you.

--
EnWirementally,
Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




Re: Main VI and sub-vi's control

2004-06-04 Thread Paul F. Sullivan
Ann,
You wrote:
...  In my Main VI, I use get control value
method to set the blinking property of the Main VI's continue button.
This button blinks fine, but when it blinks, I cannot click on it to
change its value, does anyone know why or know of a better way to do
this?
Irene responded:
I think the problem is your subvi hasn't finished running, that's why the
main vi is still waiting it to finish which blocks the user actions.
What you can do is you need to use vi server to run your subvi without
waiting it to finish...
I haven't tried it, but I think another approach would be to use 
parallel while loops, one calling your subVI and one checking the 
main VI's continue button. The second loop should continue to run 
while the first is stalled waiting for the subVI to finish.

Which approach is better depends on the details (including thread 
blocking?) and your comfort level with understanding and following 
the different architectures.

--
    EnWirementally,
Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




RE: restoring defaults to controls

2004-05-30 Thread Paul F. Sullivan
Glenn,
You wrote:
... Too bad there aren't separate properties for references of controls VS
Indicators - that would save some work or a way to determine if it's an
indicator or control.
In LV7, there is a property "Indicator" which does distinguish 
controls from indicators.

--
EnWirementally,
Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




Re: Time zones and time stamps

2004-05-25 Thread Paul F. Sullivan
Gary,
I'm attaching (private email only) my collection of snippets from 
this forum concerning time zone corrections.

--
    Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




Re: Expression node and numeric units

2004-05-22 Thread Paul F. Sullivan
Paul,
You asked:
...when I wired a numeric control with a defined unit (in
this case "m") to an expression node, I get a bad wire connection with the
associated error "You have connected numeric data types that have
incompatible units".  Same problem when I tried with and "formula node".  I
checked the Labview help file but the issue is not addressed.
Is this a fundamental limitation of the expression and formula node or is
there a way to use these primitive with variable with units.
The Convert Unit primitive will convert a number with a defined unit 
to a pure number for use with, e.g., the expression and formula 
nodes. Specifying the unit within the Convert Unit primitive puts the 
decimal in the right place, chooses English or metric units, etc., so 
using "ft" on a wire containing "1 m" will give 3.28084... as the 
output.

--
EnWirementally,
Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




Re: Can I call a labview VI from a batch file?

2004-05-18 Thread Paul F. Sullivan
Scott,
You wrote:
With much frustration, I cannot seem to get my labview vi to run from a
batch file.  Everything appears ok in terms of the directory and
filename but I keep getting a bad filename error message.
Just a guess: Are there embedded spaces that require quotes around 
the file name?

--
EnWirementally,
Paul F. Sullivan

SULLutions  (781)769-6869
"when a single discipline is not enough"
visit http://www.SULLutions.com




RE: Corrupted llibrary due to crash! Any Idea?

2004-05-14 Thread Paul F. Sullivan
Jim,

I agree with Rolf's advice:

... During development don't use LLBs.
On the other hand, they are very helpful in porting projects to other 
platforms. Different operating systems have different sets of 
characters that are illegal in file names. An LLB will allow you to 
move a file that tests a boolean condition (e.g., Run Before?.vi) 
from a Mac to a PC without renaming it. After trying to export files 
with question marks in their names a couple of times, though, you'll 
probably switch to a naming convention more like Has Been Run 
Before.vi.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Graphs placed over indicators causing slow operation.

2004-05-14 Thread Paul F. Sullivan
Dave,

You wrote:

...human cognitive processing is generally believed to be limited to about
7 items...
Curiously, crows have been reported as being able to count up to 
seven! If several hunters enter a blind and a few leave, the crows 
can tell if they've all left and it's safe to fly again, provided no 
more than seven hunters are involved. Maybe we're all bird brains!

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: AW: More then one active Vi with open Front panel?

2004-05-06 Thread Paul F. Sullivan
Gerd,

Severely editing Uwe's response to just:

...put a little wait into the false case...
  I'd suggest using an occurrence
suggests that putting a Wait on Occurrence feeding a single frame 
Sequence Structure containing the subVI
all within the while loop may be the most elegant solution of all.

How many engineers does it take to fix a VI? This thread seems to be 
a very good advertisement for open source programming.

--
EnWirementally,
        Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Parallel Loops (was More then one active Vi with open Front panel?)

2004-05-06 Thread Paul F. Sullivan
Michael,

You wrote:

...I enjoy discussions on methodology and implementation 
techniques... The issue lately is: single loop good, multiple loops 
bad.
Without multiple loops you lose the parallelism that is the hallmark 
of LabVIEW. Why would multiple loops be bad? If it's the block 
diagram real estate taken up by the loop structure, you could hide 
the loops in subVIs.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: NI-VISA Serial

2004-05-06 Thread Paul F. Sullivan
Stanley Kieta asked:

1. Is there an easy way to include VISA with the 
Application Installer so the user only needs to 
run 1 install program?

2. I need the application to automatically find 
the comm ports on each user's PC.  The "VISA 
resource name" control on my front panel lists 
these ports using the "ASRL1::INSTR" format.  Is 
there any way to get the control to list the 
conventional "COM1" notation? I tried copying 
the visaconf.ini into the same directory as the 
executable but that did not work.
From my library of forum snippets, it appears 
that Mihai Costache is the expert in question 1 
with two postings (although Edwin Dickens echoes 
the advice). I'm including only the most recent 
(which seems to be better) here, but you can find 
the other with SearchVIEW if you'd like.

Subject: RE: Communication Error in EXE using serial VISA
From: "Mihai Costache" <[EMAIL PROTECTED]>
Date: Mon, 25 Mar 2002 07:50:56 +1200
...

1. Download visa260runtime.exe from the NI site.
2. While creating your application builder script, include it in your
list of Support files.
3. Go to the Installer Setting tab, tick Create installer check-box,
then click Advanced... button.
4. Tick the Run executable after installation check-box and type
visa260runtime.exe in the Executable field.
The VISA installation will begin straight after your application's
complete installation, or after the LV run-time engine installation, if
you choose to distribute that as well.
Hope this helps,

Mihai Costache
Software Engineer
OSCMAR International Ltd.
PO Box 6008 Wellesley St.
Auckland, NEW ZEALAND
Tel: +64 - 9 - 379 0360 extn. 892
Fax: +64 - 9 - 373 9799
e-mail: [EMAIL PROTECTED]
www.oscmar.com
...
For question 2, Jürg Bögli, Edwin, and Dan Mondrik advise Mihai:

Subject: Re: VISA confusing changes
From: "Jürg Bögli" <[EMAIL PROTECTED]>
Date: Thu, 16 Aug 2001 09:54:18 +0200
Dear Mihai,

You must define an alias for your ports. (COM1 --> VISA alias, ASRL1::INSTR
--> VISA resource name.
If MAX is installed on your machine you can use it to define the VISA alias
of your ports.
If MAX is not installed, you can manually edit the visaconf.ini file to
define the alias for the ports. Assuming you have 2 COM and 1 LPT port type:
Alias0 = "'COM1','ASRL1::INSTR'"
Alias1 = "'COM2','ASRL2::INSTR'"
Alias2 = "'LPT1','ASRL10::INSTR'"
NumAliases = 3
in the [ALIASES] section. The format of a line is:
ALIASx= "'Alias', 'Resource Name'"
NumAliases must be set to the number of aliases.

Unfortunately I don't know if it is possible to hide the LPT port in the
VISA Resource Name I/O control...
Jürg Bögli  R&D en électronique  Sonceboz SA  CH - 2605 Sonceboz
Tél: +41 32 488 11 - 70   Fax: - 00   www:  http://www.sonceboz.com


Subject: RE: VISA confusing changes
From: "Dickens Edwin" <[EMAIL PROTECTED]>
Date: Thu, 16 Aug 2001 07:37:10 -0500
Mihai,

I was just having this same problem with built exe files for customers that
only have the runtime engine installed. I came up with a vi that can find
the visaconf.ini file and edit it with the proper entries so the application
will display Com1, Com2ect. instead of the ASRL1::INSTR. They are much
happier with this than having to edit the file themselves. I've included the
vi in private email.
I've built this into an .exe so all the customer has to do is run it after
installing the runtime engines. As the file sits right now, it sets up
Com1-4 and LPT1. Only the Com ports that actually exist on the machine will
show in the list. If you do not want LPT1 to show in  the list, you'll need
to change LPT1 to a space in the constant in the second for loop. This will
cause a blank space in the list that can still be selected, but at least it
does not say LPT1.
If anybody else is interested in the vi, let me know and I'll send it out in
a few days.
--
Edwin O. Dickens
DISTek Integration, Inc.
On assignment to: John Deere Product Engineering Center
phone: (319) 292-6372
email: [EMAIL PROTECTED]
Lvl 3, Aisle U, MS83A


Subject: Re: VISA confusing changes
From: <[EMAIL PROTECTED]>
Date: Mon, 20 Aug 2001 11:29:03 -0500
Peter, Jurg, et al:

I would like to answer one question from the previous email chain.  The
question was basically, "Is it possible to hide the LPT port in the VISA
Resource Name I/O control?"  The answer is yes.  Run MAX, expand the Ports
section, right-click on LPT1, choose Properties, and uncheck the Enabled
field at the bottom of the dialog.  This will disable it from VISA, and it
should no longer appear in the VISA list of found resources.  It does not
affect the ability of the OS to access the port, so you can still print,
etc.
Dan Mondrik
Senior Software Engineer, NI-VISA
National Instruments


--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: MODBUS

2004-05-06 Thread Paul F. Sullivan
oz,

Khalid's suggestion is a very good one.

I keep files of snippets from this forum on many subjects of personal 
interest and am sending you (private email only) the MODBUS 
collection.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: AW: More then one active Vi with open Front panel?

2004-05-05 Thread Paul F. Sullivan
At 5:10 PM +0200 5/5/04, Gerd Rech wrote:
Couldn't I put the subvi's in a true case and nothing in the false case
within the separate while loops?
Control the case using a local (h, that bad word again) from the
state machine.
A queue, occurrence, or semaphore would avoid the bad word.

--
EnWirementally,
        Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: More then one active Vi with open Front panel?

2004-05-05 Thread Paul F. Sullivan
Gerd,

You asked,

...The main VI is basically a state machine waiting for user clicks to go to
one of the sub VIs, which e.g. displays a xy chart of measurements...
How can I get the main VI to commence working (not waiting for the chart
window to complete and return)?
Michael responded,

You will have to use VI Server to do this...
While Michael's approach will work and is probably preferable, I 
think you might also accomplish the same thing by putting each of 
your selectable subVIs in its own loop parallel to the state machine 
loop. Use the state machine to enable the execution of the 
appropriate subVI for one iteration of the subVI's loop. One loop 
being held up until its subVI closes will not interfere with any 
other loop, including the master state machine's.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: LV serial interface for Automationdirect GS2 drives?

2004-05-04 Thread Paul F. Sullivan
Michael,

You wrote:

...Unfortunately, MODBUS is one of those acronyms I have always read over
quickly with out comprehending.  Any advise or snippets will be
appreciated.
I am attaching (private email only) my collection of MODBUS snippets 
from this forum.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: caps-lock

2004-04-24 Thread Paul F. Sullivan
David,

You asked:

...Does anyone ever use the caps-lock key?
Yes, it is very useful for entering registration codes with 
hunt-and-peck typing.

Is there some way to disable
it other than hot-glue underneath, or electric shock to train myself
out of hitting it?
My wife was trained as a secretary on a real typewriter. My kids grew 
up on computer keyboards. On the Atari 800, the "Atari" key replaced 
the inner third of the right hand "shift" key. My wife would hit the 
Atari key when reaching for the shift, doing something as innocuous 
as deleting the entire 10 page report she was typing. I drilled a 
small hole in the key cap flush with the keyboard housing. When my 
wife used the computer, she slipped a small dressmakers' pin into the 
hole, disabling the key and giving her tactile feedback that it was 
disabled. She removed the pin when she was finished, allowing us 
techies access to the full power of the keyboard. Worked like a charm!

--
    EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Reading sub-VI paths

2004-04-15 Thread Paul F. Sullivan
At 3:16 PM +0100 4/14/04, Craig Graham wrote:
...When looking at things that I've downloaded or have been sent 
through email,
I sometimes get a dialog popping up warning me that certain files were
loaded from a different path than they were expected to be at. I've never
bothered looking into it but it seems ideal for this purpose. Anyone know
under what conditions it appears?
The dialog is new in LabVIEW 7 and appears anytime something is found 
in an unexpected place.

--
EnWirementally,
        Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: Consut in spanish.

2004-04-14 Thread Paul F. Sullivan
Diego wrote that Daniel wrote:

I am writing a program in which access to different screens through
different options. The screen change is done through state-machines, closing
the origin VI and opening the VI at which I enter. The problem ins on the
screen changes, there is an intermediate state of flickering and many times
it is visible in the Windows desktop.
 The question is: How it is possible to eliminate such flickering? In
another words, Is it possible that the origin VI stays visible until the
arrival Vi finishes opening itself?
In your case, since a master program opens the new VI and closes the 
old one, the simplest fix would be for the master to open the new VI 
first, wait until its panel is open (checked using VI server), and 
then close the original VI.

If there were no master program running, the same thing could be 
accomplished by having the original pass a reference to the second VI 
or have the second derive a reference to its caller and setting the 
second to close the original once it is fully open itself.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Reading sub-VI paths

2004-04-14 Thread Paul F. Sullivan
Andreas,

You wrote:

...I'm very curious but can't figure out a way to see what copy of 
"Out Port.vi" was loaded the last time my top VI was saved, since 
both copies I know of, seem to generate a change (*) in my top VI.

So, I'm wondering if there is a way to look inside a VI and see the 
subVI paths. Not the paths in which the subVIs are found when 
loaded, but the paths that are stored in the top VI when saving to 
disk.
While LabVIEW is looking for a subVI, it displays the path where it 
expected to find it. On slower computers, one could abort the search 
before a substitute was found and read the expected location. With 
the increases in computer speed, you'll have to temporarily move or 
rename all the "Out Port" VIs so that the computer searches long 
enough for you to abort the search or gives up and shows you the file 
open dialog. Move the dialog box, if necessary, and you should see 
the path where LabVIEW expected to find the subVI.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: SubVI Connection Description is the Caption?

2004-04-13 Thread Paul F. Sullivan
LabVIEWers,

I wrote:

...Before LV6.1, even setting an
already invisible caption to be invisible (no change) would move the
label.
Actually, just reading the caption visible property is enough to 
cause the label to move to the alternate position when the panel is 
redrawn.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: SubVI Connection Description is the Caption?

2004-04-09 Thread Paul F. Sullivan
Craig,

You wrote:

...It's caught me out before that (using the default positioning) if you
display both, then the label appears in its normal place and the caption to
the left, but if you display only the caption then it moves to the place
vacated by the label.
I find that it is the the label that moves to the left when you 
display the caption as well. Before LV7, this happened even if the 
label was not visible to start with. Before LV6.1, even setting an 
already invisible caption to be invisible (no change) would move the 
label. This caused some problems with my Resize utility.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: OpenG Coding Challenge - Remove Backspace

2004-04-08 Thread Paul F. Sullivan
Paul Brown wrote:

The best way to estimate your speed is to run both the example and your vi
on your machine.  Multiply the ratio of these by the speed of the example
on the official machine (1008.6 ms).  This should give you a decent
prediction of your official time, despite the differences in hardware.
"It ain't necessarily so." [Be thankful you can't hear my singing!]

My entry is 10% slower under LV7 and OS X than under LV6 and OS 9, 
but the original example slows down 2.5X with the same change in 
environment. Not all types of code scale the same.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Large Fonts Part 2

2004-03-30 Thread Paul F. Sullivan
Jim,

You wrote:

...In our application, we found that if the 'Large Fonts' setting is ON in
Windows; the Active X controls and the NI 'Application Fonts' are
rescaled... 

- Make sure that every text font is set explicitly to an actual font.
(We use 14 Verdana)  Don't use the 'Application Font' or 'System Font'
selections.  These fonts will be rescaled.
On the other hand, explicitly sized fonts will change wildly in 
moving between platforms (not an issue if you're using ActiveX).

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: more suggestions for list

2004-03-30 Thread Paul F. Sullivan
Glenn,

You asked:

For users who receive the list in "list-mode" (1 big file), wouldn't the
list be easier to read if it were sorted by subject (after accounting for
the "Re:", "Re:RE" etc & "Fw" etc.) ?
Not everyone manages to get the subject right every time, so a fully 
automated threading would miss some entries. I think the digest 
itself should be left as is.

If you want a different format, create it locally (and maybe offer it 
to others). The simplest way to get the threaded effect is to open 
the digest in a word processor and search for each subject in turn. 
You could also create macros to actually resort the list into a 
threaded form.

Speaking of macros, I maintain a cumulative digest for each month 
with a couple of WORD macros to disable grammar and spell checking 
(to kill all those distracting colored lines), append the new entry, 
and save the cumulation with a bookmark at the point I've left off. 
I'd be glad to supply them to anyone who'd like them.

--
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: your suggestions for the list - summaries

2004-03-23 Thread Paul F. Sullivan
Mike,

You wrote:

I don't know how such a tradition can be instigated.  Other than to
simply start doing it...
Summaries have been encouraged for as long as I have been on 
Info-LabVIEW, but they have been few and far between. Perhaps a note 
in the weekly reminder might occasionally jog a person's memory to 
supply a summary--with the word SUMMARY in the subject.

--
EnWirementally,
        Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: request from an experienced newbie.

2004-03-22 Thread Paul F. Sullivan
Matt,

You wrote:

...We have chosen LabView over Visual Basic as we think
 that LV ought to ... allow
 later modifications to be made more simply (by non-programmers) than
 having to wade through reams of hostile-looking code! --- Right or wrong??
RIGHT! The graphic nature of LabVIEW allows most of us (descendents 
of visual hunters) to more easily grasp the big picture (because it 
is a picture) in well-written LabVIEW code. Once you have the big 
picture, zoom in on the interesting areas by open subVIs.

...2) display messages to the user, depending on certain conditions (e.g.
 comms success/failure, reaching a certain point in the execution of the
 GPIB commands, etc.);
There is an old utility available on the LabVIEW page of my web site 
(http://www.SULLutions.com/LabVIEW.html) called Post It that I 
developed to keep operators informed about the progress of a test of 
a digital camera. It presents a dynamic list showing which loop of 
which subtest of which test is currently being executed. It grows 
without limit as you nest tests and then shrinks back to an 
appropriate level with a summary as you complete the nested elements. 
I found it quite useful for showing the operator both the forest and 
the trees.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Detecting Lurking VIs (was Confounded and Ranting)

2004-03-21 Thread Paul F. Sullivan
LabVIEWers,

The recent discussion has indicated the danger that VIs on the 
clipboard present for tangling projects. GhostBuster.vi, now 
available on http://www.SULLutions.com/LabVIEW.html, flashes a large, 
red warning on your screen when the only VIs, Globals, and Type Defs 
in memory are invisible because they are on the clipboard, off 
screen, or have their front panels closed. The development 
environment looks free of leftover pieces, but it really isn't. You 
can even set it to detect panels that intrude somewhat onto the 
screen, in case you might not otherwise notice them. It's free as 
long as you don't intend to sell it to someone else.

GhostBuster does not detect minimized VIs. I seem to recall a 
discussion about detecting that a VI has been minimized, but I cannot 
find it at the moment. If anyone can tell me how, I'll incorporate 
that feature in the next release of GhostBuster.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Let's have election!It is fun:)

2004-03-21 Thread Paul F. Sullivan
Michael,

Here's another vote for plain text.

In addition to Scott's font problem and Urs' bandwidth problem (my 
OFFICE connection is dial-up because Verizon has trouble delivering 
even reliable voice service to our neighborhood), I have disabled 
pictures to avoid the occasional explicit ad and I archive snippets 
from the forum in a text only format that currently runs 22 Mbyte.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Decimal String to Number with DBL Default

2004-03-21 Thread Paul F. Sullivan
LabVIEWers,

One of my instruments returns readings as strings of fixed point 
numbers without any decimal point. That is, the instrument returns 
strings of integers and separately indicates where the decimal should 
be, same place for all readings. In my case, the decimal point is 
three places from the right end of the integer.

If I use "Decimal String to Number" with an I32 zero as the default, 
convert "To Double Precision Float", and then "Divide" by 1000, 
everything works fine for positive and negative numbers.

To save the conversion, I tried using a DBL zero as the default. For 
unsigned number strings, this works fine as well, but if the string 
starts with a + or a -, the string doesn't convert and I get the 
default value (LV5 to LV7). Does anyone know why this happens? Is it 
a bug?

Using the "Frac/Exp String to Number" also works, but my input string 
is more limited than what that allows and I'd rather do the tighter 
parsing imposed by converting to a decimal integer.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Digital Control and Indicator Background Color

2004-03-21 Thread Paul F. Sullivan
Ken,

Marco Tedaldi wrote:

Jacoby, Kenneth wrote:

 I would like to programmatically control the background color of the digital
 controls and indicators on my front panel, but I cannot find that property
 listed on the property node for the indicators/controls.
You can change it in the proterty node under "numeric text"/"text
colors"/"BG Color" (in Version 6i and 7)...
Numeric Text.Text Colors controls the color of the text and the 
background color of the text box. Numeric Text.Colors controls the 
foreground and background colors of the text box (almost, but not 
quite, partially redundant). But there does not seem to be any 
property to control the colors of the indicator frame, although both 
foreground and background can be changed with the paint brush.

--
    EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: Detecting Lurking VIs

2004-03-21 Thread Paul F. Sullivan
LabVIEWers,

One more update to Ghost Buster.vi, 
http://www.SULLutions.com/LabVIEW/GhostBuster.zip. The previous LV7 
version, sometimes under Windows XP and always under Mac OS X, 
managed to snatch a second reference to the launcher before it left 
memory. This didn't cause any problems in this application, but it 
might in a future application if someone used Ghost Buster as a 
model. With Jim Kring's help, the problem has been identified and 
fixed. The VIs have also been reorganized and more fully commented to 
make them easier to understand.

--
EnWirementally,
        Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Detecting Lurking VIs (was Confounded and Ranting)

2004-03-21 Thread Paul F. Sullivan
LabVIEWers,

GhostBuster.vi has been fixed to run on all versions of LabVIEW from 
6 through 7. If you have the version that uses Simple Error 
Handler.vi, please download the revised version from 
http://www.SULLutions.com/LabVIEW.html.

GhostBuster still does not detect minimized VIs. If anyone can tell 
me how to do so, I'll incorporate that feature in the next release.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: Detecting Lurking VIs (was Confounded and Ranting)

2004-03-21 Thread Paul F. Sullivan
Thanks, Rolf.

I thought about trying an iteration on "callees" so that the scheme 
would work even if more functionality (and thus more subVIs) were 
added. (I got caught first by Simple Error Handler calling General 
Error Handler.) Originally, I had hoped to avoid subVIs entirely, but 
I managed to trigger errors myself and figured they better give some 
feedback to the user.

The "Caller in memory" sounds like it might be a practical solution. 
Iteration on "Callees" looks messy. Maybe a simpler response than the 
Simple Error Handler is best. I'll look at it tomorrow.

...I just tested it but in LabVIEW 6.1 and higher the General Error 
Handler.vi has some more subVIs for it's internal user error code 
database and therefore your
VI will always pop-up.

Not sure how to fix that LabVIEW version dependant. Maybe try to avoid
any VI in the list which has any Caller in memory?
Rolf Kalbermatter
CIT Engineering Nederland BVtel: +31 (070) 415 9190
Treubstraat 7H  fax: +31 (070) 415 9191
2288 EG Rijswijkhttp://www.citengineering.com
Netherlands mailto:[EMAIL PROTECTED]
...> GhostBuster.vi, now
 > available on http://www.SULLutions.com/LabVIEW.html, flashes a large,
 red warning on your screen when the only VIs, Globals, and Type Defs
 in memory are invisible because they are on the clipboard, off
 > screen, or have their front panels closed...


--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Serial instrument simulation of data

2004-03-10 Thread Paul F. Sullivan
Brett,

You wrote:

I have been working with a vi witch connects to a serial port and reads load
and displacement, how can I simulate the type of data I would normally be
receiving , so that I can test  everything thoroughly, without actually
connecting to the instrument at work.
One of the nicest things about LabVIEW is that it allows you to 
create easily "stubs", dummy VIs with the same connector pattern at 
the real ones, to replace external equipment. I commonly simulate 
serial port writes and reads with very simple VIs in  which large 
front panel string controls and indicators allow you to specify and 
observe any character sequence you can imagine. This is readily 
extended to simulated real data by using the LabVIEW sine and random 
functions driving these controls through the appropriate formatting 
functions. The LabVIEW express VIs offer an even easier way to mimic 
real data.

I'm attaching (private email only) a set of such VIs from a LV3 
project , converted to LV6. Since they have the same names as the 
built-in VIs they replace, make sure that all 11 stubs load from the 
Stubs.llb.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: Detecting Lurking VIs

2004-03-10 Thread Paul F. Sullivan
Jim,

At 6:02 PM + 3/9/04, Jim Kring wrote:
... the problem is fixed by removing the RefNum from the ConPane, which
doesn't seem to have any negative implications for your App.
I was originally using a call by reference node and passing the 
launcher's reference to the callee through the ConPane, so that was 
just a leftover and you are correct that it can be removed. The 
revised code will be posted shortly.

Thanks,

--
EnWirementally,
        Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: How to get the name and status of the windows, programmatically?

2004-03-10 Thread Paul F. Sullivan
Hamid,

You wrote:

I need to get the name of all the windows that are open. Also, I need to
find out the status of the windows
i.e. Which one of them is maximized or minimized?
How can I find out which window is "active"?
It is not clear if you mean all the windows of all programs or just 
all LabVIEW VI panels. In the former case, I can't help  you.

The LabVIEW Application has a property called "All VIs in Memory" 
which provides the names of those VIs. In LabVIEW 7, each VI has a 
property called "Front Panel Window State" which has values including 
"Standard", "Minimized", and "Maximized". In earlier versions, only 
the Front Panel Window Open property exists and there does not appear 
to be an easy way to determined minimized  or maximized windows. The 
"Front Panel Window is Frontmost" property will tell you which is 
"active".

You can see examples of the use of these properties in Copy/Paste 
Boolean Attributes 
(http://www.openg.org/tiki/tiki-index.php?page=Copy-Paste+Boolean+Attributes) 
on the OpenG site and in Edit Panel Elements and Ghost Buster on my 
site (http://www.sullutions.com/LabVIEW.html), among others.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: Detecting Lurking VIs

2004-03-09 Thread Paul F. Sullivan
LabVIEWers,

Prodded by Dan Bookwalter and assured by Rolf Kalbermatter that I was 
not overlooking the obvious, I have upgraded Ghost Buster to launch 
different code for different versions of LabVIEW. The new release 
warns of minimized VIs in LabVIEW 7 and up. Visit
http://www.sullutions.com/LabVIEW.html to read about the improvements 
and download the new version (royalty free for personal or company 
internal use).

In LabVIEW 7.0 on my Mac, the launcher stays in memory, even though I 
think I have killed all references to it. In 6.02 and 6.1, the 
launcher leaves as soon as Ghost Buster 6 is running, as I expect. If 
you know what I am doing wrong,  please let me know and I'll fix it 
in the next version.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Links to Info-LabVIEW status information

2004-03-08 Thread Paul F. Sullivan
LabVIEWers,

At Brian Renken's suggestion, I have made the Info-LabVIEW status 
information on my site easier to access by increasing the size of the 
text and moving it to its own page, 
http://www.sullutions.com/LabVIEW/Info-LabVIEW.html. There is a link 
to this location from the old one.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: Detecting Lurking VIs (was Confounded and Ranting)

2004-03-08 Thread Paul F. Sullivan
Dan,

At 2:12 PM -0500 3/4/04, Bookwalter, Dan wrote:
Can you use the FP State property to tell you if the panel is minimized ?
Yup, and now that I look at the help screen, I'm sure I used that for 
something else just a few days ago, but I can't remember what for! 
The remaining problem with the FP State property is that it isn't 
available before LV7, or at least isn't documented then. I'll do some 
playing around and let you know what comes of it.

--
    EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: Good Programming Practice?

2004-03-02 Thread Paul F. Sullivan
George et al.,

A somewhat dated but functional example of using LV2-style globals to 
move GUI code out of the main VI is downloadable from my LabVIEW page 
(http://www.SULLutions.com/LabVIEW.html) as, appropriately, "GUI as 
SubVI". I don't think there is anything there that others have not 
already described, but sometimes it helps to see a concrete example.

Sorry to be late to the discussion, but I've been on vacation.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: making elements of a Boolean array invisible or disabled

2004-02-29 Thread Paul F. Sullivan
Glenn,

You wrote:

How do I make individual elements of a Boolean array invisible or disabled
but not the entire array?
I'm pretty sure you can't, but I accomplished the disabled effect by 
overlaying individual controls aligned with each of the array 
elements and making selected overlays visible and "disabled and 
grayed". I'm sure you could substitute decorations to fake the 
invisible effect. The alignment code is shown at 
http://www.SULLutions.com/LabVIEW/ArrayCellLocations.gif . Args2 are 
the individual elements overlaid on the array Arguments 2.

I've attached (private email only) the VI illustrated in the .gif 
(less its subVIs), should you care to experiment with this approach.

--
    EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Front panel objects

2004-02-29 Thread Paul F. Sullivan
Brett,

You wrote:

... I want to make the stop button blink red when the current value 
is less than
the peak value therefore showing the sample has failed. I have been working
with the property node blinking property node, and using the comparison Less
< , but cant seem to get any result ...
Both the rectangular and the round stop buttons on the classic 
controls palette blink between red printing on a gray background and 
gold printing and outline on a red background. The 3d stop button 
blinks to a gold background with no printing. I find the 2d effect 
acceptable but don't like the 3d one.

If you want a different set of colors, you'll have to set up a 
pseudo-blink. In a while loop with a 1000ms or so delay, toggle 
between your favorite sets of foreground and background color pairs 
when the sample has failed. Make sure you select the appropriate 
color pairs when the sample is good.

If you need an example or more help, write me directly.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Chip Programming Using DIO Card

2004-02-29 Thread Paul F. Sullivan
Alex,

You wrote:

... I am unsure exactly how you setup a DIO card to do this transfer 
given that the data must be 100ns offset from the clock pulse and 
held for a minimum period of 100ns.
A crude way to meet the setup time is to update the data and raise 
the clock pulse simultaneously on the card, but feed the clock to 
your equipment through a hundred feet (or so) of cable. As long as 
the clock period is greater than 200ns, you'll meet the hold time.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Confounded and Ranting

2004-02-29 Thread Paul F. Sullivan
George,

You wrote:

...  I have been working with LabVIEW for a
long time now and I still find myself baffled by labviews sneaky way of
linking things together...
So often I have had two very similar projects and ...
I wind up having to rename all of the files with some
clever prefix, but when there are more than say two files it really starts
to irk me.  Because it is not enough to rename them in windows... then you
have to go around replacing everything...
The OpenG package building suite has some name-mangling tools that 
automate the process of adding a project-dependent suffix to all the 
VIs in the project. Once you get things untangled, this is a quick 
way to keep them untangled.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: test message

2004-02-29 Thread Paul F. Sullivan
Dan et al.,

If you suspect that something is wrong with your connection to 
Info-LabVIEW, you can get additional information by checking my site 
(http://www.SULLutions.com/LabVIEW.html) or Uwe Frenz's 
(http://www.getemed.net/lvis/LVInfoStat.html) to see which 
Info-LabVIEW digests each of us has received and which we have 
missed. The sites are independent but cross-linked to make it easy to 
detect a problem on our side rather than Info-LabVIEW's. Uwe's site 
is updated automatically. Mine is done manually, typically by noon 
GMT, but the dates posted will let you know if I have slept in or am 
on vacation (as I was a week ago).

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: BUGs

2004-02-29 Thread Paul F. Sullivan
Greg,

You wrote, in very small part:

... units in LV is a unique experiment unlike what I've seen
in other programming languages or engineering tools.  It works
incredibly well and efficiently for most things, but ...
Bugs or no bugs, units has been a God-send to me, flagging my 
attempts to get a force by multiplying a mass and a velocity, for 
instance.

The young'uns figure they'd never make such a stupid mistake but us 
old codgers know we need all the protection we can get. And only 
LabVIEW provides this one. Thanks, NI.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: 60MS/sec- is this possible?

2004-02-16 Thread Paul F. Sullivan
E. Blasberg wrote:

... they're expecting very large peaks on the order of microseconds
and they were afraid that too low a sampling rate would miss the true
peak.
An analog sample-and-hold can be configured to capture transient 
peaks accurately and greatly reduce the load on the computer.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: For the wish list

2004-02-16 Thread Paul F. Sullivan
David Ferster wrote:

...I must be a bad designer because I do just what you are saying is a
no-no, which is to leave a small amount of real estate blank. The
error indicators stay invisible until an error condition occurs, so
that the panel is not cluttered with indicators for rarely occurring
things. Sometimes I use "ugly" error indicators, and more often I use
more elegant indicators, like a red or yellow square LED's with text...
From the operator's point of view, I like to know what's coming and 
dislike having things pop out at me from nowhere. The "Disabled and 
Grayed" state is my favorite. The indicator is subdued until it is 
needed, but everyone knows it is there. Sometimes I'll stack 
infrequently used indicators on top of each other with one grayed and 
the others invisible. The user doesn't know what might pop up but at 
least knows something is there.

For your more elegant design, I'd suggest that switching an LED 
indicator from off to on is nearly as attention getting as making it 
appear but not so startling.

From the programmer's point of view, invisible indicators are more 
easily misplaced and hidden under others or off-screen than 
grayed-out ones when a program is upgraded, especially if the upgrade 
is done by someone other than the original author.

Michael Aivaliotis wrote:

... I think in general, any input that accepts a boolean should accept
the error cluster and operate based on the error logic.
The Select primitive is one function that does accept the error 
cluster as an input. I often use it to choose between enabled and 
grayed constants. Showing labels for these constants neatly documents 
the diagram.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Standalone application installation

2004-02-13 Thread Paul F. Sullivan
Shankar Subramanian,

Your development system license for the application builder covers 
installation of the run time system on a client's machine. Additional 
licenses are required for some of the add-on toll kits.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: LabVIEW 7 Numeric Display precision - or Please Kill me now!

2004-02-13 Thread Paul F. Sullivan
Jack,

You wrote:

Who’s the darn fool at NI that set the default mode for numeric displays to
“Hide Trailing Zero’s”.
...And don’t start that “modify your Ini” line – I work on many different
computers and can’t go customizing the modifying every single one.
I'm not sure it's any easier than modifying the 
.ini file, but at least it is unlikely that 
someone will modify it back if you put a 
customized control in you user.lib.

--
EnWirementally,
        Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Filter

2004-02-07 Thread Paul F. Sullivan
Shankar,

You asked:

... Can a subVI say "Filter.vi" be called simultaneously with 
different input values?
Unless a subVI is reentrant, it will finish operating on one set of 
inputs before starting on another. You can call multiple copies 
simultaneously but they will execute sequentially.

If you wire your three channels of acquired data to three parallel 
copies of Filter.vi and wire the filtered outputs all to the same 
graph, data flow will prevent the instances of Filter.vi from running 
until their respective data are ready and require then all to 
complete before the graph is plotted. If all the channel data are 
available at the same time, the channels will be processed one after 
the other, but with no predetermined order. From the point of view of 
the graph or the data acquisition, the filters will appear to run in 
parallel, but the fine details will show the channels being processed 
in series.

--
EnWirementally,
        Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: Bird's Eye View Utility Available

2004-02-07 Thread Paul F. Sullivan
LabVIEWers,

This didn't go yesterday, so I'm trying again. (This should put PJM's 
posting answering my questions in context.)

I finally got a chance to play with PJM's excellent Bird's Eye View 
utility on my Mac under OS X. (Thanks, PJM.) If you've had problems 
with version 1.0.0, try 1.0.1; it seems to run fine on the Mac.

There are two things that puzzle me about the utility and I wonder if 
anyone can explain them to me.

When I tried to close version 1.0.0, LabVIEW popped up a message box 
saying, "Resetting VI: Bird's Eye View.vi," and hung. Since this does 
not happen with version 1.0.1, where a number of race conditions were 
fixed, I presume that something was getting in something else's way, 
but does anyone know what it means to "reset" a VI and what might 
have caused it to occur here?

Secondly, none of the VIs in the hierarchy are visible in the 
hierarchy window or in the "Unopened VIs" list. How do you do that? 
(They don't show as "SystemVIs" either.)

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: I Really Like Event Structures, But...

2004-01-31 Thread Paul F. Sullivan
Cat,

You wrote, in small part:

...I started out with arrays, but the users complained about indicators
existing for non-existent sensors.  I don't know of any way to make
individual array elements invisible??
It's probably not the best solution for your particular project, but 
individual array element could be made invisible using the procedure 
I posted last week in response to a query from Dan Bookwalter:

For one of my projects I had to overlay individual controls with
specific elements in a 1D array of similar controls. I derived the
array pitch and offsets from the Top, Height, and NumRows properties
of the array and the Left and NumText.Size properties of one of its
elements. The attached VI (private email only and without 200 subVIs)
shows how I did that. The pertinent code is shown on my web site at
http://www.SULLutions.com/LabVIEW/ArrayCellLocations.gif, lower left
corner.
In my original application, I was dealing with various possible 
commands that took different numbers of arguments as array members 
and I overlaid greyed out controls for arguments not used by the 
current command.

--
EnWirementally,
        Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: debugging reentrant executions

2004-01-30 Thread Paul F. Sullivan
Uwe,

You wrote:

...1. Those reentrant daemons have a non-reentrant subvi as a LV2-style
global. Will this LV2Global run just in one instance as expected, e.g. can
I rely on its display?
A non-reentrant subVI behaves normally even when called by a 
reentrant subVI. While the reentrant subVIs can run in parallel, any 
portions data dependent on the non-reentrant subVI will be 
serialized. This can be used to protect resources from multiple 
simultaneous access, for instance. Its panel display is reliable.

...3. If, as in my case, a reentrant daemon does not stop as expected, is
there a save way to shut it down?
How about the OpenG Kill All VIs tool.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Close aplications.

2004-01-27 Thread Paul F. Sullivan
Daniel,

You asked:

How can I do to close an aplication in LabView and close windows and 
turn off PC.
My connection of snippets from this forum has this from a couple of years ago:

Subject: Late response on exiting Windows Programmatically
From: <[EMAIL PROTECTED]>
Date: Mon, 5 Mar 2001 11:03:27 +0100
Sorry for my late response but today I finally caught up with 2 
weeks of info-labview.

I've looked into this a couple of weeks ago since I wanted to run
my built LabVIEW application as the shell and shutdown the computer
when the program quits.
To exit windows under win98 and WinMe you should call the
ExitWindowsEx function in shell32.dll.
You could use the rundll.exe program like this:
rundll32.exe shell32.dll,SHExitWindowsEx n
where n is one, or a combination of, the following numbers:
0 - LOGOFF, 1 - SHUTDOWN, 2 - REBOOT, 4 - FORCE, 8 - POWEROFF
I haven't tested it because I only have one Win95 machine here but
I found it here: 
http://support.microsoft.com/support/kb/articles/Q234/2/16.ASP

Under WindowsNT look at the MSDN reference:
http://msdn.microsoft.com/library/default.asp?URL=/library/psdk/sysmgmt/shutdown_5q25.htm
It says that you need shutdown rights before you are allowed to
shutdown the system, otherwise you will just log off. To get these rights
you have to request them, every user can get shutdown rights for the
local machine but you need administrator rights on the remote machine
to do a remote shutdown (a remote shutdown is where you tell another
computer then the one you are currently working on to poweroff).
To get the rights to shutdown for your program you need to do
some C-programming, maybe you could also do everything from LabVIEW.
What I did I copied the source code found here:
http://msdn.microsoft.com/library/psdk/sysmgmt/shutdown_7z8u.htm
and put into a CIN (with some modification so I could specify the
kind of shutdown I wanted (logoff, Windows Exit or complete power off).
Then to really power down (if your hardware supports it) you should
make a change in your registry found here:
http://msdn.microsoft.com/library/default.asp?URL=/library/winresource/dnwinnt/s8554.htm
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows 
NT\CurrentVersion\Winlogon\PowerdownAfterShutdown -> "1"

or download a utility from your computer vendor which enables 
poweroff after windows exit.

Alternatively you can also download/use the WinNT Resource kit where you
will find the shutdown.exe utility which will request the proper rights for
you and poweroff if you start it with: shutdown.exe 3 /powerdown
http://support.microsoft.com/support/kb/articles/Q186/5/57.ASP
I've made a little VI which will check if you run the development environment
in which case it will check if you have made some unsaved changes and if not
exit only LabVIEW. If you are running the runtime environment it will try
to power down the system depending on Win9X or WinNT method.
I haven't tried it on every platform and also I know that if you try
to powerdown on a system that does not support it it will reboot under
Windows95 instead of show the "it is now safe to turn off your computer"
screen. But that would require some extra work and it already serves my
purpose on the Dell WinNT machines I use (using the dell system 
utilities v.13)

If you're interested let me know.

Remco.
Hope it helps some.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: Greg's Car - salt lick

2004-01-27 Thread Paul F. Sullivan
Sorry, but I had to observe that combination in the subject brings to 
mind New England today rather than Texas in summer.

Subject: RE: Greg's Car - salt lick
From: "Michael Aivaliotis" <[EMAIL PROTECTED]>
Date: Mon, 26 Jan 2004 16:58:11 -0500
--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Icons

2004-01-26 Thread Paul F. Sullivan
Daniel,

You wrote:

 I am creatting icons by my aplication in LabView and they are really
 beattyfull... but each icon is 1.5 Mbyte. I have built them in paint
(.bmp).
 How could I do to reduce, less change quality colors?
1.5 Mbyte sounds very large for a 32x32 icon but, if it really is 
icons you want, Microangelo is a very good product for handling them 
on a Windows machine. (On the Mac, I use Resourcerer or 
Iconographer.) All of these products accept .bmp files or, at least, 
allow copy and paste from a bit map image. If these are really larger 
images, rather than icons, you'll probably need something more 
powerful like Photoshop or Debabelizer to convert from .bmp to 
something more compact like .jpg or .gif.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Edit Panel Elements

2004-01-25 Thread Paul F. Sullivan
Sorry, that link should have been http://www.SULLutions.com/LabVIEW.html.
--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Edit Panel Elements

2004-01-25 Thread Paul F. Sullivan
LabVIEWers,

Have you ever needed to manipulate decorations programmatically? Have 
you had trouble determining which indices to use? Once you had the 
right indices, did editing make them change? Find Decorations.vi is 
an editing tool that can help by flashing each decoration, even 
invisible ones, as you step trough their indices, then return them to 
their original states.

Do you need to make selected front panel elements match in width or 
height without LabVIEW 7? Resize.vi is an editing tool that provides 
much the same capability as LabVIEW 7's resize palette, but it is 
written in LabVIEW 6.02.

Both act on the VI whose front panel has most recently had the focus 
and, if your environment supports it, float on top of all other 
LabVIEW windows. They are combined with Jim Kring's Copy-Paste 
Boolean Attributes.vi in Edit Panel Elements.llb, a candidate for an 
OpenG project, newly available from 
http://www.SULLutions.com/LabVIEW, and they're free.

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Managing VISA Resources

2004-01-24 Thread Paul F. Sullivan
George,

You wrote:

I am trying to find a way to hide some of the book-keeping associated with
VISA references... I want to make ... some very high level VIs like
"Get Wavefrom", "Move Motor", "Get Spectrum", etc... but maintain similar
efficiency as a VI that passes the reference all over the place...
I'd highly recommend looking at the LabVIEW Component Oriented Design 
(LCOD) presented in "A Software Engineering Approach to LabVIEW" by 
Conway and Watts. It sounds like that is exactly what you're trying 
to do.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: EmStop

2004-01-24 Thread Paul F. Sullivan
Shankar,

You wrote:

I have a subVI that needs an emergency stop. Once this stop is pressed, the
VI should stop running. The subVI has several loops running sequentially. I
want this " EmStop" button to take effect no matter at which execution point
the VI is.
A long while ago I made a LV2 style global to do just that. It is 
called "Running Global" and is available for download from the very 
bottom of my LabVIEW page,  http://www.SULLutions.com/LabVIEW.html. 
The VI description details its use.

--
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit






Re: Finding the position of a table cell from its Edit Position Property

2004-01-24 Thread Paul F. Sullivan
Dan,

You asked:

Anyone have a slick way of determining the position of a Table Cell from its
Edit Position (row,column) property ?
For one of my projects I had to overlay individual controls with 
specific elements in a 1D array of similar controls. I derived the 
array pitch and offsets from the Top, Height, and NumRows properties 
of the array and the Left and NumText.Size properties of one of its 
elements. The attached VI (private email only and without 200 subVIs) 
shows how I did that. The pertinent code is shown on my web site at 
http://www.SULLutions.com/LabVIEW/ArrayCellLocations.gif, lower left 
corner. I would think that extending this to a 2D table would be 
straightforward.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Caputring points on a threshold

2004-01-21 Thread Paul F. Sullivan
Patrick,

You wrote:

... we would like to capture the values that cross a set (Y)
threshold and then save them to a separate array along with their (X)
value.
You can use the Threshold 1D Array primitive in a loop, feeding the 
fractional index output back to the start index input through a shift 
register,  but be careful. You must ignore any value where the 
fractional index matches the start index or you will recover all 
points above the threshold. If the start index matches, increment it 
before feeding back. Stop the loop when the fractional index is NaN. 
There is a diagram at 
http://www.SULLutions.com/LabVIEW/ThresholdDetection.gif.

If you need any more info, just ask.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: State machine diagram editor

2004-01-20 Thread Paul F. Sullivan
Paul,

You wrote:

 >Beware though that if you have enum items set {"da","moo"} and
 >supply a string "dada" or "mooable", no error is returned...
I handle this problem via the case structure's Default case.  With string
driven state machines, my default case is always "invalid case."  If a
string does not exactly match the state names, the structure executes the
default case ("invalid case") which generates an error and gives the
invalid string.  I find this very helpful for debugging as well.
With an enum-based machine, avoiding a Default case let's you know 
whether you've included all the desired cases at programming time. 
Everything's a tradeoff.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Write to File

2004-01-20 Thread Paul F. Sullivan
Shankar,

You wrote:

I have a loop that acquires data from NI DAQ and writes data to a text file.

'Acquiring' and 'writing to file' stages are separate sub VIs inside a
loop. As soon as set of 'N' data is acquired, it is sent to write to file
subVI to write in File 'X'. The process is repeated until acquisition is
done for say, "t" seconds.
I wanted to write the data into two files inside the "Write to File" subVI.
For this I just send a File refnum to the subVI and write data to a second
file (File 'Y') after writing the first (File 'X'). I use a "flush file"
command for both of them...
When I
write to one file only, scan backlog stays at zero and acquisition happens
properly. When I include the code for the second file too, scan backlog
increases...
Could anyone let me know as to what I am doing wrong here?
The likely problem is that acquiring a sample and writing two files 
to disk takes more than one sample time. The question is, "What to do 
about it?" The answer is, "Several things."

1. With the acquisition and storage VIs both in the same loop, they 
have to run sequentially. Put them in separate loops so that they can 
run in parallel. It is almost always wise to do this.

This works because a write to a disk takes a long time but not much 
processor overhead. The processor can work on the acquisition while 
the disk controller is handling the storage. Use an intelligent 
global, queue, or ordinary global to transfer the data from the 
acquisition loop to the storage loop.

2. It sounds like you call the storage VI twice, once with each of 
the two different files specified. This causes these two writes to be 
sequential. Make two separate VIs, make the VI reentrant, or combine 
the two by making the VI reentrant and wrapping it in two different 
shell VIs for the two channels. depending on your needs and comfort 
level. Now the processor can set up one transfer while the disk 
controller is trying to find the right sector on the disk for the 
other.

3. Don't flush too often.

The actual transfer to the disk is what takes most of the time. The 
"write to disk" operations normally just write to the disk buffer, 
which is very fast. When the operating system thinks it's necessary, 
when you close the file, or when you flush the file, that buffer is 
transferred to the disk. If the computer crashes in the meantime, you 
lose all the data in the buffers. (If it crashes before you close the 
file, you can recover the flushed data with certain utilities. Since 
flushing is much faster than closing, it is commonly used to save a 
little computer time over and over again at the risk of very rarely 
wasting a lot of your time.)

Unless your data is extremely valuable, don't flush the buffer after 
each write. Accumulate data over a period that is reasonable to lose 
in the unlikely event that the computer will crash. In most cases, 
flushing every minute takes essentially no net time (milliseconds per 
minute) and puts only a minute's data at risk. If your data is very 
valuable (e.g.. crash test data), write the data as it is acquired 
over a network to a backup computer as well and store it both places 
in parallel or use something more reliable than a computer to capture 
the data.

Hope this helps. If anything is unclear, just ask.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: State machine diagram editor

2004-01-19 Thread Paul F. Sullivan
At 9:59 AM -0600 1/19/04, Scott Serlin wrote:

Can you elaborate further on where the OpenG toolkit can be found with
the "Set Enum String Value" VI?
It's not an NI package. It's available through http://www.openg.org/, 
where you'll find the information. In the box on the right side of 
the screen just below search, click Downloads. That will redirect you 
to http://sourceforge.net/projects/opengtoolkit/ for the actual 
download, where you'll probably want "all_packages" but could get 
along with only lib_lvdata and lib_err. Set Enum String Value is in 
the lvdata.llb.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: State machine diagram editor

2004-01-19 Thread Paul F. Sullivan
At 10:31 AM -0800 1/18/04, PJ M wrote:
...>The OpenG toolkit has a "Set Enum String Value" VI ...

One can also just use the "Scan From String" primitive with the enum 
type def constant as the "default value 1" and the string you want 
to set as "input string". This way "output 1" will return the enum 
type def with the "input string" value.
Ouch! How could I have missed that? As long as you watch the error 
output for error 85 (the string is not an element of the enum), it 
works great. Even in LV 5.1, which is as far back as I have on this 
machine.

Thanks to this forum, I'm getting less stupid every day.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: State machine diagram editor

2004-01-18 Thread Paul F. Sullivan
Lew,

I really like your premise and architecture:

An important point is that any state diagram (and logic) that you use to
control a process should be related to the process and not to internal
computer program states or actions...
In the most general case, I use 4 asynchronous loops running in parallel and
accessing the same "Task" queue (which contains strings indicating which
task is to be executed)...
The only thing I'd do differently is to use type def enums for the 
process state and for the task queue to catch misspellings during the 
programming phase. (On older version of LabVIEW, the enums can be 
converted to and from strings for the queue, either with the 
flattening functions or with the Format to String and the OpenG VI.)

I'd argue that your task loop is really a state machine that handles 
the "computer program states" you reference in your first sentence. 
Keeping the two machines explicitly separate really clarifies the 
programming.

--
    EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: State machine diagram editor

2004-01-18 Thread Paul F. Sullivan
Mark,

You wrote:

... I use string driven
state machines instead of enum type defs when I want to create a scriptable
state machine.  That is, the state sequence is driven by a text file that
has information about what order the states are executed.  This means the
test sequence can be modified in the field using any text editor...
The OpenG toolkit has a "Set Enum String Value" VI that would allow a 
text script to run an enum-based sate machine. I didn't know about 
the OpenG VI when I first needed this capability so I built a "Set 
Enum with String" VI that works with control references. If you'd 
like that, just let me know.

--
    EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Landscape graph in a word report

2004-01-14 Thread Paul F. Sullivan
V. P. Nair wrote:

Is there any way I can make my graph display (and print) in landscape
orientation when my rest of the report is portrait?
If you make the graph a separate section (Insert>>Break>>Section 
Break), you can Format>>Document>>Page Setup>>Landscape Print 
applying only to the selected section. Does that help?

--
    EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






RE: ScrollBar

2004-01-13 Thread Paul F. Sullivan
Shankar,

You wrote:

... Is there a way I can
open a subVI FP, at particular coordinates or something similar to that such
that it always shows "Start" and does an automatic scrolling?
And Kelly responded:

It looks like you can use a property node for the VI and select the property
"Front Panel Window:Origin".  I haven't tried this but you should be able to
make the panel scroll by changing the values in the cluster...
I had a lot of trouble figuring out just what properties had to to 
set to what. "Resize Front Panel Elements", just posted to my site, 
sizes it's own window to show different buttons under different 
circumstances. The code in the "Initialize" and "Resize window" 
states should show you how to do it very explicitly. Resize.vi runs 
when opened, so you'll have to halt it first with a CTRL-. (or CMD-.) 
to be able to open the diagram.

And for those of you who would like to make selected front panel 
elements match in width or height and don't have LabVIEW 7 yet, try 
this utility.

--
EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Building functions.

2004-01-12 Thread Paul F. Sullivan
Daniel,

Would examples>>math>>math.llb>>1D Explorer Example.vi in the full or 
professional version help?

--
EnWirementally,
    Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com






Re: Best Layout for Large Scale Process Control App

2003-12-20 Thread Paul F. Sullivan
Eric,

Here's another vote for "A Software Engineering Approach to LabVIEW".

Their LabVIEW Component Oriented Design (LCOD) concept is very much 
like OOP, but their recommendation for putting all "constants" in a 
configuration file is not, AFAIK, included in the OOP rules. 
Configuration files are a perfect way to handle your comment:

... In the future, I would like to do as little individual changes 
as possible (such as changing constants, array sizes, etc throughout 
the top-level an sub-vis), and have everything be as dynamic as 
possible (change a couple of cluster sizes and maybe reorder or be 
able to change a value in some central location...
--
    EnWirementally,
Paul F. Sullivan


SULLutions  (781)769-6869
"when a single discipline is not enough"
	visit http://www.SULLutions.com