General
30 files
-
Array Point to RowCol
By JDave
Copyright © 2006, dsaunders
All rights reserved.
Author:
dsaunders
--see readme file for contact information
Description:
Converts a pixel coordinate to an array index. Returns an array of indices with a length equal to the number of array dimensions. Also returns if the point is within the content rectangle (not on the caption, scrollbars, etc.)
Works on any N-dimensional array regardless of visibility of caption, label, index display, or scrollbars. Designed to be used on mouse events that provide the mouse coordinates.
Limitations: Property nodes do not indicate the array border width, nor if the user has chosen to display an element gap. These inputs are thus provided on the VI.
Version History:
1.0.0:
Initial release of the code.
1,461 downloads
Submitted
-
Game of Life
By eaolson
Author:
Eric Olson
--see readme file for email address
Description:
Conway's Game of Life is a fun little simulation of a group of cells. How new cells are born and how old cells die is decided by a simple set of rules, but can lead to complicated behavior by the entire colony. I've always found this simulation to be interesting and I thought coding it in LabVIEW would be a fun exercise. Comments and critiques of either the game or of my coding style are always welcome.
The basic rules are simple:
1. A cell that has one or zero neighbors dies of lonliness.
2. A cell that has four or more neighbors dies of overcrowding.
3. An empty cell that has exactly three neighbors containes a new cell in the following generation.
A thorough explanation of the Game can be found at http://web.archive.o...7s_game_of_life .
Dependancies:
This uses the OpenG time, file, and variantconfig libraries. They are not included.
Download them via the OpenG Package Manager: http://web.archive.o...p?showtopic=233
Change Log:
1.0.0: Initial release of the code.
1.0.1: Include readme.txt in the zip file.
1.1.0: Added Open and Save As functions (in the menubar). Added an About dialog. Removed the Exit button (redundant to Close).
1.1.1: Forgot to include the .rtm file in the distribution. Rows/columns now update when opening a .gol file.
1,263 downloads
Updated
-
Windows Environment Variable Reader Writer
By hooovahh
Windows Environment Variable Reader Writer Vc
Copyright © 2006, Brian Hoover
All rights reserved.
Author:
Brian Hoover
**see email address in readme txt**
Description::
Purpose:
This Vi was made so that you can easily view and create environment variables from within Windows XP.
Features:
You are able to read all environment variables which you have available to you at the command prompt by typing "set". It also can write environment variables by writing them to the registry in the following location:
HKEY_CURRENT_USER\Environment
Also for added safty it will check the name you are trying to use, and won't allow its creation if a variable with that name already exists.
Usage:
To use this VI you need to be using Labview version 8.20. With Labview 8.20 installed open the VariableReadWrite.vi file, then click run. While it's running open the View Variables tab and click "Refresh Variables" to view all your command prompt variables.
Two String arrays are created, the Name of the variables, and their values. A text window is also displaying what the user would see if they typed "set" at a command prompt.
To create a variable open the Create Variables tab and fill in the information for Variable Name and Variable Value; then click Create Variable. Please note that you may need to log off then back on for the new variable to take effect.
If needed there is a "Run Regedit" button which will open the registry. From here you can see the newly created variables in the location mentioned in the Features section.
When you are done click stop to end the program.
Version History:
1.0.0:
Initial release of the code.
1,481 downloads
Submitted
-
VI_path_listing
By torekp
VI_path_listing V1.0.0
Copyright © 2006, Huron Valley Steel Corporation
All rights reserved.
Author:
Paul Torek
contact through http://forums.lavag.org, by sending PM (private message) to torekp
Description:
Lists the paths of all VIs in memory other than itself, with the (optional) exception of vi.lib VIs. Note that if you do not exclude vi.lib, some of this VI's subVIs will appear on the list. Prompts user to save the list to a text file or to Cancel the save operation.
This VI might be useful to those who do not use a rigorous source code control scheme, but still want to keep track of many VIs.
Version History:
1.0.0:
Initial release of the code.
493 downloads
Updated
-
Random permutation
By syrus
Copyright © 2006, 2007, Syrus Nemat-Nasser
All rights reserved.
Author:
Syrus Nemat-Nasser
**see readme text for email address**
Description::
This SubVI takes a positive I32 integer n as input and generates a uniformly random array of the integers from 0 to n-1 as output. It is equivalent in function to the ‘randperm’ command in MATLAB. If a non-positive value is provided, an error is raised to alert the caller.
Version History:
1.0.0:
Initial release of the code.
1.1.0:
Added input validation, error handling, and the option to use "MATLAB mode" and generate a permutation of the integers from 1 to n instead of 0 to n-1, where n is the value wired to the size input. Added a "convert to I32" before feeding the random index to the array functions to eliminate two coercion dots. Updated description to reflect these changes. Changed wiring pattern to 4-2-2-4 and changed icon to accomodate additional terminals.
2.0.0:
Added a random seed input to allow the user to optionally seed the random number generator to produce a specific random permutation. The VI now uses the Uniform White Noise PtByPt function which is not available in the LabVIEW Base package. Users who have the Base package may need to use version 1.1.0 which is still included in the distribution.
994 downloads
Updated