Welcome!

Welcome to Agilent VEE Pro Help. To find a topic you want to read, click on the Contents or Index buttons above.

Agilent VEE Pro 7.0 New Features

What's Been Fixed in this Release

Mini-Dumps - Please review this topic and take advantage of this facility

Microsoft®, MS-DOS®, Windows®, MS Windows®, and Windows NT® are U.S. registered trademarks of Microsoft Corporation.

PostScript® is a trademark of Adobe Systems Incorporated.

MATLAB® is a registered trademark of The MathWorks, Inc.

Arial® and Times New Roman® are U.S. registered trademarks of the Monotype Corporation.


VEE 7.0 New Features

Agilent VEE Pro 7.0 New Features

Agilent VEE Pro 7.0 has some new features, such as the Property Grid and Microsoft Visual Studio .NET programmability, that make the VEE Pro 7.0 save format unique. Programs saved from VEE Pro 7.0 will not load into prior VEE versions.

Undo/Redo

One of the most commonly requested features has been Undo. Both Undo and Redo operations will be supported in VEE for many common operations. Examples include: cut a line, delete a terminal, delete objects from a panel, paste objects, move an object, and many more.

See Undo and Redo

Object Property Editing

Using a property editing box similar to what is available in Visual Basic, VEE provides a Properties Window where you can easily change a host of properties for your VEE objects. It's simple and, in most cases, will be two clicks and you're done. It works when you select multiple objects (providing an "intersection" of properties for the two objects if they are different). It works on the detail view and panel view too!

See Properties (Object)

Panel Edit Features

Editing objects on panels just got easier. The following have been added: a visible grid, alignment of objects, "rubber-band" selection of objects, undo of many common operations while building a panel, bring to front, send to back, tab order, and other features as well.

Rich Text Format for Notepad and Description

Editing notes, and descriptions is now much easier. Using the power of .NET, RTF has been implemented for these two. Additionally, the notes and descriptions contain automatic hyperlink detection and bring up a browser with the link you select. Both support undo (CTRL-Z) and redo (CTRL-Y) as well as all your other familiar editing short-cut keys. You can cut and paste from an .rtf file directly into a note or description and word wrap works also. Finally, you can create a custom template (default templates are templates\notepad.rtf and templates\description.rtf). These templates are retrieved whenever you create a new object from the menu. Of course, if you don't want a template, you can always remove it.

Programmatically Use .NET Assemblies

There are a great number of .NET classes available today, and there will be more in the future. Sometimes the functionality these classes provide is not available in VEE or is more desirable than what VEE offers. To make these valuable assets available to you, VEE 7.0 provides access to the Microsoft .NET Framework Library. This Library contains feature rich classes that you can use in a way similar to your use of ActiveX in VEE 5.x and above. See the examples in the DotNet examples directory to get some idea of the power of the .NET Framework to enhance VEE.

An additional feature is the ability to import namespaces. From the Device > .NET Assembly References menu, check the "Import namespaces after closing" checkbox. Choose one or more .NET Assemblies, and you will be prompted to select zero or more namespaces. You can also choose Import .NET Namespaces from the Device menu. What is the significance of this? Well, without a namespace import you might have to type System.IO.File.Exists(). With a namespace import, your method call looks like File.Exists(). Just a few clicks replaces a lot of typing.

A new type conversion function called asClrType has been added. This function converts a VEE data type to a .NET/CLR data type. The valid .NET/CLR data types include all of the primitive data types (Boolean, Byte, SByte, Int16, Int32, Uint32, Int64, Char, Double and Single), Decimal, DataTime, and String. asClrType is rarely needed as VEE converts between VEE and .NET data types automatically most of the time. For an example of VEE program using asClrType, please see examples\dotnet\datetime.vee.

See Tell Me About > .NET Framework in the Table of Contents

Connectivity for USB Based Instruments

Keeping VEE current with the newest Agilent instrumentation and competitive software products has always been a goal for Agilent. To this end, the I/O subsystem has been enhanced to accommodate instruments with a Universal Serial Bus (USB). Another feature of USB support is the ability to use USB aliases. USB aliases replace the long and awkward address string of USB addresses.

Connectivity for LAN Based Instruments

As stated in the USB connectivity paragraph, alternative connections to instrumentation are becoming standard. To adapt to these changes, VEE has been enhanced to provide connectivity for LAN-based instruments.

Use IVI-COM Drivers

IVI-COM is the latest standard for instrument compatibility. Established by the IVI Foundation, it encourages instrument manufacturers to produce instruments that are interchangeable with their competitors. To adapt to these new standards, VEE will accept all Agilent IVI-COM drivers and some third party IVI-COM drivers as well.

VEE interacts with IVI-COM drivers by finding a Primary Interop Assembly (PIA) for them. An assembly is an .EXE or DLL file and is the fundamental building block of a .NET application. The PIA is a .NET assembly that is provided by vendors for their COM based components. Since your IVI-COM driver is a COM based component, VEE will attempt to find a PIA for it. Once this is done, VEE lets you use the IVI-COM driver just like any other .NET assembly.

See What is IVI?

The Error Reporting Mechanism has Changed

Agilent has changed the VEE error reporting mechanism. Please take advantage of this valuable facility. See Minidumps for more information.

See Also

What's Been Fixed in this Release


What's Been Fixed in VEE Version 7.0

What's Been Fixed in this Version

ID | Description
23531 | Runtime memory leak when sending Records as a parameter to a ActiveX method.
23528 | Runtime memory leak when ActiveX method returns array of Variant containing type VT_BSTR.
23527 | Runtime memory leak when ActiveX method returns array of Variant containing type VT_UI or VT_I2 or VT_R4 or VT_BOOL.
23452 | Serious Error "updatePosition sent to free object" when unpacking UserObject with external loopback line.
23397 | The object created via the "Generate Set Variable" menu item on a "Variable" node in the Program Explorer should be titled "Set varName" not "varName".
23306 | Shutting off Webserver can hang VEE
23303 | Copying multiple lines then pasting multiple lines into a Formula or MATLAB Script object may cause VEE to become unresponsive.
22947 | ToString object: writing a string using Quoted String format that is shorter than the MaxNumChars will write an extra double quote character at the end of string.
22851 | Documentation: Updated help for If/Then/Else object section on how to output a value when it meets a condition.
22801 | Documentation: Make VEE command line options available in online help.
22796 | Declare Variable objects in an Imported Library UserFunction can be modified.
22794 | Serious Error "deactivate sent to freed object" with tooltips on Graph objects on a pop up panel where the tooltip is displayed while the pop up panel is closing.
22792 | Serious Error occurs when entering values that are out of range for a Date/Time field.
22791 | Converting a Coord array to Text using the asString() function or input terminal type constraint gives incorrect result.
22784 | Too many menu items in .MNU file can cause all of the VEE menus to behave erratically (invoke the wrong commands, crash, etc).
22764 | Serious Error can occur on a line probe after unpacking a UserObject that contains other UserObjects with lines connected to the outer UserObject and then running the program.
22763 | Serious Error may occur when looking at XYDevice members under VEE Objects in the Function & Object Browser.
22761 | VEE exits immediately without an error dialog box when incorrect data is sent to the Default Value control pin of a Coord Constant object.
22756 | Documentation: File Name Selection object optional input Dialog Mode is undocumented.
22750 | Serious Error occurs when multiplying a Record that contains an enum field in a Formula object.
22746 | Removing a previously added remote instrument where Gateway address string is greater than 32 characters can cause VEE to crash.
22714 | Formula that turns input array to scalar will cause a Serious Error when indexing that input later.
22673 | MATLAB Helpdesk help content not applicable to MATLAB Script that ships with VEE.
22558 | Documentation: Typing "start vee" at the command prompt might not start VEE if you have a folder in the directory called "VEE". Use "start vee.exe" instead. Help updated to reflect this.
22547 | Documentation: Updated to indicate that a VEE 5 prog saved from 6, with no other changes, may become incompatible with VEE 5.
22543 | UnBuild Record output terminals for field names should error on bad variable names such as "2".
22486 | User Functions are not editable after File | Merge Library. You have to save, exit VEE and reload the program to edit the UserFunctions.
21961 | Hanning windowing function does not work correctly for an odd number of data points.
21959 | Documentation: Graph Marker property help incorrectly states that markers aren't linked between different views of the same graph.
16686 | MATLAB Script that saves a graph to a file can cause a VEE caution "Reference to unitialized variable dbstat".
15745 | Serious Error may occur in Instrument Manager when adding several remote instruments via Gateway field.
15370 | Having mulitple Direct I/O, FromString and FromFile objects that use READ TEXT x TOKEN INCLUDE:"..." transactions can return a corrupt string.
11803 | VXIplug&play driver object does not allow ViConstString as valid data type.
11694 | Serious Error can occur during extensive editing in a MATLAB Script object.
11681 | LOCK DEVICE command in a transaction on a Multi-Instrument Direct I/O object results in a VEE program that can't be loaded.
11520 | Drag sizing of an object on panel is off by one with relative to the grid snapping.
11096 | Font selection dialog box's sample display doesn't show the current font being used, it shows the default font.
10094 | Clicking on File | Save immediately after changing the contents of a Formula or MATLAB Script object loses those changes.
4405 | sqrt( (-1,0) ) gives wrong answer: (61e-18, 1), should be (0,1).
4366 | Memory leak in Formula and MATLAB Script object when deleting or pasting multiple lines.
4364 | VEE Beep Object only generates a click and ignores the frequency and duration fields.
4360 | Selecting text using mouse in a Formula or MATLAB Script object and deleting doesn't always work.
4233 | Notepad doesn't support a horizontal scrollbar.
4015 | Serious Error occurs when moving an ActiveX control or a Declare Variable object into a UserFunction from Main when the VEE program is running.


To Start Agilent VEE for Windows

To Start Agilent VEE

You can start multiple copies of VEE running on the same PC. However, if two copies of VEE attempt to access the same system resource (for example, an I/O interface) at the same time, unexpected results may occur.

For information about using VEE Pro RunTime to run programs, see Preventing Program Changes and To Create an Application Icon in Windows.

Using the Windows Start Button

1. Click the Start button, and then point to Programs [image] Agilent VEE Pro 7.0.

Starting from the Windows Desktop

1. Follow the directions in Windows Help to put a shortcut for the Agilent VEE application file on the desktop using Windows Explorer.

By default, VEE is installed in:

C:\Program Files\Agilent\VEE Pro 7.0\vee.exe

unless you installed it in another directory.

2. Once the shortcut is in place, double-click on the shortcut icon to start Agilent VEE.


To Start Agilent VEE with Command-Line Options

Agilent VEE provides several command-line options that you can use to start VEE and VEE Pro RunTime. For example, you can specify a VEE program file to load when VEE starts. Also, you can choose to load and run a program in VEE Pro RunTime.

To start VEE and VEE Pro RunTime using the command-line options

1. Click on the Windows Start button, and then click on Run...

2. Type vee or veerun, followed by the desired option(s), and press Enter. The veerun command also requires a program file name after the option(s).

or

1. Open an MS-DOS window.

2. Type start vee.exe or start veerun.exe, followed by the desired option(s), and press Enter. The veerun command also requires a program file name after the option(s).

Scroll down through this topic for available options and examples.

Tip

If you put a shortcut for VEE on the desktop, you can modify the shortcut’s properties to include command-line options.

Scroll down through this topic for available options and examples.

Available Options

The following table shows the options available for each platform when using VEE or VEE Pro RunTime. A description of each option appears below the table.

Option | Windows
 | VEE | VEE Runtime
-d directory | X | X
-disallowclose |  | X
-enablewarnings |  | X
filename | X | X
-geometry | X | X
-help | X | X
-iconic | X | X
-ioconfig |  | X
-maximize | X | X
-noerrdisp | X |
-nologo | X |
-preconfig |  | X
-r filename | X |
-secure ProgramName | X |
-stderr:filename ProgramName | X | X
-stdout:filename ProgramName | X | X
-veeio path to filename | X | X

Option Descriptions

-d directory

The -d option starts VEE and uses the related files, such as instrument drivers, located in the specified directory instead of the default VEE installation directory.

-disallowclose

Prevents the user from closing the VEE Pro RunTime window while a program is running.

-enablewarnings

Enables the display of error and caution dialog boxes when loading a program into VEE Pro RunTime. Without this option, VEE Pro RunTime supresses all normal error and caution dialogs during program loading. With normal error displays disabled, a failed load gives only a generic (less useful) message, such as: "File format is invalid." With
-enablewarnings, you can see a more specific cause of the problem.

filename

This is optional for the vee command, and required for the veerun command. The vee command starts VEE and opens the VEE program specified by filename in the VEE work area. The veerun command starts VEE Pro RunTime and runs the VEE program specified by filename. For Windows, if filename contains spaces, then the entire file name, including the path, must include quotation marks.

-geometry widthXheight+/-xoffset+/-yoffset
or
-geometry +/-xoffset+/-yoffset (to use default window size)

Specifies an initial window geometry to be used instead of the default geometry. Geometry values are in pixels. Positive offset values position the top-left corner of the window relative to the top-left corner of the screen. Negative offset values position the bottom-right corner of the window relative to the bottom-right corner of the screen.

The offset +0+0 is the top-left corner of your screen.

Example: -geometry 640X480+20+20 starts VEE in a window that is 640 pixels wide and 480 pixels high, that is placed 20 pixels to the right and 20 pixels down from the top-left corner of the screen.

-help

Shows the VEE command line options. (Not to be confused with the VEE online help system, which is launched from within VEE.)

-iconic

The -iconic option starts VEE as an icon instead of a window. Double-click on the icon to open it to a window.

-ioconfig

This option opens the Instrument Manager dialog box in the VEE Pro RunTime window allowing changes to the I/O configuration file vee.io. Do not include a program file name with this command; it is ignored.

-maximize

This option starts VEE in an enlarged window that fills the screen.

-noerrdisp

This option can be used in conjunction with -r. If used with -r, and the specified program does not run due to an error, VEE exits immediately without displaying an error message.

-nologo

This option suppresses the startup information that appears before VEE starts running. On Windows, the startup information box does not appear.

-prefconfig

This option opens the Default Preferences dialog box in the VEE Pro RunTime window allowing changes to the default configuration. Do not include a program file name with this command; it is ignored.

-r filename

The -r option starts VEE and runs the VEE program specified by filename. When the program finishes running, VEE exits immediately. However, if an error occurs, an error message is displayed before VEE exits. If you do not specify a file name, VEE ignores the -r option. If filename contains spaces, then the entire file name, including the path, must be quoted. Generally, the veerun command is better to use than the -r option.

-secure ProgramName

Creates a secured program using ProgramName as the source file. The following command creates the file myProg.vxe in the same directory as the source file:

vee -secure myProg

-stderr:filename ProgramName

Creates a standard error log file named filename, and logs error information generated by VEE (if errors occur) while loading and running ProgramName. You can include a directory path with filename.

-stdout:filename ProgramName

Creates a standard output file named filename, and logs information generated by VEE (if any occur) while loading and running ProgramName. You can include a directory path with filename.

-veeio path to filename

VEE lets you have multiple I/O configuration files (vee.io). This option lets you specify the one you want to use when you start VEE.

Example: Starting VEE for Windows Using filename

To start Agilent VEE for Windows and automatically open the program myprog.vee:

1. Click on the Windows Start button, and then click on Run...

2. Type vee myprog.vee and press Enter. Surround file names with quotation marks if they contain spaces.

or

1. Open an MS-DOS window.

2. Type start vee myprog.vee and press Enter. Specify a path if the program is not in the current directory. Surround file names with quotation marks if they contain spaces.

Example: Starting VEE RunTime for Windows using -disallowclose

To run the program myprog.vee in VEE RunTime for Windows and prevent closure of the execution window:

1. Click on the Windows Start button, and then click on Run...

2. Type veerun -disallowclose myprog and press Enter. Surround file names with quotation marks if they contain spaces.

or

1. Open an MS-DOS window.

2. Type start veerun -disallowclose myprog and press Enter. Specify a path if the program is not in the current directory. Surround file names with quotation marks if they contain spaces.

See Also

To Create an Application Icon in Windows


To Open a VEE Example File

To Open an Example Program File

Tip

The following topic in VEE Help contains descriptions of the example programs and links that load them into a new VEE window:

Guide to VEE Example Programs

Agilent VEE

Several example programs are provided with VEE. These examples are found in subdirectories under
C:\Program Files\Agilent\VEE Pro 7.0\examples.
For instance, the examples from the VEE manuals and online Help are found in the subdirectory:

C:\Program Files\Agilent\VEE Pro 7.0\examples\Manual

You can open any program file, including an example, by clicking on the Open button on the VEE toolbar. However, for your convenience you can open an example program file from Help:

1. Select Help [image] Open Example. The Open File dialog box appears, but is "targeted" on the examples directory.

2. Double-click a subdirectory name.

3. Click on the file name of the example file you want to open, then click on Open.


To Open a VEE Program File

Agilent VEE

1. Click the Open button on the VEE toolbar. The Open File dialog box appears.

The Open File dialog box looks for program files to open in the default directory
C:\My Documents\VEE Programs.
(By default, clicking the Save button saves your programs in that directory.)

Open button

Save button

2. Click on the file name of the program file that you want to open, and then click on Open. Or enter the name of a file in the File name type-in field and click on Open.


To Merge Objects and Programs from Library Files

VEE provides several library objects (pre-built UserObjects) and complete library programs that you can merge into your own VEE program.

Agilent VEE for Windows

1. Select File [image] Merge. The Merge dialog box appears.

By default, the Merge dialog box looks for library objects and programs in the directory
C:\Program Files\Agilent\VEE Pro 7.0\lib.
You can also merge any VEE program file into the work area by changing directories.

2. Click on the file name of the library file that you want to open, and then click on Open. The object is merged into your workspace. You can connect it into your program like any VEE object.


To Start a VEE Program

Agilent VEE provides several execution modes for running programs. They are VEE 3, VEE 4, VEE 5, and VEE 6. You set the mode using Default Preferences. Programs written with VEE 5.0 will, by default, run in VEE 5 execution mode. Programs written with VEE 4.x will, by default, run in VEE 4 execution mode, and older programs will run in VEE 3 execution mode. You can run older programs in newer modes, but they may not run as expected, and may need revision. VEE 3-mode programs should be revised as needed to run properly in VEE 4 mode before running them in VEE 5 or higher modes.

To start an entire VEE program, including all threads within the program, click the Run button on the VEE toolbar.

Run button

All threads within the work area will start, whether or not they have a Start object.

If you want to be able to start an individual thread in a program independently, add a Start object (under the Flow menu) to the thread. When you click on a Start object button, only the thread that contains the Start object will start.

If a thread employs feedback, the thread must contain a Junction object inside the feedback cycle to run in VEE 4 or higher execution modes. This is the only case where a Junction object is required. If you run a program that includes a thread with feedback, but no Junction object, an error is reported.

Example: Two threads, each with a Start object

If you want to run just the top thread, click on its Start button. The thread runs, displaying "Now is the time" in the AlphaNumeric object, as shown. However, the bottom thread does not run.

If you click on Start in the bottom thread, it runs, but the top thread does not.

If you click on the Run button, both threads of the program will run. In each thread, propagation begins at the Start object.

Shortcuts

Press CTRL+G on the keyboard to run a VEE program.

See also

Default Preferences


To Branch within a VEE Program

To branch the flow of execution within a VEE program, use the If/Then/Else or Conditional [image] objects found under the Flow menu.

To set up a conditional branch using the If/Then/Else object

1. Add an If/Then/Else object (from the Flow menu) to the work area.

2. Modify the conditional test expression as desired. For example, to test values to see if they are in the range "greater than or equal to 0.5 and less than 0.6", use the expression .5<=A AND A<.6. (You can use any of the logical or relational math operators supported by VEE in the expression field of an If/Then/Else object, as call UserFunctions and access global variables.)

3. Add additional data input terminals if required by your new expression. By default, there is only one data input terminal (A). If you want to test a value A against a value B (for example, A<=B), add a data input terminal named B.

4. Connect the sources of data to be tested to the data input terminals.

5. Finally, connect the Then and Else output terminals to activate different objects or subthreads in your program, as desired.

Example: Using If/Then/Else

The value output by the Random Number object is tested against the expression .5<=A AND A<.6. If the value is in the specified range, the Then output terminal activates the top AlphaNumeric object, which displays the random number as shown in the above figure. If the value is not in the specified range, the Else output terminal activates the bottom AlphaNumeric object, which displays Try Again. This example illustrates a simple case; you can use the Then and Else terminals to activate any sort of program thread. This example is saved as manual01.vee in your manual examples directory (Help [image] Open Example)

To Use the Conditional Objects

The objects under Flow [image] Conditional [image] (If A == B, If A ~= B, If A != B, If A < B, If A > B, If A <= B, and If A >= B) are really pre-defined If/Then/Else objects. Each has two data input terminals (A and B) and performs a pre-defined test comparing the value of A to the value of B. The Then and Else output terminals work just as in the If/Then/Else object. In fact, you can add or delete terminals and change the expression just as you would in an If/Then/Else object. For example, you could add a C terminal to the If A == B object and change the test to A == B OR B <= C.

Example: Adding Else If Conditions

The If/Then/Else and Conditional objects have another feature -- the Else If condition. You can add one or more Else If conditions (object menu [image] Add Else/If). Each Else If condition is tested if the previous condition is not met. For example, the following If/Then/Else object has two Else If conditions:

This object works as follows:

1. The expression 0<=A AND A<10 is evaluated, and the result is output on the Then terminal if the expression is true. (An expression is true if it evaluates to a non-zero value.)

2. Otherwise, the expression A<20 is evaluated, and the result is output on the corresponding Else If terminal if the expression is true.

3. If A<20 is false, the expression A<30 is evaluated, and the result is output on the corresponding Else If terminal if A<30 is true. If false, the result is output on the Else terminal.

See also

If/Then/Else


To Loop Part of a VEE Program

You can loop (repeat) part of your VEE program using one of the repeat objects described in the following list. You can include the Next and Break objects in a loop "hosted" by any of these objects. These are all under the Flow [image] Repeat menu.

Continue to scroll down for programming examples.

Summary of Repeat Objects

For Count

Outputs the count, starting with 0, repeating the number of times specified in the entry field. The default is 10, which causes the count to repeat 10 times, from 0 to 9.

For Range

Outputs a value on the data output pin repeatedly, starting with the value From, incrementing by the value Step on each repeat. For Range repeats until the output value is greater than the Thru value if Step is positive, or until the output value is less than the Thru value if Step is negative.

For Log Range

Similar to For Range, but on a log scale. The initial value output is From, but the nth value is From*exp10(n/(/Dec)). For Log Range repeats until the output value is greater than the Thru value if /Dec is positive, or until the output value is less than the Thru value if /Dec is negative.

Until Break

Activates its data output pin continuously until a Break object operates within the thread.

On Cycle

Outputs the current time value periodically (the default period is 1 second) until a Break object operates within the thread.

Next

Causes the loop to begin its next iteration immediately.

Break

Causes the loop to terminate immediately.

Example: A For Count Loop

In the following example, the For Count object causes the Random Number object to operate 10 times. The For Count object's sequence output pin indicates when For Count is done operating (the loop is done repeating). The Collector collects the 10 random values in an array, but doesn't output the array until the sequence output pin of For Count activates the XEQ pin on the Collector.

Example: Taking a Reading Every Second

In the following example, the On Cycle object executes every second, causing the instrument panel object for the HP 34401A Multimeter to output a reading every second. This program produces simulated readings, since live mode is OFF for the HP 34401A. Each reading is output to the Logging AlphaNumeric display, and to the If/Then/Else object. The If/Then/Else object causes the Break object to operate, stopping the loop, on the first value that is greater than or equal to 7. The sequence output line from the Logging AlphaNumeric display to the If/Then/Else object ensures that the final reading is displayed before the loop stops. The AlphaNumeric object, configured for the Time Stamp format, reports the time of each reading as it is taken. This example is saved as manual02.vee in your manual examples directory (Help [image] Open Example).

Example: Parallel and Nested Loops

In the following example, the program includes parallel loops, which run concurrently, and a nested loop. Thread 1 and Thread 2 are parallel loops. Subthread 1a is nested within Thread 1. Multiple levels of nesting are allowed.

Avoid the following situations when using loops, which can cause a propagation paradox and lead to unpredictable results. Running programs like these in VEE 4 or higher execution modes will produce an error.

1. Do not cross connect parallel loops.

2. Do not merge loops (with a JCT or Math object, for example).

See also

manual03.vee and manual04.vee in manual examples directory
Help [image] Open Example...


To Stop a VEE Program

Once you have started a VEE program, it will run according to the propagation rules until it finishes, and then stops.

Ways to stop a VEE program before it finishes propagating

Click the Stop button on the VEE toolbar.

Stop button

Click the Pause button to pause the program momentarily. Then click the Resume button to continue the program, or the Stop button to stop it.

Pause button

Resume button

Use Stop and Exit Thread objects. You can include a Stop or Exit Thread object in your program to define when it should terminate. For example, you can use an If/Then/Else object to conditionally branch to a Stop or Exit Thread object. When either of these objects operate, the program stops permanently just as though you clicked the Stop button.

Use Raise Error object. You can cause an error to occur, pausing your program, with the Raise Error object.

Shortcuts

Press CTRL+P on the keyboard to pause (not stop) a program.

Press CTRL+G on the keyboard to resume a paused program.

Note

In VEE 4 or higher execution modes, the Pause command is disabled if Disable Debug Features is turned on in Default Preferences.

See also

Default Preferences

Exit Thread

Stop

To Trap an Error


To Change Default Colors

You can change the default colors for all of your programs.

1. Click the Default Preferences button on the VEE toolbar, then select the Colors tab in the dialog box.

Default Preferences button

2. Click on the Screen Element field or its arrow. The drop-down list displays the screen element choices.

3. Click on the screen element in the list that you want to change. The drop-down list disappears and the current color for that screen element is shown in the Color Value field.

4. Click on the Color Value button. The Select Color dialog box appears displaying a palette of the available colors. The screen element's current color selection is highlighted in the palette with a dashed outline. The color is also shown in the Preview area.

5. To select a new color, click on a different color in the palette, and then click on OK to return to the Default Preferences dialog box.

6. Make color selections for multiple screen elements as needed before saving your selections.

7. Choose how you want to save the new color selection for the screen element:

a. To save the color selection as a permanent default color, click on Save. This saves the new default color in your vee.rc file. The new color will be the default for future VEE sessions (until you change it again).

b. To use the new color selection only for the current VEE session (until you select File [image] New, Open, or Exit), click on OK.

c. To use the new color selection and save it with your VEE program, click on OK, then go to File [image] Save As… and check the Save colors and fonts with program box in the Options area.

d. To cancel the new color selection, click on Cancel.

e. To discard current settings and return to the settings in the defaults file vee.rc, click on Reset.

See also

Default Preferences

Using Colors

How to Pick Colors


To Change Colors for an Object

Every object has a Properties Window that you can reach from the object menu. You can change colors for a particular object from the Appearance category of this window.

1. Click with the right mouse button on the object to open its object menu. Select Properties from the object menu, then select the Appearance category from the properties window.

The colors that you can change depend on the particular class of object. Typically, you can change the background and text in the object's title bar and open view.

2. Select the property you want to change.

3. To select a new color, click on a different color from the list.

4. The new color selection appears in the object and overrides the default color. The change affects only the selected objects, and is saved when you save the program.

Shortcuts

Double-click on the object's title bar to access its Properties window.

Note

You can change Panel View colors for the Main Window, UserObjects, and UserFunctions using Properties on their object menus. The Panel Views for each context must exist before you can change their colors. The Main Window’s panel color is also applied to the Execution Window when the program runs. UserObject and UserFunction edit windows must be open to set their Panel View colors. For details about creating Panel Views, see the VEE Help contents under How Do I … Build an Operator Interface.

See also

Using Colors

How to Pick Colors


To Change Default Fonts

You can change the default fonts for screen elements in the work area.

Note

1. Click the Default Preferences button on the VEE toolbar, then select the Fonts tab in the dialog box.

Default Preferences button

2. Click on the Screen Element field or its arrow. The drop-down list displays the screen element choices.

3. Click on the screen element that you want to change. The drop-down list disappears and the font value for that screen element is displayed.

4. Click on the Font Value button. The Select Font dialog box appears.

5. Click on the corresponding fields or their arrows to select a font name and size from the two drop-down lists. You can also select Bold and Italic by clicking on the appropriate checkboxes. Click on OK to return to the Default Preferences dialog box.

The font lists allow you to select any font that is installed on your system.

6. Make font selections for multiple screen elements as needed before saving your selections.

7. Choose how you want to save your font selection:

a. To save the new font selection as a permanent default font, click on Save. This will save the new default font in your vee.rc file. The new font will be the default for future VEE sessions (until you change it again).

b. To use the new font selection only for the current VEE session (until you select File [image] New, Open, or Exit), click on OK.

c. To use the new font selection and save it with your VEE program, click on OK, then go to File [image] Save As… and check the Save colors and fonts with program box in the Options area.

d. To cancel the new font selection, click on Cancel.

e. To discard current settings and return to the settings in the defaults file vee.rc, click on Reset.

See also

Default Preferences

Using Fonts


To Change Fonts for an Object

Every object has a Properties window that you can reach from the object menu. You can change fonts for a particular object using this window.

Note

1. Click with the right mouse button on the object to open its object menu. Select Properties from the object menu, then select the Font property you want to change.

The fonts that you can change depend on the particular class of object. Typically, you can change fonts for the Title text and the Object text.

2. Click on the property for the text you want to change. A Select Font dialog box appears.

3. Click on the corresponding fields or their arrows to select a font name and size from the two drop-down lists. The font lists allow you to select any font that is installed on your system. You can also select Bold and Italic by clicking on the appropriate checkboxes.

To use the default font set in Default Preferences, click on the Default checkbox.

Click on OK to return to the Properties window.

The new font selection appears in the object and overrides the default font. The change affects only this particular object, and is saved when you save the program.

Shortcuts

Double-click on the object's title bar to access its Properties window.

See also

Using Fonts


To Change an Object Title

1. Select Properties from the object menu. The Properties Window appears.

2. Select title from the list and enter the new title.

Shortcut

Double-click on the object's title bar to access its Properties window.

Note

You can change the title for the Execution Window using Properties on the Main Window’s object menu. A Panel View for Main must exist first. This title is used as the program name in the Program Explorer. For details about creating Panel Views, see the VEE Help contents under How Do I … Build an Operator Interface.


To Redo an Operation

An Edit menu selection that lets you Redo an operation.

Use

An Undo command reverses the outcome of an operation. You can return to the state before an Undo operation by using the Redo command

Notes

Redo is only available for operations supported by Undo. It is grayed out for all other operations.

Whenever you undo all operations and then initiate a new operation, the list redo actions is cleared.

Review the Undo topic for redo stack limitations and known anomalies.

Location

From the Object Properties menu, select Redo.

From the Main Menu, Edit > Redo or CTRL+Y

From the Task Bar,

See Also

Undo


To Undo an Operation

An Edit menu selection that lets you reverse an operation performed in VEE. Not all operations can be undone.

Use

For Detail, the following operations can be undone in Main, User Objects, and User Functions:

  • Cut a line

  • Add/Delete/Modify a terminal

  • Add/Delete a terminal in a UserObject or UserFunction

  • Object Moves, Alignment

  • Replace an Object

  • Cut/Paste an Object

  • Auto Scrolling

For Panel, the following operations can be undone in Panel, User Objects, and User Functions:

  • Object Alignment

  • Object Deletes

Notes

Undo is only available for some operations. If the icon is grayed out, there is nothing to undo or the operation is not supported by undo.

Undo is location sensitive. For example, you can undo an Formula object delete. If you are entering a formula and delete a portion, you can undo this deletion if you would like. So, you can not only undo object actions but also text actions within objects.

Undo also has a very useful Tooltip ( [image]) that gives you insight into which undo operation is available.

When all operations are undone and a new operation is undertaken, you can only undo the most current operation. All operations previous to that can no longer be undone.

Actions that will invalidate either the current detail view and/or panel view undo stacks.

Deleting or cutting objects from the detail view that have corresponding views on the panel view causes the panel view's undo stack to be invalidated.

Creating a UserFunction from the selected objects in a detail view causes the detail view's undo stack to be invalidated. If there is a panel view associated with the source detail view, it is invalidated.

Creating a UserObject from the selected objects in a detail view causes the detail view's undo stack to be invalidated. If there is a panel view associated with the source detail view, it is invalidated.

Unpacking a UserObject into a detail view causes the destination detail view's undo stack to be invalidated.

Converting a UserFunction to a UserObject causes the target detail view's (where the UserObject is placed) undo stack to be invalidated. If there is a panel view associated with the UserFunction, its undo stack remains intact.

Making a UserFunction from a UserObject causes the source (location of the UOCarrier) detail view's undo stack to be invalidated. If there is a panel view associated with the UserObject, its undo stack remains intact.

Moving objects from one context to another causes both the source and destination detail view's undo stacks to be invalidated. If there is a panel view associated with the source context and one of the moved objects was on the panel, then the source's panel view undo stack will also be invalidated.

Adding any output on a panel driver that causes the creation of multiple outputs causes the undo stack of the associated context to be invalidated.

Changing an input or output terminal in any way (which includes adding, deleting or modifying name, type or shape) causes the undo stack of the context view that contains the UserObject's UOCarrier to be invalidated.

Known Anomalies

Drop an object of the type Declare Variable, ActiveX Control or XYGraph onto a detail view and then clone it. Delete one of the objects. Now rename the remaining object so that it has the same name as the object that was just deleted. Now press undo. Notice that the restored object has a different name because the name it wanted to use already existed. It silently got a new, unique name assigned to it.

If you have one context selected, press Paste to paste objects and then paste the objects into a different context, no undo actions will be registered. This same thing will happen on a drag-clone to a different context also.

Location

Edit > Undo or CTRL+Z

From the Task Bar -

See Also

Redo and Paste


To Find Objects by Searching for Text

Use the Find dialog box (Edit [image] Find) to search for objects. Find makes it easier for you to locate objects in a large program that contains many individual objects, UserObjects, and UserFunctions. You can specify the text, and set options to limit the search. Find is also available from its toolbar button.

Find button

1. Open the Find dialog box (Edit [image] Find or use the toolbar button). The dialog box appears.

2. In the Find: edit field, enter the text you want to search for.

3. On the General tab, set the limits you want to define for the text search.

4. After setting the limits, click Find. The search begins immediately.

Click Stop to stop a search that is in progress. Results found up to that time are displayed.

5. When the search finishes, the Find dialog box closes, and the Find Results dialog box appears. Find Results contains a list of objects that match the search criteria. See To View Results of a Find Operation for information about viewing objects in the list.

The following figure shows the Find dialog box set up to search for the text upper. The options set on the General tab show that the search results will include all objects in nested UserObjects, and show all occurrences that contain upper anywhere in a text string.

Shortcut

Press CTRL+F on the keyboard to open the Find dialog box.

Notes

To limit the scope of a search as listed for Search in, use the context menus in the Program Explorer. Click with the right mouse button on a UserObject, function, or folder name to raise a context menu, then click on Find. The Find dialog box appears with the Search in field containing the context name.

Find will not search for:

Panels or objects on panels.

Lines or line values.

Terminal values.

See also

To Explore the Program Structure

To Find Objects by Searching for Properties

To View Results of a Find Operation

Find

Find Results


To Find Objects by Searching for Properties

Use the Find dialog box (Edit [image] Find) to search for objects. Find makes it easier for you to locate objects in a large program that contains many individual objects, UserObjects, and UserFunctions. You can specify text and object properties as search criteria, and set options to limit the search. Find is also available from its toolbar button.

Find button

1. Open the Find dialog box (Edit [image] Find or use the toolbar button). The dialog box appears.

2. In the Find: edit field, enter the text you want to search for. You can leave this field blank if you plan to search only for object properties.

3. On the General tab, set Search nested UserObjects to control the search limit. If you entered text in the previous step, set the other limits you want to define for the text search.

4. On the Advanced tab, you can set up to three properties and their values. This limits the search results to objects containing the specified properties and values.

a. Click on a button under Property to set a property name. The Property Name dialog box appears containing all available object properties.

Scroll through the list and select a property by double-clicking its name. The property name appears on the button.

b. The button under Value changes mode relative to the selected property. The value-selection methods include:

Select a value from a drop-down list.

Select a value from a dialog box.

Select a color from the color palette.

Type in a text or numeric value.

c. If necessary, click Reset to return to the single default setting for Property (Object Type) and Value (All Types).

5. After setting the search criteria, click Find. The search begins immediately.

Click Stop to stop a search that is in progress. Results found up to that time are displayed.

6. When the search finishes, the Find dialog box closes, and the Find Results dialog box appears. Find Results contains a list of objects that match the search criteria. See To View Results of a Find Operation for information about viewing objects in the list.

The following figure shows the Find dialog box set up to search for the text upper. The Advanced tab shows that the search results will include only those objects with the specified property values. Notice that the Adv status indicator (upper-right corner) is highlighted when you include property values in a search.

Shortcut

Press CTRL+F on the keyboard to open the Find dialog box.

Notes

To limit the scope of a search as listed for Search in, use the context menus in the Program Explorer. Click with the right mouse button on a UserObject, function, or folder name to raise a context menu, then click on Find. The Find dialog box appears with the Search in field containing the context name.

Find will not search for:

Panels or objects on panels.

Lines or line values.

Terminal values.

See also

To Explore the Program Structure

To Find Objects by Searching for Text

To View Results of a Find Operation

Find

Find Results


To View Results of a Find Operation

After using Find to search for objects containing specific text and properties, the Find Results dialog box appears with information about the matches. Find Results gives you an easy way to view the objects that were found. The results are retained until you do a new Find letting you open and close Find Results as needed (Edit [image] Find Results).

Find Results button

The following figure shows an example of Find Results listing the objects containing the text upper.

Using the Find Results dialog box

Double-click on a line in the list to bring the listed object, UserObject, or UserFunction into view in the work space. UserObject and UserFunction edit windows are opened; individual objects are highlighted.

Click on column headings to sort the list’s order.

The Keep Visible button’s default setting keeps Find Results open when you select an item to view. Click the button to toggle its state to close Find Results when you select an item.

Keep Visible button set to keep Find Results open

Keep Visible button set to close Find Results

Click the left or right arrow buttons to bring the previous or next item into view.

Previous and Next buttons

Click the Find button to open the Find dialog box, and start a new search. This closes Find Results, and clears its contents.

Find button

The Adv status indicator is highlighted when the search specified property values on the Find dialog box’s Advanced tab.

Shortcut

Press CTRL+R on the keyboard to open the Find Results dialog box.

Note

The Find Results menu item and toolbar button are grayed out until a Find is done.

The Find Results contents from a previous Find operation are cleared whenever you open the Find dialog box again.

See also

To Find Objects by Searching for Properties

To Find Objects by Searching for Text

Find

Find Results


To Explore the Program Structure

Use the VEE Program Explorer (View [image] Program Explorer) to explore a program’s entire structure. The Program Explorer makes it easy to access information, navigate a program, or change program contents. You can quickly open and close the Program Explorer by using its toolbar button.

Program Explorer button

To view the program structure

1. Open the Program Explorer. The window opens at the left side of the VEE work space.

2. Click on the controls (+ and -) to expand and contract the tree view. Depending on the program’s contents, the Program Explorer shows a complete list of the following information:

UserObject hierarchy starting at the Main UserObject.

Local UserFunctions.

Imported UserFunction Libraries and associated functions.

Imported Compiled Libraries and associated functions.

Imported Remote UserFunction Libraries and associated functions.

Global variables, both declared and undeclared.

Declared local variables under the appropriate context.

Declared library global variables under the appropriate library.

The following figure and list show the icons used by the Program Explorer to represent the various contexts, and variables:

1. Represents the entire program.

2. Represents UserObjects.

3. Represents local, imported, and remote UserFunctions.

4. Represents Compiled Functions.

5. Represents declared and undeclared Global Variables and declared Library Variables.

6. Represents local variables.

7. Represents containers for categories such as library names, Globals, and UserFunctions.

To use the context menus

The Program Explorer’s context menus give you access to objects and information in a program. To open the context menus, click with the right mouse button on an item in the list, then click on a menu choice. The menus’ contents change depending on the item.

To view or document program information, use the following menu choices if available on a particular context menu. The action for a menu choice changes relative to the item’s location in the program structure :

Print prints the program, UserObject, or function (see Print Program and Print Objects).

Document saves the program, UserObject, or function documentation (see Save Documentation)

Calls finds the UserFunctions the item calls.

Called By finds the UserObjects or functions that call the item.

View opens a dialog box with the variable’s current value.

To access the program’s contents to make changes, use the following menu items if available on the particular context menu:

Open brings the item into view in the work space. This is the same as double-clicking the item.

Find opens the Find dialog box (see Find). This also limits the scope of a search to the bounds of the highlighted item instead of the entire program.

Generate [image] lets you create one of the following objects containing an expression referencing a UserFunction title. You can place the generated object in another part of the program (see Call, Formula, If/Then/Else, ShowPanel, HidePanel)

Cut opens a Confirm dialog box, which lets you remove the item from the program.

Description opens the item’s Description dialog box (see Description).

Properties opens the item’s Properties Window (see Properties (Object)).

References finds the objects that use the variable.

Shortcuts

To view a UserObject, UserFunction or other context in the work space, double-click the context name in the Program Explorer.

To view the current value of a variable, double-click the variable name. A dialog box appears with information about the variable’s type, shape, and data.

Tip

Use Default Preferences to set the Program Explorer’s default state each time you start VEE. To always open the Program Explorer or always leave it closed, click the Program Explorer toolbar button to set the state you want, then open the Default Preferences dialog box, and click on Save.

Program Explorer button

See also

Default Preferences


Using the Keyboard Shortcuts

You can use keyboard shortcuts to perform many common VEE tasks. Note that the keyboard shortcuts are not case sensitive.

Controlling Files

To Clear the Work Area
To Open a VEE Program File
To Save a VEE Program to a File
To Save a VEE Program to a New File
To Print or Copy the VEE Window
To Exit VEE

Editing Programs

To Navigate the VEE Menu
To Raise the Function & Object Browser
To Select Objects
To Raise the Pop-Up Edit Menu
To Raise the Pop-Up Object Menu
To Edit a Formula Object’s Expression
To Edit a Transaction
To Move the Text Cursor
To Cancel an Edit in an Entry Field
To Cancel Edits in a Dialog Box
To Copy or Clone an Object or Text
To Cut an Object or Text
To Add a Data Input Terminal to an Object
To Add a Data Output Terminal to an Object
To Delete a Terminal from an Object
To Delete a Line
To Refresh the VEE Window

Navigating Programs

To View the Main Window
To Select Windows and Scroll the Work Areas
To Raise the Find Dialog Box
To Raise the Find Results Dialog Box
To Navigate an Operator Interface Panel

Debugging Programs

To Run, Pause, Step, or Resume a VEE Program
To View Data on a Line
To View Connections to an Object
To Toggle Breakpoint Settings
To Get Help on an Object or Dialog Box


To Clear the Work Area

Press CTRL+N. You will be prompted to save changes to the current program (shortcut for the New button on the toolbar, and for File [image] New).


To Open a VEE Program File

Press CTRL+O. You will be prompted for a file name to open (shortcut for the Open button on the toolbar, and for File [image] Open).


To Save a VEE Program to a File

Press CTRL+S. The program will be re-saved to the current file, or you will be prompted for a file name (shortcut for the Save button on the toolbar, and for File [image] Save). Note: Saved files may not be backward compatible. A version 5 file retrieved into version 6 and saved is no longer compatible with version 5.


To Save a VEE Program to a New File

Press CTRL+W. You will be prompted for a new file name, and the program will be saved there (shortcut for File [image] Save As). Note: Saved files may not be backward compatible. A version 5 file retrieved in version 6 and saved is no longer compatible with version 5.


To Print or Copy the VEE Window

To copy the VEE window to the MS Windows Clipboard, press Alt+Print Screen with VEE as the active window. (shortcut for the Print Screen button on the toolbar, and for File [image] Print Screen). From the Clipboard, you can paste the VEE window into other Windows applications that can use the Clipboard.

Note that these shortcuts allow you to capture the VEE screen even when a dialog box is present.


To Exit VEE

Press CTRL+E to exit VEE (shortcut for File [image] Exit).


To Add a Data Input Terminal to an Object

Press CTRL+A with the pointer in the input terminal area to insert another data input terminal at the pointer location (shortcut for: object menu [image] Add Terminal [image] Data Input). If you have just edited a field in the object, you may need to click the left mouse button first, and then press CTRL+A.

To add a terminal using CTRL+A, the Show Terminals object property must be active and the pointer must be over the input terminal area at the left side of the object.


To Add a Data Output Terminal to an Object

Press CTRL+A with the pointer in the output terminal area to insert another data output terminal at the pointer location (shortcut for: object menu [image] Add Terminal [image] Data Output). If you have just edited a field in the object, you may need to click the left mouse button first, and then press CTRL+A.

To add a terminal using CTRL+A, the Show Terminals object property must be active and the pointer must be over the output terminal area at the right side of the object.


To Cancel an Edit in an Entry Field

Press Esc to cancel an edit in a type-in entry field.


To Cancel Edits in a Dialog Box

Press Esc to cancel all edits in a dialog box (equivalent to clicking on the Cancel button).


To Copy or Clone an Object or Text

Select the object(s) or text you want to copy, then press CTRL+C. This puts the object(s) or text into the cut-copy-paste buffer (shortcut for the Copy button on the toolbar, and for Edit [image] Copy). Note: Text is copied only with CTRL+C, not with the toolbar button or menu choice.

To paste the copied object(s) into the work area, use CTRL+V (shortcut for the Paste button on the toolbar, and for Edit [image] Paste). Then click on the location where you want to put the object(s). Any lines connecting copied objects are retained. Note: Text is pasted only with CTRL+V, not with the toolbar button or menu choice.

To clone the selected object(s), while pressing CTRL, click with the left mouse button and drag the cloned object(s) to a new location.

You can copy object(s) and text from one work area, then paste into another work area. In Windows, you can also copy from one instance of VEE, then paste into another instance of VEE. Objects and text can be copied to other Windows applications that can use the Clipboard.


To Cut an Object or Text

Select the object(s) or text you want to cut, then press CTRL+X. This puts the object(s) or text into the cut-copy-paste buffer. (shortcut for the Cut button on the toolbar, and for Edit [image] Cut). Note: Text is cut only with CTRL+C, not with the toolbar button or menu choice.

You can replace an object cut by mistake using CTRL+V (shortcut for the Paste button on the toolbar, and for Edit [image] Paste). Then click on the location where you want to put the object. The object and its connections are restored. You can also undo the cut using Edit > Undo from the main menu. Note: Text is pasted only with CTRL+C, not with the toolbar button or menu choice.

Objects and text cut from one work area, can be pasted into another work area. Also, objects and text cut from one instance of VEE, can be pasted into another instance of VEE. Objects and text can be pasted into other Windows applications that can use the Clipboard.


To Delete a Line

Press and hold Shift+CTRL, and click the left mouse button with the pointer over or near the line you want to delete (shortcut for the Delete Line button on the toolbar, and for Edit [image] Delete Line). You can use Undo on this action.


To Delete a Terminal from an Object

Press CTRL+D with the pointer over the terminal to be deleted. (A shortcut for: object menu [image] Delete Terminal [image] Input or object menu [image] Delete Terminal [image] Output.) If you have just edited a field in the object, you may need to click the left mouse button first, and then press CTRL+D.

To delete a terminal using CTRL+D, the Show Terminals object property must be active and the pointer must be over the terminal to be deleted.

You can undo the deletion by pressing CTRL+Z.


To Edit a Formula Object’s Expression

The following are the editing actions available when you are entering an expression in a Formula object. In general, if you can do it in an RTF document, you can do it in the Formula object.

Press Enter to insert a carriage return, and move the cursor to the next line. Doing this in the middle of a line breaks the line and inserts characters after the cursor onto the next line. Doing this at the beginning of any line inserts a blank line above it.

Press Delete at the right end of a line to merge the next line into this line, retaining the current cursor position.

Press Backspace at the left end of a line to merge this line with the line above it, retaining the current cursor position.

The up- and down-arrows move the cursor vertically up and down the lines, retaining the cursor’s horizontal position. When the cursor is on the last line, pressing the down-arrow adds a new line. The right- and left-arrows move the cursor right and left.

From the left end of a line, Shift End highlights the entire line. From the right end of the line, a Home Shift highlights the entire line.

Page up and page down function as expected.

A double-click on a word highlights the word. A triple-click on a line highlights the entire line.

Pressing Tab when the Formula object has the focus launches the Function Object Browser and evaluates the formulas.


To Edit a Transaction

The following are some shortcuts that you can use when the mouse pointer is positioned over an object containing transactions (for example, the Sequencer or To File objects). For further information about transactions, refer to the chapter "Using Transaction I/O" in VEE Advanced Techniques.

Press CTRL+K with the pointer over a transaction to cut the transaction to the "cut-and-paste" buffer (object menu [image] Cut Trans).

Press CTRL+Y to paste a transaction from the "cut-and-paste" buffer at the pointer location (object menu [image] Paste Trans).

Press CTRL+O to insert a transaction at the pointer location (object menu [image] Insert Trans).

Press CTRL+N to move to the next transaction.

Press CTRL+P to move to the previous transaction.


To Move the Text Cursor

In alphanumeric text entry areas (for example, the Note Pad object) use the cursor-control arrow keys (up-arrow, down-arrow, left-arrow, right-arrow) to move the cursor in the direction of the arrow.


To Navigate the VEE Menu

You can navigate the VEE menu by using the keyboard menu accelerators. Each menu item has an underlined letter, which acts as an accelerator in conjunction with the Alt key. The keyboard accelerator letters are case insensitive. In other words, even though the underlined letter may be capitalized, you can use the lower case letter as the accelerator. Let's look at an example.

In the Device menu the D is underlined (but d works fine as the accelerator) and in the Data menu the t is underlined:

On the PC, press Alt+d to select the Device menu or Alt+t to select the Data menu.

Each sub-menu has its own accelerators, which you can use to navigate further down the menu tree. For example, to select Data [image] Continuous [image] Real64 Slider:

On the PC, press Alt+t, then Alt+i, then Alt+r.


To Raise the Function & Object Browser

Press CTRL+H (shortcut for the fx button on the toolbar, and for Device [image] Function & Object Browser).


To Raise the Pop-Up Edit Menu

Press the right mouse button with the pointer over an empty part of the Main Window work area. (This works for UserObject and UserFunction work areas as well.)


To Raise the Pop-Up Object Menu

Press the right mouse button with the pointer over any part of an object.


To Refresh the VEE Window

Press CTRL+Q to refresh the VEE window.


To Select Objects

To select one object, click the left mouse button with the pointer over the object. The selected object is highlighted with a shadow.

To select and un-select an object, press and hold CTRL, and click the left mouse button with the pointer over the object. The object becomes selected if it is not currently selected. If the object is currently selected, it becomes un-selected.

There are three ways to select multiple objects. Press and hold CTRL, and click the left mouse button on each object that you want to select. Or, while pressing CTRL, click and hold the left mouse button, then drag the outline box across the desired objects. Object selections are toggled.

Press CTRL+A to select all objects in the current work area (Main Window, UserObject, or UserFunction) whether they are currently selected or not (shortcut for Edit [image] Select All).


To View the Main Window

Press CTRL+M (shortcut for View [image] Main).


To Select Windows and Scroll the Work Areas

To move through a stack of open windows in the VEE work space:

Press CTRL+Tab or CTRL +F6 to move down through a stack of windows from the top.

Press CTRL+Shift+Tab or CTRL+Shift+F6 to move up through a stack of windows from the bottom.

With the pointer anywhere within the work area of the Main, a UserObject, or a UserFunction window:

Press Shift+up-arrow, Shift+down-arrow, Shift+left-arrow, or Shift+right-arrow) to scroll the work area in the direction of the arrow key.

Press Page Down to scroll the work area up one screen.

Press Page Up to scroll the work area down one screen.

Press Shift+Page Down to scroll the work area left one screen.

Press Shift+Page Up to scroll the work area right one screen.

Press Home to move the upper left corner of the program to the upper left corner of the work area.

Press Shift+Home to move the lower right corner of the program to the lower right corner of the work area.


To Raise the Find Dialog Box

Press CTRL+F (shortcut for the Find button on the toolbar, and for Edit [image] Find).


To Raise the Find Results Dialog Box

Press CTRL+R (shortcut for the Find Results button on the toolbar, and for Edit [image] Find Results). This command is available after a successful Find operation.


To Navigate an Operator Interface Panel

If you or another VEE programmer have created an operator interface panel view in a VEE program, you can navigate the panel with the following keys:

Press Tab and Shift+Tab to move from one field in the operator interface panel to the next. The Tab key moves focus forward, and Shift+Tab moves focus backward from field to field. When a type-in field has focus (indicated by an inverse highlight), you can edit it. When a button has focus (indicated by a dashed outline), you can "push" it as described below.

Press the space bar to "push" a button that currently has focus.

Use the appropriate alphanumeric keys to edit a type-in field that currently has focus. Press Enter or Return to complete and accept the edit, or press Esc to abort the edit.

Press Enter or Return to "push" the default button in the operator interface panel, if one has been defined by the programmer.

Operator interface panel views and how to use them are covered in detail in VEE Help under How Do I... Build an Operator Interface.


To Run, Pause, Step, or Resume a VEE Program

Press CTRL+G (or F5) to run a VEE program (shortcuts for the Run button on the toolbar, and for Debug [image] Run/Resume).

Press CTRL+P to pause a running VEE program (shortcut for the Pause button on the toolbar, and for Debug [image] Pause). (To stop a program, you must click the Stop button on the toolbar.)

Press F10 to step a paused VEE program (shortcut for the Step Over button on the toolbar, and for Debug [image] Step Over).

Press CTRL+T (or F11) to step a paused VEE program (shortcuts for the Step Into button on the toolbar, and for Debug [image] Step Into).

Press Shift-F11 to step a paused VEE program (shortcut for the Step Out button on the toolbar, and for Debug [image] Step Out).

Press CTRL+G to resume a paused VEE program (shortcut for the Resume button on the toolbar, and for Debug [image] Run/Resume).


To View Data on a Line

Click the left mouse button with the pointer over the line you want to probe (shortcut for Debug [image] Line Probe). Information about the last container of data on the line is displayed.


To View Connections to an Object

Press and hold Shift, and click the left mouse button with the pointer over the object you want to probe (shortcut for Debug [image] Object Probe). All lines and objects connected to the probed object are highlighted.


To Toggle Breakpoint Settings

Select one or more objects, then press CTRL+B (shortcut for the Toggle Breakpoint button on the toolbar, and for Debug [image] Toggle Breakpoint).

The breakpoint for each selected object is switched to the opposite state.


To Get Help on an Object or Dialog Box

When an object is selected, press F1 to open the Help topic for that object (shortcut for: object menu [image] Help). If several objects are selected, the Help topic opens for the object that was selected first. If no objects are selected, the main Help Contents window opens.

When a dialog box, such as Default Preferences is open, press F1 to open the Help topic for that dialog box (shortcut for clicking on the Help button).


To Enter a Number

You can enter a number in any VEE numeric-entry field using the conventions shown in the following examples. The hyphen (-) is used as a minus sign and the period (.) is used as a decimal point. You can include a plus sign (+) in a numeric entry field if desired. Notice that the comma (,) is not allowed as a separator. (Text-entry fields accept any arbitrary string of characters.)

Ordinary numeric entry

1001

1020768 (But not 1,020,768)

12.12

-1.223

Exponential numeric entry

1.23E3 (Equivalent to 1.23x10^3 or 1230)

6.0225E23 (Equivalent to 6.0225x10^23)

6.6256E-27 (Equivalent to 6.6256x10^-27)

Numeric entry using the ISO abbreviations

1.23k (Equivalent to 1.23x10^3 or 1230)

3.61M (Equivalent to 3.61x10^6)

2.3n (Equivalent to 2.3x10^-9)

The following table lists the ISO abbreviations recognized by VEE for entering a number.

Abbreviation Suffix Multiple

X exa 10^18

P peta 10^15

T tera 10^12

G giga 10^9

M mega 10^6

k or K kilo 10^3

m milli 10^-3

u micro 10^-6

n nano 10^-9

p pico 10^-12

f femto 10^-15

a atto 10^-18

VEE may change the form of the number you enter to another, equivalent form. For example:

+1.23 becomes 1.23 (plus signs are dropped)

6.3E-9 becomes 6.3n

6.0225E23 becomes 602.25E21 (in the standard number format)

See also

To Change the Number Format


To Change the Number Format

You can change the default global number format that VEE uses for all objects that display numbers, and you can change the number format for certain individual objects that display numbers.

To Change the Global Number Format

1. Select Default Preferences from the File menu. Then select the Number tab in the dialog box.

2. Select the desired number format by changing the appropriate fields:

a. Integer determines the number base for integers: Decimal, Octal, Hexadecimal, or Binary. (Click on the field or its arrow for the drop-down list.)

b. Real determines the format of real numbers: Standard, Fixed, Scientific, or Engineering. (Click on the field or its arrow for the drop-down list.)

c. Significant digits determines the number of significant figures (limit is 18). Type in the desired number.

3. Choose how you want to save your changes:

a. Click on Save to save the changes as new defaults in vee.rc.

b. Click on OK to use the changes for this VEE session only (until you select File [image] New, Open, or Exit).

To Change the Number Format for Certain Objects

You can select a number format independently for the following objects. The selected number format overrides the global number format, but only for the particular object.

Numeric sliders and knobs on menu Data [image] Continuous

Constants on menu Data [image] Constant

AlphaNumeric on menu Display

Logging AlphaNumeric on menu Display

Fill Bar, Meter, Tank, and Thermometer on menu Display [image] Indicator

XY graphical displays on menu Display

1. Select Properties from the object menu of the object, then click on the Number Format.

2. Click on the checkbox to turn off Global Format. Then, click on the number format field (or its arrow) to show the drop-down menu.

3. Select the number format you want the object to use, then click on OK.


To Change the Trig Mode

In VEE, trigonometric values may be entered and displayed in degrees, radians, or gradians, depending on the trig mode.

The new trig mode you choose is active for the duration of the current VEE session. When you restart VEE, the trig mode reverts to the default (Degrees). Each context (Main, UserObject, and UserFunction) has its own trig mode setting.

1. Open the object menu for the Main, UserObject, or UserFunction Window, then choose Properties.

2. Select Trig Mode and choose (Degrees, Radians, or Gradians).

Note

All internal calculations are done in radians. You'll get slightly faster performance if you set the trig mode to Radians because VEE won't need to make the conversion to radians and back.

Shortcut

Double-click the Main, UserObject, or UserFunction Window’s title bar to access the Properties dialog box.


To Use a Data Constant

VEE provides several types of data constants. To use a scalar data constant:

1. Select a data constant object (Data [image] Constant [image]). The choices are Text, UInt8, Int16, Int32, Real32, Real64, Coord, Complex, PComplex, Date/Time, and Record.

2. Enter the appropriate type of data in the constant object. The most common types are the Text, Int32, and Real64 constant objects:

a. In the Text constant, you can enter any text string (the maximum length is 32,767 characters).

b. In the Int32 constant, you can enter any 32-bit, two's-complement integer (the range is -2147483648 through +2147483647).

c. In the Real64 constant, you can enter any 64-bit real number (the range is ±1.7976931348623157E308).

In the example below, the Text, Int32, and Real64 constant objects are connected into VEE program threads. Data types are automatically converted as needed by the object receiving the data. In this example, the integer 3 is converted to a real, and added to 6.24 resulting in the real value, 9.24.

See also

To Create an Array Constant

To Use a Data Slider

To Use a Data-Selection Object

To Use a Data Input Dialog Box

Converting Data Types on Input Terminals


To Use a Data Slider

To Use a Data Slider and Knob

VEE provides four types of data slider and knob objects: the Real64 Slider, Int32 Slider, Real64 Knob and Int32 Knob. These objects allow you to input a value in your program by moving a linear slider or circular knob.

To use a Real64 Slider or Int32 Slider

1. Select Data [image] Continuous [image] Real64 Slider or Int32 Slider, and place the object in the work area. By default the Real64 Slider object has a range of 0 through 1; the Int32 Slider range is 0 through 100.

2. Change the current value (displayed in the field at the top) using any of three ways:

a. Click and hold on the slider knob while moving it up or down.

b. Click on the spin-field arrows beside the value.

c. Click on the value and type a new one.

3. To change the range, click on the upper or lower limit field and type in the value.

To use a Real64 Knob or Int32 Knob

1. Select Data [image] Continuous [image] Real64 Knob or Int32 Knob, and place the object in the work area. By default the Real64 Knob object has a range of 0 through 1; the Int32 Knob range is 0 through 100.

2. Change the current value (displayed in the field at the bottom) using any of three ways:

a. Click and hold on the circular knob while turning it around.

b. Click on the spin-field arrows beside the value.

c. Click on the value and type a new one.

3. To change the range, click on the upper or lower limit field and type in the value.

See also

Int32 Knob

Int32 Slider

Real64 Knob

Real64 Slider


To Use a Data-Selection Object

VEE provides six types of data-selection objects: Radio Buttons, Cyclic Button, List, Drop-Down List, Pop-Up List, and Slider List.

To use a data-selection object

(This procedure describes the Radio Buttons object, and applies to all six types of data-selection objects.)

1. Select Data [image] Selection Control [image] Radio Buttons and place the object in the work area. Note that the default radio button selections are Item 1, Item 2, and Item 3.

2. To change the default selections, select Edit Enum Values from the object menu. The Edit Enum Values dialog box appears.

3. Edit the values as needed. Use Tab (or down-arrow) to advance, Shift+Tab (or up-arrow) to back up among the fields. You can replace the text in each field or, to add fields, tab past the last field and type in additional text.

4. When you are finished editing the fields, click on OK.

To change a data-selection object type

1. Select Properties from the object menu. The Selection Control Properties dialog box appears.

2. On the General tab, click on the Format type you prefer, then click on OK.

See also

Selection Control


To Use a Data Input Dialog Box

Three of the built-in dialog box objects under Data [image] Dialog Box let you prompt for data input in a program. They are Text Input, Int32 Input, and Real64 Input.

(This procedure describes a Real64 Input dialog box object, and applies similarly to the Int32 Input and Text Input objects.)

1. Add a Real64 Input dialog box object to the work area (Data [image] Dialog Box [image] Real64 Input).

When the Real64 Input object operates, it displays a pop-up dialog box requesting a real number from the user. You can set the following parameters:

a. Prompt/Label determines the message displayed in the dialog box.

b. Default Value determines the optional default value to be displayed in the dialog box.

c. Value Constraint determines the range or other test that the value entered must match.

d. Error Message determines the error message to be displayed if the user responds with data that fails the test in Value Constraint.

2. Change the Prompt/Label field to Please enter a real value.

3. Run the program. The pop-up dialog box appears.

4. Enter 11 in the dialog box and click on OK. An error message appears.

5. Click on OK in the error message box. Now enter a number in the range 0 through 10 in the Real64 Input dialog box, and click on OK. The number is accepted and output on the Value terminal.

See also

Dialog Box

About Built-In Dialog Box Objects


To Enter a Formula

The basic mathematical object in VEE is the Formula object:

When placed in the work area, the object contains a preset expression and has one data input terminal, A. Note that variable A in the expression corresponds to data input terminal A.

Each variable in an expression is replaced by data on the input terminal with the same name as the variable. Variable names and terminal names are not case-dependent. In the expression a+1, the variable a corresponds to terminal A.

A variable in an expression must have a corresponding input terminal, or an error results. If you use a global variable, no corresponding terminal is required.

To use the Formula object

1. Add the Formula object to the work area (Device [image] Formula).

2. Click on the expression field in the Formula object and modify the expression as desired. For example, enter the expression 2*A+abs(B)+sin(C)+6. You can enter one or more expressions on multiple lines by pressing Enter.

3. Add data input terminals as required. (Place the pointer in the data input terminal area and press Ctrl+A.) Delete any unused data input terminals. (Place the pointer over the terminal and press Ctrl+D.)

4. Connect all of the data input terminals to appropriate sources of data, and the Result data output terminal to a display object, to complete your program.

Example

The following program uses the Formula object to evaluate an expression and display the result: Notice that the expression is split between terms across multiple lines.

See also

To Create a Variable

Formula

Processing Data


To Use the Math Operators and Functions

Over 150 built-in mathematical objects are provided with VEE in the form of operators and functions. These are really Formula objects that have been pre-configured with a descriptive title, an expression, and the appropriate data input terminals. To access the operators and functions use the Device [image] Function & Object Browser or the toolbar button.

Function & Object Browser button

You can modify the math objects as follows:

1. Change the expression to any valid VEE expression.

2. Change the title to describe the new expression.

3. Add or delete data input terminals as required.

Tips

1. Don't use several formula objects to "wire" an expression. Instead, combine the mathematical operators and functions into a single expression in a single object. VEE programs run faster when fewer objects are used.

Don't do this:

Do this instead:

2. When changing the expression, be sure to have corresponding input terminals for variable names.

3. When changing the names of the data input terminals (just double-click on the terminal and type in a new name), be sure you change the corresponding variable names in the expression as well.

4. Before minimizing the object to its icon, be sure to change the title to describe what the new mathematical expression does. It is good programming practice to change object titles all the time.

See also

Processing Data


To Use Mixed Data Types in an Expression

VEE automatically converts data types as needed, so you can use expressions containing mixed data types. Just enter the expression in a mathematical object and connect the data sources to the appropriate data input terminals.

Example

In the following program, the Formula object receives waveform data on input terminal A and real data on input terminal B. The Formula object evaluates the expression abs(A)+B by adding the real value 0.75 to the absolute value of each of the 256 points in the waveform.

See also

Processing Data


To Use an Expression in an If/Then/Else Object

VEE can evaluate mathematical expressions and branch program flow according to the result. The basic conditional object is the If/Then/Else object.

You can change the default expression in the If/Then/Else object to any conditional expression, or use the objects found under Flow [image] Conditional. The Conditional objects are really If/Then/Else objects pre-configured with expressions, descriptive titles, and data input terminals.

To use the If/Then/Else object

1. Add the If/Then/Else object to the work area (Flow [image] If/Then/Else).

2. Click on the expression field in the If/Then/Else object and modify the expression as desired. For example, enter the expression A==B OR B>=C.

3. Add data input terminals as required. (Place the pointer in the data input terminal area and press Ctrl+A.) Delete any unused data input terminals. (Place the pointer over the terminal and press Ctrl+D.)

4. Connect all of the data input terminals and one or both of the data output terminals to complete your program. If the expression is "true," the result of the expression (generally a 1) is output on the Then terminal. If the expression is "false" a 0 is output on the Else terminal.

5. If desired, add Else If conditions to the object.

Example

In the following program, if the expression A==B OR B*C==50 is true, the Then output terminal activates UserObject1. If the expression is false, the Else output terminal activates UserObject2.

See also

To Branch within a VEE Program

Conditional

If/Then/Else

Processing Data


To Use an Expression in a Transaction

VEE mathematical expressions can be evaluated and used in I/O transaction objects, such as the To File and From File objects.

Example of evaluating an expression in a To File transaction

1. Add a To File object to the work area (I/O [image] To [image] File).

2. Double-click on the transaction WRITE TEXT a EOL. The I/O Transaction dialog box appears.

3. Click on the default expression, a, and change the expression to a+sin(b):

4. Click on OK to save the new transaction (WRITE TEXT a+sin(b) EOL).

5. Add a B data input terminal to the object, and connect the data input terminals.

In the following program, the To File object adds the value of a (1) to the value of sin(b) (the sine of 30 degrees is 0.5), and outputs the result 1.5 to the file named myFile.

See also

Formula, From File, To File

Processing Data

VEE Advanced Techniques; chapter: "Using Transaction I/O"


To Find the Length of a String

1. Add the strLen(str) object to the work area using the Function & Object Browser - on the toolbar, click on

2. Connect the source of string data to the str data input terminal. Connect the Result output as desired.

3. Run the program. When the strLen(str) object operates, the length of the string is output on the Result terminal.

Examples

The strLen(str) object outputs the length of the string in bytes as an Int32 number. If str is a one-dimensional string array, strLen(str) returns an array which contains the length of each element of the array:

See also

strLen(str)


To Obtain a Substring

Two functions let you obtain a substring:

strFromThru(str,from,thru)
strFromLen(str,from,len)

Where:

str is the original string.

from is the position where the substring starts.

thru is the position where the substring stops.

len is the length of the substring.

All character positions in a string are zero-based. That is, the first character is at position 0.

To obtain a substring using strFromThru(str,from,thru)

1. Add the strFromThru object to the work area using the Function & Object Browser.

On the toolbar, click on [image] then look under
Type: Built-in Functions
Category: String
Member: strFromThru

2. Connect the source of string data to the str input terminal.

3. Specify the from and thru values:

a. Connect data to the from and thru input terminals,

or

b. Change the expression to explicitly specify from and thru. For example, the expression strFromThru(str,0,5) returns characters 0 through 5 (the first six characters) of string str. Remember to delete the from and thru terminals if you do this.

Example

The following program returns the first six characters of the string:

See also

strFromLen (str,from,len)

strFromThru (str,from, thru)


To Concatenate Strings

You can use addition (+) and multiplication (*) in VEE to concatenate strings.

Examples

You can concatenate two strings:

You can concatenate a string and a number (the number is converted to a string):

You can multiply a number and a string to repeatedly concatenate the string:

See also

Accumulator

Concatenator


To Compare Two Strings for Equality

Example

The following program compares two strings for equality using a conditional object. If the two strings are exactly the same (including spaces), the result of the expression (in this case, a 1) is output on the Then terminal. Otherwise, a 0 is output on the Else terminal. This comparison is case-sensitive (Now is not equivalent to now).

See also

Conditional

strPosStr (str1,str2)


To Convert a Number into a String

You can convert a number into a string using To String. The following procedure shows how to convert the current time in seconds into a string in the time stamp format:

1. Add a To String object to the work area (I/O [image] To [image] String). Double-click on the icon to show the open view object.

2. Double-click on the default transaction WRITE TEXT a EOL. The I/O Transaction dialog box appears.

3. Click on DEFAULT FORMAT (or its arrow) to show the drop down menu. Select TIME STAMP FORMAT and click on OK.

4. Add a now()object using the Function & Object Browser.

On the toolbar, click on [image] then look under
Type: Built-in Functions
Category: Time & Date
Member: now

Connect the now() to the data input terminal and an AlphaNumeric display to the data output terminal of To String.

5. Run the program. The now() object outputs the time in seconds. This value is converted to the time stamp format and displayed.

See also

intToChar(a)

To String

VEE Advanced Techniques; chapter: "Using Transaction I/O"


To Convert a String into a Number

If a string includes numeric information that can be read as a number, you can use From String to extract the number.

1. Add a From String object to the work area (I/O [image] From [image] String). Double-click on the icon to obtain the open view object. The default transaction is READ TEXT x REAL64, which reads the string as text and outputs a real number if possible.

2. To view the results, connect a Text constant object to the data input terminal, and an AlphaNumeric display to the data output terminal.

3. Enter the string Item number: A1222 in the Text constant and run the program. The real number value 1222 is output to the display.

See also

charToInt(a)

From String

VEE Advanced Techniques; chapter: "Using Transaction I/O"


To Create an Array Constant

You can create one-dimensional arrays using the data constant objects, such as Text, Int32, and Real64. Use this technique when you want to manually set each value in a one-dimensional array.

To create a one-dimensional text array with nine elements

1. Add a Text constant object to the work area (Data [image] Constant [image] Text).

2. Select Properties from the object menu. The Text Constant Properties dialog box appears. By default the Text constant object is configured as a Scalar.

3. To set the array size, click on 1D Array under Configuration, then click on the Size field and change it to 9.

4. To have a fixed number of elements, click on the Size Fixed checkbox as well. If you want to add additional elements on at the end, leave Size Fixed unselected.

5. Click on OK. The Text constant object appears as an array with elements 0000: through 0008:. VEE arrays are zero-based.

6. To set each value, click to the right of 0000: and type in the first element of your array. Use Tab (or down-arrow) to advance, Shift+Tab (or up-arrow) to back up among the array elements. Type in text strings for each of the elements.

Example of a nine-element, one-dimensional text array

See also

Constant

To Allocate an Array

To Build an Array in an Expression


To Allocate an Array

You can allocate arrays when you want to create them and set their values programmatically. You can create arrays of one or more dimensions.

Use the appropriate object, found under Data [image] Allocate Array, for the data type you are using. These objects include Alloc Text for text arrays and Alloc UInt8, Alloc Int16, Alloc Int32, Alloc Real32, Alloc Real64, Alloc Coord, Alloc Complex, and Alloc PComplex for numeric arrays.

Tips

All VEE array indexes are zero based. That is, the first element has index 0 in any dimension.

Allocated arrays can be 1 to 10 dimensions, and are usually "filled" with a repeated initial value.

An array of values is passed from object to object as a single data container.

Only one-dimensional integer and real arrays can be initialized with a linear or logarithmic ramp of values.

The memory required to allocate an array is determined by the number of dimensions, the sizes of the dimensions, and the data type.

The following procedures show how to allocate various types of arrays:

To Allocate a One-Dimensional Real Array

1. Add an Alloc Real64 object to the work area (Data [image] Allocate Array [image] Real64).

2. By default the Alloc Real64 object allocates a one-dimensional array with a linear ramp of values. Click on the Lin Ramp field (or its arrow) to show the drop-down menu.

3. You can select Init Value, Lin Ramp, or Log Ramp. Click on Log Ramp to select a logarithmic ramp of values.

4. Connect an XY Trace display object to the Alloc Real64 object and run the program.

To Allocate a Two-Dimensional or Larger Real Array

1. Add an Alloc Real64 object to the work area (Data [image] Allocate Array [image] Real64).

2. By default the Alloc Real64 object allocates a one-dimensional array with a linear ramp of values. Click on the Num Dims field (or its arrow) to show the drop-down menu.

3. Click on a dimension size from 2 through 10. The object adjusts to the new setting.

4. Change the size for the first dimension to 4, for the second to 3, and so on for each dimension. Then connect an AlphaNumeric display object to the output of the Alloc Real64 object.

5. Run the program. If Num Dims is set to 2, then resize the AlphaNumeric object to show the entire array. If Num Dims is greater than 2, the AlphaNumeric object displays the array size, since VEE display objects cannot display more than two dimensions.

To display more than two dimensions, you can use the To File object’s CONTAINER encoding to export data directly into PV-WAVE for visual data analysis.

More computer memory is used as you allocate larger arrays. Beyond five dimensions, you may need to declare smaller size parameters if your computer has the recommended amount of memory. If an array is too large, the VEE process may run out of memory, resulting in an error.

See also

To Build an Array in an Expression

To Change Values in an Array

To Create an Array Constant

To Collect Data into an Array

Allocate Array

To File


To Change Values in an Array

You can change values programmatically in an allocated array using an assignment operator such as a[2]=b. By modifying the assignment object’s formula and available terminals, you can assign new values to specific array locations, and use the output in other parts of your program.

To Set a New Value in a One-Dimensional Real Array

1. After adding an array allocation object (Data [image] Allocate Array [image]), add the assignment operator a[2]=b to the work area using the Function & Object Browser

On the toolbar, click on [image] then look under
Type: Operators
Category: Assignment
Member: a[2]=b

2. Change the assignment operator’s formula to a[b]=c, and add a data input terminal.

3. Connect values to the following assignment operator pins:

a. Connect the Array data output pin of the Allocate Array object to the a data input pin of the assignment operator.

b. Connect a value to the b data input pin to identify the array location. An object such as an Int32 data constant can supply this input value.

c. Connect a value to the c data input pin. This is the new value you want to assign to the array location.

The following example program shows the connections. The assignment operator accepts array data on input pin a, then assigns the real value on input pin c to the location identified on input pin b. Output pin Result contains the new value, and output pin a contains the modified array.

See also

manual06.vee and manual07.vee in manual examples directory
Help [image] Open Example...

To Allocate an Array

Set Values

See Examples

Manual06.vee and Manual07.vee


To Extract Values from an Array

You can use the Get Values object to extract values from an array:

1. Add a Get Values object to the work area (Data [image] Access Array [image] Get Values). Double-click on the icon to show the open view object.

2. Connect any data source that outputs an array to the Ary data input terminal on Get Values. When Get Values operates, the SubAry terminal outputs a sub-array that depends on the expression in the Get Values expression field. The default expression Ary causes the entire original array to be output.

The rest of the data output terminals give information about the original array on the Ary terminal:

a. Type outputs the data type of the array.

b. NumDims outputs the number of dimensions in the array.

c. DimSizes outputs a one-dimensional array listing the size (the number of elements) of each dimension.

d. TotSize outputs the total size of the array (the total number of elements).

See also

manual08.vee

To Build an Array in an Expression

To Use Arrays or Array Elements in Expressions

Get Values


To Collect Data into an Array

Use the Collector to collect data into an array of unknown size. The following procedure builds an example program demonstrating the Collector. Use the Sliding Collector for 1D array data collection.

1. Add a Collector object to the work area (Data [image] Collector). Double-click on the icon to show the object’s open view.

2. Add the For Count, random, and AlphaNumeric objects to the work area and connect the pins as shown in the following program:

3. Run the program. (Resize the AlphaNumeric display to show the entire array.)

The Sliding Collector (Data [image] Sliding Collector) differs from the Collector in two significant ways:

1. The output is always a one-dimensional array.

2. There is no XEQ terminal. Instead, the Sliding Collector is set to trigger after a specified number of values.

See also

To Build an Array in an Expression

Collector

Sliding Collector

See Example

Manual09.vee


To Use Arrays or Array Elements in Expressions

The topic To Extract Values from an Array explains that you can use an expression in a Get Values object to specify a sub-array. This topic explains how you can also specify an array or sub-array in an expression in any VEE object that has an expression field such as a Formula object.

In an expression, any reference to an array uses the following syntax:

Brackets [ ] are used after the array name to enclose the parameters specifying a sub-array. For example, if B is a two-dimensional array, B[0,0] specifies the first element in it.

The comma (,) separates array dimensions. Each sub-array operation must have exactly one specification for each array dimension.

The colon (:) separates a range of elements within one of the array dimensions.

The asterisk (*) is a wild-card character to specify all elements from a particular array dimension.

Note that all VEE array indexes are zero based. That is, the first element has index 0 in any dimension.

Examples

Assume A is a one-dimensional array, 10 elements long:

0: 100m

1: 0.2

2: 0.3

3: 0.4

4: 0.5

5: 0.6

6: 0.7

7: 0.8

8: 0.9

9: 1

The following expressions extract portions of array A:

A or A[*] returns the entire array A.

A[1] returns a scalar, which is the second element (index 1) in A:

0.2

A[1:1] returns a one-dimensional array with only one element, which is the second element (index 1) in A:

0: 0.2

A[0:5] returns a one-dimensional array that contains the first six elements (indexes 0 through 5) of A:

0: 100m

1: 0.2

2: 0.3

3: 0.4

4: 0.5

5: 0.6

A[2:*] returns a one-dimensional array that contains the third element through the end of the array; in this case, indexes 2 through 9 of A. (The indexes are redefined as 0 through 7 in the subarray.)

0: 0.3

1: 0.4

2: 0.5

3: 0.6

4: 0.7

5: 0.8

6: 0.9

7: 1

Assume B is a 5-by-5 matrix (a two-dimensional array):

 | 0: | 1: | 2: | 3: | 4:
0: | 0 | 0.2 | 0.4 | 0.6 | 0.8
1: | 1 | 1.2 | 1.4 | 1.6 | 1.8
2: | 2 | 2.2 | 2.4 | 2.6 | 2.8
3: | 3 | 3.2 | 3.4 | 3.6 | 3.8
4: | 4 | 4.2 | 4.4 | 4.6 | 4.8

The following expressions extract portions of array B:

B or B[*,*] returns the entire array B.

B[*] returns an error because it specifies only one dimension, and B is a two-dimensional array.

B[1,2] returns a scalar value from the second row (index 1), third element (index 2):

1.4

B[1,*] returns all of the second row (index 1) as a one-dimensional array:

0: 1

1: 1.2

2: 1.4

3: 1.6

4: 1.8

B[1,1:*] returns all of the second row (index 1), except for the first element (index 0), as a one-dimensional array:

0: 1.2

1: 1.4

2: 1.6

3: 1.8

See also

To Extract Values from an Array

To Build an Array in an Expression


To Build an Array in an Expression

You can also build an array by specifying portions of other arrays in an expression. However, within an expression, all sub-arrays specified must have the same number of dimensions and contain the same number of values in each dimension.

Assume B is a 5-by-5 matrix (a two-dimensional array):

 | 0: | 1: | 2: | 3: | 4:
0: | 0 | 0.2 | 0.4 | 0.6 | 0.8
1: | 1 | 1.2 | 1.4 | 1.6 | 1.8
2: | 2 | 2.2 | 2.4 | 2.6 | 2.8
3: | 3 | 3.2 | 3.4 | 3.6 | 3.8
4: | 4 | 4.2 | 4.4 | 4.6 | 4.8

The expression [B[1,1],B[2,2],B[0,0],B[2,3]] returns the following one-dimensional array:

0: 1.2

1: 2.4

2: 0

3: 2.6

You can also build an array constant in an expression. For example, the expression [1.1,1.3,1.2] creates a three-element, one-dimensional real array:

0: 1.1

1: 1.3

2: 1.2

See also

To Extract Values from an Array

To Use Arrays or Array Elements in Expressions


To Create a Record Constant

The best way to see how to create a record constant is to try an example as shown below.

To create a single record

1. Add a Record constant object to the work area (Data [image] Constant [image] Record).

2. Note that the Record constant is unlike any of the other constant objects. It has two named fields (A and B by default), each of which has a type-in field. Click on the button labeled A. The Record Field Attributes dialog box appears.

3. You can change the name of the field by typing in a new name in place of A. Change the field name to Name, but leave the data type set to Text and the number of dimensions set to 0 (scalar). Click on OK.

4. Now click on the button labeled B. Change the field name to Empl_No, and then click on Real64 (or the arrow) to show the drop-down menu.

5. Click on Int32 to select the integer data type, but leave the number of dimensions set to 0. Click on OK.

6. Enter John Doe in the type-in field next to Name, and enter 111222 in the type-in field next to Empl_No, as shown below. Connect an AlphaNumeric display object to the output pin, and run the program:

To create an array of records

1. Continuing with the previous procedure, select Properties from the object menu of the Record constant.

2. Now click on the radio button in front of 1D Array to convert the Record constant into an array of records. Set the Size to 3, and then click on OK. The object changes format.

3. The First, Prev, Next, and Last buttons let you scroll through the array of records. To change each record in the array:

a. Click on Next to scroll to the second record. Change the name to Sue Smith and the number to 111223.

b. Click on Next to scroll to the third (and last) record. Change the name to Richard Roe and the number to 111224.

4. Now run the program. Re-size the AlphaNumeric display to show the entire array of records:

See also

To Collect Data into a Record

Record Constant


To Collect Data into a Record

Use the Build Record (Data [image] Build Data [image] Record) object to build large arrays of records. This topic uses an example program to show how to use the object.

Example

1. Open the program manual10.vee and run the program.

The Build Record object builds a record from the data on its data input terminals and outputs a record on its Record output terminal. The program works as follows:

The Text array on input A is a list of names.

The Int32 array on input B is a list of employee numbers.

The Build Record object is set for an output shape of Scalar, so it outputs the scalar record {<Text Array 1D>, <Int32 Array 1D>} consisting of two record fields, each containing a one-dimensional array. The first record field is the array of names, and the second is the array of employee numbers. The input arrays need not be the same size.

2. Though Scalar is the default, you can change the output shape:

a. Click on Scalar to display Array 1D.

b. Run the program. An array of records appears in the display.

The Build Record object matches each name and employee number to form an individual record in the array of records to be output on the Record terminal. When the output shape is set to Array 1D, the input arrays must be of the same size.

See also

Build Record


To Extract a Field from a Record

To Extract Fields from a Record

Use the rec.field object (Data [image] Access Record [image] Get Field) to extract a field from a record, and use the UnBuild Record object (Data [image] UnBuild Data [image] Record) to extract all fields. This topic uses example programs to show how to use the objects.

Get Field Example

Open the program manual11.vee from your manual examples directory (Help [image] Open Example...), and run the program.

The Build Record object builds a record consisting of field A (a waveform), and field B (a scalar).

The upper rec.field object uses the expression rec.A to extract "field A of record rec" (the waveform), which is displayed by the Waveform object.

The lower rec.field object uses the expression rec.B to extract "field B of record rec" (the time), which is displayed by the AlphaNumeric object using the time stamp format.

UnBuild Record Example

Open the program manual12.vee from your manual examples directory (Help [image] Open Example...), and run the program.

The Build Record object builds a record consisting of field A (a waveform), and field B (a scalar).

The UnBuild Record object extracts fields A and B, then outputs the data on their respective pins.

See also

To Use a Record in an Expression

Get Field

SubRecord

UnBuild Record


To Change a Field in a Record

Use the assignment operator object from Data [image] Access Record [image] Set Field to change a field in a record or in an array of records. This topic uses example programs to show how to use the object.

Change Field in Record Example

Open the program manual13.vee and run the program.

In the assignment operator titled Set Name Field, the expression means: Let field Name of record Rec be equal to the value on data input terminal A. The record is connected to the rec data input terminal.

In the assignment operator titled Set Empl_no Field, the expression means: Let field Empl_no of record Rec be equal to the value on data input terminal A.

The record continues through to the display as field changes are made.

Change Field in Array of Records Example

In the following program, the expression Rec[5].Name = A specifies that array element 5 in the Name field of record Rec is to be set equal to the data on input terminal A.

See also

Set Field


To Use a Record in an Expression

You can use the record syntax Rec.Field, where Field is the name of a field within record Rec, in any VEE expression field. In the following program the expression (A.High + A.Med)/A.Low adds fields High and Med of record A, and divides the result by field Low.

Tips

To avoid confusion, give your record fields descriptive names.

You can combine the record syntax with array syntax to access an array element from a record field.

See also

manual14.vee in manual examples directory Help [image] Open Example...

Processing Data


To Create a Variable

You can create a variable that is declared or undeclared, and as local or global. An undeclared variable is created when you assign a value to it in an expression in an object such as Formula, or by using the Set Variable object. However, declaring a variable before assigning it a value has several advantages. These include scope, faster program execution speed, and preservation of a variable’s data type and shape.

To create an undeclared local variable

An undeclared local variable is created when data on an object’s data input terminal is used in an expression. This variable is local to the object. The variable name in the expression must match the input terminal’s name. The following figure shows an example of a Real64 Constant object connected to a Formula. The variables in the Formula expression (A, B, and C) get data through the corresponding input terminals, and are local to Formula. If you added output terminals to Formula (in addition to Result), they are also undeclared local variables to Formula.

To create an undeclared global variable

1. Click on Data [image] Variable [image] Set Variable and place a Set Variable object in the work area.

2. Click in the Name field and type a new variable name if desired. You can use any valid variable name in place of globalA for a variable.

3. Connect a data object to the Data terminal of the Set Variable object. The variable will be created and set to the data value. This undeclared global variable is now available for use in any expression in your program.

To create a declared local or global variable

1. Decide whether you want to declare a global or local variable. If you want to declare a local variable, open the context (UserObject or UserFunction) or library where you will use the variable.

A global variable can be declared and used anywhere in your program. A local variable must be declared and used in a specific context or library.

2. Click on Data [image] Variable [image] Declare Variable and place the Declare Variable object in the work area.

3. Click in the edit field beside Name, and enter a variable name. This should be a unique name to avoid conflict with other variables.

4. Click in the Scope edit field to set the variable’s scope.

Global makes the variable available anywhere in your program regardless of the context where the Declare Variable object exists.

Local to Context limits the variable’s use to the UserObject or UserFunction (and any UserObjects nested inside them) in which the Declare Variable object exists.

Local to Library limits the variable’s use to the library of UserFunctions (local or imported) where the Declare Variable object exists.

5. Click in the Type edit field to set the variable’s data type. Data assigned to this variable during program execution must match the declared data type or an error will result.

6. Click in the Num Dims edit field to set the variable as an array with the dimensions you select.

Tips

A declared variable must be initialized using Set Variable or an assignment operator before it can be used.

If a global variable and local variable use the same name, a conflict exists, and the local variable takes precedence.

Variable names are not case sensitive (globalA is equivalent to GlobalA).

You can use any type of data, such as records, to set an undeclared variable.

To view a list of variables in a program, click the View Variables button on the toolbar (or use View [image] Variables). Declared variables are listed when a program is opened. Undeclared globals are listed after a program is run. To view the current contents of any variable in the list, double-click the variable name. The Program Explorer also lists variable names.

View Variables button

Program Explorer button

See also

To Delete a Variable

To Use a Variable

To Use a Global Array

Default Preferences (Delete Variables at PreRun)

Set Variable

View Variables


To Delete a Variable

1. Click on Data [image] Variable [image] Delete Variable and place a Delete Variable object in the work area.

2. Choose whether to delete a specific variable, or all variables.

To delete a specific global variable by name, click on By Name (default), then click in the text field and enter the variable’s name.

To delete all variables, click on All Variables.

Tips

Delete Variable resets the values in a declared variable’s data container to uninitialized values; it does not delete the variable’s name.

Delete Variable deletes an undeclared variable’s values and its name.

Variable names are not case sensitive (globalA is equivalent to GlobalA).

The Delete Variable object will error if the variable referenced by name does not exist.

The name field may be added as a control input to Delete Variable.

See also

To Create a Variable

Delete Variable


To Use a Variable

Use the Get Variable object (Data [image] Variable [image] Get Variable) to access a variable that has been initialized, or use the variable name in an expression. These methods are very useful in a UserObject or UserFunction. The Get Variable object must be used in the correct context if the variable has been declared local or global.

Tips

To avoid using obsolete data from a previous program run, the values of all variables are deleted (cleared) at PreRun, when you run the program. To turn off Delete Variables at PreRun, click on the Default Preferences button on the toolbar (File [image] Default Preferences).

Default Preferences button

If values are deleted at PreRun, you must connect the sequence output pin of the Set Variable object to the sequence input pin of any object that uses the variable. Otherwise, an error occurs because the variables have no defined values.

You can use a variable in any object that includes an expression. However, you cannot include an expression in the name field of a Get Variable object.

You can define a global variable in the main context of an VEE program and then access the variable from within the context of a UserObject or UserFunction. This requires a sequence input connection only to the UserObject or to the Call object.

The example program manual18.vee shows how variables are declared, initialized, and used in the Main and UserObject contexts. It can be found in the Manual examples directory (Help [image] Open Example).

See also

To Create a Variable

Get Variable


To Use a Global Array

You can declare a variable to be a global array. This makes array handling easier because you can then access the array from anywhere in your VEE program. This topic uses an example program to show how to use the object.

Example

1. Open the program manual19.vee from your manual examples directory (Help [image] Open Example...), and run the program.

The two Formula objects use array syntax to access elements of the global array. For example, the expression globalA[3] retrieves the element numbered 0003 (the fourth element) in the global array globalA. You can use this method with records.

See also

To Create a Variable


To Write Data to a File

Use the To File object to write data to a file.

To create a data file

1. Add a To File object to your program (I/O [image] To [image] File).

2. Connect the data input pin of the To File object to a source of data that you want to output to a file.

3. To change the name of the destination file, click on the To File button and enter a new file name in the dialog box. Then click on OK.

The To File object uses a write transaction to output the data to the file. VEE creates the file if it does not already exist.

To write data to a file

This procedure shows how to create a simple program that writes string and real data to a file. If your program requires different choices, then use this procedure as a guide.

1. Add a To File object to your program (I/O [image] To [image] File). Click on the checkbox to turn on Clear File At PreRun & Open (a check mark appears in the box).

In general, you'll want to turn on Clear File At PreRun & Open to ensure that the file is cleared and that no old data is in the file.

2. Double-click on <Double-Click to Add Transaction> to bring up the I/O Transaction dialog box.

3. Click on the DEFAULT FORMAT field (or its arrow). A drop-down menu appears.

4. Click on STRING FORMAT, and then click on OK. Now the modified transaction is WRITE TEXT a STR EOL. This transaction writes variable a (the data on input pin A) to myFile as text data in string format, followed by an end-of-line sequence (carriage-return/line-feed).

5. Double-click on <Double-Click to Add Transaction> to add a second transaction to the To File object (object menu [image] Add Trans…). The I/O Transaction dialog box appears.

6. Change the variable field (a by default) to b.

7. Click on the DEFAULT FORMAT field (or its arrow). The drop-down menu appears.

8. Click on REAL64 FORMAT, then click on OK. The second transaction is WRITE TEXT b REAL64 STD EOL. This transaction writes variable b as text in REAL64 STD format to myFile.

9. Connect a Text constant object to terminal a and a Real64 constant object to terminal b. The finished program should appear as follows:

When you run the program, two lines of data are written to myFile, each followed by an end-of-line sequence (carriage-return/line-feed). The first is the string String data. The second is the real number 3.142.

See also

To Read Data from a File

To Edit a File I/O Transaction

To Select a File Name Programmatically

To DataSet

To File


To Read Data from a File

Use the From File object to read data from a file.

This procedure is a companion to the procedure To Write Data to a File. It shows how to read string and real data from the file created in that procedure. If your program requires different choices than those presented here, then use this procedure as a guide.

1. Add a From File object to the program (I/O [image] From [image] File).

2. Change the default transaction to READ TEXT x STR using the I/O Transaction dialog box as described for writing to a file.

3. Add a second transaction READ TEXT y REAL64, again using the I/O Transaction dialog box as described for writing to a file.

4. Connect AlphaNumeric displays to both outputs (X and y).

5. Connect the sequence output pin of the To File object to the sequence input pin of the From File object. This ensures that data is written to myFile before the From File object attempts to read data from the file. The finished program should appear as follows:

See also

To Edit a File I/O Transaction

To Select a File Name Programmatically

To Write Data to a File

From DataSet

From File


To Edit a File I/O Transaction

The To File object uses a write transaction to communicate with the specified data file. The default transaction is WRITE TEXT a EOL, which writes the data on input A as text, followed by an end-of-line sequence (a carriage-return/line-feed by default). The From File object uses similar transactions to read data from a file. You can edit a transaction by using the I/O Transaction dialog box.

To edit a transaction

1. Double-click on the transaction field in the To File or From File object. The I/O Transaction dialog box appears.

2. To change the action, click on WRITE or READ, select an action.

3. To change the encoding, click on Text, then select the encoding.

In general, the container encoding is useful if you want to retrieve the data back into VEE using From File, but not if you want to access the data file with an external application such as a spreadsheet program.

The dialog box adapts to the entries you select, making corresponding options available.

4. Change other field entries as needed to configure various options such as the data format, and the end-of-line sequence, then click on OK.

5. To add another transaction, double-click on the blank line below the last transaction.

See also

From File

To File

VEE Advanced Techniques; chapter: "Using Transaction I/O"


To Store and Retrieve a Waveform

Waveform data is best stored and retrieved in the form of a data container. The basic procedure is as follows:

1. Use a WRITE CONTAINER transaction in the To File object to write the waveform data to a file.

2. Use a READ CONTAINER transaction in the From File object to read the waveform data back from the file.

Example

The program manual20.vee in your manual examples directory shows how to use waveform data. The program works as follows:

1. The waveform data from the Function Generator is written to the wavedata file by the To File object using a WRITE CONTAINER a transaction.

2. The data is read back from the wavedata file as a waveform container by From File using a READ CONTAINER x transaction. The data is output on terminal X, and displayed by the Waveform (Time) display.

3. The sequence pin connections ensure that the waveform is written to the file before From File attempts to read it.

In a more typical situation, one VEE program would store the waveform data into a file, and then a second VEE program would read the data back into VEE, analyze it, and display it.

See also

To Write Data to a File

To Read Data from a File

To Edit a File I/O Transaction

From File

To File


To Select a File Name Programmatically

If your program reads or writes data using objects such as From File or To File, you can set up your program to request a file name at run time. The following example uses the File Name Selection dialog object with To File to show how this works.

1. Add a To File object (I/O [image] To [image] File).

2. Click on Clear File At PreRun & Open. Double-click on <Double-Click to Add Transaction>, and click on OK.

3. Add a File Name control input terminal to the To File object. (Object menu [image] Add Terminal [image] Control Input, click on OK.)

4. Add a File Name Selection object (Data [image] Dialog Box [image] File Name Selection) to the work area and connect its File Name output to the File Name control pin on the To File object. Add a Stop object to the Cancel output.

5. Connect the sequence output pin of the File Name Selection object to the sequence input pin of the To File object. This ensures that the To File object will not operate until a file name has been selected.

6. In the File Name Selection object, change the Select File For field to Writing. This ensures that the user is alerted before an existing file is overwritten.

7. Add a Text object, and connect it to pin a of To File.

Example for Windows

When you run the program, the Enter File Name dialog box appears, prompting for a file name. Enter a new file name or click on an existing file name. In Windows, change the Save as type entry to All Files (*.*) since the file to be saved is not a program file. Click on Save.

See also

File Name Selection

From File

To File


To Store Data for a Spreadsheet Program

You can use VEE file I/O to produce a data file that can be read by a spreadsheet program such as Microsoft Excel or Lotus 1-2-3. In general, the steps are as follows:

1. Determine what data file format the spreadsheet program requires. For example, how are rows and columns delimited?

2. Create a VEE program that collects the data, and then outputs the data to a file in an ASCII text format using the appropriate delimiters. Normally, the To File object is the best way to do this.

Example

The program manual21.vee in your manual examples directory shows how to collect (or simulate) 10 voltage readings, each with a time stamp, and output the data to a file that can be read by Microsoft Excel. The program works as follows:

1. The For Count and Delay objects trigger the following events approximately every 10 seconds:

a. The Counter object advances by 1.

b. The Now object outputs the current time (to within 1 second), which is converted to the Time Stamp format by the To String object.

c. The dmm (hp34401a @ (NOT LIVE)) instrument panel simulates a reading from a HP 34401A Multimeter.

2. The Build Record object builds a record for each reading (every 10 seconds), as follows: field Cnt is the count or test number, field Tm is the current time for the reading (in the format hh:mm:ss), and field Vlts is the simulated voltage reading returned by the instrument panel object.

3. The To File object writes the data out to a file in text form. In the transaction WRITE TEXT a.Cnt," ",a.Tm," ",a.Vlts EOL

a.Cnt represents "field Cnt of record a" (the count),

" " inserts a space (as a delimiter),

a.Tm represents "field Tm of record a" (the time),

" " inserts another space (as a delimiter),

a.Vlts represents "field Vlts of record a" (the reading), and

EOL inserts the end-of-line sequence (carriage-return/line-feed).

Thus, each record is converted to string format and output (with spaces as delimiters) in the following format:

1 11:29:06 5.687753697513882

When the program is finished, the file myfile will consist of 10 rows of data, for example:

1 11:29:06 5.687753697513882

2 11:29:16 6.437091378803515

3 11:29:26 7.064658105870967

4 11:29:36 7.439572075814199

5 11:29:46 7.465490768920665

6 11:29:56 7.135229243023529

7 11:30:06 6.53525004955898

8 11:30:16 5.795432812581498

9 11:30:26 6.154398687554457

10 11:30:36 6.844467171462198

In each row, the first field (the count) is followed by a space (the delimiter), the second field (the time) is followed by another space, and the third field (the reading) is followed by an end-of-line sequence.

The output file will be a Windows ASCII file, which can be read directly into Microsoft Excel. Just open the file from Excel and, when asked, tell Excel that the file is delimited, and that the delimiter is the space.

The data should appear as follows in the Excel spreadsheet:

By using appropriate delimiters you can create files that can be read by a variety of spreadsheet programs.

You can automate the process by using ActiveX Automation and Controls, or DDE (Dynamic Data Exchange). ActiveX is more powerful than DDE when you want to control other applications from VEE. Refer to VEE Advanced Techniques for information about using ActiveX and DDE.

See also

To Collect Data into a Record

Build Record

To DataSet

To File


To Load an Instrument Driver

Agilent VEE supports instrument control through the use of instrument drivers and direct I/O. Instrument drivers include Panel Drivers (controlled through Panel Driver and Component Driver objects), and VXIplug&play Drivers (controlled through Plug&play Driver objects). The Direct I/O object allows low-level transactions with an instrument.

Before you can use any instrument driver object, the appropriate instrument driver files must be installed. For the instrument drivers to communicate with instruments, you must also install the Agilent I/O Libraries as described in your Installing the Agilent I/O Libraries manual included with the Agilent VEE product.

Many Panel Drivers are provided with Agilent VEE. When you installed Agilent VEE, you could select the groups of drivers that you wanted to install. A few drivers are installed by default to run certain example programs. If you need to install additional drivers, run the VEE setup.exe program, and select the driver options that you need.

Note

VXIplug&play Drivers are available from instrument manufacturers who provide them. Agilent Technologies provides VXIplug&play Drivers for many Agilent instruments. From time to time, new and updated instrument driver files also become available. For your convenience, these files are available electronically from Agilent. See To Get Support and Download Instrument Drivers for directions to download files.


To add a TCP/IP Instrument

To Add a USB or LAN Based Instrument

To configure USB and LAN based instrument for VEE, you are required to use Agilent's IO Config utility that is provided with Agilent's I/O Driver Libraries. VEE requires version M.01.01.04 or higher of the I/O Driver Libraries.

For USB Based Instruments

  1. For USB, power the instrument; connect the USB cable. Should you remove your USB instrument from the Instrument Manager, you have to cycle the USB cable by unplugging and re-plugging it back into your instrument.

  2. Run IO Config. The USB device will be sensed by IO Config.

  3. Edit the alias if you like. Aliases simplify the naming scheme by providing a manageable name rather than the long serial number that is the standard USB identifier.

  4. Run Find Instruments and the USB device will be identified by its alias.

For LAN Based Instruments

LAN instruments are more complex to set up than USB instruments.

  1. Run IO Config (If necessary run Auto Config)

  2. Configured Interfaces should include TCPIP0

  3. Highlight this listing and choose Edit.

  4. Choose Edit VISA Config

  5. Choose Add Device

  6. Under Machine Name/IP enter the TCP/IP address to your instrument. For example: 129.82.145.206

  7. Under Device Name enter inst0

  8. Select OK three times.

Now start the Instrument Manager and select Find Instruments. If the TCP/IP address is correct and the instrument is online, it will appear in the Instrument List.


To Add an Instrument Configuration

It is easy to use an instrument control object once that instrument is listed in the Instrument Manager configuration.

To Automatically Add an Instrument

Auto Discovery provides a simple way to add and configure IEEE-488.2 and SCPI instruments. You can use this method when the instrument is connected to your computer and powered-on.

1. Select I/O [image] Instrument Manager… The Instrument Manager dialog box appears displaying the current configuration in the Instrument List area.

2. Click on Settings. The Auto Discovery Settings dialog appears.

3. Click the radio button for Detect, identify, and configure drivers... Then click OK.

4. Click on Find Instruments.

The Auto Discovery process displays its status as it runs. When Auto Discovery finishes, the current configuration is updated with an additional instrument entry named "newInstrument". This entry also shows the instrument’s model number and I/O address. You can click Save now to save this configuration, or you can choose to edit some details of the new instrument entry. (Most people change the instrument name.) See To Edit an Instrument Configuration.

5. Click on the Save button to close the dialog box and save the new configuration.

To Manually Add an Instrument

1. Select I/O [image] Instrument Manager… The Instrument Manager dialog box appears displaying the current configuration in the Instrument List area.

2. Click on Add... The Instrument Properties dialog box appears. This dialog box allows you to enter basic configuration information necessary for the new instrument.

3. Use the default Name or enter a unique new name.

4. To change the Interface, click on the interface name to display the list of supported interfaces. Click on the interface connected to your instrument.

5. Click in the Address field to set the instrument address. For information about determining what address to use for a particular instrument, refer to the owner's manual for the instrument.

6. Gateway hostname should be changed if the instrument is attached to a remote host on a networked system.

7. Optional: To set additional device attributes, click on the Advanced... button. For information about the Advanced properties, see To Edit an Instrument Configuration. (The basic and advanced "Instrument Properties" dialogs work the same whether you are adding a new entry or editing an existing entry.)

8. Click on the Save button to close the dialog box and save the new configuration.

Notes

If you add or remove interface cards used on your system, you must update the I/O_config file by running the Agilent I/O Libraries configuration utility. Please see the manual, Installing the Agilent I/O Libraries, for complete information about installing and configuring interfaces.

For detailed information about configuring instruments, see the VEE Advanced Techniques manual.

See Also

To Load an Instrument Driver

To Edit an Instrument Configuration

Instrument Manager

VEE Advanced Techniques

Owner’s manual for instrument


To Delete an Instrument Configuration

You can delete an instrument from the Instrument Manager dialog box.

1. Select I/O [image] Instrument Manager.... Then select the instrument configuration name you want to delete by clicking on it.

2. Click on the Remove button. The selection is removed from the list.

3. Click on the Save button to close the dialog box and save the new configuration.

Note

If you add or remove interface cards used on your system, you must update the I/O_config file by running the Agilent I/O Libraries configuration utility. Please see the manual, Installing the Agilent I/O Libraries, for complete information about installing and configuring interfaces.

See Also

To Edit an Instrument Configuration

Instrument Manager


To Edit an Instrument Configuration

You can edit the configuration of any instrument in the current Instrument List.

1. Select I/O [image] Instrument Manager… The Instrument Manager dialog box appears, displaying the current configuration in the Instrument List area.

2. Double-click the desired instrument in the Instrument List. This brings up the Instrument Properties dialog box. Various properties can be changed as described in the following sections.

To Edit Basic Instrument Properties

In the Instrument Properties dialog box, you can specify four basic properties:

Name: This can be any name you choose to help you identify the instrument. It is recommended that names start with a letter and not contain spaces.

Interface: Select the type of interface that is connected to the instrument.

Address: Enter the I/O address of the instrument. The form of this number depends upon the type of interface. For example, RS-232 instruments use only the logical unit number, while GPIB instruments use a number built from the logical unit and the instrument bus address.

Board Number: Enter the board number for the interface board. The board number index starts at 0 and the default is 0.

Gateway: For local interfaces, select This host. For LAN-gatewayed interfaces, enter the hostname (or IP address) of the remote gateway.

Note that all the properties except "Name" must accurately reflect physical characteristics of the instrument or interface hardware. For example, you cannot change the GPIB bus address of an instrument by typing a different number into the Address field. The bus address of an instrument must be changed by a switch or button on the instrument itself. Then this new address is entered into the Address field in VEE’s Instrument Properties dialog.

1. In the Instrument Properties dialog box, click the desired field. Enter (or select) a new value. Modify other fields as needed.

2. Click on the Save button to close the dialog box and save the new configuration.

To Edit Advanced Instrument Properties

1. In the Instrument Properties dialog box, click on the Advanced... button. The Advanced Instrument Properties dialog box appears. This dialog box displays a variable set of tabbed sheets depending on the selected interface type.

All interface types display the General, and Direct I/O tabs.
GPIB adds the Plug&play Driver and Panel Driver tab
Serial adds the Serial and Panel Driver tab
GPIO adds the GPIO and Panel Driver tabs
VXI adds the Plug&play Driver, A16 Space, Panel Driver, and A24/A32 Space tabs.
TCPIP adds the Plug&play Driver and the LAN tabs.
USB adds the Plug&play Driver and USB tabs.

2. Click on the tabs and change the default settings as needed. To change settings, type new values in the fields or click on buttons to change their states. As a guideline, you should change the settings depending on the instrument and the type of instrument-control object you will use, such as a Panel Driver, Plug&play Driver, or Direct I/O.

To use an instrument driver, you must identify the driver file on the Panel Driver or Plug&play Driver tabs. The driver file must exist on your hard disk.

For detailed information about the various configuration settings, click the Help button on the dialog box.

3. Click on the Save button to close the dialog box and save the new configuration.

See Also

To Add an Instrument Configuration

Instrument Manager


Dynamic I/O Automation Server

In previous versions of VEE, instrument bus addresses in the VEE I/O configuration file were static (fixed). In version 6.0, the Dynamic I/O Automation Server lets you find and identify instruments programmatically. This provides new levels of flexibility. For example, you can find all your instruments and then use Programmable Instrument Properties to set up Direct I/O objects.

Use

To use the Dynamic I/O Automation Server from VEE:

Select Device [image] ActiveX Automation References to display the ActiveX Automation References Dialog box. Then, check Agilent VEE DynamicIO 1.0 Type Library and click OK.

Select Device [image] Function & Object Browser to display the Function & Object Browser Dialog Box. Select Type: ActiveX Objects to display DYNAMICIOLib as the Library.

Examples

VEE examples are provided in the Help [image] Open Example… InstrumentIO directory.

See Also

Since this utility is a stand-alone ActiveX automation server, it can also be used from other applications, such as C++ and Visual Basic.


Embedded I/O Configurations and Merging

VEE Pro can merge and import program elements from a program file that also contains an embedded I/O configuration. However, embedded I/O configurations themselves cannot be merged or imported. If the objects you are merging (importing) require configured instruments, you must augment the local I/O configuration to include those instruments.

One alternative is to add instruments to the current I/O configuration and save it with the "main" program. (In other words, the program file containing all the merged elements, or the program file that does the Import Library.) Another alternative is to ensure that all necessary instruments are contained in the global I/O configuration file (vee.io) on the computer running the program.

VEE searches for the global I/O configuration file as follows:

1. If an environment variable named HOME exists, VEE always looks for the I/O configuration file there. (A blank I/O configuration file will be created if one doesn’t exist in the %HOME% directory.)

2. If no HOME environment variable is defined, then VEE looks for the I/O configuration file in:

<%USERPROFILE%>\Local Settings\Application Data\Agilent\VEE Pro

For example, if JohnDoe is logged on and running the VEE program, VEE looks for the I/O configuration file:

C:\winnt\profiles\JohnDoe\Local Settings\Application Data\Agilent\VEE Pro\vee.io


To Use a Panel Driver Object

To add a Panel Driver object to the work area, use the Instrument Manager dialog box. The HP 34401A Multimeter configuration is used as an example.

1. Select I/O [image] Instrument Manager.... The dialog box appears with the list of configured instruments in the Instrument List area.

2. Click on the instrument you want to add to the work area. If it is configured with an instrument driver file, the Panel Driver button in the Create I/O Object area becomes active. For an example click on dmm(hp34401a@(NOT LIVE)).

3. Click the Panel Driver button. The outline of the instrument panel object appears. Place the outline where you want it in the work area, and click the mouse button.

4. With live mode OFF (default), the hp34401a instrument panel generates simulated data. Try clicking on the ? in the display field. A simulated reading appears. Live mode is available only in Panel Drivers.

With live mode OFF, you can run your I/O program even if an instrument is not present. Once you've tested the program and connected an instrument, you can set live mode to ON.

5. The Measure Panel is shown by default, which allows you to select the Function, Range, and so forth. To change the Function setting, click on the Function button labeled DC Volts.

6. To change the function to DC Amps, double-click on DC Amps in the list. To change back to DC Volts, click on the Function button, now labeled DC Amps, and then double-click on DC Volts in the list.

While live mode is OFF, none of these changes affect an instrument, even if one is connected to your system. However, if live mode is ON and you have an HP 34401A Multimeter connected to the GPIB (correctly addressed and configured), the changes on the VEE instrument panel object will automatically change the state of the instrument.

7. The Measure Panel is only one of several panels that you can select. Click on the Measure Panel button at the upper-right corner of the object.

8. Double-click on Status Panel in the list. The Status Panel appears.

9. To go back to the Measure Panel, click on the Status Panel button and double-click on Measure Panel.

The various panels in an instrument panel object let you control almost all functions of an instrument. However, you need to be familiar with a particular instrument in order to use the instrument panel effectively. Refer to the instrument owner's manual for further information. For information about an instrument panel object, select Help from the object menu.

See Also

To Read Data with a Panel Driver Object


To Read Data with a Panel Driver Object

In this procedure, you will create a simple program that displays simulated voltage readings from an instrument panel object for an HP 34401A Multimeter.

1. Add an instrument panel object for the HP 34401A (I/O [image] Instrument Manager...).

2. Select Add Terminal by Component [image] Select Output Component from the object menu of the instrument panel.

3. Click on the HP 34401A display. The Reading terminal is added to the output.

4. Add an AlphaNumeric display object to the work area, connect it as shown below, and run the program. Since live mode is OFF, the data is simulated, which is indicated by the Simulated Data label (and by (NOT LIVE) in the title bar).

5. To turn live mode ON, select I/O [image] Instrument Manager..., select dmm (hp34401a @ (NOT LIVE)) in the list (if it is not already highlighted), and then click on Properties. The Instrument Properties dialog box appears showing the configuration for the HP 34401A Multimeter.

6. If the address shown (the default is 722) doesn't match the address of the instrument, enter the correct address. (For information on addressing a particular instrument, refer to the instrument owner's manual.)

7. Click the Advanced… button. Click the button to the right of Live Mode. The button toggles from OFF to ON. Then click the OK buttons to return to the Instrument Manager dialog box.

8. Click the Save button. The instrument panel now has live mode ON.

The new title, hp34401a (@ 722), shows that live mode is ON and that the instrument panel is configured to communicate with an HP 34401A Multimeter at GPIB address 722. Of course, the program will time out unless there actually is an HP 34401A at address 722 connected to your computer.

At this point, if you have an HP 34401A Multimeter, you can connect it and run the program. Otherwise, use the Advanced Instrument Properties dialog box (I/O [image] Instrument Manager..., click on Properties, click on Advanced…) to return to live mode OFF.


To Use a Component Driver Object

You can gain a slight increase in performance by using a component driver object. The HP 34401A Multimeter configuration is used as an example.

1. Select I/O [image] Instrument Manager.... The dialog box appears with the list of configured instruments in the Instrument List area.

2. Click on the instrument you want to add to the work area. If it is configured with an instrument driver file, the Component Driver button in the Create I/O Object area becomes active. For an example click on dmm(hp34401a@(NOT LIVE)).

3. Click the Component Driver button, and place the object outline in the work area.

4. The component driver object appears as an icon. Double-click on the icon to display the open view.

5. Add a Reading terminal to the component driver object (object menu [image] Add Terminal [image] Data Output).

See Also

manual22.vee in the manual examples directory
Help [image] Open Example...

Component Driver


To Use a Plug&play Driver Object

To add a VXIplug&play Driver object to the work area, use the Instrument Manager dialog box.

Note

You cannot use a VXIplug&play Driver object with any other instrument-control object (Panel Driver, Component Driver, or Direct I/O) to communicate with the same instrument in the same program.

1. Select I/O [image] Instrument Manager.... The dialog box appears with the list of configured instruments.

2. Click on the instrument you want to add to the work area. If it is configured with a VXIplug&play driver, the Plug&play Driver button becomes active.

3. Click on the Plug&play Driver button and place the To/From VXIplug&play object in the work area.

4. Double-click on an empty transaction (or from the object menu select Add Trans or Insert Trans). The Select a Function Panel dialog box appears. It displays function panels grouped into logical categories. Categories will vary with each driver.

Click the [+] and [-] icons to expand and compress the hierarchical structure of folders and functions.

Click the [f(x)] icons to select the function panel you want to use.

5. Click OK on the Select a Function Panel dialog box. The Edit Function Panel dialog box appears.

6. Edit the settings on the Edit Function Panel for the values you need. Use the Help button for more information about the particular instrument driver.

7. Click OK. To set up another function for the instrument, double-click the next transaction in the To/From VXIplug&play object.

See Also

To/From VXIplug&play

Refer to "Using VXIplug&play Drivers" in the VEE Advanced Techniques manual.


To Use a Direct I/O Object

To add a direct I/O object, use the Instrument Manager dialog box. The HP 34401A Multimeter configuration is used as an example.

1. Select I/O [image] Instrument Manager.... The dialog box appears with the list of configured instruments.

2. Click on the instrument you want to add to the work area. For an example click on dmm(hp34401a@(NOT LIVE)).

3. Click the Properties button; then, in the Instrument Properties dialog box, click the Advanced… button. In the Advanced Instrument Properties dialog box on the General tab, set Live Mode to ON. Click the OK buttons to return to the Instrument Manager.

4. Click the Direct I/O button. The outline of the direct I/O object appears. Place the outline where you want it in the work area, and click the mouse button. The object’s title bar contains the instrument’s configured name.

5. Double-click the transaction areas to enter commands for the instrument.

See Also

To Read Data Using Direct I/O

Direct I/O

MultiDevice Direct I/O


To Read Data Using Direct I/O

This procedure shows how to use the direct I/O object to read data from an HP 34401A Multimeter.

1. Add a direct I/O object, configured for address 722, to the work area as shown in To Use a Direct I/O Object.

2. The direct I/O object uses transactions to communicate with an instrument. Double-click on the "blank" transaction (the highlighted field) in the object. The I/O Transaction dialog box appears with the variable a highlighted. Enter the string "MEAS:VOLT:DC?" (including quotation marks) in its place. Click on OK to create the transaction WRITE TEXT "MEAS:VOLT:DC?" EOL.

3. Select Add Trans from the object menu to add a second transaction, or double-click the next blank transaction. Change the transaction dialog box action to READ and the encoding to TEXT . Click on OK.

4. The direct I/O object now has two transactions:

a. WRITE TEXT "MEAS:VOLT:DC?" EOL writes the command string "MEAS:VOLT:DC?" to the instrument at address 722. To the HP 34401A Multimeter, the command string MEAS:VOLT:DC? means "output one dc voltage reading."

b. READ TEXT x REAL64 reads text data in the real format from the instrument at address 722, and outputs the data on the X data output terminal.

5. To complete the program, add an AlphaNumeric display object to the work area, and connect it as shown below. (You can run this program if you have an HP 34401A Multimeter connected to the GPIB at address 722.)

See Also

Refer to "Using Transaction I/O" in the VEE Advanced Techniques manual.

Programming manual for your specific instrument

Direct I/O

MultiDevice Direct I/O


To Poll GPIB Instruments

From time to time a GPIB instrument sends a service request ("SRQ") on the bus. Agilent VEE provides two devices that help you determine what device has requested service, and what the problem is. Both of these objects are found under I/O [image] Advanced I/O.

The Interface Event object reports an event for the entire bus. For example, if Interface Event is set to report an SRQ for hpib7, any device on the interface at logical unit 7 can cause an event. You can also use the Interface Event object to detect events on the serial and VXI interfaces, if such instruments are configured.

The Instrument Event object returns the status byte from a particular instrument. On the GPIB, use Instrument Event objects to poll the individual devices on the bus.

Example

The following program shows how to use the Interface Event and Instrument Event objects to process GPIB service requests:

In the program the Interface Event object waits for an event on hpib7, that is, on the GPIB interface at logical unit 7. However, the Interface Event object does not indicate which device on the bus caused the event.

The event output of the Interface Event object activates both of the Instrument Event objects, which individually poll two GPIB instruments (the HP 34401A and HP 54600A). Each Instrument Event object has its action set to Any Set and its mask set to #H10. Any Set causes the object to wait for an event to occur, and then perform a logical AND of the returned value with the mask #H10, which corresponds to bit 4 in the status byte (DAV, or "data available"). The result is returned on the status output terminal.

See Also

Instrument Event

Interface Event


To Monitor Bus Messages

Agilent VEE communicates with an instrument by means of a series of messages. On the GPIB, the bus messages follow the IEEE-488 standard. Normally, these messages are not seen. However, when you debug your I/O program you may want to monitor the messages on the bus. To do this, add a Bus I/O Monitor object to your program. You can also use this object to monitor VXI or serial interface messages.

Note

The Bus I/O Monitor does not show any I/O done from VXIplug&play drivers.

To Add a Bus I/O Monitor Object

1. Select I/O [image] Bus I/O Monitor. The Select I/O Channel dialog appears.

2. Select one of the interfaces, such as hpib7, and click on OK.

3. Place the object in the work area.

Example

The following program shows the Bus I/O Monitor object monitoring the bus:

Each time you run the program, the sequence of bus messages is recorded. When the program stops, you can scroll through the messages. By default, the Bus I/O Monitor object can save 256 lines of information in its buffer. However, you can change the buffer size.

The Bus I/O Monitor object slows down your program, and is generally used for diagnostic purposes. Many programmers create a program using a panel or component driver to control an instrument, and then use Bus I/O Monitor to "capture" the commands and messages used to communicate with the instrument. You can then use these commands and messages to communicate with the instrument using direct I/O, which provides increased I/O performance.

See Also

Bus I/O Monitor


To Display a Scalar Value

Use the AlphaNumeric object to display scalar values. This object clears itself and displays only the new data received each time it executes.

1. Add an AlphaNumeric display to the work area (Display [image] AlphaNumeric).

2. Connect the data input pin of the AlphaNumeric object to a source of scalar data (for example, a Real64 constant object).

3. Run the program to display the data.

Example

See also

To Display a Series of Values in a Log

AlphaNumeric


To Display an Array of Values

Use the AlphaNumeric object to display an array. This object clears itself and displays only the new data received each time it executes.

1. Add an AlphaNumeric display to the work area (Display [image] AlphaNumeric).

2. Connect the data input pin of the AlphaNumeric object to a source of array data (for example, an Alloc Real64 object)

3. Run the program to display the data.

4. Resize the AlphaNumeric object to show the entire array.

Example

The one-dimensional array is a single data container consisting of 10 elements.

See also

AlphaNumeric


To Display a Series of Values in a Log

Use the Logging AlphaNumeric object to display a series of values in a log. This object keeps a "history log" of the data it receives.

1. Add a Logging AlphaNumeric display to the work area (Display [image] Logging AlphaNumeric).

2. Connect the data input pin of the Logging AlphaNumeric object to a repeating source of data (for example, a For Count object).

3. Run the program to display the log of data.

Example

The Logging AlphaNumeric object displays a log of the 10 scalar values from the For Count object.

See also

To Show an Analog Display of Data

Logging AlphaNumeric


To Show an Analog Display of Data

Use an Indicator object to display scalar data on an analog indicator. These objects provide three-color range indication.

Fill Bar displays a value using a color bar.

Meter displays a value on an analog meter.

Tank displays a value using a color bar in a graphical tank.

Thermometer displays a value using "mercury" in a graphical thermometer.

The following procedures use the Thermometer object as an example. You can use similar techniques with the other Indicator objects.

To display data on a Thermometer

1. Add a Thermometer object to the work area (Display [image] Indicator [image] Thermometer).

2. Connect an Int32 Slider object to the data input pin of the Thermometer. Move the slider to select a value, and run the program. Run the program with the slider set to different values along its range.

The "mercury" level and color change as you change the slider value. The value is displayed at the bottom of the Thermometer.

3. Try changing the range of the Thermometer scale. Click on the lower range field (0) and enter a new value. Do the same for the upper range field (100). Note that the thermometer scale changes to conform to the new range.

To configure the Thermometer object

1. Click on Properties from the object menu of the Thermometer. The Thermometer Properties window appears.

2. Try changing a few parameters:

a. You can select either a vertical (the default) or a horizontal layout for the Thermometer. You can also turn the digital display on or off.

b. You can select a color for each range (low, mid, and high). Click on a color button to show the possible colors. You can also set the lower and upper limit values to determine where each color range begins.

3. Changes from the Properties window take effect immediately.

See also

To Show a Color Alarm

Fill Bar

Meter

Tank

Thermometer


To Show a Color Alarm

The Color Alarm object displays user-definable color indicator and text string depending on the value on its data input pin.

To use a Color Alarm

1. Add a Color Alarm object to the work area (Display [image] Indicator [image] Color Alarm).

2. Connect a Real64 Slider object to the data input pin of the Color Alarm. Move the slider to select a value, and run the program. Run the program with the slider set to different values along its range.

The color and text displayed by the Color Alarm change as you change the slider position.

To configure the Color Alarm

1. Click on Properties from the object menu of the Color Alarm object. The Properties window appears.

2. Try changing a few parameters:

a. From the Layout section of the dialog box you can select either a circular (the default) or a rectangular layout for the Color Alarm. You can also turn the digital display and the "three dimensional" border on or off.

b. From the Limits section of the dialog box you can select a color for each range (low, mid, and high). Click on a color button to show the possible colors. You can also change the text for each range, and you can set the lower and upper limit values to determine where each color range begins.

3. Changes made from the Properties window take effect immediately.

See also

To Show an Analog Display of Data

Color Alarm


To Display XY Values

The XY Trace and X vs Y Plot objects are usually the most applicable of the graphical displays.

To plot a series of values

1. Add an XY Trace object to the work area (Display [image] XY Trace).

2. Connect a source of data to the data input pin on the XY Trace object. The data can either be a continuously-generated series of points, or a waveform. The Function Generator object (Device [image] Virtual Source) works well for this example.

3. Run the program.

Example

In the following program, the For Range object repeats 37 times, generating the series of values 0, 10, 20, and so forth, up to 360. The Formula object calculates the sine of each value and outputs the result to the XY Trace object, which plots the resulting curve.

To plot a series of Y values against X values

1. Add an X vs Y Plot object to the work area (Display [image] X vs Y Plot).

2. Connect the XData and YData1 data input terminals to the appropriate sources of data. You can plot a continuously-generated series of Y points against X points, or you can plot a waveform against a waveform. However, you cannot mix data shapes.

3. Run the program.

Example

In the following program, the For Log Range object repeats 14 times, generating a logarithmic series of Y data points. The Counter outputs the current count to the XData input terminal, while the For Log Range object outputs the logarithmic series to the YData1 input terminal. The X vs Y Plot object displays the resulting curve.

See also

To Display a Waveform

X vs Y Plot

XY Trace


To Display a Waveform

Use the Waveform (Time) display object or the XY Trace object to display waveform data. Use the X vs Y Plot object to display one waveform against another. The following examples show how to display waveforms.

Note

To change the display objects’ properties such as layout, grid type, and markers, double-click on the title bar, or click on Properties on the object menu. For quick access to trace and scale properties, click on the trace and scale labels.

To display a sine wave on an XY Trace object

1. Add an XY Trace object to the work area (Display [image] XY Trace).

2. Add a Function Generator object to the work area (Device [image] Virtual Source [image] Function Generator). Connect the Func output of the Function Generator to the data input pin on the XY Trace object.

3. Change the settings on the Function Generator to output a 50 Hz sine wave, as shown below. Run the program.

In the following program, the XY Trace object displays the waveform in the time domain. The magnitude of the waveform is plotted against a time scale from 0 to 20m (20 milliseconds) to match the time span of the waveform. The XY Trace object does this automatically if the input data is a waveform. Otherwise, the X axis is simply the number of points plotted.

To display one waveform against another on an X vs Y Plot object

1. Add an X vs Y Plot object to the work area (Display [image] X vs Y Plot).

2. Add two Function Generator objects to the work area.

3. Connect the Func output of one Function Generator to the XData input pin on the X vs Y Plot object. Change the settings on this Function Generator to output a 50 Hz sine wave, with Phase set to 0 degrees.

4. Connect the Func output of the other Function Generator to the YData1 input pin. Change the settings on this Function Generator to output a 50 Hz sine wave, with Phase set to 45 degrees.

5. Run the program.

In the following program, the Function Generator objects generate two 50 Hz sine waves, which are 45 degrees out of phase. These waveforms are plotted against each other, displaying a classic Lissajous figure.

To display two waveforms on a Waveform (Time) object

1. Add a Waveform (Time) object to the work area (Display [image] Waveform (Time)).

2. Click on Add Terminal [image] Data Input... from the object menu to add a second terminal.

3. Add two Function Generator objects to the work area.

4. Connect the Func output of one Function Generator to the Trace1 input pin on the Waveform object. Change the settings on this Function Generator to output a 50 Hz sine wave, with Phase set to 0 degrees.

5. Connect the Func output of the other Function Generator to the Trace2 input pin. Change the settings on this Function Generator to output a 50 Hz sine wave, with a DcOffset of -0.8, and Phase set to 0 degrees.

6. Run the program.

In the following program, the Function Generator objects generate two 50 Hz sine waves, but the second has a d.c. offset of -0.8. The Waveform (Time) object displays the two waveforms as Trace 1 and Trace 2. To change the traces’ line-style properties, click on the trace labels, then change Line Type and Point Type in the dialog box that appears.

Note

You can also use the XY Trace, X vs Y Plot, and Waveform (Time) objects to display waveform data from an instrument.

See also

To Add a Trace

To Change the Line and Point Types of a Trace

Waveform (Time)

X vs Y Plot

XY Trace


To Display Polar Data

Use the Polar Plot display object to plot polar data. The following procedure is an example of how to use this object.

1. Add a Polar Plot display object to the work area (Display [image] Polar Plot).

2. Add a For Range object and a Formula object. Connect the objects as shown in the following program. Enter the desired trigonometric formula in the Formula object and run the program.

The trigonometric formula, 1-(sin(360-A)/3)-cos(A), creates the "heart-shaped" figure. You can enter any formula that you want. The For Range object repeats, stepping the angle one degree at a time from 0 to 360 degrees. The Polar Plot object plots the trigonometric data against the angle.

See also

Polar Plot


To Add a Trace

You can add a trace to any of the graphical (XY) display objects.

1. Select Add Terminal [image] Data Input from the object menu of the display object.

2. The new input is added to the object with the appropriate label. On some displays, only the pin is visible, not the labels.

3. To see the terminal labels, select Properties from the object menu and in Show Terminals select True.

4. Once you've added the terminals that you want, connect a source of data to each.

See also

To Change the Color of a Trace

To Change the Line and Point Types of a Trace


To Change the Color of a Trace

You can change the colors of the traces in the graphical (XY) display objects.

1. Click directly on the trace name in the display’s open view to change its properties.

2. In the Edit dialog box, click on the button beside Color. Click on a new color from the resulting dialog box, and click on OK.

3. After changing the trace color, click on OK in the Edit dialog box to return to the work area. The new color is now active.

4. Repeat these steps for each trace that needs a color change.

You can also edit these values from the Properties window. From the context menu of any XY display, select Properties. In the Properties window, scroll down to the Design category. Click on the "+" to the left of the desired Trace to view and edit the properties of that trace.

See also

To Change the Line and Point Types of a Trace


To Change the Line and Point Types of a Trace

You can change the line and point types of the traces in the graphical (XY) display objects.

1. Click directly on the trace name in the display’s open view to change its properties.

2. In the Edit dialog box, you can change both the line and point types:

a. To change the line type, click on the button to the right of Line Type: -- each time you click, the line type changes. Continue clicking until you find the line type you prefer.

b. To change the point type, click on the button to the right of Point Type: -- each time you click, the point type changes. Continue clicking until you find the point type you prefer.

3. After making the changes, click on OK to return to the work area.

4. Repeat these steps for each trace that needs new line and point types.

You can also edit these values from the Properties window. From the context menu of any XY display, select Properties. In the Properties window, scroll down to the Design category. Click on the "+" to the left of the desired Trace to view and edit the properties of that trace.

See also

To Change the Color of a Trace


To Zoom into or out of the Display

You can zoom into or out of the display in any of the graphical (XY) display objects. This procedure uses an example program to show how to use zoom.

1. Load the program manual23.vee from the manual examples directory (Help [image] Open Example...). Run the program to display a trace.

2. Select Zoom [image] In from the object menu of the display object.

3. Move the pointer to the upper right-hand corner of the area on which you want to zoom. Then click the left mouse button and drag the outline box to define the area.

4. Release the mouse button. The zoomed area is displayed.

5. Click on Auto Scale to return to the original display.

6. Now select Zoom [image] Out 2 X from the object menu of the display object.

7. Note how the display zooms out to twice its original size. Click on Auto Scale at any time to return to the original display.

Shortcut

Click the left mouse button and drag the outline box around the area you want to zoom, then release the button.


To Change the Grid Type

You can change the grid type of any of the graphical (XY) display objects.

1. Select Properties from the object menu. The Properties window appears.

2. On Grid Type, select the type of grid that you want (the default is Lines).

3. Changes made in the Properties window take effect immediately.


To Set Markers in the Display

You can set markers in any of the graphical (XY) display objects to identify the positions of peaks and valleys.

1. Select Properties from the object menu. The Properties window appears.

2. Under Markers category, select NumMarkers:

a. None turns markers off (the default).

b. One turns on one marker. The marker position is displayed at the bottom of the object.

c. Two turns on two markers. The position of each is displayed at the bottom of the object.

d. Delta turns on two markers. The position of each, and the difference between the two positions, is displayed at the bottom of the object.

In addition, if you change MarkerInterpolate to True, you can place the markers between the displayed data points. (The marker positions are calculated by linear interpolation.)

3. After setting Markers, you can move the markers along a trace by clicking and dragging on them with the mouse.

Example

A program containing markers is saved as manual24.vee in the Manual examples directory (Help [image] Open Example...).

1. Load and run the program to display a waveform on the XY Trace object.

2. Try moving the markers. Note the position data at the bottom of the XY Trace object.


To Get and Set Marker Properties

You can programmatically get and set marker values in any of the graphical (XY) display objects.

1. Assuming you have an XY display with markers, select Properties from the object menu. The Properties Window
appears.

2. Type a name into the Name field. This XYDisplay becomes a Local-to-Context variable, of type Object, with the name given. You can now refer to this XY Display in any Formula or expression by this name, just like any of other Declared Variable.

3. Get a Formula object (Device [image] Formula).

4. Type the desired expression into the Formula, separating the object name and the marker property with a period. For example: myGraph.marker1X

5. Delete the default input pin if you are not using it in your formula.

As an alternative to directly typing a formula, you can use the Function & Object Browser. Assuming you have a named XY display:

1. Select Device [image] Function & Object Browser

2. Select VEE Objects from the left-most list, and select the XYDevice category. The Member (right-most) column then shows a list of all available marker properties.

3. Select a marker property and click the Create Formula button. Modify the automatically-generated expression to change the default name "XYDevice" to the name you used for your XY display object.


To Automatically Re-Scale the Display

You can re-scale any of the graphical (XY) displays using various methods. In the Properties window, click on Scales, notice the Automatic Scaling property is on by default. This automatically rescales the display after receiving data. Also in Properties, in the Layout category, you can change ShowAutoScaleButton to True. This lets you manually rescale the display, if you turn Automatic Scaling off. Also, the object menu has an Auto Scale command. Usually, it is best to leave Automatic Scaling on.

Sometimes, you may prefer to programmatically turn Automatic Scaling on and off. To do this, add a control pin to the display object, and send it the correct information.

1. Select Add Terminal [image] Control Input from the object menu of the graphical display object.

2. Select the Scales control input.

3. Add a Record Constant object (Data [image] Constant [image] Record).

4. Enter the correct field names and values to control the Scales parameters, and connect its output pin to the Scales control input. Information about Scales parameters is available in the VEE Help topic for each display.

The following figure shows an example of this. The Record Constant sets the X scale’s maximum and minimum values, and turns Automatic Scaling off. It is important that the control input takes effect before data is sent to the display. To ensure this, the Record Constant sequence output pin is connected to the Function Generator sequence input pin.

See also

Record Constant

XY Trace


To Clear the Display

Use any of the following ways to clear the display on any graphical (XY) display object:

In the display object’s Properties window, change ClearAtPreRun to True in the Behavior category.

Select Clear Control [image] Display from the object menu.

Add a Clear control input terminal to the object. From the object menu, click on Add Terminal [image] Control Input. Select Clear and click on OK. The display is cleared whenever the Clear terminal is activated by a connection to a sequence output pin.


To Change the Printing Preferences

You can change the default preferences that VEE uses for printing your program.

To display the Default Preferences dialog box, select File >Default Preferences. Then click on the Printing tab.

After changing preferences, choose how you want to save the settings:

a. To save the settings as new default values, click on Save. This saves the new values in your vee.rc or .veerc file. These preferences will be the defaults for future VEE sessions (until you change them again).

b. To use the new preferences only for the current VEE session (until you select File [image] New, Open, or Exit), click on OK.

c. To set preferences back to default values, click on Reset.

d. To cancel the changes, click on Cancel.

To change the printer palette

1. The Screen Element and B&W Printer Darkness fields both provide drop-down lists. To change the darkness (gray-scale value) for the Detail View, click on B&W Printer Darkness (or the arrow).

2. Now click on the desired darkness. If you want the Detail View background to be white, click on 0 % (White). (Most VEE elements are set to Automatic grayscale by default. The colors in your screen palette are automatically converted to appropriate shades of gray.)

To change the printout contents

1. To change the Print Magnification value, click on the field and edit the value. (The default is 75 percent. You can set values greater or less than 100 to change the size of the printed image.)

2. Select other printing options to customize a report package:

Print Header and Index Page prints a header at the top of each page containing file location and a date/time stamp, and an index listing report sections with page numbers.

Print Program Explorer prints an expanded view of the Program Explorer.

Print Cover Page includes the program’s file name, revision date, execution mode, save-file format, and the VEE revision number.

Print I/O Configuration prints the instrument configuration’s expanded tree view. You can see the instrument configuration in I/O [image] Instrument Manager…

See also

To Change Default Fonts


To Set Up a Printer

VEE supports the HP LaserJet, HP DeskJet, and most PostScript™ printers for VEE printing and for plotting operations. In addition, VEE supports most HP-GL compatible plotting devices.

To change the printer configuration for VEE, follow these steps. (In most cases the default printer configuration will work.)

1. Select File [image] Print Setup. The Print Setup dialog box appears.

2. Select the printer configuration that you want, using the standard Microsoft Windows techniques for the Print Setup dialog box.

3. Click on Properties for more printing options, or click on OK to confirm your selections.


To Print the VEE Work Space

You can print the work space contents currently visible in the VEE Window.

1. To print the work space immediately, click the Print Screen button on the toolbar.

Print Screen button

or

1. Use File [image] Print Screen. The Print dialog box appears.

2. If the printing configuration is acceptable, click on OK to print the VEE work space. Or change the parameters and then click on OK. The work space is printed including the toolbar and status bar.

Tip

You can also print the whole work space programmatically using the Print Screen object.

Shortcuts

These shortcuts let you capture the VEE screen even when a dialog box is displayed, and the toolbar button and menu are inaccessible:

Capture the VEE window in the Microsoft Windows clipboard by pressing Alt+Print Screen on the keyboard at any time. (If a program is running, it will pause momentarily.) You can then paste the image into Microsoft Paint or other Windows graphics applications.

See also

Print Screen Object


To Print a VEE Program

You can print a representation of the program currently open in the VEE Window. The entire program, or smaller parts, can be printed.

To print an entire program

1. Select File [image] Print Program. The Print Options dialog box appears. These options let you control the level of program detail that is printed:

Print Nested UserObjects prints the contents in all UserObjects contained in the program.

Print Object Views prints the open views of objects that contain useful information.

The remaining options are set according to the default preferences described in To Change the Printing Preferences . You have the opportunity to change them each time you print a program.

2. Click OK. The Print dialog box appears. Change the printing configuration if desired.

3. Click OK again to print a representation of the program.

To print from the Program Explorer

You can print an entire program or parts of a program from the Program Explorer.

1. To view the Program Explorer, click the Program Explorer button on the toolbar (or use View [image] Program Explorer).

Show/Hide Program Explorer button

2. Using the right mouse button, click on the context name in the Program Explorer that you want to print. You may need to expand the Program Explorer’s tree view to see all available names.

To print the entire program click on the program or file name at the top.

To print a single context in the program such as Main, a UserObject, or a UserFunction, click on the particular name.

3. In the context menu that appears, click on Print. The Print Options dialog box appears. The options are described above.

4. Set the options you prefer, then click OK.

5. The Print dialog box appears. Change the printing configuration if desired.

6. Click OK to print the program.

The following figure shows the Program Explorer with a context menu ready to print a UserObject.


To Print Objects in a VEE Program

You can print selected objects in a VEE program.

1. Select one or more objects in the program. Click on an object to select it. To select several objects, hold down the CTRL key while clicking on the objects or use your mouse to draw a rectangle around the objects while holding down the CTRL key.

2. Select File [image] Print Objects. The Print dialog box appears. Change the printing configuration if desired.

3. Click OK to print the selected objects.

Tip

You can also print objects programmatically by adding Print control inputs on those objects. This is useful for printing graphical XY display objects.


To Send Data to a Printer

You can send data from your VEE program directly to a printer.

1. Add a To Printer object to your program (I/O [image] To [image] Printer) and connect the data input pin to the source of the data that you want to print.

2. Double-click on the To Printer icon to display the open view containing the I/O transactions that output data.

3. The default output transaction is WRITE TEXT a EOL. If desired, change the transaction to output the data in some other form.

4. Run the program. When the To Printer object operates, the data is output to the printer, which prints the data using the current printing configuration.

Tip

The To Printer object outputs data through the Windows printer driver, which adds a header and changes the fonts. To output straight ASCII text to a printer from VEE for Windows, use the To File object with the file name set to LPT1 (or whichever printer port you are using).

See also

To Edit a File I/O Transaction

To Write Data to a File


To Plot a Graph

To Print a Graph

There is one way that you can print a graph from XY display objects such as the XY Plot or Waveform (Time) objects.

Select the Print command from the object menu of the XY display.


To Add Objects to the UserObject Work Area

Any object that you place inside the work area of a UserObject edit window becomes part of the UserObject. Use any of the following methods:

Select the appropriate object from the menus and place the object in the UserObject.

Move an object from the Main work area to the UserObject.

Use Cut/Copy/Paste to place an object that is highlighted in the Main work area into the UserObject.

Clone an object in the Main work area, moving the clone into the UserObject.

See also

UserObject


To Add Input and Output Terminals to a UserObject

In general, you can add input and output terminals to a UserObject edit window using the same techniques that you would for any other object. The terminals also appear on the UserObject icon as you add them to its edit window.

Using the object menu

From the object menu, select Add Terminal, and then select the type of terminal you want to add: Data Input, Control Input, Data Output, or Error Output. You can use this method to add terminals directly to the UserObject icon or the associated edit window.

Using the mouse and keyboard

To add a data input terminal, place the mouse cursor in the data input terminal area and press Ctrl+A. A data input terminal is added to the UserObject at the cursor location each time you press Ctrl+A.

To add a data output terminal, place the mouse cursor in the data output terminal area and press Ctrl+A. A data output terminal is added to the UserObject at the cursor location each time you press Ctrl+A.

Note

To delete terminals, place the mouse cursor over the terminal area and press Ctrl+D.

See also

UserObject


To Create a UserObject in a Program

The following example shows, step-by-step, how to create a simple UserObject and connect it in a VEE program. Ideally, the objects used together in a UserObject should perform a particular task.

1. Add a UserObject to the Main work area (Device [image] UserObject). A UserObject icon appears. Double-click on the icon to open the UserObject edit window.

2. Add objects to the UserObject work area, and connect the terminals between them as needed.

3. Add and connect the input and output terminals for the UserObject:

a. Place the mouse cursor in the input terminal area of the UserObject and press Ctrl+A. The data input terminal appears in the edit window’s terminal area and on the input side of the UserObject icon.

b. In the edit window, connect the inside pin of the input terminal to the appropriate object inside the UserObject.

c. Place the mouse cursor in the output terminal area of the UserObject and press Ctrl+A. The data output terminal appears in the edit window’s terminal area and on the output side of the UserObject icon.

d. In the edit window, connect the inside pin of the output terminal to the appropriate object inside the UserObject.

e. In the Main Window, connect an external object to the input terminal on the UserObject icon to send data to the UserObject.

f. In the Main Window, connect an external object to the output terminal on the UserObject icon to send data from the UserObject.

4. Change the UserObject title to a descriptive name so you can identify it in the program. Double-click the title bar on the UserObject edit window. In the Properties Window, type in a new title.

5. Run the program to test the UserObject.

The following example shows a program with the UserObject edit window open.

See also

To Add Input and Output Terminals to a UserObject

To Build a UserObject Panel

UserObject


To Create a UserObject from Objects in a Program

Once you have written a VEE program you may decide that you want to make part of the program into a UserObject. This procedure uses an example program to show how to convert several objects in a program into a UserObject.

1. Open the program manual13.vee in your manual examples directory (Help [image] Open Example...). This program changes fields in a record.

2. Select the objects: Set Name Field, and Set Empl_no Field.

To select objects, press and hold the Ctrl key, then click on each object using the left mouse button. The objects are highlighted with shadows when selected.

3. When you are done selecting objects, select Edit [image] Create UserObject. In the Create UserObject dialog box, change the title to Change Record Fields, then click OK.

The new UserObject appears as an icon view in the Main Window and contains all of the terminal connections to the objects inside the UserObject. The UserObject edit window also appears so you can make changes.

4. Run the program.

The following example shows the program with the UserObject edit window open.

See also

To Build a UserObject Panel

UserObject


To Exit a UserObject Early

Normally, a UserObject (or UserFunction) will not complete execution and propagate data on its output terminals until every object inside it has completed execution; however, there are two objects that force propagation to exit a UserObject before all of the objects within the UserObject have operated.

Exit UserObject, when activated, causes an immediate exit from the UserObject context to the context outside it (for example, the Main program).

Raise Error generates a user-defined error message box, and also causes propagation to exit the UserObject. (No data is output from the UserObject unless there is an Error output pin.)

Example

The following procedure shows how to use Exit UserObject using an example program:

1. Open manual26.vee from your manual examples directory (Help [image] Open Example...). Double-click on the Add Random Number object to open the UserObject edit window, then arrange the Main Window and UserObject edit window so you can see all of the objects.

2. To see the order of propagation, turn on Show Data Flow and Show Execution Flow using the toolbar buttons.

3. Run the program. In Add Random Number, the OK and Cancel buttons both become active when the program is run, pausing execution in the UserObject. (The Cancel button is just an OK button with the title changed.) Pressing the buttons cause the following actions:

OK: The upper thread in the UserObject finishes propagating. The A+B object adds its two inputs, the result is propagated to output terminal X, and then the Exit UserObject is activated. The result on terminal X is output to the AlphaNumeric display as the UserObject exits.

Cancel: The Exit UserObject in the lower thread operates. This causes an exit from the UserObject without finishing propagation of the upper thread. No data is output.

See also

Exit UserObject

Raise Error

UserObject


To Create and Use a Library of UserObjects

You can save one or more UserObjects in a file to reuse in other programs.

To create a UserObject library

1. Create the UserObject(s) in your work area.

2. Select the UserObject(s).

3. Select File [image] Save Objects. You'll be prompted for a file name in which to save the UserObject(s).

To use a UserObject library

1. Select File [image] Merge. You'll be prompted for a file name.

2. Select the file name for your library. The UserObject(s) in the file are merged into the work area. Place them where you want them in your program.

See also

To Add Objects to the UserObject Work Area

To Add Input and Output Terminals to a UserObject

To Create a UserObject in a Program

To Create a UserObject from Objects in a Program


To Secure a UserObject

After the design of a UserObject is final, you may want to save a secured version of it. You can then let others add the UserObject to their programs, while preventing them from viewing the contents or changing the UserObject. There are no side-effects to the original UserObject.

1. In the UserObject edit window, select Save Secured Version from the object menu.

2. You will be prompted for a file name in which to save the secured version of the UserObject. Enter a descriptive file name. The .vee file name extension is added automatically.

3. Click on Save.

To use the secured UserObject in a program, use File [image] Merge. You'll be prompted for the file name.

Tips

If the UserObject does not have a panel view, the secured version is displayed as an icon. The icon can be restored to its open view, but the details inside are not visible (except for the terminals). No one can view or edit the contents.

If the UserObject has a panel view, the secured version is displayed as an icon. The icon can be restored to its open view, but only the panel view and the terminals are visible. The detail view is not visible, and the panel view cannot be modified.


To Create a UserFunction in a Program

The following example shows, step-by-step, how to create a simple UserFunction and connect it in a VEE program. Ideally, the objects used together in a UserFunction should perform a particular task.

1. Add a UserFunction to the Main work area (Device [image] UserFunction). A UserFunction edit window appears.

2. Add objects to the UserFunction work area, and connect the terminals between them as needed. You can use the same techniques to add objects to a UserFunction as described in To Add Objects to the UserObject Work Area.

3. Add and connect the input and output terminals for the UserFunction:

a. Place the mouse cursor in the input terminal area of the UserFunction and press Ctrl+A. The data input terminal appears in the edit window’s terminal area.

b. In the edit window, connect the inside pin of the input terminal to the appropriate object inside the UserFunction.

c. Place the mouse cursor in the output terminal area of the UserFunction and press Ctrl+A. The data output terminal appears in the edit window’s terminal area.

d. In the edit window, connect the inside pin of the output terminal to the appropriate object inside the UserFunction.

4. Change the UserFunction title to a descriptive name so you can identify it in the program. Double-click the title bar on the UserFunction edit window. In the Properties Window dialog box, type in a new title. The title cannot contain spaces.

5. Add a Call object to your program. In the UserFunction edit window’s object menu, click on Generate [image] Call. A Call object appears with the title and terminals corresponding to those added to the UserFunction.

Depending on the UserFunction’s purpose, you may want to generate a call to it from one of the other objects in the Generate menu.

6. Connect lines to the input and output terminals on the Call object.

7. Run the program to test the UserFunction.

The following example shows a program with the UserFunction edit window open.

See also

To Build a UserFunction Panel

To Call a UserFunction in a Program

To Create a UserFunction from Objects in a Program

To Edit a UserFunction

UserFunction

VEE Advanced Techniques; chapter: "User-Defined Functions/Libraries"


To Create a UserFunction from Objects in a Program

Once you have written a VEE program you may decide that you want to make part of the program into a UserFunction. This procedure uses an example program to show how to convert several objects in a program into a UserFunction.

1. Open the program manual13.vee in your manual examples directory (Help [image] Open Example...). This program changes fields in a record.

2. Select the objects: Set Name Field, and Set Empl_no Field.

To select objects, press and hold the Ctrl key, then click on each object using the left mouse button. The objects are highlighted with shadows when selected.

3. When you are done selecting objects, select Edit [image] Create UserFunction. In the Create UserFunction dialog box, change the title to ChangeRecordFields, then click OK. UserFunction titles cannot contain spaces.

Two changes occur in the program. The objects are collected into the new UserFunction, and appear in a UserFunction edit window so you can make changes. A Call object appears in the Main Window. All terminal connections are retained.

4. Run the program to test the UserFunction.

The following example shows the program with the UserFunction edit window open, and the Call object in its open view.

See also

To Build a UserFunction Panel

To Call a UserFunction in a Program

To Create a UserFunction in a Program

To Edit a UserFunction

UserFunction

VEE Advanced Techniques; chapter: " User-Defined Functions/Libraries"


To Edit a UserFunction

To edit a UserFunction, the VEE program containing the UserFunction must be open. Then you can change how the function operates in the UserFunction edit window.

To edit a UserFunction

1. Open the program containing the UserFunction you want to edit.

2. Select Edit [image] Edit UserFunction. The Edit UserFunction dialog box appears with a list of all of the UserFunctions in that program.

3. Select the name of the UserFunction you want to edit, and click on OK. The UserFunction edit window appears.

4. Make your changes in the edit window’s work area.

5. Close the edit window. Any changes that you have made will affect all calls to the UserFunction.

Shortcuts

Get the Edit [image] Edit UserFunction menu pick by moving the mouse pointer to an empty space in the work area, then clicking the right mouse button.

Select Edit UserFunction from the object menu of the Call object, which opens the called function’s edit window.

In the Program Explorer, double-click on the UserFunction’s name to open its edit window.

See also

To Call a UserFunction in a Program

To Create a UserFunction in a Program

To Create a UserFunction from Objects in a Program

UserFunction

VEE Advanced Techniques; chapter: "User-Defined Functions/Libraries"


To Call a UserFunction in a Program

Once you have created a UserFunction, you can call it multiple times within a VEE program. This topic uses an example program to show how to call UserFunctions.

Open the program manual51.vee in your manual examples directory (Help [image] Open Example...). This program contains the RandomArray UserFunction, which is called three times:

The Call object calls RandomArray and outputs the returned array.

The Formula object calls RandomArray in the expression 1+RandomArray(). The expression adds 1 to each element of the returned array.

The To File object calls RandomArray in the transaction WRITE CONTAINER RandomArray(). The transaction writes the array returned by RandomArray to the file myFile as a container. The From File object reads the data file and sends the results to the display.

Tips

You can call the RandomArray UserFunction as many times as you like within a program.

Each call of a UserFunction is independent. (In this example, each call to RandomArray generates a different set of random numbers.)

In the Call object, just specify the name of the function to call (for example: RandomArray). However, if you call the UserFunction from an expression, you must use the expression syntax, for example: RandomArray().

UserFunction names are case-insensitive.

UserFunction names must be unique.

You can call a UserFunction name from objects that use expressions, such as the If/Then/Else, To File, and Sequencer objects.

See also

To Create a UserFunction in a Program

To Create a UserFunction from Objects in a Program

To Edit a UserFunction

UserFunction

VEE Advanced Techniques; chapters: "User-Defined Functions/Libraries" and "Using the Sequencer Object"


To Customize the VEE Menus

You can customize the menus in the VEE development environment. The file customMenu.mnu explains how to add items to the menus for special objects and functions you want to use frequently. It also explains how to use the new built-in function help() to add links to custom Help topics for programs you develop.

The file customMenu.mnu is located under the VEE installation directory, in lib. You can open it in an ASCII text editor.

See also

help()


To View Data Flow and Program Execution

You can view data flow and program execution flow in the Detail View of a VEE program while it is running. Data flow and program execution are visible in the Main Window, and in UserObject and UserFunction edit windows.

To view data and execution flow

1. Switch to the Detail View of the context(s) of interest.

2. Click the Show Data Flow and Show Execution Flow buttons on the toolbar.

Show Data Flow button

Show Execution Flow button

3. Run the program to see data and execution flow:

Data flow is indicated by small square markers moving along lines. These markers represent data containers. To change the speed that the markers move, see the next topic below.

Execution flow is shown by highlighting each object as it operates. The highlight is a light green outline around an object as it executes. The highlight changes to dark green after the object executes.

To change the data flow rate

1. Select Default Preferences from the File menu.

2. On the General tab, in the Debug group, click on the Data Flow Rate arrow to show the drop-down list. You can set a rate from 1 (slowest) to 10 (fastest).

3. To save the changes as new defaults VEE.RC, click on Save . Click on OK if you want to use the changes for this VEE session only (until you select File [image] New, Open, or Exit).

Tips

You can show data and execution flow independently by turning only one on at a time.

You can turn these features on and off whether the program is running or not.

Be sure to turn these debug features off when you don't need them. They slow down your program considerably.

The Show Data Flow and Show Execution Flow commands are in the Debug menu. Checkmarks beside the commands show that the features are on.

In VEE 4 and higher execution modes, the debugging features are disabled if the Disable Debug Features default preference is turned on.

See also

Default Preferences

To View the Call Stack


To Control Breakpoints

If you set a breakpoint on an object in your program, the program will pause just before that object operates. Then you can use Line Probe to see the data containers on each line, and you can Step or Resume program execution. Commands are available that let you toggle the breakpoint settings on objects you select, and control breakpoints for your entire program.

To toggle breakpoints

1. Select the objects where you want to change breakpoint settings. To select objects, press and hold the Ctrl key, then click on objects with the left mouse button.

2. Click the Toggle Breakpoint button on the toolbar (Debug [image] Toggle Breakpoint). The breakpoint settings on the objects you selected will be toggled. Breakpoints are cleared if they were previously set, and the objects’ highlighted outlines disappear. Breakpoints are set if they were previously clear, and the objects display highlighted outlines.

Toggle Breakpoint button

3. Run your program. The program pauses just before the object where a breakpoint is set.

4. To continue, click on one of the program-control buttons:

Resume button to resume execution.

Step Into button to step into a UserObject or UserFunction.

Step Over button to step over to the next object.

Step Out button to step out of a UserObject or UserFunction.

Stop button to stop the program.

To activate all breakpoints

1. Click on Debug [image] Activate Breakpoints.

A check mark by the menu command means all breakpoints that are set will be active when you run your program (default).

To clear all breakpoints

1. Click on Debug [image] Clear All Breakpoints.

All breakpoints in your program are cleared and the highlighted outlines disappear from the objects.

Shortcut

Press CTRL+B to toggle breakpoints.

Tips

You can also control an object's breakpoint using Properties from the object menu. On the Behavior category change BreakpointEnabled to True or False to set or clear the object's breakpoint.

In VEE 4 and higher execution modes, the debugging features are disabled if the Disable Debug Features default preference is turned on.

See also

To View the Call Stack

Default Preferences


To Step through a Program

Use the three Step buttons with the other program-control buttons on the toolbar to run your program one object at a time. The program-control buttons are:

Step Into button

Step Over button

Step Out button

Run/Resume button

Pause button

Stop button

Interactions of program-control buttons

From a stopped program, the first time you click a Step button, the program PreRuns. Click the Step Into button to operate each object in turn. The object highlighted with a yellow outline operates next.

Step Into button

If you run your program with a breakpoint enabled, the program will PreRun and then execute up to the breakpoint. From there, you can use the Step Into button to operate each object in turn.

Step Into button

At any point while stepping through a program, you can click the Resume button to continue running the program. To pause the program, click the Pause button. If you then stop the program, it will go through PreRun when restarted.

Resume button

Pause button

Stepping through a UserObject or UserFunction

The three types of Step buttons let you control how the program steps through another context in the program such as a UserObject or UserFunction:

Step Into steps into the context opening the edit window in its Detail View for you to step through the objects in it.

Step Over executes the entire context, stepping to the next object in the program.

Step Out leaves a context you are stepping through by executing all remaining objects in it, then stepping to the next object in the program.

Tip

In VEE 4 and higher execution modes, the debugging features are disabled if the Disable Debug Features default preference is turned on.

See also

To View the Call Stack

Default Preferences


To View the Call Stack

Use the Call Stack dialog box (View [image] Call Stack) to view the next object to execute and the calling context(s) in a paused program. The Call Stack is most useful when kept open while stepping through a program or using breakpoints. You can open and close the Call Stack from the menu or with its toolbar button while the program is paused or stopped.

Call Stack button

The Call Stack dialog box displays the next object to execute in the status line, and lists the current calls to UserObjects or UserFunctions including input variables. The following figure shows the Call Stack with sample data. The next object to execute is Function Generator contained in the UserObject Gen Sine Waves, which is contained in the Main program. Gen Sine Waves has three inputs Freq1, Freq2, and Phase.

Interactions with program controls

When the Call Stack is open, it contains information only when a program is paused. No information is available when a program is running or stopped.

Each time a program pauses, the Call Stack automatically updates, remaining in sync with the program execution flow.

The Call Stack displays information when a program is paused by:

pressing the Pause button.

using the Step Into, Step Over, and Step Out buttons.

a breakpoint setting.

a program execution error.

Accessing Call Stack contents

When a program is paused and the Call Stack is open, the current context is displayed and the next object to execute is highlighted.

To access any context in the current Call Stack list, double-click on the context name, and the program will display it.

See also

To View Data Flow and Program Execution

To Control Breakpoints

To Step through a Progam


To View the Data on a Line

Use the Line Probe command (Debug [image] Line Probe) to view the data container that has been passed on any VEE data line. The program must be paused or stopped.

To probe a line quickly, simply move the mouse pointer over the desired line. The pointer changes shape and a line tip appears summarizing the data. Click on the line to see the Line Value box as shown in the following figure:

If you probe a line on which no data has been transmitted (or on which a sequence pin "ping" has been transmitted), the Line Value dialog box reports Nil (empty) container.


To Find the Endpoints of a Line

Use the Line Probe command (Debug [image] Line Probe) to trace a line and show its endpoints. The program must be paused or stopped.

To probe a line quickly, simply move the mouse pointer over the desired line. The pointer changes shape and the line is highlighted with its endpoints. Click on the line to see the data container.


To Trap an Error

Normally, all VEE errors are reported by the Error Message dialog box. However, you can trap an error generated by a particular object by adding an Error output terminal to that object.

To add an Error output terminal to an object, select Add Terminal [image] Error Output from the object menu.

If an object that has an Error output terminal generates an error, the normal VEE Error Message dialog does not appear. Instead, the Error terminal outputs the error number that must be processed by the program.

There are various ways to use the Error output terminal:

Use the Error output to activate another object, such as Raise Error.

Use If/Then/Else to determine an action based on the error number.

Use errorInfo()to view error information for the last trapped error.

Example

Open the program manual37.vee in your manual examples directory (Help [image] Open Example...). It shows some techniques for trapping errors.

See also

errorInfo()

Error Output (Object Menu)

Raise Error


To View the Last Error

VEE errors are reported by the Error Message dialog box. When an error is reported, you may need to close the error dialog box in order to access the problem in the program. To view the error message again, click on View [image] Last Error.

Errors handled by an Error output terminal on an object cannot be viewed with this command.

The Last Error buffer is cleared when the program is run again or when a new program is loaded.


To Add Structure to Your Program

The following tips show how you can add structure to a VEE program.

1. Analyze what your VEE program does. Can you identify a group of objects that together perform a specific sub-task? Create a UserObject from those objects.

2. Are there sub-tasks that appear multiple times in your program? If so, create a UserFunction to do the task, and call the UserFunction each time it is needed.

3. Proceed through your program, building a hierarchical structure using UserObjects and UserFunctions.

4. If you pass a single data container to several objects, consider using a global variable to pass that data.

See also

To Create a UserObject in a Program

To Create a UserFunction in a Program

UserObject

UserFunction


To Document Your Program

You can make your program easier to use, debug, and maintain by using the following techniques:

1. Give your program a descriptive name. When saving the program, use a file name that indicates its function. This name also appears at the top of the Program Explorer. If the Main Window has a panel view, use its Properties Window to enter a title for the associated Execution Window. This title replaces the file name in the Program Explorer, and appears in the Execution Window’s title bar when you run the program. These names are used with the program-documentation feature Save Documentation.

2. Rename objects to names that are more meaningful to you. For example, Repeat 100x may be more useful than For Count. (In the object’s Properties Window, change the entry for Title.)

3. Rename input and output terminals to descriptive names. For example, if terminal A inputs a flow rate, you may want to change the name to Flow_Rate. (Double-click on the terminal and change the title in the dialog box.) You cannot change the title of some terminals.

4. Add descriptions to key objects and functions by using Description in the object menu. The information may include why you used that particular object, details about the inputs and outputs, and the options that you used on the object. Use short descriptions to keep the program size smaller.

5. Add notes to yourself or others using the Note Pad display object (Display [image] Note Pad). The information could include:

Your name, and phone number, and the date you created the program.

What this program does.

The dates that you made changes and what the changes were.

6. Customize icons, such as UserObject icons, by adding a descriptive bitmap.

7. Use the print commands to make hardcopy printouts of your program. Print commands are on the File menu, the object menus of the Main Window and UserObject/UserFunction edit windows, and on the Program Explorer (click on names with the right mouse button).

See also

To Add a Bitmap to an Icon

To Add a Picture to the Panel

Description

Save Documentation


To Add a Bitmap to an Icon

You can add a bitmap to any iconified VEE object.

To add a standard bitmap

1. Select Properties from the object menu. In the Icon Appearance category, select IconPicture.

2. The available bitmaps in your bitmaps directory are displayed in the Picture group. Scroll through the list and click on the file name that you want. For example, if you click on beep.icn, the Beep icon is shown in the Preview area.

To browse through other directories, click on Browse. The Select File dialog box appears letting you navigate through the directories to select a bitmap file.

3. The following is a UserObject icon with the Beep bitmap:

To add a custom bitmap

The procedure for adding a custom bitmap is the same as for adding one of the standard bitmaps. However, you must first create the bitmap. To create a custom bitmap, use an appropriate bitmap editor for your computer (for example, the Microsoft Paint program). The following file formats are supported:

BMP, ICN, or GIF

The default bitmap directory is:

C:\Program Files\Agilent\VEE Pro 7.0\bitmaps

See also

To Add a Picture to the Panel


To Profile Execution Parameters

Use the Profiler (View [image] Profiler) to collect execution information about a program. The Profiler measures execution parameters regarding the amount of compiler time each context (Main, UserObject, or UserFunction) uses while a program runs. This information is useful when you want to modify your program to maximize efficiency, and improve execution speed. You can open and close the Profiler from the menu or with its toolbar button.

Profiler button

The data in the Profiler display shows the amount of compiler time each context uses to execute. The following figure is an example of a profile including the number of executions for each context with the percentage of time and number of seconds used in the elapsed program time:

To profile a program

1. Open the program.

2. Open the Profiler (View [image] Profiler or use the toolbar button).

If necessary, click Options to change how data is displayed and saved to a file.

3. Click the Start Profiling button on the Profiler. The status indicator PROF is highlighted on the VEE Window status bar. You can leave the Profiler open or close it; once you start the Profiler, it collects data whether it is open or not.

4. Run the program.

5. With the Profiler open, click the Refresh button to update the display.

You can refresh the display during any program state: running, paused, or stopped. New data is always collected while the Profiler is running, but you must refresh the display to see the new data. Data is retained until you click Clear, open another program, or click File [image] New.

To sort the displayed data by column, click a column label to resort the data in reverse order.

6. Click Save to write profile data to a file. You must click Refresh before clicking Save to include the latest data. The saved file includes a calculated total of %Time and Time(sec).

7. Click Stop Profiling to stop collecting data.

Tip

To bring the Main Window, a UserObject, or a UserFunction into view in the work space, double-click the context name in the Profiler display.

See also

Profiler


To Remove Barriers to Program Performance

The following are some general techniques that you may be able to use to improve program execution speed.

Use VEE’s VEE 4 or higher execution modes and disable the debug features on the Default Preferences dialog box. These modes run programs in a compiled execution mode.

On UserObjects and UserFunctions, choose a specific data type and shape required on the data input terminals; do not leave them set to Any. Specifying these parameters helps the program run faster in the VEE 4 and higher execution modes. For other objects, leave data type and shape set to Any. Then, VEE converts data types only when necessary, saving execution time. See Converting Data Types on Input Terminals.

Turn off Clear at PreRun and Clear at Activate on displays where not needed.

Use Initialize at PreRun and Initialize at Activate on data objects instead of setting defaults with control pins.

Collect data for graphical displays into an array, and plot the entire array at once rather than plotting each individual scalar point. If the X values of a plot are regularly spaced, use an XY Trace object rather than an X vs Y Plot object.

Run the program from the panel view. If the panel view contains fewer objects than the detail view, the program will run faster.

Set graphical displays to be as plain as possible. The settings that allow the fastest update times are Grid Type [image] None and all Layout features disabled. Use the Auto Scale control input only when needed, since it slows down a program.

Turn off unnecessary digital displays on indicators such as the Fill Bar, Meter, Tank, and Thermometer objects.

Iconify those objects that continuously update their displays (such as the Timer, Counter, Accumulator, AlphaNumeric, and graphical display objects) if you don't need to see the displayed information.

If using a Strip Chart display, set the buffer size as small as possible.

Collect data for processing into an array, and then process the data as an array.

Use Complex data in expressions rather than PComplex. Most of the math libraries will convert PComplex to Complex, calculate the answer, and convert Complex back to PComplex.

To display PComplex data, set Trig Mode (under File [image] Default Preferences) to Radians. VEE stores PComplex values internally as radians.

If importing libraries of functions (Device [image] Import Library), delete them after the program no longer needs them (Device [image] Delete Library).

For sections of a program requiring fast execution, create compiled functions using a textual programming language.

In general, the fewer objects that need to operate, the faster the program will run. Perform as many functions as possible in each object.

See also

To Reduce the Number of Objects in a Program


To Reduce the Number of Objects in a Program

Many VEE objects can perform a set of functions. Your programs will be more compact, easier to maintain, and will run faster if you use the following techniques:

Enter equations in a Formula object instead of connecting several constant and single-function math objects to input terminals on a Formula. You can nest functions in a Formula object. For example, you can enter the expression (sin(ramp(100, 0, 360))).

Use one If/Then/Else object with multiple conditions (for example, A == B OR A<=C AND A>D) instead of using multiple If/Then/Else or Conditional objects.

To input a one-dimensional array of data, use a Constant object configured as an array instead of using one Constant object for each value and then building an array.

To read all of "the rest" of the data in a file, use the ARRAY 1D TO END:(*) transaction in a From File object. This is simpler and faster than looping on single-element reads and collecting the result into an array.

Use the Sequencer to control the flow of execution of several UserFunctions. Refer to the chapter "Using the Sequencer Object" in VEE Advanced Techniques for further information.

When using the Sequencer, only enable logging for transactions where the Log record is required. If the Log output terminal is not used, delete it to speed up execution slightly.


To Increase I/O Performance

In general, direct I/O provides the fastest I/O performance. To optimize the I/O performance of your VEE program:

1. Create your program using an instrument panel object (or component driver object) to communicate with the instrument. Test and debug the program and instrument configuration.

2. Add a Bus I/O Monitor object to the program. Run the program and "capture" the messages sent to the instrument, and received from it, by the instrument panel or component driver.

3. Rewrite the program so that it uses a Direct I/O object to communicate with the instrument using the "captured" messages. This will speed up I/O performance in the final program. For a long string of instrument commands, consider storing them in a Text object connected to a Direct I/O object’s data input.

4. In cases where extremely fast I/O is required, you can create a compiled function to perform the instrument I/O function. See the chapter, "User-Defined Functions/Libraries" in VEE Advanced Techniques for information.

See also

Bus I/O Monitor

Direct I/O

To Use a Direct I/O Object


What are Panels?

Panel Views (also called panels) are the user interface to your program. You generally create them after you've completed the functional part of your program. The Detail View (your development area) and the Panel View are two views of the same program that appear in the Main Window; just like heads and tails are the two sides of the same coin. You generally copy only display and data input objects to the panel. Only the objects themselves (and not the lines or pins) are displayed. You can then run your program in either view.

After creating a Panel View for your program, the program can also run in a separate execution window in the VEE work space. The execution window runs your program using all of the settings you specify for the Panel View. You can control the execution window’s use with the Main Window’s property Show On Execute. The execution window lets you observe both your program details and the Panel View at the same time, and shows what your finished program will look like when run in VEE RunTime. Only a small subset of menu items are available when the execution window is open to prevent program modification. However, securing your program and running it in VEE RunTime is usually the best way to deliver a finished program to your users. The following three figures show a paused program in its Detail View, the corresponding Panel View, and execution window.

A Detail View

The Corresponding Panel View

The Execution Window

VEE has three types of panels; they all are similar in the way you create, modify, and use them:

Main Panel - The panel associated with the Main context. If an object is in the Main work area, you can select and add it to the Main Panel. Building a Main Panel is described in To Add Objects to a Panel and To Delete Objects from a Panel.

UserObject Panel - Each UserObject can have its own panel. This panel can be used on its own or added to other panels, including the Main Panel. This panel can be visible all the time or popped up (like a dialog box) when the UserObject executes, and the Show Panel on Execute property is checked. Building a UserObject Panel is described in To Build a UserObject Panel.

UserFunction Panel - Each UserFunction can have its own panel (just like a UserObject). This panel pops up when the UserFunction executes, and the Show Panel on Execute property is checked, or when specified via a showPanel() function call. Building a UserFunction Panel is described in To Build a UserFunction Panel.


To Add Objects to a Panel

The Main Panel is the foundation of your user interface. No matter what type of panel you build, you use the same skills you do when building the Main Panel.

1. Put the object in its open view. Most of the time you want the open view on your panel; once the object is on the panel, you can't minimize or open it.

2. Select the object(s) you want added to the panel. You can select objects by pressing CTRL while clicking with the left mouse button on each object, or holding the mouse button down while dragging a selection box to include multiple objects.

3. Click the Add to Panel button on the toolbar ( or use Edit [image] Add To Panel).

Add to Panel button

You will now see the Panel View of your program in the Main Window. Switch between the Panel View and the Detail View by pressing the Panel and Detail buttons on the left side of the Main Window’s title bar. Any time you want to add other objects to the panel, start from the Detail View and follow the steps above.

Note

Though the Main Window can be sized in Detail or Panel View; there are no scroll bars in Panel View. Objects selected from the Detail View are put in relatively the same position when added to the panel, and are moved to fit on the Panel View. You may need to reposition Panel View objects if you resize the window.


To Delete Objects from a Panel

1. Make sure you're in the Panel View.

2. Delete the objects. Select Delete from the object menu of the object

The object remains in the Detail View, but is deleted from the Panel View.

If you delete (Cut) an object from the Detail View, it is automatically deleted from the Panel View.

Note

If you Cut and then Paste objects on the Detail View, any associated Panel View objects are deleted and you'll have to add them to the panel again. Use Copy and Paste instead.

Note

When running a program, certain object menu actions, such as Delete, are not allowed in the Detail and Panel Views, and in the execution window. You must pause or stop the program first.


Changing the Appearance of a Panel

Generally, an object's appearance on the Panel View is unlinked from its appearance on the Detail View. For example, if you change the color of an object on the Panel View, it does not change the color of the associated object on the Detail View (and vice-versa). However, the data displayed and other execution-related information are linked; if changed in one view, it changes in the other. Changes in the Panel View appear in the execution window the next time you run the program.

When an object on the Panel View or the Detail View inherits the default properties that are set in Default Preferences (that is, you haven't changed the object’s colors or fonts properties), the properties will change when the system defaults change. These values are still not linked between Panel and Detail. For instance, an object on Panel can have its color set to gold while its color on Detail remains the default and vice versa.

Properties That Are Not Linked Between Panel and Detail Views

Show Title Bar (if object is shown in the open view)

Layout group properties:

Horizontal

Vertical

Show Digital Display

Show Tic Marks

Rectangular

Circular

Show Digital Display

Show 3-D Border

Scaled

Show Caption

Show Traces Legend

Show Scales Legend

Show Scale Labels

Show Scroll Bars

Show Auto Scale Button

Enable Trace/Scale Editing

Grid Type

Markers

Color Properties: all colors

Font properties: all fonts

Traces: all properties except trace name

Scales: all properties

Label Justification properties

Editing Enabled property (on Note Pad objects)

Format properties:

Radio Buttons | Cyclic Button | List | Drop-Down List | Pop-Up List | Slider List

Button | Check Box | Vertical Paddle | Horizontal Paddle | Vertical Rocker | Horizontal Rocker | Vertical Slide | Horizontal Slide

Limits category properties:

High Color

Mid Color

Low Color

Sub-Range Configuration category properties:

Colors

Icon appearance category tab properties:

Picture file and display mode

Show Title

Layout category properties (available on the Panel View only):

Size & Position (X, Y, Width, Height)

Border

All other properties are linked between Panel and Detail Views (a change in one view changes both views).


To Change an Object's Border Appearance

In the Panel View, you can change the depth appearance of an object by specifying a border option.

1. From the object menu, select Properties.

2. Go to the Appearance category.

3. Choose from the Border options: None, Flat, Sunken, or Raised.

The following figure shows the appearance of the different border styles.

Border Styles

Note: When The Border Is Set to None

When an object’s border is set to None, and the color matches the background color, the object's color extends to where the border would be. You can see where the border is when moving or sizing an object, or if you change the object’s color.

Regardless of the border setting, the object's size does not change. For example, if you've sized an OK object without a border, and then choose to have a border, part of the object text may be obscured by the border. In the following figure, both objects are the same size. The one on the left has Border set to None; the one on the right has Border set to Flat.

A Border Width Example


To Label Areas

To add text to an area on the panel, use the Label object.

1. From the Detail View, select Display [image] Label.

2. From the Label object's object menu, select Properties.

3. Change the title to the desired label text.

4. Select the Label object and select Edit [image] Add To Panel. Position the label where you want it.

The Label object color by default is tied to the default Panel View color (set from File [image] Default Preferences) so that the label background blends invisibly into the Panel View.

You change the label text from either the Detail or Panel View by changing the title text via the Properties window, or programmatically change the label text at run time by adding a data input terminal. You can also change the justification of text by specifying Left, Right, or Center justification via the Properties window.


To Align Objects

When you add an object to the Panel View, its upper-left corner is automatically aligned to a user-definable grid, but the size of the object is not changed. When you move an object on the Panel View, its upper-left corner aligns to the nearest grid detent. To resize the object to the grid, move the cursor to the lower-right corner of the object, get the corner resize cursor, and click. If the corner resize cursor is difficult to use, then use Size on the object menu.

There are several ways to align objects:

1. Select the objects and use Edit > Align or Distribute.

2. Select the objects and, in the Properties window, you can set the size of all the objects.


To Change the Grid Size

1. From the Main Window’s object menu, select Properties.

2. Select the Panel category.

3. Set the PanelGridSize. The smallest grid size is 2.

4. Change PaneDrawGrid to True to see the grid.

When you change grid size, existing objects on the panel do not automatically align to the grid. When you click on an object, its upper-left corner aligns to the nearest grid detent. When you click on the corner resize area, the object resizes to the nearest grid detent. Any Move or Size aligns the object to the current grid size.

You can move or size an object off-grid by holding the Shift key while clicking to move or size the object.

Note

Each panel has its own grid. To change the grid size on a UserObject or UserFunction grid, select Properties from its object menu and then follow the rest of the steps listed above.


To Match Object Sizes

You may want to match the size of one object to the size of another object in the Panel View.

There are several ways to do this:

1. Turn on View > Properties. Select all of the objects. In the Properties window, under the Layout category, set the values for size.

2. Select all of the objects. Move the mouse to the bottom right of one object until the size cursor (double-headed arrow) appears. Hold down the CTRL key while pressing the left mouse button down. Drag all the objects sizes to the desired size. Use Undo if the size is not what you wanted.


To Add a Picture to the Panel

There are two ways to add a graphical image, such as a bitmap, to a Panel View. These methods refer to the Main Window, and can be used with UserObjects, and UserFunctions, too.

To add an image directly to the background of the Panel View

The Panel View must already exist to use this method. A quick way to create a blank Panel View is to click Create Panel on the Main Window’s object menu.

1. From the Main Window’s object menu, select Properties.

2. G to the Panel category. This tab appears after a Panel View has been created.

3. Choose Panel BackgroundPicture, select file.

4. Select a display mode: Actual, Centered, Scaled, or Tiled. See Picture Display Modes below.

5. Click OK.

To place one or more movable and sizable images on the Panel View

1. From the Detail View, select Display [image] Picture. The Picture object appears in the Main work area.

2. From the object menu of the Picture, select Properties.

3. Choose a Picture file.

4. Select a display mode: Actual, Centered, Scaled, or Tiled. See Picture Display Modes below.

5. Click OK.

6. Select the Picture object.

7. Select Edit [image] Add To Panel.

Tip

You can programmatically change the image on a Panel View by adding a data input terminal to the Picture object.

The currently supported graphics formats are:

Bitmap (*.BMP)

GIF87a (*.GIF)

Windows MetaFile (*.WMF)

Portable Network Graphics (*.PNG)

Picture Display Modes

Actual - The picture is displayed in its actual size. The object or panel is resized to the size of the picture.

Centered - The picture is displayed in its actual size. The picture is centered on the object or panel (which remains the same size).

Scaled - The picture scales to the current size of the object or panel. After this choice is selected, the scaling may take a few moments.

Tiled - The picture remains at its actual size, but is repeated horizontally and vertically until it fills the entire object or panel.

The following picture shows the different display modes.

A Picture Object With Different Display Modes

Note

To increase execution speed, VEE caches graphic images. If you've loaded an image into VEE and then changed the file that contains your image, you need to select a different image file, and then re-select the original image file. Once you've done that, the new image is used.


What is a UserObject Panel?

A UserObject Panel is very similar to the Main Window’s Panel. Each has its own context, so each has its own Trig Mode and Edit menu, as well as its own Panel View. A UserObject Panel is more flexible than the Main Panel in the ways it can be displayed.

There are three ways to display UserObject Panels

Independent Panel: A Panel on a UserObject.

This method is useful when you want to bundle your UserObject for someone else to use or to simplify parts of your program for someone else to use without building a Main Panel.

Pop-Up Panel: A panel on a UserObject with Show Panel on Execute specified.

This method is usually used for custom dialog boxes that query for information, and then go away. This type of panel pops up anywhere in a VEE window.

A Panel on the Main Panel: A panel on a UserObject that is then added to the Main Panel.

This method is used to group functionality. You can also nest panels on other panels.

The following figure shows the different types of UserObject Panels.

Three Ways to Display a UserObject Panel


To Build a UserObject Panel

1. In the UserObject’s edit window, select the object(s) by pressing Ctrl, then clicking with the left mouse button on the object(s).

Note
Objects to be put on the UserObject Panel must be in the UserObject's Detail View. You cannot select objects from outside the UserObject boundaries or from nested UserObjects.

2. From the UserObject's Edit menu, select Add To Panel.

Now you've created a UserObject Panel View that is independent of the Main Panel. You switch between the Panel View and the Detail View by pressing the Panel and Detail buttons on the left side of the edit window's title bar. Any time you want to add other objects to the UserObject panel, start from the Detail View and follow the steps above.


To Build a Pop-Up Panel

Once you've created a UserObject Panel, follow these steps to make the panel pop up when the UserObject executes:

1. From the UserObject's object menu, select Properties.

2. In the Pop-Up Panel category, set ShowPanelOnExecute to True.

3. Click OK.

While the program runs and the UserObject executes, the UserObject Panel pops up and is visible on both the Main Window’s Detail View and Panel View (if it exists). If the Main Window property ShowPanelOnExecute is turned on, the UserObject Panel pops up only in the Execution Window.

Note

To change the appearance of the Pop-Up Panel, set the ShowPopUpPanelTitle and ShowPopUpPanel Border properties in the Pop-Up Panel category in the Properties window.

To change the background color of the Panel View, set the BackColor property in the Appearance category of the Properties Window.

Note

You generally use a Pop-Up Panel when creating a custom dialog box. For details, refer to Building a Custom Dialog Box.

If you need a simple dialog box, you may not need to create a Pop-Up Panel. Use one of the Dialog Box objects. For details, refer to About Built-In Dialog Box Objects.


To Keep a Pop-Up Panel Displayed

Once you've created a Pop-Up Panel and run it, you may notice that it flashes up and is instantly gone. This action happens because nothing pauses the execution of the UserObject, therefore you can't see or respond to the information on the Pop-Up Panel. Follow these steps to add an OK button to maintain execution of the UserObject until you click on the button.

1. Select Flow [image] Confirm (OK).

2. Place the OK object on the Detail View of the UserObject.

3. Select the OK object.

4. From the UserObject's Edit menu, select Add To Panel.

Now when you run the program, the UserObject Panel pops up and stays up until you press the OK button.

For details about using OK and Cancel buttons and creating custom dialog boxes, refer to Building a Custom Dialog Box.


To Change the Size of a Pop-Up Panel

The size of a Pop-Up Panel is the size of the Panel View of the UserObject. Follow these steps to change the size.

1. Put the UserObject’s edit window in its Panel View by pressing the Panel button on the left side of the UserObject's title bar.

2. Resize the panel to the desired size.

From the object menu, select Size. Or position your cursor at an edge of the object and resize by dragging the edge.

When you resize the UserObject Panel, you're including the size of the title and border.


To Change the Location of a Pop-Up Panel

The first time you run your program, a Pop-Up Panel is displayed in the center of the VEE work area. You change the location of a Pop-Up Panel by repositioning the panel while the program is running.

1. Press Run.

2. When the panel pops up, drag it to the desired location.

Every time the program is run, the panel will pop up to that location. Note that you can position the Pop-Up Panel to any location, the grid does not affect the location. If the Main Panel property Show on Execute is turned off, you can reposition the UserObject Pop-Up Panel anywhere in the VEE work space. If Show on Execute is turned on, the Pop-Up Panel can be repositioned only within the Execution Window border.

Note

The location of the upper-left corner of the entire Pop-Up Panel stays in the same place regardless of the Pop-Up Panel properties, or whether Show Title Bar and Show Border are selected or not. For example, if you have set the location of a Pop-Up Panel and then turn off Show Title Bar, the panel will shift so that the upper-left corner of the Pop-Up Panel is now located where the upper-left corner of the Pop-Up Panel's title bar was.


To Add a UserObject Panel to the Main Panel

Once you've created a Panel View in a UserObject edit window, follow these steps to add this panel to the Main Panel.

1. In the Main Window’s Detail View, click on the UserObject icon using the right mouse button, then select Restore.

The UserObject icon expands into the Panel View that you created in the UserObject’s edit window.

2. Select the UserObject.

3. Select Edit [image] Add To Panel from the main menu.

Now you'll see the Main Window’s Panel View with the UserObject Panel displayed on it.

You can nest a UserObject Panel on its parent UserObject Panel by following the same steps above, except you must use the Edit menu of the parent UserObject.

Once the UserObject Panel has been added to the Main Panel, change its size, location, and other appearance details the same way you change them for objects on any other panel as described in Changing the Appearance of a Panel and related topics.

Note

When you nest a panel on another panel (as described above), you're making a copy of its contents, and the copy is linked to the original. However, the copy is locked; to change the panel, you must make the changes to the original UserObject Panel. When add or delete objects from the nested panel, or otherwise change the original UserObject Panel, the copy is also changed.


To Add Objects to a Nested UserObject Panel

Once a UserObject Panel has been added to the Main Panel (or to a parent UserObject Panel), you can still add objects to this panel. However, you must add these objects to the original UserObject Panel, then adjust sizes and positions of related objects and panels.

1. Return to the Main Window’s Detail View by pressing the Detail button on the left side of the Main Window title bar.

2. Access the UserObject’s edit window.

If the UserObject is in its icon view, double-click it.

If the UserObject is in its restored view, select Edit UserObject from the object menu.

3. Put the UserObject’s edit window in its Detail View by pressing the Detail button on the left side of the title bar.

4. Add any desired objects to the UserObject’s Detail View.

5. Select the new objects to add to the panel. From the UserObject's Edit menu (click the mouse’s right button), select Add To Panel.

6. Rearrange objects on the UserObject Panel View for a good appearance. You may need to resize the panel.

7. In the Main Window, click on the Panel View button to view the UserObject panel with the new objects. You may need to resize the panel so all objects are visible.


To Delete Objects from a Nested UserObject Panel

1. Return to the Main Window’s Detail View by pressing the Detail button on the left side of the Main Window title bar.

2. Access the UserObject’s edit window.

If the UserObject is in its icon view, double-click it.

If the UserObject is in its restored view, select Edit UserObject from the object menu.

3. Put the UserObject edit window in its Panel View by pressing the Panel button on the left side of its title bar.

4. Delete the objects you want removed from the nested UserObject panel by selecting Delete from their object menus.

The objects still exist in the UserObject’s Detail View. If you want to remove them from the program, delete the objects from the Detail View instead, which also deletes them from the Panel View.

5. Rearrange objects on the UserObject Panel View for a good appearance. You may need to resize the panel.

6. In the Main Window, click on the Panel View button to view the edited UserObject panel. You may need to resize the panel.


To Delete a UserObject Panel from the Main Panel

1. In the Main Window, go to the Panel View by pressing the Panel button on the left of the title bar.

2. Delete the UserObject Panel. From the object menu select Delete or double-click on the object menu button.

The UserObject Panel still exists, but it is no longer added to the Main Window’s Panel View.


What is a UserFunction Panel?

A UserFunction Panel is built and runs basically the same way as a UserObject Panel. However a UserFunction Panel is only visible when the UserFunction is executing (a Pop-Up Panel) or if programmatically displayed via showPanel(). A UserFunction Panel cannot be added to the Main Panel (or parent UserFunction or UserObject Panels).


To Build a UserFunction Panel

If you have a UserFunction and want to create a panel for it, follow these steps.

1. Select the object(s) in the UserFunction’s Edit Window by pressing CTRL, then clicking the left mouse button on the objects you want.

Note
Objects on the UserFunction Panel must be in the UserFunction's Detail View. You cannot select objects from outside the UserFunction boundaries. UserObject Panels nested inside a UserFunction can be added to the UserFunction Panel. For the method to do this, see To Add a UserObject Panel to the Main Panel .

2. From the UserFunction's Edit menu, select Add To Panel.

Now you've created a UserFunction Panel View. Switch between the Panel View and the Detail View by clicking on the buttons at the left end of the UserFunction title bar.

3. Close the UserFunction Edit Window when you are finished editing.

Any time you want to add other objects to the panel, start from the UserFunction's Detail View and follow the previous steps.

Note

If you have already created a UserObject Panel and then made the UserObject into a UserFunction, the UserFunction Panel automatically exists. If the UserObject Panel was added to the Main Panel, it was automatically deleted because a UserFunction Panel cannot be on the Main Panel.


To Build a UserFunction Pop-Up Panel

1. Select Edit [image] Edit UserFunction.

2. Select the UserFunction name.

3. From the UserFunction's object menu, select Properties.

4. In the Pop-Up Panel category, change the ShowPanelOnExecute check box to True.

The UserFunction Pop-Up Panel operates the same way as a UserObject Pop-Up Panel as explained in To Build a Pop-Up Panel.

Note: To Build a Status Panel

A status panel is programmatically popped up with showPanel(). For details refer to Building a Status Panel.


To Change the Size of a UserFunction Pop-Up Panel

1. Select Edit [image] Edit UserFunction.

2. Select the UserFunction name.

3. Switch the UserFunction to its Panel View.

4. Resize the panel to the desired size.

From the object menu, select Size. Or position your cursor on an edge of the object and resize by dragging the edge.

When you resize the UserFunction Panel, you're resizing the entire UserFunction area including the title, and the border.


To Change the Location of a UserFunction Pop-Up Panel

Follow the same steps as with a UserObject Panel shown in To Change the Location of a Pop-Up Panel.


Making Your Panel Keyboard Navigable

Perhaps your users prefer to navigate around the Panel View using only the keyboard or perhaps they do not have access to a mouse in their environment. For these users, build a panel that is keyboard navigable.

In general, when using the keyboard to run a program, first an object must get focus, then the object's data value or state can be changed.

Definition

Focus is a term indicating a location where you can perform an action. In VEE, the object or field that has focus is either surrounded by a marquee (a dotted rectangle) or, for a type-in field, a vertical caret is shown and existing text is shown in inverted colors (text is selected) if the object was tabbed to; if an object was clicked-on, it gets focus but the appearance of the existing text is not changed.

There are several things to remember about keyboard navigation:

It's hard for the user to tell when the object on the Panel View has operated (except OK buttons which are grayed out unless they can be selected). Inform the user that an object has operated or have the user indicate when they have finished making changes (for example, by pressing an OK button).

Without a mouse, the user can't access an object's object menu (this access is useful with Display object menu choices such as Zoom and Auto Scale). You can add control input terminals for some of these parameters, if you need to let your user use them.

You can specify the tab order of tabbing through a Panel View. The pattern is discussed in Panel View Navigation Techniques.

Different objects have different rules for keyboard interaction. You must tell the user what they are; see Panel View Selection Techniques for details.


To Give Focus to an Object or Panel

Some information about focus

You can set the tab order of the objects on each panel. On each object, set the Properties for TabIndex and TabStop.

You can modify the data on an object only when it has focus.

When a panel pops up, only objects on the Pop-Up Panel get focus until the panel is closed.

Only objects with data fields, buttons, or a selection area can get focus. Note that every data field, button, or selection area can be tabbed into.

For example, if you have a Slider on the panel (as shown in the following figure); the first Tab gives focus to the MinValue field.

A Slider on a Panel

To prevent users from tabbing through these fields and changing them, add control input terminals for fields such as MinValue and MaxValue.

Selection Control, Toggle Control, and Slider objects execute as soon as the program starts to run unless the Wait for Input property has been set. This property allows these objects to execute only after they get focus and have values changed or selected.

If Esc or Enter is assigned to an OK button and then pressed, the OK button gets and keeps the focus.

If a function key is assigned to an OK button and then pressed, the focus stays on the object that had focus before the function key was pressed.

Note

Do not use VEE's built-in Dialog Box objects on a keyboard-driven panel that contains other objects. After the Dialog Box object stops executing, no other object gets focus, so you can't navigate to other objects via the keyboard. For information about Dialog Box objects, refer to About Built-In Dialog Box Objects.


To Assign an OK Button to the Enter or Esc Key

When you create a panel, you can assign a Confirm (OK) button to the Enter and Esc keys on the keyboard. This lets anyone using your program press a specific keyboard key rather than the Confirm (OK) button. Otherwise, the user must Tab to the button and press Space. This feature is especially useful on custom dialog boxes made from Pop-Up Panels. For more information about building custom dialog boxes refer to Building a Custom Dialog Box.

To assign these keyboard keys to Confirm (OK), follow these steps:

1. Select Flow [image] Confirm (OK).

2. Add the Confirm (OK) button to the panel.

3. From the OK button's object menu, select Properties.

4. Select Assign to [Enter] Key and/or Assign to [Esc] Key to True.

Note
You can assign the Enter key to only one OK button per context and you can assign the Esc key to only one OK button per context. If you assign either of these keys to more then one OK button per context, the previous assignment is automatically turned off.

5. Changes take effect immediately.

When the program runs, any OK button assigned to Enter has its label appear in a bold font to indicate that it is the default button.

Note
The Enter and Esc keys can only have a Confirm (OK) button assigned to them from the Panel View of your program (or UserObject/UserFunction). To assign Confirm (OK) to other keys, see To Assign a Button to a Function Key.


To Assign a Button to a Function Key

When you create a panel, you can assign a Confirm (OK) button to a function key (F1, F2, F3, etc. at the top of the keyboard). This lets anyone using your program press a specific keyboard key that is equivalent to the Confirm (OK) button. Otherwise, the user would have to Tab to the button and press Space. To assign keyboard function keys to Confirm (OK), follow these steps:

1. Select Flow [image] Confirm (OK).

2. Add the Confirm (OK) button to the panel.

3. From the OK button's object menu, select Properties.

4. Select the Assign to Function Key dropdown.

5. Select the function key to assign to this OK button (F1 through F12). Some keyboards have only eight function keys, but VEE allows you to select any of the choices to allow cross-platform development; see General Tips for more information. In Windows, the F10 key is a reserved key that functions the same as Alt.

Note
You can assign a specific function key to multiple OK buttons. When the function key is pressed, all of the associated buttons that are currently active will operate.

The title of the OK button is automatically changed to reflect the function key assignment. You can change the title to exclude the function key information.

Note
You can use function keys to press an OK button from either the Panel View or the Detail View. Key assignments also work in the execution window when the ShowPanelonExecute property is turned on for the Main Window.


Panel View Navigation Techniques

To navigate around a Panel View, use the Tab key to go forward and Shift+Tab to go back.

For Earlier Versions

Beginning in VEE version 7.0, you can configure the tab order of objects on panels. Via the Properties window, you can set the TabIndex and TabStop values for each object on a panel. You can do this for new programs, and for pre-7.0 programs.

Note: Pre-7.0 programs loaded into VEE 7.0 and later, are, by default, set to the TabIndex property of each object on a panel according to the algorithm in the section below “Tab Order in Programs created in VEE 6.2 and earlier”. Thus, old programs will execute in 7.0 with the same behavior as in prior versions of VEE.

Programs loaded into 7.0 may be modified to explicitly set the TabIndex value for objects on each panel. The object with property TabIndex set to value zero (0) is the first object that is tabbed to when that panel pops up. Note: multiple objects on the same panel can have the same TabIndex value (z-order of these objects then determines tab order). This behavior is not recommended but is allowed.

TabStop is used to remove an object from the tabbing order. Some objects, which do not allow any operator input, such as an AlphaNumeric display, have their TabStop value set to false. Other objects can have this property set to false if the desired behavior is to have the object appear on a panel but not allow the operator to tab to that object.

When editing a program in VEE 7.0 and later, new objects added to panel will by default have their TabStop property set to one higher than the existing highest TabStop value on that panel. For example, if you have a panel with three objects with their TabStops set to 0, 1 and 2, and you add another object to that panel, the new object by default will have its TabStop property set to 3.

When a panel is executed, the object with TabIndex zero (or the lowest value) is given initial focus. Tabbing will then proceed to the object with the next TabIndex value, progressing from zero to the maximum TabIndex value.

For older versions (6.2 and prior), the order in which the objects and panels are traversed is as follows:

After you press Run, VEE divides the panel into groups of objects. The first group is determined by the topmost (lowest y-coordinate value) object and contains all objects that have a y coordinate close to that of the topmost object. The first object to get focus is the leftmost object in the group. Tab moves the focus from left to right.

Note
If the leftmost object has Auto Execute set, it does not get the focus first, but you can Tab to the object.

The y-position of an object or panel is determined by the location of its upper-left corner.

Once the focus has gone as far right as it can in the first group, it continues with the leftmost object in the next group.

The next group is determined by the topmost object that was not in the previous group. Tab starts at the leftmost object in this group and continues to the right. This ordering repeats throughout the panel.

The following figure shows a typical grouping of objects.

A Simple Tabbing Order Example for Programs Created in VEE 6.2 and Earlier

The following figure shows a more complex grouping of objects. At first it appears that the Third Text object should be included in the first group. But the first group is determined by the Second Text object, therefore the Third Text object is too far down to fit into the first group.

The third group is determined by the Fifth Text object. The Fourth and Sixth objects are close enough to be in that group.

A Complex Tabbing Order Example

Note
An OK button can only be tabbed to when it is activated (when the text is not grayed out).

If an object has multiple fields, Tab takes you through all the fields before going to the next object.

If you are in a UserObject Panel nested on another panel, Tab takes you through all the objects in the UserObject before continuing to the next object out of the UserObject Panel.

If you are in a Pop-Up Panel (UserObject or UserFunction), you can Tab only within the Pop-Up Panel until it finishes executing.

Remember that you can Tab to objects whether or not they've executed (except OK objects).


Panel View Selection Techniques

When using a mouse, you click to select a choice or change a value. When using a keyboard, you tab to the object to give it focus and then you select a choice or change a value by using the following techniques:

Radio Buttons and List:

and [image] to select a choice.

Space to select the current choice.

Cyclic Button:

Space to change the choice.

Drop-Down List:

to get the list.

and [image] to select a choice.

Space or Return to put the list away.

Esc to cancel the choice.

Pop-Up List:

Space to get the list.

and [image] to select a choice.

Space or Return to put the list away.

Esc to cancel the choice.

All Toggle Control objects:

Space to change the value.

All Edit Fields (such as Constant objects):

Type in a new value.

Tab or Enter to continue to the next field.

Esc cancel the changes.

Start and OK Buttons:

Space to select them.

Objects with multiple fields (such as Function Generator):

Select a choice or change a value using one of the techniques listed above depending on the type of field, then Tab to the next field.

Note

If you have Esc or Enter assigned to an OK object and you use Esc or Enter in an edit field (such as in Constant and Slider objects), the OK button will be pressed after the edit field data is entered.

When a Data [image] object has Wait For Input set, it executes when you select a choice or change a value as described above. When a Data [image] object has Auto Execute set, it starts the thread running when you select a choice or change a value as described above. To see an example that demonstrates Wait for Input, refer to To Build a Self-Modifying Panel.

Note

Data in Data [image] Constant and Data [image] Slider objects must be changed for Wait For Input or Auto Execute to work. Replacing a character with the same character is interpreted as a change.


Most Important

The topics about developing good user interfaces contain guidelines and general interface design information. This information is not a substitute for Human Factors help or comments from users.

Get advice from a professional user-interface designer such as a Human Factors engineer or graphical designer. The information in this section contains only rough guidelines. If you have access to a user-interface designer, ask them to look at your Panel Views and give you comments.

Get user feedback. Let your users use the panel. Ask them if they can find the information needed. Make sure they can identify what they should do. Verify that the colors and fonts are useful and that they allow comfortable long-term use.

General User Interface Design Guidelines

Know your users and their environment.

Empower users. Let them control the basic characteristics of the program. Minimize the number of rules users must learn to use the system.

Be consistent in user interactions, data presentation, and layout. Group and order the information displayed.

Accommodate different levels of users via defaults, help, or templates for novice or intermittent users, and accelerators or shortcuts for advanced or frequent users.

Build users' confidence. Help them accomplish their tasks quickly and without frustration. Do not use accusative wording like user error.

Provide feedback to users. Let them confirm data input or directly see the result of their actions.

Orient users. Provide them with enough information to understand the current state of the program and how to respond to this state.

Design for error recovery. When users make mistakes, they need a chance to recover from them.

Verify your design with the real users of the program.


Using Colors

When using colors in your panels, consider the limitations of colors for your audience and the specific uses for color.

Facts about Colors

Older people are often less sensitive to color and may need brighter color levels. The ability to discern shades of blue may be diminished. However, younger users may find brighter colors more fatiguing.

Eight percent of men and 0.5 percent of women have some form of color deficiency. The most common deficiency is an inability to distinguish between red and green.

There are individual variations in color perception. Different monitors, different environmental lighting, cultural and occupational connotations, and personal preferences for colors can all affect the way people see, distinguish, and perceive color.

Be aware that colors have different meanings in different cultures; it's best to use neutral colors for large areas.

Note: Redundant Cues

Because of the reasons listed above, use color only as an additional form of communication. For example, to distinguish a Stop from a Go button, don't just change the color from Red to Green; also make sure there is explanatory text that changes. One way to make sure your color is used as a redundant cue is to first create the panel without specifying colors, and then add them as needed.

Use as few colors as possible. More than four or five different colors on a single panel or seven different colors in your entire user interface, may be distracting and confusing.

Colors project an image about your program. Bright colors may project a toy-like quality. Muted or subtle colors may create an impression of sophistication or professionalism.

For background and text (foreground) combinations, use colors that have high contrast; but avoid putting colors from opposite sides of the color wheel together (like yellow and blue). The contrast is good, but boundaries may bleed into one another. The following figure shows the colors on a color wheel.

A Color Wheel

Use generally-accepted color encodings, such as Green for Go or Normal Status and Red for Stop or Emergency. This color coding may be dependent on cultural or occupational standards.

Consider the printing needs of your audience. If the user prints a color screen to a color printer, the colors on the printer won't necessarily match those on the screen due to printer limitations. If the screen is printed to a non-color printer, make sure the colors translate well to black and white. Note that on the Default Preferences Properties dialog box, the Printing tab Screen Element settings do not apply to color changes from the default colors. When you've changed colors from the defaults, VEE automatically gray-scales the colors on the printout.

So if it's so troublesome, why use color?

To enhance the aesthetics. An interface with pleasant-looking colors is easier to operate and view for long periods of time.

To group objects together visually.

To aid navigation and recognition.

To enhance readability.

To show what is similar and what is different. Different colors distinguish different groups of information from each other.

To call attention to an object or event. It's easy to find information if it is colored differently.

To accentuate information encoding. Color information can aid understanding, especially when using common encodings like Yellow for caution, Red for danger or failed, Blue for water or cooling.

Use a basic overall color scheme, keeping similar functions the same color and only use contrasting colors when needed.


How to Pick Colors

Here are some guidelines to help you pick colors that enhance the usability and readability of your panel.

Generally you want to use a neutral-colored background, White or Gray is best. However, lighter colored backgrounds increase the perception of flicker (the amount depends on the system monitor). Shades of Blue are also very good for backgrounds (for both objects and panels).

If your background color is too light, the border highlight of a 3-D object may not stand out. If the background color is too dark, the object's border shadow may not stand out.

When displaying text, pick colors that have good contrast with the background. For example, if the background color is White, the following colors are the best and worst for text:

Black - Best

Blue - Best

Red - Best

Yellow - Worst (low contrast)

Cyan - Worst (low contrast)

If the background color is Black, the following colors are the best and worst for text:

Yellow - Best

White - Best

Green - Best

Blue - Worst

Red - Worst (may bleed into the background)

Magenta - Worst (may bleed into the background)

Note that on VEE display objects (such as X vs Y), the default background color for the graph is black, and you'll want to pick good colors for the graph’s grid lines. You can also change the trace line and point types to distinguish the graph traces.

The following figure shows how these colors can be used:

Displaying Different Color Text

This program is saved as colors.vee in your manual examples directory. Open this example to see what these colors look like on your screen.

Regardless of the background color, make sure that the color of the text displayed is about the same level of brightness and has good contrast. These guidelines for object background and text also apply to panel backgrounds and objects placed on them.

Generally, shades of Blue work best as a background. To use Blue as a text color, use a greenish blue (like Teal).


Using Fonts

Facts about Fonts

It takes users about 25% more time to read text on a computer screen than on paper. Comprehension is about the same. Therefore, putting large amounts of text on your panel will slow down your user.

There are proportional and non-proportional fonts. A proportional font uses different widths for different letters; for example, the space used to print the letter w is wider than the space used to print the letter i. Proportional fonts are generally easier to read and look better. Some common proportional fonts are: Lucida*, Arial*, and Time New Roman*.

A non-proportional font uses the same width for all letters and is used when you need to vertically align data in a table. Some common non-proportional fonts (also called mono-spaced fonts) are Courier and Courier New.

The fonts available in VEE depend on the fonts installed on your system.

Font size indicates the height of characters, not the width. So if you change the font type, but keep the font size the same, you may have to resize the object to accommodate the text width.

Generally, use a 12-point font size for text meant for general reading. You may want to use a larger font or a bold font for emphasis. Although font size on paper is an absolute size (like inches or centimeters), fonts on a computer screen are based on logical font size, which varies according to your monitor resolution. So no matter what size font you use, you'll need to make sure it is readable on the screen. The following figure shows different font sizes.

Font Sizes

Some studies show that serif fonts (those with thin lines at the top and/or bottom of the main strokes of the letter) allow the user to read faster than sans serif fonts. You'll need to see if this makes a difference for your users. The following figure shows a serif and a sans serif font.

Serif and Sans Serif Fonts

Text is faster to read if it is left-justified with a ragged right margin.

Use no more than three different font types, and four font colors per program. Use fonts consistently to help the user understand which text is more important. Generally, larger text is the most important.

Use font types and sizes consistently to make it easier for you to align and balance the text across the screen.

Blue is generally a bad color for text - the eye is least sensitive to this color.

Verify your font choices with the users of your program to ensure legibility.

* Arial and Times New Roman fonts are products of the Monotype Corporation.
Lucida font is a product of Bigelow & Holmes, Inc.


Layout Tips

Maintain a consistent layout even as the panel's content changes. For example, if you have a message area at the bottom of the screen, a display area on the side, and a status area at the top - stay with this layout; don't move elements around as the program runs.

Group related information.

Balance information through the available screen area.

Remember to leave white space (blank areas without objects) to make your panel easier to use. If the screen is full, with objects positioned against other objects with no space between them, it is harder for your user to find needed information.

Always place navigation controls in the same place on every panel.

Align and size objects in related groups so they are the same size. Align them horizontally or vertically so that there is not a ragged edge to disrupt identifying and scanning the objects. Make the spacing between objects a constant distance.

Use dialog boxes to present infrequent or low-use features. This lets the user respond and be done with this information, and reduces clutter on the Main Panel.


To Call Attention to an Object

Use visual attributes to call attention to areas on the screen:

Use object size. The eye is naturally drawn to larger objects. There also is a connotation of importance. If you are differentiating information by size, use a maximum of five different sizes.

Use border characteristics to distinguish objects. Use lighter colors on the raised surfaces and darker colors on the recessed surfaces. To see the different border styles, refer to the figure Border Styles.

Use different colors to indicate different levels of importance. You should use a maximum of four or five different colors on a panel. And a maximum of seven different colors in your entire user interface. If you decide to use more, supply a legend to explain each color's purpose or meaning.

For fine details or small areas, black, white, and gray give the best readability.

Brighter colors attract more attention than dimmer colors (for example, using Blue, Yellow, or Red, instead of Blue Gray, Gold, or Light Red). Users can differentiate between a maximum of five different brightness levels.

Lighter colors and warmer colors (such as Red) appear to advance to the user. Darker colors and cooler colors (such as Blue) appear to recede.

Use font size. Use at least four points of size difference to denote relative importance.

Use font styles such as bold and italics. Italics makes text slower to read, so don't use italics for text requiring quick reading.

Blinking/Flashing is an excellent way to get attention. With VEE, some ways to direct attention are to pop-up a panel, change bitmaps in a Picture object, change colors and text in a Color Alarm object, or use a Dialog Box object. No more than four items should be blinking or flashing at a time.

Another way to draw attention is to use sound. Use the Beep object (if the hardware supports it).

Each of these attributes should be used in a consistent way throughout your program.


About Built-In Dialog Box Objects

Before creating a custom dialog box, consider if the built-in Dialog Box objects (located under the Data menu) will meet your needs. They are easy to use and have many useful features.

The differences between Dialog Box objects and Pop-Up Panels (used to build custom dialog boxes) are:

Dialog Box objects do not need to be added to a panel, they pop up automatically. The following figure shows a Message Box object and the panel it generates.

A Message Box

Dialog Box objects perform only one operation per object - they ask for specific user input. If you need to ask the user several questions at once, or to display data, then create a custom dialog box.

Dialog Box objects are modal. In other words, while they are popped up, the rest of the program is stopped. This is different than Pop-Up Panels; while Pop-Up Panels are popped up, the rest of the program continues to execute.

Dialog Box objects should not be used on a keyboard-driven panel. After they finish executing, no other object gets focus, so you can't navigate to other objects via the keyboard.

Dialog Box objects already have many built-in features. You don't have to write a program to get features such as constraint checking or timeouts. The built-in features of the Dialog Box objects are listed in the following table:

Dialog Box Object Features

_________________________________________________________________________________________________

Dialog Box Object

Constraint Checking

Password Masking

Timeout

Custom Button Text

Formatting Options

_________________________________________________________________________________________________

Text Input Gets text input | X | X | X | X | X Field Width
Int32 Input Gets integer input | X | X | X | X | X Field Width
Real64 Input Gets real input | X | X | X | X | X Field Width
Message Box Displays information | n.a. | n.a. | X | X | X Multiple Line Messages
List Box Allows single or multiple selection from a list | n.a. | n.a. | X | X | X List Height
File Name Selection Allows file name selection | X[1] | n.a. | n.a. | n.a. | n.a.

_________________________________________________________________________________________________

1 Gives a warning if overwriting an existing file. Doesn't allow opening a non-existent file.

Dialog Box objects have additional color and font properties so you can easily control the appearance of the pop-up panel. The following figure shows these properties.

Message Box Properties on the Colors and Fonts

Dialog Box objects are easy to use without a mouse. You press the Enter key to press the default button; or press the Esc key to press the rightmost button (usually Cancel). Use Tab and Shift+Tab to move the focus to input fields or buttons. Press Space to press a button that has focus. Refer to Making Your Panel Keyboard Navigable for information about focus.

For more details refer to Dialog Box, and To Output a Value on Timeout.


To Output a Value on Timeout

When you set a Timeout on a Dialog Box object (via the Properties dialog box), and the timeout period expires, the value 1 is output on the Timeout data output pin. Often you want a value (such as the Default value) output when the timeout period expires; to do this, follow these steps, which use a Text Input dialog box:

1. Set the Timeout.

Select Properties from the object menu. Select the Timeout Enabled check box. Set the Pop-Up Duration. Click OK.

2. Add the Default Value data input pin.

3. Select Data [image] Constant [image] Text to input the default value. (Select a Data [image] Constant object appropriate to your needs to input the default value.)

4. Input the default value into the Text object.

5. Connect the Text data output pin to the Default Value data input pin.

6. Select Flow [image] Gate.

7. Connect the data output pin of the Text to the data input pin of the Gate.

8. Connect the Timeout data output pin to the sequence input pin of the Gate. When the timeout period expires, the default value is output through the Gate.

The following figure shows a program that uses a JCT object to output either the entered value or the default value if the timeout occurred. This program is saved as timeout.vee in your manual examples directory.

Outputting a Default Value on Timeout


Building a Custom Dialog Box

When a built-in Dialog Box object doesn't fit your needs, create a custom dialog box. The following topics explain how to create custom dialog boxes from Pop-Up Panels. Once they are created, you add the controls, displays or other objects as needed. If you prefer not to build programs by following the steps below, open the files (via Help [image] Open Example) that contain the dialog box programs and modify them to suit your needs.

To create a Pop-Up Panel, follow the steps in To Build a UserObject Panel. You can make the Pop-Up Panel from either a UserObject or a UserFunction. Unless otherwise specified, the instructions for this group of topics assume the use of a UserObject.


To Build a Basic Dialog Box

1. Once you've built a Pop-Up Panel, follow the steps in To Keep a Pop-Up Panel Displayed twice. The first time to add an OK object so that users can confirm their choices, and the second time to add an OK object to be the Cancel button so that users can cancel their choices.

2. Assign the Enter key to the OK button and the Esc key to the Cancel button.

Select Properties for the first OK object and change the AssignToEnterButton property to True.

Select Properties from the second OK object's object menu. Change the Title to Cancel and change the Assign to [Esc] key check box to True.

Now the OK button is assigned to the Enter key (by default) and the Cancel button is assigned to the Esc key.

3. Select Flow [image] Exit UserObject and place it in the Detail View of the UserObject.

4. Connect the data output pin of the Cancel button to the sequence input pin of Exit UserObject.

5. Select Data [image] Constant [image] Text. (This could be any object to get user input.)

6. Connect the data output pin of the OK button to the sequence input pin of the Text object.

7. Create a data output terminal on the UserObject.

8. Connect the data output pin of the Text object to the data output pin of the UserObject.

9. Select Flow [image] Exit UserObject.

10. Connect the sequence output pin of the Text object to the sequence input pin of the Exit UserObject.

Now the dialog box outputs the value if OK (or Enter) is pressed. No value is output if Cancel (or Esc) is pressed.

The following figure shows the program created using these steps.

A Basic Custom Dialog Box

This program is saved as dialog1.vee in your manual examples directory.

Details about this example:

The OK button must be connected to the Text object; if it was not, the Text object would operate as soon as the UserObject began to run. Therefore, the default data would get propagated to the UserObject output data pin. The OK button prevents the Text object from operating until the user, after typing in the Text object, presses OK.

The threads with OK and Cancel must be connected to Exit UserObject objects. If they were not, the user would have to press both OK and Cancel for data to be output from the UserObject, because a UserObject does not propagate its output data until all objects inside it have finished operating.

To see these execution principles demonstrated, follow these steps:

1. Select the Show Execution Flow toolbar button.

2. Show the UserObject’s edit window in its Detail View.

3. Run the program.


To Set a Timeout

If you want to have the dialog box go away after a period of time, set a timeout. Follow these steps to add a timeout to the custom dialog box created in To Build a Basic Dialog Box.

1. Select Flow [image] Delay and place it in the Detail View of the UserObject.

2. Select Flow [image] Exit UserObject.

3. Connect the sequence output pin of the Delay object to the sequence input pin of the Exit UserObject.

4. Specify the pop-up duration (in seconds) in the Delay edit field. When the time is up, the Pop-Up Panel is put away.

5. Add a second data output terminal to the UserObject.

6. Connect the Delay object's data output pin to the second data output pin to make it available for use in the Main context.

When the timeout period expires, an empty container is output on this terminal.

The following figure shows the program created using these steps.

A Dialog Box With a Timeout

This program is saved as dialog2.vee in your manual examples directory.

When the timeout expires in dialog2.vee, no value is output from the UserObject. Often you want the UserObject to output the default value when it times out as shown in the following figure.

The Default Value is Output When the Timeout Period Expires

This program is saved as dialog3.vee in your manual examples directory.


To Check for Valid Data

The following figure shows a program that checks the input value against some constraint, before outputting the value. If the value does not meet the constraint, another dialog box pops up to inform the user.

A Dialog Box With Constraint Checking

This program is saved as dialog4.vee in your manual examples directory.

The important aspects of this example are:

The Until Break object allows you to retype a number after the Error Pop-Up Panel executes, or to retype a number after the Enter a number... object has already executed once.

The Error Pop-Up Panel is a UserObject Pop-Up Panel that displays a message, and responds to Enter or Esc. It times out after five seconds.


To Build a Self-Modifying Panel

To have a panel present choices to the user based on previous user selections, create a self-modifying panel.

The following figure shows a program that changes the choices in a Drop-Down List, based on the selection made in a Radio Buttons object. The Pop-Up Panel is shown in the upper right of the figure.

A Self-Modifying Panel

This program is saved as dialog5.vee in your manual examples directory.

The important aspects of this example are:

The Select a Product (Radio Buttons) object has Wait for Input set in its Properties window.

Phantom Tests, Beetle Tests, and Viper Tests are Text arrays that contain the list of tests to input to the Select the test to run, Drop-Down List object via an Enum Values control input pin.

Select the test to run has Wait for Input set on its Properties window to hold off sending data to the Gate until a test number is chosen after a product selection.


Building a Status Panel

To display a status panel while your tests run and to update it with current test data, use a UserFunction Panel. Show it with the showPanel object and run it with the Call object.

When you use showPanel, you cannot use Show Panel On Execute (in the UserFunction Properties window). The following table summarizes the differences between the way showPanel and Show Panel On Execute execute.

Differences Between showPanel and Show Panel On Execute

_________________________________________________________________________________________________

showPanel

Show Panel On Execute

_________________________________________________________________________________________________

The panel stays up until a hidePanel object is executed or the program stops. | The panel stays up until the UserFunction is finished executing or the program stops.
The UserFunction is executed with Call, and the panel is displayed with showPanel. Therefore, the UserFunction can be executed multiple times while the panel remains visible. | The UserFunction is executed and the panel is displayed with Call. Therefore, each time the UserFunction is called, the panel is automatically displayed; after the UserFunction has finished executing, the panel is automatically hidden.
The displayed position can be set programmatically at run time. | The displayed position is set manually at development time.
The displayed panel size can be different than the size of the Panel View. | The displayed panel size is the same size as the Panel View.
The user cannot move the panel when it's visible. | The user can move the panel when it's visible.

_________________________________________________________________________________________________


To Build a Status Panel

Build a status panel by building a UserFunction Panel as described in To Build a UserFunction Panel. When the UserFunction’s edit window is open, make sure the ShowPanelOnExecute check box is not set in its Properties window.


To Show a Status Panel

Use the showPanel object to show a status panel.

1. Select Device [image] Function & Object Browser. In the Function & Object Browser, select Type: Built-in Functions, then Member: showPanel.

The showPanel object appears with a formula containing five parameters and their associated terminals for the UserFunction name, position, and size. You can connect objects containing data to the input terminals, or you can edit the parameters directly and delete the inputs.

2. Type the UserFunction name between the quotes, replacing UFname.

3. To specify a location, type the x and y coordinates to specify the position in the VEE window of the UserFunction Panel's upper-left corner. The coordinates for the upper-left corner of the VEE window is 0, 0. The edit field on the showPanel object looks like: showPanel(MyFunc,300,300).

If you do not specify a location, the panel is displayed in the center of the screen.

4. To specify the size of the panel displayed, you must have specified the location. Specify the width and height of the panel in pixels.

If this size is smaller than the existing UserFunction Panel View, the upper-left part of the panel is displayed. If the size specified is bigger than the existing Panel View, the panel displayed has additional area added on its bottom right.

If there is a background picture, it is displayed in the size specified, and is shown according to its display mode. For example, if the display mode is Scaled, the background image is scaled to the size specified in the showPanel object.

When you specify the location and size, the edit field on the showPanel object looks like: showPanel(MyFunc,300,300,100,100).

You can display only one panel for each UserFunction. If you execute a second showPanel, the first panel is hidden and the panel is shown as specified in the second showPanel call.


To Hide a Status Panel

When the program finishes executing, all panels shown with showPanel are no longer displayed. To hide a panel while the program is running, follow these steps:

1. Select Device [image] Function & Object Browser. In the Function & Object Browser, select Type: Built-in Functions, then Member: hidePanel.

2. Type the UserFunction name between the quotes, replacing UFname. When this object operates, the named panel is hidden.


To Update a Status Panel

The showPanel object only shows the panel; it does not execute the UserFunction. Use the Call object (located in Device [image] Call) to send new data to the status panel and update the display. You can also call the UserFunction from any expression such as in a Formula or a Sequencer object.

You can also use showPanel in any expression such as in a Formula or a Sequencer object. For example, use showPanel as an expression in the first transaction of a Sequencer. As each test runs, the data on the status panel is updated. Use hidePanel in the last transaction of the Sequencer.

After you've sent new data via the Call object, you do not need to call showPanel again; the contents of the displayed panel are updated automatically.


A Status Panel Example

The following figure shows a simple status panel that is updated with information. After you make a choice in the List Box object, the data associated with that test is displayed on the panel.

A Status Panel

The following figure shows the program that displays the status panel. This program is saved as status.vee in your manual examples directory.

A Status Panel Example Program

The important aspects of this example are:

The Record constant sets the record of test results. This could be the log output from a test function.

The Until Break object lets you choose the test information multiple times.

The Get Field object resets the List Box to the value selected in the last iteration.

When the Done button is pressed on the List Box, the status panel is hidden and the Until Break loop is completed.

The UserFunction contains a Panel View that is updated each time the UserFunction is called.

The mfgtest.vee program in the apps examples directory demonstrates a more complete program that uses status panels in conjunction with the Sequencer.


To Animate Pictures

You can use showPanel and hidePanel to perform animation. Follow these steps to create a simple animation program:

1. Create a Panel View in the Main Window by using Create Panel on the Main Window’s object menu.

2. In the Main Window Properties, change Execution Window Title to A Simple Animation, and be sure to enable ShowPanelonExecute.

From the Appearance Properties, select a background color for the Main Panel.

This color is important, because you'll use that same color for the background of the animation file(s).

3. Create a graphics file of the image you want to animate.

4. Open a UserFunction edit window using Device [image] UserFunction.

5. Select Display [image] Picture, placing the object in the UserFunction window. Specify your graphics file via the Properties window.

6. Add the Picture object to the UserFunction Panel, then from the Picture object menu, select Properties.

7. Turn off the Picture border and title bar, and place the Picture in the upper-left corner of the UserFunction Panel.

8. From the UserFunction object menu, select Properties.

9. Change Title to picture. Turn off the UserFunction Panel's title bar and border from the Pop-Up Panel category.

10. Change the Panel View background color to the Main Panel's background color.

11. Reduce the UserFunction Panel size.

12. Select Device [image] Function & Object Browser, then select the built-in function showPanel, placing it in the Main Detail View.

13. Type the UserFunction name between the quotes, replacing Ufname with picture.

14. Delete the input terminals except for the position parameters x and y.

15. Use the terminal names in the edit field so it looks like showPanel(picture,x,y).

16. Select Flow [image] Repeat [image] For Range.

17. In the For Range object, fill in the range of x and y coordinates, such as From: -20, Thru: 500, and Step: 10.

18. Add the Gate and Delay objects from the Flow menu. Set the Delay value to .05.

19. Connect the For Range output to the Gate input, and the Gate output to the showPanel X and Y inputs.

20. Connect the Gate sequence out to the Delay sequence in. Then connect the Delay output to the showPanel sequence in.

21. Press the Panel button to see the Panel View.

22. Run the program and see how the picture moves across your Panel View.

The following figure shows the program created using these steps, including the UserFunction Panel.

A Simple Animation

This program is saved as animate.vee in your Manual examples directory.

Race: A Simple Animation

The following figure shows a portion of the Panel View of a program that uses simple animation in VEE.

This program is saved as Race.vee in the Games examples directory. The Wheel.vee and Slots.vee programs in the Games directory demonstrate more complex animation.

Using Multiple Images

You can create animations with multiple images by adding a data input terminal to the Picture object, and programmatically inputting the file name to the Picture at run time. When the Picture display mode is Scaled, images take longer to display than if Centered or Actual are selected.


Building a Panel With Non-English Text

To build a panel with non-English text you need to have your environment set up to display non-English characters. There are a few things in VEE that are in English and cannot change on your panel:

Some objects have English text. For example, Data [image] Selection Control [image] Pop-Up List. When the list is popped up, the title of the pop up is Make Selection. The buttons are OK and Cancel.

The menu choices in the Panel View are in English, as are the associated dialog boxes, such as Open, Save, and Save As.

The object menu choices are in English.

After setting the environment to display non-English characters, you can type non-English text in VEE in any place you can type English text. For example, Labels, Constant objects, titles on objects, Confirm (OK) buttons, and Dialog Box objects (and the buttons on them).


Preventing Program Changes

When delivering a program for others to run, you generally don't want to let them modify it. You only want them to observe the program execution and operate any controls. There are two basic ways to prevent accidental modification:

File [image] Create RunTime Version - When you use this command, you save a secured version of the current program to the file filename.vxe, without any side-effect to the current program. Users can run the secured version directly in the VEE RunTime environment. You must create a Main Panel View so that they can see a panel as the program executes. This choice is useful to prevent any access to your source program.

Caution
There is no way to unsecure a secured (.vxe) program; be sure to save an unsecured version of your source program (.vee).

veerun filename - This command is primarily used to run secured VEE programs. However, you can use it to run unsecured programs. When VEE starts, it loads the program in filename, and runs the program in the VEE RunTime environment. As soon as the program is done, the run-time window closes. You must create a Main Panel View so that users can see a panel as the program executes. This is a useful choice if you do not want to maintain two files (a source file and a secured file).

Note

The version of VEE RunTime used to run a program must the same or newer than the version of VEE used to develop the program.


To Prevent Program Changes

The following list contains some tips to use when getting ready to deliver your program:

To prevent users from editing text in Note Pad object(s) added to the Panel View, turn off editing for the Note Pad. In the Panel View containing the Note Pad object, edit Note Pad Properties; in the Appearance category change EditEnabled to False.

To prevent users from changing maximum and minimum values on objects such as Slider, Meter, Thermometer, Fill Bar, and Tank, add control pins for MaxValue and MinValue.

To prevent users from moving UserObject or UserFunction Pop-Up Panels, use the Lock Panel Position property on the object menus for these panels. Also, you can use a UserFunction Panel instead and display it programmatically with the showPanel object. Refer to Building a Status Panel for details about showPanel.

To prevent users from changing the scale on VEE graphical Display objects, change the Layout. In the Panel View containing the object, select Properties from the object's object menu; in the Layout category, turn off Enable Trace/Scale Editing.

To prevent any of the VEE default colors and fonts on the destination system from being used, save the program with all your default colors and fonts.

1. Select File [image] Save As….

2. Select the Save colors and fonts with program check box.

3. Click Save. All the colors and fonts used in your program are now explicitly saved in your program.


To Secure a Program

Caution: There is no way to unsecure a secured (.vxe) program; be sure to retain your source program (.vee)

If you decide to create a secured version of your program before distributing it, follow these steps:

1. Select File [image] Create RunTime Version.

2. In the Create RunTime Version dialog box, enter the program name. You do not need to enter the file name extension, since .vxe is added automatically.

3. Select Save colors and fonts with program to save all the default colors and fonts in the program file that are selected in the Default Preferences dialog box. This ensures that whoever runs your program will also get all of your default colors and fonts. If this option is not selected, only the colors and fonts explicitly set in your program are saved in your program file. This allows others using your program to retain their own default colors and fonts. If an existing program is loaded, the option is set according to how the program was saved previously.

Save I/O configuration with program is enabled by default. You can un-check this selection if you do not want the embedded I/O configuration. VEE allows you to embed I/O configuration information in the program itself. See Instrument Manager for more information about saving an I/O configuration.

There is no side-effect to the source program. The secured program is saved to a different file name. For example, the unsecured program prog.vee is saved as the secured program prog.vxe.

You can run secured programs in VEE RunTime, which is a run-only version of VEE. You may distribute your program and VEE RunTime on an unlimited number of computers.

Note

If the user must observe or interact with the program as it executes you must create Panel View(s) in the form of a Main Panel View or Pop-Up Panels. If you want your program to run without user intervention, Panel Views are not necessary. However, some sort of status indication is helpful.


To Re-Secure a Program

When distributing a secured program to your users, each time you change the original program, you must save it secured again, and redistribute it. Refer to To Secure a Program.


To Secure a UserObject

When you're distributing a UserObject for others to use, you may want to secure the UserObject to prevent modifications to it. Only the icon view or the UserObject Panel View is available to them. Be sure to create a Panel View if users must interact with the UserObject.

1. Open the UserObject’s Edit Window. From its object menu, select Save Secured Version.

2. In the Save Secured Version dialog box, enter the UserObject’s file name. The .vee extension is added automatically.

If the program containing the UserObject has already been saved, or you've saved the UserObject via File [image] Save Objects, you may not want to save the UserObject again. If you still want to save a secured version, use a different file name.

3. When others want to use the secured UserObject, they select File [image] Merge, and then select the file name of the secured UserObject. They use the secured UserObject in the program just like any other object.


To Include All Needed Files

When distributing your program to other systems, you should embed your instrument configuration in the VEE program. Embedded I/O configuration is the best choice in most cases. If the I/O configuration is not embedded in the program, it can be edited on the target system; see To Configure VEE Pro RunTime.

Files you must include with your program (if you use them) are:

Data files.

*.cid files for instrument drivers you've written.

*.cid files for instrument drivers not installed on the destination system.

VXIplug&play instrument drivers.

IVI-COM drivers.

Graphics files you've created.

DLLs or compiled functions that you call.

Additionally, you must include the .NET Framework redistribution package (dotnetfx.exe) and it must be installed before the runtime is installed. If the .NET Framework is not installed, the VEE Pro runtime product does not install .

Once you have the required files together, you can copy them to other systems. If your program controls instruments, you must also install the Agilent I/O Libraries (version M.01.01.04 or higher); see the guide, Installing the Agilent I/O Libraries for more information.

Putting all files on distribution media

You can create distribution media containing VEE Pro RunTime, which you can include with your program.

1. Copy all of your program and supporting files onto a disk.

2. Copy the VEE Pro RunTime setup files from the VEE CD-ROM to a CD-R or Zip disk. The files are on the VEE CD-ROM, in the subdirectory runtime.

3. Copy the Agilent I/O Libraries (version M.01.01.04 or higher) to another CD-R (if your program controls instruments).

4. Prepare your product’s documentation.

You are responsible for explaining installation procedures to your end-user or customer about how to install all of the files from your distribution disks. For VEE Pro RunTime, the runtime subdirectory contains the setup.exe program that installs the product and the dotnetfx.exe file that installs the .NET Framework.

For more information about VEE Pro RunTime, see About the Agilent VEE Pro RunTime Product.


To Create an Application Icon in Windows

To Create an Application Icon

It is convenient for your users to double-click on a program icon to run your VEE program. To set up the icon, follow the steps below on the destination system. For details about these procedures, refer to the MS Windows documentation and online help.

You can place a shortcut to the program on the desktop or in the taskbar’s Start menu. The steps are similar for a secured or unsecured program. However, be sure to use the veerun command in the shortcuts to run an unsecured program. This prevents access to the source.

A desktop shortcut

1. In Windows Explorer, click on your program’s file name with the right mouse button, then select Create Shortcut. The file name Shortcut to filename appears in the list.

2. Drag the shortcut file name to the desktop. A shortcut icon appears.

3. Change the shortcut command for an unsecured program (.vee) to include veerun in the Target command. A secured program (.vxe) automatically uses veerun; you only need to change the command if you want to use any veerun options.

a. Click on the shortcut icon with the right mouse button, then select Properties. The Shortcut Properties dialog appears.

b. On the Shortcut tab, change Target to look something like this:

"C:\Program Files\Agilent\VEE Pro RunTime 7.0\veerun.exe" MyApp.vee

Be sure to include the quotation marks, and any veerun options you need. For a list of command-line options, see To Start Agilent VEE with Command-Line Options.

If the path for Start in is correct, you do not need to specify the program’s path in Target.

c. Click OK.

4. To change the shortcut icon’s label, click on the icon, then click on the label. Type in a new label. Double-click the shortcut to run the program.

A Start menu shortcut

1. On the Windows task bar, click Start [image] Settings [image] Taskbar.

2. In the Taskbar Properties dialog box, on the Start Menu Programs tab, click Add. The Create Shortcut dialog appears.

3. Enter the command to run your program. Use quotation marks if you type in the command.

For an unsecured program (.vee), include veerun and your program’s file name with their respective paths. A secured program (.vxe) automatically uses veerun, so the command only needs to include the program file name and path. The command for an unsecured program should look something like

"C:\Program Files\Agilent\VEE Pro RunTime 7.0\veerun.exe" "C:\My Documents\VEE Programs\MyApp.vee"

Include any veerun options that you need. For a secured program, you need to include veerun in the command to use options. For a list of command-line options, see To Start Agilent VEE with Command-Line Options.

Click Next. The Select Program Folder dialog appears.

4. Select the folder to place the shortcut in. You can select an existing folder or create a new one. Click Next. The Select a Title for the Program dialog appears.

5. Enter a useful name for the program’s shortcut. This name will appear on the Start menu. Click Finish.

6. Click OK. Select Start [image] Programs to use the shortcut.

See Also

To Start Agilent VEE with Command Line Options


Execution Mode

Understanding Execution Mode

What is an Execution Mode?

Each VEE version has several Execution Modes. (They were called "Compatibility Modes" in previous versions). These modes allow a newer version of VEE to run programs created with an older VEE version exactly the same way the older VEE ran them. This is known as “backwards compatibility,” and all versions of VEE are 100% backwards compatible by using these Execution Modes.

For example, VEE version 4.0 had two Execution (Compatibility) Modes: VEE 3.x and VEE 4. This allowed VEE 4.0 to run old programs created with VEE version 3.0 (or prior) in the exact same way the programs ran in VEE version 3. If you want to run a VEE 3 program in Compiled mode, you switch modes, then VEE 4 runs your program under the Compiler.

In the same manner, VEE version 5.0 had three Execution (Compatibility) Modes: VEE 3.x, VEE 4, and VEE 5. In VEE version 6.0, VEE 6 Execution Mode is added to the list. A VEE program knows what version of VEE created it and what Execution Mode was used. When VEE loads that program, VEE puts itself into that corresponding Execution Mode, so the program will run exactly as it did in the older version of VEE.

Once a program is written and saved with an Execution Mode, the program retains that Execution Mode, unless changed by the user. For example, suppose you developed and saved a program in version 5.0. This program is saved with Execution Mode VEE 5. If you then load the program in version 6.0 and save it, the program still has Execution Mode VEE 5. Unless you change the Execution Mode (using the Default Preferences Dialog Box or other means), the Execution Mode does not change for the program, no matter which version of VEE loads the program.

VEE 6 Execution mode will work in VEE 7. Also, in previous VEE versions, it was sometimes possible to run a program created in a newer version of VEE in an older version. This depended upon which features the program contained. However, programs written in VEE 7 cannot be run in previous versions.

Why Should I Change Execution Modes?

You should change Execution Modes if you add new features to an existing program. For example, suppose you have a program written in version 5.0 (with associated Execution Mode VEE 5). To add new features (such as new data types) available in version 6.0, you should change the Execution Mode to VEE 6. If you change the program but do not change the Execution Mode, the new features added to the program may not run properly.

When Should I Change Execution Modes?

In most cases, programs written in previous versions of VEE will run 100% in newer versions of VEE as long as the Execution Mode is not changed. However, you may not be able to add new features unless the latest Execution Mode is used.

The following table shows the combinations of programs that will run for various versions and Execution Modes. Note that old programs will run in any version as long as the Execution Mode is not changed. The only potential problem occurs when the Execution Mode is switched.

Program Created in Execution Mode:

Running in VEE | VEE 4 | VEE 5 | VEE 6&7
Version VEE 4 | runs | CNA | CNA
Version VEE 5 | runs | runs | CNA
Version VEE 6 | runs | runs | runs
Version VEE 7 | runs | runs | runs

CNA means Compatibility Not Assured. Programs created on later versions of VEE might load and run on earlier versions of VEE, if they do not include any features unique to the later version. Programs which take advantage of newly added features will not run correctly on older versions of VEE, and in some cases, the programs may not even load into older versions of VEE. The point of Execution Modes is to assure that existing programs will run on newer versions of VEE. There is no assurance that new features will run on old versions of VEE.

Guidelines to Switching Execution Modes

When developing new programs, you should use the latest execution mode.

You can run any existing VEE program by selecting the applicable Execution Mode (VEE 3 for VEE 3.x programs, VEE 4 for VEE 4.x programs, or VEE 5 for VEE 5.x programs). The appropriate mode for older programs is automatically set when the program is loaded.

If you load a program which is set to VEE 5 or lower execution mode, and switch to VEE 6 Execution Mode, the old program may or may not run correctly. Most programs will run correctly. See the following example for a "bug fix" that may cause a program to run differently.

For example, suppose you have a version 5.0 program (Execution Mode VEE 5) which includes a To File that does a WRITE BINARY BYTE transaction. In version 5.0 (and prior versions), you could send "300" into this and get "44" written to the file. (This is technically a bug because "300" does not fit into a byte.)

In VEE 5 Execution Mode, you still get "44" to preserve program compatibility. However, in VEE 6 Execution Mode you get an error message saying VEE cannot convert 300 to a UInt8 (out of range).

Location

File [image] Default Preferences [image] Execution Mode

See Also

“Using VEE Execution Modes” in Chapter 1 of the VEE Advanced Techniques manual


Understanding Propagation

Propagation is the general flow of execution through your VEE program. The propagation guidelines define the order in which VEE objects operate. In general, propagation is determined by data flow, that is the flow of data from object to object within a VEE program.

Propagation Summary

The following is a summary of the propagation rules that VEE follows when a program executes in VEE 4 or higher execution mode:

Data flows through objects from left-to-right -- sequence flows from top-to-bottom.

All data and XEQ input pins must be connected.

Objects with no data input pins or sequence input pin connections operate first.

All data input pins must be activated before an object operates (except for the JCT object).

If the sequence input pin is connected, it must be activated before an object can operate.

Objects operate only once unless connected to a repeat object (for example, For Count), or unless forced to operate by an XEQ pin.

Control pins execute immediately and do not cause the object to operate or propagate.

When an error is generated from an object with an Error pin, the Error pin propagates instead of the data output pins. However, the sequence output pin is activated. (If there is no Error pin, an error message is displayed.)

Parallel subthreads may operate in any order.

Multiple threads may operate in any order.

Basic Propagation Order

Based on the propagation rules, the objects in a VEE program executing in VEE 4 or higher mode operate in the following basic order when you press Run:

1. Objects that have no data input pins, and which have no sequence input pins connected, operate first.

2. Other objects operate in the order determined by data flow. In other words, objects with data input pins operate only when data is present on all data inputs, except as noted in How Objects Operate.

3. The order of propagation can be modified by connecting sequence pins, which are described in Pins and Propagation.


Pins and Propagation

This topic summarizes all of the types of pins, and their effect on propagation.

Data pins input or output a data container.

An object will not operate until all of its data input pins are activated. (Except the JCT object, which operates when any data input pin is activated.)

After an object operates, its data output pins propagate (if no error conditions have occurred).

Control pins (optional) are inputs that affect the state of the object but have no effect on propagation.

Common control pins include Clear, Reset, and Default Value. Control pins are connected with dashed lines to indicate that propagation is not affected.

Sequence pins are used only to specify the order of execution.

An object operates only after all data input pins and sequence input pins (if connected) are activated.

A sequence output pin propagates after all the data output pins have activated and data flow has propagated as far as possible.

It is best not to use sequence pins to obtain correct propagation -- let data flow determine the order of execution instead.

A sequence input pin is activated by the presence of a data container, but the data in the container is ignored. A sequence output pin propagates an empty (nil) container when it activates.

Error pin (optional). You can add an Error pin to trap an error condition the object generates. The Error pin propagates the appropriate error number if an error condition occurs.

If an error occurs, the Error pin propagates instead of any data output pins. Only the error pin and the sequence output pin (if connected) propagate.

XEQ pin is a pin that forces an object to operate immediately (even if a data input pin has not yet been activated). Only the Collector, and Sample & Hold objects use an XEQ pin to force the object to execute immediately, and propagate its data.

The XEQ pin is activated by the presence of a data container, but the data in the container is ignored.

Note

Do not leave any data input pins or the XEQ pin unconnected, or an error will occur when you run your program.

You may leave data output pins, control pins, and Error pins unconnected. Sequence pins, more often than not, should be left unconnected.


Understanding Sequence Pins

This topic summarizes the role of sequence pins in propagation, focusing on their recommended use.

Sequence Pins are the top and bottom pins on VEE objects. The top input pin, if connected, must be pinged before the object will execute. It may be convenient to think of this pin as a trigger or hold-off pin.

The bottom output pin will propagate after the object’s data (or Error) outputs propagate, and propagation has continued to downstream objects as far as it can.

Connecting these sequence pins is generally not needed in most programs, and some user programs greatly overuse sequence pins. Overusing sequence pins can confuse the compiler, and more importantly can confuse other programmers (or you a year from now!) trying to understand, modify, and maintain your program. However, there are a few cases where these connections are required.

Loops

The top sequence input of a Loop (For Count, For Range, etc) is often connected to ensure the loop doesn’t begin until after something else finishes. Similarly, the bottom sequence output of a Loop is often connected to objects in your program that should execute after the loop finishes. That general flow is easy to see in the following diagram:

To/From File or DataSet

If your VEE program writes to a file, and later reads from that file, you may need sequence pins to ensure the program doesn't read from the file until the program has finished writing to it. Here are two examples:

Setting and Getting Variables

You typically need the sequence input of a Get Variable (or a Formula that uses a variable) connected to ensure the Set happens before the Get. For example:

Control Input Pins that Carry Data

Unfortunately, many control input pins to VEE objects actually carry data. For example, the "FileName" input on a ToFile, or the "Formula" expression input on a Formula. In these cases, a sequence line is required to ensure the VEE object with the control input doesn't execute until the data coming in the control input has been received.

Using Confirm/OK Buttons on Popup Panels

Often Confirm buttons are used as "Ok" and "Cancel" buttons on popup panels to prevent execution of objects until the operator has completed data entry. The sequence ordering is sometimes confusing for new users, as the natural instinct is to place the Ok after the Knob (because the operator interacts in that order). Experience with VEE makes it easier to view the Ok button as a "hold-off," something that releases the data beneath it. The following example shows the normal configuration of VEE Confirm buttons.

Try this program with the Ok connected after the Knob (with Show Data Flow and Show Execution Flow on) to understand why the Ok must execute first. Connect a display to the output of the UserObject to see whether the new or old value is propagated in each configuration.

Multiple Data Output Lines Mixed with Control Flow

There are a few cases when programs use multiple lines out the same pin, mixing data flow with control flow. This can cause programming errors that are difficult to detect. In the following example, assume the operator chose a value on the Knob and pressed Ok.

Will the Formula and propagation of the UserObject happen first, or will the Exit UserObject happen before the Formula? Will the UserObject output pin get a value before the Exit UserObject executes? This is not deterministic; it’s random. Here you need sequence pins.

See the previous example for a better way to connect the Exit UserObject sequence pin.

Common Cases of Over-Using Sequence Pins

Programmers with a background in procedural languages sometimes want to connect sequence pins when they are not needed. Here are some common examples where beginning VEE programmers connect sequence pins, but data flow has already determined program flow.

The unnecessary sequence connection may be easy to see in these simplified diagrams. But some programmers are tempted to add sequence connections in larger programs, even though the flow patterns are essentially the same as these.

A previous control-pin example can be confusing to some. There is no need for sequence lines when acceptable program flow is dictated by data pins. However, control pins do not dictate program flow like data pins do. The following two diagrams are similar, but not equal.

The control-flow model (dashed blue line) needs the help of sequence pins, the data-flow model (solid blue line) does not.


How Objects Operate

A VEE object operates by accepting the data on its input pins, processing that data, and then returning the resulting data on its output pins. A VEE object will not operate until all of its data input pins are activated with data on them. (There is one exception: The JCT object will operate when one of its data input pins is activated with data.)

Let's look at a simple example. In the program below, the a+b object will not operate until there is data on both of its data input pins. Thus, both of the Real64 constant objects must operate first (in no particular order).

When the a+b object operates, it adds the data and activates its output pin with the resulting data. The AlphaNumeric object does not operate until its data input pin has data, so it operates last, displaying the result.

As you can see, data flow has determined the order of operation of the objects in the above program. That is, data flow determines the propagation order.

In addition to the data pins, the sequence pins can be used as a hold-off to control when an object operates. This is useful when you want to prevent data input pins from accepting any data until valid data is available. In the following program, a Confirm OK object has been added to the previous example:

The sequence output pin of the Confirm OK object is connected to the sequence input pin of the a+b object. Sequence input pins need not be connected. That is, if a sequence input pin is not connected, it is ignored by the object. However, if a sequence input pin is connected, the object will not operate until it has been activated. So, in the above example the a+b object won't operate until you press (click on) the OK button. Then the data input pins accept the data.

The XEQ pin has the opposite effect on object operation. An object propagates immediately when the XEQ pin is activated using any data present on its data input pins. This is important to consider when using both the XEQ pin and sequence input pin on an object. The XEQ pin must be connected, and the object will not propagate until the XEQ pin is activated. Here is an example:

The For Count object repeats five times, outputting data to the Data input terminal on the Collector. The Collector collects the five values into an array, which it propagates when the XEQ terminal is activated by the sequence output pin of the For Count object.

Note

Remember that you can use Properties from the object menu to turn on Show Terminals. With Show Terminals turned on, the data input and output pins become "terminals", showing their names.


Propagation of Threads and Subthreads

A very simple VEE program usually contains only one thread. Programs that are more complicated contain additional threads and subthreads which affect the program’s propagation.

Threads – Objects connected through data and sequence lines, which are solid, form a thread. Objects connected only through control lines, which are dashed, are not considered to be in a thread. A program can contain several threads. For example, the following program contains two parallel threads. The threads are independent because they are not connected by data or sequence lines.

Subthreads -- A branch of a thread is called a subthread. When two subthreads begin at the same data output pin of the same object, and there are no sequence or data lines between them, they are parallel subthreads. The following program shows two parallel subthreads branching from the data output pin of the Real64 constant object:

Parallel threads and subthreads operate in random order with relation to each other. One or more objects (or all objects) in a thread will operate, then one or more in another thread operate. However, there are two exceptions to this:

If a thread contains an Interface Event or Device Event object, it takes over execution when an event is trapped. For example, if Interface Event detects an GPIB SRQ message, the thread will continue to completion before any other thread can continue. Other threads are held off to allow the event to be serviced. For further information, refer to Interface Event and Device Event.

If a thread has a Start object, and if you start the thread by pressing the Start button, that thread will run to completion before you can start any other threads.


Some UserObject Concepts

A UserObject provides the means for you to encapsulate a group of objects that perform a particular task into a single, custom object. This encapsulation allows you to:

Use modular design techniques in building your VEE program. This allows you to solve a complex problem through an organized approach. UserObjects allow you to use top-down design techniques to create a more flexible and maintainable program.

Build user-defined objects that you can save in a library for later re-use.

Once a UserObject is created and saved, you can Merge it in other programs.

UserObject Features

When you add a UserObject to the Main Window, it appears in an icon view, and remains that way in your program. When you double-click the icon, the UserObject’s edit window pops up presenting the work area where you can build a specific program segment by adding objects and connecting them. The terminal areas accommodate data and control terminals so the UserObject can communicate with the rest of your program. The following figure shows the UserObject named UserObject1 in its icon view and edit window.

Contexts and UserObjects

The Main Window and UserObjects represent separate contexts within a VEE program, just as subprograms represent separate contexts within a C or BASIC program. As shown in the previous figure, you can nest UserObjects in a VEE program, which results in additional contexts. In the previous figure, there are three contexts. More objects can be added to each context.

1. The Main Window is one context which contains UserObject1.

2. UserObject1 is a context and contains UserObject2.

3. UserObject2 is a context which can contain other objects.

Propagation and UserObjects

Propagation in a program containing UserObjects is affected by the fact that a UserObject is a separate context. The UserObject propagation rules are as follows:

All data input terminals (and the sequence input terminal if connected) of the UserObject must be activated before any objects within the UserObject operate.

Once the data input terminals (and the sequence input terminal if connected) of the UserObject have been activated, the UserObject operates. The objects within the UserObject operate following the rules of propagation.

Programs written before VEE version 4.0 may contain an optional XEQ terminal. If it is activated, the UserObject immediately begins operation of the objects within its work area, using whatever "old" data may be on the unactivated input terminals of the UserObject. In most cases, you need not use the XEQ terminal for a UserObject. It is not available in VEE 4.0 and later versions, and existing programs with XEQ pins on UserObjects will not compile if run in the VEE 4 or higher execution mode.

The UserObject data output terminals do not propagate until all objects within the UserObject finish operating (unless the UserObject is exited prematurely by an error or an Exit UserObject). Only those output terminals activated from inside the UserObject pass data to objects outside the UserObject. When activated, each data output terminal propagates only one data container.

In programs written before VEE version 4.0 (running in the VEE 3 execution mode), the objects within the UserObject time-share in operation with external objects on different subthreads. This is time-slicing. The UserObject does not block the operation of objects outside the UserObject. In programs running in the VEE 4 or higher execution mode, the UserObject will time-slice only when invoked from separate threads.

For more information about the propagation rules, refer to Understanding Propagation.

Note

If there is a Start object in a UserObject, pressing Start runs only the objects connected to the same thread as the Start object. No data will be read from the input terminals of the UserObject, nor will its output terminals propagate. Therefore, no propagation outside the UserObject takes place.

Data Output from a UserObject

As stated in the propagation rules, each data output terminal of a UserObject propagates only one data container (the last received by the terminal) to the context outside the UserObject when the objects within the UserObject finish propagating. This can lead to unexpected results in your program if you neglect to account for it. The following example illustrates this situation:

Although the For Count object sends 10 data containers (the numbers 0 through 9) to the Count output terminal, only one data container (the last number) propagates from the UserObject. However, you can use a Collector object to collect the data from the For Count object into an array. The Array output terminal also propagates only one data container, but that container is a one-dimensional array of 10 values (0 through 9).


Understanding Data Containers

The propagation of data through a VEE program consists of the movement of data containers from one object to another. The data container is the VEE internal data format. Every data container has both a data type (text, real, and so forth), and a data shape (scalar, one-dimensional array, and so forth).

A data container may have only a single value in it, or it may have an array of several values. In either case, only one data container propagates from a particular data output pin when an object operates.

In the following example program, the Real64 constant object is configured as a one-dimensional array. The Int32 constant object is configured as a scalar.

As you might expect, when the program runs the Real64 constant object propagates a data container that is a one-dimensional real array. The Int32 constant object outputs a data container that is an integer scalar (the value 1). So how does VEE add these two containers? There is no problem -- VEE provides automatic data type conversion. VEE "promotes" the integer value 1 to become an equivalent real value (1.0). The a+b object then adds the real value 1.0 to every element in the one-dimensional real array, and outputs the resulting one-dimensional real array, as shown above.

If you are interested in the specific container that has been passed on any VEE data line, you can use Line Probe to look at that information. Move the mouse pointer over the desired line so the line is highlighted, and then click the left mouse button. The Container Information box appears. For example, the container passed on the data output line from the Real64 constant object of our example appears as follows.

In general, VEE converts data types automatically, and resolves data shapes if possible. You normally don't need to worry about how this is done. However, for technical information about the conversion process, refer to Converting Data Types on Input Terminals and Instrument I/O Data Type Conversions.

Terminal Information

Terminals show the object input type and shape requirements and display information about the input or output container. Pins are the connection points for terminals. You can display terminals if they are present but not visible; on the object menu, click Properties and check Show Terminals on the General tab.

To view or modify the attributes of a terminal, double-click on the terminal's information area (not the pin). You'll see a dialog box showing terminal information.

If all the fields in the dialog box are grayed out, the terminal cannot be modified. However if some of them are entry fields (white backgrounds) or buttons, you can change the values.

Terminals have the following characteristics:

Name is the name of terminal. You can usually modify this field. In formula expressions, the terminal name can be used in the equation.

Mode displays the terminal type, such as Data, Control, Trigger, or Error. You cannot modify this field.

Required Type and Required Shape (input terminals only) specify information about the input data that the object expects. On some objects, you can modify the Required Type or Shape, but you normally will not need to do this.

Container Information contains information about the container that the object will process (according to the input requirements on an input terminal) or has processed (on an output terminal). This information includes the data type, data shape, the size (if data is an array), any mappings, and the data itself.


Data Types

VEE provides several data types that are used for all VEE operations. That is, every VEE data container sent between VEE objects is one of these types.

Note

If an input terminal on a VEE object specifies Any (the default in many cases), it will accept containers of any VEE data type.

Composite data types (Waveform, Spectrum, Record, Coord, and Object) are associated with particular data shapes.

UInt8 is an 8-bit two's complement unsigned integer (0 to 255).

Int16 is a 16-bit two's complement integer (-32768 to 32767).

Int32 is a 32-bit two's complement integer (-2147483648 to 2147483647).

Real32 is a 32-bit real that conforms to the IEEE 754 standard (±3.40282347E±38).

Real64 is a 64-bit real that conforms to the IEEE 754 standard (approximately 16 significant decimal digits or ±1.7976931348623157E308).

PComplex is a magnitude and a phase component in the form (mag, @phase). Phase is in the currently active trigonometric units. For example, the PComplex number 4 at 30 degrees is represented as (4, @30) when Trig Mode is set to Degrees. Each component is Real64.

Complex is a rectangular or Cartesian complex number. Each complex number has a real and an imaginary component in the form (real,imag). Each component is Real64. For example, the complex number 1 +2i is represented as (1,2).

Waveform is a composite data type of time domain values that contains the Real64 values of evenly-spaced, linearly-mapped points and the total time span of the waveform. The data shape of a Waveform must be an Array 1D (a one-dimensional array).

Spectrum is a composite data type of frequency domain values that contains the PComplex values of points and the minimum and maximum frequency values. Spectrum allows the domain data to be uniformly mapped as log or linear. The data shape of a Spectrum must be an Array 1D.

Coord is a composite data type that contains at least two components in the form (x, y, ...). Each component is Real64. The data shape of a Coord must be a Scalar or an Array 1D.

Enum is a text string that has an associated integer value. The Enum data type is propagated by the objects found under Data [image] Selection Control (for example, the Radio Buttons object). You can access the integer value with these objects’ ordinal output pin, or by using the ordinal(x) function. The data shape of an Enum must be Scalar. Enum cannot be a required data input type.

Text is a string of alphanumeric characters.

Record is a data type composed of fields. Each field has a name and a container, which can be of any type (including Record), and a data shape of Scalar or 1D Array.

Object is a data type reserved for variables used for ActiveX Automation Objects and Controls when using VEE's execution mode. Objects can be passed as inputs to and outputs from UserObjects and UserFunctions, but not to remote UserFunctions nor compiled functions. An Object variable contains values for the name of the Dispatch interface, such as "Range" or "Application", and the pointer value of Dispatch, which are exported from an Automation Object. Object data shape must be Scalar.

Variant is not a distinct data type. It is used in expressions to indicate that the value it represents can be one of a number of other data types. It is the data type it holds at the moment.

For more information on data types and data type conversions, refer to Converting Data Types on Input Terminals and Instrument I/O Data Type Conversions.

For more information on Agilent VEE’s support of ActiveX Automation and Controls, see the VEE Advanced Techniques manual.

Special Instrument I/O Data Types (VEE 5 and lower execution modes):

All integer values are stored and manipulated internally by VEE as the Int32 data type, and all real numbers are stored and manipulated as the Real (or Real64) data type. However, instruments generally support 16-bit integers or 8-bit bytes. Also, some instruments support a 32-bit real format. Therefore, VEE supports the following three data types, which are used only for I/O transactions involving instruments:

Byte is an 8-bit two's complement byte (-128 to 127). (Byte is used in READ BINARY, WRITE BINARY, and WRITE BYTE instrument I/O transactions. The WRITE BYTE transaction is used for specialized character output to GPIB instruments.)

Int16 is a 16-bit two's complement integer (-32768 to 32767).

Real32 is a 32-bit real that conforms to the IEEE 754 standard (±3.40282347E±38).


Data Shapes

Composite data types (Waveform, Spectrum, Record, Coord, and Object) are associated with particular data shapes:

The Waveform and Spectrum data types are always one-dimensional arrays.

The Record and Coord data types can be either scalars or one-dimensional arrays. (They cannot be arrays of two or more dimensions.)

The Object data type is always a scalar.

All other data types may have either a Scalar or an Array data shape:

Scalar is a single number such as 10 or (32, @10).

Array is an array with one to ten dimensions.

Arrays may be mapped. (A mapping is a set of continuous or discrete values that express the independent variables for an array.)

In many cases, a VEE object has data pins with an input data shape requirement of Any, meaning that the object accepts containers of more than one of the data shapes.


Converting Data Types on Input Terminals

In conventional programming languages, you manually convert between data types. VEE automatically converts between most data types.

Note

Data shapes are not converted on input terminals, but data types and shapes may be automatically converted when used in math functions. Refer to Processing Data for further information.

Most objects accept any data type on their data input terminals, but a few objects require a particular data type or shape. For these objects, the data input terminal automatically attempts to convert the input container to the desired data type.

For example, a Magnitude Spectrum display needs Spectrum data. If the output of a Function Generator (a Waveform) is connected to the Magnitude Spectrum display, the input terminal of the Magnitude Spectrum automatically does an FFT to convert time-domain data to frequency-domain data (Waveform to a Spectrum).

The type conversion can be a promotion or demotion. A promotion is the conversion from a data type with less information to one with more. For example, a conversion from an Int32 to Real64 is a promotion. Such promotions take place automatically as needed -- you rarely need to be concerned with them.

A demotion is a conversion that loses data. For example, the conversion from a Real32 to an Int32 is a demotion because the fractional part of the Real32 number is lost. A demotion of data type occurs only if you force it by specifying a certain data type for an input on an object. Once you have specified a data type, the demotion will occur automatically if it is needed and is possible.

For example, if you change the input on a Formula object to Int32, and another object supplies a Real64 number to that input (such as 28.2), the value will be demoted to an Int32 (28).

To change the data type on the Formula input from Any to Int32, just double-click on the input terminal's information area (not the pin), and then click on the Required Type field. Click on Int32 in the drop-down list to change types.

Note

The conversion of data types for instrument I/O transactions in VEE 5 and prior execution modes is a special case. Refer to Instrument I/O Data Type Conversions for further information.

The Record data type has the highest priority. However, VEE does not automatically promote to or demote from the Record data type. To convert between Record and non-Record data, use Build Record and Unbuild Record. For further information, refer to "Using Records and DataSets" in the VEE Advanced Techniques manual.

The Object data type also has no automatic promotion or demotion, and it cannot be converted to other data types. ActiveX automation objects use the Object data type. You can create and use automation objects by using the functions CreateObject and GetObject.

When the conversion cannot be done, VEE returns an error. The following table shows when conversion is automatic "yes" or when VEE returns an error "no".

Table: Promotion and (Demotion) of Types in Input Terminals

_________________________________________________________________________________________________

To: | UInt8 Int16 Int32 | Real32 Real64 | Complex | PComplex | Waveform | Spectrum | Coord | Enum | Text
From: |  |  |  |  |  |  |  |  |

_________________________________________________________________________________________________

UInt8 Int16 Int32 | (yes)[3] | yes | yes[1] | yes[1] | no | no | yes[2] | no | yes
Real32 Real64 | (yes)[3] | (yes)[3] | yes[1] | yes[1] | no | no | yes[2] | no | yes
Complex | no | no[4] | n/a | yes | no | no | no | no | yes
PComplex | no | no[4] | yes | n/a | no | no | no | no | yes
Waveform | (yes)[3] | (yes)[8] | no | no | n/a | yes[5] | yes | no | yes
Spectrum | no | no | (yes)[8] | (yes)[8] | yes[5] | n/a | no | no | yes
Coord | no | no | no | no | no | no | n/a | no | yes
Enum | no[6] | no | no | no | no | no | no | n/a | yes
Text | (yes)[7] | (yes)[7] | (yes)[7] | (yes)[7] | no | no | (yes)[7] | no | n/a

_________________________________________________________________________________________________

Table Notes:

yes = A promotion

(yes) = A demotion

n/a = Not applicable

[1] An integer or real value promotes to Complex (value, 0) or to PComplex (value, @0).

[2] The independent component(s), which are the first n-1 field(s) of an n-field Coord, are the array indexes of the value unless the array is mapped. If the array is mapped, the independent component(s) are derived from the mappings of each dimension. The dependent component, y, is the array element. If the container is a Scalar (non-array), conversion fails with an error.

[3] These demotions will cause an error if the value is out of range for the destination type.

[4] This demotion is not done automatically, but can be done with the re(x), im(x), mag(x), and phase(x) objects or the Data [image] Build Data/UnBuild Data [image] objects.

[5] An FFT or inverse FFT is automatically done.

[6] This demotion is not done automatically, but can be done with the ordinal(x) object.

[7] This demotion causes an error if the text value is not a number (such as 34 or 42.6) or is not in an acceptable numerical format. The acceptable formats are as follows (spaces, except within each number, are ignored):

Text that is demoted to an integer or real type may also include:

A preceding sign. For example, -34.

A suffix of e or E followed by an optional sign or space and an integer. For example, 42.6E-3.

Text demoted to Complex must be in the following format: (number, number).

Text demoted to PComplex must be in the following format: (number, @number). The phase (the second component) is considered to be radians for this conversion, regardless of the Trig Mode setting.

Text demoted to a Coord type must be in the following format: (number, number, ...).

[8] These demotions keep the Waveform and Spectrum mappings.


Instrument I/O Data Type Conversions

On instrument I/O transactions, VEE performs automatic data-type conversions according to the following rules. In VEE 6 Execution Mode, the new data types are used, and no conversion is done. However, in VEE 5 and prior modes, the following conversions are still performed just as the VEE 5.0 version did, for backwards compatibility. For example, READ BINARY Int16 will return an Int16 in VEE 6 mode, but an Int32 in VEE 5 and prior execution modes.

Note

These data-type conversions are completely automatic, so you won't normally need to be concerned with them. However, the following list shows what happens in VEE 5 and prior execution modes.

On a READ transaction, Int16 or Byte (UInt8) values from an instrument are converted to Int32 values, preserving the sign extension. Also, Real32 values from an instrument are converted to 64-bit Real numbers.

On a WRITE transaction, integer or real values are converted to the appropriate output format for the instrument

If an instrument supports the Real32 format, VEE converts 64-bit Real values to Real32 values, which are output to the instrument. If the Real64 value is outside of the range for Real32 values, an error will occur.

If an instrument supports the Int16 format, VEE truncates Int32 values to Int16 values, which are output to the instrument. Real values are first converted to Int32 values, which are then truncated and output. However, if a real value is outside the range for an Int32, an error will occur.

If an instrument supports the Byte format, VEE truncates Int32 values to Byte (UInt8) values, which are output to the instrument. Real values are first converted to Int32 values, which are then truncated and output. However, if a real value is outside the range for an Int32, an error will occur.


What is .NET?

Visual Studio .NET is Microsoft’s latest development platform. Unlike previous products, such as Visual Studio 6, .NET addresses the needs of both desktop programmers and Web developers. The strength of .NET from a VEE perspective is the .NET Framework's free runtiime. The .NET Framework is distributed with VEE 7.0 and is integral to several of the new features.

The key feature and benefit of the .NET Framework for VEE is the Framework class LIbrary (FCL). The FCL is of particular value to VEE programmers. There are 100's of new properties and methods that are now available through the Function & Object Browser. This new feature enables your code to derive functionality such as File and Directory management; simpler String management; simplified views of the Operating System environment; the manipulation of Web pages; access to Operating System processes; reading the registry; and many, many more.


.NET Terminology

As you review the topics describing .NET, you may find this list of Microsoft defined terms useful.

Assembly – Components are packaged in assemblies. Assemblies are the reusable, versionable, self-describing building blocks of .NET applications. The simplest assembly is a single executable that contains all the information necessary for deployment and versioning. An Assembly is the fundamental building block of the .NET Framework. It takes the form of an executable (.exe) or dynamic link library (.dll) file.

Primary Interop Assembly (PIA) – A primary interop assembly is a unique, vendor-supplied assembly that contains type definitions (as metadata) of types implemented with COM. There can be only one primary interop assembly, which must be signed with a strong name by the publisher of the COM type library.

Namespace – .NET Framework types use a dot syntax naming scheme that connotes a hierarchy. This technique groups related types into namespaces so they can be searched and referenced more easily. The first part of the full name — up to the rightmost dot — is the namespace name. The last part of the name is the type name. For example, System.Collections.ArrayList represents the ArrayList type, which belongs to the System.Collections namespace. The types in System.Collections can be used to manipulate collections of objects. (Nested namespaces are an exception to this rule. Please see MSDN documentation for more information.)

Reference – To use an Assembly, you must add a reference to it.

Shared Member – Shared members are properties, procedures, and fields that are shared by all instances of a class. Some programming languages refer to such items as static members.

Shared fields and properties are useful when you have information that is part of a class, but is not specific to any one instance of a class. Normal fields and properties exist independently for each instance of a class. Changing the value of a field or property associated with any one instance does not affect the value of fields or properties of other instances of the class. On the other hand, when you change the value of a shared field and property associated with an instance of a class, you change the value associated with all instances of the class. In this way, shared fields and properties behave like global variables that can be accessed only from instances of a class.

Class – If you are familiar with object-oriented programming, you know that a class defines the operations an object can perform (methods, events, or properties) and defines a value that holds the state of the object (fields). Although a class generally includes both definition and implementation, it can have one or more members that have no implementation.

An instance of a class is an object. You access an object's functionality by calling its methods and accessing its properties, events, and fields.

Instance Member – An instance member is tied to a specific instance of a class. Changes to its value affect the object it is associated with and no other objects.


VEE and the .NET Framework

Before beginning a review of how the .NET Framework interacts with VEE, review the .NET Framework by looking up the “.NET Framework – getting started” in the MSDN index.

Use

Under the Device menu there is a new menu option called .NET Assembly References. As you will remember from the definitions, a reference allows you to use an Assembly. Open this menu selection. You will see a window similar to the following graphic:

There are a great number of assemblies you can select. These assemblies are located in the VEE home directory or in the directory where the .NET Framework is installed. If you are using an assembly that is not in one of these directories, use the Browse button to the select it. There is also a checkbox for Importing Namespaces. Importing a namespace is equivalent to the using statement in C# or the Imports statement in Visual Basic.

The most commonly used assembly, mscorlib, is selected in the previous graphic. Go ahead and select this assembly. mscorlib encapsulates many functions useful to VEE users, such as file system manipulation, collection management, and data type conversion. Another very commonly used assembly is System, which contains functions such as process management, web request and response, and regular expressions.

Notice there is another tab labeled COM. Under this tab is a list of all the COM type libraries currently registered with your computer. In fact, this is the almost the same list of type libraries you see when you use the ActiveX automation references dialog box.

How do you know which of these two choices to use? You should use ActiveX if:

  • the library appears there

  • is fully functional

  • and has no Primary Interop Assembly (PIA).

This avoids adding another layer, the .NET Interop. You should use the .NET/COM interop if:

  • the library doesn't appear under ActiveX

  • or not all the functionality gets imported

  • or you know the COM library has a PIA

For example: not all IVI-COM drivers interfaces are visible from the Function & Object Browser's ActiveX Objects list. However, the .NET interop does allow you to see all of the IVI driver interfaces.

When using the .NET Assembly References menu option and selecting a COM type library from the list, VEE tries to import the COM type library as a .NET assembly. If there is a PIA, VEE uses it, otherwise VEE creates an Interop Assembly (or assemblies if the COM type library references other type libraries) in the directory where the program is saved. After VEE gets the Interop Assembly, it gets all the type information from that assembly.

Note

To avoid the overhead of VEE having to copy over the generated Interop Assemblies from a temporary directory to your VEE program directory, save your VEE program first. This way, the generated Interop Assemblies will be directly saved in your VEE program directory.

Go ahead and select the COM tab. This may take some time as VEE scans your registry for COM type libraries. Now select the Microsoft ActiveX Plugin.

You are now prompted for the namespace to import. This an optional step, but go ahead and select Interop.ActiveXPlugin, System, and System.IO.

Note

The Import .NET Namespaces dialog box will come up every time unless you uncheck the check box in the .NET Assembly References dialog box.

From the Device menu, open the Function & Object Browser. Select .NET/CLR Objects from the menu options. Note how the Assembly window reflects the two selections you made earlier.

All of the namespaces are listed in the Namespace window. All of the types are listed in the Type window and all the members of each type are listed in the Members window. Members include constructors, fields, properties, methods, and enumerations.

If you have used ActiveX in VEE, you will find that selecting a .NET class member is almost exactly the same process. The differences are minor and include:

1. COM did not have any shared (static) members. If the .NET member is a static member, the help area shows the STATIC keyword. The static icon ( [image]) also appears next to the member icon. To invoke a static member, you invoke on the class, not on an object instance. You can use the Function & Object Browser to get yourself familiarized with the syntax.

2. Instance object variables are generated with the first letter in lower case. This is a clue to you that you are dealing with an instance member. This also means you need to declare and initialize a variable if you haven't already done so.

3. To create a .NET object, select the constructor (constructors and methods share this icon [image]) in the member list. As in the previous graphic, the Create Instance button is available. Selecting this button generates a formula template for creating a new .NET object. You can connect to the dateTime output pin in the following graphic to any input pin of any formula box that requires this .NET object as input.

4. The Enums ( [image]) in .NET are strongly typed, so you can no longer substitute an integer constant for an Enum like you did with ActiveX objects. You have to enter the full Enum name (minus the namespace if you have imported it) or use the Create Formula button and save yourself some typing. For examples, see Enum related examples in the examples\dotnet directory.

See Also

Importing a Namespace in VEE


Importing a Namespace in VEE

Importing a Namespace into VEE Pro

Namespaces qualify a type by creating a template for static members or enumerators and thereby eliminating the need for a type prefix.

Use

Importing a namespace is the same as using the Imports statement in Visual Basic or the using statement in C#. In both cases, you will not have to qualify the use of a type from that namespace. VEE supports two methods for importing a namespace.

The first method is by using the checkbox on the .NET Assembly References menu choice as shown in the graphic below:

The second method is to select the Import .NET Namespaces option from the Devices menu. A full list of .NET namespaces is listed and, to import one, just select the checkbox beside it.

If the assembly you select has no namespaces, the list will be empty.

If you have not imported a namespace for a class, the static members and enumerations for that class will be fully qualified by VEE's Function & Object Browser's Create Instance button automatically. This will make your formula boxes much larger.

Examples

See DateTime.vee and FileInfo.vee


VEE and PIAs

VEE and Primary Interop Assemblies

You already know from the topic ".NET Terminology" that a PIA is “...a unique, vendor-supplied assembly that contains type definitions (as metadata) of types implemented with COM. There can be only one primary interop assembly, which must be signed with a strong name by the publisher of the COM type library.” How does VEE make these PIAs available to you?

When you choose the COM tab in Device > .NET Assembly References, VEE goes through the registry and finds all registered COM type libraries on your machine. As you select COM type libraries, if the library has a PIA and the PrimaryInteropAssemblyCodeBase key for the COM type library is registered, then the PIA location is shown in the description area. Note that PrimaryInteropAssemblyCodeBase is only registered when the PIA is registered with /codebase option. Not all PIAs are registered this way. Currently, all Agilent IVI-COM drivers are registered with the /codebase option, but many assemblies are not. Also note that when you check a COM type library, all VEE does is to look at the registry, it does not load the interop assembly if there is one. Once you choose OK, if there is no PIA, then VEE will generate one or more Interop Assemblies automatically.

If you choose browse and select a PIA or an Interop Assembly directly, however, VEE actually loads the interop assembly in order to find out which COM type library it belongs to and whether it is a primary interop assembly or not, which is the key difference between browse/select and just a check on the COM tab list. After the interop assembly is loaded, VEE finds out which COM type library it belongs to and then checkmarks the corresponding COM type libraries under the COM tab list.


Programming .NET

Typing

A new type conversion function called asClrType has been added. AsClrType converts a VEE data type to .NET/CLR data type. The valid .NET/CLR data types include all of the primitive types (Boolean, Byte, Sbyte, Int16, Uint16, Int32, Uint32, Int64, Uint64, Char, Double, and Single), Decimal, Date/Time and String. An error will be thrown if the .NET data type is not valid or the conversion fails.

asClrType is rarely needed as VEE converts between VEE and .NET data types automatically most of the time. It’s only needed when you have to use a specific .NET data type that’s not natively supported in .NET or if you want to use a VEE data type like a .NET object, for example, in order to invoke the .NET object methods. For example, VEE converts between .NET String and VEE Text data types automatically, but if you want to use the many useful String functions provided by .NET, you will need to convert the VEE Text to a .NET String object first.

The .NET and Win32 APIs

For an excellent comparison of these two APIs see, http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dndotnet/html/win32map.asp

Programming Practices

Installing a New Assembly

Please review the .NET Terminology topic if assembly is a new term for you. Public assemblies must be installed in the Global Assembly Cache (GAC). The assemblies installed in the (GAC) are seen by all the applications on your computer. (Please refer to MSDN for more details.) Once the shared assembly is updated, you can reference it by choosing the Browse button and browsing to the original location of the assembly before it was installed in the GAC.

Most assemblies are not installed in the GAC. They are private assemblies. A private assembly should be located with the VEE program that references it. The first time you use the .NET Assembly References dialog box to browse and select a private assembly, VEE will copy it over to the same directory as your current VEE program if it is not already located there. This copying also makes distributing your VEE program easier and is known as xcopy deployment.

Updating an Assembly

If you have already referenced the shared assembly in your VEE program, you need to do a File/New or restart VEE again before the new version of the shared assembly will be loaded by VEE. If it is not a shared assembly but a private assembly, you need to do a File/New or restart VEE after manually copying the new version of the private assembly into your current VEE program directory.

Calling an Instance Method

When calling an instance method, it is easy to forget to declare and create the .NET object first. To avoid this problem, it is recommended that you use the Function & Object Browser and the Create Instance button to generate the constructor formula template first.

In the figure below, fileInfo is declared locally and initialized as System.IO.FileInfo object. You can wire the fileInfo output pin to the input pin of any subsequent formula boxes that require this object instance. Also note, that both the CreateInstance and the fileInfo.LastAccessTime formula boxes are created by VEE automatically. All you need to do is wire them together and provide any additional parameters.

Calling a Shared/Static Method

When you call a .NET member, if the member is Shared/Static, the word STATIC appears in the Function & Object Browser description box. Static methods are called from a .NET class directly, not from an object. Thus you do not need to create a .NET object first. The following graphic is an example of a static method with the namespace imported.

Tips

  • If you are calling a .NET method requiring a Long/Single/Double.../ from a VEE formula box where the parameter comes from an input pin, say 'A', you can often eliminate a 'Method Not Found' exception by simply double-clicking input pin A, and setting the required type to match: int32/Real32/Real64/etc.. This is easier than calling the built in asCltType function or the .NET System.Convert.To* functions.

  • The formula template generated for Instance members always begin with a lower case letter. Static members have a fully qualified name (namespace plus classname) unless their namespace has been imported.

  • When you call a .NET member, if the member is Static, the word Static appears in the description box of the Function & Object Browser. Static methods are called from a .NET class directly, not from an object. Thus, you do not need to create a .NET object first.

  • Enums in .NET are different from enums in COM. They are strong typed. There are two types of enums in .NET, one is treated as an enumeration of constants, the other is treated as bit fields. Only the latter type of enums are intended for bitwise operations. In VEE, both types of enums will have their underlying integral value displayed in the description area of the Function & Object Browser. You can use bitOr, bitAnd, etc. on the latter type of enums as in the VEE example, examples\dotnet\FileAttributes.vee.

  • There is a new Copy to Clipboard button in the Function & Object Browser. You can use this button to copy a formula text into the clipboard, and later paste it anywhere in a formula box. This is especially useful when you want to have multiple formula statements inside of one formula box.

Limitations

VEE does not support the creation of .NET Delegates

VEE does not support subscribing to .NET Events.

VEE does not support adding .NET visual controls to a VEE panel.

Examples

For an example of asClrType, see StringSplit.vee.

For an example of calling an Instance and Static methods, see FileInfo.vee


Converting VEE Data Types to .NET

Converting VEE Pro Data Types to .NET

VEE converts data types between VEE and .NET automatically for all data types that both VEE and .NET natively support. For example, Int16, Int32, Real64, etc. You may wish to undo this automatic conversion so you can use the data as a true .NET object. In those cases, you can use the new asClrType type conversion function to convert a VEE data type to a .NET/CLR type. See the conversion tables below for more details.

.NET operations in VEE will usually accept a precision-widening (type promotion) data type as a parameter, but not a precision-narrowing (type demotion) data type. For example, you may pass VEEs UInt8 to a .NET operation that requires a parameter of type System.Int16, but not the other way around. Also, if the .NET operation requires a ByRef parameter and you want to retrieve its result back, then the data type has to be match exactly. For example, if the .NET method requires a parameter of type ByRef Int32, then you can only pass VEEs ByRef Int32 data type. If you dont care about retrieving the result back, then you may skip the ByRef keyword and the normal parameter rule would apply.

The following tables illustrate the data type conversion functions between VEE and .NET.

For an example of how to use asClrType, see StringSplit.vee.

Tables

Table 1 - Converting .NET scalar data types to VEE data types in VEE 7.0

Convert From .NET Data Type | Convert To VEE Data Type | Notes
System.Boolean | Int16 | Use isVariantBool() to determine if the VEE Int16 was of type System.Boolean
System.Byte | Uint8 |
System.Char | Object | You can use a System.Convert.To* method to convert it to a .NET data type that VEE can convert automatically, e.g., ToInt32().
System.DateTime | Object | See examples\dotnet\DateTime.vee.
System.Decimal | Object | You can use a System.Convert.To* method to convert it to a .NET data type that VEE can convert automatically, e.g., ToInt32(). If the value does not fit in an Int32, an error 751 will occur indicating a System.OverflowException. The System.Decimal structure itself also provides a number of conversion methods.
System.Double | Real64 |
System.Enum | Object | See examples\dotnet\FileInfo.vee.
System.Int16 | Int16 |
System.Int32 | Int32 |
System.Int64 | Object | You can use a System.Convert.To* method to convert it to a .NET data type that VEE can convert automatically, e.g., ToInt32(). If the value does not fit in an Int32, an error 751 will occur indicating a System.OverlfowException.
System.SByte | Object | You can use a System.Convert.To* method to convert it to a .NET data type that VEE can convert automatically, e.g., ToInt16().
System.Single | Real32 |
System.String | Text | VEE automatically converts String to Text. If you want to use the many useful functionalities in the System.String class, you may use asClrType to convert the text back to System.String, e.g., Set dotNetString = asClrType(veeText, System.String); ModifiedString = dotnetString.Replace( ,_); Also see examples\dotnet\stringsplit.vee for an example
System.UInt16 | Object | You can use a System.Convert.To* method to convert it to a .NET data type that VEE can convert automatically, e.g., ToInt32().
System.UInt32 | Object | You can use a System.Convert.To* method to convert it to a .NET data type that VEE can convert automatically, e.g., ToInt32(). If the value does not fit in an Int32, an error 751 occurs indicating a System.OverflowException.
System.UInt64 | Object | You can use a System.Convert.To* method to convert it to a .NET data type that VEE can convert automatically, e.g., ToInt32(). If the value does not fit in an Int32, an error 751 will occur indicating a System.OverflowException.
System.Object | Object |

Table 2 - Converting VEE data types to .NET scalar data types in VEE 7.0

Convert From VEE Data Type | Convert To .NET Data Type | Notes
Int16 | System.Int16 | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
Int32 | System.Int32 | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
Real32 |  | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
Real64 |  | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
Text |  | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
UInt8 |  | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
<scaler of type *> |  | Use asVariantBool() on any scalar VEE data type that can be cast to an Int16, (UInt8, Int16, Int32, Real32, Real64, Text). You may also use the more generic asClrType, e.g., asClrType(veescalar, System.Boolean).
Date/Time |  | VEEs Date/Time is stored as type Real64. Use asClrType(veeDateTime, System.DateTime). See examples\dotnet\DateTime.vee.
Object |  | If VEE holds a pointer to a .NET Object.

Table 3 - Converting .NET array data types to VEE data types in VEE 7.0

Convert From .NET Data Type | Convert To VEE Data Type | Notes
System.Boolean Array | In16 Array | Use isVariantBool() to determine if the array was of type System.Boolean
System.Byte Array | UInt8 Array |
System.Char Array | Object | The VEE object holds a pointer to a System.Array .NET object. You can use the formula CreateInstance(mscorlib,System.String,charArray).ToString(); to convert an array to a .NET data type that VEE can convert automatically.
System.DateTime Array | Object | The VEE object holds a pointer to a System.Array .NET object.
System.Decimal Array | Object | The VEE object holds a pointer to a System.Array .NET object. You can use a System.Convert.To* method to convert each array member to a .NET data type that VEE can convert automatically, e.g., ToInt32().If the value does not fit in an Int32, an error 751 occurs indicating a System.OverflowException. The System.Decimal structure itself also provides a number of conversion methods.
Double Array | Real64 Array |
System.Enum Array | Object | The VEE object holds a pointer to a System.Array .NET object.
System.Int16 Array | Int16 Array |
System.Int32 Array | Int32 Array |
System.Int64 Array | Object | The VEE object holds a pointer to a System.Array .NET object. You can use a System.Convert.To* method to convert each array member to a .NET data type that VEE can convert automatically, e.g., ToInt32(). If the value does not fit in an Int32, an error 751 occurs indicating a System.OverflowException.
System.SByte Array | Object | The VEE object holds a pointer to a System.Array .NET object. You can use a System.Convert.To* method to convert each array member to a .NET data type that VEE can convert automatically, e.g., ToInt16().
System.Single Array | Real32 Array |
System.String Array | Text Array | VEE automatically converts String to Text. If you want to use the many useful functions in the System.String class, you can use asClrType to convert the text array back to a System.String array.
System.UInt16 Array | Object | The VEE object holds a pointer to a System.Array .NET object. You can use a System.Convert.To* method to convert each array member to a .NET data type that VEE can convert automatically, e.g., ToInt32().
SystemUInt32 Array | Object | The VEE object holds a pointer to a System.Array .NET object. You can use a System.Convert.To* method to convert each array member to a .NET data type that VEE can convert automatically, e.g., ToInt32(). If the value does not fit in an Int32, an error 751 occurs indicating a System.OverflowException.
System.UInt64 Array | Object | The VEE object holds a pointer to a System.Array .NET object You can use a System.Convert.To* method to convert each array member to a .NET data type that VEE can convert automatically, e.g., ToInt32(). If the value does not fit in an Int32, an error 751 will occur indicating a System.OverflowException..
System.Object Array | Object | The VEE object holds a pointer to a System.Array .NET object.

Table 4 - Converting VEE array data types to .NET data types in VEE 7.0

Convert From VEE Data Type | Convert To .NET Data Type * | Notes
Int16 Array | System.Int16 Array | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
Int32 Array | System.Int32 Array | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
Real32 Array | System.Single Array | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
Real64 Array | System.Double Array | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
Text Array | System.String Array | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
UInt8 Array | System.Byte Array | Use asClrType to convert to other .NET/CLR types. See asClrType documentation.
< type *> Array | System.Boolean Array | Use asVariantBool() on any VEE data type that can be cast to an Int16, (UInt8, Int16, Int32, Real32, Real64, Text). You may also use the more generic asClrType, e.g., asClrType(veeArray, System.Boolean).
Date/Time Array | System.DateTime Array | VEEs Date/Time is really of type Real64. Use asClrType(veeDateTimeArray, System.DateTime). See examples\dotnet\DateTime.vee.
ref, out, ByRef | Either scalar or array of the type indicated by the mapping table above | Use the VEE keyword ByRef. Not using the ByRef keyword will not cause a .NET operation exception, but the passed-in parameter will not be changed. This is probably not what the .NET class designer intended.


.NET and IVI Drivers

What is IVI? IVI is a new instrument driver standard being developed by the IVI Foundation. The IVI Foundation is a consortium established to promote specifications for programming test instruments. These specifications provide multiple benefits but primarily make instrument interchangeability simpler. For a review of the IVI Foundation, go to http://www.ivifoundation.org/.

Why would I want to use an IVI-COM driver? Assume two vendors provide an IVI-COM driver for a DMM. To meet the IVI standard, the base drivers must be interchangeable. This means that whichever driver you use on your system, the DMMs from either vendor will work. Your code is reusable without any intervention.

Use

How do I make IVI-COM drivers available to VEE? Install the IVI-COM drivers. To find drivers for your instruments, go to http://www.agilent.com/find/adn. If you are an ADN member, select Downloads from the menu > Drivers by Driver Type > IVI-COM Drivers and Components. Be sure to download and install the IVI-COM Shared Components before installing IVI-COM drivers. Also, be sure to select the button labeled "Install PIA's" on the Shared Components installer. If you are not an ADN member, it is an online source for Agilent drivers, evaluation software, documentation, and white papers. To sign up for this free service, fill out the registration form for new users.

Once the IVI-COM drivers are registered on your system, they are available just like any other COM component and, like most COM components, will appear on the COM tab of the Device > .NET References in VEE.

How do VEE and .NET make IVI-COM drivers available? Through .NET’s interop technology. Via the interop, the IVI-COM drivers become available to VEE. If there isn’t a primary interop assembly available for a COM DLL that you select, VEE attempts to generate an Interop Assembly (or more than one if the COM .dll references other type libraries). VEE then adds the Assembly Reference to the Function Object Browser’s .NET Object Assembly References list. At this point, the IVI-COM driver can be invoked just like any other COM type library.

Examples

Agilent recommends that you use the Device > .NET Assembly References COM tab rather than ActiveX. It will supply more of the types necessary for the use of the IVI driver. The Notepad for these examples is very helpful and should be explored fully. There are other examples also in ~installdir\examples\ivi-com.

IVIAgilentSA.vee and EPM_Averages_IVI_COM.vee

See Also

What is IVI? and .NET and COM


VEE and .NET Security

VEE 7.0 depends upon the .NET Framework and the CLR. There is one security issue to consider for network installations. If you install VEE on a network drive,

  1. Open a command prompt. Go to your system drive (usually C).

  2. Change directory to \[winnt or windows]\Microsoft.NET\Framework\v1.1.4322

  3. From the prompt run the following command:

Caspol –machine –addgroup “All_Code” –url File://[VEEInstallDir]/* FullTrust

The VEEInstallDir is your VEE installation directory on a network drive. (Caspol ships with the .NET Framework and is installed when VEE is installed.) You may also run the .NET Framework Configuration Wizard to achieve the same result. You must have administrative privileges to run either tool.

In addition to this, if your VEE program references .NET assemblies, VEE often needs to generate and/or save assemblies to an accessible location. So for example, if you open a VEE program with .NET references from email or a network without saving locally first, you might get a warning.


Processing Data

To process data, you operate on it with math functions available in the Function & Object Browser. Use the Function & Object Browser toolbar button to open the browser. You can combine the functions to create mathematical expressions.

Note

You can also process data before running a program by using numeric entry fields such as those in Constant objects. Numeric entry fields on some objects support the use of arbitrary formulas. The formula is immediately evaluated; the resulting value is used for the field. You cannot use variables in Constants. Also, the typed-in formula must evaluate to a scalar value of the proper type or of a type that can be converted to that which the object expects. In general, you can use any of the dyadic operators, parentheses for nesting, function calls, and the predefined numeric constant PI (3.1416...) in numeric entry fields.

The Function & Object Browser contains a set of mathematical functions to process your data in numerous ways. Each of these functions are expressions entered in a Formula object with the corresponding title, inputs, and outputs. You can change the expressions in the open view of each Formula object, and change their properties, too. All the functions that are listed in the Function & Object Browser can be used in any object in other menus that allow expressions. The objects in other menus that allow expressions are:

Data [image] Access Array [image] Set Values

Data [image] Access Array [image] Get Values

Data [image] Access Record [image] Get Field

Data [image] Access Record [image] Set Field

Device [image] Sequencer

Flow [image] If/Then/Else

Flow [image] Conditional (all conditional objects)

I/O objects that use transactions

Expressions may contain the names of data input terminals, data output terminals (I/O transactions and Formulas only), variables (global and declared), user-defined functions (compiled, remote, and UserFunctions), and any mathematical expression from the Function & Object Browser. Data input terminal names are used as variables. VEE is not case sensitive about names of input variables within expressions for USASCII keyboards. For non-USASCII keyboards, VEE is case insensitive for 7-bit ASCII characters only. Expressions are evaluated at run-time.


General Concepts

If you pass an array to a function, the function operates on each element of the array, unless stated otherwise. For example, sqrt of a scalar returns a scalar; sqrt(4) returns 2. But sqrt of an array returns an array of the same size; sqrt([1,4,9,64]) returns the array [1,2,3,8].

In VEE 5 and higher execution modes, all numbers in an expression field without a decimal point or "E" exponent are considered to be Int32. In VEE 4 and VEE 3 modes, all numbers are considered Real64 values, unless you use parentheses to specify Complex or PComplex values. Therefore, 2 is considered to be a Real64 or an Int32, depending on the execution mode of your program. (1, @2) is a PComplex number, while (1, 2) is a rectangular Complex number. 1.0 and 1E3 are always Real64.

Note

VEE interprets multiple values contained within parentheses as a Complex or PComplex value. If you need to use a Coord value in an expression, use the coord(x, y) function. The coord function takes 2 or more parameters. coord(1, 2) returns a Scalar Coord container with two fields.

All functions that operate on Coord data operate only on the dependent (last) field of each Coord. For example, abs(coord(-1, -2, -3)) returns the Coord (-1, -2, 3).

An Enum container is always converted to Text before every math operation except the function ordinal(x). Enum arrays are not supported. If you try to create an Enum array, a Text array is created instead.

For information on specific data type definitions, refer to Data Types.

Using Strings in Expressions

Strings within expressions must be surrounded by double quotes. You may use the following escape sequences within strings:

________________________________________

Escape Character

Meaning

________________________________________

\n | Newline
\t | Horizontal Tab
\v | Vertical Tab
\b | Backspace
\r | Carriage Return
\f | Form Feed
\" | Double Quote
\’ | Single Quote
\\ | Backslash
\ddd | Character Value. d is an octal digit.

________________________________________

Using Arrays in Expressions

Arrays in expressions can be used just like scalars, just refer to them by their name. Array constants can be entered directly into an expression (such as [1,2,3]). Arrays used in functions, like sin([1,2,3]), have the sin function applied to every element of the array. VEE requires commas between array elements.

Note

Array indices are 0-based. The indices start with zero and continue to n-1, where n is the number of elements in that particular dimension.

You can use expressions to access portions of an array. Once you've specified the sub-array in the expression, you can output the sub-array, or use it in further expression calculations.

You can access only contiguous sub-arrays from each array. To access sub-arrays, you must specify a parameter for each dimension in the array.

Use the following characters to specify array parameters:

The comma "," separates array dimensions. Each sub-array operation must have exactly one specification for each array dimension.

The colon ":" specifies a range of elements from one of the array dimensions.

The asterisk "*" is a wildcard to specify all elements from that particular array dimension.

Note

Waveform time spans, Spectrum frequency spans, and array mappings are adjusted according to the number of points in the sub-array. For example, if you have a 256 point Waveform (WF) and you ask for WF[0:127], you'll get the first half of the Waveform and a time span that is half of the old one.

Examples

A is an Array 1D, 10 elements long.

A[1] accesses the second element in A and outputs a scalar.

A[0:5] returns a one-dimensional sub-array that contains the first 6 elements of A.

A[1:1] returns a one-dimensional sub-array that contains one element, which is the second element of A. Note the difference between this and the first example, A[1].

A[2:*] returns a one-dimensional sub-array that contains the third through the tenth elements of A.

A or A[*] returns the entire array A.

A[1,2] returns an error because it specifies parameters for a two-dimensional array.

B is a 5x5 matrix (an Array 2D).

B[*] returns an error because it specifies only one parameter, and B is a two-dimensional array.

B[1,2] returns a scalar value from the second row, third element.

B[1,*] returns all of row one as an Array 1D.

B[1,1:*] returns all of row one, except for the first element, as an Array 1D.

B[4,1:4] returns an Array 1D that contains four elements: the second through fifth values from row 4.

B[5,5] returns an error because arrays are zero-based. The array can only be accessed through B[4,4].

B[1 1] returns an error because a comma must separate the dimension specifiers.

Building Arrays in Expressions

You can build an array from elements of other arrays or sub-arrays. Each element in the expression must specify the same number of dimensions and contain the same number of values in each dimension.

Examples

A is an Array 1D with ten elements. B is a 5x5 matrix.

[1,2,3] returns a three element Real Array 1D that contains the values 1, 2, and 3.

[A[0], A[5:7], A[9]] causes an error because both scalar and Array 1D elements are specified.

[A[0:4], B[0,*]] returns a ten element Array 2D (of size 2 by 5) that contains the first five elements from A as the first row and the first row from B as the second row.

[A[0], A[1], B[2,3], A[5]] returns a four element Array 1D that contains the first and second element of A, the element from the third row and fourth column of B, and the sixth element of A.

Using Variables in Expressions

You can create and set variables by using the Declare Variable and Set Variable objects, and you can access variables by using the Get Variable object. Refer to Declare Variable, Set Variable, and Get Variable for further information.

In addition, you can access a variable by including its name in a mathematical expression. You can include a variable in a mathematical expression in a Formula object, or in any object with a delayed-evaluation expression field. These objects include If/Then/Else, Get Values, Get Field, Set Field, and all devices using expressions in transactions, including To File, From File, From DataSet, From Stdin, To/From Socket, Sequencer, and Direct I/O.

To include a variable in an expression, just use the variable name as if it were an input variable. For example, suppose a program uses a Set Variable object to define the variable numFiles. Elsewhere in the program, a Formula object with input A may use the expression numFiles+3*A.

Note

Variable names are case-insensitive. Either upper-case or lower-case letters may be used. Thus, GLOBALA is equivalent to globalA.

To avoid errors or unexpected results, you should be aware of two limitations when you include variables in an expression:

1. Local input variables have higher precedence than global variables. This means that, in case of duplicate variable names, the local variable is chosen over the global variable. For example, if the expression Freq*10 is included in a Formula object that has a Freq input (a local variable), and there is also a global variable named Freq, the expression will be evaluated with the local variable Freq, not the global one. No error will be reported regarding this duplication.

2. Depending on the flow of your program, an object that evaluates an expression containing a variable may execute before the variable is defined. For example, suppose the variable globalA is set with a Set Variable object, and the expression globalA*X^2 is included in a Formula object. Depending on the flow of your program, the Formula object may execute before the Set Variable object executes. In this case, the Formula object won't be able to evaluate the expression because globalA is undefined. An error message will appear.

It is important that you take steps to ensure correct propagation -- that Set Variable executes first. You can do this by connecting the sequence output pin of the Set Variable object to the sequence input pin of the Formula object in this case, or of any other object that includes the variable in an expression to be evaluated. If a Get Variable object is used, its sequence input pin should also be connected to the sequence output pin of Set Variable. Also, if you declare a variable using the Declare Variable object, you must initialize it using Set Variable. For further information, refer to the "Variables" chapter of VEE Advanced Techniques.

Note

By default, Delete Variables at PreRun in the Default Preferences dialog box is checked (enabled), so values are deleted from variables when you run a program. This prevents variables from containing "old" data and causing unexpected results.

Variables can be arrays. Just access a variable array as if it were an input variable using array syntax, for example: GlobAry[2]. If a variable is a Record, use the record access syntax, such as globRecord.numFiles.

Using Records in Expressions

You can use expressions to access a field or sub-field of a record. Use the A.B sub-field syntax to access the B field of a record A. If A is a record with a field B, which itself is a record which has a field C, you may use the A.B syntax recursively to access the C field. That is, use the expression A.B.C. If A does not have a B field, or B does not have a C field, an error will result.

There is no limit on the number of recursions of A.B.C.D.E.F that may be used in expressions. Note that field names are not case sensitive (lowercase and uppercase letters are equivalent). Field names may be duplicated in sub-Records, so you may use the expression A.a.A.

Records are very useful as variables, so that one variable may hold several different values. Note that a Formula object can be used in place of a Get Variable. Thus, you can accomplish the GlobRec.numFiles access in one object, instead of using both a Get Variable and a Formula object to unbuild the record.

The record and array syntax may be combined in expressions to access a field of a record array (for example A[1].B), or to access a portion of an array that is a field of a record (for example, A.B[1]). Note the difference between A[1].b and A.b[1] (both are supported):

You would use the first for a record 1D with a field b. A[1].b accesses the field b of the second record element of the record array A.

You would use the second for a scalar record with a field b, which is a 1D array. A.b[1] accesses the second element of the field b of the record A.

To change a field in a record, use the assignment operator in a Formula object. For example, suppose you have a record R with a field A, and you wish to change the value of R.A to be sin(R.A). Just change the expression to R.A = sin(R.A). You can continue to use the record R (with the new value for field A) later in your VEE program.

Note

For information about using Objects in expressions to manipulate ActiveX automation objects and controls, see the manual, VEE Advanced Techniques.


Using Assignment Operations

The Formula object allows expressions that use assignment operations to change values in parts of arrays and records, and assign values to local and global variables. The Result output terminal contains that part of the array or record that changed, not the entire array or record. For example, in a Formula with the expression A[2] = 4 the Result terminal contains array element A[2] with a value of 4. It does not contain all of array A. Formula objects preset with assignments are available in the Function & Object Browser in Type: Operators, Category: Assignment.

Note

Assignment operations are allowed only in Formula objects.

For information about using assignment operations to manipulate ActiveX automation objects and controls, see the manual, VEE Advanced Techniques.

Allowed Syntax

Multiple expressions, separated by semi-colons, are allowed in Formulas. The left-hand side of expressions allow syntax that change the values for array and record elements, and for variables. The right-hand side must match exactly the part of the left-hand side that is being modified. For records, the schema (a field's type, shape, or size) cannot be changed, only its values. The following examples show left-hand syntax that works for arrays:

A[2]=
A[2, 3, 4:5]=
A[2:4, 4:6, 3:*, *]=

The following examples show left-hand syntax that works for records:

RecA.B=
RecA.B.C.D=
RecA[1].B=
RecA.B[1]=
RecA.B.C.D[1]=
RecA[1].B[2].C[3].D=
RecA.B[2:3].C[3:4]=

The following left-hand syntax is allowed to directly set global and local variables, and initialize declared local variables:

GLOBAL=2
TMP_LOCAL=4

Here are examples of assignments showing how the right-hand-side must match the part of the left-hand-side that is being modified. The data type of the right-hand side must be coercible to the data type of the left-hand side, such as integer to real or real to String. A coercion such as Complex to real cannot be done.

ArrayA[2:4] = ArrayB (ArrayB must be a one-dimensional array with three elements.)

ArrayA[2, 3, 4:5, 7, 8:9] = ArrayB (ArrayB must be a two-dimensional array, of size 2 by 2.)

Rec[3:4].field = ArrayB (ArrayB must be a one-dimensional array with two elements.)

Rec[3:4].field[4:5] = ArrayB (ArrayB must be a two-dimensional array, of size 2 by 2.)

Non-explicit use of arrays of records on the left-hand side of assignments is not allowed. If Rec is an array of records, the expression Rec.A=2 will cause an error, prompting a request that you use the full explicit syntax, Rec[*].A=2. A similar error results with Rec.B=2 if Rec is a scalar record, and B is an array; the resulting prompt will request that you use the explicit Rec.B[*]=2.

Note

In VEE 4.0 and later versions, the Set Values and Set Field objects are actually Formula objects with assignment expressions. These objects have been changed from their definitions in prior versions of VEE. Existing programs written with VEE 3.x and older, that use the Set Values and Set Field objects will retain the prior definition.

Global and Local Variables in Assignments

Assignments in Formula objects can change values in global and local variables with expressions such as A=2 or GlobalA[5]=2. Since variables can be undeclared globals, declared globals or locals, or directly-set locals, the Formula object will look for the variable A using the following order of precedence:

1. A local variable which is an input terminal. This overwrites the input terminal value, including its type and shape.

2. A local variable which is an output terminal. This variable is created and placed on the output terminal.

3. A global variable. The variable must already exist. Its value is completely changed, including its type and shape.

Given these rules, an error results if Formula contains an assignment such as tmp=2 where tmp does not meet one of these criteria.

Assigning values to global arrays and records requires added attention since these variables may be undeclared or declared. A global exists when it is created using an object such as Set Variable, or when it is declared using Declare Variable. For an undeclared global, its type and shape can be changed by an assignment expression; however, for a declared global, the right-hand side of the assignment must be coercible to the global’s declared type.

Very Important!

When you declare a global array or record variable using the Declare Variable object, the entire variable must be initialized collectively before you can change part of the global. The following figure shows the variable GlobalAry declared and initialized before an individual part is changed by the assignment in Formula.

Data Container Contents on Terminals

Formula object input and output terminals affect how the values for variables are changed by assignments. The data container on the Result output terminal contains the modified part of an assignment expression’s left-hand side, including any changes to the data type and shape. In a Formula with the expression ArrayA[2:4] = ArrayB[5:6], the Result output terminal contains ArrayA[2:4] with the values from ArrayB[5:6]. In an expression such as ArrayA[2]=4 where the ArrayA data type is Complex, the value for ArrayA[2] in the output terminal is converted to Complex (4,0).

The following output terminal names can be used:

Result is the default output terminal on Formula. It is a reserved name, and contains the result of an assignment expression. You can delete Result to use other outputs, then add it back if needed, but you cannot rename an output terminal Result.

An input terminal name. This value is copied from the input. If changed in an assignment, the new value is used on the output. The variable must exist and have a value before it can be used as an input terminal name.

A local variable name such as tmp that is created by an assignment expression such as tmp=2.

You can use additional output pins on a Formula to get various parts of a modified array or record out of the object. This lets you pass the modified part of a variable out one terminal and pass the whole variable out another terminal. To get the whole array or record on the output terminal, use a global variable in an assignment expression or add an output terminal to the Formula object for the array or record. If an output terminal exists that does not get a value assigned, an error occurs.

Mappings on arrays are ignored unless the entire container is modified. For example, ArrayA[2:4] = ArrayB[2:4] does not modify the mappings on ArrayA. But A = ArrayB[2:4] will set the mappings on A since it is replaced by ArrayB.

Error Recovery

Since a Formula can contain a series of expressions including assignments and other operations, errors are handled in certain ways. If an assignment or other operation is done, then a following expression errors, previous expressions are not undone. Consider the expressions Global[2]=24; 2/0 in a Formula. Global[2] is set to 24, then the division by zero causes an error. VEE will not set Global[2] back to its previous value.

Note

For procedures about using assignment operations, see the VEE Help (Help [image] Contents). In the How Do I … section, open the Work with Data section, then look at the topics under Working with Arrays (such as To Change Values in an Array), and at topics under Working with Variables.


Using Dyadic Operators

The set of dyadic operators have several additional conditions and guidelines. The dyadic operators are visible in the following categories of the Function & Object Browser in Type: Operators:

Category: Arithmetic

a + b

a - b

a * b

a / b

a ^ b (exponentiation)

a mod b (modulo - returns remainder of division)

a div b (integer division - no remainder)

Category: Comparison

a ~= b

a == b

a != b

a < b

a > b

a <= b

a >= b

Category: Logical

a AND b

a OR b

a XOR b

NOT a (a monadic that follows the same guidelines as dyadics)

When using dyadic operators on arrays, the array size, array shape, and array mappings (if they exist) must match. For Coords, the values of the independent variable for each Coord must match.

Precedence of Dyadic Operators

This list is the order of precedence of the dyadic operators. They are listed from highest to lowest, with operators of the same precedence listed on the same level.

1. parentheses ( and ) used to group expressions

2. ^

3. unary minus -

4. * / MOD DIV

5. + -

6. ~= == != < > <= >=

7. NOT

8. AND

9. OR XOR

Data Type Conversion

For the dyadic operators, the input values are promoted to the highest data type and then the operation is performed. The data type of the output is the highest input data type. For example, when the complex number (2, 3) is added to the String "Dog", "Dog"+(2,3), the result is the String "Dog(2, 3)".

Note

There is one exception to this rule. When you multiply a Text string by an Int32, the result is a repeated string. For example, "Hello"*3 returns HelloHelloHello. No data type promotion occurs in this case.

The data type order (from highest to lowest) is:

1. Object

2. Record

3. Text (Enum is treated as Text)

4. Spectrum

5. PComplex

6. Complex

7. Coord (no conversion to any other numeric type possible)

8. Waveform

9. Real64

10. Real32

11. Int32

12. Int16

13. UInt8

14. Variant

The Variant data type is not "fixed" as a specific kind of data. It can be one of the other data types as needed.

Object Considerations: Objects will not automatically demote to other types. No dyadic operations are supported on Objects themselves, but since most Objects have a default property which is a String or Integer value, most operations can be performed on Objects. The difference is that you end up performing the operation on the default property. For more information about Objects and their use with ActiveX automation in VEE, see "Using ActiveX Automation Objects and Controls" in the VEE Advanced Techniques manual.

Record Considerations: Records have the highest precedence of all data types, but other data types can be converted to the Record data type only by using special objects such as Build Record. Records will not automatically demote to other types, nor will other types automatically promote to the Record type.

The dyadic operators do support combining records and other data types, but they will always return a record in this case. A dyadic operation on a record and non-record will apply the operation with the non-record to every field of the record. For example, consider a record R with two fields A, a scalar real value (2.0), and B, a scalar Complex value (3,30). The expression R+2 will produce a record R with two fields A, a scalar real with value 4, and B, a scalar Complex with value (5,30). If the operation cannot be performed on every field in the record, an error occurs.

Dyadic operations on a record and any other type will return a record with the same "schema," so the resulting record will have the same fields with the same names, types, and shapes. The dyadic operation may not change the type or shape of a field of a record. For example, consider a record R with two fields A, a scalar real, and B, a scalar Complex. The expression R+(2,3) will cause an error. VEE will first try to add (2,3) to R.A, then do the same with R.B. The error occurs because the R.A field is a real and the result of R.A+(2,3) would be a Complex. The Complex cannot be demoted to a real to be stored back into R.A.

Dyadic operations on records using arrays treat the record as having higher precedence than the array. For example, [1,2,3] + [3,4,5] produces [4,6,8], so the arrays are combined piece by piece. But records have higher precedence than arrays. This means that if R is a record with two fields A and B, the expression R + [1,2] will try to add the array [1,2] to each field of R. It will not add 1 to R.A, and 2 to R.B.

Things get even more complicated when you combine arrays with record arrays. For example, suppose R is a record 1D array, two long, with three fields A, B, and C. The expression R + [1,2,3], or the expression R + [1,2] will add the entire array to each field A, B, and C for every element of R. Even though R is an array, the fact that it is a record is more important.

A dyadic operation on two records will combine them field by field, so the two records must have the same "schema." That is, each record must have the same number of fields, and each field must have the same name, type and shape, in the same order.

If you want to add 1 to field A, add 2 to field B, and so forth, the easiest way is to use multiple assignments (see Assignment). In a Formula object, enter the expression R.A=R.A+1,R.B=R.B+2. You can then use R.A and R.B with their new values in your program.

Coord Considerations: The Coord data type has some special rules associated with it:

Although arrays of integer and real data types can be promoted to Coord, a Coord cannot be converted to any other numeric type.

When unmapped arrays are converted to Coord, the independent Coord values (the first Coord fields) are created from the array indexes; the dependent Coord value (the last Coord field) contains the element value. For example, if array A is converted to a Coord and A contains [1,5,7], it is converted to a Coord array with [(0,1),(1,5),(2,7)] in it.

When mapped arrays are converted to Coord, the independent Coord parameter ranges from the low value of the mapping to the value Xmin+(Xmax-Xmin/N)*(N-1).

Spectrum Considerations: If you choose to use dB scaling, you must keep track of it yourself. Although dB-scaled data displays correctly (except on the Waveform (Time) display), many math functions such as fft(x), ifft(x), and those involving PComplex numbers don't operate correctly on dB-scaled data. If you need to use these operations, convert the dB-scaled data to linear scaling before operating on it.

When you are using particular dB units, some math functions give meaningful results, but only within the confines of those units. For example, if you add 20 to a dBW-scaled Spectrum, 20 is added to the magnitude of each element (which has the same effect as converting the Spectrum to a linear scale, multiplying each element by 100, and converting back to dBW).

Variant Considerations: The result of dyadic (+-*/, etc.) evaluations and functions cannot be a Variant

In the expression b=a, b will be the same type as a, even if it was a Variant.

In the expression b=a+2, b will never be a Variant, regardless of what a is.

In the expression b=sin(a), b will never be a Variant, regardless of what a is.

The function func(2+a) will always be sent a non-Variant, regardless of what a is.

The function func(a) will be sent a Variant if a is a Variant.

Just a variable name a, a monadic operator -a, or parentheses (a) will not change the data type of a.

Data Shape Considerations

For dyadic operations where both operands (inputs) are arrays, the size and shape of the arrays must match. The result of the operation is an array with the same size and shape as the input arrays, except for the relational operators (==, <, and so on, which always return a scalar.) If arrays have a different number of dimensions or are of different sizes, VEE returns an error. For example, [1,2] + [1,2,3] returns an error.

If you are operating on a scalar and an array, the scalar is treated as if it were a constant array of the same size and shape as the array operand. For example, 2 + [1,2,3] is treated as [2,2,2] + [1,2,3]. The result is [3,4,5].

When an n-dimensional array is converted to a Coord, the Coord data shape is an Array 1D with n+1 fields in each Coord element.


ActiveX Controls

VEE does not support all ActiveX Controls. If a control is incompatible with VEE, an error will probably occur when you add the control to your program or while you are using it.

At the time VEE 7.0 was released, the following ActiveX Controls were known to not work well with VEE and should be avoided:

Microsoft Forms Object Library

Microsoft ADO Data Control 6.0


Memory Leak in Transaction Objects

Under certain conditions, memory leaks occur when using transaction objects in your VEE program. Direct I/O and From File are examples of transaction objects.

The memory leak condition exists only if a transaction object contains two READ transactions that both reference the same output pin, but use different data types. The following pair of transactions is an example:

READ TEXT x STR
READ TEXT x REAL

Use one of the following workarounds to prevent the memory leaks:

If you do not need the value of x that results from the first transaction, you may reference a special symbol called null. Include the word null in the first READ transaction instead of using the data output pin name. The object reads the data and discards it, then executes the next READ transaction. The transaction object would contain:

READ TEXT null STR
READ TEXT x REAL

Add a second output pin to accommodate the two pieces of data and have each transaction reference a different data output pin. Such transactions might appear as:

READ TEXT x STR
READ TEXT y REAL


Memory Leak with Math Expressions

Memory Leak with Expressions that Error

Under certain very rare conditions, memory leaks may occur when using math expressions in Formula objects, or in transaction objects that accept math expressions.

Your program may leak memory when a Formula object uses an Error pin, and the Error pin fires during the expected course of program execution. An example of this condition is where an expression performs a divide-by-zero operation causing the Error pin to fire.

A similar condition exists in transaction objects that accept math expressions, and use Error pins. A To File object might contain the transaction

WRITE TEXT a/b EOL

Since math expressions are evaluated in transaction objects the same way as in Formula objects, the potential for memory leaks is the same.


User Contributed Programs

User Contributed VEE Programs

These examples are provided as illustrations only and are "as is". Agilent Technologies makes no warranty of any kind in their regard. They have been contributed by VEE users from all over the world. If you are interested in contributing a sample, submit it to vrf-examples@agilent.com. Please document the example thoroughly and let us know if you want your name and/or email address published.

ExcelAsDatabase.vee Use Excel as a 'database' for table lookup.

The Excel workbook consist of five fields (columns) in the Table worksheet: ID, Code, Project, Date and Comment.

The Query worksheet use Excel's DGET functions to lookup data in the table. The lookup value for the query is sent in from VEE and the query result is read back and presented in VEE.
InstrumentAssistant.vee Instrument Assistant example program

This program can be used to find all connected instruments on all configured GPIB and VXI interfaces. The program can also be used to communicate with a selected instrument (only GPIB instruments are supported). Standard IEEE488.1/488.2
commands can be sent in addition to userdefined commands. A history buffer that keep track of sent commands is included. Data can be read from the instrument using ASCII or binary block formats.

This example program use these features of VEE:
* The Dynamic I/O Automation Server
* Programmable Instrument Properties
* I/O configuration saved with the program file
SQLServerUsingADO.vee VEE-Database access

This simple example program illustrates how VEE can use Microsoft ADO (rev 2.1) Automation Server for integration with SQL Server 7.0 databases. SQL Server 7.0 must be available on a remote server or on this system as specified in the Server field. Specify (local) as server if VEE and SQL Server is running on same PC.

The program use SQL's pubs example database by default and:

  • Lists all databases on SQL server by reading the Catalog Schema
  • Finds all tables in one database (pubs) by reading the Tables Schema
  • Allow execution of SQL querys
  • Allow viewíng of tables
  • Traps ADO errors from SQL Server
MakeSelections.vee Make a multiple selection popup object

This example program contains a Multiple Selection object allowing the user to make one or more selections from an input
list. VEE's standard selection object only allow single item selection.

VEE_Window_mods.vee This example shows how you can change attributes of the VEE window. It demonstrates:
  1. The import of API functions (Function ImportLib)
  2. The creation of global constants on runtime from a string array (Function CreateGlobals)
  3. The way to find the Window handle of the current VEE application and to change the attributes of the window:
    1. Stay on top
    2. Allow resizing
    3. Show system menu
    4. minimize box enabled/disabled
    5. maximize box enabled/disabled
    6. Hide the entire VEE program for a specified amount of time

Contributed by Georg Nied eMail:info@gn-software.de

Change character in string.vee This function changes one character in a string into a different character.

Submitted by Juan Carlos Martín Castillejos

nidaq.vee Call NI-DAQ library entry points.

This include file has been modified to work the Agilent VEE Import Library object to support the NIDAQ32.DLL.

This modified version is based on the 6.6 version of NI-DAQ.

All Instrument programs below were submitted by Tom Silchia
856xTDFB.vee Extracts trace data from the HP/Agilent 8560E-Series Spectrum Analyzers.TDF B (B-Format):

Return Binary Numbers in Measurement7.0 7.0 The binary (B) format transmits data in measurement units, as binary numbers. This format provides the fastest data transfer and requires the least amount of memory to store data. Each data point is transferred in binary as two 8-bit bytes; the most significant byte is sent first, followed by the least significant byte. Binary data can also be easily converted into measurement data. If speed and memory are important considerations, you may prefer B-format to P-format. Unlike A-block and I-block formats, the B-format does not send a header. The data is sent immediately, and the end-or-identify message (EOI) is sent with the last byte.

856xTDFI.vee Extracts trace data from the HP/Agilent 8560E-Series Spectrum Analyzers. TDF I (I-block format):

Return Indefinite Block-Data Fields in Measurement Units. Very similar to A-block format, the I-block format transmits data in measurement units as binary numbers in an indefinite block-data field of unknown size. Each data point is sent as two 8-bit bytes; the most7.0 significant byte is sent first, followed by the least significant byte. The I-block format also transfers a header before the trace data. The header is comprised of ASCII characters "#", and "I".

856xTDFM.vee Extracts trace data from the HP/Agilent 8560E-Series Spectrum Analyzers. TDF M (M-format):

Return Decimal Numbers in Measurement Units (output only). The measurement units (M) format transfers trace data as ASCII integer values in measurement units, which is the internal format used by the spectrum analyzer. See Figure 5-8 on page 305. The displayed amplitude of each element falls on one of 601 vertical points (with the 601st equal to the reference level). For example, the peak of the signal in Figure 5-8 on page 305 is equal to -10 dBm, or one division below the reference level. This is equal to 540 measurement units (600 measurement units at the reference level, less 60 measurement units for one division down, equals 540 measurement units). There are also ten additional points of overrange. Measurement units range from 0 to 610. A line feed (ASCII code 10) follows data output. The end-or-identify message (EOI) is sent with a line feed. The M-format is faster than the P-format, but most applications will require computer conversion to parameter units. Also, because the M-format transfers data as ASCII characters, the data can be viewed directly.

856xTDFP.vee Extracts trace data from the HP/Agilent 8560E-Series Spectrum Analyzers.

TDF P: Return7.0 Decimal Numbers in Parameter Units The real number, or "P" format allows you to receive or send data as7.0 ASCII decimal values in real-number (parameter) units. This is the7.0 default format when the instrument is turned on, and when instrument7.0 preset (IP) is activated. Numbers are in dBm, dBmV, dBmV, volts, or7.0 watts, as determined using the amplitude units (AUNITS) command.7.0 Default units are volts for linear trace information, and dBm for7.0 logarithmic trace information.7.0 A line feed (ASCII code 10) follows data output. The end-or-identify7.0 message (EOI) is sent with a line feed.7.0 NOTE When using the P-format, be sure to include amplitude units with the7.0 trace data using the AUNITS command.7.0 Real-number data can be an advantage if you wish to use the data later7.0 in a program. However, data transfers using P-format tend to be slow7.0 and require more storage memory (approximately 1200 bytes for binary7.0 and 4800 bytes for real numbers). In some cases, P-format can take up7.0 to four times the amount of controller memory compared to binary7.0 format.

859xTDFBB.vee Extracts trace data from the HP/Agilent 8590E-Series Spectrum Analyzers.

7.0 TDF B enables the binary format. With the binary format, the marker or trace data is transferred as bytes. Of all the trace data formats, TDF B transfers trace data the fastest. The setting of the MDS command determines whether the trace data is transferred as one or two 8-bit bytes.7.0 NOTE : This example utilizes the MDS B (Measurement Data Size) as BYTE. Transferring a single byte (8-bits) per data point. When transferring trace data, MDS B transfers trace data the faster than MDS W because only 401 bytes are transferred. Because MDS B combines two bytes into one byte, some resolution is lost.

859xTDFBW.vee Extracts trace data from the HP/Agilent 8590E-Series Spectrum Analyzers.

TDF B enables the binary format. With the binary format, the marker or trace data is transferred as bytes. Of all the trace data formats, TDF B transfers trace data the fastest. The setting of the MDS command determines whether the trace data is transferred as one or two 8-bit bytes.7.0 NOTE : This example utilizes the MDS W (Measurement Data Size) as WORD. Transferring a word of 2 bytes (8 bits each).per data point. MDS W transfers trace data with no loss of resolution.

859xTDFI.vee Extracts trace data from the HP/Agilent 8590E-Series Spectrum Analyzers.

7.0 TDF I is the I-block data format. With the I-block data format, trace data must7.0 be preceded by “#,” and “I.” The setting of the MDS command determines whether the trace7.0 data is transferred as one or two g-bit bytes. Unlike using the A-block format, you do not7.0 provide the number of data bytes when sending trace data back to the spectrum analyzer.

859xTDFM.vee Extracts trace data from the HP/Agilent 8590E-Series Spectrum Analyzers.

7.0 TDF M is the measurement data format. The measurement data format transfers7.0 trace data in measurement units, and the measurement data can range from -32768 to7.0 + 32767.

859xTDFA.vee Extracts trace data from the HP/Agilent 8590E-Series Spectrum Analyzers.
The A-block format is similar to binary format in that each data point is sent as two 8-bit bytes (this, too, is in the internal representation of measurement data). A-block format also transfers a four-byte header before the 401 points of trace data. These bytes are the ASCII character “f’, “A”, and two-byte number representing the length of the trace data, followed by the data bytes.
8510C_pass_thru.vee

Provides an outline for a method to use the 8510 Pass Thru functionality.

8510_hpgl_Acq.vee | Programming sample for acquiring and dumping the HPGL graphics from the 8510 family network analyzers.
856xPlot2File.vee Acquires an HPGL plotter dump from an 8560E-Series Spectrum Analyzer to a file.

Once acquired the temp.plt file can be viewed via any compatible HPGL file viewer. Note newer versions of Microsoft Office products by default do not include the HPGL viewer. Visit Microsoft's website and search on hpgl 32 bit for downloads that can enable HPGL file imports into Microsoft Word and/or Microsoft Excel.

871xLearn_String.vee Acquire and send the 871x learn string from and to the instrument.

The application is intended to be executed on 8711C, 8712C, 8713C, 8714C and the entire 871xET/ES vector network analyzer families. The program is broken into a main, two user objects, and one user function. The user object "getLearnString" acquires the learnstring and stores the data to text file, 'C:\learnData.txt". This object has it's own notes detailing operation and execution. The user object "sendLearnStringOut" queries the learn string data from the file 'C:\learnData.txt" and then writes the bytes into the analyzer thus recalling the learnString State. This object has it's own notes detailing operation and execution. The "err_check" user function provides a means of confirming that no errors are caused during the program execution. The OK buttons allow the user to configure the analyzer, acquire the learnstring, reset analyzer (to a preset) and then resend the acquired learnstring, confirming proper operation.

8753_freq_data.vee Extract the trace frequency point data from an 8753/8720 family network analyzer.

Use the OUTPLIML command to extract the stimulus and marker data. NOTE the LIMIT test FUNCTION is NOT on! The command provides a means to extract the frequency points.

8753_marker.vee Reading the marker data out of the 8753/8720 family VNAs with several methodologies.

Note that marker data and the validity of the data is a function of the analyzers DISPLAY FORMAT. The first value is the marker reading; the second value may or may not be valid as a function of the DISPLAY FORMAT; the third value is the STIMULUS (frequency or time). For full details refer to the 8753/8720 Programmer's Guide Marker Data section. For this example the FORMAT is LOG MAG, per the manual the second marker value is "insignificant", a.k.a. a place holder, or equivalently JUNK

4395A_Extract_State.vee Extract the state from a 4395A combination analyzer

This application has been tested with the 4395A combination analyzers. The application will catalog the INTERNAL MEMORY and parse all saved files of type state (as indicated by "*.STA" file type). Once the file list has been created, the Agilent VEE application will extract all the *.STA files to the external controller. The *.STA files are binary files which can be sent BACK to the 4395A (either via the PC and VEE, or via 3.5" floppy).

4396b_ascii_out.vee Extract a FORMATTED data trace from a 4395A, 4396A, or 4396B combination analyzers.

The program queries the instrument(s) for the FORMATTED data trace as a "FORM4"(ascii) data transfer. The data trace array size is automatically determined from the queried number of points (a.k.a. "no_poin") and then passed to the real_32 array variable. The program outlines some other Agilent VEE features such as querying the trace START Frequency, STOP frequency and NUMBER of POINTS, and then passing these to a linRamp function (embedded in Agilent VEE) in order to AUTOMATICALLY create the frequency points for each data value. Another feature is the capability to create X-vs-Y plots for displaying the frequency/amplitude data extracted from the analyzer. As a final note the minimum and maximum data values are easily extracted and displayed via Agilent VEE.

4194a_gain_delay.vee | Extract the GAIN and GROUP delay data from the Agilent 4194A impedance analyzer.
4294A_ascii_out.vee Example for the Agilent 4294A Impedance Analyzer.

Outlines methods to acquire Impedance, Phase, Parallel Capacitance, Parallel Conductance, in both FORMATTED display trace data and REAL and IMAGINARY data trace formats.

8753_Limit_test.vee | A method for reporting a limit line failure on the 8753/8720 family of vector network analyzers
8753ES_registerRecall.vee | Outlines a process for recalling instrument states from internal memory on the 8753/8720 family vector network analyzers.
8753ES_NumGroup_OPC.vee | Demonstrates the use of use of *OPC? and NUMG (or number of groups) for the 8753/8720 family of vector network analyzers to coordinate and synchronize end of sweep when averaging is activated within the analyzer.
8753ES_NumGroup_SPOLL.vee | Demonstrates the use of SPOLL and NUMG (or number of groups) for the 8753/8720 family of vector network analyzers to coordinate and synchronize end of sweep when averaging is activated within the analyzer
8753Graphics.vee | Write HPGL TEXT to the 8753/8720 family network analyzers display.
8753LearnStr.vee | Program for reading and writing the binary learn string from and to the 8753 and 8720 family of vector network analyers.
8757_PassThru.vee | Program for the 8757 Scalar Network Analyzer and compatible signal source. The program outlines a method for using the PassThru mode to access and communicate with the signal source connected to the analyzers "8757 System Interconnect" GPIB buss. This is a dedicated GPIB for controlling the source directly from the 8757 scalar analyzer.
8757_E8257C_ScpiPassThru | Program for the 8757 Scalar Network Analyzer and compatible signal source. The program outlines a method for using the PassThru mode to access and communicate with the signal source connected to the analyzers "8757 System Interconnect" GPIB buss. This is a dedicated GPIB for controlling the source directly from the 8757 scalar analyzer.
4284A_BIN_ASCII.vee | Program for outlining how to extract either ASCII or BINARY data transfers from the 4284A Impedance Analyzer.
4263B_BIN_ASCII.vee | Program for the 4263B LCR meter. Outlines how to acquire either a BINARY or ASCII data transfers from LCR meter.
e5100a.vee | Program for the E5100A low frequency network analyzer. Provides an outline of using the E5100As built in waveform analysis to acquire the statistics for Channel 1 (as GAIN) and Channel 2 (as phase).
E5100A_Resp_Cal_Array.vee | Program for the E5100A low frequency network analyzer outlining how to extract a transmission thru response calibration array (as a FORM4 - ASCII transfer) from the analyzer. The extracted array is saved to a file on the controlling PC.
8753_form2.vee | Program for the 8753 and 8720 family of vector network analyzers. The program provides a tutorial for both synchronizing sweep complete via an SRQ mask and extracting the trace data array as a FORM 2 - REAL 32 binary block transfer.
8753_form3.vee | VEE Sample program for the 8753 and 8720 family of vector network analyzers. The program provides a tutorial for both synchronizing sweep complete via an SRQ mask and extracting the trace data array as a FORM 3 - REAL 64 binary block transfer.
8753_form3_COMPLEX.vee | Program for the 8753 and 8720 family of vector network analyzers. The program provides samples of: synchronizing sweep complete via an SRQ mask; extracting Real and Imaginary trace data array as a FORM 3 - REAL 64 binary block transfer; and how read the array into a variable defined as a COMPLEX array.
8753_form4.vee | Program for the 8753 and 8720 family of vector network analyzers. The program provides a tutorial for both synchronizing sweep complete via an SRQ mask and extracting the trace data array as a FORM 4 - ASCII data array transfer.
8753_hpgl_Acq.vee | Program for acquiring and dumping the HPGL graphics from the 8753 and 8720 family network analyzers.
EPM_Sensor_Status.vee | Program for the EPM E-Series of average sensing RF power meters. The program uses the "STATUS:DEVICE:CONDITION? bit response to determine which channels have sensors connected and if they are connected to either the front or rear panel connections.
EPM_Averages_SPOLL.vee | Program for the EPM E-Series of average sensing RF power meters. The program uses the manual filter mode which allows the user to set the filter length (a.k.a. averages). The program also utilizes an SPOLL to determine when the measurement data is available.
EPM_LoUpLimit_Test.vee | Program for the EPM E-Series of average sensing RF power meters that shows the use of the "STAT:OPER:LLF:SUMM:COND?" (lower limit failure reporting) and the "STAT:OPER:ULF:SUMM:COND?" (upper limit failure reporting) status queries.
EPM_LoadCalTable.vee | Program for the EPM E-Series of average sensing RF power meters. The program outlines how to catalog the list of internal sensor calibration tables, select a table, and then write user calibration factors, at user defined frequencies, to the selected calibration table.
EPM_Meas_SPOLL.vee | Program for the EPM E-Series of average sensing RF power meters. The program uses the MEASURE command which allows the power meter to control the instrument setup. The program also utilizes an SPOLL to determine when the measurement data is available.
ENA_StateRdWrt.vee | Program for the ENA (E5070/E5071) family of network analyzers. Provides examples of cataloging the memory, extracting a state file as a binary block to the PC, and then recalling the binary state file (from the PC) and writing back the binary block to the ENA memory.

ENA_Average_SPOLL.vee

Program for the ENA (E5070/E5071) family of network analyzers. The program is intended to provide a guide for ONE method of detecting an AVERAGE COMPLETE CONDITION on the ENA Series Vector Network Analyzers. An E5071A was tested.
ENA_Fast_SPOLL | Program for the ENA (E5070/E5071) family of network analyzers. The program can be utilized as a launching point in understanding typical trace sweep speeds and data acquisition and transfer speeds as a function of various bandwidths on the network analyzer.


Guide to VEE Example Programs

This guide summarizes the example programs shipped with Agilent VEE Pro. These examples demonstrate useful programming techniques, and are divided into the categories listed below.

Click on a category to see a list of programs and their summaries. The button shown with each VEE program opens it in a new VEE window.

Note

Examples in the examples\Manual directory are not listed here since they are discussed in other VEE Help topics, and in the VEE manuals.

ActiveX Controls

Analysis

Electrical Applications

Dynamic I/O Configuration

Financial Applications

Games

Instrument Measurements

Manufacturing Applications

MATLAB Script

Mechanical Applications

Microsoft .NET Framework

Microsoft Access

Microsoft Excel

Microsoft Outlook

Microsoft Word

Old VEE RPC API

VEE Lib Examples

VEE Programming Concepts

Visual Basic

VB Script

Visual C++


Microsoft .NET Examples

Example Name

Description

Referenced Assemblies/
Namespaces/Classes

Difficulty

ComputingHash.vee

Demonstrates how to compute a hash of the contents of a VEE record. The VEE record and the hash are saved out to a file. The file is then re-read. The hash is recomputed on the record that is extracted from the file and then compared to the hash stored in the file. This is a simple way to verify the contents of the file are intact.

Assemblies: Mscorlib

Namespaces: System. System.Text, System.Security.Cryptography

Classes: System.Security.Cryptography.SHAManaged, System.Text.Encoding

3

DateTime.vee

Demonstrates the built-in DateTime functions in the .NET Framework, e.g., getting the current date and time, getting the day of week, getting the year, querying whether its a leap year, etc.

This is also a good example to see how static and instance members are mixed together and invoked from VEE. The System namespace is imported to save some typing.

Assemblies: Mscorlib

Namespaces: System

Classes: System.DateTime, System.DayOfWeek

1

DateTimeConversion.vee

Demonstrates how to convert between .NET DateTime and VEE time. It also shows an example of using the new asClrType type conversion function. Note that with .NET's DateTime class, it is easy to convert UTC time to local time. The System namespace is imported to save some typing. Also, every object in .NET has at least one ToString method to produce nicely formatted print of the object information; this example shows how powerful it can be.

Assemblies: Mscorlib

Namespaces: System

Classes: System.DateTime

2

DeleteDir.vee

Demonstrates how easy it is to query whether a directory exists, create a deep directory hierarchy and recursively delete it. This tiny example serves as an introduction to the many easily accessible file system management functions in the .NET Framework. See FileOperations.vee for a larger number. For an overview, browse the class under the System.IO namespace. Also, see MSDN for more details.

Assemblies: Mscorlib

Namespaces: System.IO

Classes: System.IO.Directory

1

DiskInfo.vee

Demonstrates how to get the size and free space of your disk. This used to a non-trivial task involving importing kernel32.dll and invoking the Win32 API call. Compare this example with examples\contrib\Win32\kernel32.vee. This example also queries a lot of other disk information. See the user function show_all_diskproperties. This is also a good example to see how to access and enumerate .NET collections.

Assemblies: Mscorlib, System.Management

Namespaces: System, System.Management

Classes: System.Management.ManagementObject

3

DrawOnBitmap.vee

Demonstrates how to create a bitmap of the desired size and type. You can then draw on it using the System.Drawing.Graphics object. The resulting bitmap is saved to the specified file and then the VEE picture object is used to display the bitmap. There are two key concepts in this example. The first is getting a "Graphics" object from the bitmap using the static method System.Drawing.Graphics.FromImage() method. The Bitmap class derives from the System.Drawing.Image class, so an instance of a bitmap can be passed to this function. Once you have a graphics object, you can draw pretty much anything you want on it. The second key concept is to Dispose of any drawing objects that are explicitly created. In this example, the Graphics object created by calling FromImage, the font that was create as well as the Bitmap object are all disposed. Failure to so can cause the VEE program to consume too many GDI resources and adversely affect program performance.

Assemblies: Mscorlib, System.Drawing

Namespaces: System.Drawing, System.Drawing.Imaging

Classes: System.Drawing.Bitmap, System.Drawing.Graphics, System.Drawing.Font, System.Drawing.Brushes, System.Drawing.Pens, system.Drawing.Imaging.PixelFormat, System.Drawing.Imaging.ImageFormat

Environment.vee

With .NET Framework, it is easy to get information about your program environment, e.g., the current directory, the command line, the machine and user name, etc.

This is also a good example to see how static members are invoked from VEE.

Assemblies: Mscorlib

Namespaces: System

Classes: System.Environment

1

EnumerateEnums.vee

Demonstrates some interesting things that you can do with .NET Enumerations. This example gets the type of System.FileAttributes, iterates through the enumerations defined in that type, and prints out the textual and numerical values of those enumerations. The example is designed generically enough that you can apply the EnumNamesAndValues user function on any .NET Enum types, not just the System.FileAttributes type.

Assemblies: Mscorlib

Namespaces: System

Classes: System.Enum, System.FileAttributes

3

FileInfo.vee

Demonstrates how easy it is to obtain attributes of a file, e.g., the creation time, the last access time, the file length and whether it is read-only. Note that System or System.IO namespaces are imported to save some typing.

This IsFileReadOnly user function also shows how you would do bit operations on .NET Enums and how you can convert a .NET type to another .NET type using the System.Convert class.

Assemblies: Mscorlib

Namespaces: System, System.IO

Classes: System.Convert, System.FileInfo, System.FileAttributes

2

FileOperations.vee

Demonstrates VEE 7.0's use of the .NET Framework's File and Directory classes. First, it gets the special Personal Folder directory which is usually under "document settings\username"; it then creates a deep directory hierarchy under the personal folder if it doesn't already exist; it then creates a text file there and writes a formatted line to the file; finally it opens the file for reading. This also demonstrates how to get all the logical drives on your machine.

Assemblies: Mscorlib

Namespaces: System.IO

Classes: System.IO.Directory, System.IO.File, System.IO.Path, System.IO.StreamWriter

2

GetStockQuote.vee

Demonstrates how to get stock quotes with only 10 lines of code. Just type in the ticker symbol for your favorite stock and you get the 20 minute delayed quote back.

This example shows some powerful things that you can do with the .NET Framework, e.g., web request and response, reading a stream, string matching via regular expressions, etc.

Assemblies: Mscorlib, System

Namespaces: System.Net, System.IO, System.Text.RegularExpressions

Classes: System.Net.WebRequest, System.Net.WebResponse, System.IO.Stream, System.IO.StreamReader, System.Text.RegularExpressions.Regex

3

HashTable.vee

Demonstrates one of the built-in data structures in .NET Framework. A hash table is a collection of key and value pairs organized based upon the hash code of the key. A Hash table allows a more efficient search algorithm than an Array does. You can store any type of objects based on any type of key as long as the key implements a couple of methods (GetHashCode and Equals). This example shows how to add the key and value pairs, get the number of items stored, find out whether a key exists in the hash table, do a search based on a key, etc.

Assemblies: Mscorlib

Namespaces: System.Collections

Classes: System.Collections.Hashtable

1

IPAddress.vee

Demonstrates how to easily get the IP address of your machine (or any machine). This example also shows how to access a .NET object array using the GetValue Array method.

Assemblies: Mscorlib, System

Namespaces: System.Net

Classes: System.Net.Dns, System.Net.IPHostEntry, System.Environment, System.Array

1

ProcessInfo.vee

Demonstrates how easy it is to get information about a process like its virtual memory size, total processor time, handle count, priority, start time, number of threads, thread ids, thread states and thread priorities.

Assemblies: Mscorlib, System

Namespaces: System, System.Diagnostics

Classes: System.Diagnostics.Process, System.Threading.Thread

2

Registry.vee

Demonstrates how to use the .NET Framework classes to access your registry. This used to be a non-trivial task involving importing advapi32.dll and invoking some hard to understand WIN32 API calls. Compare this example with examples\contrib\advapi32.vee.

Assemblies: Mscorlib

Namespaces Microsoft.Win32

Classes: Microsoft.Win32.Registry, Microsoft.Win32.RegistryKey

1

SelectFiles.vee

Demonstrates how to use one of the built-in common dialogs in the .NET Framework. In this example, the OpenFileDialog class is used to display a Windows standard open file dialog box, but you could just as easily use others like SaveFileDialog, PrintDialog, ColorDialog, FontDialog, etc. You can still use VEEs File Name Selection dialog box, but you can get more flexibility with .NETs OpenFileDialogBox. For example, you can turn on multi-selection of files easily.

Assemblies: System.Windows.Form

Namespaces: System.Windows.Form

Classes: System.Windows.Forms.OpenFileDialog

1

Sendmail.vee

Demonstrates how easy it is to send an email with .NET Framework. This example accomplishes the same result as the lib\SmtpMail.vee example with a lot less work. With .NET, you can send an email from your VEE program with eight lines of code or less.

Assemblies: System.Web

Namespaces: System.Web.Mail

Classes: System.Web.Mail.SmtpMail

2

SpecialFolders.vee

Demonstrates how to get the paths of all kinds of special folders on your machine. This used to be a non-trivial task involving importing shfolder.dll and invoking Win32 API calls. Compare this examples with examples\contrib\win32\shfolder.vee.

Note that the namespace is imported.

Assemblies: Mscorlib

Namespaces: System

Classes: System.Environment, System.Environment.SpecialFolder

1

Stack.vee

Demonstrates one of the built-in data structures in the .NET Framework. A stack is a last-in first-out collection, which is in contrast to a queue which is a first-in first-out collection. This example shows how to add (push) objects to the stack and remove (pop) them.

Assemblies: mscorlib

Namespaces: System.collections

Classes: System.Collections.Stack

1

StringSplit.vee

Demonstrates how to split a string into multiple strings using any number of delimiters.

The .NET System.String class has many useful functions. While VEE converts .NET String to VEE Text automatically, sometimes you may want to use the String as a .NET object in order to use its many functions. This example shows how to convert a VEE Text to .NET String. It also shows how to convert an array of VEE Text to an array of .NET System.Char.

This is a good example to see how to use the new AsClrType type conversion function.

Assemblies: mscorlib

Namespaces: System

Classes: System.String, System.Char

2

TextEncodedBInary.vee

Demonstrates how to use the .NET Framework classes to encode binary data as text using Base64 and then convert the Base64 text encoded binary back to binary form. You can use this technique to send binary data in a text email if you didn't have access to file attachments.

Assemblies: Mscorlib

Namespaces: System

Classes: System.Convert

2

TimeZone.vee

Demonstrates how to use the System.TimeZone object.

  • Getting the UTC offset of the current time

  • Determining if a time is in Daylight Savings Time

  • Getting the name of the Daylight Savings Time period

  • Getting the name of the standard time period

  • Getting the start and end times of Daylight Savings time

Assemblies: Mscorlib

Namespaces: System, System.Globalization

Classes: System.TimeZone, System.Globalization.DaylightTime

1

WhichOS.vee

Demonstrates how to get the version and platform of your operating system.

The README details the steps to reproduce the example.

Assemblies: mscorlib

Namespaces: System

Classes: System.Environment, System.OperatingSystem

1

*Difficulty Level is numbered from 1 to 3, 1 being the easiest and requiring the least amount of .NET and VEE experience.


ActiveX Controls
examples\ActiveXControls

The ActiveX controls listed here must be installed on your system before the programs will run properly.

1. ActiveMovie Control

2. & 3. Microsoft Calendar Control

4. Microsoft Common Dialog Control

5. ListView Control

6. ProgressBar Control

7. Microsoft RichTextBox Control

ActiveX Control Examples
 | Example Name | Description
1 | ActiveMovie.vee | Demonstrates how to use the ActiveMovie control to display a movie file.
2 | Calendar.vee | Demonstrates the basics of using an ActiveX control: setting and getting properties and calling methods using the Microsoft Calendar control.
3 | CalendarQuery.vee | Demonstrates the use of the Microsoft Calendar control. The program displays two Calendar controls to the user to get a Start date and a Stop date for a simulated database query.
4 | CommonDialog.vee | Demonstrates the use of several Windows common dialog boxes as implemented in the Common Dialog ActiveX control.
5 | ListView.vee | Demonstrates the use of the ListView control provided by comctl32.ocx.
6 | ProgressBar.vee | Demonstrates the use of the ProgressBar control provided by comctl32.ocx.
7 | RichTextBox.vee | Demonstrates how to get RTF text into the RichTextBox control, then save that text in a VEE program to avoid distributing a separate .rtf file with your program.


Analysis
examples\Analysis

Analysis Examples
Example Name | Description
AnalogFilter.vee | Shows how to display the transfer function of a filter, and how to use array math rather than iterators.
curvefit.vee | Illustrates various regression methods to perform curve fitting.
magDist.vee | Demonstrates magDist() function generating a histogram of data point distribution.
mixer.vee | demonstrates how to: Simulate signals using the Virtual Source. Obtain information from a sophisticated data structure.
psk.vee | Illustrates the use of many objects in unconventional ways to implement a message encoding/decoding scheme.
ReadMarkerValues.vee | Demonstrates a pair of UserFunctions that set markers on an XY Trace display, then read the values back out.
setmap.vee | Shows how to retrieve meaningful information from a Spectrum data type using the Data [image] UnBuild Data [image] Spectrum, PComplex, and Data [image] Access Array [image] Set Mappings objects.
traj1.vee | Demonstrates the differences between the Detail and Panel Views in a program that calculates trajectory.
traj2.vee | Demonstrates the Show Panel on Execute mode for UserObjects to display data as requested.
xfftfunc.vee | Performs FFT on a waveform using the ScaleFFT UserFunction.


Electrical Applications
examples\Applications

Electrical Application Examples
Example Name | Description
digfilt.vee | Illustrates the following: Unbuilding and building time-domain waveforms. Construction of a 3rd order elliptical digital filter. Automatic conversion from the time domain to the frequency domain.
telecomm.vee | Simulates a DS1 Pulse Template test using previously stored waveform data. A common measurement in the telecommunications field monitors the pulse shape from a DS1 test fixture. This program illustrates how to automate the waveform template matching to a measured DS1 pulse.
lissajou.vee | Demonstrates lissajous pattern generation using two waveform inputs to an X vs Y Plot display object.
pid.vee | Shows a simple Proportional-Integral-Derivative controller for closed-loop process control.


Dynamic I/O Configuration
examples\InstrumentIO

Dynamic I/O Configuration Examples
Example Name | Description
DynamicFindDMM.vee | Can find either the first digital multimeter or all DMMs on your system.
DynamicFindInstruments.vee | Finds all GPIB and VXI instruments on your system, and returns their model names and bus addresses. The instruments must be IEEE 488.2 compliant and must understand the "IDN?" command.
DynamicFindInterfaces.vee | Reports the type and logical unit number of all instrument interfaces on your system.
DynamicFindRemoteInstruments.vee | Finds all instruments available on the specified remote host. The remote host must have Agilent VEE installed for remote discovery to work.
PreRunDeviceCheck.vee | Demonstrates some of the instrument configuration checking features available during VEE's pre-run phase.


Financial Applications
examples\Applications

Financial Examples
Example Names | Description
simp_npv.vee | Demonstrates financial calculations using a simple Net Present Value model with no provision for effect of taxes.
payback.vee | Demonstrates financial calculations using a simple Net Present Value "Discounted Payback Period" model with some provision for the effect of taxes.
futValue.vee | Demonstrates financial capabilities of VEE, and shows the future value growth of a principal amount, through graphical curve plotting.


Games
examples\Games

These examples are complete programs that demonstrate a variety of VEE programming techniques.

Game Examples

Example Name

Battleship

BlackJack

Euchre

MineSweeper

Movies

Race

Reversi

Slots

Solitaire

StraVEEgo

Wheel


Instrument I/O

Instrument Measurements
examples\InstrumentIO

Instrument Measurement Examples
Example Name | Description
4195imp.vee | Measures the impedance characteristics of a chip type component.
4195net.vee | Is a setup to study the transmission frequency response of a bandpass filter.
4195s11.vee | Measures the Return Loss of a device under test.
4195s12.vee | Measures the Reverse Transmission Coefficients of a device under test.
4195s21.vee | Measures the Forward Transmission Coefficients of a device under test.
4195s22.vee | Measures the Reverse Reflection Coefficients of a device under test.
4195spec.vee | Studies the Harmonic Distortion of a frequency signal with the following parameters: Sweep Start frequency: 5 MHz Sweep Stop frequency: 105 MHz R1 input attenuation: 40 dB S1 source amplitude: -15 dB
4338_ext.vee | Shows how to control the HP 4338A external trigger, and use the instrument drivers sequence output to perform an SRQ and SPOLL, then log readings from the HP 4338A component driver.
8720cal.vee | Shows how the calibration data for an HP 8720C can be stored in a file after the calibration and later on it can be retrieved from the file to dump the cal data to the instrument.
8720lims.vee | Shows the limit segments editing using the HP 8720C and performs the limit line testing on the measured characteristics of the test device.
8720smp1.vee | Performs a phase measurement to study the deviation from linear phase.
8720smp2.vee | Performs phase measurement using an HP 8720C, and the phase value is detected for the selected stimulus frequency. In the second state, Z:Transmission characteristics measurement is done.
8753lims.vee | Shows the limit segments editing using the HP 8753C and performs the limit line testing on the measured characteristics of the test device.
BpTr_STR.vee | Demonstrates stress measurement on a bipolar transistor.
DIOFreq.vee | Finds the frequency response of the HP 3478 multimeter using Direct I/O objects. Needs a HP 3325B function generator and a HP 3478 multimeter.
enum_id.vee | Shows how to use a Selection Control object (Enum) to generate an input for an ID device that uses numbers to select internal states.
hpe1326.vee | Takes readings from the HP E1326. After a delay to take the readings, the readings are uploaded to a file.
hpe1413.vee | Uploads HP E1413 data to a file and then displays the data.
hpe1488a.vee | Takes readings on the HP E1431A, transfers them over the local bus to the HP E1488A, then reads the data over the GPIB to display it on a Waveform display.
hpe1562.vee | Readings are taken on the HP E1413 and transferred directly to the HP E1562 from the HP E1413 FIFO via the VME backplane. Then the readings are read from the HP E1562 and sent by Local Bus to the HP E1488A.
gpibtest.vee | This utility allows you to perform simple GPIB transactions with an instrument.
IC_IB_VB.vee | Displays the hFE values corresponding to IC>1mA and IC<4mA. This is a good example of transistor characteristics and hFE calculation based on the above results.
IC_VCE.vee | Is an example of IC vs VCE characteristics of bipolar transistor.
ID_VDS1.vee | Is a good example of ID-VGS characteristics of MOSFET. It also gives information about Vth@ID=10mA and Vth@MAX(Gm)
ID_VDS2.vee | Is an example of ID vs VGS of MOSFET.
IDfreq.vee | Finds the frequency response of the HP 3478 multimeter using HP Instrument Drivers(HP-ID). Needs a HP 3325B function generator and a HP 3478 multimeter.
cap4291.vee | Can be used for studying: Frequency characteristics of impedance OSC level characteristics of capacitance and dissipation factor Frequency characteristics of capacitance and dissipation factor DC bias voltage characteristics of capacitance and dissipation factor
imp4291.vee | Does Resistance and Reactance Measurement over the frequency sweep from 1000KHz to 1800 MHz.
instr.vee | Shows three methods in VEE for programming instruments.
k2000.vee | Tests the operation of the Keithley 2000 Digital Multimeter.
k2000_dc.vee | Is an example using the Keithley 2000 voltmeter. 100 DCV readings are taken and shown on an XY Trace.
k2001.vee | Tests the operation of the Keithley 2001 Digital Multimeter.
k2001_dc.vee | Sets up the Keithley 2001 to take DC readings using the .01 NPLC Aperture. 100 readings are taken and averaged. Both the average and a plot of the values are shown.
logger1.vee | Shows how to construct a simple multi-channel data logger.
logger2.vee | Shows a data logger that saves measurement data to a file.
loss4291.vee | Can be used for measuring frequency characteristics of relative Permittivity. Channel 1 measures Permittivity real(Er') and channel 2 measures Loss tangent(tan delta).
perm1_91.vee | Is a program for the HP 4291A that measures permeability real for channel 1 measures permeability loss factor for channel 2.
perm2_91.vee | Is used for measuring: Frequency characteristics of relative Permeability OSC level characteristics of relative Permeability DC bias current characteristics of relative Permeability
prmtty_91.vee | Is a program for the HP 4291A that measures permittivity real for channel 1 measures permittivity loss factor for channel 2.
rd126014.vee | Writes the data of "Data Buffer" to port 1 of the Racal Dana 1260-14 and reads it from port 0.
scopeMask.vee | Displays a DS1 mask in the waveform memories of an HP 54502 or HP 54504 oscilloscope. This demonstrates the concept of creating a mask in a scope's waveform memories. Although it builds something that looks like a DS1 mask, the data from which the mask is built does not conform to any standard.
smallsig.vee | Measures small signal gain. This measurement is useful for the study of characteristics of active devices like amplifiers in the linear operating region. This program doesn't include the calibration measurement.
Vdownld.vee | Downloads drivers to the VXI Command Module.


IVI Driver Example

EPM_Averages_IVI_COM.vee

EPM_Cal_and_Zero_IVI_COM.vee

EPM_Offset_Measurements_IVI_COM.vee

IVIAgilentSA.vee


Manufacturing Applications
examples\Applications

Manufacturing Examples

Example Name

Description

mfgtest.vee

introduces some VEE features that you may find useful as you try to build a manufacturing test system. Several VEE features are highlighted, including:

Dialog boxes:
There are several different types of dialog boxes that this example uses. The "login" function makes the heaviest use of them. They are found under the Data [image] Dialog Box menu.

Keyboard drivability:
You may completely control this program by using the Tab key, space bar, and Enter keys in the dialog boxes. Also, there is a custom dialog that allows you to navigate by pressing a function key.

Indicators:
We use several display objects, such as a Color Alarm and Thermometer, to indicate pass or fail conditions in a running test. Indicators are found under the Display [image] Indicator menu.

Picture object:
This object lets you display graphics in a scaleable object. We have used it to display a test connection diagram. It accepts graphics files in Graphics Interchange Format (GIF), Bitmap (BMP), and X Window Dump (XWD) formats. This object is found under the Display menu.

Sequencer status panels:
We have a generic function whose Panel View can be programmatically displayed or hidden. We use this to give a dynamic view of tests as the Sequencer runs.

Sequencer:
The Sequencer has a data pin named ExecTrans that takes an array of test names to execute. By using a multiple-selection list box (one of the Dialog Box objects), you can allow the user of your program to dynamically choose which tests the Sequencer should run.


MATLAB

MATLAB Script
examples\MATLAB

MATLAB Script Examples
Example Name | Description
BasicGraphManipulation.vee | Shows some basic graph and plot manipulation.
FindMaximums.vee | Shows how to locate and highlight graph peaks
Interpolation.vee | Shows the MATLAB Interpl 1D data interpolation function.
Logo3DPlot.vee | Makes an attractive 3D shaded surface plot.
MultiGraphFigure.vee | Shows how to create and display subplots.
MultiTraceGraph.vee | Shows how to plot and color multiple graph traces.
Plot2DArray.vee | Shows how to plot 2D array data from VEE.
SignalProcessing.vee | Introduces the extensive Signal Processing capabilities of MATLAB.
Surf3DPlot.vee | Shows how to create and rotate a MATLAB 3D shaded surface plot.


Mechanical Applications
examples\Applications

Mechanical Examples

Example Names

Description

beam.vee

Demonstrates the use of VEE in a cantilever beam deflection problem. This program uses an XY Trace display to show the deflection of a beam under uniform, ramp, and combined load situations.

chaos.vee

Shows the steady-state value of a simple population model.

coilspr.vee

Demonstrates the calculation of the natural frequency for a coil spring using a number of variable parameters.

convcoef.vee

Demonstrates the use of VEE with a Natural Convection Heat Transfer Model that calculates the heat transfer coefficient, "h", for several body or surface types.

fluidflw.vee

Shows a simple Mechanical Engineering problem setup and solution. It also shows methods of data entry and display, and the use of arrays and global variables for calculating formulas.

torsion1.vee

Shows a simple mechanical engineering problem and solution. It also shows basic data entry and display, as well as the use of a calculation formula.

The program uses a simple formula to calculate the angular deflection of a round torsion shaft, given specified diameter, length, applied torque, and material shear modulus values.

torsion2.vee

Shows a mechanical engineering problem setup and solution. It shows various data entry and display methods, and the use of a calculation formula.

The program uses a simple formula to calculate the angular deflection of a round torsion shaft, given a range of diameters, length, a range for applied torque, and material shear modulus values.


Microsoft Access
examples\ActiveXAutomation

The applications and related ActiveX automation type libraries referenced here must be installed on your system before the programs will run properly.

Microsoft Access Interaction Examples
Example Name | Description
AccessDataClient.vee | Launches Access and stores the test data and the VEE record data into the database file testData.mdb, and then reads it.
AccessEnumerate.vee | Opens the DAO 3.6 (ACCESS) database named testData.mdb, then enumerates (displays all) tables in the database. Next, all fields in the resultsTable are enumerated. This demonstates that DAO is installed, how to open a database and recordset, use the count and name properties, etc. Note that several "MSys" tables are created by the DAO engine.


Microsoft Excel
examples\ActiveXAutomation

The applications and related ActiveX automation type libraries referenced here must be installed on your system before the programs will run properly.

Microsoft Excel Interaction Examples
Example Names | Description
Excela.exe | Uses Excel and ActiveX automation to insert random data into a spreadsheet one cell at a time. It then uses Excel's Average function to calculate the average of the data inserted into Excel.
Excelb.vee | Uses Excel and ActiveX Automation to insert an array of random data into a spreadsheet in one operation. It then uses Excel's StDev function to calculate the standard deviation of the data inserted into Excel.
ExcelGraph.vee | Uses Excel and ActiveX Automation to insert data into a spreadsheet. It then instructs Excel to create a new Chart and formats the Chart appropriately.
ExcelWeather.vee | Uses Excel and ActiveX Automation to calculate the weather report.

Calling VEE from Excel

SpreadsheetApp.xls is an Excel file that calls VEE functions in lib.vee. One function synthesizes a pulse from data read from a file; the other function displays the pulse with test limits. To open an example, use the Windows Explorer and double-click this file:

<VEE_install_dir>\examples\CallableVEE\Excel\SpreadsheetApp.xls


Microsoft Outlook
examples\ActiveXAutomation

The applications and related ActiveX automation type libraries referenced here must be installed on your system before the programs will run properly.

Microsoft Outlook Example
Example Names | Description
Outlook.vee | Sends e-mail using the ActiveX Automation capability of VEE and Microsoft Outlook.


Microsoft Word
examples\ActiveXAutomation

The applications and related ActiveX automation type libraries referenced here must be installed on your system before the programs will run properly.

ActiveX Automation Examples
Example Name | Description
Word.vee | Uses Word and ActiveX Automation to insert test data and a bitmap of a VEE UserFunction into a Word document.
WordDataSheet.vee | Performs ActiveX Automation search and replace in a Word document used as a template for a single page datasheet.
WordMailMerge.vee | Uses ActiveX Automation to perform mail merge in a Word document named mmerge.doc, using the database file mmerger.mdb.


Callable VEE

Old VEE RPC API
examples\CallableVEE\Rpc_api

Old VEE RPC Example
Example Name | Description
lib.vee | Is a VEE library which contains several callable functions, including the DS1 pulse test functions.

DS1 Pulse Test

CallVEE.c is a C source file that calls two VEE functions in lib.vee. One synthesizes a pulse from data read from a file. The other displays the pulse with test limits.

The preferred method of calling VEE 6.0 and above is the Callable VEE ActiveX Automation Server. However, the original C API still works. You might choose the old method if you are working in K&R C (rather than C++).

To open an example, use the Windows Explorer and double-click this file:

<VEE_install_dir>\examples\CallableVEE\Rpc_api\CallVEE.c


Lib

VEE Lib Examples
examples\Lib

There is \lib directory in VEE's install directory. It contains various functions and objects that may be useful in your VEE programs. You can import these objects by using File [image] Merge. The following examples show these library objects being used in complete programs.

Lib Examples
Example Names | Description
1dto2d.vee | Illustrates use of the Formula object and Array building syntax to construct a 2D array from a larger 1D input array when the array sizes are fixed.
2dto1d.vee | Illustrates use of the MatToAry.vee library object for "flattening" multiple dimensioned arrays into a 1D array.
barcht1.vee | Illustrates use of the BarChart.vee library object to display an array of data.
barcht2.vee | Illustrates use of the BarPF.vee library object to display an array of data by comparing each element to a fixed limit.
barcht3.vee | Illustrates use of the BarStack.vee library object to display two arrays of data simultaneously
barcht4.vee | Illustrates use of the BarComp.vee library object to display two arrays of data simultaneously.
dialog.vee | Illustrates use of the dialog library object for requesting user input at a specific point in your program. This program is a starting point for more complicated dialog boxes; for simple dialog boxes, use the Dialog Box objects built into VEE on the Data menu.
keypad.vee | Illustrates the use of the keypad.vee library object.
maparray.vee | Illustrates use of the mapArray.vee library object to build an array of numbers corresponding to each element of a Spectrum or Waveform input.
multiplex.vee | Demonstrates use of a Formula object as a Multiplexer object.
pathsep.vee | Illustrates use of the pathSep.vee library object to normalize the path separator character for both DOS and posix path names.
piechart.vee | Illustrates use of the PieChart.vee library object to display an array of data.
rmfile.vee | Demonstrates the use of the rmfile.vee library object.
SMTPMail.vee | Is a library object that demonstrates the use of the To/From Socket object to implement send-only Simple Mail Transfer Protocol (SMTP) functionality.
xy_cntrl.vee | Shows how to adjust traces and scales on an XY Trace display, using the Record Constant objects Traces Control and Scales Control. These controls are in the XY_cntrl.vee library object. To control only one scale or trace, open the Properties dialog box for the Traces Control or Scales Control, then set Array Size to 0 on the General tab


Concepts

VEE Programming Concepts
examples\Concepts

VEE Programming Examples
Example Name | Description
AdvancedDialog.vee | Shows how to create a dialog box that takes initial parameters, validates user input, and returns the information the user entered.
ascii.vee | Illustrates how to convert a keyboard character to its ASCII code, and how to convert an ASCII code to a character.
convert.vee | Shows how easily VEE handles different types of data including DECIMAL, HEXADECIMAL, OCTAL, and BINARY.
complex.vee | Illustrates generating, adding, processing, and displaying Complex and Polar Complex numbers.
datacomp.vee | Compresses new data by checking for a change and recording only the changes with a time stamp.
feedback.vee | Illustrates feedback and how it can be used to implement a simple one-pole IIR digital filter.
fib.vee | Illustrates using feedback to model an equation such as the Fibonacci sequence: a(n) = a(n-1) + a(n-2).
if.vee | Illustrates the use of the If/Then/Else object to output a value.
infoAbout.vee | Describes the pop-up help device used in many of these program examples.
integrate.vee | Shows how to integrate functions with upper and lower bounds that are entered into a dialog box, then graphically display the integration results.
layout1.vee | Demonstrates how laying out a VEE program using left to right data flow helps the programs readability.
layout2.vee | Demonstrates the effect of aligning and sizing objects on a programs layout.
loop.vee | Generates a series of random integers, each between 1 and 10, and finds out how many of them sum up to be less than or equal to 100.
magphase.vee | Illustrates a simple method of displaying the Magnitude and Phase vs. Frequency from a time-domain waveform. Note that the Mag/Phase Display in the program is a UserObject and not a supplied display object.
oneshot.vee | Illustrates the use of a Toggle Button to create a One-Shot Button.
opt1.vee | Uses Parallel Math to operate on arrays of data.
opt2.vee | Reads a two-dimensional array of data from a file.
opt3.vee | Compares how Formula objects in two threads evaluate expressions allowing Sieve to run faster or slower.
redim.vee | Shows how to change the dimensions of an array.
scattrgm.vee | Illustrates a method of plotting scattergrams using the X vs Y display.
strings.vee | Demonstrates use of the built-in String functions available in the Function & Object Browser (on the Device [image] Function & Object Browser menu).
text1.vee | Illustrates several ways to combine text strings.
timetick.vee | Uses the On Cycle object (on Flow [image] Repeat menu) to generate a 1-second Time-Of-Day clock.
tofrom1.vee | Illustrates how to save data between successive executions of a program by writing the latest data to a file after reading and modifying data previously written to the same file.
tofrom2.vee | Illustrates how one thread writes to a file and a second thread reads the data and processes it at its own speed.
tofrom3.vee | Shows how to use the Selection Control objects such as Radio Buttons (on the Data [image] Selection Control menu), and the WRITE CASE I/O transaction together. Use this technique to map easily-understood strings into corresponding output strings.
tofrom4.vee | Illustrates how to use transaction I/O to write VEE waveforms. This program combines some of the concepts of data type conversion and transaction I/O. The To String object is used for convenience in viewing results. You may substitute a To File object with the same transactions for any To String.
tr_ctrl.vee | Shows how to use the Traces control input pin to a Strip Chart display. The control pin changes the line color from green to red, depending on the value of the data.
truefals.vee | Shows three ways to generate TRUE and FALSE text strings from a number.
whichos.vee | Demonstrates how to read the computers operating system and platform using the whichOS() and whichPlatform() functions.
wizbang.vee | Demonstrates the use of Alarms, Indicators, and Controls.
zerofill.vee | Illustrates several methods of extending an array by zero filling to a prescribed length. Use of math functions within the Formula object is illustrated, as is use of Allocate Array and ramp to generate fixed arrays.


Visual Basic
examples\CallableVEE\VisualBasic

DS1 Pulse Test

CallVEE.vbp is a Visual Basic project. The program calls two VEE functions in lib.vee. One synthesizes a pulse from data read from a file. The other displays the pulse with test limits. If Microsoft Visual Basic is installed on your system, you can open an example by double-clicking this file in the Windows Explorer.

<VEE_install_dir>\examples\CallableVEE\VisualBasic\CallVEE.vbp


Visual Basic Script

VB Script
examples\CallableVEE\VBScript

If Microsoft VB Script is available on your system, you can run these examples by double-clicking them in the Windows Explorer.

DS1 Pulse Test

CallVEE.vbs is a VB Script file that calls two VEE functions in lib.vee. One synthesizes a pulse from data read from a file. The other displays the pulse with test limits.

<VEE_install_dir>\examples\CallableVEE\VBScript\CallVEE.vbs

Getting Callable VEE Server Information

GetServerInfo.vbs is a VB Script file that returns information about the registered Callable VEE Server, for example, the I/O configuration file being used by the host.

<VEE_install_dir>\examples\CallableVEE\VBScript\GetServerInfo.vbs

Create and Display a Waveform

GetWaveform.vbs is a VB Script file that uses one of VEE's unique data types. It shows how to create, pass, and return Waveform data.

<VEE_install_dir>\examples\CallableVEE\VBScript\GetWaveform.vbs

Finding and Loading a VEE Library

UsingInstallDir.vbs is a VB Script file that discovers VEE's install directory, then loads and calls a VEE library relative to that directory.

<VEE_install_dir>\examples\CallableVEE\VBScript\UsingInstallDir.vbs


Visual C++
examples\CallableVEE\VisualC++

DS1 Pulse Test

CallVEE.cpp is a Visual C++ file that calls two VEE functions in lib.vee. One synthesizes a pulse from data read from a file. The other displays the pulse with test limits. If Microsoft Visual C++ is installed on your system, you can open an example by double-clicking this file in the Windows Explorer.

<VEE_install_dir>\examples\CallableVEE\VisualC++\CallVEE.cpp


ASCII Table

The following table lists the ASCII 7-bit character codes:

     | Binary |Octal|Hex| Dec |GPIB Msg

-----|--------|-----|----|----|----------

NUL | 0000000 | 000 | 00 | 0 |

SOH | 0000001 | 001 | 01 | 1 | GTL

STX | 0000010 | 002 | 02 | 2 |

ETX | 0000011 | 003 | 03 | 3 |

EOT | 0000100 | 004 | 04 | 4 | SDC

ENQ | 0000101 | 005 | 05 | 5 | PPC

ACK | 0000110 | 006 | 06 | 6 |

BEL | 0000111 | 007 | 07 | 7 |

BS | 0001000 | 010 | 08 | 8 | GET

HT | 0001001 | 011 | 09 | 9 | TCT

LF | 0001010 | 012 | 0A | 10 |

VT | 0001011 | 013 | 0B | 11 |

FF | 0001100 | 014 | 0C | 12 |

CR | 0001101 | 015 | 0D | 13 |

SO | 0001110 | 016 | 0E | 14 |

SI | 0001111 | 017 | 0F | 15 |

DLE | 0010000 | 020 | 10 | 16 |

DC1 | 0010001 | 021 | 11 | 17 | LLO

DC2 | 0010010 | 022 | 12 | 18 |

DC3 | 0010011 | 023 | 13 | 19 |

DC4 | 0010100 | 024 | 14 | 20 | DCL

NAK | 0010101 | 025 | 15 | 21 | PPU

SYN | 0010110 | 026 | 16 | 22 |

ETB | 0010111 | 027 | 17 | 23 |

CAN | 0011000 | 030 | 18 | 24 | SPE

EM | 0011001 | 031 | 19 | 25 | SPD

SUB | 0011010 | 032 | 1A | 26 |

ESC | 0011011 | 033 | 1B | 27 |

FS | 0011100 | 034 | 1C | 28 |

GS | 0011101 | 035 | 1D | 29 |

RS | 0011110 | 036 | 1E | 30 |

US | 0011111 | 037 | 1F | 31 |

space| 0100000 | 040 | 20 | 32 | listen 0

! | 0100001 | 041 | 21 | 33 | listen 1

" | 0100010 | 042 | 22 | 34 | listen 2

# | 0100011 | 043 | 23 | 35 | listen 3

$ | 0100100 | 044 | 24 | 36 | listen 4

% | 0100101 | 045 | 25 | 37 | listen 5

& | 0100110 | 046 | 26 | 38 | listen 6

" | 0100111 | 047 | 27 | 39 | listen 7

( | 0101000 | 050 | 28 | 40 | listen 8

) | 0101001 | 051 | 29 | 41 | listen 9

* | 0101010 | 052 | 2A | 42 | listen 10

+ | 0101011 | 053 | 2B | 43 | listen 11

, | 0101100 | 054 | 2C | 44 | listen 12

- | 0101101 | 055 | 2D | 45 | listen 13

. | 0101110 | 056 | 2E | 46 | listen 14

/ | 0101111 | 057 | 2F | 47 | listen 15

0 | 0110000 | 060 | 30 | 48 | listen 16

1 | 0110001 | 061 | 31 | 49 | listen 17

2 | 0110010 | 062 | 32 | 50 | listen 18

3 | 0110011 | 063 | 33 | 51 | listen 19

4 | 0110100 | 064 | 34 | 52 | listen 20

5 | 0110101 | 065 | 35 | 53 | listen 21

6 | 0110110 | 066 | 36 | 54 | listen 22

7 | 0110111 | 067 | 37 | 55 | listen 23

8 | 0111000 | 070 | 38 | 56 | listen 24

9 | 0111001 | 071 | 39 | 57 | listen 25

: | 0111010 | 072 | 3A | 58 | listen 26

; | 0111011 | 073 | 3B | 59 | listen 27

< | 0111100 | 074 | 3C | 60 | listen 28

= | 0111101 | 075 | 3D | 61 | listen 29

> | 0111110 | 076 | 3E | 62 | listen 30

? | 0111111 | 077 | 3F | 63 | UNL

@ | 1000000 | 100 | 40 | 64 | talk 0

A | 1000001 | 101 | 41 | 65 | talk 1

B | 1000010 | 102 | 42 | 66 | talk 2

C | 1000011 | 103 | 43 | 67 | talk 3

D | 1000100 | 104 | 44 | 68 | talk 4

E | 1000101 | 105 | 45 | 69 | talk 5

F | 1000110 | 106 | 46 | 70 | talk 6

G | 1000111 | 107 | 47 | 71 | talk 7

H | 1001000 | 110 | 48 | 72 | talk 8

I | 1001001 | 111 | 49 | 73 | talk 9

J | 1001010 | 112 | 4A | 74 | talk 10

K | 1001011 | 113 | 4B | 75 | talk 11

L | 1001100 | 114 | 4C | 76 | talk 12

M | 1001101 | 115 | 4D | 77 | talk 13

N | 1001110 | 116 | 4E | 78 | talk 14

O | 1001111 | 117 | 4F | 79 | talk 15

P | 1010000 | 120 | 50 | 80 | talk 16

Q | 1010001 | 121 | 51 | 81 | talk 17

R | 1010010 | 122 | 52 | 82 | talk 18

S | 1010011 | 123 | 53 | 83 | talk 19

T | 1010100 | 124 | 54 | 84 | talk 20

U | 1010101 | 125 | 55 | 85 | talk 21

V | 1010110 | 126 | 56 | 86 | talk 22

W | 1010111 | 127 | 57 | 87 | talk 23

X | 1011000 | 130 | 58 | 88 | talk 24

Y | 1011001 | 131 | 59 | 89 | talk 25

Z | 1011010 | 132 | 5A | 90 | talk 26

[ | 1011011 | 133 | 5B | 91 | talk 27

\ | 1011100 | 134 | 5C | 92 | talk 28

] | 1011101 | 135 | 5D | 93 | talk 29

^ | 1011110 | 136 | 5E | 94 | talk 30

_ | 1011111 | 137 | 5F | 95 | UNT

` | 1100000 | 140 | 60 | 96 | second 0

a | 1100001 | 141 | 61 | 97 | second 1

b | 1100010 | 142 | 62 | 98 | second 2

c | 1100011 | 143 | 63 | 99 | second 3

d | 1100100 | 144 | 64 | 100 | second 4

e | 1100101 | 145 | 65 | 101 | second 5

f | 1100110 | 146 | 66 | 102 | second 6

g | 1100111 | 147 | 67 | 103 | second 7

h | 1101000 | 150 | 68 | 104 | second 8

i | 1101001 | 151 | 69 | 105 | second 9

j | 1101010 | 152 | 6A | 106 | second 10

k | 1101011 | 153 | 6B | 107 | second 11

l | 1101100 | 154 | 6C | 108 | second 12

m | 1101101 | 155 | 6D | 109 | second 13

n | 1101110 | 156 | 6E | 110 | second 14

o | 1101111 | 157 | 6F | 111 | second 15

p | 1110000 | 160 | 70 | 112 | second 16

q | 1110001 | 161 | 71 | 113 | second 17

r | 1110010 | 162 | 72 | 114 | second 18

s | 1110011 | 163 | 73 | 115 | second 19

t | 1110100 | 164 | 74 | 116 | second 20

u | 1110101 | 165 | 75 | 117 | second 21

v | 1110110 | 166 | 76 | 118 | second 22

w | 1110111 | 167 | 77 | 119 | second 23

x | 1111000 | 170 | 78 | 120 | second 24

y | 1111001 | 171 | 79 | 121 | second 25

z | 1111010 | 172 | 7A | 122 | second 26

{ | 1111011 | 173 | 7B | 123 | second 27

| | 1111100 | 174 | 7C | 124 | second 28

} | 1111101 | 175 | 7D | 125 | second 29

~ | 1111110 | 176 | 7E | 126 | second 30

[del]| 1111111 | 177 | 7F | 127 |


Error Codes

Use the following list to find the error message that corresponds to the error code output from an error terminal.

OBJECTS

300 The input terminal number <n> is not connected

301 Input <n> is not present
(valid range = [<n>..<n>])

302 No additional inputs are allowed
-- limited to <n>

303 The input must be <type>

304 The input cannot be <type>

305 Input(s) mismatch: <name>, <name>

306 Required input <name> is not present

308 Required output <name> is not present

309 Output(s) mismatch: <name>, <name>

310 Output <n> is not present
(valid range = [<n>..<n>])

311 No additional outputs are allowed
-- limited to <n>

312 No <type> was selected

313 <operation> is not supported

314 Invalid combination of parameters: <n>

315 Component <name> cannot be added

317 There is no panel to switch to

318 UserFunction <name> has no panel view

320 Child process failed to run

321 Child process died

322 Could not open the pipe

323 List has no elements

330 The Max value must be greater than the Min value

331 VEE OneLab cannot load or execute this program

340 Cannot compile an object with more than one xeq pin

341 The xeq pin must be the bottom-most data in pin

342 Cannot compile a context object with an xeq pin

343 UserObject cannot reside in its Edit Window

344 CallBox cannot reside in calling function
(recursion is not allowed)

345 Duplicate device name.
Change <name> to be unique.

346 Must specify a Name for the device.

347 Cannot compile a program with error pins on
iterators or junctions

CONTAINERS

400 Value is empty or nil
(could be zero-element array)

401 Value out of bounds
(valid range = [<n>..<n>])

402 <name> value must be <type>

403 <name> value is out of range

404 Numeric value must be positive

405 <name> was not found

410 Value must be a scalar

411 Value must be an array

412 Value must be a scalar or linear array

413 Value must be a <n> dimensional array

414 Value must be a waveform or linear array

415 Values must have same number of dimensions

416 Values must have same size and shape

417 Record structures must match

418 Records cannot be merged

420 Value must be a square matrix

421 Shapes of matrix values are inappropriate for
matrix multiply

422 Value must be a matrix with an ODD number of columns

430 Scalar cannot be accessed by a non-zero index

431 Value for an array index is out of range

432 Values for array/subarray indices are inappropriate

433 Too many array dimensions given
(maximum = <n>)

434 Value must have <n> field(s)

435 Both values must have the same number of fields

440 Invalid operation for data type <type>

441 Invalid operation for scalar value

442 Invalid operation for a <n> dimensional array

443 Operation valid only for numeric values

444 Invalid assignment of Declared Variable

445 Attempted access to Declared Variable <name>
which has not yet been initialized

450 Operation requires that array be mapped

451 Array mappings for values must match

452 Sample frequency for array mappings must match

453 <type> cannot have vertical steps

454 Construction of an array is not allowed

460 Cannot increment/decrement arrays and functions

461 Value is > 16 digits -- cannot increment/decrement

462 Attempt to overwrite constant or parameter <name> failed

463 Input coordinates are not monotonic over "X"

464 Unable to convert <type> to <type>

465 <action> is not allowed <message>

MATH

500 Illegal values for argument(s) in function <name>

501 Function <name> does not allow negative values

502 Function <name> requires <n> argument

510 Math error in function <name>

511 Division/Modulo by zero

512 Negative value cannot be raised to a
non-integer power (<n>)

513 Zero cannot be raised to a non-positive power (<n>)

514 Numeric data overflow in function <name>

515 Numeric data underflow in function <name>

516 Overflow of sum occurred during calculation of <name>

517 Function or UserFunction: '<name>' is unknown

520 Bounds for LOG mapping must be > 0

521 X-data for LOG mapped function must be > 0

522 Derivatives of order <n> are not supported

523 Interpolation on multi-dimensional arrays is not supported

ActiveX

550 ActiveX object <name> failed

551 An ActiveX object returned incompatible data type <name>

552 <name> in the referenced ActiveX object failed

553 An ActiveX object returned an error
during <action> <name>

554 <name> is not a member of the referenced ActiveX object

555 Attempt to Set property <name> without specifying a value

556 ActiveX object does not implement the interface <name>

557 ActiveX object could not be created

558 The target operating system platform for <name>
is not WIN32

559 Could not load type library from <name>

560 The Property <name> was not found

561 There isn't any type information loaded for <name>

562 Invalid CLSID: <number>

563 Invalid ProgID: <name>

564 Could not establish event connection to <name>

565 Cannot access ActiveX Object <name>

566 An ActiveX object returned an incompatible value

567 Could not get instance of ActiveX object <name>

568 Programmatic access to VEE object property failed

569 ActiveX Automation array error

570 Cannot access data in ActiveX Automation array

571 Cannot create remote objects. DCOM is not installed.
Download and install DCOM95 from the Microsoft web site

MATLAB Script

590 MATLAB not installed. Reinstall VEE and
select the MATLAB Script install option.

591 Could not start the MATLAB Script engine

592 Generic MATLAB error <message>

593 Error in MATLAB Script

594 MATLAB data contains infinity or NaN

EXPRESSIONS

600 Syntax error: <description>

601 Invalid expression: <description>

602 Function was not found: <name>

603 Variable was not found: <name>

604 Function was not loadable: <name>

610 Too many arguments supplied (maximum=<n>)

611 Wrong number of parameters supplied to function <name>

620 Name or string constant is too long (> n chars)

621 Duplicate symbol name <name>

622 Invalid variable/terminal name <name>

623 Closing quote for the string was not found

624 Illegal character(s) found while parsing string

625 Illegal escape sequence <sequence>

626 Duplicate record field name <name>

627 Duplicate library name <name>

628 Invalid record field name <name>

629 Invalid UserFunction name <name>

630 Invalid value

631 Value of the expression must be either all zero
or all non-zero

640 Mismatch error: Expected <name>, got <name>

641 Unknown parameter: <name>

642 Undefined parameter: <name>

643 This program has no execution window

650 Library: <name> contains running functions. Cannot delete

660 Invalid name: <name>

FILES

700 File <name> was not found

701 End of file or no data found

702 Cannot open file <name>: Permission denied

703 Cannot read file <name>

704 Cannot write to file <name>

705 Read error on file <name>

706 End of file or no match found

707 Needed to read <n>, found only <m>

708 Bytes read must be multiple of data size

710 File <name> is not a named pipe

711 Cannot create file <name>

712 File <name> already exists

713 Invalid directory name <name> in path

714 File is a directory

715 Directory is not empty

716 Cannot execute file <name>

717 Invalid working directory <name>

718 Could not create process.
(Windows error number: <n>)

720 File is in use

721 Device is Busy

722 Cannot access a different file system

723 Too many files are open

724 File is too large

725 Disk is full

726 Error during 'seek' of file

727 Bad system file number

728 Too many symbolic links

729 File format is invalid

730 No UserFunctions found in file

731 Sorry, cannot load from file

732 Sorry, cannot save to file

733 Cannot merge secured program

734 Could not create a shared memory segment

735 Sorry, cannot save program

736 Cannot read binary file <name>

737 Cannot write to binary file <name>

738 Could not recover from parsing error

739 Stack pointer corrupted after return from
compiled function

.NET

751 .NET invocation failure.

752 Exception

753 No default member

754 Cannot access .NET

755 No property put value

756 Object could not be created

757 Could not get member information

758 Could not get VEE to .NET

759 Could not get Namespace

760 Type not found

761 Event connect failed

I/O

800 No such device or incorrect address

801 Configuration error: <description>

802 Incorrect special device file <name> found

803 Device, <name>, is not message based

804 Invalid access to memory on device, <name>

810 Instrument driver error <n>: <description>
Refer to your instrument manual for further information

811 I/O error or timeout occurred

812 Invalid bin block header

813 Must be the active system controller to access GPIB

814 Lock acquisition failed on <device> <interface>

815 Error returned from VXIplug&play function call,
error value <n>

816 Error returned from VXIplug&play init() function call,
error value <n>

821 Transaction not supported for <name> interface

830 Could not initiate DDE link to
application <name>, topic <name>

831 DDE POKE to item <name> failed

832 DDE REQUEST from item <name> failed

833 DDE EXECUTE failed

850 Host, <name>, is unknown

851 There is no Service Manager on host, <name>

852 Networking is not initialized on this host

853 Connection has timed out

854 An interrupt occurred before receive on network

855 The connection has been shut down by the peer

856 The operating system is out off buffer space

857 The network is down

858 An interrupt occurred before the connection
to the host <name>

859 The port, <name>, is already in use

860 Attempted connection to <name> has timed out

861 Service Manager on <name> has not responded

862 Service, <name>, on host, <name>, has not responded

863 Service, <name>, not found on host, <name>

864 Service, <name>, on host, <name>, cannot be started

865 Error in service, <name>, on host, <name>

866 The connection was refused on host, <name>

867 The UserFunction, <name>, in service, <name>,
was not found

868 Permission denied for user, <name>, on host, <name>

869 Remote Service, <name>, on host, <name>,
reports error: <n>

870 Non-blocking receive

871 Remote debug terminated before completion

876 Failure code returned in COM HRESULT

877 Expected parameter <name> to be passed ByRef

878 Invalid value returned from <name>

879 The VEE data container is empty

880 The size of array: <name> must be a multiple of:
field count <n>

SYSTEM

900 Operation is not allowed while the program is running

901 Illegal form of feedback

902 Unexpected BREAK encountered

903 Unexpected CONTINUE encountered

904 Invalid device encountered

905 Incorrect revision "<rev>"
(Expected "<rev>")

906 A Thread with feedback requires a START object

910 Process is out of memory,
save your program IMMEDIATELY

911 Floating-point exception, possible overflow/underflow

912 There are too many system processes

913 Reset or Break encountered

914 Cannot open display

915 The operating system is out of resources

920 Write on a pipe with no process to read it
(signal = <n>)

921 User-defined signal 1 received
(signal = <n>)

922 User-defined signal 2 received
(signal = <n>)

930 Error(s) encountered during PreRun

935 A Junction is required inside of feedback cycles.

936 UserFunction is not reentrant

937 Sample & Hold was not given any data.

938 VEE was unable to compile this part of the program.

939 Cannot push START when thread is
connected to input terminals.

940 Illegal form of feedback

941 T1 must be activated before T2.

950 through 999

See Also

About .NET Errors in VEE


Glossary

This Glossary defines several terms used to name or describe Agilent VEE features.

Activate
ActiveX
Allocate
Array
Asynchronous
Auto Execute
Bitmap
Breakpoint
Buffer
Button
Cascading Menu
Checkbox
Click
Clone
Compiled Function
Component
Component Driver
Composite Data Type
Container
Context
Control Pin
Coupling
Cursor
Cut Buffer
Data Container
Data Field
Data Flow
Data Input Pin
Data Output Pin
DataSet
Data Shape
Data Type
DDE (Dynamic Data Exchange)
Default
Default Button
Demote
Detail View
Device Driver
Dialog Box
Direct I/O Object
DLL (Dynamically Linked Library)
Double-Click
Drag
Driver
Driver Files
Drop-Down List
Entry Field
Error Message
Error Pin
Execute
Execution Flow
Expression
Feedback
Flow
Font
Function
Global Variable
Grayed Feature
Highlight
Host
Hypertext
Icon
Instrument
Instrument Driver
Instrument Panel
Interface
Interface Driver
Iterate
Library
Line
Logical Unit
Loop
Main Menu
Main Work Area
Main Window
Mapping
Maximize
Maximize Button
Menu
Menu Bar
Menu Title
Minimize
Minimize Button
Mouse
Mouse Button
Network
Object
Object Menu
Object Menu Button
Open
Open View
Operate
Operator Interface
Outline Box
Palette
Panel Driver
Panel View
Pin
Pointer
Pop-Up Menu
PostRun
Preferences
PreRun
Program
Program Explorer
Promote
Propagation
Properties
Pterodactyl
Pull-Down Menu
Radio Button
Record
Remote Function
Restore
Run
Save
Scalar
Schema
Screen Dump
Scroll
Scroll Arrow
Scroll Bar
Select
Select Code
Selection
Selection Field
Sequence Input Pin
Sequence Output Pin
Sequencer
Sleep
Startup Directory
State
Status Bar
Status Field
Step
Terminal
Terminal Area
Thread
Title Bar
Toolbar
Transaction
Trig Mode
User-Defined Function
UserFunction
UserObject
Variable
View
Wait
Window
Windows 98
Windows NT
Work Area
Work Space
Working Directory
XEQ Pin


About .NET Errors in VEE

About .NET Errors in Agilent VEE Pro

VEE provides all of the information that .NET passes it. For the most part, a review of the specific .NET method you are using provides you with enough information to determine the nature of the exception. If it does not, you can go straight to the exception type in MSDN.

An example of a verbose exception box where the exception is self-explanatory is:

A less verbose but common error message where the method is the clue is:


Access Array

A menu item.

Use

Use Access Array to access the following array modification objects:

Set Values

Get Values

Set Mappings

Get Mappings

Notes

These objects are usually used after the Allocate Array objects to modify the elements or add mappings to a newly created array.

Location

Data [image] Access Array

See Also

Allocate Array, Get Mappings, Get Values, Set Mappings, and Set Values.

To Extract Values from an Array


Access Record

A menu item.

Use

Use Access Record to access the following record modification objects:

Merge Record

SubRecord

Set Field

Get Field

Notes

These objects are usually used after the Build Record object to modify the elements, merge records or access portions of the record.

Location

Data [image] Access Record

See Also

Build Record, Merge Record, SubRecord, Set Field, and Get Field.

To Change a Field in a Record


Accumulator

An object that displays and outputs a running sum of its input values.

Use

Use Accumulator to keep a running total.

Object Menu

Clear - Clears the contents of the Accumulator.

Note

The type of the accumulated output data is the same as the highest order of the input value. Thus, if the Accumulator is input a Real64 and an Int32, it outputs a Real64.

For example, if the Accumulator data input is activated with a Real64, then later is activated by a Complex, the current accumulated data is Complex; the Accumulator converts the Real64 data to Complex. If one of the inputs is text, all of the data will be converted to text.

Use caution when mixing data types. The order in which they are entered will make a difference in the output. If the inputs are real, real, and text, the Accumulator will add the reals and convert the result to text, then append the input text string to the end of the real string. If the inputs are text, real, and real, the Accumulator will convert the two reals to strings and append them to the end of the text string. Rather than adding the two reals, they will appear as two separate numbers in the accumulated string.

Location

Device [image] Accumulator

See Also

Counter and Properties (Object)


Activate Breakpoints

When checked, enables all set breakpoints. When not checked, disables all breakpoints.

Use

Use Activate Breakpoints to toggle between debugging and normal program running. When Activate Breakpoints is on, the menu selection is checked. When a breakpoint is encountered, the program stops running.

Notes

The orange (by default) border surrounding the objects with set breakpoints is still present, even when Activate Breakpoints is off. The object Properties shows Set Breakpoint as being checked regardless of the state of Activate Breakpoints.

Breakpoints are only active in VEE 4 and higher execution modes if the Disable Debugging Features box in Default Preferences is not checked. When a breakpoint is set on an object, Step Into will break, Step Over will not break.

Location

Debug [image] Activate Breakpoints

See Also

Clear All Breakpoints, Default Preferences, Properties (Object), Step Into, Step Over, and Toggle Breakpoint.


ActiveX Automation References

Displays the ActiveX Automation References dialog box, which lets you make ActiveX automation libraries available for use in VEE.

Use

Use the ActiveX Automation References dialog box to select the ActiveX automation libraries for VEE to use to control other applications. Libraries appear in this dialog box if their associated applications have been installed so the Windows Registry recognizes them. When you select the libraries you want, press OK to load them into memory for use in VEE, and to search for their object classes, dispatch interfaces, and exported events. You must select type libraries only if you plan to handle events generated by them, or if you want to reference any type libraries so their functionality (properties, methods, enumerations, events) will appear in the Function & Object Browser.

Before referencing type libraries, use the built-in functions CreateObject() or GetObject() to connect with an automation object. Then, after selecting libraries, open VEE’s Function & Object Browser (Device [image] Function & Object Browser) and select ActiveX Objects in the Type: area to generate expressions in Formula objects that manipulate the objects. Use additional Formula expressions to get and set their properties, and call methods.

Dialog Information

Registered Automation Servers: - Contains the list of registered ActiveX automation libraries. Click on a name to highlight it and see information in the status area below the list. Click in the box beside a name, and click OK to select it for use in VEE.

Browse… - If a library exists on your system that does not appear in the list, click Browse to search for it in the Add ActiveX Automation Reference dialog box. When you find and open the library, VEE adds it to the list, and attempts to register it. To use it in VEE, be sure its box is checked, and click OK.

Notes

VEE must be set to VEE 5 or higher execution mode for ActiveX support to take effect (Default Preferences). ActiveX Automation lets you use VEE as an Automation Controller for applications capable of acting as Automation Servers. This lets you interact with applications such as Microsoft Word, Excel, and Access for activities such as sending data from VEE for report generation. This fully supersedes VEE’s current application-control solution, Dynamic Data Exchange (DDE), for automation-capable applications.

An automation library is installed when you install an application that contains it.

Only select as many libraries as you will need for your program to avoid using excessive memory.

For more information about programming techniques that effect the cleanup of ActiveX references, see the CreateObject topic.

Location

Device [image] ActiveX Automation References…

See Also

See example programs in the ActiveX example directories
Help [image] Open Example…

ActiveX Control References, Default Preferences, Formula, Function & Object Browser, CreateObject, GetObject.

Refer to "Using ActiveX Automation Objects and Controls" in the VEE Advanced Techniques manual.


ActiveX Control Host

A VEE object that hosts an ActiveX control added to the VEE work area.

Use

The ActiveX Control Host is used as a container for an ActiveX control. When you add a control to the work area (Device [image] ActiveX Controls), VEE creates the container so you have access to the control that is similar to the access available to other VEE objects. The container also gives you access to the control’s specific properties built into it by the control’s developers.

When a control appears in the work area, it has a title and variable name in its title bar. It does not have pins that let you connect it to other objects using lines. You must use expressions referring to the variable name that manipulate the control by getting and setting its properties, and calling methods. VEE’s Function & Object Browser (Device [image] Function & Object Browser) helps you to generate these expressions in Formula objects. The variable name essentially is the declared variable name of the control. The control’s declared variable name is very similar to a variable created using the Declare Variable object, except that the control’s variable is already initialized. The declaration is local-to-context, so by default, the variable name can only be used in the context in which it exists. For information about accessing the ActiveX control globally, see Notes below.

Object Menu

  • Help - Opens this VEE Help topic that describes the container object.

  • Properties - Provides access to the VEE container object’s properties such as title, variable name, colors, fonts, and icon view.

  • Control Properties - Provides access to the control’s property pages that are built in by its developers. Every kind of control has different properties. In the resulting properties window, click the Help button to get more information.

  • Edit Event Handler… - Opens the Edit Event Handler dialog box if any event-handler UserFunctions have been created for the control.

  • Create Event Handler… - Opens the Create Event Handler UserFunction browser. This browser lets you create a UserFunction to handle an event generated by the control. You can create an event handler for each event listed in the browser’s Member area.

Properties (container object)

Title - Displays the container object’s current title and allows you to edit it.

Name - Displays the control’s current local variable name and allows you to edit it. This declares and initializes the control as a local-to-context variable.

Notes

VEE must be set to VEE 5 or higher execution mode for ActiveX support to take effect (Default Preferences). ActiveX controls are available as individual products or may be installed as part of a larger application.

VEE does not support all ActiveX controls. If a control is incompatible with VEE, an error will occur when you add the control to your program or while you are using it.

When you add a control to the VEE work area, it appears with an assigned local variable name in its title bar. You can change the assigned variable name by double-clicking the control’s title bar to get the ActiveX Control Properties dialog box. In the Design category, change value of Name. Since the control has no pins to connect with lines to other objects in your program, you must manipulate the control using expressions in Formula objects that refer to the control by its variable name. Since the variable is local-to-context, these expressions must appear in the same context as the control.

If you want the variable name to be global, then declare a new variable name using Declare Variable (Data [image] Variable [image] Declare Variable). Since the control’s variable name already exists, you cannot simply declare it as global; VEE does not allow such conflicts. In Declare Variable, enter the variable name, set Scope to Global, and set Type: to Object. You do not need to check Specify Object Type; however, by specifying the object type details, VEE will do type checking automatically to assure that the specified Library and Class are assigned only to the declared variable. Then you can set the control’s local variable (such as Calendar1) equal to the declared variable (such as g_calendar1) as shown in this expression:

Set g_calendar1 = Calendar1

Location

Device [image] ActiveX Controls

See Also

See example programs in the ActiveX example directories
Help [image] Open Example…

ActiveX Control References, Declare Variable, Default Preferences, Formula, Function & Object Browser.

Refer to "Using ActiveX Automation Objects and Controls" in the VEE Advanced Techniques manual.


ActiveX Control References

Displays the ActiveX Control References dialog box, which lets you make ActiveX controls available for use in VEE.

Use

Use the ActiveX Control References dialog box to select the ActiveX controls that you want to use in your VEE program. Controls appear in this dialog box if they or their associated applications have been installed so the Windows Registry recognizes them. When you select the controls you want, press OK to load them into memory for use in VEE, and to search for their object classes, dispatch interfaces, and exported events.

After selecting controls, use Device [image] ActiveX Controls to pick a control and place it in your program’s detail view as you do for any other VEE object. The resulting control "object" appears with a variable name in its title bar. Since controls have no pins like other objects, you must manipulate it using the control’s variable name in Formula expressions. VEE’s Function & Object Browser (Device [image] Function & Object Browser) helps to generate these expressions.

Dialog Information

Registered Controls: - Contains the list of registered ActiveX control type libraries. Click on a name to highlight it and see information in the status area below the list. Click in the box beside a name, and click OK to select it for use in VEE.

Browse… - If a control exists on your system that does not appear in the list, click Browse to search for it in the Add ActiveX Control Reference dialog box. When you find and open the control, VEE adds it to the list, and attempts to register it. To use it in VEE, be sure its box is checked, and click OK.

Notes

VEE must be set to VEE 5 or higher execution mode for ActiveX support to take effect (Default Preferences). ActiveX controls are available as individual products or may be installed as part of a larger application.

Only select as many controls as you will need for your program to avoid using excessive memory.

After you select names using the ActiveX Control Reference dialog box, VEE adds control names to the menu Device [image] ActiveX Controls. It is normal for some selections to result in more than one ActiveX control being added to the menu.

VEE does not support all ActiveX controls. If a control is incompatible with VEE, an error will occur when you add the control to your program or while you are using it.

Location

Device [image] ActiveX Control References…

See Also

See example programs in the ActiveX example directories
Help [image] Open Example…

ActiveX Automation References, ActiveX Controls, Declare Variable, Default Preferences, Formula, Function & Object Browser.

Refer to "Using ActiveX Automation Objects and Controls" in the VEE Advanced Techniques manual.


ActiveX Controls

A Device menu choice that lets you add ActiveX controls to the VEE work area.

Use

Use the ActiveX Controls menu to add the ActiveX controls that are available for VEE to use. Controls appear in the cascading menu if they were selected using the ActiveX Controls Reference dialog box (Device [image] ActiveX Controls Reference…).

Notes

VEE must be set to VEE 5 or higher execution mode for ActiveX support to take effect (Default Preferences). ActiveX controls are available as individual products or may be installed as part of a larger application.

VEE does not support all ActiveX controls. If a control is incompatible with VEE, an error will occur when you add the control to your program or while you are using it.

Location

Device [image] ActiveX Controls

See Also

See example programs in the ActiveX example directories
Help [image] Open Example…

ActiveX Control Host, ActiveX Control References, Default Preferences.

Refer to "Using ActiveX Automation Objects and Controls" in the VEE Advanced Techniques manual.


Add Terminal

A menu item.

Use

Use Add Terminal to access the following features which add terminals:

Data Input

Control Input

Data Output

Error Output

Short Cuts

You can quickly add a data terminal by placing the cursor over the input or output terminal display area and then pressing CTRL+A. Each press of CTRL+A inserts an additional data terminal where the cursor is located.

Location

On each object menu [image] Add Terminal

See Also

Properties (Object), Line Probe, Delete Terminal, Control Input (Object Menu), Data Input (Object Menu), Data Output (Object Menu), and Error Output (Object Menu).

To Add Input and Output Terminals to a UserObject

To Automatically Re-Scale the Display

To Select a File Name Programmatically


Add To Panel

Copies the selected objects to the associated context panel of your VEE program.

Use

Use Add To Panel to place a set of selected objects on the panel view to create a user interface for your program. For example, the panel view might include only the input and display objects for a program; the detail view of the program is not displayed.

When a panel view exists and the program is not secured, there are two buttons on a UserObject's or UserFunction's title bar that allow you to toggle to the desired view.

If you select Add To Panel and a panel view does not exist, it is created.

Notes

The Add To Panel feature is not available if no objects are selected.

The panel view of a UserObject may be added to the Main panel view or the panel view of a UserObject that is a surrounding context. In other words, panels can be nested. When panels are added to parent panels, an exact duplicate of the source panel is generated. Whenever the source panel is modified, all duplicate panels are updated as well.

To add a UserObject panel to a parent panel, such as the Main panel:

1. After creating a UserObject and its panel, right-mouse click on the UserObject’s icon view to get its object menu.

2. Click on Restore to get the open view. It appears like a panel view. Do not delete this or you will delete the UserObject from the parent program.

3. Select the UserObject so it is highlighted.

4. Click on the Add To Panel toolbar button (Edit [image] Add To Panel). The UserObject appears in the parent panel.

Location

Edit [image] Add To Panel

Or UserObject object menu Edit [image] Add To Panel

See Also

Create UserObject, Delete (Object Menu), Create RunTime Version, Select All, View Detail, and View Panel.

To Add a UserObject Panel to the Main Panel

To Add Objects to a Nested UserObject Panel

To Add Objects to a Panel

To Build a UserFunction Panel

To Build a UserObject Panel


Advanced Instrument Properties

A dialog box that allows you to configure instrument device drivers and interface communications parameters.

Use

After you have selected an Interface: type (GPIB, Serial, etc.) using the Instrument Properties dialog box, clicking on the Advanced... button will bring up the Advanced Instrument Properties dialog box.

There are six different versions of the Advanced Instrument Properties dialog box, one for each of the following types of interfaces:

1. GPIB

2. Serial

3. GPIO

4. VXI

5. TCPIP

6. USB

Dialog Information

The Advanced Instrument Properties dialog box provides the following tabs and fields:

Note
Each type of interface, (GPIB, Serial, GPIO, VXI, TCPIP, or USB) does not always require all of the same communications parameters. For example, the Direct I/O tab for a GPIO interface configuration will contain only a subset of the fields that are present on the Direct I/O tab for a GPIB interface configuration. The following tab descriptions present all of the possible fields that can be found on any particular type of tab.

General tab:

Timeout (sec): - Allows you to specify how many seconds VEE will wait for an instrument to respond to a communication request before generating an error. The default is 5 seconds.

Live Mode: - Specifies whether Live Mode is ON or OFF. If Live Mode is off, you can run your VEE program even if your instrument is not connected. However, to actually communicate with the instrument, Live Mode must be ON. Live Mode remains OFF until you enter a non-zero address in the Address field of the Instrument Properties dialog box; then, Live Mode switches to ON. You can then toggle the ON or OFF field by clicking on it. Live Mode does not apply to Plug&play Drivers.

Byte Ordering: - Specifies the byte order the device uses for reading and writing binary data. VEE determines if byte swapping is necessary. Click on this field to choose between MSB (send Most-Significant Byte, first) and LSB (send Least-Significant Byte, first). All IEEE 488.2-compliant devices use the MSB order. MSB is also the default. Refer to your instrument manual for more specific information.

Description (optional): - Allows you to enter your own brief alphanumeric identifier for the instrument.

Direct I/O tab:

Read Terminator: - Allows you to specify the characters used to terminate an instrument's Read transaction. The default termination character is \n (newline).

Write - Allows you to specify several parameters of an instrument write transaction. There are five fields which can be edited to specify these parameters. These fields are:

EOL Sequence: - Allows you to specify the characters used to identify an EOL (End Of Line). The default characters are \n.

Multi-Field as: - Choices are Data Only (default), and (...) Syntax.

Array Separator: - Allows you to specify the character used as an Array Separator. The default charater is "," (a comma).

Array Format: - Choices are Linear or Block. The default is Linear.

END (EOI) on EOL: - End Or Identify on End Of Line. The choices are YES or NO. The default is NO.

Conformance: - Allows you to specify which GPIB IEEE conformance specification will be used in the Direct I/O transaction. The choices are, IEEE 488 (default), and IEEE 488.2.

Binblock: - Allows you to specify the Binblock format for a Direct I/O transactions. The Binblock format choices are:

None - If you specified Conformance (above) to be IEEE 488.2, this will be the default choice.

#A - An IEEE 728 block header with the format: #A<Byte_Count><Data>

#I - An IEEE 728 block header with the format: #I<Byte_Count><Data>

#T - An IEEE 728 block header with the format: #T<Data><END>

Where:

- # is the actual character.
- A, I and T are the actual characters.
- <Byte_Count> consists of two bytes which together form a 16-bit unsigned integer that specifies the number of bytes that follow in <Data>. (VEE calculates this automatically).
- <Data> is a stream of arbitrary bytes.
- <END> indicates that EOI is asserted with the last data byte transmitted.

State (Learn String): - The State field indicates whether or not the instrument has been configured for uploading and downloading learn strings. The choices are Not Config'd (which is the default value), or Configured. If you choose Configured then the Upload String and Download String fields will be highlighted for an input.

Upload String: - The Upload String field specifies the command that is sent to the instrument when you select the Upload State from the Direct I/O object menu. Specify the command that causes the instrument to output its learn string; consult your instrument programming manual for details. Note that you must enclose the command with double quotes.

Download String: - The Download String field specifies the string that is sent to the instrument immediately before the learn string as the result of a WRITE STATE (LEARN STRING) transaction in a Direct I/O object. This field is provided to support instruments that require a command prefix when downloading a learn string; consult your instrument programming manual for details.

Plug&play Driver tab:

Plug&play Driver Name: - The driver name assigned to the Plug&play device being configured. The default name is Unknown.

Parameters to init() call group:

Address (eg GPIB-VXI0::12::INSTR): - The device address of the Plug&play instrument.

Perform Indentification Query - When this box is checked, a query of the Plug&play device ID will be performed at initialization. The box is checked by default.

Perform Reset - When this box is checked, the device will automatically be sent a Reset command. The box is checked by default.

Panel Driver tab:

ID Filename: - Clicking on this field will bring up the Read from what Instrument Driver? dialog box. From the Read from what Instrument Driver? dialog box, you can select the desired ID Filename from the directories and files that are displayed.

Sub Address: - Enter the Sub Address (if any) of the Panel Driver.

Error Checking: - Turns Error Checking ON or OFF. Default is ON.

Incremental Mode: - Turns Incremental Mode ON or OFF. Default is ON.

Serial tab:

Baud Rate: - The default baud rate is 9600 (bits per second).

Character Size: - The default is 8(bits). Allowed values are 5, 6, 7, 8, and None.

Stop Bits: - The default is 1. Allowed values are 1 and 2.

Parity: - The default is None. Allowed values are None, Odd, Even, Mark, and Space.

Handshake: - The default is None. Allowed values are None and Xon/Xoff.

Receive Buffer Size: - The default is 4096 (bytes).

GPIO tab:

Data Width: - The Data Width field specifies the number of bits of parallel data transmitted as a unit across the GPIO interface. This field configures the interface to read and write data either 8 bits (the default value), or 16 bits wide. No hardware switches need to be set in conjunction with this field.

A16 Space tab: (VXI Only)

Byte Access (D8) - The Byte Access field specifies whether the VXI device supports 8-bit, A16 memory accesses. The Byte Access choices are:

NONE - The device does not support byte access. This is the default.

ODD ACCESS - The device supports byte access, but only on odd-byte boundaries (D08(O)).

ODD/EVEN ACCESS - The device supports byte access on all boundaries (D08(E)).

Word Access (D16) - The Word Access field is not editable. All VXI devices must support 16-bit access (D16).

LongWord Access (D32) - The LongWord Access field specifies whether the VXI device supports 32-bit, A16 memory accesses. The LongWord Access choices are:

NONE - The device does not support 32-bit access. This is the default.

D32 ACCESS - The device supports 32-bit, A16 memory access.

Add Register - Each time you click on the Add Register field, a row of new fields will appear on the right half of the dialog box. Each of these new fields allow you to configure access to a device's A16 memory. The four fields are:

Name - This is the symbolic name of the register, which is used to refer to the particular register in a Direct I/O object using either a READ REGISTER or a WRITE REGISTER transaction.

Offset - This is the offset in bytes from the relative base of the device's A16 memory, for the register being configured. The default Offset is 0.

Format - This is the data format that will be read from, or written to, the register being configured. The read or write access will take place at the byte specified in the Offset field. The possible formats are:
- BYTE - Read or write a byte. The device must support and be configured correctly for 8-bit access by using the Byte Access field explained above. If the BYTE field is ODD, the byte location specified in the Offset field must be an odd number.
- WORD16 - Read or write a 16-bit word. The 16 bits are represented as a two's complement integer. All VXI devices explicitly support this format.
- WORD32 - Read or write a 32-bit word. The 32 bits are represented as a two's complement integer. VEE supports this format even if the LongWord Access field is specified as NONE (by using two D16 accesses to read or write all 32 bits). If the LongWord Access field is specified as D32 ACCESS, all 32 bits are accessed.
- REAL32 - Read or write a 32-bit word which is represented as an IEEE 754 32-bit floating-point number. VEE supports this format even if the LongWord Access field is specified as NONE (by using two D16 accesses to read or write all 32 bits). If the LongWord Access field is specified as D32 ACCESS, all 32 bits are accessed.

Mode - Specify what I/O mode the register will support. The choices are:
- READ - This register will appear as a choice in a READ REGISTER transaction only.
- WRITE - This register will appear as a choice in a WRITE REGISTER transaction only.
- READ/WRITE - This register will appear as a choice in both a READ REGISTER and WRITE REGISTER transaction.

Delete Register - When you click on the Delete Register field, a Select Register To Delete box will appear which contains the symbolic Name of each of the currently configured registers. Click on the symbolic Name of the register you wish to delete, then click the OK button to confirm the deletion.

A24/A32 Space tab: (VXI Only).

The A24/A32 Space refers to the A24 or A32 extended memory in a VXI device. A VXI device can implement either A24 memory or A32 memory, but not both.

Byte Access (D8) - The Byte Access field specifies whether the VXI device supports 8-bit, extended memory accesses. The Byte Access choices are:

NONE - The device does not support byte access. This is the default.

ODD ACCESS - The device supports byte access, but only on odd-byte boundaries (D08(O)).

ODD/EVEN ACCESS - The device supports byte access on all boundaries (D08(E)).

Word Access (D16) - The Word Access field is not editable. All VXI devices must support 16-bit access (D16) for all memory spaces.

LongWord Access (D32) - The LongWord Access field specifies whether the VXI device supports 32-bit extended memory accesses. The LongWord Access choices are:

NONE - The device does not support 32-bit access. This is the default.

D32 ACCESS - The device supports 32-bit extended memory access.

Add Location - Each time you click on the Add Location field, a row of new fields will appear on the right half of the dialog box. Each of these new fields allow you to configure access to a device's extended memory. The four fields are:

Name - This is the symbolic name of the location, which is used to refer to the particular memory location in a Direct I/O object using either READ MEMORY or WRITE MEMORY transactions.

Offset - This is the offset in bytes from the relative base of the device's extended memory, for the location being configured. The default Offset is 0.

Format - This is the data format that will be read from, or written to, the location being configured. The read or write access will take place at the byte specified in the Offset field. The possible formats are:
- BYTE - Read or write a byte. The device must support and be configured correctly for 8-bit access by using the Byte Access field explained above. If the BYTE field is ODD, the byte location specified in the Offset field must be an odd number.
- WORD16 - Read or write a 16-bit word. The 16 bits are represented as a two's complement integer. All VXI devices explicitly support this format.
- WORD32 - Read or write a 32-bit word. The 32 bits are represented as a two's complement integer. VEE supports this format even if the LongWord Access field is specified as NONE (by using two D16 accesses to read or write all 32 bits). If the LongWord Access field is specified as D32 ACCESS, all 32 bits are accessed.
- REAL32 - Read or write a 32-bit word which is represented as an IEEE 754 32-bit floating-point number. VEE supports this format even if the LongWord Access field is specified as NONE (by using two D16 accesses to read or write all 32 bits). If the LongWord Access field is specified as D32 ACCESS, all 32 bits are accessed.

Mode - Specify what I/O mode the location will support. The choices are:
- READ - This location will appear as a choice in a READ MEMORY transaction only.
- WRITE - This location will appear as a choice in a WRITE MEMORY transaction only.
- READ/WRITE - This location will appear as a choice in both a READ MEMORY and WRITE MEMORY transaction.

Delete Location - When you click on the Delete Location field, a Select Memory Location To Delete box will appear which contains the symbolic Name of each of the currently configured locations. Click on the symbolic Name of the location you wish to delete, then click the OK button to confirm the deletion.

Location

I/O [image] Instrument Manager... then select
Add... or Properties then select
Advanced...

See Also

Instrument Properties, Instrument Manager.

To Add an Instrument Configuration

To Use a Direct I/O Object

See "Configuring Instruments" in the VEE Advanced Techniques manual.


Advanced I/O

A menu item.

Use

Use Advanced I/O to access the following objects for low-level control of the GPIB, RS-232 (serial), VXI, LAN, and USB interfaces (such as bus commands, polling, and service requests):

Interface Operations

Device Event

Interface Event

MultiDevice Direct I/O

Notes

VXIplug&play does not support any of the Advanced I/O features.

Location

I/O [image] Advanced I/O

See Also

Bus I/O Monitor, Device Event, Interface Event, Interface Operations, and MultiDevice Direct I/O.

To Poll GPIB Instruments


Align

An Edit menu selection that allows you to physically Align objects in your VEE Panel and Detail views.

Use

Align provides several options for manipulating the physical placement of VEE objects. The options control horizontal and vertical alignment, as well as the distribution of the objects. You can hold down the CTRL key and simultaneously use the left mouse button to select the objects you wish to Align. You can also hold down the CTRL key and draw a box around the objects you wish to align by using the left mouse key and dragging from the upper left to the lower right corner of the selection area. Finally, if you want to select all of the objects, you can go the Edit Menu and choose Select All. Once you have selected the objects, use one of the following menu options to perform the alignment.:

  • Middles - Performs a horizontal alignment of the selected VEE objects using the middle of the left-most object as a Y coordinate reference point.

  • Tops - Performs a horizontal alignment of the selected VEE objects using the top of the left-most object as a Y coordinate reference point.

  • Bottoms - Performs a horizontal alignment of the selected VEE objects using the bottom of the left-most object as a Y coordinate reference point.

  • Centers - Performs a vertical alignment of the selected VEE objects using the center of the top-most object as an X coordinate reference point.

  • Lefts - Performs a vertical alignment of the selected VEE objects using the left side of the top-most object as an X coordinate reference point.

  • Rights - Performs a vertical alignment of the selected VEE objects using the right side of the top-most object as an X coordinate reference point.

  • Distribute Horizontally – Performs a horizontal distribution of the selected VEE objects by using the left side of the left most object and evenly distributing the objects on the horizontal plane.

  • Distribute Vertically - Performs a vertical distribution of the selected VEE objects by using the top of the topmost object you select and evenly distributing the objects on the vertical plane.

Notes

If, when aligning an object, its new placement would cause it to overlap an object, use the Bring-to-Front or Send-to-Back feature to rearrange the object as needed.

Aligned objects are not unselected after an alignment has occurred. This allows a subsequent group alignment of those same objects.

The reference object is not moved during an alignment or distribution.

Location

Edit [image] Align

Middles or

Tops or

Bottoms or

Centers or

Lefts or

Rights or

Distribute Horizontally

Distribute Vertically

See Also

Default Preferences, Bring to Front (Object Menu), Send to Back (Object Menu), and Select All


Allocate Array

A menu item.

Use

Use Allocate Array to access the following array building and initialization objects:

Alloc Text

Alloc UInt8

Alloc Int16

Alloc Int32

Alloc Real32

Alloc Real64

Alloc Coord

Alloc Complex

Alloc PComplex

Notes

Use Set Values to modify arrays that already exist.

Location

Data [image] Allocate Array

See Also

Alloc Coord, Alloc Complex, Alloc UInt8, Alloc Int16, Alloc Int32, Alloc PComplex, Alloc Text, Alloc Real32, Alloc Real64, Get Values, Set Mappings, and Set Values.

To Allocate an Array

To Change Values in an Array


Alloc Complex

An object that creates a Complex array.

Use

Use Alloc Complex to create an array of Complex elements.

Open View Parameters

Num Dims - The number of dimensions in the output array. Num Dims is an integer from 1 through 10. Default is 1.

Init Value - The value to place in each array element. Default is (0, 0).

Size - The number of elements in the dimension. There is one size field per dimension. Default is 10.

Init Value and Size may be set on the object or from data input pins.

Notes

To change the values of individual elements, use Set Values.

If the Num Dims value is changed, the view automatically creates or deletes fields on the open view so that the number of dimension size fields matches the value of the Num Dims value.

The output array is not mapped. Use Set Mappings to map the dimensions of the array.

Location

Data [image] Allocate Array [image] Complex

See Also

Complex, Get Values, Set Mappings, and Set Values.

To Allocate an Array and Properties (Object)


Alloc Coord

An object that creates a Coord array.

Use

Use Alloc Coord to create an array of Coord elements.

Open View Parameters

Num Dims - The number of dimensions in the output array. Unlike other array types such as Int32 and Real64, Num Dims can only be 1 since Coord arrays of greater than 1 dimension are not allowed in VEE.

Num Coord Dims - The number of values in each Coord. Valid range is 2 to 10.

Init Value - The value to place in each array element. Default is (0, 0), (0,0,0), (0,0,0,0), etc. depending on the value of Num Coord Dims.

Size - The number of elements in the dimension. Default is 10.

Init Value and Size may be set on the object or from data input pins.

Notes

To change the values of individual elements, use Set Values.

Location

Data [image] Allocate Array [image] Coord

See Also

Allocate Array, Build Data, Coord, Get Values, Set Values, and UnBuild Data.

To Allocate an Array and Properties (Object)


Alloc Int16

An object that creates an integer array.

Use

Use Alloc Int16 to create an array of 2-byte integer elements.

Open View Parameters

Num Dims - The number of dimensions in the output array. Num Dims is an integer from 1 through 10. Default is 1.

Init Value | Lin Ramp | Log Ramp

Init Value - The values to place in each array element. This value is interpreted as an integer. Default is 0.

Lin Ramp - A linear ramp of integer values that are as equally spaced as possible between the ramp initial value (inclusive) and the ramp ending value (inclusive). This option is only available if Num Dims = 1.

Log Ramp - A ramp of integer values that are as logarithmically spaced as possible between the ramp initial value (inclusive) and the ramp ending value (inclusive). This option is only available if Num Dims = 1.

Size - The number of elements in the dimension. There is one size field per dimension. Default is 10.

Init Value and Size may be set on the object or from data input pins.

Notes

To change the values of individual elements, use Set Values.

If the Num Dims value is changed, the view automatically creates or deletes fields on the open view so that the number of dimension size fields matches the value of the Num Dims value.

The output array is not mapped. Use Set Mappings to map the dimensions of the array.

Location

Data [image] Allocate Array [image] Int16

See Also

Int16, Get Values, Set Mappings, and Set Values.

To Allocate an Array and Properties (Object)


Alloc Int32

An object that creates an integer array.

Use

Use Alloc Int32 to create an array of 4-byte integer elements.

Open View Parameters

Num Dims - The number of dimensions in the output array. Num Dims is an integer from 1 through 10. Default is 1.

Init Value | Lin Ramp | Log Ramp

Init Value - The values to place in each array element. This value is interpreted as an integer. Default is 0.

Lin Ramp - A linear ramp of integer values that are as equally spaced as possible between the ramp initial value (inclusive) and the ramp ending value (inclusive). This option is only available if Num Dims = 1.

Log Ramp - A ramp of integer values that are as logarithmically spaced as possible between the ramp initial value (inclusive) and the ramp ending value (inclusive). This option is only available if Num Dims = 1.

Size - The number of elements in the dimension. There is one size field per dimension. Default is 10.

Init Value and Size may be set on the object or from data input pins.

Notes

To change the values of individual elements, use Set Values.

If the Num Dims value is changed, the view automatically creates or deletes fields on the open view so that the number of dimension size fields matches the value of the Num Dims value.

The output array is not mapped. Use Set Mappings to map the dimensions of the array.

Location

Data [image] Allocate Array [image] Int32

See Also

Int32, Get Values, Set Mappings, and Set Values.

To Allocate an Array and Properties (Object)


Alloc PComplex

An object that creates a PComplex array.

Use

Use Alloc PComplex to create an array of PComplex elements.

Open View Parameters

Num Dims - The number of dimensions in the output array. Num Dims is an integer from 1 through 10. Default is 1.

Init Value - The value to place in each array element. The initial value's phase is normalized to fall between pi and -pi radians; if the number's magnitude is negative, it is converted to a positive by shifting the phase angle 180 degrees. Default is (0, @0).

Size - The number of elements in the dimension. There is one field per dimension. Default is 10.

Init Value and Size may be set on the object or from data input pins.

Notes

Set Values changes the values of individual elements.

If the Num Dims value is changed, the view automatically creates or deletes fields on the open view so that the number of dimension size fields matches the Num Dims value.

The output array is not mapped. Use Set Mappings to map the dimensions of the array.

Location

Data [image] Allocate Array [image] PComplex

See Also

Allocate Array, Get Values, PComplex, Set Mappings, and Set Values.

To Allocate an Array and Properties (Object)


Alloc Real32

An object that creates a real array.

Use

Use Alloc Real32 to create an array of 4-byte real elements.

Open View Parameters

Num Dims - The number of dimensions in the output array. Num Dims is an integer from 1 through 10. Default is 1.

Init Value | Lin Ramp | Log Ramp

Init Value - The value to place in each array element. Default is 0.

Lin Ramp - A linear ramp of real values that are as equally spaced as possible between the ramp initial value (inclusive) and the ramp ending value (inclusive). This option is only available if Num Dims = 1.

Log Ramp - A ramp of real values that are logarithmically spaced between the ramp initial value (inclusive) and the ramp ending value (inclusive). This option is only available if Num Dims = 1.

Size - The number of elements in the dimension. There is one size field per dimension. Default is 10.

Init Value and Size may be set on the object or from data input pins.

Notes

To change the values of individual elements, use Set Values.

If the Num Dims value is changed, the view automatically creates or deletes fields on the open view so that the number of dimension size fields matches the Num Dims value.

The output array is not mapped. Use Set Mappings to map the dimensions of the array.

Location

Data [image] Allocate Array [image] Real32

See Also

Get Values, Real32, Set Mappings, and Set Values.

To Allocate an Array and Properties (Object)


Alloc Real64

An object that creates a real array.

Use

Use Alloc Real64 to create an array of 8-byte real elements.

Open View Parameters

Num Dims - The number of dimensions in the output array. Num Dims is an integer from 1 through 10. Default is 1.

Init Value | Lin Ramp | Log Ramp

Init Value - The value to place in each array element. Default is 0.

Lin Ramp - A linear ramp of real values that are as equally spaced as possible between the ramp initial value (inclusive) and the ramp ending value (inclusive). This option is only available if Num Dims = 1.

Log Ramp - A ramp of real values that are logarithmically spaced between the ramp initial value (inclusive) and the ramp ending value (inclusive). This option is only available if Num Dims = 1.

Size - The number of elements in the dimension. There is one size field per dimension. Default is 10.

Init Value and Size may be set on the object or from data input pins.

Notes

To change the values of individual elements, use Set Values.

If the Num Dims value is changed, the view automatically creates or deletes fields on the open view so that the number of dimension size fields matches the Num Dims value.

The output array is not mapped. Use Set Mappings to map the dimensions of the array.

Location

Data [image] Allocate Array [image] Real64

See Also

Get Values, Real64, Set Mappings, and Set Values.

To Allocate an Array and Properties (Object)


Alloc Text

An object that creates a Text array.

Use

Use Alloc Text to create an array of Text elements.

Open View Parameters

Num Dims - The number of dimensions in the output array. Num Dims is an integer from 1 through 10. Default is 1.

Init Value - The value to place in each array element. This value is interpreted as a string. Default is null (an empty string).

Size - The number of elements in the dimension. Default is 10.

Init Value and Size may be set on the object or from data input pins.

Notes

To change the values of individual elements, use Set Values.

If the Num Dims value is changed, the view automatically creates or deletes fields on the open view so that the number of dimension size fields matches the Num Dims value.

The output array is not mapped. Use Set Mappings to map the dimensions of the array.

Location

Data [image] Allocate Array [image] Text

See Also

Get Values, Set Mappings, Set Values, and Text.

To Allocate an Array and Properties (Object)


Alloc UInt8

An object that creates an integer array.

Use

Use Alloc UInt8 to create an array of 1-byte integer elements.

Open View Parameters

Num Dims - The number of dimensions in the output array. Num Dims is an integer from 1 through 10. Default is 1.

Init Value | Lin Ramp | Log Ramp

Init Value - The values to place in each array element. This value is interpreted as an integer. Default is 0.

Lin Ramp - A linear ramp of integer values that are as equally spaced as possible between the ramp initial value (inclusive) and the ramp ending value (inclusive). This option is only available if Num Dims = 1.

Log Ramp - A ramp of integer values that are as logarithmically spaced as possible between the ramp initial value (inclusive) and the ramp ending value (inclusive). This option is only available if Num Dims = 1.

Size - The number of elements in the dimension. There is one size field per dimension. Default is 10.

Init Value and Size may be set on the object or from data input pins.

Notes

To change the values of individual elements, use Set Values.

If the Num Dims value is changed, the view automatically creates or deletes fields on the open view so that the number of dimension size fields matches the value of the Num Dims value.

The output array is not mapped. Use Set Mappings to map the dimensions of the array.

Location

Data [image] Allocate Array [image] UInt8

See Also

UInt8, Get Values, Set Mappings, and Set Values.

To Allocate an Array and Properties (Object)


AlphaNumeric

An object that displays alphanumeric data.

Use

Use AlphaNumeric to display any of the data types as a single value, an Array 1D, or a Array 2D. To view an array, scroll the display with the scroll bars.

Properties

ShowArrayIndices - When this property is True and the data received is an array, each line in the display area is indexed. Default is True.

Number Format - If Global format is checked, use the default format. Default is on.

Integer: - If Global Format is off, specify the number format for integer numbers to be displayed on this object. The choices are Decimal (e.g. 42), Octal (e.g. #Q52), Hexadecimal (e.g. #H2a), and Binary (e.g. #B00101010). Default is Decimal.

Real: - If Global Format is off, specify the number format for Real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Sat 01/Jan/2003 17:01:38). Default is Standard.

Significant Digits: - If Global Format is off, specify the number of significant digits to display for Real values.

Notes

A row of asterisks (***) is displayed if the current width of the AlphaNumeric object is too small to display the default precision of the numeric type (using the currently specified display font). Resize the object to display the data.

If there is a 2D Array, you will see a scroll bar (unless you have resized the object to show the entire array).

Arrays that are three-dimensional and larger are displayed as the string 3D Array and so forth.

The display of ASCII values 0-31 is dependent on font and may not be readable.

Text strings longer than 2048 characters may not display properly on some platforms (operating systems). Text strings longer than 32767 characters do not display properly on any platform.

Location

Display [image] AlphaNumeric

See Also

Default Preferences and Logging AlphaNumeric.

To Display a Scalar Value and Properties (Object)

To Display an Array of Values


Arrange Icons

A Windows menu selection which controls the arrangement of minimized window icons in the VEE workspace.

Use

Use Arrange Icons to access the following icon placement functions:

by Position - this selection will arrange all minimized window icons along the bottom of the VEE workspace based on their current positions.

by Name - this selection will lexicographically arrange all minimized window icons along the bottom of the VEE workspace.

Notes

The Arrange Icons menu item will be unavailable (grayed out) if there are no open, minimized windows.

Location

Window [image] Arrange Icons

See Also

Minimize All, by Name, and by Position.


asClrType

asClrType(x, t)

A function that converts a VEE data container “x” to a .NET object of type “t”.

Use

Use asClrType to convert a VEE data container to a .NET object of type “t”. VEE converts data types between VEE and .NET automatically for all data types that both VEE and .NET support natively. For example, Int16, Int32, Real64, etc. This is a design decision that should satisfy most VEE use cases. In less frequent use cases, you may wish to “undo” this automatic conversion so you can use the data as a true .NET object. In those cases, you can use asClrType type conversion function to convert a VEE data type to a .NET/CLR object.

“x” is a VEE data container. The allowed VEE data container types are Uint8, Int16, Int32, Real32, Real64, Text and arrays of those types. “t” is a .NET/CLR type. The allowed .NET/CLR data types include all the primitive types (System.Boolean, System.Byte, System.Sbyte, System.Int16, System.Uint16, System.Int32, System.Uint32, System.Int64, vUint64, System.Char, System.Double, and System.Single), System.Decimal, System.DateTime and System.String.

Returns a .NET object of type “t”. An error 440 will occur if either the VEE data container or the .NET/CLR type is not allowed. An error 464 will occur if the conversion fails.

Assumption: You have referenced the assembly mscorlib.dll. This assembly provides all the .NET/CLR data types allowed for this function.

Examples

VEE automatically converts the .NET type System.String to VEE’s Text. If you want to use the many useful functions in the System.String class, you may use asClrType to convert the text back to System.String:

Set dotnetString = asClrType(“abacusabcus”, System.String);

dotNetString.EndsWith(“us”);

Also see examples\DotNet\StringSplit.vee.

Location

Device [image] Function & Object Browser

Type: Built-in Functions

Category: Type Conversion

Member: asClrType


Auto Scrolling

In Detail view, drag but don't drop an Object to the edge of the main work area and pause, the work area will scroll in that direction. You can move the Object to any edge or corner.


Beep

An object that generates an audible tone.

Use

Use Beep to generate a tone of a specified frequency, duration, and volume.

Open View Parameters

Frequency (Hz) - The frequency of the tone in Hertz. Default is 1000 Hz.

Duration (sec) - The time in seconds for the tone to last. Default is 0.1 sec.

Volume (0-100) - The relative volume of the tone, where 0 is silent and 100 is the loudest. Default is 80. (On the PC, any value from 1 to 100 causes the same volume. However, a value of 0 causes silence.) This parameter is ignored for all versions of Windows.

All of the three open view parameters can be added as data input terminals.

Notes

The functionality of the Beep object is hardware dependent. In some cases, one or more of the open-view parameters may not affect the actual tone generated. Also, some computers do not have internal speakers and may require an external speaker module. Refer to your computer owner's manual for information about its audio output capabilities.

A Frequency or Volume value less than or equal to zero will pause for the specified duration.

The Beep object may complete execution (activate its sequence output pin) before a long duration tone has completed. Execution of subsequent Beep objects, however will pause program execution until the previous tone has completed.

Frequency and volume are ignored no Windows 98/ME.

Location

Display [image] Beep

See Also

Properties (Object)


Break

An object that terminates the current iteration loop.

Use

Use Break to stop the loop and continue execution through the sequence output pin of the iterator.

Note

Break is usually used with Until Break objects. It may also be used with other iteration objects and is often used with an If/Then/Else object to conditionally stop iteration.

Location

Flow [image] Repeat [image] Break

See Also

For Count, For Range, For Log Range, Next, On Cycle, If/Then/Else, and Until Break.

To Loop Part of a VEE Program and Properties (Object)


Bring to Front (Object Menu)

Brings an Object to the front of the viewable plane by changing the z-order of the object..

Use

From the Object menu of the Panel view, places the chosen Object in the foreground of the viewable plane.

See Also

Send to Back (Object Menu), Align, and Move (Object Menu)


Build Arb Waveform

An object that creates a waveform from a set of coordinate data.

Use

Use Build Arb Waveform to create a uniformly sampled waveform from an Array 1D of Coord values.

Open View Parameters

Num Points - The number of points in the output waveform. Default is 256. Num Points may be set from a data input.

Notes

Build Arb Waveform uses the following formula:

  dx = (Xmax-Xmin)/Num Points

  Xvalue = Xmin + (point * dx)

Therefore, the last data point is not the last independent value of Coord.

The independent values (x) of each Coord must be greater than, or equal to, the independent value of the previous Coord in the array.

The Input Coord array must be (x,y) pairs, not (x,y,z).

Location

Data [image] Build Data [image] Arb Waveform

See Also

Build Waveform, Comparator, Coord, Function Generator, Noise Generator, Pulse Generator, and Properties (Object)

See Examples

ScopeMask.vee


Build Complex

An object that creates a Complex number.

Use

Use Build Complex to create a Complex number from real and imaginary components.

Notes

If one of the inputs is an array, the other input must be either a Scalar or an array of the same size and shape. Both inputs are converted to type Real64. The output is the same size and shape as the inputs. The input values' mappings are ignored and the output Complex value is not mapped.

Location

Data [image] Build Data [image] Complex

See Also

Build Data, UnBuild Complex, and Properties (Object)

See Examples

Complex.vee


Build Coord

An object that creates a Coord from real numbers.

Use

Use Build Coord to build a Coord from real components.

Notes

The number of data inputs determines the number of coordinate fields. The default (and minimum) is 2 (x,y). The maximum number of coordinate fields is 10.

If one of the inputs is an array, the other input(s) must be either Scalar or array data of the same size and shape. All inputs are converted to type Real64. The output is of the same shape as the inputs. The input values' mappings are ignored.

The data input shape must be a Scalar or Array 1D.

Note
For Coordinate data type, the field names will always be x, y, z, w, v, u, t, s, r, q even though you may change the input terminal names. These field names are used on UnBuild Coord and sort(x).

Location

Data [image] Build Data [image] Coord

See Also

Build Data, Coord, UnBuild Coord, UnBuild Data, and Properties (Object)

See Examples

FutValue.vee


Build Data

A menu item.

Use

Use Build Data to access the following objects that create containers of particular data types from separate components:

Build Coord

Build Complex

Build Complex

Build Waveform

Build Arb Waveform

Build Spectrum

Build Record

Location

Data [image] Build Data

See Also

Allocate Array, Build Arb Waveform, Build Complex, Build Coord, Build PComplex, Build Record, Build Spectrum, Build Waveform, Set Mappings, Set Values, and UnBuild Data.


Build PComplex

An object that creates a PComplex (polar complex) number from separate components.

Use

Use Build PComplex to create a PComplex number from the magnitude and phase components. Units of the phase component are determined by the Trig Mode setting under File [image] Default Preferences.

Notes

If one of the inputs is an array, the other input must be either a Scalar or an array of the same size and shape. Both inputs are converted to type Real64. The output is of the same shape as the inputs. The input values' mappings are ignored and the output PComplex value is not mapped.

The phase of the initial value is normalized to fall between pi and -pi radians. If the magnitude is negative, it is converted to positive and the phase angle is shifted 180 degrees.

Location

Data [image] Build Data [image] PComplex

See Also

Alloc PComplex, Build Complex, Build Data, Default Preferences, PComplex, UnBuild PComplex, and Properties (Object)

See Examples

Complex.vee, FutValue.vee, and Manual10.vee


Build Record

An object that creates a record from separate components

Use

Use Build Record to create a record from scalar or array components. The input data components become fields in the output record. The output record can be either a scalar or a one-dimensional array.

Open View Parameters

Output Shape - You can set the shape of the output record to either Scalar or Array 1D.

Notes

The fields in the record are named from the names of the corresponding input terminals. The field names are case insensitive (lowercase and uppercase letters are equivalent). Field names may not be duplicated within a single record. Additional data inputs may be added to create a record with any number of fields. Records of records are allowed (where a field in a record is itself a record). There is no limit on recursion (except for the available memory).

If all inputs are scalar quantities, the record on the Record output pin will be a scalar record consisting of one field for each input, regardless of the specified Output Shape.

If one or more of the inputs are array, the shape of the resulting record depends on the specified Output Shape:

If Scalar is specified as the Output Shape, the output record will be a scalar that consists of one field for each input. Each field will be either a scalar or an array, the same shape as the corresponding input.

If Array 1D is specified as the Output Shape, the output record will be a one-dimensional array of records with fields for each input. If an input is a scalar or one-dimensional array, the corresponding field in the record will be a scalar. If an input is an n-dimensional array, the corresponding field will be an array of n-1 dimensions. If more than one of the inputs are arrays, they must all have the same size and shape. Here are some examples:

If input A is a one-dimensional array 10 elements long and input B is a scalar, the output will be a one-dimensional record array of 10 elements with two fields, A and B. The individual elements of the A input array will appear in the individual array elements of field A in the output record. Input B will be duplicated 10 times in the B field of the output record.

If an input is an array of two or more dimensions, the output record will still be an Array 1D. For example, if an input field is a two-dimensional array, 10-by-3 in size, the output record is a one-dimensional array with a length of 10, but with a field which is a one-dimensional array of 3 elements.

Location

Data [image] Build Data [image] Record

See Also

From DataSet, Get Field, Merge Record, Record Constant, Set Field, SubRecord, To DataSet, and UnBuild Record.

To Collect Data into a Record and Properties (Object)

See Examples

appA_Records1.vee and Ch5_UnBuild.vee


Build Spectrum

An object that creates a Spectrum from separate components.

Use

Use Build Spectrum to build spectrum values from an array of PComplex or Complex numbers and the frequency interval information.

Example

If you have an Array 1D of [5], PComplex (0,@1), (0,@2), and so forth, and frequency start equals 11 and stop equals 16, then frequency sample equals 11, 12, 13, 14, 15.

Open View Parameters

Start/Stop Freq |Center/Span Freq - Determines whether the two type-in values represent Start/Stop or Center/Span. Either Start/Stop or Center/Span values can be added as inputs.

Freq Sampling - Specifies whether the frequency sampling values are sampled linearly or logarithmically. Default is Linear.

Notes

The input PComplex values' mappings are ignored.

VEE does not track dB-scaled data. When you perform operations on dB-scaled data, you must ensure that they are done correctly.

To convert between linear- and db-scaled data, use the library programs provided with VEE in the lib directory under the VEE program installation directory.

There are the same number of points as sampling intervals. Each point is at the beginning of the sampling interval.

Location

Data [image] Build Data [image] Spectrum

See Also

Build Data, Build Waveform, and UnBuild Spectrum.

fft(x) and Properties (Object)


Build Waveform

An object that creates a Waveform from separate components.

Use

Use Build Waveform to create a Waveform from a real array of amplitude values and time span information.

Open View Parameters

Time Span - The length of time in seconds over which the y data was sampled. Time Span may be added as a data input. Default is 20m seconds.

Notes

The input values' mappings are ignored. Build Waveform assumes the y data was sampled linearly at a constant rate over the given interval.

There are the same number of points as sampling intervals. Each point is at the beginning of the sampling interval.

Location

Data [image] Build Data [image] Waveform

See Also

Build Arb Waveform, Build Data, Build Spectrum, and UnBuild Waveform.

ifft(x) and Properties (Object)

See Examples

DigFilt.vee and ReadMarkerValues.vee


Bus I/O Monitor

An object that logs the messages sent over an I/O interface path (GPIB, GPIO, USB, LAN, VXI, or RS-232).

Use

Use Bus I/O Monitor to record each byte (command or data) transferred between VEE and any instruments it is controlling by way of Instrument Panels, Component Drivers, Direct I/O, and the Advanced I/O devices. The information that is recorded can be optionally sent to a log file. The Bus I/O Monitor does not show information from Plug&play Drivers.

The display area of Bus I/O Monitor contains five columns. For GPIB, GPIO and RS-232 the columns indicate:

Column 1 - Line number.

Column 2 - GPIB command (*), data output (>), or data input (<).

Column 3 - Hexadecimal value of the byte transmitted.

Column 4 - 7-bit ASCII character corresponding to the byte transmitted.

Column 5 - Bus command mnemonic (GPIB bus commands only).

Only columns 1 through 3 are used when monitoring GPIO communications.

Only columns 1 through 4 are used when monitoring RS-232 communications.

For VXI the columns indicate:

Column 1 - Line number.

Column 2 - VXI command (*), data output (>), or data input (<).

Column 3 - Memory space (A16, A24, or A32), symbolic name for register or location, offset from named location.

Column 4 - Hexadecimal value of the byte transmitted.

Column 5 - Logical address of the VXI instrument.

Object Menu

Clear - Clears the contents of the Bus I/O Monitor. Clear may be added as a control input pin.

Clear Log File - Deletes the contents of the specified log file. This parameter can be added as a control input.

Properties

Logging

LoggingEnabled - Records activity in the list area of the Bus I/O Monitor. Log Enable and Log Disable control input pins may be added. Default is True.

FileLoggingEnabled - Sends data to the specified file as it is recorded by the Bus I/O Monitor. Monitor data is always appended to the end of the specified file. The Log File Name can be specified on the open view of the Bus I/O Monitor or can be added as a control input. Default is False.

BufferSize

Lines: Determines the maximum number of lines retained in the monitor's display. Once the monitor is full, lines at the beginning of monitor are discarded to make room for newly-logged lines. Default is 256.

Notes

The Bus I/O Monitor allows execution to proceed much faster when displayed as an icon rather than an open view.

Each Bus I/O Monitor object is capable of monitoring one physical bus. For example, to monitor VEE activity on one GPIB card and one RS-232 card, the user would need two Bus I/O Monitors.

Bus I/O Monitor is not a general purpose hardware bus monitor since it only shows the bytes input and output by VEE. Any other programs that input/output to the bus do not log their I/O to the VEE monitor.

You can change the time zone that appears in this object by using the Date/Time Properties dialog box (Time Zone tab) in Control Panel. After changing the time zone setting, you must restart VEE for the change to take effect.

Location

I/O [image] Bus I/O Monitor

See Also

Advanced I/O and Instrument Manager.

To Monitor Bus Messages


Button

See Toggle Control.


by Name

A function which manages the arrangement of icons (minimized windows) in the VEE workspace.

Use

Use by Name to lexicographically organize icons (minimized windows) in the VEE workspace. Icons will be aligned and/or stacked at the bottom of the workspace. The lexicographical organization is based on the name appearing in the title bar of the icon.

Location

Window [image] Arrange Icons [image] by Name

See Also

Arrange Icons, by Position and Minimize All.


by Position

A function which manages the arrangement of icons (minimized windows) in the VEE workspace.

Use

Use by Position to physically organize icons (minimized windows) in the VEE workspace. The icons will be neatly aligned and/or stacked at the bottom of the workspace.

Location

Window [image] Arrange Icons [image] by Position

See Also

Arrange Icons, by Name and Minimize All.


Call

An object that executes a previously defined function.

Use

Use Call to execute (call) a previously defined UserFunction, Remote Function, or Compiled Function. Each input and output on the Call Function object corresponds to the respective input/output on the called function. Call Function inputs are passed to the called function by position, not by name. For example, the Call Function object may have as its inputs, A and B. But the called function may have as its inputs x and y. No matter, the first input (A) on Call Function is passed as the first input (x) of the called function. Only position is significant.

You may also call a UserFunction, Compiled Function, or Remote Function by including its name in any expression whose evaluation is delayed until run time. These include expressions in various objects, such as Formula, If/Then/Else, and Set Values, and expressions in Sequencer and I/O transactions. For example, you can call the function someUsrFunc by including the expression 2+someUsrFunc(a) in a Formula object.

You can select a function to call in two ways. You can execute Select Function in the object menu and select a name from a list of available functions, or you can type in the name directly in the Function Name field. In either case, Call will automatically configure its input and output pins for the called function, if that function is recognized by VEE.

Since VEE can Call UserFunctions (either locally created or imported from a library), Compiled Functions, or Remote Functions, it is possible to have two functions with the same name. Naming conflicts in a Call object are resolved by searching tokens in the following order:

1. Function names found in the same library as the calling object

2. Local UserFunctions

3. Imported UserFunctions, Compiled Functions, and Remote Functions. The precedence between these three is not guaranteed. To ensure the desired selection, include the library name in the call, using “dot” notation. For example, myLib.func().

The search order described above applies to Execution Mode VEE 5 and higher. In earlier Execution Modes, function names were searched in a different order. This difference in search order can have a dramatic effect on programs containing similarly named functions from different libraries. For more details, refer to “Using VEE Execution Modes” in Chapter 1 of the VEE Advanced Techniques manual.

Open View Parameters

Function Name - The name of the UserFunction, Remote Function, or Compiled Function to be called.

Object Menu

Edit UserFunction - Displays the editing window to the named UserFunction. When you're done editing, press the close or minimize button in the upper right corner of the window.

Select Function - Lists the functions currently known to VEE. Imported and Remote UserFunctions and Compiled Functions are listed by library name. When you select a function, the input and output pins on this object are automatically configured as defined by the called function. (This selection is grayed out if there are no UserFunctions or Compiled Functions.)

Configure Pinout - Automatically configures the input and output pins on this object as defined by the called function. (This selection is grayed out if the named function currently doesn't exist in VEE.)

Notes

The Call Function object acts much like a math function call. Any inputs act like the formal arguments of an internal VEE function, while any outputs act like return values from that function.

VEE 4 and higher Execution Modes - If Execution Mode in Default Preferences is set to VEE 4 or higher, the execution of Call Function is asynchronous -- a call to a UserFunction will "time-slice" with parallel threads. If the UserFunction is executing and gets called again from another part of the program, the second call will block until the original call returns. Calls to Compiled Functions and Remote Functions are synchronous (see below).

VEE 3 - If Execution Mode in Default Preferences is set to VEE 3, the execution of Call Function is synchronous -- a call to a function will suspend the execution of parallel threads until the function is completed.

Location

Device [image] Call

See Also

Delete Library, Edit UserFunction, Formula, Import Library, UserFunction, UserObject, and Properties (Object)

To Call a UserFunction in a Program


Call Stack

A View menu object that is useful for program debugging.

Use

Use the Call Stack dialog box as an aid in debugging your VEE program. The Call Stack dialog box displays the UserObject or UserFunction where the program is currently executing. In addition to identifying the currently executing object, the dialog box also shows the list or hierarchy of which UserObject or UserFunction invoked or called the currently executing object.

The Call Stack dialog box only displays useful information when the program is in a paused state. No information is available while the program is running. You can pause the program by any of several methods including Activate Breakpoint, Pause, etc.

Dialog Information

The Call Stack dialog box contains no user-editable fields or buttons. Just below the title bar of the Call Stack dialog box is a status field. This status field indicates the current status of the program. While the program is executing, the status bar will display: Program is running.

When the program is paused and Call Stack is enabled, three things will occur.

1. The Call Stack dialog box status bar will indicate the object that will be the next to execute in the program. This display takes the format:

Next Object: objectTitle(objectType)

Where objectTitle is the text displayed in the object's title bar, and (objectType) is the type of object that will execute, such as a Formula object.

2. The object that is identified in the status bar will be displayed and highlighted in the VEE workspace.

3. The hierarchy of calls that lead to the currently executing object or function is displayed inside the dialog box window. Clicking on any of the items listed in the hierarchy will bring that UserObject or UserFunction into the VEE workspace and highlight it.

Notes

Call Stack can be used in conjunction with the Step Into, Step Out and Step Over functions as an aid in debugging your VEE program.

Location

View [image] Call Stack

See Also

Activate Breakpoints, Find, Pause, Profiler, Run/Resume, Step Into, Step Out, Step Over, and Toggle Breakpoint

To View the Call Stack


Cascade

A function for managing windows in the VEE workspace.

Use

Use Cascade to arrange all opened (non-minimized) windows in the VEE workspace, as overlapping windows. Windows in the workspace will be stacked and offset down and to the right.

Notes

When multiple windows are open in the VEE workspace, it is possible to use the Ctrl key, in combination with other keys, to scroll through other non-minimized windows in the workspace.

Simultaneously pressing the Ctrl+Tab or Ctrl+F6 keys, moves the current top window to the bottom of the window stack. The next window down in the stack then becomes visible.

Simultaneously pressing the Ctrl+Shift+Tab or Ctrl+Shift+F6 keys moves the bottom window in the window stack to the top of the window stack.

Location

Window [image] Cascade

See Also

Arrange Icons, Close All, Minimize All, Tile Horizontally, and Tile Vertically.


Check Box

See Toggle Control.


Clean Up Lines

Redraws all lines in the Main program, UserObject, or UserFunction to route around objects using only horizontal and vertical line segments.

Use

If you disable Automatic Line Routing, connecting lines are straight from pin to pin (unless tacked). Select Clean Up Lines from time to time to tidy up the lines in your program.

Notes

Clean Up Lines is context sensitive; when it is selected from the UserObject or UserFunction Edit menu, only the lines within that particular context are affected. When selected from the menu bar Edit, only the lines in the root context (not in any UserObjects) are affected.

It may take several moments to completely re-route the lines in a complex program.

When a particular routing seems complex, move some of the objects apart to give the Auto Line Routing feature more room to find a shorter path.

After using Clean Up Lines, sometimes it is difficult to determine if two lines cross each other or if one line is connected to three places. Use Line Probe to display the endpoints of the lines.

Location

Edit [image] Clean Up Lines
or
UserObject (Object Menu) [image] Edit [image] Clean Up Lines

See Also

Default Preferences, Line Probe, and UserObject.


Clear All Breakpoints

Clears execution breakpoints.

Use

Use Clear All Breakpoints to delete all breakpoints from objects when you are finished debugging.

Location

Debug [image] Clear All Breakpoints

See Also

Activate Breakpoints, Properties (Object), and Toggle Breakpoint.

To Control Breakpoints


Clone (Object Menu)

Duplicates this object and places a copy of the object in the Paste buffer.

Use

Use Clone to create a copy of the object. Clone makes a duplicate object immediately available and puts a copy of the object in the Paste buffer. Clone copies all the attributes of the cloned object including terminals, parameters, and size.

Notes

To copy multiple objects at the same time, select the objects using CTRL-Left Button or Edit [image] Select All, then use Edit [image] Copy and Edit [image] Paste (or CTRL-c and CTRL-v).

Each Clone overwrites the previous content of the Paste buffer.

Each Clone of a UserObject is an independent copy of all objects in it. Changing one copy does not affect any others.

Each Clone of an Instrument Panel reflects a different state of the same instrument.

Short Cuts

Select object(s) to be cloned. Place the mouse over the object(s) and press and hold CTRL-Left Button. Drag the cloned object(s) to the desired location (you must move a distance of at least 65 pixels before the object(s) will be cloned).

Location

On each object menu [image] Clone

See Also

Object Menu, Cut (Object Menu), Copy, Paste, and Replace.


Close All

A function for managing windows in the VEE workspace.

Use

Close All will close all open or minimized windows (icons) and leave an empty VEE workspace.

Location

Window [image] Close All

See Also

Arrange Icons, Cascade, Minimize All, Tile Horizontally and Tile Vertically.


Collector

An object that collects data and outputs an array.

Use

Use Collector to create a one-dimensional array from scalar input data, or to create an output array from collected input arrays. If the input arrays have "n" dimensions, the collector can either output an array of n+1 dimensions, or it can output a one-dimensional array (with the input data "flattened"). When all data has been collected, activate the XEQ pin to output the resulting array.

Open View Parameters

Output Shape - Choose one of two selections:

n+1 Dim Array - The input signals (arrays of n dimensions) are collected and output as an array of n+1 dimensions.

1 Dim Array - The input signals, regardless of shape, are "flattened" by the collector and output as an Array 1D.

(For scalar input data, the output shape will be "Array 1D" regardless of the selection.)

Object Menu

Clear - Clears the contents of the Collector.

Notes

Because XEQ is required on the Collector you cannot add another XEQ pin or delete it.

The Collector continues to collect the input data until the XEQ pin is triggered.

The Collector has two inputs; one for the data coming in (any shape and type); the other tells the object when to execute. The Collector accepts multiple pieces of data on the first data input pin, and collects the data until the XEQ pin is activated. Then the object copies the full set of data to its output pin and propagates its output. The output data pin is never propagated until the XEQ pin is activated. Once the data propagates, the Collector clears its internal buffer and again starts collecting data. The type of the output signal is determined by the type of the first data container coming in after each XEQ or Clear. All subsequent containers are coerced to the type of the first one. If coercion fails, an error is reported.

The shape of the output signal depends on the Output Shape selection:

n+1 Dim Array operation - If you select n+1 Dim Array for the Output Shape, the Collector will collect the data coming into its Data pin, and will output an array of one dimension higher than the number of dimensions of the input data. Each input signal must be the same size and shape as the first input signal, until the XEQ pin is triggered. No mapping information is copied -- the output signal is not mapped.

For example, if the first input data is a Real64 1D array, 10 long, each subsequent input signal must be a 1D array, 10 long, of a type that can be coerced into Real64, until the XEQ pin is triggered. The output signal will be a Real64 2D array with 10 columns and n rows, where "n" is the number of times data was sent to the Data input pin before XEQ was triggered.

1 Dim Array operation - If you select 1 Dim Array for the Output Shape, the Collector collects the data coming into its Data pin and outputs an Array 1D, regardless of the shape of the input data. Scalar or Array 1D data is appended to the end; multi-dimensional arrays are flattened into an Array 1D and then appended.

For example, if the data in is a scalar Real64 value 1.2, then a scalar Int32 value 34, then XEQ is activated, it will output a Real64 Array 1D, two long, with the values [1.2, 34.0]. Then, if it is activated with several Complex data containers, it will output a Complex Array 1D.

Note that for scalar inputs of any type, the Collector generates the same output signal regardless of the Output Shape selection.

Since Waveform and Spectrum signals do not support more than one dimension, they are not allowed as inputs when the Collector is operating in the n+1 Dim Array mode. To collect Waveform or Spectrum data into a 2D array, unbuild the data first and then collect it into a 2D array. Note that the mapping information will be lost.

Since Record and Coord containers only support up to 1D arrays, only scalar Record or Coord containers are allowed as inputs when the Collector is operating in the n+1 Dim Array mode.

Enum inputs are converted to type Text before being placed into an array.

For Record inputs, the field names, types and sizes must match.

The Collector begins with its internal buffer cleared. It clears its internal buffer of collected data each time the XEQ pin is activated. You can add a control input for Clear and programmatically clear the Collector data before XEQ is activated. Subsequent activation of the data input starts the collecting over again. The output is not propagated until XEQ is activated.

If the XEQ pin is activated, and the data input has not been activated with non-nil data since the last clear, the Collector will output a nil signal in VEE 3 execution mode. If you are in VEE 4 or higher execution mode and the input data type is known, you will get a zero-element-array of that data type. If the input data type is not known, the Collector will output a zero-element-array of type Int32.

Location

Data [image] Collector

See Also

Allocate Array, Concatenator, Get Values, Set Values, Sliding Collector, and Properties (Object)

To Collect Data into an Array


Color Alarm

An object that displays a different color and text string, depending on the value of the Scalar input.

Use

Use Color Alarm as an "LED" that displays a color and a text string, based on an input value and user-defined ranges. The input value may also be displayed in an optional digital numeric field.

Properties

ClearAtPreRun - When the property is True, the contents of the Color Alarm are cleared at PreRun. Default is True.

 ClearAtActivate - When the property is True, the contents of the Color Alarm are cleared at Activate. Default is True.

Shape - Selects the shape of the Color Alarm display. Default is Circular.

 Show 3-D Border - If the property is True, the Color Alarm is shaded to give it a 3-dimensional look. If the property is False, the Color Alarm is displayed as one flat color; this is useful when you need very small "LED" displays, you need the object to operate a little faster, or you don't like the 3-D look.

 ShowDigitalDisplay - If the property is True, a digital display of the input value is displayed at the bottom of the open view of the object. If the property is False, the digital display is not displayed and the object operates faster. Default is False.

HighColor - Specifies the color used for the highest range (i.e., greater than High Limit).

 High Text - Specifies the text displayed on the Color Alarm when the HighColor is used. Default is High.

 High Limit - Defines the numeric lower limit for the highest range. This value must be greater than or equal to the Low Limit.

 MidColor - Specifies the color used for the middle range (i.e., less than or equal to High Limit and greater than Low Limit).

 Mid Text - Specifies the text displayed on the Color Alarm when the MidColor is used. Default is Mid.

 Low Limit - Defines the numeric upper limit for the lowest range. This value must be less than or equal to the High Limit.

 LowColor - Specifies the color used for the lowest range (i.e., less than or equal to the Low Limit).

 Low Text - Specifies the text displayed on the Color Alarm when the LowColor is used. Default is Low.

Notes

The input data must be Scalar and able to be converted to Real64 (Complex, PComplex, Spectrum, and Coord must be first "unbuilt".)

The Low Limit must be less than the High Limit.

To use only 2 ranges of color, set the Low Limit equal to the High Limit.

To use only 1 color, set the LowColor, MidColor, and HighColor to the same color.

Location

Display [image] Indicator [image] Color Alarm

See Also

AlphaNumeric, Fill Bar, Logging AlphaNumeric, Meter, Tank, and Thermometer.

To Show a Color Alarm


Comparator

An object that compares two values then outputs the coordinates where the comparison fails.

Use

Use the Comparator to compare a numeric test value, such as a Waveform or Coord, with a reference value. If one or more of the values in Test Value fails the comparison, a Coord Array 1D is output on the Failures output pin and the Failed output pin activates. If all values pass the comparison, an empty Coord is output on the Failures output pin and the Passed output pin activates.

The independent field (x) in the Failures output Coord Array 1D contains the index or mapping of each failure point. The dependent field (y) contains the Test Value that failed.

Open View Parameters

Test Value == Ref Value - Change the comparison operator by clicking on it and selecting the function from the list that is displayed. Default is ==.

Notes

The Comparator compares only numeric values, even if they are in Text objects. The Comparator cannot compare text strings.

The shape of the Ref Value is treated as the same shape as the Test Value. For example, a Scalar Ref Value of 3 is treated as an Array 1D (with all elements equal to 3) when the Test Value is an Array 1D. If arrays are compared, their size and number of dimensions must match.

If Test Value is a scalar, Ref Value must be a scalar.

If Test Value is an unmapped array, any mappings on Ref Value are ignored.

If Test Value is a mapped array, the independent variable of the Failures output Coord (x) is the mapping of the element that failed.

If Test Value is a Coord, only the dependent variable of the Coord is used in the comparison. The Failures output Coord contains the Coord value that failed.

All tests use an "almost equal" algorithm that checks equality or inequality to at least six significant digits. If the Ref Value is an array with more than one element, a value for "virtual zero" is derived from the reference data's magnitude. Any data points with a value of "0" must be matched with this "virtual zero" value.

Location

Device [image] Comparator

See Also

Allocate Array, Build Arb Waveform, Coord, If/Then/Else, Set Values, and Properties (Object)


Complex

An object that outputs constant Complex scalars or an Array 1D.

Use

Use Complex to set a Complex Constant or to get user input. Click on the entry field to enter a value.

Example

To use Complex as a prompt on a panel, change the name of the Complex object to a prompt such as Enter the AC voltage:. The user fills in the requested information in the entry field.

Type in (2,10/27) to have the Complex constant evaluate the formula and display the answer.

Properties

 DataShape - Sets the initial data shape of the value(s) to be output with this object. Default is Scalar.

 ArraySize: - When 1D Array is selected, ArraySize sets the length of the array. Default is 10.

 ArraySizeFixed - When the property is True, the array cannot have lines added or deleted. This selection is only available if 1D Array is selected.

 ShowArrayIndices - When the property is True, each line in the entry field is indexed. This selection is only available if 1D Array is selected. Default is True.

 Wait for Input - When the property is True, the object does not operate until the object's value is changed. When the property is False, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When the property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

 InitialValue - Specifies the value to be set. Default value is (0, 0).

 InitializeAtPreRun - When the property is True, the InitialValue is set at PreRun time. Default is False.

 InitializeAtActivate - When the property is True, the InitialValue is set at Activate time. Default is False.

 NumberFormat: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Sat 01/Jan/2003 17:01:38). Default is Standard.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value(s). This input requires a Complex value, either a Scalar or an Array 1D. The Constant is reconfigured to match the shape of the incoming data.

The Reset input allows you to programmatically set the value(s) to zero. If the Constant is configured as an Array 1D, all values are set to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the value can be changed in the object’s open view.

Note that the InitialValue field is always a scalar, even if Complex is configured to be an array.

You can enter just the real and imaginary values, separate them with a comma, and let VEE format the number for you.

Location

Data [image] Constant [image] Complex

See Also

Alloc Complex, Build Complex, Default Preferences, Constant, Coord, Date/Time, Selection Control, Int16, Int32, PComplex, Real32, Real64, Text, Toggle Control, UInt8.

To Use a Data Constant


Complex Plane

An object that displays continuously-generated complex data as a Cartesian plot.

Use

Use Complex Plane to display Complex, PComplex, or Coord data values on a real versus imaginary axis.

Open View Parameters

These are the default open view parameters. Their use, and the availability of other parameters, is controlled by selections on the object menu and in the Properties dialog box (object menu [image] Properties).

Imag - The name of the Y (imaginary) axis.

Trace1 - The name of the first trace.

Real - The name of the X (real) axis.

Object Menu

Auto Scale [image] - Clicking these menu items immediately re-scales the display to show the entire trace. (Can be added as control pins, or set using the Scales properties tab to automatically re-scale the display after data is collected.)

Auto Scale - Automatically scales both axes.

Auto Scale X - Automatically scales the X axis.

Auto Scale Y - Automatically scales the Y axis.

Zoom [image] - Scales the display.

In - Magnifies the display to contain only the rectangular region that you selected with the pointer. You select the region after selecting this feature by dragging on the graph area. This action outlines the information with a "rubber band" box.

Out 2|5|10|20|50|100X - Expands the scales of the display by a factor in both the X and Y directions about the center.

Clear Control [image] - Parameters that specify when to clear the display.

Display - Clears the displayed trace(s). This parameter may be added as a control input.

Next Curve - Resets the pen to display the next curve in a family of curves (data from the next time the display operates) without clearing the previous curve. Next Curve must be selected (or activated) before each new curve in the family. This parameter may be added as a control input.

Center Markers - If markers are available, brings them to the center of the visible part of the trace. This is useful if you've scrolled the display and markers are not visible.

Add Right Scale - Adds up to two additional Y-axis scales to permit traces to have different scale ranges. After adding a right scale, you may add a terminal for its input (object menu [image] Add Terminal [image] Data Input). Then set its properties using the Traces and Scales tabs on the Properties dialog box.

Print - Presents the Print dialog box. Pressing OK prints or plots a copy of the device's entire display on the selected output device. Print may be added as a control input.

Properties

Name - Assigns a variable name to the display. By entering a name, you can programmatically read marker values if they are turned on. The variable is an Object data type, and it is local to the context where the display exists. See Notes for details.

ClearAtPreRun - When the property is True, the display is cleared at PreRun time. Default is True.

 ClearAtActivate - When the property is True, the display is cleared at Activate (context entry) time. Default is True.

ShowTracesLegend - In the open view, controls the visibility of the trace names and colors. Use EditTracesAndScales to control the edit-button function of the trace legends. Default is True.

 ShowScalesLegend - In the open view, controls visibility of the scale names. Use EditTracesAndScales to control the edit-button function of the scale legends. Default is True.

 ShowScaleLabels - In the open view, controls visibility of the values labeling the scale axes. Default is True.

 ShowScrollBars - In the open view, controls visibility of the scroll bars on the X and Y scales. Default is True.

 ShowAutoScaleButton - In the open view, controls visibility of the Auto Scale Button. Default is False.

 EditTracesAndScales - In the open view, controls the edit-button function of the trace and scale properties. When enabled, click on an individual trace or scale name to edit its properties. Default is True. Use ShowTracesLegend and ShowScalesLegend to control visibility of the trace(s) and scale(s) names.

GridType - Default is Axis.

NumMarkers: - Allows you to find the exact value of a data point on the displayed curve. If the data is plotted on a log scale, the values shown on the marker are the linear data points.

To move markers to a different trace, go to the open view and click on the button to the left of the marker values near the bottom of the display. The button cycles through the different line types and colors of the different traces.

 MarkersInterpolate - When the property is True, you can place markers between the displayed data points. The marker values displayed are calculated by linear interpolation. Default is False.

 MarkerColor - The color of the markers

DisplayBackColor - Allows you to select the color of the display area from a palette. You can select different colors when the display appears in the detail view and the panel view. The default Background color is set in Default Preferences on the Colors tab for Screen Element: Graph Background.

 ScaleLabelFont: - Allows you to select the font of the scale labels from the list of available fonts on your system. The default font for scale label text is set in Default Preferences on the Fonts tab for Screen Element: Graph Scale Label Text.

Traces Category:

Name - The name of the trace that is displayed to the left of the graph area and the name of the corresponding input terminal.

Color - The color of the trace. Each added trace has a different color than the existing traces. Default for the first trace is yellow.

LineStyle - The format of the line connecting data points. Default is a continuous line.

PointStyle - The symbol that marks each data point. To show unconnected data points, select the single dot LineStyle format and the desired PointStyle symbol. Default is a dot.

Scale - If it exists for more than one Y scale, choose which scale this Trace is scaled by.

ScaleNumberFormat: (a property that appear for the X and Y scales, and for any additional Y scales.)

Scales Group:

Show Scale: - If you have multiple Y scales, a selection (using a check box) to specify if the end points and an axis of each additional right scale is displayed to the right of the graph area.

Scale Name: - The names of the scales appearing in the open view.

Automatic Scaling: - Controls whether the display automatically re-scales to show the entire trace immediately after it receives data. Default is True. If this is turned off, you can re-scale the display by using the Auto Scale button on the General tab, in the Layout group, or the Auto Scale command on the object menu.

Maximum: - The maximum values of the scales.

Minimum: - The minimum values of the scales.

Label Spacing: - Controls which tic marks are labeled with the scale values. Default for X scale is Every Other Tic; default for Y scale(s) is Every Major Tic.

Mapping: - The way the x and y data is mapped to the display. The mapping may be linear or log. To make a log-log plot, change both X and Y axes to Log. Default is Linear.

Log Cycles: - The maximum number of decades shown (counting down from the maximum x and y values) when Automatic Scaling is on. Log Cycles is only used when the Mapping is Log. Log Cycles is useful when a trace contains a large dynamic range in the data. Default is 4.

Scale Color - The color of any background grid or tic marks. Default is Gray.

Global Format - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Sat 01/Jan/2003 17:01:38). Default is Standard.

The X and Y marker values take on the same number format as the scale to which they are attached. The delta marker values for X and Y use the default number format unless you use the Time Stamp format. Then, if both markers 1 and 2 on the X scale, or both markers on the Y scale are using the Time Stamp format, the delta marker values use the Delta Time format.

Notes

Inputs must be Scalar or Array 1D of type Complex, PComplex, or Coord.

Input data of type Coord is plotted by simply using its x and y values without first being converted to type Complex.

Add traces with the Add Terminal [image] Data Input object menu selection. Up to twelve traces are allowed.

When the AutomaticScaling property is True (Scales category), the program executes faster if a complete set of data is sent to the display. Then, the display automatically re-scales once. If a program sends one data point at a time to the display, the display may automatically re-scale after each data point, which will slow down program execution. In this case, use a Collector object to create an array, then send the array to the display.

Adding Control Inputs

You can add a Title control input pin, which sets the title bar name to the specified text value. This allows programmatic control over the title shown when the display is printed.

You can add a Traces control input pin. The control input data must be an array of records (or a record scalar if you only want to control one trace). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A field named TraceNum with an integer value (1 is the first trace). The TraceNum field is required. An error occurs if it is omitted.

One or more of the following fields:

Name

Pen

LineType

PointType

The Name field must have a text value. The Pen, LineType and PointType values must be integers from 0 to n, where 0 draws nothing and n is the number of choices available.

You can add a Scales control input pin to control the scales parameters listed above. The control input data must be an array of records (or a record scalar, if you only want to control one scale). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A Text field named Scale with a value X, Y (or Y1), Y2, or Y3. The Scale field is required. An error occurs if it is omitted.

One or more of the following fields:

Name - Changes the scale name in the open view. Must be a text value.

Min - Sets the X scale minimum. Must be an integer or real value.

Max - Sets the X scale maximum. Must be an integer or real value.

Mapping - Must have a text value of Linear or Log.

AutoScale - Controls automatic scaling. Must have a text value of On or Off.

Refer to "Using Records and DataSets" in VEE Advanced Techniques for further information.

Programmatically Setting and Reading Marker Values

You can programmatically get and set marker values. To prepare the display, open its Properties window. Enter a value for Name. The value for Name implicitly declares an Object variable that is local to the display’s context. Next, turn on a setting in the Markers category. VEE assigns the following properties to the markers’ X and Y positions, including the delta values. (Marker1 points down; Marker2 points up.)

Marker1X (gets the position as a Real64)

Marker1Y (gets the position as a Real64)

Marker2X (gets the position as a Real64)

Marker2Y (gets the position as a Real64)

MarkerDX (gets the position as a Real64)

MarkerDY (gets the position as a Real64)

Marker1 (gets/sets the position as a Coord)

Marker2 (gets/sets the position as a Coord)

The Marker1 and Marker2 properties can be used to read the current marker position or move the marker to a new position. All other marker properties are read-only. If you attempt to move the marker to a coordinate that is not on the trace, the marker will "snap" to the closest point that is on the trace.

In your program, enter one or more expressions in a Formula object to set or read the marker values. Each expression must contain the display Name and the marker property of interest. Marker property names are not case-sensitive. If the display’s Name is XY, and Delta Markers is turned on, the following expressions will read all the available marker values, assigning them to the variables a through f as Real64 scalars:

a = XY.Marker1X

b = XY.Marker1Y

c = XY.Marker2X

d = XY.Marker2Y

e = XY.MarkerDX

f = XY.MarkerDY

You can assign the display Name to a global variable. Add an assignment expression to your program in a Formula object, and declare the global using the Declare Variable object. As an example, assume you declared the variable globalXY as a global, and set its Type to Object. Then, in the context where the display exists, add this expression to your program:

Set globalXY = XY

This lets you read the display’s marker values from another context in the program using an expression such as:

a = globalXY.Marker1X

As you develop a program, you may want to include a way to pause the program so you can manually reposition the markers before the program reads their values. One way to pause a program is to add a Confirm (OK) button between the display’s sequence output and the Formula object’s sequence input. Alternately, you may want to position the markers programmatically.

Location

Display [image] Complex Plane

See Also

Magnitude Spectrum, Polar Plot, Strip Chart, Waveform (Time), X vs Y Plot, XY Trace, and Default Preferences.

To Set Markers in the Display, To Get and Set Marker Properties


Component Driver

An instrument control object that reads and writes values to components you specifically select. No control panel is displayed for the instrument, which differs from the Panel Driver object.

Use

Use a Component Driver to control an instrument by setting the values of only a few components at a time. Before you can use a Component Driver, the instrument driver for the desired instrument must be installed.

To add a Component Driver object to the VEE work area, click on I/O [image] Instrument Manager... to display the Instrument Manager dialog box. Check the list of configured instruments to see if there is an entry for the instrument you want to use:

If the instrument you want is in the list, and is properly configured:

1. Click once on the instrument entry to highlight it.

2. Click on the Component Driver button.

If the instrument you want is in the list, but you need to change its configuration, click on Properties…, change the configuration using the dialog boxes, save the configuration (click OK), and then follow steps 1 and 2 above.

If the instrument you want is not in the list, click on Add…, configure the instrument using the dialog boxes, save the configuration (click OK), and then follow steps 1 and 2 above.

For information about the configuration dialog boxes, refer to Instrument Manager and Instrument Properties.

Notes

Component Drivers may be operated with Live Mode off. This allows you to run your program without communicating with the instrument, whether or not the instrument is connected to the computer. You must set Live Mode to on (refer to Instrument Properties) before your program will communicate with the physical instrument.

To be useful, at least one input or one output must be added to the Component Driver object. More than one input or output can be added and both inputs and outputs may appear on the same object. An input performs the set actions for the component. An output performs the get actions. Control pins are available as inputs to initialize the component, programmatically change the device address, and set the timeout value.

Location

I/O [image] Instrument Manager...

See Also

Direct I/O, Instrument Manager, Instrument Properties, Panel Driver, Add Terminal, and Properties (Object)

To Use a Component Driver Object

Also, refer to the chapter titled "Using Panel Driver and Component Driver Objects", in the VEE Advanced Techniques manual.


Concatenator

An object that outputs the concatenation of all its input data into an Array 1D.

Use

Use Concatenator to combine two or more data elements into the elements of an Array 1D. The size of the resultant array is the sum of the sizes of the inputs. Data inputs can be added to allow three or more containers to be concatenated.

Enum inputs are converted to type Text before concatenation occurs.

Notes

The output data type is the highest type of all the input data types. If any input is an array of more than one dimension, the array is flattened (row major) into an Array 1D for the concatenation.

To concatenate multiple lines of Text into one line, use Accumulator.

Nil inputs are ignored. This is different than the concat(x,y) function which operates within the formula box. In the formula box, all nil inputs are automatically converted to Real64 scalars with value 0. Thus, concat(a,b), where a is nil and b is an Int32 scalar value 5, results in the Array 1D, two long of Real64 with values [0, 5]. The Concatenator object with two inputs with nil and an Int32 scalar value 5 outputs an Int32 array one long with value [5].

If the first value (first data input) is mapped, the other input values may be either mapped with the same point spacing, or unmapped. The result will be mapped from the Xmin to Xmin + dx * N where "Xmin" is the minimum value of the mapping of the first array value, "dx" is the distance between two consecutive points in the first value, and "N" is the size of the result array.

Location

Data [image] Concatenator

See Also

Accumulator, Allocate Array, Collector, Set Values, Sliding Collector, and Properties (Object)

concat(x,y)


Conditional

A menu item.

Use

Use Conditional to access the following conditional branches:

If A == B

If A ~= B

If A != B

If A < B

If A > B

If A <= B

If A >= B

Use Conditional objects to decide which subthread to run.

Notes

Note the difference between Comparison items under Device [image] Functions & Object Browser and Conditional items. Comparisons are formulas with output 0 or 1; Conditionals are If/Then/Else and have two or more outputs, of which one fires.

Note that the return value of Logical items AND, OR, XOR, and NOT in the Device [image] Function & Object Browser... is of type Int32 and is the same shape as the operands. This is different than the conditionals such as == that always return a scalar.

The logical operators are defined for type text only in the sense of whether the string is null or not. That is, "0" and "1" are logically true since they are non-null strings, while "" is false. Therefore, "zoo" AND "" (null string) is logically false since the second string is null. Remember that when comparing a Text type to a non-string type, the latter is promoted to a Text type. This means that "zoo" AND "0" is true since the real 0 is promoted to the string "0" and, since both strings are non-null, the AND expression is true, returning 1.

Location

Flow [image] Conditional

Then select the desired conditional branching object.

See Also

If A ~= B, If A == B, If A != B, If A < B, If A > B, If A <= B, If A >= B, and If/Then/Else.

Comparison, Triadic Operator, and Function & Object Browser.

To Branch within a VEE Program


Confirm (OK)

See OK.


Constant

A menu item.

Use

Use Constant to access the following input constants:

Text

UInt8

Int16

Int32

Real32

Real64

Coord

Complex

PComplex

Date/Time

Record

Notes

All Constant objects, except Text, support the use of arbitrary formulas in the input box. (Global variables are allowed only if they have been set in a previous execution of the program. Click on Globals in the Program Explorer to see what variables exist.) The formula is parsed and evaluated immediately after it is typed and entered into the edit field. The resulting Scalar number is used as the value for the Constant. Constants do not support input variables like the Formula object does, therefore you cannot use input variable names in the formulas. The typed in formula must evaluate to a Scalar value of the proper type or of a type that can be converted to the Constant you are using.

The syntax supported is the same as in the Formula object, but with some exceptions. You cannot use array building syntax ([, ]) operators to construct an array, since they would return a non-Scalar and the return value must be Scalar. Also, you cannot use input name variables in Constant objects.

In general, the use of any of the dyadic operators, parentheses for nesting, function calls, and the predefined numeric constant PI (3.1416...) is allowed.

The Variant type does not appear in the Constant object. The only way to create a Variant data type is use Declare Variable and select type "Variant."

Examples

When you type (2, @PI/2) into a PComplex object, it is evaluated and returns (2, @90) (if Trig Mode is set to Degrees).

When you type 14 + exp10(3) into a Real64 object, it is evaluated and returns 1014.

When you type (1, 2) into a Real64 object, an error is returned because VEE does not allow the conversion from Complex to Real64.

Location

Data [image] Constant

See Also

Complex, Coord, Date/Time, Int16, Int32, PComplex, Real32, Real64, Record Constant, Selection Control, Text, Toggle Control,UInt8.

To Create a Record Constant

To Create an Array Constant

To Use a Data Constant


Continuous

A menu item.

Use

Use Continuous to access the following objects:

Int32 Slider

Real64 Slider

Int32 Knob

Real64 Knob

Location

Data [image] Continuous

See Also

Int32 Knob, Int32 Slider, Real64 Knob, and Real64 Slider.

To Use a Data Slider and Knob


Control Input (Object Menu)

Adds an asynchronous control input terminal to the object.

Use

Use Control Input to add asynchronous inputs, such as Reset or Clear, to objects.

After selecting Control Input, choose the control to add from a dialog box. On some systems, the terminal for a control input is a different color than for a data input.

Notes

Control inputs are not available on all objects.

Activation of a control input pin does not cause the object to operate, it only forces that particular action to happen (for example, Clear).

Often the actions performed by a control input may also be done from a selection on the object menu or by a button on the open view.

Location

On each object menu [image] Add Terminal [image] Control Input

See Also

Add Terminal, Data Output (Object Menu), Delete Terminal, and Object Menu.


Coord

An object that outputs a constant Coord Scalar or Array 1D.

Use

Use Coord to set a Coord constant or to get user input. Click on the entry field to enter a value.

Properties

DataShape - Sets the initial data shape of the value(s) to be output with this object. Default is Scalar.

 ArraySize: - When 1D Array is selected, ArraySize sets the length of the array.

 ArraySizeFixed - When the property is True, the array cannot have lines added or deleted. This selection is only available if 1D Array is selected.

 ShowArrayIndices - When the property is True, each line in the entry field is indexed. This selection is only available if 1D Array is selected. Default is True.

 Wait for Input - When the property is True, the object does not operate until the object's value is changed. When the property is False, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When the property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

InitialValue - Specifies the value to be set. Default value is (0, 0).

 InitializeAtPreRun - When the property is True, the InitialValue is set at PreRun time. Default is False.

 InitializeAtActivate - When the property is True, the InitialValue is set at Activate time. Default is False.

Number Format - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Sat 01/Jan/2003 17:01:38). Default is Standard.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value(s). This input requires a Coord value, either a Scalar or an Array 1D. The Constant is reconfigured to match the shape of the incoming data.

The Reset input allows you to programmatically set the value(s) to zero. If the Constant is configured as an Array 1D, all values are set to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the value can be changed in the object’s open view.

Note that the InitialValue field is always a scalar, even if Coord is configured to be an array.

Coords can contain more than two fields. For example, a Coord with three fields is (x, y, z).

The mathematic operations on Coords operate on the dependent variable only, that is, they operate on the y value of the (x, y) pair.

Example

Type in 2, 5 + exp10(2) to generate the Coord constant (2,105).

The Coord Array 1D can be used to define bounding envelopes on waveforms and as input to Comparators for waveforms. Use an Array 1D of Coords to define the limiting points on the bounding waveform. The limiting points are the endpoints of line segments that define the limiting waveform shape. Then send this array through the Build Arb Waveform box to create a limiting waveform. The new bounding waveform can be used in the Comparator box as one of the inputs to generate the points that fall outside the bounding waveform.

You can use the bounding waveform in the clipUpper or clipLower function to clip the waveform to the bounding limits.

To use Coord as a prompt on a panel, change its title to the desired input and turn Wait for Input on. The user then supplies the requested input before the Coord object operates.

Location

Data [image] Constant [image] Coord

See Also

Complex, Constant, Date/Time, Int16, Int32, PComplex, Real32, Real64, Selection Control, Text, Toggle Control, and UInt8.

To Use a Data Constant


Copy

Places a copy of the selected objects in the Paste buffer, and on the Clipboard in Windows 98 and NT.

Use

Use Copy and then Paste to make multiple copies of a set of selected objects.

Notes

Copy is only available after objects are selected.

Each Copy overwrites the previous contents of the Paste buffer.

Copied objects can be pasted into another location in the same program, or into another VEE session. In Windows 98 and NT, copied objects can be pasted into other applications.

To copy a single object, use the Clone selection from its object menu. Copy is different from Clone in that Clone gives you a duplicate set of objects immediately and Copy only places the objects in the Paste buffer for later use.

Location

Edit [image] Copy

See Also

Clone (Object Menu), Cut, Object Menu, Paste, Replace, and Select All.


Counter

An object that displays and outputs the number of times its data input pin has been activated.

Use

Use Counter to keep a running count. Counter keeps a running count of the number of times an input has been activated by a previous object's output. The Counter output is a Real64 scalar.

Object Menu

Clear - Clears the contents of the Counter.

Notes

The data input for Counter does not require any particular type data and even counts an input with a nil value. It can also be cleared by activating the input Clear control pin.

The value of the Counter, a Real64 scalar, is available at the Counter output.

Location

Device [image] Counter

See Also

Accumulator and Properties (Object)


CreateInstance

Create Instance(AssemblyName, ClassName)

Creates a new instance of the .NET object specified by AssemblyName and ClassName, and returns a reference to it. You may specify additional parameters for invoking a particular constructor of the object.

Use

Use CreateInstance to create a .NET object in your program. You should never have a need to write the CreateInstance formula yourself. Instead, open the Function & Object Browser, select the assembly, the namespace, the class type, the appropriate constructor, and use the Create Instance button to create the formula template. This is the best way to save you some typing and avoid mistakes.

The AssemblyName is the name of an assembly that you have already referenced through the .NET assembly reference dialog box. The ClassName is the name of a class qualified with its namespace.

CreateInstance takes any number of additional parameters for invoking a particular constructor of the object. Again, use the Function & Object Browser to select and create the formula template.

Example

This example creates an instance of System.Collections.Hashtable class and returns a reference to it.

Set hashtable = CreateInstance("mscorlib", "System.Collections.Hashtable");

Notes

VEE must be set to VEE 5 (or higher) execution mode for .NET support (Default Preferences).

The assembly reference for a .NET type must be made available to VEE before you can create expressions which use that .NET type (Device [image] .NET Assembly References…).

You will notice that not all .NET types listed in Function & Object Browser have constructors. This is normal. For types without constructors listed, you do not need to call CreateInstance to access the .NET object.

Also, to invoke the static members of a .NET type (those with the [image] icon), you do not need to call CreateInstance first. For example, to invoke the static property Now of System.DateTime, you do not need to construct an object instance first.

Location

Device [image] Function & Object Browser

Type: Built-in Functions

Category: .NET Automation

Member: CreateInstance

See Also

See example programs in the .NET example directories

.NET Example Programs


Create RunTime Version

Saves a secured version of the program that cannot be edited.

Use

Use Create RunTime Version to lock the main panel view of a program after it is completed and before users have access to it. Access to the detail view in a secured item is no longer available.

When you use Create RunTime Version, you are prompted for a file name to call the secured version. The secured file will then be saved with the name <filename>.vxe. To run a secured file, select File [image] Open... and change the Files of type: selection to Secure VEE Programs (*.vxe) and select the file. Many of the VEE development tools (Edit, Debug, ...) are not available when a secured file is loaded.

Notes

A secured program loads and runs faster than an unsecured program.

Use Default Preferences to set the file format for secured programs to ASCII or binary. The binary format, the default setting, saves files that are smaller in size and will load faster.

For added security, VEE cannot merge .vxe files into another program. However, VEE will import libraries saved as .vxe files.

Location

File [image] Create RunTime Version...

See Also

Default Preferences, UserFunction, UserObject.

To Secure a Program


Create UserObject

Puts selected objects into a UserObject.

Use

Use Create UserObject to group objects together logically and physically. Select the objects to be included and then select Create UserObject. The UserObject created contains the selected objects.

A UserObject operates just like any other object; no objects operate inside a UserObject until all data inputs to the UserObject are activated. All operations inside the UserObject must be complete before the data output is activated.

The maximize button on the right side of the title bar of the open view increases the size of the UserObject to the size of the VEE work area.

If the objects in the UserObject were connected to other objects before they were in the UserObject, terminals are automatically created on the UserObject to maintain the connections. Objects inside the UserObject can not be connected to objects outside the UserObject, without first adding input and output pins from the UserObject menu.

Notes

If no objects are selected, Create UserObject is not available. To create an empty UserObject, select UserObject from the Device menu. You can place new objects inside the UserObject after it has been created by moving them inside the UserObject window. Placing existing objects inside a new UserObject must be done with Cut and Paste.

It is convenient to save UserObjects of common functions (using Save Objects...) to create a library of functions to be used again.

When you Step Over a UserObject the entire context of the UserObject runs. Use Step Into to run individual objects within the UserObject and Step Out to run all remaining objects and exit the UserObject.

Location

Edit [image] Create UserObject

See Also

Add To Panel, Default Preferences, Create RunTime Version, Select All, Step Into, Step Over, Step Out, Unpack (Object Menu), UserFunction, and UserObject.

To Create and Use a Library of UserObjects

To Create a UserObject from Objects in a Program

To Create a UserObject in a Program


Create UserFunction

An Edit menu selection that allows you to create a UserFunction from user-selected VEE objects.

Use

By using Create UserFunction, you can collect a number of functionally related VEE objects together into a separate UserFunction. Converting related VEE objects into a UserFunction can be especially useful when those same objects are used repeatedly in your VEE program.

To create a UserFunction, select the VEE objects you wish to include in the function by holding down the CTRL key, and simultaneously clicking on the objects using the left mouse button. The selected objects will be highlighted with shadows.

After you have selected the objects you want to include in the function, then select Create UserFunction from the Edit menu. The Create UserFunction dialog box will appear. The Function Name: field in this dialog box will allow you to enter your own descriptive name for the UserFunction you are about to create. If you choose not to enter a new UserFunction name, the name will default to UserFunction1. Once you have selected a name for the new UserFunction, click on the OK button on the Create UserFunction dialog box.

After you have created the new UserFunction, all of the objects you selected will now appear in a new UserFunction window. The new window will have a title bar containing the UserFunction name you assigned. Additionally, a Call to this new UserFunction will appear as a Call object in the VEE window where the new UserFunction was created.

Notes

If no VEE objects have been selected in the window that is currently active, the Create UserFunction menu selection will be grayed out (unselectable).

Location

Edit [image] Create UserFunction

See Also

Call, Edit UserFunction, Import Library, UserFunction, and UserObject.

To Create a UserFunction from Objects in a Program

To Create a UserFunction in a Program


Cut

Deletes the selected objects and places them in the Paste buffer, and on the Clipboard in Windows.

Use

Use Cut to delete a set of selected objects or to remove the objects from one place on the work area and put multiple copies of them in another place on the work area (using Paste).

Notes

Cut is only available after objects are selected.

Cut is not available when a program is running.

To delete a single object, use the Delete feature from its object menu.

Each Cut overwrites the previous contents of the Paste buffer.

If you accidentally Cut objects, they can be recovered by using Undo.

Cut objects can be pasted into another location in the same program, into another VEE session, or into other applications.

To make multiple copies without deleting objects, use Clone or Copy. To cut objects without modifying the clipboard, use the object context menu Delete.

Cuts can be undone on both Panel and Detail views.

Location

Edit [image] Cut

See Also

Clone (Object Menu), Cut (Object Menu), Copy, Paste, Replace, To Undo an Operation, Delete (Object Menu), and Select All.


Cut (Object Menu)

Deletes the object and places it in the Paste buffer, and on the Clipboard.

Use

Use Cut to remove this object from your work area.

Notes

Cut is only available from User Objects and User Functions.

Each Cut overwrites the previous contents of the Paste buffer.

Cut (Object Menu) is not available when a program is running.

If you accidentally Cut an object, it can be recovered by using Paste or Undo.

A cut object can be pasted into another location in the same program, or into another VEE session. A cut object can be pasted into other applications.

If you want to delete multiple objects, use the Cut selection from the Edit menu or draw a rectangle around the items you want to cut by holding down the CTRL key and moving the left mouse key. Right click on any open area in the work area and choose Cut from the menu.

Short Cuts

To delete the object under a pointer, press CTRL+D.

Location

On the object menu [image] Cut

See Also

Clone (Object Menu), Copy, Cut, Paste, Replace, and Select All.


Cyclic Button

See Selection Control.


Data Input (Object Menu)

Adds a data input terminal to the object.

Use

Use Data Input to increase the number of data input terminals the object uses. On some objects additional data inputs are automatically named A, B, C, and so on. You can change the names of most terminals to names that are more meaningful to you.

Although you cannot change the data type or shape of most input terminals, you can change these constraints on some objects, such as If/Then, Formula, Shift Register, and objects under the I/O menu.

Note
You should not change the data type or shape of an input terminal unless the object needs only that data type; if a constraint is changed from Any, the input data must be converted to the terminal constraint before the object processes the data. Conversions are time-consuming. If the conversion is unsuccessful, the object returns an error.

Notes

Data Input is only available from objects that permit additional data inputs.

Short Cuts

You can quickly add a data input terminal by placing the cursor over the input terminal display area and then pressing CTRL+A. Each press of CTRL+A inserts another data input terminal at the cursor location. The Add Terminal [image] Data Input adds the terminal at the end. CTRL+D deletes terminals covered by the cursor.

Location

On each object menu [image] Add Terminal [image] Data Input...

See Also

Add Terminal, Data Output (Object Menu), Control Input (Object Menu), Conditional, Delete Terminal, Object Menu, and Properties (Object).


Data Output (Object Menu)

Adds a data output terminal to the object.

Use

Use Data Output to increase the number of data output terminals. On some objects, additional data outputs are automatically named X, Y, Z, W, V and so on. You can change these data output names to names that are more meaningful to you.

The output terminal container information (data type and shape) is not displayed in the terminal information dialog box until after that object has executed.

Notes

Data Output is only available from objects that permit additional data outputs.

Short Cuts

You can quickly add a data output terminal by placing the cursor over the output terminal display area and then pressing CTRL+A. Each press of CTRL+A inserts another data output terminal at the cursor location. The Add Terminal [image] Data Output adds the terminal at the end. CTRL+D deletes terminals covered by the cursor.

Location

On each object menu [image] Add Terminal [image] Data Output...

See Also

Add Terminal, Data Input (Object Menu), Delete Terminal, Error Output (Object Menu), Instrument Manager, and Object Menu.


Date/Time

An object that outputs a constant date and time value. Date/Time takes an input date and time and converts it to the number of seconds between the input and the beginning of the Epoch (defined as beginning at 0000 hours UTC January 1, 0001 AD).

Use

Use Date/Time to display the time and date at the moment an object or data is created.

Date/Time can be used to calculate elapsed time between a past and current event by comparing the two mathematically.

To change a value such as the day, date, or time, type the value. For example, typing Tue changes Mon 27/Oct/2003 15:43:33 to Tue 28/Oct/2003 15:43:33. If you don't specify a value, the current day, date, or time is displayed. If you change just one of these the other time elements will stay the same.

Example

You can use Date/Time to determine the length of time that has passed between the moment a specific piece of experimental data was produced and another moment in time, either past or present. Use a Date/Time box to enter the new, arbitrary date then take the difference between the original, experimental data and the new arbitrary date.

To determine the length of time it takes for all or part of your program to execute, use Timer or now().

Properties

DataShape - Sets the initial data shape of the value(s) to be output with this object. Default is Scalar.

 ArraySize: - When 1D Array is selected, ArraySize sets the length of the array.

 ArraySizeFixed - When the property is True, the array cannot have lines added or deleted. This selection is only available if 1D Array is selected.

 ShowArrayIndices - When the property is True, each line in the entry field is indexed. This selection is only available if 1D Array is selected. Default is True.

 PasswordMasking - When this property is True, the input text is echoed as asterisks (*). This feature is useful when the operator is entering sensitive date/time data. The string that is output on the Date/Time output pin is not masked. Masking is disabled when Configuration is 1D Array. Default is False.

Wait for Input - When the property is True, the object does not operate until the object's value is changed. When the property is False, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When the property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

InitialValue - Specifies the value to be set. Default value is Sat 01/Jan/1 17:00:00 MST.

 InitializeAtPreRun - When the property is True, the InitialValue is set at PreRun time. Default is False.

 InitializeAtActivate - When the property is True, the InitialValue is set at Activate time. Default is False.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value(s). The Constant is reconfigured to match the shape of the incoming data. The control input should be a valid Date/Time string as given by the parse rules for date/time constants. These are the same rules as those for Direct I/O.

The Reset input allows you to programmatically set the value(s) to zero. If the Constant is configured as an Array 1D, all values are set to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the value can be changed in the object’s open view.

Note that the InitialValue field is always a scalar, even if Date/Time is configured to be an array.

You can display Date/Time output in AlphaNumeric or Logging AlphaNumeric by using the Time Stamp number format available in those objects' Properties window.

You can write the Date/Time output to various locations such as a string, file, or printer by using objects such as To String, To File, or To Printer (I/O [image] To [image]). In these objects, use the Time Stamp format in a WRITE TEXT transaction.

For MS Windows, you can change the time zone that appears in this object by using the Date/Time Properties dialog box (Time Zone tab) in Control Panel. After changing the time zone setting, you must restart VEE for the change to take effect.

Location

Data [image] Constant [image] Date/Time

See Also

Timer

To Use a Data Constant


Declare Variable

An object that allows you to declare programming variables.

Use

Use the Declare Variable object to declare variables anywhere in a VEE program. Three types of variables can be declared:

Global - the declared variable can be used anywhere within the program. This is the default declared variable scope.

Local to Context - the declared variable is specific to the context in which it was declared, such as within a particular UserObject or a UserFunction.

Local to Library - the declared variable is specific to a particular Library and only its UserFunctions can get to it.

Object Menu

Add Field -- Adds a new field to the record at the end of the field list. A dialog box will allow you to define the name, type, and shape of the new field. This field is grayed out unless you choose the Record type.

Insert Field -- Inserts a new field to the record at a specified position. A dialog box allows you to define the name, type, and dimension of the new field. A second dialog box allows you to specify the insertion point if more than one field exists. This field is grayed out unless you choose the Record type.

Delete Field -- Allows you to delete record fields. A dialog box will list the available fields to delete. This selection is available only if the record has more than one field. This field is grayed out unless you choose the Record type.

Edit Event Handler… - Opens the Edit Event Handler dialog box if any event handler UserFunctions have been created for the declared ActiveX object.

Create Event Handler… - Opens the Create Event Handler UserFunction browser. This browser lets you create a UserFunction to handle an event generated by an ActiveX automation object. You can create an event handler for each event listed in the browser’s Member area. This menu pick is available when Type is set to Object and you have enabled events for the specified Library and Class.

Open View Parameters

Name: - The user-defined variable name. The default name is global1.

Scope: - The program scope of the declared variable. Valid program scope values are Global, Local to Context and Local to Library. The default program scope is Global.

Type: - The data type of the variable, such as Real64, Int32, Enum, etc. The default type is Real64.

When Type is set to Record, the Declare Variable dialog box expands to the right. The expanded area lets you define and build the Record. Use Add Field, Insert Field, and Delete Field in the object menu to build the Record.

When Type is set to Object, a new field, "Sub Type", appears and the Declare Variable dialog box expands to the right. The expanded area lets you specify optional details when declaring a variable for an ActiveX or .NET object. You do not need to specify these details when declaring a variable; however, by doing so VEE will do type checking automatically to assure that the specifications are assigned only to the declared variable. For an ActiveX object to change values for Library, Class, and Events, click on Specify Object Type, then click on Edit… Change the values in the resulting dialog box Specify Object Type. For a .NET object to change values for Assembly, Namespace, Type, and Members, set the Sub Type to .NET, then click Edit... Change teh values in the resulting dialog box (Specify Object Type). Sub-Type "Any" allows an object of sub-type .NET, ActiveX(COM), or a VEE object such as an XYDisplay.

When Type is set to Variant, the value assigned to the variable can be any data type.

Num Dims: - The number of dimensions of the variable. The valid range is 0 through 10. The default value is 0.

Notes

For more information about programming techniques that effect the cleanup of ActiveX references, see the CreateObject topic.

Location

Data [image] Variable [image] Declare Variable

See Also

ActiveX Automation References, ActiveX Control References, Delete Variable, Get Variable, Set Variable, Specify Object Type, Variant, View Variables, and Properties (Object)

To Create a Variable

See the VEE Advanced Techniques manual for details about using ActiveX objects and controls in VEE.


Default Preferences

A menu choice that provides you with a dialog box for setting the default preferences in your VEE programming environment.

Use

Use Default Preferences to set VEE work area options. Saved options are used when you start up VEE and when you select New. Some of these options are also saved in your program, so you can configure each program with a different set of defaults.

Dialog Information

General tab:

Environment group

Auto Line Routing- When the Auto Line Routing check box is selected, the lines connected to an object are automatically rerouted when that object is moved or sized. VEE draws only horizontal and vertical lines with lines routed around other objects. It may take several moments to redraw the lines for a complicated program. When the Auto Line Routing check box is not selected, connecting lines are drawn straight from pin to pin (unless tacked). Choose Edit [image] Clean Up Lines to reroute lines around objects.

Delete Variables at PreRun - When the Delete Variables at PreRun check box is selected, the values stored in all variables are deleted before the program runs each time. Because Get Variable objects cannot execute until the variables they call are set with Set Variable objects, an error will be returned if a required variable has not been set. When the Delete Variables at PreRun check box is not selected, the values stored in variables will not be deleted at PreRun, and the program runs using data from a previous run. However, you need to be careful, this data may be invalid (not correct for the execution of the program this time), no error will be reported, and you may encounter unexpected results.

Execution Mode group:
For more information, see Understanding Execution Mode. For details about compatibility issues between execution modes, see the VEE Advanced Techniques manual.

VEE 6&7 - Runs the program using the same settings as the VEE 6.0 product. VEE 6 mode includes all the features of VEE 5 mode plus new Data Types UInt8, Int16, Real32, and Variant.

VEE 5 - Runs the program using the same settings as the VEE 5.0 product. This allows programs written with VEE 5.0 to run exactly the same as they would under that older version. VEE 5 mode includes all the features of VEE 4 mode plus ActiveX support on Windows. NOTE: Some programs written with VEE 4.0 and older may behave differently in the VEE 5 mode.

VEE 4 - Runs the program using the same settings as the VEE 4.0 product. This programs written with VEE 4.0 to run exactly the same as they would under that older version. VEE 4 mode adds the compiler technology, which allows for the faster program run-time than older versions. NOTE: Some programs written with VEE 3.2 and older versions will behave differently in this mode. Even though the program may appear to run normally, errors may occur due to time-slicing differences.

VEE 3 (Not Compiled) - Runs the program with the older VEE interpreter to allow programs written with VEE 3.2 and older versions to run exactly the same as they would under that older version.

Trig Mode group:

Degrees | Radians | Gradians - specifies the default for trigonometric units used throughout this program. If you select Radians, your trigonometric calculations will execute the fastest.

Debug group:

Data Flow Rate: - Sets the rate at which the Data Flow markers move, indicating data flow through the program. Select a rate from 1 to 10 (where 10 is the fastest). The default rate is 6.

Disable Debug Features - Allows you to turn off all debugging features for the fastest possible program execution.

Check Instrument Addresses at PreRun - With instrument checking enabled, VEE checks all supported instruments at prerun to verify that the referenced instruments are accessible (live). If an instrument or interface is not accessible, VEE:

1. Shows a dialog box prompting the user to retry after fixing the problem. The user can answer "Yes" to retry the detection for this instrument, "No" to check the next instrument, or "Cancel" to completely bypass this instrument.

2. If that instrument is detected after retry, then VEE checks the next instrument.

3. After an unsuccessful retry (or a "No" answer), VEE shows a list of live instruments on the same interface type. Then the user can choose an alternate address for the current instrument.

Program Development group:

Alignment Spacing - Designates the amount of space (in pixels) that is placed between VEE objects when Edit [image] Align [image] Space Equally is checked. Choosing one of the other Align [image] commands causes the objects to align with the amount of space specified.

Binary RunTime File Format - Controls file format when saving a program as a .vxe file using File [image] Create RunTime Version. Turn on Binary RunTime File Format (the default) for smaller file size and better program security. When turned off, the file is saved in ASCII format.

Colors tab:

Screen Element - Allows you to select the screen element (a graphical part of VEE) for which you'll set the default color. You can change the color of some of these elements locally using the Properties selection on a specific VEE object's menu.

Color Value - Allows you to select the color of the screen element from a palette.

Fonts tab:

Screen Element - Allows you to select the screen element (a graphical part of VEE) for which you will set the default font. You can change the font of some of these elements locally by using the Properties selection on a specific VEE object's menu.

Font Value - Allows you to select the text font of the screen element from the list of available fonts on your system.

Number tab:

Integer: - Specifies the number format for integer numbers to be displayed on this object. The choices are Decimal (e.g. 42), Octal (e.g. #Q52), Hexadecimal (e.g. #H2a), and Binary (e.g. #B00101010). Default is Decimal.

Real: - Specifies the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), and Standard (e.g. 98.6). Default is Standard.

Printing tab:

Screen Element - Allows you to select the screen element (a graphical part of VEE) for which you'll set the shade of gray to use when printing.

B & W Printer Darkness - Allows you to select the shade of gray to use for each screen element, when it prints on non-color printers. The defaults are usually fine for most printers.

Print Magnification: - Specifies the magnification used when printing a VEE program or part of a program. Use a lower number for a smaller image on the printout. To make a printout of a maximized screen fit on one page, the default printing magnification is set to 75%.

Print Header and Index Page - When this box is checked, each page of a printout of the VEE program will contain a two-line header showing the date and time, the program file name, and a page number. At the end of the printout, an index page will be printed which shows the page numbers of the indexed items.

Print Program Explorer - When this box is checked, the VEE program printout will show the information contained in the Program Explorer window.

Print Cover Page - when this box is checked, the first page of the VEE program printout will show the following:

A graphic of the Agilent VEE product logo.

The file name of the program being printed.

The file format under which the program was saved.

The revision code of the VEE software being used (such as 6.0, etc.).

The current VEE execution mode (VEE 6, etc.).

The Main user object Description file (if one has been entered).

Print I/O Configuration - when this box is checked, the instrument configuration’s expanded tree view is printed. You can see the instrument configuration in I/O [image] Instrument Manager…

To generate a plot, interactively choose the Print menu entry from the display's object menu. If the current Printer Setup is in the Print to File mode, the file or directory name specified will be used.

The entire view of the display object will be plotted, and scaled to fill the defined plotting area, while retaining the aspect ratio of the original display object. By re-sizing the display object, you can control the aspect ratio of the plotted image. By making the display object larger, you can reduce the relative size of the text and numeric labels around the plot.

Web Server tab:

Enable Server - Allows you to turn on VEE’s built-in Web server. The default is off. The Web server lets you monitor and troubleshoot a VEE application from a remote Web browser using standard HTTP 1.0 protocol. VEE must be running on a system that is connected to a network.

Root Directory: - Allows you to specify the location of files accessible to remote Web browsers. The default is ~installDir/www. Do not put private files in this directory or in any of its subdirectories since they are viewable by any Web browser with access to the host system. The file index.html is installed in the default root directory. This file is the default Web server home page, which you may adapt to your needs. If you change Root Directory, move index.html to the new location and do not change its file name.

HTTP Port Number: - Allows you to specify the port number for the Web server. The default is 80. The only times when you may need to change the default port number is when another Web server, such as another VEE, is running on the same system, or if you want to restrict access to VEE’s Web server. Do not use a port number that has already been allocated. Allowed values range from 0 through 65535. For a list of currently allocated ports see the services file:
Windows NT: \Winnt\system32\drivers\etc\services

Server Timeout (sec): - Allows you to set the maximum time the Web server waits for VEE to process Web server commands. The default is 60 seconds. If the VEE program is busy performing a time-consuming activity, a timeout message is sent to the Web browser.

Log File: - Allows you to specify the location for the log file http.log. The default location is a temporary directory such as C:\tmp\http.log. If the log file does not exist already, it is created when you make any changes in Default Preferences. The log contains a record of all incoming HTTP requests processed by the Web server. Data is appended to the log file, so you must monitor its size.

Notes

After you enable the VEE Web server and set its attributes, you can access the Web server from any Web browser that supports the HTTP 1.0 specification (any commonly available browser). Enter a URL in one of the two following formats:

http://hostname{:port}{/file}

or

http://hostname{:port}{/command}{?parameter}

Where:

hostname (required) identifies the host system on which VEE is running. When used alone in a URL, this opens the Web server home page index.html.

port (optional) identifies the Web server’s HTTP Port Number if not using the default value.

file (optional) identifies a directory and/or file relative to the Root Directory for the browser to open. You can include a file name extension, such as .jpeg or .html.

command (optional) specifies a command supported by the Web server letting you monitor, troubleshoot, and control a VEE program from the browser. Commands are described below.

parameter (optional) specifies a parameter required by a command. Parameters are described with the commands below.

The Agilent VEE Web server supports the following commands:

ViewVEE displays the entire VEE window.

ViewMainDetail shows the Main window's detail view. An error appears if the program was saved as a secured RunTime program.

ViewMainPanel displays the Main window's panel. An error appears if the Main window doesn't have a panel.

ViewExecWindow displays an VEE Execution window. An error message appears if no Execution window exists.

ViewDetail?UserFuncName displays the detail view of a UserFunction named UserFuncName. An error message appears if UserFuncName doesn't exist or has been saved as a secured RunTime file. The view is sized such that all objects in the UserFunction are visible, even if the current UserFunction window size is smaller.

ViewPanel?UserFuncName displays the panel view of a UserFunction named UserFuncName. An error message appears if UserFuncName doesn't exist or doesn't have a panel.

ViewError shows the Error window of the current program.

The following examples show URLs that you can enter in a Web browser. They assume that VEE is running on a networked system with the host name my_system, the Web server is enabled, and it is using the default HTTP port number 80.

http://my_system/public_docs/page.html
Displays the file page.html in the directory public_docs. This directory and file are located on the host system relative to the Web server’s root directory.

http://my_system/ViewExecWindow
Displays the VEE Execution window.

When Save is pressed, default preferences are stored in the defaults file VEE.RC in the VEE program installation directory for MS Windows). Some of these properties are saved in your program as well as the defaults file. These include the choices in the Environment and Trig Mode groups on the General tab, and the number format on the Number tab. The colors and font values are saved in the program only if the Save colors and fonts with program box is checked on the File [image] Save dialog. Also for colors and fonts, only the settings you change are saved in the defaults file.

If OK is pressed, the changes are valid only for the current work session.

If Reset is pressed, your current settings are discarded and the defaults file is re-read.

If Cancel is pressed, the changes you made are canceled.

Location

File [image] Default Preferences

See Also

Align, Clean Up Lines, Delete Variable, Get Variable, Set Variable, Show Data Flow, Program Explorer, and Properties (Object)

To Change Default Colors

To Change Default Fonts

To Change the Number Format

To Change the Printing Preferences

To Set Up a Printer


Delay

An object that waits a specified period of time before activating its Done data output terminal.

Use

Use Delay to delay execution of a thread segment for a specified number of seconds.

Example

Use Delay as a time out in a dialog box created with a UserObject.

Open View Parameters

Enter the number of seconds delay in the edit field. If you add a data input pin, the value supplied to that pin determines the delay period in seconds.

Notes

The delay value is specified in seconds and has a resolution dependent on the system clock and the nature of the program in which the Delay is operating. You can set the value for the Delay through a data input.

The delay interval is measured from the time when the sequence input pin is activated. After the specified interval, the Done data output terminal is activated. Note that Delay is "asleep" while it is waiting, thereby allowing other objects the opportunity to operate.

In most cases, either the Done data output terminal or the sequence out pin may be used to continue propagation after the Delay time expires. However, when the Delay object is part of a thread containing other objects executing in parallel, the sequence out pin may not fire until a much longer time has elapsed. This is because sequence out pins are fired only when there are no other objects which may execute. To ensure that the delayed thread will continue at the end of the Delay period, use the Done data output terminal, which always fires at the end of the Delay time period.

Location

Flow [image] Delay

See Also

Instrument Event, Interface Event, OK, On Cycle, and Properties (Object)

To Set a Timeout


Delete (Object Menu)

Removes this object from the panel or detail view.

Use

Use Delete to remove the object from the detail or panel view. Note that when deleting the object from panel view, the object remains on the detail view.

Deleting an object from detail view also removes it from the panel view.

Notes

Delete does not modify the clipboard (ie. for Paste).

You can undo a Delete by pressing CTRL+Z, by selecting Edit > Undo from the main menu, or by selecting [image] from the taskbar.

Short Cuts

You can quickly delete an object by double clicking the object menu selection box in the upper left corner of the object.

Location

On the object menu [image] Delete

See Also

Cut, Object Menu, To Undo an Operation, and Properties (Object).

To Delete Objects from a Panel


Delete Variable

An object that deletes the value of a variable that has already been created in the execution of the current program.

Use

Use the Delete Variable object to delete a variable by name or to delete all variables currently set in the program. The variable must have been created previously by a Set Variable object within the program.

Open View Parameters

By Name - The open view displays a field for the name of the variable. The name is not case sensitive (either lower-case or upper-case letters may be used). Thus globalA is the same variable as GLOBALa. The name field may be added as a control input.

All Variables - Deleting all variables will delete all declared variables of all scopes, and all undeclared variables. The name field is grayed out (unavailable).

Notes

The Delete Variable object will error if the variable referenced by name does not exist. To avoid getting this error, add an error output pin to the Delete Variable object.

When the Delete Variable object has executed, the variable referenced by name (or all variables) are deleted, just as if they never were created. Subsequent use of the variable in Get Variable objects will error since the variable does not exist.

Deleting variables when they're not needed anymore with the Delete Variable object saves memory and helps you better manage your variables.

In Default Preferences, if Delete Variables at PreRun is on (the default), all variables are deleted before your program executes. If Delete Variables at PreRun is turned off, variables will not be deleted, and you must program carefully to avoid propagating invalid data.

For more information about programming techniques that effect the cleanup of ActiveX references, see the CreateObject topic.

Location

Data [image] Variable [image] Delete Variable

See Also

Default Preferences, Get Variable, Set Variable, View Variables, and Properties (Object)

To Delete a Variable


Delete Library

An object that deletes (unloads) a library of UserFunctions, Compiled Function definitions, or Remote Function definitions from a running program.

Use

Use Delete Library to delete a library from your VEE program. The action taken depends on the type of library:

UserFunction - Delete Library deletes from the VEE program the UserFunctions previously loaded with an Import Library object. This deletes only the UserFunctions contained in the library named in the Library Name field.

Compiled Function - Delete Library detaches a shared library from the VEE process. However, the file containing the shared library is actually detached only when the last library pointing to that file is deleted. That is, if you have several different libraries pointing to the same shared library file (with either the same or a different definition file), the shared library file is detached from the VEE process only when there are no more libraries using the attached code. The operating system will not allow you to move or delete a shared library file once it is attached to a process. You must use the Delete Lib option in the Import Library object to detach the code if you want to create a new shared library file.

Remote Function - Delete Library shuts down the remote VEE process and removes the Remote Function definitions from the local VEE process. Delete Library actually shuts down the remote process when the last library that references the remote process is deleted on the local host.

Open View Parameters

Library Name - In this field, enter the name of the library that you want to delete.

Notes

Delete Library is generally used for advanced operations where you want to dynamically load, and then delete, library objects from a running VEE process. This greatly reduces the memory requirements of the VEE process.

The Delete Library object will accept a single Data Input terminal. The default name of the input terminal is LibraryName.

Location

Device [image] Delete Library

See Also

Call, Edit UserFunction, Import Library, UserFunction, UserObject, and Properties (Object)


Delete Line

Removes the line between two pins.

Use

Use Delete Line to eliminate wrong connections or to modify connections in your program. Select Delete Line, then click on or near the line to be deleted.

To exit this mode without deleting a line, click on an empty space on the work area, away from any lines.

Notes

To view the endpoints of a line (without deleting it), place the cursor over the line momentarily. This will highlight the line and show the endpoints. It will also show the value carried by the line.

Delete Line is not available when the program is running.

Delete Line can be undone.

Short Cuts

While holding down CTRL+Shift place the pointer over line(s) and click the left mouse button to delete lines.

You can delete a series of lines this way, one at a time.

Location

Edit [image] Delete Line

See Also

Cut, To Undo an Operation, and Line Probe.


Delete Terminal

A menu item.

Use

Use Delete Terminal to access the following features which delete terminals:

Input - Used to delete a data or control input pin that was added to the object. After selecting Input, select the pin to be deleted from the dialog box displayed. The pin and any connections to it are deleted. If two pins have identical names, VEE deletes the pin based on the order that the pins appear in the list.

Output - Used to delete a data or error output pin that was added to the object. After selecting Output, select the pin to be deleted from the dialog box displayed. The pin and any connections to it are deleted. If two pins have identical names, VEE deletes the pin based on the order that the pins appear in the list.

Notes

Input is available only if the object has input pins that may be deleted. Some pins cannot be deleted.

Output is available only if the object has output pins that may be deleted. Some pins cannot be deleted.

Short Cuts

You can quickly delete a data terminal by placing the cursor over the terminal view area and then pressing CTRL+D.

Location

On each object menu:
Delete Terminal [image] Input…

Delete Terminal [image] Output…

See Also

Add Terminal, Line Probe, Object Menu, and Properties (Object).


DeMultiplexer

An object that directs the input value to a selected output pin.

Use

Use DeMultiplexer to direct the input data to a particular output pin. The output that is activated depends on the value of the address input.

Notes

DeMultiplexer has two inputs, one for data output and one for the address value (which determines the output to be propagated). Only one output is propagated each time the object operates. If the value of the address input is not within the range of the number of outputs [0 [image] (N-1)], an error is returned. Additional outputs can be added to the object. Outputs can be deleted, but then the following outputs (if any) are renumbered in order.

Location

Device [image] DeMultiplexer

See Also

If/Then/Else, JCT, and Properties (Object)


Description

Accessible from the object menu for information about an object, or from the title bar menu for information about the main program, User Object, or User Function.

Displays an editable Rich Text Format (RTF) dialog box that displays user-supplied information. There is a default Description, which demonstrates the capabilities of the dialog box, that is displayed when the Description dialog box is opened. To create your own default Description, edit the description.rtf file in installdir\templates. If you want an empty description dialog box, edit the description.rtf file and leave it empty.

Use

Use Description to document an object, and explain how or why it's used. Or from the title bar menu, use Description to document the entire file.

To write a description, click in the text area and type the description, or cut and paste a description from a RTF file. Click OK when you're finished.

Open View Parameters

OK - Saves the description information with the program.

Cancel - Cancels current changes to description, and closes Description window.

Insert Template - Inserts the template file Description.rtf at the cursor location. The template is editable by you and is saved in %installDir%\Templates.

Clear All - Clears all content from the Description window. To recover canceled text, press Cancel, then re-open the Description window.

Notes

You can edit the text area using the usual VEE edit functions.

When printing using Print All with Print All Objects selected or printing using Print Objects, the description for the object will also be printed.

Since Description is an RTF dialog box, you can use an RTF enabled application to create beautifully formatted text that includes multiple fonts, colors, tables, active URLs, etc.

You can print the Description text but it is always printed as text only.

Location

On each object menu [image] Description

or

On each title bar menu [image] Description

See Also

Note Pad, Object Menu, Create RunTime Version


Dialog Box

A menu item.

Use

Use Dialog Box to access the following prepared dialog box objects:

Text Input

Int32 Input

Real64 Input

Message Box

List Box

File Name Selection

Location

Data [image] Dialog Box

See Also

File Name Selection, Int32 Input, List Box, Message Box, Real64 Input, Text Input, and UserObject.

About Built-In Dialog Box Objects

To Use a Data Input Dialog Box


Direct I/O

An object that writes data to and reads data from an instrument using transaction statements.

Use

Use Direct I/O to output and input a variety of encodings and formats to instruments.

Object Menu

Show Config - Displays the instrument configuration.

Upload State - Uploads the current instrument state to a learn string, and associates this state with this particular instance of the Direct I/O object. Supports GPIB and message-based VXI devices that support learn strings.

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Print Trans - Prints the detailed dialog box that describes the currently highlighted transaction.

Open View Parameters

Direct I/O Actions:

READ - Reads data from an instrument using the specified encoding and format.

WRITE - Writes data to an instrument using the specified encoding and format.

EXECUTE - For a GPIB instrument, sends either a Selected Device Clear, Go To Local, Remote, or Group Execute Trigger command. For a serial instrument, sends Break or Reset. For a GPIO instrument, sends Reset. For a VXI message-based instrument, sends either a Selected Device Clear, Go To Local, Remote, or Trigger command.

WAIT - Waits the specific number of seconds before executing the next transaction. For a GPIB instrument or a VXI message-based instrument, wait until the bitwise AND of the serial poll response with the mask is either zero (ALL CLEAR) or non-zero (ANY SET).

For GPIO instruments only, the READ action allows IOSTATUS and the WRITE action allows IOCTL.

For VXI instruments only, the READ and WRITE actions allow REGISTER: and MEMORY:. The WAIT action also supports the ability to wait until the value in a memory or register offset AND a mask value satisfy the ANYSET, ALL CLEAR, or EQUAL.

Direct I/O Encodings:

TEXT - Writes all data types in human-readable form. VEE numeric data is automatically converted to text as it is written.

BINARY - Writes all data types in an machine-specific binary format.

BINBLOCK - Writes all VEE data types in binary files with IEEE 488.2 definite length block headers.

When using BINBLOCK with an instrument that outputs a terminating line-feed, select End byte (LF) so that VEE will consume the terminating line-feed. If the instrument does not output a terminating line-feed, select No END byte.

CONTAINER - Writes all data types in a platform-independent text format.

Short Cuts

You can quickly add a data terminal by placing the cursor over the input or output terminal display area and then pressing CTRL+A. Each press of CTRL+A adds an additional data terminal.

You can quickly delete a data terminal by placing the cursor over the terminal view area and then pressing CTRL+D.

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Control pins are available as inputs to programmatically change the device address and timeout period.

Location

I/O [image] Instrument Manager

See Also

Advanced I/O, Component Driver, Formula, Instrument Manager, Panel Driver, and To/From VXIplug&play.

To Increase I/O Performance

To Read Data Using Direct I/O

To Use a Direct I/O Object

Also, refer to the appendix "I/O Transaction Reference" in the VEE Advanced Techniques manual.


Do

An object that creates a branch point to control the execution flow of a thread.

Use

Use Do to create a branch point; the object connected to the data output pin is activated before the object connected to the sequence output pin. Note that this forces the order in which objects operate.

Location

Flow [image] Do

See Also

Break, Start, and Properties (Object)


Drop-Down List

See Selection Control.


Edit UserFunction

A menu selection that allows you to edit a locally-created UserFunction within a program. You may also view (but not change) a UserFunction imported with a library.

Use

Use Edit UserFunction to edit a UserFunction created locally within a program by executing Make UserFunction from the object menu of a UserObject. If you have saved a series of UserFunctions in a library file, you will have to open the library file to edit those UserFunctions.

Notes

When you select Edit UserFunction, a dialog box appears listing the available local UserFunctions to edit. Once you select a UserFunction, a window is created that displays a work area showing the functionality of the original UserObject from which the UserFunction was created. You can edit this work area just as you would edit any UserObject. When you have finished, close the window. When you save the file, the edited UserFunction will be saved with it.

While editing a UserFunction you can switch between the Panel and Detail view by using the Panel and Detail icons from the title bar.

When viewing a UserFunction imported with a library, you cannot change the UserFunction. However, to aid in debugging, you may set breakpoints, and open/iconize/move objects. These changes will not be saved to the library file.

Shortcuts

From the Program Explorer, double click a User Function to edit it.

Location

Edit [image] Edit UserFunction

Object menu of Call Function [image] Edit UserFunction

See Also

Call, Create UserFunction, Delete Library, Import Library, UserFunction, and UserObject.

To Edit a UserFunction


Error Output (Object Menu)

Adds an error output terminal to the object.

Use

Use Error Output to allow your program to trap and process VEE errors. If an Error pin is on an object and the object encounters an error, no error dialog box is displayed. Instead, the error number is output to the Error pin.

If an error is trapped, the error output pin and the sequence output pin are activated; no data is output on the data output pins.

The error output pin outputs a Scalar Int32 container with the value of the error number that was generated.

Notes

Error Output is available from almost all objects. Some objects, such as Bus I/O Monitor and Note Pad, never return an error, therefore, they do not allow the addition of an error output pin.

An error output terminal outputs the error number of the VEE error. It does not output the meaning of the number or any recovery information. Error information is available under the Error Codes topic under Help [image] Contents and Index

Use errorInfo() to determine error information for the last error trapped when using error output pins. After the error is trapped, execute an errorInfo() object to output a record that contains all the information that would be displayed in an error dialog box.

A Raise Error object in a UserObject can generate an error that may be trapped by the error pin of an enclosing UserObject.

The error pin on a UserObject traps any errors for any object in the UserObject.

Location

On each object menu [image] Add Terminal [image] Error Output

See Also

Add Terminal, Delete Terminal, errorInfo, Object Menu, Raise Error, and UserObject.

To Trap an Error


Execute Program

An object that starts an MS-DOS or Windows process.

Use

Use Execute Program to start MS-DOS or Windows processes, including executable programs, operating system commands, or batch files. The PC Execute object returns an exit code from the program that was executed. If Wait for prog exit is set to No, the exit code output terminal does not propagate any return value.

Open View Parameters

Run Style - If the program you want to execute runs in a window, Run Style specifies the window style:

Normal runs the program in a standard window.

Minimized runs the program in a window minimized to an icon.

Maximized runs the program in a window enlarged to its maximum size.

Wait for prog exit - If Wait for prog exit is set to Yes, VEE runs the external process, and waits until the external process terminates before activating the sequence output pin of the Execute Program object.

If Wait for prog exit is set to No, VEE runs the external process, but activates the sequence output pin of the Execute Program object without waiting for the external process to terminate.

Prog with params - The program you want to run. Here are some examples of what you might type into this field:

COMMAND.COM /C DIR C:\TMP (on Windows 98)
CMD /C DIR C:\TMP (on Windows NT)

PBRUSH

C:\MYDIR\MYFILE.BAT

"\Program Files\Windows Media Player\mplayer2.exe" "\WINNT\Media\Mozart's Symphony No. 40.rmi"

www.favorite_site.org/index.htm

Path names containing spaces must be enclosed in quotes, as shown in the next-to-last example.

In the last example, the known suffix ".htm" starts your Internet browser and loads the specified URL. If the browser is already running, it loads the specified URL.

Working directory - Points to a directory where the program you want to execute can find files it needs. So, if you want to run the program nmake using the makefile in the directory c:\progs\cprog1 use these parameters:

In Prog with params:, enter nmake.

In Working directory:, enter c:\progs\cprog1.

Notes

Execute Program is not transaction based. You cannot communicate with external processes using transactions.

If you have included the appropriate path in the PATH variable, you don't need to include the path in the Prog with params field. Set the PATH variable in AUTOEXEC.BAT file for Windows 98 or User Environment Variables (Main / Control Panel / System) for Windows NT.

To execute a .EXE file, you don't need to include the suffix in the Prog with params field. However, for .COM and .BAT files you do need to include the suffix.

If the action specified in Prog with params does not cause a new instance of a program to start, the Execute object does not wait for the program to exit, even if Wait for prog exit is set to Yes. The exit code terminal does not propagate an exit code in this case. One example of this behavior is "executing" a URL when your Internet browser is already running. The specified URL is opened in the running browser, and VEE does not wait until you eventually close your browser. Other common examples of this behavior are passing files to existing instances of a word processor or a spreadsheet editor. Note that the designer of the external application (browser, spreadsheet, etc.) determines whether a new instance is started or the existing instance is used in these cases.

The Execute object uses the ShellExecuteEx() Win32 API.

Location

I/O [image] Execute Program

See Also

To/From DDE and Properties (Object)


Execution Window

A selection on the View menu.

Use

If your Main UserObject has a panel, and ShowPanelOnExecute is enabled on Main's Properties Window, then that panel will appear inside the Execution Window when you run your VEE program. This will allow you to see both your Main object window as well as the Execution Window. Also, the Execution Window shows you what your executable program will look like when run in VEE Pro RunTime.

The Execution Window can be moved, resized, maximized, minimized or moved to the bottom of the window stack, but it cannot be closed.

The name that appears in the title bar of the Execution Window can be set from the object menu on the Main window. From the Main object menu, select Properties, then change the PopUpPanelTitle.

Location

View [image] Execution Window

See Also

Add To Panel, Main, and Create RunTime Version.

About the Agilent VEE Pro RunTime Product.


Exit

Exits (quits) VEE.

Use

Use Exit to end this work session with VEE.

Notes

If your program changes have not been saved when you select Exit, you are prompted to save them.

You are not allowed to Exit when a program is running. Use the Stop object to exit a running program.

Short Cuts

Press CTRL+E to exit. On the window control button in the upper-left corner of the VEE window, either double-click on the button, or click on the button and choose Close from its menu.

Location

File [image] Exit

See Also

Raise Error, Exit Thread, Exit UserObject, New, Open, and Stop.


Exit Thread

An object that stops the execution of a thread.

Use

Use Exit Thread to terminate the execution of an independent thread. Exit Thread only stops the execution of the thread on which it resides.

Location

Flow [image] Exit Thread

See Also

Break, Raise Error, Exit UserObject, Start, Stop, and Properties (Object)

To Stop a VEE Program


Exit UserObject

An object that stops the execution of a UserObject.

Use

Use Exit UserObject to stop the execution of all threads in the UserObject and start execution in the next object after the UserObject in the program. Any data sent to the UserObjects output terminals before the Exit UserObject was encountered, is passed to the appropriate succeeding object(s) by activating these outputs.

Use Exit UserObject to make an early exit from a UserObject.

Location

Flow [image] Exit UserObject

See Also

Create UserObject, Raise Error, Exit Thread, Start, Stop, UserObject, and Properties (Object)

To Exit a UserObject Early


File Name Selection

An object that displays a pop-up dialog box that displays a list of files to the user.

Use

Use File Name Selection to display a list of the files on a disk drive to the user. The user responds by selecting one of the choices on the dialog box. File Name Selection is very useful to interactively request file names to be used in To File and From File objects.

In the pop-up dialog box, when a file selection is made and the OK button is pressed, the selection is output on the File Name output pin. When the Cancel button is pressed, a 1 is output on the Cancel output pin.

Open View

Prompt/Label - The string that prompts the user to select a file name. You may add this parameter as a data input. Default is Enter File Name:

Initial Directory - The directory that is initially shown in the File Name Selection pop-up dialog box. You may add this parameter as a data input. Default is the directory from which you stared VEE.

Initial File/Wildcard - Allows you to set a file name as the default or to filter a set of file names by using wildcard characters. You may add this parameter as a data input. Default is *.*.

Select File For: Reading | Writing - When you select Reading, the user must select an existing file name from the pop-up dialog box. If the user types a nonexistent file name into the pop-up dialog box and presses OK, they are prompted to enter an existing file name.

When you select Writing, the user may type a new file name or select an existing file name from the pop-up dialog box. If an existing file name is chosen, a warning dialog box pops up asking if it's OK to overwrite the file. If the user presses Yes, the file name is output to the File Name output pin. If the user presses No, the user is returned to the File Name Selection dialog box to select another file name. You may add this parameter as a data input.

Notes

The pop-up location of the File Name Selection dialog box is not selectable. This dialog box always appears near the upper-left corner of the VEE window.

To respond to the pop-up dialog box using only the keyboard: when the dialog box pops up, use Enter and Esc keys. Or use the Tab key to move between the buttons and the selection area; move through the choices with the arrow keys, and select the file name with the Space bar.

The pop-up dialog box is only displayed while the program is running. While the pop-up dialog box is displayed, the entire program pauses execution, then continues when the dialog box is closed.

The Input Terminal "Dialog Mode" accepts two text strings, either Writing or Reading. These strings are case sensitive.

Location

Data [image] Dialog Box [image] File Name Selection

See Also

From File, Int32 Input, List Box, Message Box, Real64 Input, Text Input, To File, UserObject, and Properties (Object)

To Select a File Name Programmatically


Fill Bar

An object that displays a Scalar numeric value graphically using a color bar.

Use

Use Fill Bar to display a numeric value on an analog scale with a color bar, and an optional digital numeric field.

Open View

The minimum and maximum values of the Fill Bar are set on the open view of the object by clicking on the present value and typing in a new value. Tic marks and their labels are automatically calculated and displayed. The minimum value must be less than the maximum value.

These values may also be added as control inputs.

Properties

Orientation - Selects the how the Fill Bar is displayed. Default is Vertical.

 ShowDigitalDisplay - If the property is True, a digital display of the input value is displayed at the bottom of the open view of the object. If the property is False, the digital display is not displayed and the object operates faster. Default is True.

ShowTics - Controls visibility of scale’s tic marks and labels. Default is True.

 Logarithmic - When turned on, changes scale from linear to logarithmic. Default is False.

 Label Spacing - Controls which tic marks are labeled with the scale values. Default is Every Other Tic.

HighColor - Specifies the color used for the highest range (i.e., greater than High Limit).

High Limit - Defines the numeric lower limit for the highest range. This value must be greater than or equal to the Low Limit. You may add this value as a control input, which disables this property's edit field.

 MidColor - Specifies the color used for the middle range (i.e., less than or equal to High Limit and greater than Low Limit).

 Low Limit - Defines the numeric upper limit for the lowest range. This value must be less than or equal to the High Limit. You may add this value as a control input, which disables this property's edit field.

 LowColor - Specifies the color used for the lowest range (i.e., less than or equal to the Low Limit).

NumberFormat - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

Notes

The input data must be Scalar and able to be converted to Real64 (Complex, PComplex, Spectrum, and Coord must be first "unbuilt".)

The Low Limit must be less than the High Limit.

To use only 2 ranges of color, set the Low Limit equal to the High Limit.

To use only 1 color, set the Low Color, Mid Color, and High Color to the same color.

Short Cuts

To quickly change the orientation of the Fill Bar, just resize it to the desired shape. It will automatically change orientation.

Location

Display [image] Indicator [image] Fill Bar

See Also

AlphaNumeric, Color Alarm, Logging AlphaNumeric, Meter, Tank, and Thermometer.

To Show an Analog Display of Data


Find

This menu choice provides a dialog box to search for text strings and certain object properties in a VEE program.

Use

The Find feature provides you with a convenient method of performing text string searches in VEE programs. This makes it easy to locate specific text within program objects, and will also allow searches for certain other object properties, such as an object's title bar color or background color.

However, Find will not search for the following:

Panels or objects on panels.

Lines or line values.

Terminal values.

Dialog Information

The Find dialog box includes a single-line text field for entering a searchable text string, and provides several options for configuring the search specifications. The dialog box features are:

Find What: - The text string to be searched for is entered on this line. If you leave this line blank, a search will match any and all text.

Search in: - Allows you to limit the scope of the text search to only certain segments of the VEE program. The default is to search Entire Program.

Find - The Find button begins the text search using the search parameters that the user specifies on the General and Advanced tabs of the dialog box.

Stop - The Stop button halts the search process. Any matches found up until the search process was stopped are retained.

Help - The Help button invokes the on-line help information for the Find dialog box.

A Status Bar is located at the bottom of the Find dialog box. The Status Bar indicates the status of the search process. The information in the Status Bar will update as new matches are found.

Properties

General tab

The General options tab provides a set of constraints for limiting the general text search. The options are:

Match Case - If checked, the text must match the user-specified search string exactly. Default is off.

Find all matches on each object - Default is off.

Search nested UserObjects - Default in on.

Show occurrences that - further constrains the search as follows:

Contain search text - Default is on.

Exactly match search text - Default is off.

Begin with search text - Default is off.

End with search text - Default is off.

Advanced tab:

Clicking on the Advanced tab will bring up a new set of options on the Find dialog box. The options on the Advanced tab provide a way to constrain a search based on object types and object characteristics. The Property and Value buttons on the Advanced tab are used in combination to define the search criteria. Once a Property button has been defined, its associated Value button also must be defined.

Property and Value - There are three buttons in the Property column and three buttons in the Value column. Clicking on one of the buttons in the Property column brings up a Property Name dialog box which lists the names of specific search properties. For each Property Name selected, a value must then be selected by clicking on the adjacent Value button. The Property and Value combinations are paired as follows:

Object Type (default) - when this Property Name is selected, the Value button will default to All Types. Clicking on the Value button will bring up the Select Object Type(s) dialog box. This dialog box lists all VEE functions that are capable of opening an object in the VEE workspace. For an explanation of each of the object types that are available, refer to that object type's specific section in Help.

Note that in the Select Object Type(s) dialog box, all of the object types available are pre-selected by default. In order to select just one, or several object types, click the Clear All button on the dialog box, then use the left mouse button to select the specific object types desired. Any and all selected object types may be unselected by clicking on the Clear All button. A Property button can also be assigned a Property Name other than Object Type. A few property name examples, and their associated Value are described below:

- Description - valid values are any user-defined Description entered by the user in the Value field.
- Device name - valid values are any user-defined Device name entered by the user in the Value field.
- Popup Panel Title Background Color - valid values are any color from the VEE color map. The default color for this value will be the color specified by the user in the Default Preferences dialog box. Clicking on the Value field will open the Select Color for Object Title dialog box. The user can use the left mouse button to select any color from the color palette in this dialog box.

Reset - The Reset button defaults the first Property button to Object Type and defaults the first Value button to All Types. The remaining two pairs of Property and Value buttons on the Advanced tab will be cleared of any selected options.

Short Cuts

Press Ctrl+F to open the Find dialog box.

To limit the scope automatically, open Find from the Program Explorer by clicking with the right mouse button on a particular context, such as a UserFunction or UserObject.

Location

Edit [image] Find...

See Also

Default Preferences and Find Results.

To Find Objects by Searching for Properties

To Find Objects by Searching for Text


Find Results

Displays a dialog box that lists the results of the last Find search.

Use

Use Find Results to display a dialog box that shows the results of the last execution of a Find text search. If a Find text search has not been executed, then the Find Results menu item will be grayed out (unselectable).

The Find Results dialog box will also be displayed when you click on the Find button on the Find dialog box.

Dialog Information

The title bar of the Find Results dialog box provides a summary of the Find search, including how many matches were found, as well as the total number of VEE objects. Below the title bar are several control buttons, the specific search text that was used, and the search scope (Entire Program, etc.).

Control buttons - The control buttons provide short cuts to viewing the Find Results. The control buttons include:

Keep Visible - A toggle function which controls whether or not the dialog box remains visible after viewing a match.

Display previous item - Displays the previous match in the Find Results list.

Display next item - Displays the next match in the Find Results list.

Find - Restores the Find dialog box.

Find: - This window displays the specific text that was searched for, enclosed in quotation marks.

Scope: - This window displays the scope of the search. The default is the entire program.

Object Location - The pathname to the UserFunction or UserObject where the match was found. In the case of nested VEE UserObjects, this is the path through each of the nested objects.

Object Title - The title of the object on which the text was found. This title is set via the Object Properties.

Object Type - The type of VEE object on which the text was found (such as a Formula object, Constant object, etc.).

Text Found - The text that was found somewhere in the object. This text could be in the object title or somewhere internal to the object itself.

Short Cuts

Press Ctrl+R to open the Find Results dialog box.

You can also change the sorting order of a column in the dialog box by clicking on the column header.

Location

Edit [image] Find Results

See Also

Find

To View Results of a Find Operation


For Count

An object that activates its data output pin a specified number of times.

Use

Use For Count to execute a subthread a specified number of iterations. The output of a For Count can be used as a value for succeeding objects in the subthread.

Open View Parameters

Enter the number of iterations in the entry field or as an input.

Notes

The For Count output value is a Real64 scalar ranging from 0 to n-1 where n is the specified count value. All access to unmapped array objects is zero-based, therefore For Count is ideally suited for traversing the dimensions of such objects when required. The For Count value is the dimension size.

If the specified For Count value is zero or negative, the output is not activated, but the sequence output pin is.

Execution of the subthread hosted by the For Count output continues until one of the following occurs:

All objects that can, have operated. The subthread is deactivated, the iteration counter is incremented, and, if the count value is less than the specified count, the subthread is reactivated by refiring the For Count output with the new iteration value.

A Break object operates. The subthread is deactivated and the sequence output pin is activated. Note that the value that remains on the For Count output is the same value present when the Break was encountered.

A Next object operates. The subthread is deactivated and the iteration counter is incremented. If the count value is less than the specified Count, the subthread is reactivated by refiring the Count output with the new iteration value, and execution of the subthread proceeds as usual. If the iteration counter has reached the Count value, the sequence output pin is activated.

When the subthread hosted by the For Count object finishes an iteration, all data containers sent during the previous iteration are invalidated before the next iteration. This prevents "old" data from a previous iteration from being reused in the current iteration. However, if flow branching is present within the iterative subthread, some objects may not execute on every iteration. Thus, data containers sent by those objects may be invalidated before other objects can execute on the data. To obtain the desired propagation in this case, use the Sample & Hold object.

Location

Flow [image] Repeat [image] For Count

See Also

Break, For Log Range, For Range, Get Values, Next, On Cycle, Sample & Hold, Set Values, Until Break, and Properties (Object)

To Loop Part of a VEE Program


For Log Range

An object that activates its data output pin a specified number of times.

Use

Use For Log Range to execute a subthread for a specified number of iterations. Use For Log Range to specify a beginning, end, and increment, and generate output values that are evenly distributed along the log 10 scale.

Open View Parameters

From - The beginning value of the iteration loop.

Thru - The ending value of the iteration loop. When the value of the iterator is greater or equal to the Thru value, the loop is completed.

/Dec - Determines the spacing of values from the iterator. The 0th value is From. The nth value is From*exp10(n/(/Dec)).

From, Thru, and /Dec may be added as inputs.

Notes

The For Log Range output value is a Real64 scalar ranging from From to Thru.

Execution of the subthread hosted by the For Log Range output continues until one of the following occurs:

All objects that can, have operated. The subthread is deactivated, the iteration counter is incremented by the /Dec value, and, if the count value is less than the Thru value, the subthread reactivates the For Log Range output with the new iteration value.

A Break object operates. The subthread is deactivated and the sequence output pin is activated. Note that the value that remains on the For Log Range output is the same value present when the Break was encountered.

A Next object operates. The subthread is deactivated and the iteration counter is incremented by the /Dec value. If the count value is less than the Thru value, the subthread reactivates the Data output with the new iteration value, and execution of the subthread proceeds as usual. If the iteration counter has reached or exceeded the Thru value, the sequence output pin is activated. If the counter is exceeded, then the value that remains on the Data output is an out-of-range value.

When you add any of the optional data inputs, they do not necessarily line up with the names of the fields to which they supply a value. Make sure you know which values you are inputting and the pins associated with them. (Use Show Terminals if necessary.)

If the Thru value is less than From value, /Dec must be negative or the loop does not execute.

If /Dec = 0 the loop iterates infinitely or until a Break object is encountered in the subthread.

If From equals Thru, the loop executes once.

When the subthread hosted by the For Log Range object finishes an iteration, all data containers sent during the previous iteration are invalidated before the next iteration. This prevents "old" data from a previous iteration from being reused in the current iteration. However, if flow branching is present within the iterative subthread, some objects may not execute on every iteration. Thus, data containers sent by those objects may be invalidated before other objects can execute on the data. To obtain the desired propagation in this case, use the Sample & Hold object.

Location

Flow [image] Repeat [image] For Log Range

See Also

Break, For Count, For Range, Next, On Cycle, Sample & Hold, Properties (Object), Until Break, and Properties (Object)

To Loop Part of a VEE Program


Formula

An object that performs a user-defined mathematical operation, function, or other expression specified by a mathematical formula.

Note
Refer to Function & Object Browser for information about the individual mathematical operations and functions supported by the Formula object.

Use

Use Formula to execute any desired mathematical expression supported by VEE. Many predefined operators and functions are available in the Function & Object Browser. Additionally, the browser displays user-defined functions, and ActiveX objects and controls that are available. The default Formula object has one input (A) and an example formula (2*A+3). However, the example can be replaced with any desired formula, and any number of inputs or outputs can be added as required by the user-defined formula. (If the formula requires no inputs, you may delete all inputs.)

The input(s) can be of any data type. For a relational formula (e.g. A <= B), the resulting output is a scalar Int32 with the value 0 ("false") or 1 ("true"). For other mathematical formulas, the resulting output is of a data type consistent with the inputs and with the formula itself. All nil inputs to formula objects, and to I/O transactions containing formulas are automatically converted to Real64 numbers with the value of 0.0. Refer to Understanding Data Containers for a discussion of the rules that determine the data type and shape of the result of a formula.

The outputs may be assigned values in the expressions. The Result output always contains the result of the last expression. Output terminals are essentially local variables to the Formula.

For a detailed discussion of expression syntax and math operations, refer to “Math Operations” (chapter 9) in the VEE Advanced Techniques manual.

Open View Parameters

Formula field (unlabeled) - Default is 2*A+3. You can enter any mathematical formula consisting of the operators and functions located in the Function & Object Browser. After you enter a formula and click on another area of your program, the syntax is automatically checked and any errors are reported. The Formula field can be added as a control input, which accepts array and scalar text.

The Formula object expands to include multiple lines. With the edit cursor in the formula field, press the Enter key to move the cursor to a new line.

You can add comments between expressions as shown in this example:

c=2*a+3; // a comment to the end of line
d=sin(40); // another comment
// one last comment

Notes

All of the supported dyadic operators and functions are located in the Function & Object Browser. Any of these operators and functions, including calls to UserFunctions, Remote Functions, and Compiled Functions can be used in a Formula object to construct a mathematical expression using the described syntax. (The only exception is MATLAB functions, which can only be called from a MATLAB Script object.) If any ActiveX Controls or Automation objects are available for use in VEE, you can manipulate them in Formula expressions.

Although you could perform a series of mathematical calculations using several individual, predefined Formula objects, a single Formula object containing the same expressions will perform the same calculations with higher performance. This is because a fixed amount of overhead is associated with each graphical object in the program, so a program with fewer objects will run faster.

Multiple expressions can be entered on a single line, or on multiple lines. You can lay out the expressions in the Formula object in ways that are more readable. Use semicolons to separate expressions. You can split a single expression across multiple lines; however, do not split a variable name across two lines.

You can assign values to multiple outputs using multiple expressions. If a Formula object has outputs a, b, and c (as well as Result), the expressions:

a=2*3;
b=a+2;
c=a+b

result in the appropriate values being assigned to the three output terminals. Result will have the value of the last expression, in this case, c.

Output terminals may also be used for temporary storage in an expression. The following expressions swap values in an array, where the input a contains the array, and the output tmp is used for temporary storage:

tmp=a[2];
a[2]=a[3];
a[3]=tmp

The Formula object is a Rich Text Format box. The editing features in the Formula object include all of the features you would expect to find in an RTF box including:

Full arrow key functionality

Use of Delete, End, Home, Insert, Page Up and Page Down

Full 10 key support

Expression Evaluation Details

The following description about token search order applies to any expression whose evaluation is delayed until run time. These include expressions in various objects, such as Formula, If/Then/Else, and Set Values, and expressions in Sequencer and I/O transactions.

Since VEE can call UserFunctions (either locally created or imported from a library), Compiled Functions, or Remote Functions, it is possible to have two functions with the same name. Naming conflicts in an expression are resolved by searching tokens in the following order:

1. Local input/output terminals

2. Function names found in the same library as the calling object

3. Local UserFunctions

4. Built-in functions, such as sin()

5. Imported UserFunctions, Compiled Functions, and Remote Functions. The precedence between these three is not guaranteed. To ensure the desired selection, include the library name in the call, using “dot” notation. For example, myLib.func().

The precedence for resolving function names can cause unexpected results or errors if you are not careful to avoid conflicts. Consider this example:

At first glance, this formula appears to add the sine of 30 to the number on the input terminal, sending 2.5 as the result. However, terminal names have precedence over built-in function names (see above). The expression sin(30) will attempt to “call” the input terminal and treat it as a function or ActiveX method. If sin were an Object capable of evaluating sin(30), valid results are possible. However, it is more likely that these situations are a programming mistake or misunderstanding. In the example above, the result is a program failure with a confusing error message. This type of error is not limited to input pin names; it can happen any time two tokens have the same name and their precedence is not what you wanted. It is recommended that you avoid precedence problems by choosing unique names for all your variables and functions.

The search order described above applies to Execution Mode VEE 5 and higher. In earlier Execution Modes, variable and function names were searched in a different order. For example, in VEE 4 mode, internal function like sin() had top precedence. In VEE 5 mode (and higher), local UserFunctions were given precedence over internal functions, allowing the creation of customized versions of functions like sin(). This difference in search order can have a dramatic effect on programs containing similarly named functions from different libraries. For more details, refer to “Using VEE Execution Modes” in Chapter 1 of the VEE Advanced Techniques manual.

Location

Device [image] Formula

See Also

ActiveX Automation References, ActiveX Control References, Function & Object Browser, UserFunction.

Converting Data Types on Input Terminals

Execution Mode

Processing Data (browse entire sequence)

Understanding Data Containers (browse entire sequence)

To Enter a Formula

To Use Arrays or Array Elements in Expressions

To Use the Math Operators and Functions

To Use a Record in an Expression

Properties (Object)


For Range

An object that activates the data output a specified number of times.

Use

Use For Range to execute a subthread a specified number of iterations specified by a beginning value, ending value, and increment. Use For Range to generate values that are evenly distributed between the From and Thru values.

Open View Parameters

From - The beginning value of the iteration loop.

Thru - The ending value of the iteration loop. When the value of the iterator is greater than or equal to the Thru value, the loop is completed.

Step - The increment value between the current value of the iterator and its next value.

All open view parameters are available from data inputs.

Notes

The For Range output value is a Real64 scalar ranging from the From to the Thru value.

Execution of the subthread hosted by the For Range output continues until one of the following occurs:

All objects that can, have operated. The subthread is deactivated, the iteration counter is incremented by the step value, and, if the count value is less than the Thru value, the subthread is reactivated by refiring the For Range output with the new iteration value.

A Break object operates. The subthread is deactivated and the sequence output pin is activated. Note that the value that remains on the For Range output is the same value present when the Break was encountered.

A Next object operates. The subthread is deactivated and the iteration counter is incremented by the Step value. If the count value is less than the specified Thru, the subthread is reactivated by refiring the Data output with the new iteration value, and execution of the subthread proceeds as usual. If the iteration counter has reached the Thru value, the sequence output pin is activated.

When you add any of the optional data inputs, they do not necessarily line up with the names of the fields to which they supply a value. Make sure you know which values you are inputting and the pins associated with them. (Use Show Terminals if necessary.)

If the Thru value is less than the From value, Step must be negative, otherwise the output is never activated.

If Step = 0, the loop iterates infinitely or until a Break object is encountered on the subthread.

If From equals Thru, the loop executes once.

When the subthread hosted by the For Range object finishes an iteration, all data containers sent during the previous iteration are invalidated before the next iteration. This prevents "old" data from a previous iteration from being reused in the current iteration. However, if flow branching is present within the iterative subthread, some objects may not execute on every iteration. Thus, data containers sent by those objects may be invalidated before other objects can execute on the data. To obtain the desired propagation in this case, use the Sample & Hold object.

Location

Flow [image] Repeat [image] For Range

See Also

Break, For Count, For Log Range, Next, On Cycle, Sample & Hold, Properties (Object), Until Break, and Properties (Object)

To Loop Part of a VEE Program


From

A menu item.

Use

Use From to access the following objects which are sources for I/O operations:

File

DataSet

String

Location

I/O [image] From

See Also

To


From DataSet

An object that allows the user to conditionally retrieve records from a data set.

Use

Use From DataSet to find and retrieve from a dataset either one record or all records that meet the constraints of a logical expression formula. If the record retrieved meets the constraints of the query expression, the record is output on the Rec output pin.

The default expression in the Formula field is 1, (true). Thus, either the first record found (One), or all records in the data set (All) will be output.

If you want to test values in record fields, you must use the form Rec.A for field A, Rec.B for field B, and so forth. For example, the expression:

Rec.A<10

tests each record to see if field A is less than ten. If Get records: One is specified, the first record in the dataset with field A less than 10 will be output on Rec. If Get records: All is specified, all records with field A less than 10 will be output. Note that the entire record will be output.

The following control pins may be added:

File Name - This control pin allows the user to change the name of the file from which the records will be read.

Rewind - This control pin "rewinds" the From DataSet file so that it can be re-read from the beginning of the file.

Formula - This control pin allows the user to change the formula which is used to determine which records read from the file will be output by the device.

Close - This control pin closes the file.

Open View Parameters

From DataSet - Click on the name field to display a dialog box, then select the name of the file that contains the DataSet.

Get Records - Select One or All:

If One is selected, the first record found in the data set that meets the constraints of the selection formula will be output, and From DataSet will stop executing. When One is selected, the output shape is always a scalar.

If All is selected, all records found in the data set that meet the constraints of the selection formula will be output. The output shape will always be an array. From DataSet will stop executing when it reaches the end of the file.

Search Specifier - Enter a mathematical expression to test the records in the data set. Either the first One, or All records that satisfy the expression will be output, depending on the Get Records selection. The default expression is 1 (true).

Notes

You may use any valid mathematical expression in the conditional formula. You may add additional inputs for use in the expression, just as for a Formula object. If you want to test values in record fields, express them as Rec.A, Rec.B, and so forth. The expression can be fairly complex, for example:

Rec.A > Rec.B AND Rec.C < 2.3

You must observe the normal stipulations for determining True or False for conditional expressions:

For any relational test (for example, equality between two operands), if one operand is an array, the other must be either a scalar or an array of the same size and shape. If the first operand is equal to the second, the result is True; otherwise it is False.

If both operands are of type Coord, they must have all of their independent variables and dependent variables match exactly for the result to be True. If independent variables do not match, an error is returned. Complex, PComplex, and Spectrum operands must have both parts match for the operation to return True. Enums are converted to Text for comparison.

Arrays must have all the respective values of both operands equal for the operation to return True.

You may wish to bring in a DataSet (an array of records) from a file, edit it, and then save it back to the file. This can be accomplished with a From DataSet, a Record Constant using the Default Value input pin, and a To DataSet. See Record Constant for more information.

You may add an EOF output pin to this object. When the object executes and there are no records meeting the query expression constraints, or you are already at the end of the DataSet, this pin will fire. Otherwise, an End of file with no Data Found error will result when this condition occurs.

If you have multiple From DataSet objects reading from the same file, they will share the file pointer. That is, all of the objects read sequentially through the file, no matter how many objects there are reading the file. See From File for more detail.

Location

I/O [image] From [image] DataSet

See Also

Build Record, Formula, Record Constant, To DataSet, UnBuild Record, and Properties (Object)

To Read Data from a File


From File

An object that reads data from a file using I/O transactions.

Use

Use From File object to read a wide variety of file encodings and formats. From File is especially useful for importing data files generated by other software packages.

When several From File objects refer to the same disc file, a single read pointer is maintained for all such objects even if they are in different threads or different contexts. This means that data read by one From File object is not reread by another From File object using the same file unless a REWIND operation has been done on the file. The file is opened and the file pointer is reset to the beginning of the file (implied REWIND) when the first From File object for that file operates after PreRun. All files are closed when the program stops.

From File Actions:

READ - Reads data from a file using the specified encoding and format.

EXECUTE - REWIND repositions the file's read pointer to the beginning of the file without erasing the contents of the file. CLOSE closes an open file. DELETE deletes the file.

WAIT - Waits the specified number of seconds before executing the next transaction.

From File Encodings:

TEXT - Reads text ASCII files written by VEE or other software packages.

BINARY - Reads all data types from a machine-specific binary format.

BINBLOCK - Reads all VEE data types from binary files with IEEE 488.2 definite length block headers.

CONTAINER - Reads all data types from a machine-specific text format.

Open View Parameters

Open View provides a field for the data file name, followed by a list of available transactions. The data file name can be added as a control input.

Open View shows the list of file transactions to be executed.

Object Menu

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Print Trans - Prints the detailed dialog box that describes the currently highlighted transaction.

Notes

An EOF (End of File) output terminal can be added with Add Data Output. EOF is a special output terminal that propagates with a nil container when a transaction attempts to read data past the End of File. When an End of File condition is detected and the EOF output is activated, none of the other data outputs are activated, even if they contain newly read data.

If EOF is detected and there is no EOF output pin, an error is returned.

To read all of the data in the file, use a READ ... ARRAY TO END: transaction.

Short Cuts

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Location

I/O [image] From [image] File

See Also

To File, To Read Data from a File, and Properties (Object)

VEE Advanced Techniques, "Using Transaction I/O."


From String

An object that reads data from a string by using transactions.

Use

Use From String to read a wide variety of encodings and formats from textual data in a string.

If a one-dimension array of Text is passed to the AString input, the From String transactions will act in the same way as if those lines of text were being read from a file with the From File object. That is, an array of Text will be treated as a single stream of text with new-line characters between each string element.

From String Actions:

READ - Reads data using the specified encoding and format.

WAIT - Waits the specified number of seconds before executing the next transaction.

From String Encodings:

TEXT - Reads all data types from the AString input.

CONTAINER - Reads all data types from a VEE specific text format.

Open View Parameters

The open view shows the list of transactions to be executed.

Object Menu

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Print Trans - Prints the detailed dialog box that describes the currently highlighted transaction.

Notes

From String is a useful debug tool to explore how READ TEXT transactions operate. Connect a Text Constant object to the From String input terminal labeled AString, and connect a Logging AlphaNumeric display to the From String output terminal to immediately view the results. It's also useful to parse a string returned from an instrument.

Short Cuts

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Location

I/O [image] From [image] String

See Also

From, From File, To String, and Properties (Object)

To Convert a String into a Number

VEE Advanced Techniques, "Using Transaction I/O."


Function & Object Browser

A Device menu item for accessing mathematical and logical functions; and ActiveX Objects.

Use

Use Function & Object Browser to access the Function & Object Browser. From the browser, you can choose from:

Operators

Built-in Functions

MATLAB Functions

Local User Functions

Imported User Functions

Remote User Functions

Compiled Functions

ActiveX Objects

.NET/CLR Objects

VEE Objects

Instruments

Notes

The Function & Object Browser dialog box contains either four or five fields. The configuration changes when ActiveX Objects is selected.

Type: - Select an item in this field to display the related entries in the other fields. Operators and Built-in Functions are provided with VEE. Local, Imported, and Remote User Functions and Compiled Functions are created by the user. Selecting ActiveX Objects splits the Category field into the Library and Class fields. Selecting .NET/CLR Objects splits the Category field into the Assembly, Namespace, and Type fields.

Category: - <All> contains a listing of all of the functions of the selected Type. Other Category entries break down the available functions into smaller groups.

Library: - Appears with the Class field when Type is set to ActiveX Objects. ActiveX type library names appear in the Library field if you have selected ActiveX automation or control type libraries in Device [image] ActiveX Automation References or ActiveX Control References. Select names in the Library and Class fields to view the properties, methods, and events that are available for an ActiveX object.

Class: - Appears with the Library field when Type is set to ActiveX Objects. The names that appear in the Class field are the classes contained in the ActiveX type library highlighted in the Library field. Select a class name to view the properties, methods, and events that are available for an ActiveX object.

Assembly: - Appears with the selection of the .NET/CLR Object. Assemblies are the reusable, versionable, self-describing building blocks of .NET applications. An Assembly is the fundamental building block of the .NET Framework. Assemblies appear in the Assembly field when you have selected them from the Device [image] .NET Assembly References.

Namespace: - Appears with the selection of the .NET/CLR Object. To see namespaces in the Namespace field, you must have selected at least one Assembly that has namespaces associated with it. Select namespaces from the Namespace field to see a partial listing of the members that are available within that namespace.

Member: - If Operators or any function names are highlighted in Type, this lists the names of operators and functions available in the selected Category. A scroll bar is provided for lists that are larger than the provided space. To get an operator or function from this list to put in a program, click on the Member name and click Create Formula/Create Call or simply double-click on the name.

If ActiveX Objects is highlighted in Type, the Member list contains the properties, methods, and events available for an ActiveX object that are related to the highlighted Library and Class names. To create formulas in a program for properties and methods, click on the Member name and click Create Formula or double-click on the name.

If .NET/CLR is highlighted in Type, the Member list contains constructors, properties, methods, and enumerators available for the .NET/CLR object selected in Type.

You cannot create anything from the event names. To create event handlers for an ActiveX automation object, declare a variable of type Object using Declare Variable, enable its events, then use Create Event Handler in the object menu. To create event handlers for an ActiveX control, you must add the control to your program first (Device [image] ActiveX Controls), then use Create Event Handler in the object menu.

Description Field - This is the large field at the bottom of the dialog box. For built in functions, VEE provides a description string for the highlighted function. For local, imported, and remote user functions, VEE displays the contents of the Show Description dialog box for the highlighted function. For ActiveX objects, VEE displays the formula syntax with parameters.

For additional information on any of the names in the Member list, highlight a name and click on Help. The information about Operators and Built-in Functions is available from VEE Help. Information about ActiveX Members is available if vendors have supplied online help for them.

Location

Device [image] Function & Object Browser

See Also

ActiveX Automation References, ActiveX Control Host, ActiveX Control References, ActiveX Controls, Assignment, Call, Declare Variable, Delete Library, Edit UserFunction, Import Library, Miscellaneous Operators, and UserFunction.

To Use the Math Operators and Functions

See the manual, VEE Advanced Techniques, for details about using ActiveX objects in VEE.


Function Generator

An object that outputs a Waveform.

Use

Use Function Generator to generate a Waveform of your own specifications.

Properties

ErrorOnAliasing - Evaluates whether Num Points divided by Time Span (same frequency) is less than twice the specified frequency. If it is, an error is returned. The purpose of this evaluation is to determine whether the points being generated provide an accurate representation of the function being generated. A selected check box generates a literal presentation of points. Default is on.

Open View Parameters

All of these parameters may be set from the open view or added as data inputs.

Function - The shape of the waveform (Sine, Square, Triangle, and so forth). Default is Cosine.

Frequency - The frequency of the waveform in Hertz. This parameter is ignored if the Function is set to DcOnly. Default is 200 Hertz.

Amplitude - The absolute value of the maximum and minimum values in linear units before any dcOffset is added. Default is 1.

dcOffset - The offset of the waveform (the amount it is shifted up or down). Default is 0.

Phase Units - Degrees (Deg), radians (Rad), or gradians (Grad). Phase Units overrides the current Trig Mode for the phase value. Default is Deg.

Phase - The shift of the waveform by a portion of a period. The waveform is shifted toward negative time for positive values of phase. Phase is ignored when Function is set to DcOnly. Default is 0.

Time Span - The duration of the waveform (in seconds). Default is 20m seconds.

Num Points - The number of points in the waveform. The time between points in the waveform is Time Span/Num Points. Num Points must be positive. Default is 256.

Notes

There are the same number of points as sampling intervals. Each point is at the beginning of the sampling interval.

Location

Device [image] Virtual Source [image] Function Generator

See Also

Build Arb Waveform, Comparator, Noise Generator, and Pulse Generator.


Gate

An object that passes the input data to the data output pin when the sequence in pin is activated.

Use

Use Gate to hold the container until another action occurs (and activates the sequence input pin).

Notes

If the sequence input pin is not connected, there is no "holdoff" effect. Therefore, Gate passes the data from data input pin to data output pin whenever the data input pin is activated.

The data that flows into Gate is not stored; the container on the data input pin is the container output when the sequence input pin is activated.

Location

Flow [image] Gate

See Also

DeMultiplexer, JCT, and Properties (Object)

To Output a Value on Timeout


Get Field

An object that allows the user to unbuild a record and recover one of its fields or sub-fields.

Use

Use Get Field to extract a field or sub-field of a record. The Get Field object is simply a Formula object that is initialized with an input terminal Rec and the expression Rec.A. Use the "dot" syntax to specify the field that you want to extract from the record input. For example, Rec.A extracts the A field from the Rec record input.

Open View Parameters

Formula field (unlabeled) - The default is Rec.A. You can enter any mathematical formula allowed in the Formula object, but normally you would want to use the A.B dot syntax to extract a field from a record. You can add a Formula control input.

Notes

The Get Field object is actually just a Formula object that has been initialized with a Rec input and the expression Rec.A. You can use any expression in Get Field that you can use in a Formula object, but to extract a field you will need to use the "dot" syntax like Rec.A or A.B.C.

The A.B dot syntax in Get Field is fully supported in all Formula objects. These include Formula, If/Then/Else, Get Values, Set Field, and all transaction devices (To File, To String, etc.)

Note the distinction between the Get Field, UnBuild Record, and SubRecord objects.

The Get Field object works like a Formula object, in that it uses dot syntax (A.B) to unbuild a record. Note that Get Field allows you to unbuild a record of records in one step by using an expression such as A.B.C. This process would require two UnBuild Record objects.

The UnBuild Record object has outputs for the Name List and Type List of the input record fields. The other (optional) outputs A, B, etc. of the UnBuild Record object return the same results as would multiple Get Field objects.

The SubRecord object differs from UnBuild Record and Get Field in that its output is always a record. The SubRecord device allows you to either include or exclude a list of fields from a record to form a subrecord.

Location

Data [image] Access Record [image] Get Field

See Also

Build Record, Formula, Record Constant, Set Field, SubRecord, and UnBuild Record.

To Extract a Field from a Record


Get Mappings

An object that outputs mapping information about a container.

Use

Use Get Mappings to get information about mapped arrays. Get Mappings outputs the type of mapping (log or linear) and the beginning and ending values of each mapping for each dimension.

Open View Parameters

NumDims - The number of dimensions in the input array, which is an integer value with a minimum value of 1 and a maximum value of 10.

Notes

If the input array is not mapped, Get Mapping outputs Linear (0,n-1), where "n" is the number of points in that dimension of the input array.

Get Mapping does not allow a Coord as input, because the Coord data type has explicit mappings.

Num Dims must match the number of dimensions in the input array.

If the Num Dims value is changed, the view automatically creates or deletes output terminals so that the number of outputs, three for each dimension, matches the value of the Num Dims value. For each dimension, Get Mappings has three data output terminals.

Short Cuts

To view the mappings of a mapped array, use Line Probe on a line or open the terminal to view the container data.

Location

Data [image] Access Array [image] Get Mappings

See Also

Line Probe, Set Mappings, Properties (Object), UnBuild Data, and Properties (Object)


Get Values

An object that extracts elements from an array.

Use

Use Get Values to access particular elements of an array. You can extract single or multiple elements, columns, or rows from one or more arrays.

Use Get Values to get information about a set of data such as: the data type, the number of dimensions, the dimension sizes, and the total size of all the array elements of the input array.

Open View Parameters

Formula field (unlabeled) - Specifies the elements of the array that you are extracting. The specific symbols associated with arrays are:

Comma (,) - Separates element dimensions.

Colon (:) - Indicates a set of elements inclusively.

Asterisk (*) - A wild card to indicate the entire column or row.

Example

To extract the 2nd column from a two dimensional array [3,3] elements, keeping in mind that array indices are zero-based:

- - - -
|1 2 3 | | 2 |
|4 5 6 | Array [*,1] outputs: | 5 |
|7 8 9 | | 8 |
- - - -

Notes

All arrays are zero-based.

There must be exactly one specification for each array dimension.

The Get Values object is actually just a Formula object that has been initialized with an Ary input, the expression Ary, and several outputs. You can use any expression in Get Values that you can use in a Formula object.

The Ary[2,3] subarray syntax in Get Values is fully supported in all Formula objects. These include Formula, If/Then/Else, Get Field, Set Field, and all transaction devices (To File, To String, etc.).

The data type string output value is the same as the string returned from the typeName() function.

Location

Data [image] Access Array [image] Get Values

See Also

Array, Formula, Set Values, typeName(), UnBuild Data, and Properties (Object)

To Extract Values from an Array


Get Variable

An object that gets the value of a variable that has already been created in the execution of the current program.

Use

Use the Get Variable object to get a variable (by name), for use as data in a VEE program. The variable must have been previously created or initialized by a Set Variable or Formula assignment object within the program.

Undeclared Global Variables created (with Set Variable) in one context of a program can be used as data in another context of that program such as UserObjects and UserFunctions. For example, a Set Variable in the root context of a program could create an undeclared global variable, which could then be used as data by including a Get Variable in a UserObject. This is especially useful when the program contains several nested layers of UserObjects.

Variables may also be used by name in the expression fields of the following objects: Formula, If/Then/Else, Get Values, Get Field, Set Field, and all objects using expressions in transactions, including To File, From File, Direct I/O, From Stdin, To/From Named Pipes, and Sequencer. This direct usage is often more useful than the Get Variable object.

Open View Parameters

The open view displays a field for the name of the variable. The name is not case sensitive (either lower-case or upper-case letters may be used). Thus globalA is the same variable as GLOBALa. The name field may be added as a control input. The name can only be the name of the variable, it cannot be an expression such as globalA+1 or globalRec.field. Use expressions such as these in a Formula.

Notes

To avoid unexpected results, your program must ensure that a variable is set with Set Variable before a Get Variable object (or an object that includes the variable name in an expression) executes. Generally, the best way to ensure this is to connect the sequence output pin of the Set Variable object to the sequence input pin of the Get Variable object, or other object that uses the variable. However, there are cases when the sequence input pin need not be connected. For further information about this, refer to "Variables" in VEE Advanced Techniques.

In Default Preferences, if Delete Variables at PreRun is on (the default), all variables are deleted before your program executes. If Delete Variables at PreRun is turned off, variables will not be deleted, and you must program carefully to avoid propagating invalid data.

Global variables are truly global since they are not defined at a UserObject level. A global variable that is defined in one context of a program can be used in any other context within the program. For example, you can define a global variable with a Set Variable object in the root context of the program, and then include a Get Variable to get that global variable in a UserObject. However, you will need to avoid name conflicts throughout the program:

If two or more Set Variable objects attempt to set the same variable (with the same name), the current value will be overwritten as each Set Variable executes. This may result in unexpected behavior if you are unaware of the duplicate names.

If there is a data terminal variable with the same name as a variable, the data terminal variable takes precedence.

For further information, refer to " Variables " in the VEE Advanced Techniques manual.

Location

Data [image] Variable [image] Get Variable

See Also

Default Preferences, Delete Variable, Set Variable, View Variables, and Properties (Object)

To Use a Variable


Help (Object Menu)

Gives help on this object.

Use

Use Help to view the reference page for this object. To exit help, close the help window.

Notes

To get help on multiple objects, terminology, or procedural information, use the Help menu on the VEE menu bar.

Help for Instrument Panel or Component Driver contains help about the driver itself.

Shortcut

To get help quickly on a selected object, press F1.

Location

On each object menu [image] Help

See Also

Object Menu and Properties (Object).


Horizontal Paddle

See Toggle Control.


Horizontal Rocker

See Toggle Control.


Horizontal Slide

See Toggle Control.


If A ~= B

An object that branches output if the data input values are almost equal.

Use

Use If A ~= B to test for approximate equality and branch based on that test.

Notes

If A ~= B is a pre-configured If/Then/Else object that tests the approximate equality of the inputs.

If the inputs are approximately equal, the Then output is propagated with an Int32 scalar 1, else the Else output is propagated with an Int32 scalar 0.

The test for "almost equal" is slightly different for Complex and Polar Complex numbers. For two real numbers (a and b) the test for "almost equal" is:

a - b <= a * 10E-7

However, for two Complex values (a and b) the test is:

re(a) - re(b) <= mag(a) * 10E-7

where:

re(a) is the real component of a

re(b) is the real component of b

mag(a) is the vector magnitude of a

Location

Flow [image] Conditional [image] If A ~= B

See Also

Comparison, Conditional, If/Then/Else, If A == B, If A != B, If A < B, If A > B, If A <= B, and If A >= B.

To Branch within a VEE Program


If A == B

An object that branches output if the data input values are equal.

Use

Use If A == B to test for equality and branch based on that test.

Notes

If A == B is a pre-configured If/Then/Else object that tests the equality of the inputs.

If the inputs are equal, the Then output is propagated with an Int32 scalar 1, else the Else output is propagated with an Int32 scalar 0.

Location

Flow [image] Conditional [image] If A == B

See Also

Comparison, Conditional, If/Then/Else, If A ~= B, If A != B, If A < B, If A > B, If A <= B, and If A >= B.

To Branch within a VEE Program


If A >= B

An object that branches output if one input is greater than or equal to the other.

Use

Use If A >= B to test for one input being greater than or equal to the other, and branch based on that test.

Notes

If A >= B is a pre-configured If/Then/Else object.

If the value of A is greater than or equal to the value of B, the Then output is propagated with an Int32 scalar 1, else the Else output is propagated with an Int32 scalar 0.

Location

Flow [image] Conditional [image] If A >= B

See Also

Comparison, Conditional, If/Then/Else, If A ~= B, If A == B, If A != B, If A < B, If A > B, and If A <= B.

To Branch within a VEE Program


If A > B

An object that branches output if one input is greater than the other.

Use

Use If A > B to test for one input being greater than the other and branch based on that test.

Notes

If A > B is a pre-configured If/Then/Else object.

If the value of A is greater than the value of B, the Then output is propagated with an Int32 scalar 1, else the Else output is propagated with an Int32 scalar 0.

Location

Flow [image] Conditional [image] If A > B

See Also

Comparison, Conditional, If/Then/Else, If A ~= B, If A == B, If A != B, If A < B, If A <= B, and If A >= B.

To Branch within a VEE Program


If A <= B

An object that branches output if one input is less than or equal to the other.

Use

Use If A <= B to test for one input being less than or equal to the other, and branch based on that test.

Notes

If A <= B is a pre-configured If/Then/Else object which tests for the inequality of the inputs.

If the value of A is less than or equal to the value of B, the Then output is propagated with an Int32 scalar 1, else the Else output is propagated with an Int32 scalar 0.

Location

Flow [image] Conditional [image] If A <= B

See Also

Comparison, Conditional, If/Then/Else, If A ~= B, If A == B, If A != B, If A < B, If A > B, and If A >= B.

To Branch within a VEE Program


If A < B

An object that branches output if one input is less than the other.

Use

Use If A < B to test for one input being less than the other, and branch based on that test.

Notes

If A < B is a pre-configured If/Then/Else object.

If the value of A is less than the value of B, the Then output is propagated with an Int32 scalar 1, else the Else output is propagated with an Int32 scalar 0.

Location

Flow [image] Conditional [image] If A < B

See Also

Comparison, Conditional, If/Then/Else, If A ~= B, If A == B, If A != B, If A > B, If A <= B, and If A >= B.

To Branch within a VEE Program


If A != B

An object that branches output if the inputs are not equal.

Use

Use If A != B to test for inequality and branch based on that test.

Notes

If A != B is a pre-configured If/Then/Else object which tests for the inequality of the inputs.

If the value of A is not equal to the value of B, the Then output is propagated with an Int32 scalar 1, else the Else output is propagated with an Int32 scalar 0.

Location

Flow [image] Conditional [image] If A != B

See Also

Comparison, Conditional, If/Then/Else, If A ~= B, If A == B, If A < B, If A > B, If A <= B, and If A >= B.

To Branch within a VEE Program


If/Then/Else

An object that branches execution flow based on the values of its input(s).

Use

Use If/Then/Else to make decisions about which subthread branch to execute. You may enter any legal math expression in the formula boxes on the open view.

Only the output pin associated with a true condition is activated. The container output is the value of the expression.

If/Then/Else evaluates the expressions in the If/Else If clauses (top to bottom) until one evaluates to a non-zero value. This non-zero container is copied to that expression's corresponding output and that one output is propagated. Only one output is propagated. If none of the expressions evaluate to a non-zero value, then the Else output is propagated with the zero value of the last evaluated expression.

If any of the expressions evaluate to a value that is an array, the array values are checked to see if they are either all zero or all non-zero. If the values are mixed, an error is returned since it cannot be determined whether the array is true or false. To produce a scalar, use expr == 0 or expr!=0 since the equality comparisons always return a scalar.

Open View Parameters

Enter an expression in the edit field.

Object Menu

Add Else/If - Adds a condition that is tested if the previous condition is not met and an output pin that is activated if the condition is true. The new condition is added below all current conditions.

Insert Else/If - Opens a dialog box listing the current conditions, letting you insert a new condition (and related output pin) before any of the current ones.

Delete Else/If - Deletes a condition. After selecting Delete Else/If, select a condition to delete from a dialog box that is displayed.

Delete Else/If is not available when only one condition is displayed. This feature is only available if you have at least two Else/If conditions.

Notes

You may use any legal mathematical statements in the conditional statement. You may add additional inputs for use in the expressions, just as in the Formula object.

To output a value when it meets a condition, multiply the condition statement by the value. For example, to output the value in the variable A when A is less than 10, use the following expression in the edit field:

(A<10)*A

When this condition is true, the value of A is output on the Then data output pin. This technique works only for true statements (which output to Then or Else If data output pins). Also, this technique only works when A does not equal 0. If A equaled 0, the result of the equation would be false and zero would be output on the Else data output pin. The Else data output pin will always return zero if the condition is false.

The objects under Flow [image] Conditional are pre-configured If/Then/Else objects that test for a specific condition.

To get a TRUE|FALSE (1|0) output, use the Comparison objects. They are available in the Function & Object Browser under Type: Operators, Category: Comparison.

Also note the difference between Comparison and Conditional objects. Comparisons are formulas with output 0 or 1. Conditionals are If/Then/Else and have two outputs, of which one activates.

Location

Flow [image] If/Then/Else

See Also

Comparison, Conditional, Formula, Triadic Operator, and Properties (Object)

To Branch within a VEE Program


Import Library

An object that loads a library of UserFunctions, Compiled Function definitions, or Remote Function definitions into a running VEE program.

Use

Use Import Library to load a library of one of the following kinds of functions into your VEE program at run time:

UserFunction - Import Library loads all of the UserFunctions from a specified file. (UserFunctions are created by selecting the Make UserFunction selection on the object menu of a UserObject. You create a library by creating several UserFunctions and saving them to a file.)

Compiled Function - Import Library attaches a Dynamically Linked Library, or DLL to the VEE process, and parses the Definition File declarations. (Compiled Functions are programs written in a programming language such as C, which are dynamically linked to the VEE process. Refer to VEE Advanced Techniques for further information.)

Remote Function - Import Library starts a VEE process on a remote host and loads the Remote File into the VEE process. (Remote Functions are actually UserFunctions loaded by the remote VEE process, but callable on the local host. Refer to "User-Defined Functions/Libraries" in the VEE Advanced Techniques manual for further information.)

Once the library of UserFunctions, Compiled Functions, or Remote Functions is loaded, the functions are executed (called) by name using the Call Function object.

Open View Parameters

Library Type - A dialog box allows you to choose UserFunction, Compiled Function, or Remote Function.

Library Name - Assign a logical name to the library you are loading.

File Name - (UserFunction or Compiled Function only.) Select the file that contains the library to import. For Compiled Functions this is a .dll.

Definition File - (Compiled Function only.) Select the definition file for the Compiled Function. This is the file containing the prototypes for the function calls (the .h file).

Host Name - (Remote Function only.) Enter the name of the remote host where the Remote Function will operate.

Remote File Name - (Remote Function only.) Enter the file name (complete path) of the library (e.g. /users/MyUserName/MyDir/MyFile).

Remote Timeout - (Remote Function only.) Set the timeout in seconds for the Remote Function.

Geometry - (Remote Function only.) Enter the initial geometry for the window that contains the view of the remote VEE, in the standard geometry format. For example, 800x500+0-0 (width x height+/-xoffest+/-yoffset.

Remote Debug - (Remote Function only.) When this checkbox is selected, all of the UserFunctions within the library will execute in debug mode (i.e. you will be able to perform debugging on them such as setting breakpoints and doing line probes). The program will pause just before executing each remote UserFunction. This setting works with UserFunctions whether or not they have panel views.

Object Menu

Load Lib - Immediately loads the specified library into VEE. If a library with the same name was previously loaded, that library is deleted and overwritten with the new library.

Delete Lib - Immediately deletes the specified library from VEE. (This provides the same functionality as the Delete Library object.)

Notes

The Import Library object is generally used for advanced operations where you have developed sets of UserFunctions, Compiled Functions, or Remote Functions into libraries. Import Library allows you to load such libraries dynamically at run time. For UserFunctions you can save considerable space by creating a library and loading it with Import Library -- you don't have to save copies of the UserFunctions in each individual program. Also, when you develop a library of standard UserFunctions, you can keep the source code for those functions in a single place. Refer to VEE Advanced Techniques for a detailed discussion of using UserFunctions, Compiled Functions, and Remote Functions.

UserFunctions loaded at run time by Import Library operate exactly like any locally-created UserFunction within the program. You can execute any UserFunction with the Call Function or Formula object. However, only locally created UserFunctions can be edited within the program. Imported UserFunctions cannot be edited, but they may be viewed for debugging purposes using Edit UserFunction. If you want to edit any of the external UserFunctions, you must open the library file that contains the UserFunctions and use the Edit UserFunctions selection on the Edit menu. Once you have edited the UserFunction, save the file back to the disk.

Doing an Import Library from a program file containing an embedded I/O configuration does not import any of that I/O configuration. See Embedded I/O Configurations and Merging.

Location

Device [image] Import Library

See Also

Call, Delete Library, Edit UserFunction, UserFunction, UserObject, and Properties (Object)


Indicator

This menu choice offers you a variety of analog-type graphical displays based on Scalar numeric input values.

Use

The Indicator menu provides you with a choice of five different VEE objects for graphical display of Scalar numeric input values. These five objects are:

Meter - Displays Scalar numeric values on an analog-type meter scale.

Thermometer - Displays Scalar numeric values using a color bar inside a graphical thermometer.

Fill Bar - Displays Scalar numeric values graphically using a color bar.

Tank - Displays Scalar numeric values graphically using a color bar inside a graphical tank.

Color Alarm - A graphical alarm indicator that displays different colors and text strings, depending on the Scalar input value.

Location

Display [image] Indicator

See Also

Color Alarm, Fill Bar, Meter, Tank, and Thermometer.

To Show a Color Alarm

To Show an Analog Display of Data


Instrument Event

An object that captures events generated by GPIB or VXI devices.

Use

The Instrument Event object can be configured to detect various device events. Depending upon configuration, the object may wait for the event, giving up execution to other parallel threads, or it may simply return a boolean (0 or 1) or other indicator of the state of the device.

If the Instrument Event object has been configured to wait for the event, then upon the event the object will execute. Any thread hosted by this object will have priority over any other parallel threads, and will execute to completion. If the Instrument Event object has been configured to simply return an indicator of device state, the thread containing it will have normal priority, and will execute in parallel with any other threads.

Open View Parameters

Device - The currently selected device is displayed in the Device field. Click on this field to display a list of the currently configured GPIB and VXI devices.

Event - Allows selection of specific events. Click on this field to display the choices:

Spoll - Returns the status byte of GPIB devices and message-based VXI devices. If an GPIB device has been selected, the only possible selection is Spoll. The returned status byte is used with the Mask value.

SRQ - For VXI, an SRQ is generated from a message-based device when the device sends either a VME interrupt or a signal register write that is a request-true event. When this asynchronous event occurs, the device's status byte is returned, thus causing the device to generate a request-false event. The returned status byte is used with the Mask value.

Signal Interrupt - This asynchronous event is generated from either message-based or register-based VXI devices. The event occurs when the device sends either a VME interrupt or a signal register write that is a device-defined event or an undefined event. The returned 32-bit value is the value placed in the signal write register, or the value placed on the VXI Bus when the device does an interrupt acknowledge (IACK). This value is used with the Mask value.

Action - Determines the execution behavior of the Device Event object upon detection of the specified event, in conjunction with the specified bit mask.

No Wait - Execute immediately, outputting the current state of the configured event, as specified by a 32-bit integer, to the status pin. This value is either the boolean value FALSE (0) or a device-dependent bit pattern. If the event choice is Spoll, the low byte of the returned integer is the status byte of the device. For the two asynchronous VXI events, a FALSE (0) is returned if the event has not occurred. If the event has occurred, the device-dependent bit pattern is returned.

All Clear - Wait for the event to occur and use the returned value in a logical AND operation with the Mask value. If no bit is set, then execute by placing the original, unmasked value on the status output pin.

Any Set - Wait for the event to occur and use the returned value in a logical AND operation with the Mask value. If any bit is set in the resulting bit pattern, then execute by placing the original, unmasked value on the status output pin.

Mask - You can enter a value to be used as a bit mask (default = 0). The Mask value is used in a logical AND operation with the value returned by the device when the specified event occurs.

Notes

The execution behavior of the Instrument Event object can either be asynchronous or synchronous as determined by the choice of the Action parameter. No Wait specifies a synchronous, polling behavior. The object executes immediately and any attached thread will have the same priority as all other threads currently executing. Choosing Any Set or All Clear causes the Device Event object to wait until both the event has occurred, and the logical AND of the Mask value and the value returned by the device satisfies the "any bit set" or "no bit set" criteria. When both of these conditions have been satisfied, the object executes. Any thread attached will have a higher priority, and will execute to completion, blocking all other concurrently executing threads.

Strictly speaking, the Spoll event is not a true asynchronous event as are the VXI SRQ and Signal Interrupt. By using a Mask value and the appropriate action, Any Set or All Clear, the status byte can be evaluated continuously with the Mask value until the correct bits are modified by the device. The object will wait until this occurs, allowing concurrent threads to continue execution. For the Spoll event, choosing the No Wait Action is identical to specifying the All Clear Action with a mask value of zero -- the Device Event object executes immediately.

For the true asynchronous events SRQ and Signal Interrupt, the device waits until the event occurs, allowing concurrent threads to continue executing. Once the interrupt occurs, the resulting status byte, signal write register contents, or IACK value will be logically ANDed with the mask value. The object executes only if the resulting bit pattern satisfies the Any Set or All Clear criteria. If the All Clear action is specified with a mask value of zero, the Device Event object will execute when the interrupt occurs.

A control pin is available as an input to programmatically change the device timeout period.

Location

I/0 [image] Advanced I/O [image] Instrument Event

See Also

Interface Event, Interface Operations, and Properties (Object)

To Poll GPIB Instruments


Instrument Manager

Displays the Instrument Manager dialog box.

Use

Select I/O [image] Instrument Manager to display the Instrument Manager dialog box. Use this dialog box to add, delete, edit, locate, and configure interfaces and instruments. You can also create the following types of instrument I/O objects: Direct I/O, VXIplug&play Drivers, Panel Drivers, and Component Drivers.

Dialog Information

The Instrument Manager dialog box is divided into the following areas:

Instrument List - The tree view contains three nodes: My Configuration (the root), interfaces, and instruments. Click on a node to select it. The selected node controls the actions performed by buttons in other areas. To edit an interface or instrument in the list, double-click it.

Auto Discovery - This area controls the automatic discovery and configuration of instruments and their drivers. There are three buttons in this area:

Find Instruments - This button starts an automatic search for all instruments available on the selected interface. If the root node is selected, all local interfaces are searched for instruments. The Auto Discovery Settings dialog (displayed by clicking the Settings… button) controls some details of this search.

Note: If you are using a GPIB to LAN interface, due to lengthy time-out periods when trying to find LAN devices from the root node, Agilent recommends launching the find operation from the GPIB interface. Find operations launched in this manner will work properly and quickly.

Configure Drivers - This button performs an identification of the selected instrument and configures any available drivers for that instrument. Note that only IEEE-488.2 (and most VXI) instruments can be identified. Instruments on less sophisticated interfaces, like RS-232, cannot be automatically detected or identified.

Configure Drivers operates on a selected instrument in the Instrument List. It is only available when an instrument is selected; if the root node or an interface is selected, this button is grayed out (unavailable).

If this button is grayed out when an instrument is selected, then no instrument I/O is available on your system. In this case, you need to install the appropriate I/O Libraries (VISA, SICL, etc.) to support your instrument interface(s).

Settings... - This button brings up the Auto Discovery Settings dialog, which controls some of the actions performed during instrument discovery.

If Detect only is selected, the Find Instruments button simply detects whether a device is present at each bus address.

If Detect, identify, and configure... is selected, the Find Instruments button also performs an identification and driver configuration for each instrument detected. (This is the same configuration performed by the Configure Drivers button.)

If Ask before sending... is checked, a confirmation dialog is presented before *IDN? is sent to identify each instrument. If not checked, *IDN? is sent to all instruments without operator confirmation. You may want the confirmation dialog if your system contains old, non-IEEE-488.2 instruments.

Instrument - This area allows you to change instrument configurations. There are three buttons in this area:

Add... - This button allows you to add an instrument to the list. When you click on Add, the Instrument Properties dialog box appears. You can configure the instrument by filling out the fields in this dialog box.

Remove - This button deletes the currently selected instrument from the list. Interface nodes are automatically removed when all instruments associated with the interface are removed. If you make a mistake, just choose the Cancel button to recover. This will exit the Instrument Manager without saving any changes.

Properties- This button allows you to edit the selected interface or instrument configuration. Clicking on Properties opens the Interface Properties or Instrument Properties dialog box. You can also double click on the interface or instrument that you want to edit.

Create I/O Object - This area determines the type of instrument I/O object that is added to your VEE program. Click on one of the driver buttons to add an instrument I/O object to the work area. Buttons are grayed out when those drivers are not available for the selected instrument.

There are five buttons at the bottom of the dialog box: OK, Save, Cancel, Print, and Help.

OK - Click on this button to retain the instrument configuration with the current session, and close the Instrument Manager.

Save - Click on this button to save the instrument configuration in the veeio configuration file, and close the Instrument Manager. This button is grayed out if the instrument configuration is embedded in the VEE program.

More about Auto Discovery

Find Instruments operates on the selected node in the Instrument List. If the root node (typically "My Configuration") is selected, then all local GPIB and VXI interfaces are searched. If an individual interface is selected, only that interface is searched. GPIO and RS-232 interfaces cannot be searched for instruments because they do not support any standard protocol for automatic instrument detection.

The Find Instruments operation does not search LAN-gatewayed interfaces when run from the root node, but it will search for remote instruments if run from a gatewayed interface node. The Find Instruments operation does not search for new LAN-gatewayed interfaces. The initial entry for a gatewayed interface must be made manually.

The search can produce the following results in the Instrument List area:

Instruments that were already listed in the instrument configuration and are physically present on the interface are marked by a computer icon.

Instruments that were not already listed in the instrument configuration file, but are physically present on the interface are added to the list and marked by a question mark.

Instruments that were already listed in the instrument configuration, but are not physically present on the interface are not marked.

Note that the Auto Discovery process does not delete instruments from the current configuration. It can add new entries and note if the existing entries correspond to live instruments or not. However, an entry is not removed simply because the corresponding instrument is not alive when the Find Instruments button is pressed. This conservative approach is welcomed by most users in most situations. The one small disadvantage is that you cannot create an I/O configuration that is exactly equal to the currently-connected instruments by pressing just one button. If you need to create a configuration which contains only the instruments connected locally at a given time, first delete all the instrument entries, then press Find Instruments.

More about Saving an I/O Configuration

The instrument configuration can be saved in a separate file or embedded in the VEE program. If you want to use a separate file, the configuration is saved in vee.io. A VEE program that has I/O objects relies on the instrument I/O configuration file to find the instruments referenced in the program. If the program is not matched to the configuration file (for example, if a program file is copied from one machine to another without copying the corresponding vee.io file), an object might not be able to execute because its associated instrument is not configured.

As an alternative, instrument configuration information may be embedded in the VEE program file. To create an embedded configuration, choose File [image] Save As… (or Save for a new program file), and check the Save I/O configuration with program box in the Options area. Then click OK to save the program. When the I/O configuration is saved with the program, the Save button in the Instrument Manager is disabled.

The Instrument Manager displays whether the I/O configuration is from a separate vee.io file or is embedded in the program.

Notes

An I/O object (except Plug&play Driver objects) may be operated with or without actual instruments connected to the computer. If you want to control a live instrument, you must set a correct, non-zero address and enable Live Mode. The address and Live Mode setting are controlled by way of the Instrument Properties dialog box. If the address is zero or if Live Mode is off, the instrument object operates but does not attempt to communicate with a physical instrument. Plug&play Driver objects ignore the Live Mode setting when it is off, and always try to access the physical instrument.

Before VEE can communicate with your physical instruments, the instruments (and their interfaces) must be properly configured. Refer to your I/O Libraries installation instructions for more information.

For instrument-specific help, select Help from the object menu of a Panel Driver or Component Driver object.

Panel Drivers can be used interactively or within a program. To set the value of an individual component, click on the field containing the value of the component and complete the resulting dialog box. To make a measurement and display the result, click on the corresponding numeric readout or XY display inside the Panel Driver open view.

It is possible to have more than one object controlling a single instrument. It is also possible to have multiple copies of the same driver, each controlling a different physical instrument. In either case, it is the configured name that determines which object controls which instrument.

Location

I/O [image] Instrument Manager

See Also

Advanced Instrument Properties, Advanced I/O, Bus I/O Monitor, Component Driver, Direct I/O, Instrument Properties, Panel Driver, To/From VXIplug&play.

To Delete an Instrument Configuration

To Add an Instrument Configuration

To Edit an Instrument Configuration

VEE Advanced Techniques, "Configuring Instruments"


Instrument Properties

A dialog box that allows you to configure instruments.

Use

Use the Instrument Properties dialog box to add a new instrument configuration or to edit an existing configuration. You can use Instrument Properties to configure GPIB, Serial, GPIO, VXI, TCPIP, and USB instruments and their associated objects, such as Direct I/O, Plug&play Drivers, and Panel Drivers.

Dialog Information

The Instrument Properties dialog box provides the following fields and buttons:

Note
Use the Tab key to tab from field to field, or click on the desired field with the mouse. Do not press Enter (or Return) until you are finished with the dialog box. Pressing Enter (or Return) will cause the dialog box to close -- it is equivalent to pressing OK.

Name - Enter a unique name to identify this particular instrument configuration. Note that more than one configuration, each identified by a unique name, can control a single instrument, but this technique is not recommended. You cannot use the same name for two different instruments.

Interface - Specifies the type of hardware interface used to communicate with the instrument (the default is GPIB). Click on GPIB to display a list of available interface types (GPIB, Serial, and so forth). If you are using a GPIB interface, select GPIB for this field.

Address (eg 714) - Specifies the I/O address of your instrument. The default is 0. (When you enter a non-zero address, Live Mode changes to ON.) For more information about setting addresses, refer to "Configuring Instruments" in the VEE Advanced Techniques manual.

Gateway - Specifies the LAN gateway's host name when a VEE process is accessing instruments connected to a remote computer. The default value is This host. For more information about advanced I/O control, refer to "Advanced I/O Topics" in the VEE Advanced Techniques manual.

Board Number - Each board of this interface type is numbered beginning with 0. The default is 0.

Alias - The USB alias for the VISA address string. USB VISA address strings are long and awkward to use. The alias provides a simpler method for identifying the instrument. The default is USBDevice1.

TCPIP Address - The TCPIP address of the instrument. The format of TCPIP address string is TCPIP[board]::host address[::LAN device name]::INSTR where items in brackets are optional. An example would be TCPIP0::jetscrm3::GPIB0,9::INSTR. 0 is the board:: jetscrm3 is the host address (this could also be an IP address such as 129.82.135.12)::GPIB0 is the portal on the GPIB/LAN converter box, ,9 is the address of the instrument::and INSTR is the interface.

Advanced... - Clicking on the Advanced... button will open the Advanced Instrument Properties dialog box. From the Advanced Instrument Properties dialog box, you can configure the device driver, and the communications parameters for each of the interface types listed above. Refer to the separate Help topic for Advanced Instrument Properties.

OK - Once you have completed your configuration, click OK to confirm your changes.

Location

I/O [image] Instrument Manager… then select an instrument by double-clicking its line in the Instrument List.

See Also

Advanced Instrument Properties, Advanced I/O, Bus I/O Monitor, Component Driver, Direct I/O, Instrument Manager, and Panel Driver.

To Add an Instrument Configuration

VEE Advanced Techniques, "Configuring Instruments".


Int16

An object that outputs a constant 2-byte integer scalar or 1D array.

Use

Use Int16 to set an integer constant or to get user input. Click on the entry field to enter a value.

Example

To use Int16 as a prompt on a panel view, change the name of the Int16 object to a prompt such as Enter the number of seconds to delay:. The user fills in the requested information in the entry field.

Type in the formula 12*1024 into the Int16 and it will calculate the result.

Properties

General tab:

DataShape - Sets the initial data shape of the value(s) to be output with this object.

 ArraySize: - When 1D Array is selected, ArraySize sets the length of the array.

 ArraySizeFixed - When this property is True, the array cannot have lines added or deleted. This selection is only available if 1D Array is selected.

 ShowArrayIndices - When this property is True, each line in the entry field is indexed. This selection is only available if 1D Array is selected. Default is True.

Wait for Input - When this property is True, the object does not operate until the object's value is changed. When the check box is not selected, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When this property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

Initialization group:

 InitialValue - Specifies the value to be set. Default value is 0.

 InitializeAtPreRun - When this property is True, the InitialValue is set at PreRun time. Default is False.

 InitializeAtActivate - When this property is True, the InitialValue is set at Activate time. Default is False.

NumberFormat:

Global Format - Use the default format. Default is on.

Integer: - If Global Format is off, specify the number format for integer numbers to be displayed on this object. The choices are Decimal (e.g. 42), Octal (e.g. #Q52), Hexadecimal (e.g. #H2a), and Binary (e.g. #B00101010). Default is Decimal.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin available on most data constants.

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value(s). This input requires an integer value, either a Scalar or an Array 1D. The Constant is re-configured to match the shape of the incoming data.

The Reset input allows you to programmatically set the value(s) to zero. If the Constant is configured as an Array 1D, all values are set to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the value can be changed in the object’s open view.

Note that the InitialValue field is always a scalar, even if Int16 is configured to be an array.

Location

Data [image] Constant [image] Int16

See Also

Alloc Int16, Complex, Constant, Coord, Date/Time, Selection Control, Default Preferences, UInt8, Int32, PComplex, Real32, Real64, Text, and Toggle Control.

To Use a Data Constant


Int32

An object that outputs a constant 4-byte integer scalar or ID Array.

Use

Use Int32 to set an integer constant or to get user input. Click on the entry field to enter a value.

Example

To use Int32 as a prompt on a panel view, change the name of the Int32 object to a prompt such as Enter the number of seconds to delay:. The user fills in the requested information in the entry field.

Type in the formula 12*1024 into the Int32 and it will calculate the result.

Properties

 ArraySize: - When 1D Array is selected, ArraySize sets the length of the array.

 ArraySizeFixed - When the property is True, the array cannot have lines added or deleted. This selection is only available if 1D Array is selected.

 ShowArrayIndices - When this property is True, each line in the entry field is indexed. This selection is only available if 1D Array is selected. Default is True.

 EnableStepping - When this property is True, stepping controls appear at the right end of the entry field to let you scroll through values. Default is False.

 DetentSize - When the EnableStepping property is True, this sets the size between values when using the stepping controls to scroll through values. Default is 1.

 Wait for Input - When this property is True, the object does not operate until the object's value is changed. When the property is not selected, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When this property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

 InitialValue - Specifies the value to be set. Default value is 0.

 InitializeAtPreRun - When this property is True, the InitialValue is set at PreRun time. Default is False.

 InitializeAtActivate - When this property is True, the Initial Value is set at Activate time. Default is False.

NumberFormat:

 Global Format - Use the default format. Default is on.

 Integer: - If Global Format is off, specify the number format for integer numbers to be displayed on this object. The choices are Decimal (e.g. 42), Octal (e.g. #Q52), Hexadecimal (e.g. #H2a), and Binary (e.g. #B00101010). Default is Decimal.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin available on most data constants.

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value(s). This input requires an integer value, either a Scalar or an Array 1D. The Constant is re-configured to match the shape of the incoming data.

The Reset input allows you to programmatically set the value(s) to zero. If the Constant is configured as an Array 1D, all values are set to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the value can be changed in the object’s open view.

Note that the InitialValue field is always a scalar, even if Int32 is configured to be an array.

Location

Data [image] Constant [image] Int32

See Also

Alloc Int32, Complex, Constant, Coord, Date/Time, Selection Control, Default Preferences, UInt8, Int16, PComplex, Real32, Real64, Text, and Toggle Control.

To Use a Data Constant


Int32 Input

An object that displays a pop-up dialog box that accepts integer number input.

Use

Use Int32 Input to prompt the user to enter an integer number, accept the number, and check the number with a user-defined test for validity.

In the pop-up dialog box, when the OK button is pressed, the integer number input by the user is output on the Value output pin. When the Cancel button is pressed, a 1 is output on the Cancel output pin.

Open View

  • Prompt/Label - The string that prompts the user to fill in the text field. You may add this parameter as a data input. Default is Enter Integer Value:

  • Default Value - The text that is in the dialog's input field before anything is typed. If the user presses OK without typing anything, this text is output. You may add this parameter as a data input. Default is 5

  • Value Constraint - The equation that tests the input text for validity. You can use any mathematical expression or call a UserFunction. You may add this parameter as a data input. Default is 0<=value AND value<=10; which means it checks for user input of a value between 0 and 10. To accept any value, use the expression 1.

  • Error Message - The text that is output in a message box if the user input does not meet the Value Constraint. You may add this parameter as a data input. Default is You must enter a integer between 0 and 10.

Properties

  • PopupTimeoutEnabled - When this property is True, a Timeout output pin is added to the object. Default is False.

  • PopUpDuration - Sets the length of time the pop-up dialog box is displayed. After this period of time, the dialog box times out and a value of 1 is output on the Timeout output pin. No other outputs pins have data if the Timeout pin executes. This field is only available when the Timeout Enabled check box is selected. Default is 60 seconds.

  • PopupOKLabel - Sets the button label to OK if True. You may also use alternative wording if your users are not native English speakers. Regardless of the wording, the button's function remains the same.

  • PopupCancelLabel - Sets the button label to Cancel if True. You may also use alternative wording if your users are not native English speakers. Regardless of the wording, the button's function remains the same.

  • PopupPasswordMasking - When this property is True, the input text is echoed as asterisks (*). This feature is useful when the operator is entering sensitive data such as a password. The string that is output on the Value output pin is not masked. Default is False.

Notes

The default location of the pop-up dialog box is approximately at the center of the work area. If you move it, next time it will pop-up to the new location.

The title text of the error message dialog box is the same as the Int32 Input object title.

To respond to the pop-up dialog box using only the keyboard: when the dialog box pops up, start typing and use the Enter and Esc keys. Use the Tab key to move between the input field and the buttons and then select the buttons with the Space bar.

The pop-up dialog box and the error dialog box are only displayed while the program is running. While the pop-up dialog box is displayed, the entire program pauses execution, then continues when the dialog box is closed.

Location

Data [image] Dialog Box [image] Int32 Input

See Also

File Name Selection, List Box, Message Box, Real64 Input, Text Input, and UserObject.

To Use a Data Input Dialog Box


Int32 Knob

An object that outputs the integer value of the knob.

Use

Use Int32 Knob to input Int32 values. Int32 Knob is particularly useful on a panel view.

Open View Parameters

The open view displays fields for the knob's current value, minimum, and maximum values, and the knob control.

Properties

Orientation - Sets how the Knob is displayed. Default is Horizontal.

 ShowDigitalDisplay - If the property is True, the current value of the knob is displayed in an edit field at the bottom of the open view of the object. When you modify this value, the position of the knob changes. Default is True.

ShowTic - Controls visibility of scale’s tic marks and labels. Default is True.

 LabelSpacing: - Controls which tic marks are labeled with the scale values. Default is EveryOtherTic.

 DetentSize: - Sets the distance between the values that are available from the Knob. If other values are entered, they are rounded to the nearest detent. Any real Detents are truncated to Int32. Default is 1.

Wait for Input - When the property is True, the object does not operate until the object's value is changed. When the property is False, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When the property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

InitialValue - Specifies the value to be set. Default value is 0.

 InitializeAtPreRun - When the property is True, the InitialValue is set at PreRun time. Default is False.

 InitializeAtActivate - When the property is True, the InitialValue is set at Activate time. Default is False.

Number Format - If Global Format is off, specify the number format for integer numbers to be displayed on this object. The choices are Decimal (e.g. 42), Octal (e.g. #Q52), Hexadecimal (e.g. #H2a), and Binary (e.g. #B00101010). Default is Decimal.

Notes

Initialization is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, Disable Editing, MaxValue, MinValue, and Detents:

The Default Value input allows you to programmatically change the current value. This input requires an Int32 Scalar value.

The Reset input allows you to programmatically set the value to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the current, minimum, and maximum values can be changed in the open view.

The MaxValue and MinValue inputs allow you to programmatically set the min and max value fields. These inputs require a real scalar value, which is then converted to an Int32.

The Detents input allows you to programmatically set the detent value.

Location

Data [image] Continuous [image] Int32 Knob

See Also

Complex, Selection Control, Int32, Int32 Slider, PComplex, Real64, Real64 Knob, Text, and Toggle Control.

To Use a Data Slider and Knob


Int32 Slider

An object that outputs the integer value of the slider.

Use

Use Int32 Slider to input Int32 values. Int32 Slider is particularly useful on a panel view.

Open View Parameters

The open view displays fields for slider value, min, max, and slider control.

Properties

Orientation - Sets how the Slider is displayed. Default is Vertical.

 ShowDigitalDisplay - If the property is True, the current value of the slider is displayed in an edit field at the top of the open view of the object. When you modify this value, the position of the slider control changes. Default is True.

ShowTics - If the property is True, the slider shows marks and labels for values between the min and the max. The default is True. For programs prior to VEE revision 4.0, the default is False.

 LabelSpacing: - Controls which tic marks are labeled with the scale values. Default is Every Other Tic.

 Detent Size: - Sets the distance between the values that are available from the Slider. If other values are entered, they are rounded to the nearest detent. Any real Detents are truncated to Int32. Default is 1.

Wait for Input - When the property is True, the object does not operate until the object's value is changed. When the property is False, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When the property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

InitialValue - Specifies the value to be set. Default value is 0.

 InitializeAtPreRun - When the property is True, the InitialValue is set at PreRun time. Default is False.

 InitializeAtActivate - When the property is True, the InitialValue is set at Activate time. Default is False.

NumberFormat - If Global Format is off, specify the number format for integer numbers to be displayed on this object. The choices are Decimal (e.g. 42), Octal (e.g. #Q52), Hexadecimal (e.g. #H2a), and Binary (e.g. #B00101010). Default is Decimal.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, Disable Editing, MaxValue, MinValue, and Detents:

The Default Value input allows you to programmatically change the current value. This input requires an Int32 Scalar value.

The Reset input allows you to programmatically set the value to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the current, minimum, and maximum values can be changed in the open view.

The MaxValue and MinValue inputs allow you to programmatically set the min and max value fields. These inputs require a real scalar value, which is then converted to an Int32.

The Detents input allows you to programmatically set the detent value.

Location

Data [image] Continuous [image] Int32 Slider

See Also

Complex, Selection Control, Int32, Int32 Knob, PComplex, Real64, Real64 Knob, Real64 Slider, Text, and Toggle Control.

To Use a Data Slider and Knob


Interface Event

An object that captures asynchronous interface events for VXI, GPIB, and serial.

Use

The Interface Event object can be configured to detect various interface events. Depending on the configuration, the object may wait for the event, giving up execution to other parallel threads, or it may simply return a boolean (0 or 1) or other indicator of the state of the interface.

If the Interface Event object has been configured to wait for the event, then upon the event the object will execute. In VEE 3 execution mode only, any thread hosted by this object will have priority over any other parallel threads, and will execute to completion. If the Interface Event object has been configured to simply return an indicator of interface state, the thread containing it will have normal priority, and will execute in parallel with any other threads.

Open View Parameters

Interface - The currently selected interface is displayed in this field. Click on this field to display a list of the currently configured interfaces. For an interface to appear in this list, at least one instrument for that interface must be configured using I/O [image] Instrument Manager.... Multiple interfaces of the same type are distinguished by their logical units (e.g.: "hpib7" and "hpib8").

Action - Determines the execution behavior of the Interface Event object upon detection of the event.

Wait - Wait for the event to occur. The object executes when the event occurs. Any thread hosted by this object will have priority over any other parallel threads, and will execute to completion when the event occurs, but is "blocked" until the event occurs. When the event occurs, a boolean TRUE (1) or an interface-event-specific bit pattern is output.

No Wait - Execute immediately, placing the current state of the configured event, as specified by a 32-bit integer, on the event output pin. This value is the boolean value FALSE (0) if the event has not occurred. If the event has occurred, a TRUE (1) or an interface-event-dependent bit pattern is returned. In the No Wait configuration, any thread hosted by the Interface Event object will have normal execution priority, and will execute in parallel with any other threads.

Event - Allows selection of specific interface events. Click on this field to display the choices. For each choice below, both the Wait and the No Wait actions are described. Note that in each case, the thread propagation priorities for Wait and No Wait are as described above.

SRQ - This is the only choice for the GPIB interface:
-- If the Action choice is Wait, the Interface Event object delays execution until a GPIB device asserts the service request line. It then places the boolean value TRUE (1) on the event output pin.
-- If the Action choice is No Wait, a boolean value FALSE (0) is output if the event has not occurred. If the event has occurred, a boolean TRUE (1) will be output on the event pin.

DAV - (Data Available) This is the only choice for the serial interface.
-- If the Action choice is Wait, the Interface Event object delays execution until data arrives in the receive buffer. The number of bytes in the receive buffer is placed on the event output pin, alerting the following object to read those bytes from the buffer.
-- If the Action choice is No Wait, the Interface Event object executes immediately giving out the number of bytes in the receive buffer from the event output pin.

Sys Reset - The Interface Event object executes when a system reset occurs on the VXI interface:
-- If the Action choice is Wait, a boolean TRUE (1) is output on the event pin when the system reset occurs.
-- If the Action choice is No Wait, a FALSE (0) is output if the system reset has not occurred.

Sys Active - When the VXI Resource Manager has finished its VXI initialization and management, it sends a Begin Normal Operation (BNO) command to the VXI interface. If Sys Active is configured, the Interface Event object executes when this occurs:
-- If the Action choice is Wait, a boolean TRUE (1) is output on the event pin when the BNO command occurs.
-- If the Action choice is No Wait, a FALSE (0) is output if the event has not occurred.

Sys Deactive - When normal VXI operation is aborted an Abort Normal Operation (ANO) or End Normal Operation (ENO) command is sent to the interface. If Sys Deactive is configured, the Interface Event object executes when this occurs:
-- If the Action choice is Wait, a boolean TRUE (1) is output on the event pin when the ANO or ENO command occurs.
-- If the Action choice is No Wait, FALSE (0) is output if the event has not occurred.

TTL Trig - When TTL Trig is configured, the Interface Event object "monitors" the VXI TTL trigger lines:
-- If the Action choice is Wait, the Interface Event object executes when a VXI device asserts one or more of the eight TTL trigger lines in the VXI backplane, placing a 32-bit integer on the event output pin. Only the low byte of this integer is significant. It is a bit pattern showing which of the eight TTL trigger lines are active (bit 0 corresponds to trigger line 0, bit 7, to trigger line 7). Each bit set (1) indicates that the corresponding line has been triggered. For example, 00010001 indicates that TTL lines 0 and 4 have been triggered.
-- If the Action choice is No Wait, the boolean FALSE (0) is output if no triggers have occurred.

ECL Trig - When ECL Trig is configured, the Interface Event object "monitors" the VXI ECL trigger lines:
-- If the Action choice is Wait, the Interface Event object executes when a VXI device asserts one or more of the four ECL trigger lines in the VXI backplane, placing a 32-bit integer on the event output pin. The low byte of this integer is a bit pattern showing which of the four ECL trigger lines are active. (Bit 0 corresponds to trigger line 0, bit 3, to trigger line 3.) Each bit set (1) indicates that the corresponding line has been triggered. For example, 00001001 indicates that ECL lines 0 and 3 have been triggered.
-- If the Action choice is No Wait, the boolean FALSE (0) is output if no triggers have occurred. Note that some VXI card cages may choose to implement only two ECL trigger lines.

EXT Trig - When EXT Trig is configured, the Interface Event object "monitors" the VXI EXT trigger lines:
-- If the Action choice is Wait, the Interface Event object executes when an external device asserts an embedded controller's "Trig In" input. Up to four external trigger inputs can occur. A 32-bit integer is output on the event pin when the Interface Event object executes. The low byte of this integer is a bit pattern showing which of the four EXT trigger lines are active. (Bit 0 corresponds to external trigger 0, bit 3, to external trigger 3.) Each bit set (1) indicates that the corresponding trigger has occurred. For example, 00001001 indicates that EXT trigger lines 0 and 3 have been triggered.
-- If the Action choice is No Wait, the boolean FALSE (0) is output if no triggers have occurred. Some controller implementations may have no external trigger inputs.

Unknown Interrupt - If Unknown Interrupt is configured, the Interface Event object checks for any VME interrupts from a VME or VXI device not in the VXI controller's servant area:
-- If the Action choice is Wait, such an interrupt causes the Interface Event object to execute. The 32-bit value returned is the value placed on the VXI Bus when the device does an interrupt acknowledge (IACK).
-- If the Action choice is No Wait, the boolean FALSE (0) is output if no interrupt has occurred.

Unknown Signal - If Unknown Signal is configured, the Interface Event object checks for any signal register write from a VXI device not in the VXI controller's servant area:
-- If the Action choice is Wait, such a signal causes the Interface Event object to execute. The 32-bit value returned is the contents of the signal write register.
-- If the Action choice is No Wait, the boolean FALSE (0) is output if no signal has occurred.

Notes

The execution behavior of the Interface Event object can either be asynchronous or synchronous, as determined by the choice of the Action parameter. NO WAIT specifies a synchronous, polling behavior. The object executes immediately, and any attached thread will have the same priority as all other threads currently executing. Choosing WAIT causes the Interface Event object to wait until the event has occurred. Any thread hosted by the object will have a higher priority, and will execute to completion, blocking all other concurrently executing threads.

Timeout Control Pin - Sets timeout period the object waits trying to acquire a locked interface to service an event. An error occurs if no interface is acquired.

Location

I/O [image] Advanced I/O [image] Interface Event

See Also

Instrument Event, and Interface Operations.

To Poll GPIB Instruments


Interface Operations

An object that uses transactions to send low-level interface commands and data by way of GPIB, VXI, USB, TCPIP, and serial.

Interface Operations should be used for interface-specific tasks, or for special cases where communication with devices via Direct I/O or an Instrument Driver does not afford the necessary level of control.

Use

Use Interface Operations for low-level operations such as:

Sending non-standard GPIB addressing sequences.

Sending a GPIB group trigger message, or pulling on VXI trigger lines.

Sending arbitrary bytes via GPIB, with or without ATN true.

Sending clear and reset commands to either the VXI or GPIB interfaces.

Sending IEEE 488.1 defined multi-line messages.

Sending interface lock and unlock messages to the serial interface.

To use Interface Operations you must add one or more transactions. To do this, click on Add Trans in the object menu. Transactions are listed as lines of text in the open view of the object. To edit a transaction, double click on the transaction and complete the resulting dialog box.

Object Menu

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Print Trans - Prints the detailed dialog box that describes the currently highlighted transaction.

Properties

Interface: - Displays the bus configuration and allows you to change to another interface. Multiple interfaces of the same type are distinguished by their logical units (e.g., "hpib7" and "hpib8").

 Timeout: - Sets the timeout period. Can be set with a control input pin.

Short Cuts

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Location

I/O [image] Advanced I/O [image] Interface Operations

See Also

Advanced I/O, Bus I/O Monitor, Formula, and Instrument Manager.

VEE Advanced Techniques, "Using Transaction I/O."


Interface Properties

A dialog box used to configure various interface addresses.

Use

You can use the Interface Properties dialog box to configure or edit a GPIB, VXI, Serial, or GPIO interface address.

Open View Parameters

The following parameters are configured from the Interface Properties dialog box:

Interface: - This is the interface type to be configured (the default interface type is the type you selected from the Instrument List.

Address: - This is the logical unit number of the interface you wish to configure or edit.

Gateway: - Specifies the LAN gateway's host name when a VEE process must access the instruments connected to a remote computer. The default value is This host. For more information about advanced I/O control, see the "Advanced I/O Topics" chapter in the VEE Advanced Techniques manual.

Location

I/O [image] Instrument Manager...

From the Instrument List on the Instrument Manager dialog box, select (highlight) one of the interface icons such as, GPIB, VXI, Serial, or GPIO, then click on the Properties button. This will bring up the Interface Properties dialog box.

See Also

Advanced I/O, Advanced Instrument Properties, and Instrument Properties.

To Add an Instrument Configuration

To Edit an Instrument Configuration


JCT

An object that outputs the value from the most recent data input (one of multiple inputs) that is activated.

Use

Use JCT like a wired OR to connect the data output pins of two or more objects to one data input pin of another object. JCT is often used in feedback loops for data initialization. JCT passively transmits data. In VEE 4.0 and later, a JCT is required in threads using feedback.

Notes

JCT is useful for setting up initial conditions.

Inputs to JCT are asynchronous data inputs. This means that JCT operates any time any of its data inputs is activated. When more than one pin on the JCT is activated before the JCT can operate, the incoming data is queued up in the order in which it was received. The JCT then activates its output repeatedly much like an iterator until the data queue is empty. If the input data pin is activated by a feedback loop, multiple activations are ignored.

One of the common uses of JCT is in a feedback loop where an initial value is first supplied through one of the inputs, and feedback values are then supplied through one or more of the other data inputs.

Location

Flow [image] Junction

See Also

DeMultiplexer and Properties (Object)


Junction

See JCT.


Label

An object that is used to put a text label on the Panel View.

Use

Use Label to create labels or headings on the Panel View. This object does not need to execute, and its background color blends into the background color of the Panel View.

Open View

The current Label string is shown. Default is Label. To change the Label, change the object's title using Properties in the object menu, or use a data input.

Properties

Justification - Specifies the layout of the text within the object border. Default is Left.

Notes

The default object color for the Label is the same as the default Panel View color so that the Label background blends into the Panel View.

The default Border setting for the Label object on the Panel View is None.

If using the data input for the label value, note that the Label object will not auto-size at run time to fit the string’s length. Label clips the text of a string sent to it on the data input if the string is longer than the Label object. Be sure to size the Label object large enough so the string fits when using the data input.

Location

Display [image] Label

See Also

Beep and Text.

To Label Areas


Last Error

A View menu item that allows you to retrieve the last Error dialog box that was generated in your VEE program.

Use

Last Error allows you to retrieve the last Error dialog box that was generated in your VEE program. You can click the Go To button on the Error dialog box and the detail view of the VEE program will be brought into the VEE workspace. As long as the program remains in an Error state, the UserObject or UserFunction where the error occurred will be highlighted. If the program is no longer in an Error state, for example if the program has been stopped, the object will not be hightlighted.

Dialog Information

The Last Error dialog box contains the following information and buttons:

Error message and error number - The main window of the Last Error dialog box will contain a brief explanation of the error that was generated, and will identify the Object Title and the Object Type where the error occurred. The Error number will also be indentified.

Go To - Clicking on the Go To button will bring up the detail view of the VEE program, and if the program is still in an Error state, the UserObject or UserFunction where the error occurred will be highlighted.

Call Stack - Clicking on the Call-Stack button will bring up the Call Stack dialog box. The Call Stack dialog box may contain more information regarding where in your program the Error occurred.

Close - Closes the Error dialog box.

Help - Clicking on Help will open the Help topic that provides more information on the Error number you received.

Notes

Errors that are trapped and handled by an Error pin will not be retrievable using Last Error.

Location

View [image] Last Error

See Also

Error Output (Object Menu), Call Stack, errorInfo(), and Raise Error.


Line Probe

Displays the container information that is transmitted on a line between two objects.

Use

Use Line Probe as a debugging tool to examine the container transmitted on a line. When you use Line Probe, the cursor changes to a magnifying glass, and remains in that mode until you click in the work area. Click on the line you want to examine. This opens a dialog box displaying the current container on the line.

If the container on the line is not nil, the dialog box displays the current type, shape, and size of the containers. Data values of up to Array 2D are shown. If any of the dimensions of the container are mapped, the mapping values are shown for each dimension.

Control inputs often have no data on them. Sequence output pins never have data on them. If an object has not yet operated, the lines connected to its inputs and outputs may show nil or old data.

Notes

To view the endpoints of a line, select Line Probe and drag the pointer to the line. Click the left mouse button over the highlighted line to display the line’s current attributes.

To view the endpoints of a line without showing its data, select Line Probe and hold down the mouse button when the pointer is over the line. Move the pointer away from the line before releasing the button.

You can also check the current data from inside the terminals of an open view object by double-clicking on the terminals.

Short Cuts

To view simple scalar values and the endpoints of a line, simply place the mouse pointer over the line. Pausing over the line displays the value of the container (if it is simple enough to display) and highlights the endpoints. Click on the line with the left mouse button to display complete container information.

If a line between two pins is short and only the terminal names appear while paused over the line, press Shift to force the mouse pointer to Line Probe.

Location

Debug [image] Line Probe

See Also

Default Preferences, and Properties (Object).

To View the Data on a Line


List Box

An object that displays a pop-up dialog box that displays a list to the user.

Use

Use List Box to display a list message to the user. The user responds by selecting one (or more) of the choices on the dialog box. You may customize the text on the buttons.

In the pop-up dialog box, when a selection is made, the selection is output on the Text output pin and its index into the list is output on the Index output pin. When multiple selections are made, an array of text is output on the Text output pin and an array of indices is output on the Indices output pin.

Open View

  • List Entries Edit ... - Allows you to edit the list of choices displayed on the List Box pop-up dialog box. You may add this parameter as a data input.

  • Default Entry - Allows you to select the default entry from the choices in List Entries to appear on the pop-up dialog box. You may add this parameter as a data input.

  • Allow Multiple Selections - When the check box is selected, the user may choose one or more selections from the list. Also two additional buttons are added to the pop-up dialog box: Select All and Clear All.

Properties

  • PopupTimeoutEnabled - When this property is True, a Timeout output pin is added to the object. Default is False.

  • PopUpDuration - Sets the length of time the pop-up dialog box is displayed. After this period of time, the dialog box times out and a value of 1 is output on the Timeout output pin. No other outputs pins have data if the Timeout pin executes. This field is only available when the Timeout Enabled check box is selected. Default is 60 seconds.

  • PopupOKLabel - Sets the button label to OK if True. You may also use alternative wording if your users are not native English speakers. Regardless of the wording, the button's function remains the same.

  • PopupCancelLabel - Sets the button label to Cancel if True. You may also use alternative wording if your users are not native English speakers. Regardless of the wording, the button's function remains the same.

  • PopupSelectAllLabel - available only when Allow Multiple Selections is selected

  • PopupClearAllLabel - available only when Allow Multiple Selections is selected

  • PopupPasswordMasking - When this property is True, the input text is echoed as asterisks (*). This feature is useful when the operator is entering sensitive data such as a password. The string that is output on the Value output pin is not masked. Default is False.

  • PopupNumDisplayedItems - Sets the maximum number of lines the List Box will display without a scroll bar. If this value is greater than the number of list entries, the dialog pop-up is sized to contain the number of list entries (no blank lines). Default is 10.

Notes

The default location of the pop-up dialog box is approximately at the center of the work area. If you move it, next time it will pop-up to the new location.

To respond to the pop-up dialog box using only the keyboard: when the dialog box pops up, use Enter and Esc keys. Or use the Tab key to move between the buttons and the selection area; select the choice(s) with the Space bar.

The pop-up dialog box is only displayed while the program is running. While the pop-up dialog box is displayed, the entire program pauses execution, then continues when the dialog box is closed.

Location

Data [image] Dialog Box [image] List Box

See Also

File Name Selection, Message Box, Int32 Input, Real64 Input, Text Input, and UserObject.

About Built-In Dialog Box Objects


List

See Selection Control.


Logging AlphaNumeric

An object that displays a Scalar or Array 1D of alphanumeric data. Logging AlphaNumeric allows data to be displayed without overwriting the display.

Use

Use Logging AlphaNumeric to display consecutive input (either Scalar or Array 1D) as a history of previous values.

Object Menu

Clear - Clears all the data that was displayed on Logging AlphaNumeric. Clear may be added as a control input.

Properties

ClearAtPreRun - When the property is True, the contents of the Logging AlphaNumeric are cleared at PreRun. Default is True.

 ClearAtActivate - When the property is True, the contents of the Logging AlphaNumeric are cleared at Activate. Default is True.

Buffer Size - Specifies the number of lines that the display buffer holds. If more than that number of lines is input to Logging AlphaNumeric the last values are kept and the previous are overwritten. Default is 256.

 NumberFormat - If Global Format is off, specify the number format for integer numbers to be displayed on this object. The choices are Decimal (e.g. 42), Octal (e.g. #Q52), Hexadecimal (e.g. #H2a), and Binary (e.g. #B00101010). Default is Decimal.

  • Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Sat 01/Jan/1994 17:01:38). Default is Standard.

Notes

A row of asterisks (***) is displayed if the current width of the Logging AlphaNumeric object is too small to display the default precision of the numeric type. Resize the object and rerun the program to display the data.

The display of ASCII values 0-31 is dependent on font and may not be readable.

Text strings longer than 2048 characters may not display properly on some platforms (operating systems). Text strings longer than 32767 characters do not display properly on any platform.

Location

Display [image] Logging AlphaNumeric

See Also

AlphaNumeric and Default Preferences.

To Display a Series of Values in a Log


Magnitude Spectrum

An object that graphically displays a spectrum.

Use

Use Magnitude Spectrum to display Spectrums or Waveforms in the frequency domain. Waveforms are automatically converted to spectrums by way of a Fourier Transform. The X axis is in the sampling units of the input Spectrum (typically frequency).

Open View Parameters

These are the default open view parameters. Their use, and the availability of other parameters, is controlled by selections on the object menu and in the Properties dialog box (object menu [image] Properties).

Mag - The name of the Y axis.

Trace1 - The name of the first trace.

Freq - The name of the X axis.

Object Menu

Auto Scale [image] - Clicking these menu items immediately rescales the display to show the entire trace. (Can be added as control pins, or set using the Scales properties tab to automatically rescale the display after data is collected.)

Auto Scale - Automatically scales both axes.

Auto Scale X - Automatically scales the X axis.

Auto Scale Y - Automatically scales the Y axis.

Zoom [image] - Scales the display.

In - Magnifies the display to contain only the rectangular region that you selected with the pointer. You select the region after selecting this feature by dragging on the graph area. This action outlines the information with a "rubber band" box.

Out 2|5|10|20|50|100X - Expands the scales of the display by a factor in both the X and Y directions about the center.

Clear Control [image] - Parameters that specify when to clear the display.

Display - Clears the displayed trace(s). This parameter may be added as a control input.

Next Curve - Resets the display to show the next curve in a family of curves (data from the next time the display operates) without clearing the previous curve. Next Curve must be selected (or activated) before each new curve in the family. This parameter may be added as a control input.

Center Markers - If markers are available, brings them to the center of the visible part of the trace. This is useful if you've scrolled the display and markers are not visible.

Add Right Scale - Adds up to two additional Y-axis scales to permit traces to have different scale ranges. After adding a right scale, you may add a terminal for its input (object menu [image] Add Terminal [image] Data Input). Then set its properties using the Traces and Scales tabs on the Properties dialog box.

Print - Presents the Print dialog box. Pressing OK prints or plots a copy of the device's entire display on the selected output device. Print may be added as a control input.

Properties

Name - Assigns a variable name to the display. By entering a name, you can programmatically read marker values if they are turned on. The variable is an Object data type, and it is local to the context where the display exists. See Notes for details.

ClearAtPreRun - When the property is True, the display is cleared at PreRun time. Default is True.

 ClearAtActivate - When the property is True, the display is cleared at Activate time. Default is True.

ShowTracesLegend - In the open view, controls the visibility of the trace names and colors. Use EditTracesAndScales to control the edit-button function of the trace legends. Default is True.

 ShowScalesLegend - In the open view, controls visibility of the scale names. Use EditTracesAndScales to control the edit-button function of the scale legends. Default is True.

 ShowScaleLabels - In the open view, controls visibility of the values labeling the scale axes. Default is True.

 ShowScrollBars - In the open view, controls visibility of the scroll bars on the X and Y scales. Default is True.

 ShowAutoScaleButton - In the open view, controls visibility of the Auto Scale Button. Default is False.

 EditTracesAndScales - In the open view, controls the edit-button function of the trace and scale properties. When enabled, click on an individual trace or scale name to edit its properties. Default is True. Use ShowTracesLegend and ShowScalesLegend to control visibility of the trace(s) and scale(s) names.

GridType - Default is Lines.

NumMarkers - The number of markers displayed in the graph. To move markers to a different trace, go to the open view and click on the button to the left of the marker values near the bottom of the display. The button cycles through the different line types and colors of the different traces.

 MarkerInterpolate - When the property is True, you can place markers between the displayed data points. The marker values displayed are calculated by linear interpolation. Default is False.

DisplayBackColor - Allows you to select the color of the display area from a palette. You can select different colors when the display appears in the detail view and the panel view.

ScaleLabelFont - Allows you to select the font of the scale labels from the list of available fonts on your system. The default font for scale label text is set in Default Preferences on the Fonts tab for Screen Element: Graph Scale Label Text.

Traces Group: (one per trace)

Name: - The name of the trace that is displayed to the left of the graph area and the name of the corresponding input terminal.

Color: - The color of the trace. Each added trace has a different color than the existing traces. Default for the first trace is yellow.

LineStyle: - The format of the line connecting data points. Default is a continuous line.

PointStyle: - The symbol that marks each data point. To show unconnected data points, select the single dot LineStyle format and the desired PointStyle symbol. Default is a dot.

Scale - If it exists for more than one Y scale, choose which scale this Trace is scaled by.

Scales property: (one per X and Y scale and extra Y scales)

Show Scale: - If you have multiple Y scales, a selection (using a check box) to specify if the end points and an axis of each additional right scale is displayed to the right of the graph area.

Scale Name: - The names of the scales appearing in the open view.

Automatic Scaling: - Controls whether the display automatically rescales to show the entire trace immediately after it receives data. Default is on. If this is turned off, you can rescale the display by using the Auto Scale button on the General tab, in the Layout group, or the Auto Scale command on the object menu.

Maximum: - The maximum values of the scales.

Minimum: - The minimum values of the scales.

Label Spacing: - Controls which tic marks are labeled with the scale values. Default for X scale is Every Other Tic; default for Y scale(s) is Every Major Tic.

Mapping: - The way the x and y data is mapped to the display. The mapping may be linear or log. To make a log-log plot, change both X and Y axes to Log. Default is Linear.

Log Cycles: - The maximum number of decades shown (counting down from the maximum x and y values) when Automatic Scaling is on. Log Cycles is only used when the Mapping is Log. Log Cycles is useful when a trace contains a large dynamic range in the data. Default is 4.

Scale Color - The color of any background grid or tic marks. Default is Gray.

ScaleNumberFormat: (a property appears for the X and Y scales, and for any additional Y scales.)

Global Format - Use the default format. Default is True.

Real - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

The X and Y marker values take on the same number format as the scale to which they are attached. The delta marker values for X and Y use the default number format unless you use the Time Stamp format. Then, if both markers 1 and 2 on the X scale, or both markers on the Y scale are using the Time Stamp format, the delta marker values use the Delta Time format.

Notes

Inputs must be of type Spectrum, Waveform, or Coord (Scalar or Array 1D).

Input data of type Coord is plotted by simply using its x and y values without first being converted to type Spectrum.

Add traces with the Add Terminal [image] Data Input object menu selection. Up to twelve traces are allowed.

When the Automatic Scaling property is on (Scales tab), the program executes faster if a complete set of data is sent to the display. Then, the display automatically rescales once. If a program sends one data point at a time to the display, the display may automatically rescale after each data point, which will slow down program execution. In this case, use a Collector object to create an array, then send the array to the display.

Adding Control Inputs

You can add a Title control input pin, which sets the title bar name to the specified text value. This allows programmatic control over the title shown when the display is printed.

You can add a Traces control input pin. The control input data must be an array of records (or a record scalar if you only want to control one trace). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A field named TraceNum with an integer value (1 is the first trace). The TraceNum field is required. An error occurs if it is omitted.

One or more of the following fields:

Name

Pen

LineType

PointType

The Name field must have a text value. The Pen, LineType and PointType values must be integers from 0 to n, where 0 draws nothing and n is the number of choices available.

You can add a Scales control input pin to control the scales parameters listed above. The control input data must be an array of records (or a record scalar, if you only want to control one scale). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A Text field named Scale with a value X, Y (or Y1), Y2, or Y3. The Scale field is required. An error occurs if it is omitted.

One or more of the following fields:

Name - Changes the scale name in the open view. Must be a text value.

Min - Sets the X scale minimum. Must be an integer or real value.

Max - Sets the X scale maximum. Must be an integer or real value.

Mapping - Must have a text value of Linear or Log.

AutoScale - Controls automatic scaling. Must have a text value of On or Off.

You can add Print and Plot control input pins. On Windows, these inputs behave the same way, using the settings in Windows’ Print Setup dialog box (File [image] Print Setup…). If the current Printer Setup is in Print to File mode, you may specify the destination file or directory name as string data on the Plot control input. If no control input value is given, the file or directory name specified in Printer Setup will be used.

Refer to "Using Records and DataSets" in VEE Advanced Techniques for further information.

Programmatically Setting and Reading Marker Values

You can programmatically get and set marker values. To prepare the display, open its Properties window. Enter a value for Name. The value for Name implicitly declares an Object variable that is local to the display’s context. Next, turn on a setting in the Markers group. VEE assigns the following properties to the markers’ X and Y positions, including the delta values. (Marker1 points down; Marker2 points up.)

Marker1X (gets the position as a Real64)

Marker1Y (gets the position as a Real64)

Marker2X (gets the position as a Real64)

Marker2Y (gets the position as a Real64)

MarkerDX (gets the position as a Real64)

MarkerDY (gets the position as a Real64)

Marker1 (gets/sets the position as a Coord)

Marker2 (gets/sets the position as a Coord)

The Marker1 and Marker2 properties can be used to read the current marker position or move the marker to a new position. All other marker properties are read-only. If you attempt to move the marker to a coordinate that is not on the trace, the marker will "snap" to the closest point that is on the trace.

In your program, enter one or more expressions in a Formula object to set or read the marker values. Each expression must contain the display Name and the marker property of interest. Marker property names are not case-sensitive. If the display’s Name is XY, and Delta Markers is turned on, the following expressions will read all the available marker values, assigning them to the variables a through f as Real64 scalars:

a = XY.Marker1X

b = XY.Marker1Y

c = XY.Marker2X

d = XY.Marker2Y

e = XY.MarkerDX

f = XY.MarkerDY

You can assign the display Name to a global variable. Add an assignment expression to your program in a Formula object, and declare the global using the Declare Variable object. As an example, assume you declared the variable globalXY as a global, and set its Type to Object. Then, in the context where the display exists, add this expression to your program:

Set globalXY = XY

This lets you read the display’s marker values from another context in the program using an expression such as:

a = globalXY.Marker1X

As you develop a program, you may want to include a way to pause the program so you can manually reposition the markers before the program reads their values. One way to pause a program is to add a Confirm (OK) button between the display’s sequence output and the Formula object’s sequence input. Alternately, you may want to position the markers programmatically.

Location

Display [image] Spectrum (Freq) [image] Magnitude Spectrum

See Also

Magnitude vs Phase, Phase Spectrum, Polar Plot, Default Preferences, Spectrum (Freq), and Waveform (Time).

To Display a Waveform, To Set Markers in the Display, To Get and Set Marker Properties


Magnitude vs Phase

An object that displays a polar plot of Magnitude against Phase of a complex Spectrum.

Use

Use Magnitude vs Phase to display Spectrums or Waveforms. Waveforms are automatically converted to spectrums by way of a Fourier Transform. The Radius of each data point is the spectrum's magnitude; the Angle is the Spectrum's phase in the current trig units.

You can change the display between Polar and Smith Chart modes by using Properties on the object menu. You change from Lines to Smith Chart.

Marker values are displayed in polar format (r:radius, a:angle) for the Polar grid type and complex impedance or admittance format for Smith Chart and Inv Smith Chart grid type.

Open View Parameters

These are the default open view parameters. Their use, and the availability of other parameters, is controlled by selections on the object menu and in the Properties dialog box (object menu [image] Properties).

Mag - The name of the radius scale.

Span: - The vertical dimension of the display. When the origin is centered on the display, the Span is twice the radius. This parameter controls the scaling of the display. Default is 2.

Trace1 - The name of the first trace.

Polar Reference Location - Specifies the part of the polar plot displayed. This is quicker than scrolling to the area. Changing the reference point in the entry field scrolls the part of the graph specified (such as Center) to the location specified (such as (0, @0)).

Ref Radius: - The radius value of the bold graticule circle.

Object Menu

Auto Scale [image] Auto Scale - Immediately rescales the display to show the entire trace. Auto Scale resets the polar reference location to Center (0,@0). (Can be added as a control pin, or set using the Scales properties tab to automatically rescale the display after data is collected.)

Auto Scale X - Not available.

Auto Scale Y - Not available.

Zoom [image] - Scales the display.

In - Magnifies the display to contain only the rectangular region that you selected with the pointer. You select the region after selecting this feature by dragging on the graph area. This action outlines the information with a "rubber band" box.

Out 2|5|10|20|50|100X - Expands the scales of the display by a factor in both the X and Y directions about the center.

Clear Control [image] - Parameters that specify when to clear the display.

Display - Clears the displayed trace(s). This parameter may be added as a control input.

Next Curve - Resets the display to show the next curve in a family of curves (data from the next time the display operates) without clearing the previous curve. Next Curve must be selected (or activated) before each new curve in the family. This parameter may be added as a control input.

Center Markers - If markers are available, brings them to the center of the visible part of the trace. This is useful if you've scrolled the display and markers are not visible.

Add Right Scale - Adds up to two additional Radius-axis scales to permit traces to have different scale ranges. After adding a right scale, you may add a terminal for its input (object menu [image] Add Terminal [image] Data Input). Then set its properties using the Traces and Scales tabs on the Properties dialog box.

Print - Presents the Print dialog box. Pressing OK prints or plots a copy of the device's entire display on the selected output device. Print may be added as a control input.

Properties

Name - Assigns a variable name to the display. By entering a name, you can programmatically read marker values if they are turned on. The variable is an Object data type, and it is local to the context where the display exists. See Notes for details.

ClearAtPreRun - When the property is True, the display is cleared at PreRun time. Default is True.

 ClearAtActivate - When the property is True, the display is cleared at Activate time. Default is True.

ShowTracesLegend - In the open view, controls the visibility of the trace names and colors. Use EditTracesAndScales to control the edit-button function of the trace legends. Default is True.

 ShowScalesLegend - In the open view, controls visibility of the scale names. Use EditTracesAndScales to control the edit-button function of the scale legends. Default is True.

 ShowScrollBars - In the open view, controls visibility of the scroll bars on the scales. Default is True.

 ShowAutoScaleButton - In the open view, controls visibility of the Auto Scale Button. Default is False.

 EditTracesAndScales - In the open view, controls the edit-button function of the trace and scale properties. When enabled, click on an individual trace or scale name to edit its properties. Default is True. Use ShowTracesLegend and ShowScalesLegend to control visibility of the trace(s) and scale(s) names.

GridType: - Default is Lines. Shows lines at the major divisions and tic marks at the minor divisions. The X and Y axes are shown as thick lines.

Smith Chart - Displays data in a Smith Chart (also called an "impedance chart"). Marker values are given as real and imaginary impedances. The bold circle is the "reference radius" and its linear radius value is shown in the lower right corner of the display. The Smith Chart grid and markers only represent properly scaled values if the input data has been normalized. To normalize the data, divide all magnitudes by the characteristic impedance.

Inv Smith Chart - Displays data in an Inverse Smith Chart (also called an "admittance chart"). An Inverse Smith Chart is used in the same way as a Smith Chart except grid and marker values are admittance values rather than impedance values.

NumMarkers: - The number of markers defined for the graph. To move markers to a different trace, go to the open view and click on the button to the left of the marker values near the bottom of the display. The button cycles through the different line types and colors of the different traces.

MarkerInterpolate - When the property is True, >/font> you can place markers between the displayed data points. The marker values displayed are calculated by linear interpolation. Default is False.

DisplayBackColor: - Allows you to select the color of the display area from a palette. You can select different colors when the display appears in the detail view and the panel view.

Traces Group: (one per trace)

Name: - The name of the trace that is displayed to the left of the graph area and the name of the corresponding input terminal.

Color: - The color of the trace. Each added trace has a different color than the existing traces. Default for the first trace is yellow.

LineStyle: - The format of the line connecting data points. Default is a continuous line.

PointStyle: - The symbol that marks each data point. To show unconnected data points, select the single dot LineStyle format and the desired PointStyle symbol. Default is a dot.

Scale - If it exists for more than one Y scale, choose which scale this Trace is scaled by.

Scales property: (one per X and Y scale and extra Y scales)

Show Scale: - If you have multiple Radius scales, a selection (using a check box) to specify if the end points and an axis of each additional right scale is displayed to the right of the graph area.

Scale Name: - The names of the scales appearing in the open view.

Automatic Scaling: - Controls whether the display automatically rescales to show the entire trace immediately after it receives data. Default is True. If this is turned False, you can rescale the display by using the Auto Scale button on the General tab, in the Layout group, or the AutoScale command on the object menu.

Vertical Span: - The vertical dimension of the display. The default value is 2.

Scale Color - The color of any background grid or tic marks. Default is Gray.

Reference Corner: - Specifies the part of the polar plot displayed. This is quicker than scrolling to the area. Changing the Reference Value scrolls the part of the graph specified (such as Center) to the location specified (such as (0, @0)). The default value is Center.

Reference Value: - Defines the numeric polar coordinate values to be used in the polar plot. The default values are (0, @0).

Notes

Inputs must be of the type Spectrum, Waveform, or Coord (Scalar or Array 1D).

Input data of type Coord is plotted by simply using its x and y values as rectangular coordinates without first being converted to type Spectrum.

Add traces with the Add Terminal [image] Data Input object menu selection. Up to twelve traces are allowed.

When the Automatic Scaling property is on (Scales tab), the program executes faster if a complete set of data is sent to the display. Then, the display automatically rescales once. If a program sends one data point at a time to the display, the display may automatically rescale after each data point, which will slow down program execution. In this case, use a Collector object to create an array, then send the array to the display.

Adding Control Inputs

You can add a Title control input pin, which sets the title bar name to the specified text value. This allows programmatic control over the title shown when the display is printed.

You can add a Traces control input pin. The control input data must be an array of records (or a record scalar if you only want to control one trace). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A field named TraceNum with an integer value (1 is the first trace). The TraceNum field is required. An error occurs if it is omitted.

One or more of the following fields:

Name

Pen

LineType

PointType

The Name field must have a text value. The Pen, LineType and PointType values must be integers from 0 to n, where 0 draws nothing and n is the number of choices available.

You can add a Scales control input pin to control the scales parameters listed above. The control input data must be an array of records (or a record scalar, if you only want to control one scale). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A Text field named Scale with a value X, Y (or Y1), Y2, or Y3. The Scale field is required. An error occurs if it is omitted.

One or more of the following fields:

Name - Changes the scale name in the open view. Must be a text value.

Min - Sets the X scale minimum. Must be an integer or real value.

Max - Sets the X scale maximum. Must be an integer or real value.

Mapping - Must have a text value of Linear or Log.

AutoScale - Controls automatic scaling. Must have a text value of On or Off.

Refer to "Using Records and DataSets" in VEE Advanced Techniques for further information.

Programmatically Setting and Reading Marker Values

You can programmatically get and set marker values. To prepare the display, open its Properties dialog box. On the General tab, enter a value for Name. The value for Name implicitly declares an Object variable that is local to the display’s context. Next, turn on a setting in the Markers group. VEE assigns the following properties to the markers’ X and Y positions, including the delta values. (Marker1 points down; Marker2 points up.)

Marker1X (gets the position as a Real64)

Marker1Y (gets the position as a Real64)

Marker2X (gets the position as a Real64)

Marker2Y (gets the position as a Real64)

MarkerDX (gets the position as a Real64)

MarkerDY (gets the position as a Real64)

Marker1 (gets/sets the position as a Coord)

Marker2 (gets/sets the position as a Coord)

The Marker1 and Marker2 properties can be used to read the current marker position or move the marker to a new position. All other marker properties are read-only. If you attempt to move the marker to a coordinate that is not on the trace, the marker will "snap" to the closest point that is on the trace.

In your program, enter one or more expressions in a Formula object to set or read the marker values. Each expression must contain the display Name and the marker property of interest. Marker property names are not case-sensitive. If the display’s Name is XY, and Delta Markers is turned on, the following expressions will read all the available marker values, assigning them to the variables a through f as Real64 scalars:

a = XY.Marker1X

b = XY.Marker1Y

c = XY.Marker2X

d = XY.Marker2Y

e = XY.MarkerDX

f = XY.MarkerDY

You can assign the display Name to a global variable. Add an assignment expression to your program in a Formula object, and declare the global using the Declare Variable object. As an example, assume you declared the variable globalXY as a global, and set its Type to Object. Then, in the context where the display exists, add this expression to your program:

Set globalXY = XY

This lets you read the display’s marker values from another context in the program using an expression such as:

a = globalXY.Marker1X

As you develop a program, you may want to include a way to pause the program so you can manually reposition the markers before the program reads their values. One way to pause a program is to add a Confirm (OK) button between the display’s sequence output and the Formula object’s sequence input. Alternately, you may want to position the markers programmatically.

Location

Display [image] Spectrum (Freq) [image] Magnitude vs Phase (Polar)

Display [image] Spectrum (Freq) [image] Magnitude vs Phase (Smith)

See Also

Magnitude Spectrum, Phase Spectrum, Polar Plot, Spectrum (Freq), and Default Preferences.

To Display a Waveform, To Set Markers in the Display, To Get and Set Marker Properties


Main

Main is the root UserObject window in VEE.

Use

The Main window is the root UserObject in VEE programs. It is required in programs and cannot be deleted. Other UserObject and UserFunction windows are created from the Main window.

If the Main window has been minimized or closed, it can be re-opened by selecting it from the View menu. It can also be reopened by clicking on Main in the VEE Program Explorer window.

Properties

Title - Displays the current title of the program. You can edit the title when an object is placed in the panel view. The title is displayed in the title bar of the program when the program is run with the -r command-line option. The default is Untitled.

ShowPanelonExecute: - This property is available when you add an object to the Main panel view. When ShowPanelonExecute is on, the Main panel view appears in the Execution window when you run the program.

TrigMode group:

Degrees | Radians | Gradians - specifies the trigonometric units used in the main program. If you select Radians, your trigonometric calculations will execute the fastest. The Trig Mode used by UserObjects is not affected by this setting.

Convert Infinity to 9.9E37 on Binary Reads - If the check box is selected, when an instrument (or a file containing instrument data) returns +INF (+infinity), -INF (-infinity), or NAN (not a number) on a binary read, VEE converts it. This conversion will slow down I/O somewhat on every binary read.

You may want to select the check box if you're getting data from an instrument that follows the SCPI standard and you're outputting that data to a graphical display object. If the check box is not selected, and +INF, -INF, or NAN is sent to a display object, you will get a floating-point exception error. If the check box is selected, you'll be aware of the +INF, -INF, or NAN value by a spike in the graph.

Notes

If the Main window has not been closed, it will also appear in the Window menu as:

Window [image] 1 Main

Location

View [image] Main

See Also

Arrange Icons, Cascade, Close All, Minimize All, Program Explorer, Tile Horizontally, Tile Vertically, and Properties (Object)


Make UserFunction (Object menu)

A menu selection, found only in the object menu for a UserObject, which converts the UserObject into a UserFunction.

Use

Use Make UserFunction to convert a UserObject into a UserFunction. The name displayed in the title area of the UserObject becomes the UserFunction name. The UserObject disappears and is replaced with a Call Function object.

Notes

If the name in the UserObject title area is not a valid name for a UserFunction, or if you haven't changed the name from "UserObject", you will be prompted for a new name for the UserObject.

A valid UserFunction name must begin with an alpha character, followed by alphanumeric characters or underscores.

Location

On the object menu (UserObjects only) [image] Make UserFunction

See Also

Call, Edit UserFunction, hidePanel(), showPanel(), UserFunction, and UserObject.


Make UserObject

A menu selection, found only under Edit UserFunction, which re-converts a UserFunction back into a UserObject.

Use

Use Make UserObject to convert a UserFunction back into a UserObject.

Notes

Make UserObject is almost the inverse of Make UserFunction. Although Make UserObject converts the UserFunction back into a UserObject, any Call Function objects remain present, and remain connected in the main context of the program. However, the UserFunction itself is gone.

Location

Edit [image] Edit UserFunction [image] Make UserObject (on the UserFunction Object Menu)

See Also

Edit UserFunction, Make UserFunction (Object menu), UserFunction, and UserObject.


math_syntax

This list contains links to the Help topics for VEE math operators and functions.

abs(x)
acos(x)
acosh(x)
acot(x)
acoth(x)
a + b (add)
Ai(x)
a ~= b (almost equal to)
a AND b
+ - * /
Array
asin(x)
asinh(x)
atan(x)
atan2(y,x)
atanh(x)
bartlet(x)
Bessel
beta(x,y)
Bi(x)
binomial(a,b)
bit(x,n)
bitAnd(x,y)
bitCmpl(x)
bitOr(x,y)
bits(str)
bitShift(x,y)
Bitwise
bitXor(x,y)
blackman(x)
Calculus
ceil(x)
charToInt(a)
clearBit(x,n)
clipLower (x,a)
clipUpper (x,a)
cofactor(x, row,col)
comb(n,r)
Comma Operator
Complex Parts
concat(x,y)
conj(x)
convolve(a,b)
cos(x)
cosh(x)
cot(x)
coth(x)
cubert(x)
Data Filtering
defIntegral (x,a,b)
deriv(x, order)
derivAt(x, order,pt)
det(x)
a div b (truncated division)
a / b (divide)
dmyToDate (d,m,y)
a == b (equal to)
erf(x)
erfc(x)
exp(x)
exp10(x)
a ^ b (exponent)
exponential regression
factorial(n)
fft(x)
floor(x)
fracPart(x)
Freq Distribution
gamma(x)
Generate
a > b (greater than)
a >= b (greater than or equal to)
hamming(x)
hanning(x)
hmsToHour (h,m,s)
hmsToSec (h,m,s)
Hyper Bessel
Hyper Trig
i0(x)
i1(x)
identity(x)
ifft(x)
im(x)
init(x,val)
integral(x)
intPart(x)
intToChar(a)
inverse(x)
j(x)
j0(x)
j1(x)
jn(x,n)
k0(x)
k1(x)
a < b (less than)
a <= b (less than or equal to)
linear regression
log(x)
log10(x)
logarithmic regression
Logical
logMagDist (x,from,thru, logStep)
logRamp (numElem, from,thru)
mag(x)
magDist(x, from,thru, step)
matDivide (numer, denom)
matMultiply (A,B)
Matrix
max(x)
maxIndex(x)
maxX(x)
mday(aDate)
mean(x)
meanSmooth (x,numPts)
median(x)
min(x)
minIndex(x)
minor(x,row, col)
minX(x)
a mod b (modulo)
mode(x)
month(aDate)
movingAvg (x,numPts)
a * b (multiply)
NOT a
a != b (not equal to)
now()
a OR b
ordinal(x)
perm(n,r)
phase(x)
poly(x,vec)
Polynomial
polynomial regression
polySmooth (x)
Power
power curve regression
product(x)
ramp (numElem, from,thru)
random (low,high)
randomize (x,low,high)
randomSeed (seed)
re(x)
Real Parts
recip(x)
rect(x)
Regression
rms(x)
rotate(x, numElem)
round(x)
sdev(x)
setBit(x,n)
Signal Processing
signof(x)
sin(x)
sinh(x)
sort(x, direction, field)
sq(x)
sqrt(x)
Statistics
strDown(str)
strFromLen (str,from,len)
strFromThru (str,from, thru)
String
strLen(str)
strPosChar (str,char)
strPosStr (str1,str2)
strRev(str)
strTrim (str,trimlist)
strUp(str)
a - b (subtract)
sum(x)
tan(x)
tanh(x)
Time & Date
totSize(x)
transpose(x)
Triadic Operator
Trig
vari(x)
wday(aDate)
xcorrelate (a,b)
xlogRamp (numElem, from,thru)
a XOR b
xramp (numElem, from,thru)
y0(x)
y1(x)
year(aDate)
yn(x,n)


MATLAB® Script

An object that calls the MATLAB Script engine with operations specified by MATLAB Script commands. VEE data can be passed to the MATLAB Script engine and returned from the MATLAB Script engine.

MATLAB Help

The Help topic you are reading describes how to invoke MATLAB from VEE. It does not explain how to write MATLAB programs or what you can do with MATLAB once you have invoked it. Help on MATLAB and its scripting language is available two ways:

VEE’s Function & Object Browser has a Help button at the bottom. Clicking the Help button when you have a MATLAB function selected starts the MATLAB Help system and displays the topic for that function.

The MATLAB object menu (right-click menu) contains a MATLAB Help choice. (Note: "Help" and "MATLAB Help" are both on this menu.) Clicking MATLAB Help starts the MATLAB Help system.

If your MATLAB Script object was created from VEE’s Device menu, the help system is started with the main MATLAB HelpDesk window. If your MATLAB Script object was created from VEE’s Function & Object Browser, the help system is started with the topic for the function you selected when you created the MATLAB Script object.

Use

Use the MATLAB Script object to access the power of MATLAB software within VEE. This object is similar to a VEE Formula object. MATLAB Script commands can be entered in the formula field, and data can be passed using input and output pins.

Many predefined functions are available when you create a MATLAB Script object from the Function & Object Browser. Alternately, the default object available from the Device menu has two inputs, one output, and an example script (X=A+B). Any of these example objects can be modified to have a different number of input or output pins and a different set of MATLAB Script commands. There are approximately 1500 functions available in the MATLAB Script engine supplied with VEE. The MATLAB Signal Processing Toolkit provides about 200 more functions. VEE's Function & Object Browser shows about 500 of the most popular functions. Consult the MATLAB HelpDesk for information about all the MATLAB functions.

Variable names in MATLAB Script are case sensitive, but not so in VEE. In other words, "A" and "a" refer to the same variable in VEE, but refer to different variables in MATLAB. Keep this in mind when writing formulas in MATLAB Script. For example, if your VEE data terminal is named "A", use "A" in the MATLAB Script, not "a".

VEE does not perform any syntax checking of MATLAB Script commands. If your MATLAB Script object contains syntax errors, those errors are not discovered until the MATLAB Script engine is called. Any errors reported by MATLAB are mapped to VEE errors 591 or 592. If MATLAB reports any warnings, these are shown as VEE Caution messages.

The first MATLAB Script object to execute opens a single MATLAB session. All other instances of MATLAB Script objects share that same session. Therefore, MATLAB Script objects can share global variables in the MATLAB workspace.

MATLAB Script, as provided by this VEE object, does not support the MATLAB function definition capability.

Data Notes

Only some VEE data types are allowed as MATLAB Script inputs. You can use input terminal data type constraints to ensure that VEE input data is converted to a supported type. For example, assume you have Int32 data. The MATLAB Script object does not accept integer data, but it accepts Real64 data. You can double-click the input terminal and select Real64 as the Required Type. With that constraint set, inbound Int32 data is automatically promoted to Real64 by the input pin before it is passed to MATLAB. VEE also provides some automatic array conversions to increase the convenience of using VEE 1D arrays. The following tables describe the alignment of VEE data types and MATLAB data types.

Input Pin Data

From VEE Type | To MATLAB Type | Notes
Text Scalar | character array | Promoted to array size (1 x n), where n is the length of the VEE string.
Text 1D Array | character array | Becomes array size (m x n), where m is the number of elements in the VEE array and n is the length of the longest VEE string in the array.
Text Array, 2D or more | -- | Not supported.
Real64 Scalar | double array | Promoted to array size (1 x1).
Real64 Array | double array | VEE 1D arrays are promoted to array size (m x 1). VEE arrays with 2D or greater retain original shape. ..
Complex Scalar | complex array | Promoted to array size (1 x 1).
Complex Array | complex array | VEE 1D arrays are promoted to array size (m x 1). VEE arrays with 2D or greater retain original shape.
Waveform 1D Array | double array | VEE 1D arrays are promoted to array size (m x 1). Waveform time-base mapping is lost.

Output Pin Data

From MATLAB Type | To VEE Type | Notes
Empty Matrix | nil | No output container is generated.
character array of size (1 x n) | Text Scalar |
character array of size (m x n) | Text 1D Array | Shaped as 1D array with m elements.
character array, 3D-10D | -- | Not supported.
double array of size (1 x 1) | Rea64 Scalar |
double array of size (m x 1) or (1 x n) | Real64 1D Array or Real64 2D Array | Automatic demotion to VEE 1D array is selectable in object properties. Otherwise, a 2D array is returned.
double array, 2D-10D | Real64 Array |
complex array of size (1 x 1) | Complex Scalar |
complex array of size (m x 1) or (1 x n) | Complex 1D Array or Complex 2D Array | Automatic demotion to VEE 1D array is selectable in object properties. Otherwise, a 2D array is returned.
complex array, 2D-10D | Complex Array |

MATLAB Script allows (and sometimes generates) infinity as a numeric value. VEE does not allow values of infinity. If a MATLAB Script object attempts to return the floating-point representation for plus infinity, minus infinity, or NaN (not a number), the call will fail and generate VEE error 594.

Multiple MATLAB Versions

Before VEE uses the MATLAB Script engine, it checks if MATLAB is already registered on the system. If MATLAB is already present, the MATLAB Script engine installed with VEE is not registered as the MATLAB Automation Server. In this case, VEE uses the existing MATLAB and does not interfere with the operation of the MATLAB development environment. More importantly, MATLAB uses the first entry it finds in the Path. If you have a prior version of MATLAB, it will be in the Path prior to the MATLAB installed with VEE. In this case, the older MATLAB will always be called first.

In certain cases, you might want to register the MATLAB Script engine installed with VEE, even though there was a pre-existing version. (For example, if your previous MATLAB version did not have the Signal Processing Toolbox.) In this case, you can manually register with the command:

<vee_install_dir>\matlab\bin\matlab.exe /regserver

If you later need to toggle the registration back to the other MATLAB version, execute that version with the /regserver option or, alternately, you can just run that version of MATLAB as it reregisters itself every time it runs.

MATLAB 5.3, 6.1, and 6.5 all work under VEE 7.0.

Location

Device [image] Function & Object Browser [image] MATLAB Functions

Device [image] MATLAB Script


Merge

Adds the contents of a program or set of saved objects into the work area while keeping the existing contents of the work area.

Use

Use Merge to combine a previously saved program or set of objects into an existing program in the VEE work area. Merge is useful for bringing in previously created programs or sets of objects from a library of functions that are used often.

Notes

Any Default Preferences (for example, the Trig Mode) that are saved with a program will not be loaded or used when you Merge that program into the VEE work area. The currently active Default Preferences for the work area will remain unchanged.

You cannot use Merge for UserFunctions. Use Merge Library instead.

Merge presents a dialog box that lets you select the name of the file you want to open. When you use Merge, the dialog box points to the lib directory under the VEE program installation directory.

You use Merge to load a file that was saved with Save or Save As.

If the program saved has a panel view, the panel is not imported into the program. The panel views of UserObject are input.

Doing a Merge from a program file containing an embedded I/O configuration does not merge any of that I/O configuration. See Embedded I/O Configurations and Merging.

Location

File [image] Merge

See Also

Merge Library, Open, Save, and Save Objects.

To Create a Library of UserObjects

To Merge Objects and Programs from Library Files


Merge Library

Loads a library of UserFunctions into the work area.

Use

Use Merge Library to merge UserFunctions previously saved in a library file of functions, into the current work area.

Merge Library loads all of the UserFunctions from a specified file. (UserFunctions are created by selecting the Make UserFunction selection on the object menu of a UserObject. You create a library by creating several UserFunctions and saving them to a file.)

Once the library of UserFunctions is loaded, the functions are executed (called) by name using the Call object.

Notes

Merge Library is used for advanced operations where you have developed sets of UserFunctions into libraries. When you develop a library of UserFunctions, you can keep the source code for those functions in a single place. Refer to VEE Advanced Techniques for a detailed discussion of using UserFunctions.

UserFunctions loaded by Merge Library operate exactly like any locally-created UserFunction within the program. You can execute any UserFunction with the Call object, or by including the UserFunction in any object that takes an expression (for example, Formula). You can edit any of the merged UserFunctions, loaded by Merge Library, as they are now merged into the VEE work area.

Any Default Preferences (for example, the Trig Mode) that are saved with a function will not be loaded or used. The currently active Default Preferences for the work area will remain unchanged.

Merge Library presents a dialog box that allows you to select the name of the file you wish to open. The dialog box points to the lib directory under the VEE program installation directory.

Doing a Merge Library from a program file containing an embedded I/O configuration does not merge any of that I/O configuration. See Embedded I/O Configurations and Merging.

Location

File [image] Merge Library

See Also

Call, Delete Library, Edit UserFunction, Import Library, Open, Save, Save Objects, UserFunction, and UserObject.


Merge Record

An object that allows the user to merge two or more records of the same shape into a single record.

Use

Use Merge Record to merge two or more records into a single record. Any number of scalar records can be merged. Any number of record arrays can be merged so long as all arrays have the same number of elements.

Notes

Any number of input pins (A, B, and so forth) may be added, but each must be of the Record data type. The merged record is output on the Record output pin.

The records to be merged must not have any duplicate field names. The field names are taken from the input records (the input terminal names are ignored).

Location

Data [image] Access Record [image] Merge Record

See Also

Build Record, From DataSet, Record Constant, Set Field, To DataSet, UnBuild Record, and Properties (Object)


Message Box

An object that displays a pop-up dialog box that contains a message to the user.

Use

Use Message Box to display an informational message to the user. The user responds by pressing one of the buttons on the dialog box. The text on the buttons may be customized.

In the pop-up dialog box, when a button is pressed, a 1 is output on the output pin associated with (having the same name as) the button.

Open View

  • Message - The string of information displayed on the Message Box pop-up dialog box. Use \n to start a new line in the text in this field. You may add this parameter as a data input. Default is User Message

  • Symbol - The graphical image displayed on the left side of the Message Box pop-up dialog box. You may add this parameter as a data input.

    • Question - A white question mark within a green circle.

    • Exclamation - A black exclamation mark within a yellow circle.

    • Information - A white letter "i" within a blue circle.

    • Stop - A white text "STOP" within a red hexagon.

    • Blank - Use this when you do not want a graphic on the pop-up.

    • <Custom...> - Gives you a dialog box allowing you to select a picture from graphics files to use as your symbol.
      In the dialog box:
      - Picture - Enter the file name of a graphics file from your file system. The directory shown is the bitmaps directory under the installation directory. To choose a file from another directory, press the Browse... button.
      - Actual (default) automatically resizes the object to fit the graphic image's actual size.
      The image does not scale if the object is resized. - Scaled rescales the graphic image's size as the object is resized.

You may add this parameter as a data input. Default is Information

  • Buttons - The text shown on the buttons displayed at the bottom of the Message Box pop-up dialog box. Choices are

  • OK

    • OK Cancel

  • Abort Retry Ignore

    • Yes No

    • Yes No Cancel

    • Retry Cancel

    • <Custom ...> - Gives you a dialog box in which to input text for the button labels for up to three buttons. If you leave an input field blank, you will not get a button for that field.

The data output pins are automatically configured to correspond to your choice for Buttons.

  • Default - The button that is selected when the user presses Enter. The choices displayed depend on the Buttons chosen. You may add this parameter as a data input. Default is OK.

Properties

  • PopupTimeoutEnabled - When this property is True, a Timeout output pin is added to the object. Default is False.

  • PopUpDuration - Sets the length of time the pop-up dialog box is displayed. After this period of time, the dialog box times out and a value of 1 is output on the Timeout output pin. No other outputs pins have data if the Timeout pin executes. This field is only available when the Timeout Enabled check box is selected. Default is 60 seconds.

Notes

The default location of the pop-up dialog box is approximately at the center of the work area. If you move it, next time it will pop-up to the new location.

To respond to the pop-up dialog box using only the keyboard: when the dialog box pops up, use the Enter key to select the leftmost button and the Esc key to select the rightmost button. Or use the Tab key to move between the buttons and select the buttons with the Space bar.

The pop-up dialog box is only displayed while the program is running. While the pop-up dialog box is displayed, the entire program pauses execution, then continues when the dialog box is closed.

If you added a Timeout output pin to the object by turning on Timeout Enabled in Properties on the General tab, you can delete it only by turning off Timeout Enabled. You cannot delete this output pin using Delete Terminal on the object menu, or Ctrl+D (the "delete terminal" shortcut).

Location

Data [image] Dialog Box [image] Message Box

See Also

File Name Selection, List Box, Int32 Input, Real64 Input, Text Input, and UserObject.

About Built-In Dialog Box Objects


Meter

An object that graphically displays a Scalar numeric value.

Use

Use Meter to display a value on an analog scale and digital numeric field.

Open View

The minimum and maximum values of the Meter are set on the open view of the object by clicking on the present value and typing in a new value. If minimum value is greater than the maximum value, the Meter needle's operation direction is changed (i.e., right to left instead of left to right).

These values may also be added as control inputs.

Properties

ClearAtPreRun - When the property is True, the contents of the Meter are cleared at PreRun. Default is True.

 ClearAtActivate - When the property is True, the contents of the Meter are cleared at Activate. Default is True.

Orientation - Sets how the Meter is displayed. If the orientation of the Meter is vertical, the minimum value is at the top and the maximum is at the bottom. Default is Horizontal.

 ShowDigitalDisplay - If the property is True, a digital display of the displayed value is added to the bottom of the open view of the object. If the property is False, the digital display is not displayed and the object operates faster. Default is True.

 ShowTics - Controls visibility of scale’s tic marks and labels. Default is True.

 Logarithmic - When the property is True, changes scale from linear to logarithmic. Default is False.

 LabelSpacing - Controls which tic marks are labeled with the scale values. Default is Every Other Tic.

Sub-Range Configuration Category: - Sets different colors for different ranges of the display. The color ranges overlay each other with red on the bottom and green on top. This allows red (default) sub-ranges at each end of the scale.

Show Range - When the property is True, the sub-range color is displayed on the object.

Meter Range - Sets the limits of the sub-range.

ColorRange - Sets the color for the different ranges

NumberFormat:

Global Format - Use the default format. Default is True.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

Notes

The input data must be Scalar and able to be converted to Real64 (Complex, PComplex, Spectrum, and Coord must be first "unbuilt".)

Location

Display [image] Indicator [image] Meter

See Also

AlphaNumeric, Logging AlphaNumeric, and Default Preferences.

To Show an Analog Display of Data


Minimize All

A function for managing windows in the VEE workspace.

Use

Minimize All will minimize all opened, non-minimized windows. Minimized windows will appear as small icons at the bottom of the VEE workspace.

Location

Window [image] Minimize All

See Also

Arrange Icons, Cascade, Close All, Tile Horizontally, and Tile Vertically.


Minimize (Object Menu)

Iconizes the open view of an object or window.

Use

Use Minimize to show the icon view of an object or to minimize an open window (Main, UserObject, UserFunction) in the VEE work space.

Notes

Minimize is available from the open view of all objects and windows.

Short Cuts

To minimize an object or window, press the minimize button on the upper right of the object or window (on the right side of the title bar).

Location

On the object menu [image] Minimize

See Also

Restore (Object Menu).


Miscellaneous Operators

A Formula type object found under Function & Object Browser.

Use

Generally, you can use the Miscellaneous Operators objects to access the Triadic Operator, to create or read simple arrays, or to read a field in a record.

Notes

When you have selected Category: Miscellaneous, the Member column of the Function & Object Browser dialog box will display a variety of operator examples. Clicking on one of these examples will bring up a VEE object pre-loaded with that Miscellaneous Operator. The example objects include:

(a?b:c) - A triadic operator. If 'a' is true (non-zero), then 'b' is output, else 'c' is output.

PI - The value 3.14 (carried out 17 decimal places). A transcendental number represented by the ratio of the circumference to the diameter of a circle.

[1,2,3] - Create a 1-dimensional array from scalars.

[a,b,c] - Create an array of any dimension from matching-shape parts.

a[2] - Return part of an array.

a[5,3:4,*] - Return part of a more complex array.

rec.field - Return one field of a record.

object.value - Get a Property of an ActiveX object.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Miscellaneous

See Also

Assignment, Function & Object Browser, and Triadic Operator


Move (Object Menu)

Moves this object.

Use

Use Move to reposition the object on the work area by dragging it.

Notes

Move retains the connections with other objects. If Automatic Line Routing is set, it may take a few moments to redraw lines.

Move works in both Panel and Detail view.

To move multiple objects, select the objects (using CTRL-left mouse button or Edit [image] Select All) and drag them.

You may also select multiple objects to move by drawing a rectangle around the objects them. You can accomplish this by placing your mouse in the upper left corner of the area you are selecting and then, with the CTRL key and your left mouse key depressed, drag to the lower right corner of the selection area.

If moving causes Objects to overlap in Panel view, use Bring to Front or Send to Back from the Object Menu to adjust the positioning of the Objects.

Short Cuts

Instead of selecting Move, place your cursor over the object. This activates the four-corner move cursor. Drag the object (using the left mouse button). The pointer must not be over an action area of the object (like a button or an entry field).

Location

On each object menu [image] Move

See Also

Object Menu.


MultiDevice Direct I/O

An object that writes data to and reads data from more than one instrument in the same transaction box.

Use

Use MultiDevice Direct I/O to output and input a variety of encodings and formats to instruments at various I/O addresses.

Open View Parameters

The open view shows the list of transactions to be executed.

Direct I/O Actions:

READ: Reads data from an instrument using the specified encoding and format.

WRITE: Writes data to an instrument using the specified encoding and format.

EXECUTE: For a GPIB instrument, sends either a Selected Device Clear, Go To Local, Remote, or Group Execute Trigger command. For a serial instrument, sends Break or Reset. For a GPIO instrument, sends Reset. For a VXI message-based instrument, sends either a Selected Device Clear, Go To Local, Remote, Trigger, Lock Device, or Unlock Device command.

WAIT: Waits the specific number of seconds before executing the next transaction. For a GPIB instrument or a VXI message-based instrument, wait until the bitwise AND of the serial poll response with the mask is either zero (ALL CLEAR) or non-zero (ANY SET).

For GPIO instruments only, the READ action allows IOSTATUS and the WRITE action allows IOCTL.

For VXI instruments only, the READ and WRITE action allows REGISTER: and MEMORY:. The WAIT action also supports the ability to wait until the value in a memory or register offset AND a mask value satisfy the ANYSET, ALL CLEAR, or EQUAL.

Object Menu

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Print Trans - Prints the detailed dialog box that describes the currently highlighted transaction.

Short Cuts

You can quickly add a data terminal by placing the cursor over the input or output terminal display area and then pressing CTRL+A. Each press of CTRL+A adds an additional data terminal.

You can quickly delete a data terminal by placing the cursor over the terminal view area and then pressing CTRL+D.

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Notes

MultiDevice Direct I/O is very similar to Direct I/O. However, MultiDevice Direct I/O is not dedicated to any specific instrument. Each transaction can communicate with any configured instrument at various I/O addresses. The transaction dialog box lets you specify the intended instrument from the available configured instruments.

You can use an instrument's default address originally entered during instrument configuration, or specify another address. In cases where an instrument address is different, click on the Default Address button to reveal an additional text box. Enter the new address value or variable name in the box.

Location

I/O [image] Advanced I/O [image] MultiDevice Direct I/O

See Also

Advanced I/O, Component Driver, Direct I/O, Formula, Instrument Manager, Panel Driver, and To/From VXIplug&play.

To Read Data Using Direct I/O

To Use a Direct I/O Object

Properties (Object)

For more information on MultiDevice Direct I/O, see the chapter titled, "Using Transaction I/O" in the VEE Advanced Techniques manual.


New

Clears the work area.

Use

Use New to clear the work area.

Notes

If your program has not been saved, New prompts you to save your changes.

New does not clear the Paste buffer. New reads in the default Preferences settings from the defaults file, VEE.RC.

New maintains the directory paths that the Save and Open commands use.

Short Cuts

Press CTRL+N to clear the program.

Location

File [image] New

See Also

Default Preferences


Next

An object that causes a Repeat [image] object to immediately start the next iteration.

Use

Use Next to skip to the next iteration of the current loop without executing the remaining objects on the iteration subthread.

If Next is not on an iteration subthread, it stops all execution on the subthread.

Notes

Next is often used with an If/Then object to conditionally control iteration.

Location

Flow [image] Repeat [image] Next

See Also

Break, For Count, For Log Range, For Range, If/Then/Else, On Cycle, and Until Break.

To Loop Part of a VEE Program

Properties (Object)


Noise Generator

An object that generates a waveform of noise data.

Use

Use Noise Generator to generate a waveform of simulated white noise.

Open View Parameters

All of these parameters may be set from the open view or added as data inputs.

Amplitude - The absolute value of the maximum and minimum values. Default is 1. No value is greater than Amplitude. No value is less than -Amplitude.

Time Span: - The duration of the waveform (in seconds) Default is 20m.

Num Points: - The number of points in the waveform. The time between points in the waveform is Time Span/N. Num Points must be positive. Default is 256.

Location

Device [image] Virtual Source [image] Noise Generator

See Also

Build Arb Waveform, Build Waveform, Comparator, Function Generator, Pulse Generator, and Properties (Object)


Note Pad

Displays an editable Rich Text Format (RTF) dialog box that displays user-supplied information. There is a default NotePad entry, which demonstrates the capabilities of the dialog box, that is displayed when the NotePad dialog box is opened. To create your own default NotePad entry, edit the notepad.rtf file in installdir\templates. If you want an empty NotePad dialog box, edit the notepad.rtf file and leave it empty or delete the file altogether.

Use

Use Note Pad to document your program, label the panel view, or write notes.

Open View Parameters

To enter information in the Note Pad, click on the panel, then type the note, or type the text in any RTF enabled application then cut and paste it into the Note Pad.

Object Menu

Insert File... - Gives you a dialog box that lets you select an existing text or RTF file to insert into Note Pad.

Clear All - Clears all text from Note Pad, with a dialog box to confirm or reject the action.

Properties

EditingEnabled - When this property is True, allows you to edit the text in the panel. When not selected, no editing is allowed. This is useful when a Note Pad is on a panel view and you don't want other users to modify your note.

Notes

Each Note Pad is a stand-alone object and is not connected to any other objects.

After editing or resizing, scroll bars are added or removed from the Note Pad as required.

You can use all the usual VEE edit functions to edit the text area.

Notepad is in Rich Text Format (RTF) with word wrap enabled. You can cut and paste any RTF document into Notepad.

You can print the Notepad text, but it is always in pure text format.

You can create a template for your Notepad entries by editing the Notepad.rtf file found in %installDir%\Templates.

Location

Display [image] Note Pad

See Also

Description

To Document Your Program


Object Menu

The menu associated with every object that contains selections that affect that object.

Use

Use the object to set status, edit, set controls, and add and delete the terminals of an object.

Use Object Menu to access the following object actions:

Restore

Move

Size

Minimize

Clone

Replace

Help

Properties

Description

Add Terminal

Data Input

Control Input

Data Output

Error Output

Delete Terminal

Input

Output

Delete

Use the Object Menu to access the following actions for objects placed on the panel views of the Main window, UserObjects, or UserFunctions:

Move

Size

Properties…

Go To Detail View

Delete

Notes

Many object menus have additional menu features specific to that object. Refer to information on the object for details about those object menu choices.

Most objects have additional options specific to that object on their Properties window (which is accessed via Properties on the object menu). Refer to information on the object for details about those object properties.

Short Cuts

To delete an object, double-click on the object menu button (available in the open view).

To access the Properties window, double-click on the object's title bar (available in the open view).

To get help on a selected object, press F1.

Location

To access an object's Object Menu, position the pointer over the object and click the right mouse button. Note that to access the object menu of the open view of a UserObject you must position the pointer over the title bar or terminals, otherwise, the Edit Menu is presented.

You can also access the Object Menu from the open view by positioning the pointer over the object menu button (the square with a bar in the middle to the left of the title bar) and pressing the left mouse button.

See Also

Move (Object Menu), Size (Object Menu), Minimize (Object Menu), Restore (Object Menu), Replace, Clone (Object Menu), Help (Object Menu), Properties (Object), Description, Add Terminal, Delete Terminal, Control Input (Object Menu), Data Input (Object Menu), Data Output (Object Menu), Error Output (Object Menu), and Cut (Object Menu).


OK

An object that pauses the execution flow of a subthread until it is pressed.

Use

Use OK to wait for a user response.

Properties

Assign to Function Key - When the property is True, this object will execute when the specified function key is pressed from the detail view or the panel view. You can assign a function key to multiple OK objects. Default is False.

Assign to Enter Button - When the property is True and the program is being run from the panel view, pressing Enter on your keyboard will execute the object. You can have only one OK assigned to Enter per context. If you try to set it for more than one OK, the previous setting is unselected. This property is useful when you use an OK object as the OK button on a custom dialog box. Default is False.

 Assign to Escape Button - When the property is True and the program is being run from the panel view, pressing the Esc key on your keyboard will execute the object. You can have only one OK assigned to Esc per context. If you try to set it for more than one OK, the previous setting is unselected. This property is useful when you use an OK object as the Cancel button on a custom dialog box. Default is False.

Notes

OK often is used when creating a dialog box or with the Selection Control constant.

The button part of the OK doesn't become active until the object operates.

You can use either the Go data output pin or the sequence output pin to continue the thread.

Another way to pause the execution flow of a thread when using objects under Data [image] Constant is to use the Wait for Input property.

Location

Flow [image] Confirm (OK)

See Also

Gate, JCT, Start and Stop.

To Assign a Button to a Function Key

To Assign an OK Button to the Enter or Esc Key

To Build a Basic Dialog Box

To Keep a Pop-Up Panel Displayed


On Cycle

An object that begins execution of a subthread at a specified interval.

Use

Use On Cycle to execute a subthread that must be repeated periodically. The output of On Cycle is the current date and time. This date and time can be displayed on any object that supports a Time Stamp number format.

Use On Cycle to trigger instruments at specific intervals.

Open View Parameters

Enter the number of seconds per iteration period in the entry field or as an input. If this value is 0 or -1, On Cycle operates continuously (the same as Until Break).

Notes

Execution of the subthread hosted by the On Cycle output continues until one of the following occurs:

All objects that can, have operated. The subthread is deactivated, the iteration timer is reset, and the subthread is reactivated after the number of seconds have elapsed.

A Break object operates. The subthread is deactivated and the sequence output pin is activated.

A Next object operates. The subthread is deactivated and the iteration timer is reset.

On Cycle starts operation at the specified time period. If the thread takes longer to complete than the period of the On Cycle object, then the next iteration starts at the next period synchronization point. For example, if the period in the On Cycle is 1 second and the thread it hosts takes 1.5 seconds to complete, the next iteration starts .5 seconds after the thread completes.

While waiting for the next time period to begin, On Cycle "sleeps" allowing other objects on this or other threads to operate.

When the subthread hosted by the On Cycle object finishes an iteration, all data containers sent during the previous iteration are invalidated before the next iteration. This prevents "old" data from a previous iteration from being reused in the current iteration. However, if flow branching is present within the iterative subthread, some objects may not execute on every iteration. Thus, data containers sent by those objects may be invalidated before other objects can execute on the data. To obtain the desired propagation in this case, use the Sample & Hold object.

Location

Flow [image] Repeat [image] On Cycle

See Also

AlphaNumeric, Break, For Count, For Log Range, For Range, Next, Sample & Hold, Until Break, and Properties (Object)

To Loop Part of a VEE Program


Open

Loads a program file into the work area, replacing the existing program.

Use

Use Open to bring a previously saved program into VEE for running or editing. Move to the directory where the file is located, click on the file name, and press OK. The program is displayed on your screen.

Notes

Open presents a dialog box that allows you to select the name of the program file you wish to open. When VEE is loading in the file, the pointer icon changes to a pair of glasses.

You can Open a file that was saved with Save Objects, Save or Save As.

Short Cuts

CTRL+O opens files.

Location

File [image] Open

See Also

Merge, Save, and Save Objects.

To Open a VEE Program File


Panel Driver

An instrument control object that forces all the function settings in the corresponding physical instrument to match the settings in the control panel displayed in the open view of the object.

Use

Use a Panel Driver to control the state of an instrument by means of the control panel displayed in the open view. Before you can use a Panel Driver, the instrument driver for the desired instrument must be installed.

To add a Panel Driver object to the VEE work area, click on I/O [image] Instrument Manager to display the Instrument Manager dialog box. Check the list of configured instruments to see if there is an entry for the instrument you want to use:

If the instrument you want is in the list, and is properly configured:

1. Click once on the instrument entry to highlight it.

2. Click on Panel Driver to add the instrument panel for that instrument.

If the instrument you want is not in the list, or is in the list but not properly configured, it needs to be added and/or configured. Refer to Instrument Manager, Instrument Properties, and Advanced Instrument Properties.

For further information about using Panel Drivers, refer to the chapter titled "Using Panel Driver and Component Driver Objects" in the VEE Advanced Techniques manual

Object Menu

Add Terminal by Component [image] Select Input Component - Use to add fields visible on the panel as inputs to a Panel Driver.

Add Terminal by Component [image] Select Output Component - Use to add fields visible on the panel as outputs to a Panel Driver.

Show Config - Displays the configuration of an instrument. (You can edit this configuration using I/O [image] Instrument Manager.)

Sync - Synchronizes an instrument driver's state to the state of the instrument under the following conditions:

The ID code contains a sync component.

The ID has live mode turned on.

Notes

Panel Drivers may be operated with Live Mode off. This allows you to run your program without communicating with the instrument, even if the instrument is not connected to the computer. This means that you must set Live Mode to on (refer to Advanced Instrument Properties) before your program will communicate with the physical instrument.

Panel Drivers can be used interactively or within a program. To set the value of an individual component, click on the field containing the value of the component and complete the resulting dialog box. To make a measurement and display the result, click on the corresponding numeric readout or XY display inside the Panel Driver open view.

It is possible to have more than one object controlling a single instrument. That is, two Panel Driver objects could control fgen in the same program. These objects perform state recalls when operated.

You can add inputs and outputs for the components of a Panel Driver (just as for a Component Driver). Inputs perform the set actions, panel set actions, and coupled actions for the component. Control pins are available as inputs to initialize the instrument, programmatically change the instrument address and timeout period, and for a sync signal. Outputs perform the get actions and panel get actions.

Location

I/O [image] Instrument Manager

See Also

Advanced Instrument Properties, Add Terminal, Component Driver, Direct I/O, Instrument Manager, Instrument Properties, and To/From VXIplug&play.

To Read Data with a Panel Driver Object

Also, see "Using Panel Driver and Component Driver Objects" in the VEE Advanced Techniques manual.


Paste

Places a copy of the Paste buffer on the work area.

Use

After using Cut, Copy, or Clone on the Detail view, use Paste to retrieve a copy of a set of objects.

Paste allows you to recover objects that have been accidentally Cut. Connections to and from these objects are also restored.

Notes

The Paste buffer only holds one set of objects. The Paste buffer is replaced each time you Clone, Cut or Copy.

The Paste buffer is not cleared when you use Open, Merge, or New.

Paste does not paste text - only objects. Use keyboard keys to cut/copy and paste text. Highlight the text, then use Ctrl-C (copy) or Ctrl-X (cut), then click in the new location and use Ctrl-V (paste).

Location

Edit [image] Paste

See Also

Clone (Object Menu), Copy, Cut, Cut (Object Menu), and Replace.


Pause

A button that temporarily causes all threads to stop running.

Use

Use Pause to temporarily suspend program execution. After Pause is selected, select Resume to continue execution.

Notes

Selecting Pause puts the program in the "paused" state. Both Resume and the Step functions are active and can be used to proceed.

Short Cuts

Press CTRL+P to pause a running program.

Location

Debug [image] Pause

See Also

Call Stack, Line Probe, Default Preferences, Run/Resume, Run, Show Data Flow, Show Execution Flow, Step Into, Step Over, Step Out, Stop, Stop (Object), and Toggle Breakpoint.

To Step through a Program


PComplex

An object that outputs a constant PComplex number.

Use

Use PComplex to set a Polar Complex constant or to get user input. Click on the entry field to enter a value.

Example

To use PComplex as a prompt on a panel view, change the name of the PComplex object to a prompt such as Enter the AC voltage:. The user fills in the requested information in the entry field.

Type in (2,@PI/2) and it will calculate the PComplex Constant formula.

Properties

DataShape - Sets the initial data shape of the value(s) to be output with this object.

 ArraySize: - When 1D Array is selected, Size sets the length of the array.

 ArraySizeFixed - When the property is True, the array cannot have lines added or deleted. This selection is only available if 1D Array is selected.

 ShowArrayIndices - When the property is True, each line in the entry field is indexed. This selection is only available if 1D Array is selected. Default is False.

Wait for Input - When the property is True, the object does not operate until the object's value is changed. When the property is False, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When the property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

 InitialValue - Specifies the value to be set. Default value is (0, @0).

 InitializeAtPreRun - When the property is True, the Initial Value is set at PreRun time. Default is False.

 InitializeAtActivate - When the property is True, the Initial Value is set at Activate time. Default is False.

NumberFormat: Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value(s). This input requires a PComplex value, either a Scalar or an Array 1D. The Constant is reconfigured to match the shape of the incoming data.

The Reset input allows you to programmatically set the value(s) to zero. If the Constant is configured as an Array 1D, all values are set to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the value can be changed in the object’s open view.

Note that the Initial Value field is always a scalar, even if the PComplex is configured to be an array. Trig Mode specifies phase value units.

You can enter Magnitude and Phase values (separated by commas) and VEE formats automatically.

Location

Data [image] Constant [image] PComplex

See Also

Alloc PComplex, Complex, Constant, Coord, Date/Time, Selection Control, UInt8, Int16, Int32, Real32, Real64, Text, Default Preferences, and Toggle Control.

To Use a Data Constant


Phase Spectrum

An object that graphically displays the magnitude of a spectrum as a function of its phase angle.

Use

Use Phase Spectrum to display phase against frequency of Spectrums or Waveforms (in the frequency domain). Waveforms are automatically converted to spectrums by way of a Fourier Transform. The X axis is in the sampling units of the input spectrum. The Y axis units are the current Trig Mode setting.

Open View Parameters

These are the default open view parameters. Their use, and the availability of other parameters, is controlled by selections on the object menu and in the Properties dialog box (object menu [image] Properties).

Phase - The name of the Y axis.

Trace1 - The name of the first trace.

Freq - The name of the X axis.

Object Menu

Auto Scale [image] - Clicking these menu items immediately rescales the display to show the entire trace. (Can be added as control pins, or set using the Scales properties tab to automatically rescale the display after data is collected.)

Auto Scale - Automatically scales both axes.

Auto Scale X - Automatically scales the X axis.

Auto Scale Y - Automatically scales the Y axis.

Zoom [image] - Scales the display.

In - Magnifies the display to contain only the rectangular region that you selected with the pointer. You select the region after selecting this feature by dragging on the graph area. This action outlines the information with a "rubber band" box.

Out 2|5|10|20|50|100X - Expands the scales of the display by a factor in both the X and Y directions about the center.

Clear Control [image] - Parameters that specify when to clear the display.

Display - Clears the displayed trace(s). This parameter may be added as a control input.

Next Curve - Resets the display to show the next curve in a family of curves (data from the next time the display operates) without clearing the previous curve. Next Curve must be selected (or activated) before each new curve in the family. This parameter may be added as a control input.

Center Markers - If markers are available, brings them to the center of the visible part of the trace. This is useful if you've scrolled the display and markers are not visible.

Add Right Scale - Adds up to two additional Y-axis scales to permit traces to have different scale ranges. After adding a right scale, you may add a terminal for its input (object menu [image] Add Terminal [image] Data Input). Then set its properties using the Traces and Scales tabs on the Properties dialog box.

Print - Presents the Print dialog box. Pressing OK prints or plots a copy of the device's entire display on the selected output device. Print may be added as a control input.

Properties

Name - Assigns a variable name to the display. By entering a name, you can programmatically read marker values if they are turned on. The variable is an Object data type, and it is local to the context where the display exists. See Notes for details.

ClearAtPreRun - When the property is True, the display is cleared at PreRun time. Default is True.

 ClearAtActivate - When the property is True, the display is cleared at Activate time. Default is True.

ShowTracesLegend - In the open view, controls the visibility of the trace names and colors. Use EditTracesAndScales to control the edit-button function of the trace legends. Default is True.

 ShowScalesLegend - In the open view, controls visibility of the scale names. Use EditTracesAndScales to control the edit-button function of the scale legends. Default is True.

 ShowScaleLabels - In the open view, controls visibility of the values labeling the scale axes. Default is True.

 ShowScrollBars - In the open view, controls visibility of the scroll bars on the X and Y scales. Default is True.

 Show AutoScaleButton - In the open view, controls visibility of the Auto Scale Button. Default is False.

 EditTracesAndScales - In the open view, controls the edit-button function of the trace and scale properties. When enabled, click on an individual trace or scale name to edit its properties. Default is True. Use ShowTracesLegend and ShowScalesLegend to control visibility of the trace(s) and scale(s) names.

GridType - Lines. Shows lines at the major divisions and tic marks at the minor divisions. The X and Y axes are shown as thick lines.

Markers Category: - Allows you to find the exact value of a data point on the displayed curve. If the data is plotted on a log scale, the values shown on the marker are the linear data points.

To move markers to a different trace, go to the open view and click on the button to the left of the marker values near the bottom of the display. The button cycles through the different line types and colors of the different traces.

 NumMarkers - The number of markers shown in the graph. The None selection is the default.

 MarkerInterpolate - When the property is True, you can place markers between the displayed data points. The marker values displayed are calculated by linear interpolation. Default is False.

DisplayBackColor - Allows you to select the color of the display area from a palette. You can select different colors when the display appears in the detail view and the panel view.

ScaleLabelFont - Allows you to select the font of the scale labels from the list of available fonts on your system. The default font for scale label text is set in Default Preferences on the Fonts tab for Screen Element: Graph Scale Label Text.

Traces group: (one per trace)

Name - The name of the trace that is displayed to the left of the graph area and the name of the corresponding input terminal.

Color - The color of the trace. Each added trace has a different color than the existing traces. Default for the first trace is yellow.

LineStyle - The format of the line connecting data points. Default is a continuous line.

PointStyle - The symbol that marks each data point. To show unconnected data points, select the single dot LineStyle format and the desired PointStyle symbol. Default is a dot.

Scale - If it exists for more than one Y scale, choose which scale this Trace is scaled by.

Scales property: (one per X and Y scale and extra Y scales)

Show Scale: - If you have multiple Y scales, a selection (using a check box) to specify if the end points and an axis of each additional right scale is displayed to the right of the graph area.

Scale Name: - The names of the scales appearing in the open view.

Automatic Scaling: - Controls whether the display automatically rescales to show the entire trace immediately after it receives data. Default is on. If this is turned off, you can rescale the display by using the Auto Scale button on the General tab, in the Layout group, or the Auto Scale command on the object menu.

Maximum: - The maximum values of the scales.

Minimum: - The minimum values of the scales.

Label Spacing: - Controls which tic marks are labeled with the scale values. Default for X scale is Every Other Tic; default for Y scale(s) is Every Major Tic.

Mapping: - The way the x and y data is mapped to the display. The mapping may be linear or log. To make a log-log plot, change both X and Y axes to Log. Default is Linear.

Log Cycles: - The maximum number of decades shown (counting down from the maximum x and y values) when Automatic Scaling is on. Log Cycles is only used when the Mapping is Log. Log Cycles is useful when a trace contains a large dynamic range in the data. Default is 4.

Scale Color - The color of any background grid or tic marks. Default is Gray.

ScaleNumberFormat: (a property appears for the X and Y scales, and for any additional Y scales.)

Global Format - Use the default format. Default is on.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

The X and Y marker values take on the same number format as the scale to which they are attached. The delta marker values for X and Y use the default number format unless you use the Time Stamp format. Then, if both markers 1 and 2 on the X scale, or both markers on the Y scale are using the Time Stamp format, the delta marker values use the Delta Time format.

Notes

Inputs must be of the type Spectrum, Waveform, or Coord (Scalar or Array 1D).

Input data of type Coord is plotted by simply using its x and y values without first being converted to type Spectrum.

Add traces with the Add Terminal [image] Data Input object menu selection. Up to twelve traces are allowed.

When the AutomaticScaling property is True (Sc ales category), the program executes faster if a complete set of data is sent to the display. Then, the display automatically rescales once. If a program sends one data point at a time to the display, the display may automatically rescale after each data point, which will slow down program execution. In this case, use a Collector object to create an array, then send the array to the display.

Adding Control Inputs

You can add a Title control input pin, which sets the title bar name to the specified text value. This allows programmatic control over the title shown when the display is printed.

You can add a Traces control input pin. The control input data must be an array of records (or a record scalar if you only want to control one trace). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A field named TraceNum with an integer value (1 is the first trace). The TraceNum field is required. An error occurs if it is omitted.

One or more of the following fields:

Name

Pen

LineType

PointType

The Name field must have a text value. The Pen, LineType and PointType values must be integers from 0 to n, where 0 draws nothing and n is the number of choices available.

You can add a Scales control input pin to control the scales parameters listed above. The control input data must be an array of records (or a record scalar, if you only want to control one scale). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A Text field named Scale with a value X, Y (or Y1), Y2, or Y3. The Scale field is required. An error occurs if it is omitted.

One or more of the following fields:

Name - Changes the scale name in the open view. Must be a text value.

Min - Sets the X scale minimum. Must be an integer or real value.

Max - Sets the X scale maximum. Must be an integer or real value.

Mapping - Must have a text value of Linear or Log.

AutoScale - Controls automatic scaling. Must have a text value of On or Off.

Refer to "Using Records and DataSets" in VEE Advanced Techniques for further information.

Programmatically Setting and Reading Marker Values

You can programmatically get and set marker values. To prepare the display, open its Properties window. Enter a value for Name. The value for Name implicitly declares an Object variable that is local to the display’s context. Next, turn on a setting in the Markers group. VEE assigns the following properties to the markers’ X and Y positions, including the delta values. (Marker1 points down; Marker2 points up.)

Marker1X (gets the position as a Real64)

Marker1Y (gets the position as a Real64)

Marker2X (gets the position as a Real64)

Marker2Y (gets the position as a Real64)

MarkerDX (gets the position as a Real64)

MarkerDY (gets the position as a Real64)

Marker1 (gets/sets the position as a Coord)

Marker2 (gets/sets the position as a Coord)

The Marker1 and Marker2 properties can be used to read the current marker position or move the marker to a new position. All other marker properties are read-only. If you attempt to move the marker to a coordinate that is not on the trace, the marker will "snap" to the closest point that is on the trace.

In your program, enter one or more expressions in a Formula object to set or read the marker values. Each expression must contain the display Name and the marker property of interest. Marker property names are not case-sensitive. If the display’s Name is XY, and Delta Markers is turned on, the following expressions will read all the available marker values, assigning them to the variables a through f as Real64 scalars:

a = XY.Marker1X

b = XY.Marker1Y

c = XY.Marker2X

d = XY.Marker2Y

e = XY.MarkerDX

f = XY.MarkerDY

You can assign the display Name to a global variable. Add an assignment expression to your program in a Formula object, and declare the global using the Declare Variable object. As an example, assume you declared the variable globalXY as a global, and set its Type to Object. Then, in the context where the display exists, add this expression to your program:

Set globalXY = XY

This lets you read the display’s marker values from another context in the program using an expression such as:

a = globalXY.Marker1X

As you develop a program, you may want to include a way to pause the program so you can manually reposition the markers before the program reads their values. One way to pause a program is to add a Confirm (OK) button between the display’s sequence output and the Formula object’s sequence input. Alternately, you may want to position the markers programmatically.

Location

Display [image] Spectrum (Freq) [image] Phase Spectrum

See Also

Magnitude Spectrum, Magnitude vs Phase, Spectrum (Freq), and Default Preferences.

To Display a Waveform, To Set Markers in the Display, To Get and Set Marker Properties


Picture

An object that is used to display a graphic image.

Use

Use Picture to display a graphic image on the Detail or Panel View. It allows you to tile, stretch, and clip your picture. The graphics file name may be added as a data input to the Picture object.

Properties

Picture Category:

Use Picture to choose a graphics file from your file system to be displayed on this object. The directory shown is the bitmaps directory under the installation directory. To choose a file from another directory, press the Browse ... button. You may add the file name as a data input.

Actual | Centered | Scaled | Tiled
-- Select Actual to specify automatic resizing of the object to fit the actual size of the graphic image. If the object is resized, the image does not scale, and is displayed in the upper left corner of the object.
-- Select Centered to specify that the image is kept fixed size and always centered on the object, even if the size of the object is changed.
-- Select Scaled to specify that the image is scaled as the size of the object is changed. Rescaling may take a few moments to complete.
-- Select Tiled to duplicate the image horizontally and vertically on the object to create a "wallpaper" effect.

Preview - Displays the current graphic image selected.

VEE examines the file to determine the file format. The currently supported formats are:

Bitmaps (*.BMP)

JPEG (*.JPG)

Windows Meta File (*.WMF)

GIF87a (*.GIF)

GIF89 (*.GIF)

Portable Network Graphics (*.PNG)

Default bitmaps are located in the bitmaps directory under the VEE program installation directory.

Notes

If the size property is set to a choice other than Actual, the default background color for the object is the same as the default Panel View color so that the background blends into the Panel View.

A background graphic can be added to any UserObject or UserFunction panel, as well as having Picture objects on their panels.

GIF89 support is limited to a single frame (no animated GIFs), and a transparent background color is not allowed.

Location

Display [image] Picture

See Also

Label, Beep, and UserObject.

To Add a Picture to the Panel


Plug&play Device Configuration

Allows you to specify or modify the configuration for a Plug&play instrument to be used from VEE

Use

Use this dialog box to add or edit instruments from the list of configured instruments.

Note that not all Plug&play drivers support all platforms. Also, certain versions of VTL/VISA may not be supported on all platforms. Please check with the appropriate vendor.

Dialog Information

The Plug&play Driver tab of the Advanced Instrument Properties dialog box is divided into these areas:

Plug&play Driver Name: - Select the name of the driver. The selections available are the drivers which have been installed. This is also the directory where the driver is located. This field is required. The default location of these drivers are:

Windows 98: C:\VXIPNP\WIN98

Windows NT: C:\VXIPNP\WINNT

Parameters to init() call

Address: - Enter the digits of the address that identifies the instrument. The address format depends on the interface that the instrument is connected to:

- VXI address string. For a VXI instrument with an embedded or MXIbus controller, the address string takes the form VXI[board]::VXI logical address[::INSTR]. An example is VXI::24::INSTR for an instrument at logical address 24.

- GPIB-VXI address string. For a VXI instrument that is being controlled from a GPIB card to a command module, the address string takes the form GPIB-VXI[board]::VXI logical address[::INSTR] . An example is GPIB-VXI0::24::INSTR for an instrument at VXI logical address 24.

- GPIB address string. For a non-VXI instrument being controlled from a GPIB card, the address string takes the form GPIB[board]::GPIB primary address::[GPIB secondary address][::INSTR] An example is GPIB0::4::24::INSTR for an instrument at primary address 4 and secondary address 24.

Perform Identification Query - When the check box is selected, the identity of the instrument is checked the first time a function panel for this driver is executed. Generally, you want to select this check box.

Perform Reset - When the check box is selected, the instrument is initialized to a pre-defined state the first time a function panel for this driver is executed. Generally, you want to select this check box.

Notes

The Plug&play Driver Name field allows you to select the driver name from those drivers that have already been installed. To install the set of files needed for each driver, follow the instructions included with the instrument driver. Each VXIplug&play driver was written by the hardware vendor and shipped with the instrument.

It is possible to have more than one object controlling a single instrument. It is also possible to have multiple copies of the same driver, each controlling a different physical instrument. In either case, it is the configured name that determines which object controls which instrument.

Location

I/O [image] Instrument Manager. Then press the Add… or Properties button to display the Instrument Properties dialog box. Press the Advanced button.

See Also

Direct I/O, Instrument Manager, Instrument Properties, Panel Driver, and To/From VXIplug&play.


Polar Plot

An object that displays a graphical plot in polar coordinates.

Use

Use Polar Plot to display a value on a polar scale when separate polar information is available for radius and angle data.

When more than one trace is to be plotted, each execution of the Polar Plot object uses the single angle input data with each trace's Radius input data, therefore, all traces share the single angle input.

Open View Parameters

These are the default open view parameters. Their use, and the availability of other parameters, is controlled by selections on the object menu and in the Properties dialog box (object menu [image] Properties).

Y name - The name of the radius scale.

Span: - The vertical dimension of the display. When the origin is centered on the display, the Span is twice the radius. This parameter controls the scaling of the display. Default is 2.

RData1 - The name of the first trace.

Polar Reference Location - Specifies the part of the polar plot displayed. This is quicker than scrolling to the area. Changing the reference point in the entry field scrolls the point of the display specified (such as Center) to the coordinate specified (such as (0,@0)).

Ref Radius: - The radius value of the bold graticule circle.

Object Menu

Auto Scale [image] Auto Scale - Immediately rescales the display to show the entire trace. Auto Scale resets the polar reference location to Center (0,@0). (Can be added as a control pin, or set using the Scales properties tab to automatically rescale the display after data is collected.)

Auto Scale X - Not available.

Auto Scale Y - Not available.

Zoom [image] - Scales the display.

In - Magnifies the display to contain only the rectangular region that you selected with the pointer. You select the region after selecting this feature by dragging on the graph area. This action outlines the information with a "rubber band" box.

Out 2|5|10|20|50|100X - Expands the scales of the display by a factor in both the X and Y directions about the center.

Clear Control [image] - Parameters that specify when to clear the display.

Display - Clears the displayed trace(s). This parameter may be added as a control input.

Next Curve - Resets to display to show the next curve in a family of curves (data from the next time the display operates) without clearing the previous curve. Next Curve must be selected (or activated) before each new curve in the family. This parameter may be added as a control input.

Center Markers - If markers are available, brings them to the center of the visible part of the trace. This is useful if you've scrolled the display and markers are not visible.

Add Right Scale - Adds up to two additional Radius-axis scales to permit traces to have different scale ranges. After adding a right scale, you may add a terminal for its input (object menu [image] Add Terminal [image] Data Input). Then set its properties using the Traces and Scales tabs on the Properties dialog box.

Print - Presents the Print dialog box. Pressing OK prints or plots a copy of the device's entire display on the selected output device. Print may be added as a control input.

Properties

Name - Assigns a variable name to the display. By entering a name, you can programmatically read marker values if they are turned on. The variable is an Object data type, and it is local to the context where the display exists. See Notes for details.

ClearAtPreRun - When the property is True, the display is cleared at PreRun time. Default is True.

 ClearAtActivate - When the property is True, the display is cleared at Activate time. Default is True.

ShowTracesLegend - In the open view, controls the visibility of the trace names and colors. Use EnableEditTracesAndScales to control the edit-button function of the trace legends. Default is True.

 ShowScalesLegend - In the open view, controls visibility of the scale names. Use EnableEditTracesAndScales to control the edit-button function of the scale legends. Default is True.

 ShowScrollBars - In the open view, controls visibility of the scroll bars on the scales. Default is True.

 ShowAutoScaleButton - In the open view, controls visibility of the Auto Scale Button. Default is False.

 EnableEditTracesAndScales - In the open view, controls the edit-button function of the trace and scale properties. When enabled, click on an individual trace or scale name to edit its properties. Default is True. Use ShowTracesLegend and ShowScalesLegend to control visibility of the trace(s) and scale(s) names.

GridType - Default is Lines.

Smith Chart - Displays data in a Smith Chart (also called an "impedance chart"). Marker values are given as real and imaginary impedances. The bold circle is the "reference radius" and its linear radius value is shown in the lower right corner of the display. The Smith Chart grid and markers only represent properly scaled values if the input data has been normalized. To normalize the data, divide all magnitudes by the characteristic impedance.

Inv Smith Chart - Displays data in an Inverse Smith Chart (also called an "admittance chart"). An Inverse Smith Chart is used in the same way as a Smith Chart except grid and marker values are admittance values rather than impedance values.

Markers Category: - Allows you to find the exact value of a data point on the displayed curve. If the data is plotted on a log scale, the values shown on the marker are the linear data points.

To move markers to a different trace, click on the button to the left of the marker values near the bottom of the display. The button cycles through the different line types and colors of the different traces.

NumMarkers - The number of markers on the graph.

MarkerInterpolate - When this property is set to True, you can place markers between the displayed data points. The marker values displayed are calculated by linear interpolation. Default is False.

BackColor - Allows you to select the color of the display area from a palette. You can select different colors when the display appears in the detail view and the panel view.

Traces Group: (one per trace)

Name: - The name of the trace that is displayed to the left of the graph area and the name of the corresponding input terminal.

Color: - The color of the trace. Each added trace has a different color than the existing traces. Default is yellow.

LineStyle: - The format of the line connecting data points. Default is a continuous line.

PointStyle: - The symbol that marks each data point. To show unconnected data points, select the single dot LineStyle format and the desired PointStyle symbol. Default is a dot.

Scales: - If it exists for more than one Y scale, choose which scale this Trace is scaled by.

Scales property: (one per X and Y scale and extra Y scales)

Show Scale: - If you have multiple Radius scales, a selection (using a check box) to specify if the end points and an axis of each additional right scale is displayed to the right of the graph area.

Scale Name: - The names of the scales appearing in the open view.

Automatic Scaling: - Controls whether the display automatically rescales to show the entire trace immediately after it receives data. Default is on. If this is turned off, you can rescale the display by using the Auto Scale button on the General tab, in the Layout group, or the Auto Scale command on the object menu.

Vertical Span: - The vertical dimension of the display. The default value is 2.

Scale Color - The color of any background grid or tic marks. Default is Gray.

Reference Corner: - Specifies the part of the polar plot displayed. This is quicker than scrolling to the area. Changing the Reference Value scrolls the part of the graph specified (such as Center) to the location specified (such as (0, @0)). The default value is Center.

Reference Value: - Defines the numeric polar coordinate values to be used in the polar plot. The default values are (0,@0).

Notes

Inputs must be Scalar or Array 1Ds that can be converted to the type Real64.

Angle units are in the current Trig Mode.

All inputs must be the same size and shape. Mapping information on the inputs data is ignored.

Add traces with the Add Terminal [image] Data Input object menu selection. Up to twelve traces are allowed.

When the Automatic Scaling property is on (Scales tab), the program executes faster if a complete set of data is sent to the display. Then, the display automatically rescales once. If a program sends one data point at a time to the display, the display may automatically rescale after each data point, which will slow down program execution. In this case, use a Collector object to create an array, then send the array to the display.

Adding Control Inputs

You can add a Title control input pin, which sets the title bar name to the specified text value. This allows programmatic control over the title shown when the display is printed.

You can add a Traces control input pin. The control input data must be an array of records (or a record scalar if you only want to control one trace). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A field named TraceNum with an integer value (1 is the first trace). The TraceNum field is required. An error occurs if it is omitted.

One or more of the following fields:

Name

Pen

LineType

PointType

The Name field must have a text value. The Pen, LineType and PointType values must be integers from 0 to n, where 0 draws nothing and n is the number of choices available.

You can add a Scales control input pin to control the scales parameters listed above. The control input data must be an array of records (or a record scalar, if you only want to control one scale). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A Text field named Scale with a value X, Y (or Y1), Y2, or Y3. The Scale field is required. An error occurs if it is omitted.

One or more of the following fields:

Name - Must be a text value.

Min - Must be an integer or real value.

Max - Must be an integer or real value.

Mapping - Must have a text value of Linear or Log.

Refer to "Using Records and DataSets" in VEE Advanced Techniques for further information.

Programmatically Setting and Reading Marker Values

You can programmatically get and set marker values. To prepare the display, open its Properties dialog box. On the General tab, enter a value for Name. The value for Name implicitly declares an Object variable that is local to the display’s context. Next, turn on a setting in the Markers group. VEE assigns the following properties to the markers’ X and Y positions, including the delta values. (Marker1 points down; Marker2 points up.)

Marker1X (gets the position as a Real64)

Marker1Y (gets the position as a Real64)

Marker2X (gets the position as a Real64)

Marker2Y (gets the position as a Real64)

MarkerDX (gets the position as a Real64)

MarkerDY (gets the position as a Real64)

Marker1 (gets/sets the position as a Coord)

Marker2 (gets/sets the position as a Coord)

The Marker1 and Marker2 properties can be used to read the current marker position or move the marker to a new position. All other marker properties are read-only. If you attempt to move the marker to a coordinate that is not on the trace, the marker will "snap" to the closest point that is on the trace.

In your program, enter one or more expressions in a Formula object to set or read the marker values. Each expression must contain the display Name and the marker property of interest. Marker property names are not case-sensitive. If the display’s Name is XY, and Delta Markers is turned on, the following expressions will read all the available marker values, assigning them to the variables a through f as Real64 scalars:

a = XY.Marker1X

b = XY.Marker1Y

c = XY.Marker2X

d = XY.Marker2Y

e = XY.MarkerDX

f = XY.MarkerDY

You can assign the display Name to a global variable. Add an assignment expression to your program in a Formula object, and declare the global using the Declare Variable object. As an example, assume you declared the variable globalXY as a global, and set its Type to Object. Then, in the context where the display exists, add this expression to your program:

Set globalXY = XY

This lets you read the display’s marker values from another context in the program using an expression such as:

a = globalXY.Marker1X

As you develop a program, you may want to include a way to pause the program so you can manually reposition the markers before the program reads their values. One way to pause a program is to add a Confirm (OK) button between the display’s sequence output and the Formula object’s sequence input. Alternately, you may want to position the markers programmatically.

Location

Display [image] Polar Plot

See Also

Complex Plane, Magnitude Spectrum, Magnitude vs Phase, Spectrum (Freq), Strip Chart, Waveform (Time), and Default Preferences.

To Display Polar Data, To Set Markers in the Display, To Get and Set Marker Properties


Pop-Up List

See Selection Control.


Print

A dialog box that allows you to print using standard Microsoft Windows printing conventions.

Use

Use the Print dialog box to select the print quality and number of copies to print.

Dialog Information

Printer - Identifies the current Windows system printer. To change the printer, click on the Properties button to display the Print Setup dialog box.

Print Range - Fixed at All for VEE.

Print Quality - Selections are printer specific. For HP LaserJet Printers, it defaults to 300 dpi (300 dots-per-inch).

Copies - Enter the number of copies to print (default = 1).

Collate Copies - Defaults to off (no checkmark). Click on the check box to turn Collate Copies on.

When you are done, click on OK if you are ready to print or Cancel to stop without printing. Or, click on Properties if you want to display the Print Setup dialog box, which allows you to change additional parameters.

Notes

Refer to your Microsoft Windows documentation for further information about setting up printers for Windows applications.

Location

File [image] Print Screen

File [image] Print Program

File [image] Print Objects

See Also

Print Objects, Print Program, Print Screen, and Print Setup.

To Change the Printing Preferences

To Print a VEE Program

To Print Objects in a VEE Program

To Print or Copy the VEE Window

To Print the VEE Work Space


Print Objects

Outputs a page for each of the selected objects, containing all views and Description data, to a printer or a print file.

Use

Use Print Objects to get hardcopy of selected objects. Print Objects displays a dialog box that specifies information about the printer configuration.

Print Objects will print all views (icon, open, detail, or panel), along with Description data, for each object. If the object contains transactions, the detailed dialog box describing each transaction is also printed.

If no objects are currently selected, the Print Objects menu item will be grayed out.

Dialog Information

Print Objects displays the appropriate dialog box for your system; see Print.

Notes

Print Objects may take a few moments to capture the image of the objects, particularly if you select a large number of objects. While the image is being captured, the pointer changes to an hourglass. You can't use VEE until the capture is completed (the pointer changes back to an arrow).

VEE saves only one configuration for printing, which stays constant from one printing operation to the next.

Location

File [image] Print Objects

See Also

Print, Print Program, Print Screen, Default Preferences, and Select All.

To Change the Printing Preferences

To Print a VEE Program

To Print Objects in a VEE Program

To Print or Copy the VEE Window

To Print the VEE Work Space


Print Program

Outputs the entire detail view of the program to a printer or a print file.

Use

Use Print Program to get hardcopy of your entire program. Print Program displays the Print Options dialog box that allows you to specify what to output to the printer. After you have selected your print options, clicking on the OK button will bring up the Print dialog box.

Print Program produces indexed pages to show the complete structure of a VEE program. The output includes a total view of the top-level program, and a page for each object in the program, which shows all views of the object and its Description data. If the object contains transactions, the detailed dialog box describing the transaction is also printed. Each page of the output contains information describing the image's place in the program.

Various aspects of the printing process may be controlled independently by way of the Print Options dialog box.

Dialog Information

The Print Program dialog box displays five fields:

Print Nested UserObjects - Causes the print engine to recursively print any nested UserObjects that are within the object that is currently being printed.

Print Object Views - Causes all objects within a context to be printed. However, how an object is printed is somewhat dependent on an object's complexity. That is, simple objects, such as a Gate, a Junction, or an UntilBreak object, are printed as they would appear in the VEE program. More complex objects, such as a Graph or Sequencer object, will be printed in its open view form.

Print Header and Index Page - If this box is checked, each page of the VEE program printout will contain a two-line header which shows the date, time, program file name, and a page number. At the end of the printout, an index page will be printed which shows the page numbers of the indexed items.

Print Program Explorer - When this box is checked, the VEE program printout will show the information contained in the Program Explorer window.

Print Cover Page - When this box is checked, the first page of the VEE program printout will show the following:

A graphic of the VEE product logo.

The file name of the program being printed.

The file format under which the program was saved.

The revision code of the VEE software being used (such as 6.0, etc.).

The current VEE execution mode (VEE 6, VEE 5, etc.).

Print I/O Configuration - When this box is checked, the instrument configuration’s expanded tree view is printed. You can see the instrument configuration in I/O [image] Instrument Manager…

When you press OK, the appropriate dialog box appears for your system; see Print.

Notes

Print Program takes a few moments to capture the image of your program. While the image is being captured, the pointer changes to an hourglass. You can't use VEE until the capture is completed (the pointer changes back to an arrow).

VEE saves only one configuration for printing, which stays constant from one printing operation to the next.

Location

File [image] Print Program...

See Also

Default Preferences, Print, Print Screen, Print Objects, and Save Documentation.

To Change the Printing Preferences

To Print a VEE Program

To Print Objects in a VEE Program

To Print or Copy the VEE Window

To Print the VEE Work Space


Print Screen

Outputs the contents of the VEE window to a printer or a print file.

Use

Use Print Screen to get hardcopy of the portion of your program that is visible on your screen. Print Screen displays a dialog box that specifies information about the printer configuration.

Dialog Information

Print Screen displays the appropriate dialog box for your system; see Print.

Notes

Print Screen takes a few moments to capture the image in the window. While the image is being captured, the pointer changes to an hourglass. You can't use VEE until the capture is completed (the pointer changes back to an arrow).

The size of the VEE display window determines the size of the print area. To get a large output, maximize the VEE window (but too large an image gets clipped). Larger images take longer to scan and print.

VEE saves only one configuration for printing, which stays constant from one printing operation to the next.

Location

File [image] Print Screen

See Also

Print, Print Program, Print Objects, and Default Preferences.

To Change the Printing Preferences

To Print a VEE Program

To Print Objects in a VEE Program

To Print or Copy the VEE Window

To Print the VEE Work Space


Print Screen Object

An object that prints a copy of the visible portion of the VEE window on the system printer.

Use

Use Print Screen to print a copy of the visible work area while the program is running.

Notes

The printer used by Print Screen (the VEE system printer) is configured by:

File [image] Print Setup

Print Screen directs output to the configured graphics printer or directory.

A running program is paused when Print Screen operates. It resumes when Print Screen is finished.

Location

I/O [image] Print Screen

See Also

Print, Print Program, Print Screen, Print Objects, and Default Preferences.

To Change the Printing Preferences


Print Setup

A dialog box that allows you to set up your printer using standard Microsoft Windows printing conventions.

Use

Use the Print Setup dialog box to select a printer, the printing orientation, and the paper size and source.

Dialog Information

Printer - Select either Default Printer or Specific Printer. If you select Specific Printer, you can select from a list of printers configured on your Windows system.

Paper - Select the paper Size and Source from the lists of supported choices.

Orientation - Select either Portrait or Landscape.

If you click on Properties, an additional (the standard Windows) dialog box prompts you for further selections.

Notes

Refer to your Microsoft Windows documentation for further information about setting up printers for Windows applications.

When running VEE under Windows 98, Print True Type as graphics on the Font tab and Use raster graphics on the Graphics tab should be selected for almost all VEE printing situations.

When running VEE under Windows NT, Print Text as Graphics should be On in the Document Properties dialog box. This dialog box is accessed from File [image] Print Setup. In the Print Setup dialog box, click the Properties button, then the Advanced tab.

Location

File [image] Print Setup

(Or select one of the other print options from the file menu to bring up the Print dialog box.)

See Also

Print, Print Program, Print Objects, and Print Screen.

To Change the Printing Preferences

To Print a VEE Program

To Print Objects in a VEE Program

To Print or Copy the VEE Window

To Print the VEE Work Space


Profiler

A menu choice that provides you with execution information regarding UserObjects and UserFunctions.

Use

When you enable the Profiler, the Profiler Information dialog box will appear. From the Profiler Information dialog box you can profile a variety of execution parameters for each UserObject and UserFunction in a VEE program.

When the Profiler is started, it will provide you with comparative information regarding the amount of time each UserObject or each UserFunction is taking to execute. This information may be very useful when you are attempting to modify your VEE program to maximize efficiency, and improve execution speed.

As long as the Profiler is enabled, PROF will be highlighted on the program Status Bar in the lower right corner of the VEE workspace.

Dialog Information

Name - The Name column lists the name of each UserObject and each UserFunction being profiled.

# Executions - This column shows the number of times each UserObject or UserFunction executed during profiling.

% Time - Shows the total percentage of time, within the context of the entire program execution, that a particular UserObject or UserFunction spent executing.

Time(sec) - Shows the amount of time, in seconds, that a particular UserObject or UserFunction took to execute.

Start Profiling - The Start Profiling button is a toggle function that will Start Profiling or Stop Profiling. When profiling has been started, the PROF field will be highlighted on the VEE program Status Bar.

Refresh - The Profile Information dialog box does not automatically update with new profile data. You must click on the Refresh button to cause the Profiler to retrieve the latest profile data from the running, paused or stopped VEE program.

Clear - The Clear button resets all field values in the Profiler Information dialog box to 0 (zero).

Save - Clicking on the Save button will cause the Profiler data to be saved to a file name you can specify using the Options... button. (See the Options... explanation below).

Options... - Clicking on the Options... button will bring up the Profiler Options dialog box. The Profiler Options dialog box contains the following fields and buttons:

# digits for % Time - This field allows you to specify how many digits of accuracy (to the right of the decimal point) you want to have displayed in the % Time field on the Profiler dialog box. The default number of digits is 2.

# digits for Time(sec) - This field allows you to specify how many digits of accuracy (to the right of the decimal point) you want to have displayed in the Time(sec) field on the Profiler dialog box. The default number of digits is 3.

Show only executed contexts - If this box checked (enabled), Profiler data will be shown only on those UserObjects and UserFunctions that executed. By default, this box is not checked.

Save Options group - The items in the Save Options group define options about how Profiler data are saved to a data file. These options are:

- Save File Name: - This field specifies the file name where Profiler data is saved. Clicking on this field will bring up the Save data filename dialog box. From the Save data filename dialog box, you can specify the file name and file type you wish to use to store the Profiler data. The default file name is profile.dat.
- Overwrite data - If the Overwrite data box is checked (enabled), each time you Save newly collected Profiler data, you will overwrite the Profiler data previously collected and saved to the Profiler data file. By default, Overwrite data is enabled.
- Comma delimited - The Comma delimited box allows you to specify whether or not Profiler data is written to the data file in comma delimited format or non-comma delimited format. If the data is written in Comma delimited format, data is written to the data file with commas as delimiters (separators) between the various Profiler data fields. Using comma delimiters in the data file makes it much easier to transfer the data file to other types of software applications (such as spreadsheets). By default, the Comma delimited box is not checked (not enabled).
- OK - Click on OK to confirm any options you have selected in the Profiler Options dialog box.

Notes

After the Profiler has collected and displayed data in the Profiler dialog box, you can double click on any UserObject or UserFunction shown in the Name field, and that UserObject or UserFunction will be brought into the VEE workspace.

Additionally, clicking on any column labels such as Name, # Executions, % Time, etc., will cause the data displayed in the Profiler dialog box to be sorted in reverse order. Clicking again will reverse the sort again.

Location

View [image] Profiler

See Also

Call Stack, Clean Up Lines, Show Data Flow, Show Execution Flow, and Properties (Object).

To Profile Execution Parameters


Program Explorer

A View menu item that turns the Program Explorer window on or off.

Use

The Program Explorer menu selection is a toggle function that determines whether or not the Program Explorer window is displayed. When it is active, the Program Explorer window is located to the left of the VEE workspace. You can set the default state of Program Explorer by the following method:

1. Set the current state of Program Explorer using either the View menu or its Toolbar button.

2. Select File [image] Default Preferences.

3. Press the Save button on the Default Preferences dialog box.

4. Press the OK button on the Default Preferences dialog box.

The next time you start VEE, Program Explorer will start in the state that you established via Default Preferences.

You can resize the width of the Program Explorer window by hovering the mouse cursor over the vertical separation between the VEE workspace and the Program Explorer window itself. When the mouse cursor changes shape to a vertical split cursor, press the left mouse button and drag the cursor right or left to increase or decrease the size of the window.

You can resize the height of the Program Explorer window (if both Program Explorer and Properties are visible) by hovering the mouse cursor over the horizontal separator between the Program Explorer and the Properties windows.

Notes

The purpose of the Program Explorer window is to show the programmer the hierarchical structure of the VEE program that is currently loaded. This structure is shown using different icons to represent different parts of the program. The icons represent complete lists of the following different types of program information:

UserObject hierarchies starting at the Main UserObject.

Local UserFunction list.

Imported UserFunction library list and associated functions.

Imported Compiled Libraries and associated functions.

Imported Remote UserFunction Libraries and associated functions.

Globals, both declared and undeclared.

Declared library globals under the appropriate library.

Declared local variables under the appropriate context.

A large portion of the Program Explorer functionality is accessed through context menus. For example, if you move the mouse cursor over a UserObject icon in the Program Explorer window and then click the right mouse button, the context menu for a UserObject will appear.

Not all items in Program Explorer will provide a context menu, but the menus that do appear will depend on the type of item (a UserObject icon, a UserFunction icon, etc.). The following items in Program Explorer will provide context menus:

Program (or Root) Node

Main UserObject

UserObjects

UserFunctions

Local UserFunctions

Imported UserFunctions

Imported UserFunction Library

Remote UserFunction

Compiled Function

Global Variable

Library Global Variable

Local Variable

Location

View [image] Program Explorer

See Also

Default Preferences, UserFunction, UserObject

To Explore the Program Structure


Properties (Object)

The Window associated with every object containing selections that affect that object. This page describes only the general properties that are available on every object. Due to the characteristics of some objects, certain options and tabs are not available.

Use

Use the Properties Window to edit the title, set a breakpoint, set object colors and fonts, set title colors and fonts, change the appearance of the icon and the open view, and perform other object-specific actions.

Window Information

Title - Displays the current title of the object and allows you to edit it.

 ShowTitleBar - When this property is True, the title bar on the open view of the object is displayed.

 Show Terminals - When this property is True, Show Terminals displays the input and output terminals on the open view. The displayed terminals show the terminal name. To access complete terminal information, double-click on the object's terminal.

BreakpointEnabled - Enables the breakpoint on the object when the property is True; disables the breakpoint on the object when the property is False. Use BreakpointEnabled as a debugging tool to pause the execution of the program before this object executes. The object that is next to execute has a yellow border (by default). To continue execution, press the Resume or one of the Step buttons on the tool bar. When a breakpoint is set in the Properties window or selected from the Debug menu, the breakpoint is enabled and the object is highlighted with a orange (by default) border.

 Title BackColor - Allows you to select the color of the title bar (open view) and the title (icon view) from a palette.

 Title ForeColor - Allows you to select the color of the text used in the title bar (open view) and the title (icon view) from a palette.

 BackColor - Allows you to to select the color of the open view of the object from a palette.

 ForeColor - Allows you to select the color of the text used in the open view from a palette. This choice is not available if there is no text in the body of the open view of the object.

 Title Font - Allows you to select the font of the title bar (open view) and the title (icon view) from the list of available fonts on your system.

 Font - Allows you to select the font of the text used in the open view from the list of available fonts on your system. This choice is not available if there is no text in the body of the open view of the object.

ShowIconTitle - When the check box is selected, the object name on the icon view of the object is displayed. When the Show Title check box is not checked, the object name is not displayed on the icon. This feature is generally used if you want only a bitmap to be displayed on the icon.

IconPicture - Use Picture to choose a graphics file from your file system to be displayed on this icon.

The directory shown is the bitmaps directory under the installation directory. To choose a file from another directory, press the Browse ... button.

Select Centered to specify that the image is kept fixed size and always centered in the icon, even if the size of the icon is changed.

Select Scaled to specify that the image is scaled as the size of the icon is changed.

Preview - Displays the current graphic image selected. See Help on the Picture object for currently supported formats.

Default bitmaps are located in the bitmaps directory under the VEE program installation directory.

Border: available only from objects on the Panel view

None | Flat | Sunken | Raised - Select the border characteristics of the object displayed on the panel.

Location: available only from objects on the Panel view

X: - The horizontal location (in pixels) of the upper left corner of the object. 0 is located at the upper left of the work area.

Y: - The vertical location (in pixels) of the upper left corner of the object. 0 is located at the upper left of the work area.

Size: available only from objects on the Panel view

Width: - The distance between the left and right sides of the object. This number includes the width of any object border.

Height: - The distance between the top and bottom sides of the object. This number includes the width of any object border.

Notes

When modifying a Font property, the font Dialog has a checkbox labeled Automatically Resize Object on Font Change. When the check box is selected, you've changed a font, and pressed OK, the object resizes to fit the new font. When the check box is not selected, the object remains the same size, no matter how large or small the font is. This choice is not available if there is no Object Text font selection.

Any changes you make in the Properties window from the panel view of the object, only affect the panel view of that object. The Properties choices available from the panel view of an object are a subset of the detail view choices.

Most objects have additional options specific to that object in their Properties window (which is accessed via Properties on the object menu). Refer to information on that object for details about those object properties.

Short Cuts

You can quickly access the Properties window by double-clicking on the object's title bar (available in the open view).

Location

On each object menu [image] Properties ...

From the Main Menu View [image] Properties

See Also

Default Preferences and Object Menu


Pulse Generator

An object that generates and outputs a pulse waveform.

Use

Use Pulse Generator to generate a pulse waveform using your own specifications.

Properties

ErroronAliasing - If the property is True, returns an error if the period of any high or low pulse state is less than twice the sampling period (Time Span/Num Points). The purpose of this evaluation is to determine whether the points being generated provide an accurate representation of the pulse being generated. An unselected check box generates a literal presentation of points. Default is True.

Open View Parameters

All of these parameters may be set from the open view or added as data inputs.

Frequency - The rate in Hertz at which pulses are generated.

Pulse Width - The width, in time, of the pulses. The time is measured from the mid-point of the low-to-high transition to the mid-point of the high-to-low transition. Pulse width must be a positive real number. Default is 5m seconds.

Pulse Delay - The time from the start of the waveform to the beginning of the first transition. Pulse Delay must be a positive real number. Default is 0.

Thresholds - Determine the thresholds used by Rise Time and Fall Time.
Low Threshold = (first percentage) * (high - low)
High Threshold = (second percentage) * (high - low)

0%-100%

10%-90%

20%-80%

Rise Time - The time, in seconds, to make the transition from the low threshold to the high threshold. Rise Time must be a positive real number.

Fall Time - The time, in seconds, to make the transition from the high threshold to the low threshold. Fall Time must be a positive real number.

High - The value of the waveform when the pulse is active. High must be a real number. Default is 1.

Low - The value of the waveform when the pulse is not active. Low must be a real number. If the value of Low is greater then the value of High the pulse generated is inverted. Default is 0.

Burst Mode - Enables or disables multiple pulses being generated at the Frequency. When Burst Rate is OFF, only one pulse is generated at the Frequency. When Burst Mode is On, a Burst Count number of pulses is generated at the Frequency. Default is OFF.

Burst Count - The number of pulses generated at the Rep Rate. Burst Count must be a positive integer. Default is 2.

Burst Rep Rate - The rate at which the Burst Count pulses are generated. Burst Rep Rate must be a real number greater than 1/pulse width.

Time Span: - The duration of the waveform (in seconds). Default is 20m seconds.

Num Points: - The number of points in the waveform. The time between points in the waveform is Time Span/numPoints. Num Points must be positive. Default is 256.

Location

Device [image] Virtual Source [image] Pulse Generator

See Also

Build Arb Waveform, Build Waveform, Comparator, Function Generator, and Noise Generator.


Radio Buttons

See Selection Control.


Raise Error

Generates a user-defined error condition with associated error number (escape code) and text message. (This object was formerly called Escape.)

Use

Use Raise Error to stop execution of the current UserObject and generate an error that may be trapped by the error pin of an enclosing UserObject or the main work area. If the error is not trapped (by an error pin on a UserObject) and the escape code is non-zero, Raise Error stops the program and generates an error dialog box.

Raise Error may also be used in a UserFunction to generate an error trapped by an error pin on the object that called the UserFunction.

Open View Parameters

Code - An error number; it must be an Int32. VEE uses error numbers between 300 and 1,000; it is best to use error numbers exclusive of this range. You can enter the Code in the entry box or add it as a data input.

Message - The text message to output. You can enter the Message in the entry box or add it as a data input.

Notes

If VEE is invoked with the -r command line option, an untrapped error generated by Raise Error causes VEE to terminate. The Code and Message are written to stderr and 255 is returned to the operating system as the exit code.

To generate a specific exit code, use the Stop object.

Location

Flow [image] Raise Error

See Also

Error Output (Object Menu), Create UserObject, Exit UserObject, Exit Thread, Start, Stop, and Properties (Object)

To Trap an Error


Real32

An object that outputs a constant 4-byte real number.

Use

Use Real32 to set a real constant or to get user input. Click on the entry field to enter a value.

Example

To use Real32 as a prompt on a panel view, change the name of the Real32 object to a prompt such as Enter the offset:. The user fills in the requested information in the entry field.

Type in 100M*PI to have the Real32 Constant evaluate this formula and display the Real32 number answer.

Properties

DataShape - Sets the initial data shape of the value(s) to be output with this object.

 ArraySize - When 1D Array is selected, ArraySize sets the length of the array.

 ArraySizeFixed - When the property is True, the array cannot have lines added or deleted. This selection is only available if 1D Array is selected.

 ShowArrayIndices - When the property is True, each line in the entry field is indexed. This selection is only available if 1D Array is selected. Default is True.

Wait for Input - When the property is True, the object does not operate until the object's value is changed. When the property is False, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When the property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

InitialValue - Specifies the value to be set. Default value is 0.

 InitializeAtPreRun - When the property is True, the Initial Value is set at PreRun time. Default is False.

 InitializeAtActivate - When the property is True, the Initial Value is set at Activate time. Default is False.

Global Format - Use the default format. Default is True.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value(s). This input requires a real value, either a Scalar or an Array 1D. The Constant is reconfigured to match the shape of the incoming data.

The Reset input allows you to programmatically set the value(s) to zero. If the Constant is configured as an Array 1D, all values are set to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the value can be changed in the object’s open view.

Note that the InitialValue field is always a scalar, even if Real32 is configured to be an array.

Location

Data [image] Constant [image] Real32

See Also

Alloc Real32, Complex, Constant, Coord, Date/Time, Selection Control, UInt8, Int16, Int32, PComplex, Real64, Text, and Toggle Control.

To Use a Data Constant


Real64

An object that outputs a constant 8-byte real number.

Use

Use Real64 to set a real constant or to get user input. Click on the entry field to enter a value.

Example

To use Real64 as a prompt on a panel view, change the name of the Real64 object to a prompt such as Enter the offset:. The user fills in the requested information in the entry field.

Type in 100M*PI to have the Real64 Constant evaluate this formula and display the Real64 number answer.

Properties

DataShape - Sets the initial data shape of the value(s) to be output with this object.

 ArraySize: - When 1D Array is selected, Size sets the length of the array.

 ArraySizeFixed - When the property is True, the array cannot have lines added or deleted. This selection is only available if 1D Array is selected.

 ShowArrayIndices - When the property is True, each line in the entry field is indexed. This selection is only available if 1D Array is selected. Default is True.

Stepping Category: (disabled when Configuration is 1D Array)

EnableStepping - When the property is True, stepping controls appear at the right end of the entry field to let you scroll through values. Default is False.

DetentSize - When the EnableStepping property is True, this sets the size between values when using the stepping controls to scroll through values. Default is 1.

Wait for Input - When the property is True, the object does not operate until the object's value is changed. When the property is False, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When the property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

InitialValue - Specifies the value to be set. Default value is 0.

 InitializeAtPreRun - When the check box is selected, the InitialValue is set at PreRun time. Default is False.

 InitializeAtActivate - When the check box is selected, the InitialValue is set at Activate time. Default is False.

NumberFormat: Global Format - Use the default format. Default is on.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value(s). This input requires a real value, either a Scalar or an Array 1D. The Constant is reconfigured to match the shape of the incoming data.

The Reset input allows you to programmatically set the value(s) to zero. If the Constant is configured as an Array 1D, all values are set to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the value can be changed in the object’s open view.

Note that the InitialValue field is always a scalar, even if Real64 is configured to be an array.

Location

Data [image] Constant [image] Real64

See Also

Alloc Real64, Complex, Constant, Coord, Date/Time, Selection Control, UInt8, Int16, Int32, PComplex, Real32, Text, and Toggle Control.

To Use a Data Constant


Real64 Input

An object that displays a pop-up dialog box that accepts real number input.

Use

Use Real64 Input to prompt the user to enter a real number, accept the number, and check the number with a user-defined test for validity.

In the pop-up dialog box, when the OK button is pressed, the real number input by the user is output on the Value output pin. When the Cancel button is pressed, a 1 is output on the Cancel output pin.

Open View

  • Prompt/Label - The string that prompts the user to fill in the text field. You may add this parameter as a data input. Default is Enter Real Value:

  • Default Value - The text that is in the dialog's input field before anything is typed. If the user presses OK without typing anything, this text is output. You may add this parameter as a data input. Default is 5

  • Value Constraint - The equation that tests the input text for validity. You can use any mathematical expression or call a UserFunction. You may add this parameter as a data input. Default is 0<=value AND value<=10; which means it checks for user input of a value between 0 and 10. To accept any value, use the expression 1.

  • Error Message - The text that is output in a message box if the user input does not meet the Value Constraint. You may add this parameter as a data input. Default is You must enter a real number between 0 and 10.

Properties

  • PopupTimeoutEnabled - When this property is True, a Timeout output pin is added to the object. Default is False.

  • PopUpDuration - Sets the length of time the pop-up dialog box is displayed. After this period of time, the dialog box times out and a value of 1 is output on the Timeout output pin. No other outputs pins have data if the Timeout pin executes. This field is only available when the Timeout Enabled check box is selected. Default is 60 seconds.

  • PopupOKLabel - Sets the button label to OK if True. You may also use alternative wording if your users are not native English speakers. Regardless of the wording, the button's function remains the same.

  • PopupCancelLabel - Sets the button label to Cancel if True. You may also use alternative wording if your users are not native English speakers. Regardless of the wording, the button's function remains the same.

  • PopupPasswordMasking - When this property is True, the input text is echoed as asterisks (*). This feature is useful when the operator is entering sensitive data such as a password. The string that is output on the Value output pin is not masked. Default is False.

Notes

The default location of the pop-up dialog box is approximately at the center of the work area. If you move it, next time it will pop-up to the new location.

The title text of the error message dialog box is the same as the Real64 Input object title.

To respond to the pop-up dialog box using only the keyboard: when the dialog box pops up, start typing and use Enter and Esc keys. Use the Tab key to move between the input field and the buttons and then select the buttons with the Space bar.

The pop-up dialog box and the error dialog box are only displayed while the program is running. While the pop-up dialog box is displayed, the entire program pauses execution, then continues when the dialog box is closed.

Location

Data [image] Dialog Box [image] Real64 Input

See Also

File Name Selection, Int32 Input, List Box, Message Box, Text Input, and UserObject.

To Use a Data Input Dialog Box


Real64 Knob

An object that outputs the Real64 value of the knob.

Use

Use Real64 Knob to input values. Real64 Knob is particularly useful on a panel.

Open View Parameters

The open view displays fields for the knob's current value, minimum, and maximum values, and the knob control.

Properties

Orientation - Sets the orientation of how the Knob is displayed.

 ShowDigitalDisplay - If the property is True, the current value of the knob is displayed in an edit field at the bottom of the open view of the object. When you modify this value, the position of the knob changes. Default is True.

ShowTics - Controls visibility of scale’s tic marks and labels. Default is True.

 Logarithmic - When property is True, changes scale from linear to logarithmic. Default is False. When turned on, Detents changes to Steps/Decade.

 LabelSpacing: - Controls which tic marks are labeled with the scale values. Default is Every Other Tic.

 Detents or Steps/Decade: - On a linear scale, Detents sets the distance between the values that are available from the Knob. On a log scale, Steps/Decade sets the number of steps available within each decade from the Knob. If other values are entered, they are rounded to the nearest detent. Default for Detents (linear scale) is 1m. Default for Steps/Decade (logarithmic scale) is 1.0.

Wait for Input - When the property is True, the object does not operate until the object's value is changed. When the property is False, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When the property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

InitialValue - Specifies the value to be set. Default value is 0.

 InitializeAtPreRun - When the property is True, the Initial Value is set at PreRun time. Default is False.

 InitializeAtActivate - When the property is True, the Initial Value is set at Activate time. Default is False.

NumberFormat Category:

Global Format - Use the default format. Default is on.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, Disable Editing, MaxValue, MinValue, and Detents:

The Default Value input allows you to programmatically change the current value. This input requires a real scalar value.

The Reset input allows you to programmatically set the value to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the current, minimum, and maximum values can be changed in the open view.

The MaxValue and MinValue inputs allow you to programmatically set the min and max value fields. These inputs require a real scalar value.

The Detents input allows you to programmatically set the detent value.

Location

Data [image] Continuous [image] Real64 Knob

See Also

Complex, Selection Control, Int32, Int32 Slider, Int32 Knob, PComplex, Real64, Real64 Slider, Text, and Toggle Control.

To Use a Data Slider and Knob


Real64 Slider

An object that outputs the Real64 value of the slider.

Use

Use Real64 Slider to input values. Real64 Slider is particularly useful on a panel.

Open View Parameters

The open view displays a field for min, max, slider value, and slider control.

Properties

Orientation - Sets the orientation of how the Slider is displayed.

 ShowDigitalDisplay - If the property is True, the current value of the slider is displayed in an edit field at the top of the open view of the object. When you modify this value, the position of the slider control changes. Default is True.

ShowTics - Controls visibility of scale’s tic marks and labels. Default is True.

 Logarithmic - When this property is True, changes scale from linear to logarithmic. Default is False. When turned on, Detents changes to Steps/Decade.

 LabelSpacing: - Controls which tic marks are labeled with the scale values. Default is Every Other Tic.

 Detents or Steps/Decade: - On a linear scale, Detents sets the distance between the values that are available from the Slider. On a log scale, Steps/Decade sets the number of steps available within each decade from the Slider. If other values are entered, they are rounded to the nearest detent. Default for Detents (linear scale) is 1m. Default for Steps/Decade (logarithmic scale) is 1.0..

Wait for Input - When the property is True, the object does not operate until the object's value is changed. When the property is False, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When the property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

InitialValue - Specifies the value to be set. Default value is 0.

 InitializeAtPreRun - When the check box is selected, the InitialValue is set at PreRun time. Default is False.

 InitializeAtActivate - When the check box is selected, the InitialValue is set at Activate time. Default is False.

NumberFormat:

Global Format - Use the default format. Default is on.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, Disable Editing, MaxValue, MinValue, and Detents:

The Default Value input allows you to programmatically change the current value. This input requires a real scalar value.

The Reset input allows you to programmatically set the value to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the current, minimum, and maximum values can be changed in the open view.

The MaxValue and MinValue inputs allow you to programmatically set the min and max value fields. These inputs require a real scalar value.

The Detents input allows you to programmatically set the detent value.

Location

Data [image] Continuous [image] Real64 Slider

See Also

Complex, Selection Control, Int32, Int32 Knob, Int32 Slider, PComplex, Real64, Real64 Knob, Text, and Toggle Control.

To Use a Data Slider and Knob


Record Constant

An object that outputs a constant of the Record data type.

Use

Use the Record Constant object to define and build a Record constant, or to interactively edit an existing record or array of records.

Open View Parameters

In the open view there is a Field name button and a Value button (or type-in field) for every field in the record. (By default, the Field name buttons A and B correspond to the Value fields "Text field" and "1.25", respectively.) If the record is an Array 1D (that is, Array Elements is non-zero), there is an additional field in the open view for the index into the array (0, 1, etc.) To step through the array values, First, Prev, Next, and Last buttons are provided.

Field name -- A button that, when pressed, pops up a dialog box that allows the user to re-name the record field, and change its type and shape. An error will occur if you attempt to rename a field to an existing field name. Field names are not case sensitive (lowercase and uppercase letters are equivalent). When changing the data type, VEE will attempt to coerce the data into the new data type, subject to the existing rules about data type coercion.

Value -- Allows you to edit the values in the field. If the field is a scalar container of a data type other than Enum, Value is a type-in field. That is, you can click on the field and type in the desired value. If the field is an Enum or Array 1D container, the Value field is a button, which brings up a dialog box to allow you to select the values. If the field is an array of two or more dimensions, the values may not be edited.

Object Menu

Add Record -- Adds a record at the end of the record array. The new record is a copy of the last record in the array. (This menu selection is not active for record scalars.)

Insert Record -- Inserts a record at the position in the record array that you are currently viewing. The new record is a copy of the record that you were viewing. (This menu selection is not active for record scalars.)

Delete Record -- Deletes the record that you are currently viewing from the array. (This menu selection is not active for record scalars. Also, for record arrays, the selection is active only if there is more than one record in the array.)

Add Field -- Adds a new field to the record at the end of the field list. A dialog box will allow you to define the name, type, and shape of the new field.

Insert Field -- Inserts a new field to the record at a specified position. A dialog box allows you to define the name, type, and dimension of the new field. A second dialog box allows you to specify the insertion point.

Delete Field -- Allows you to delete record fields. A dialog box will list the available fields to delete. This selection is available only if the record has more than one field.

Properties

DataShape - Sets the initial data shape of the value(s) to be output with this object.

 ArraySize: - When 1D Array is selected, Size sets the length of the array.

 ArraySizeFixed - When the property is True, the array cannot have lines added or deleted. This selection is only available if 1D Array is selected.

 Schema Fixed - When the property is True, the format ("schema") of the record is fixed, and may not be modified. This is useful when allowing users to modify Record values interactively on a pop-up panel.

NumberFormats:

Global Format - Use the default format. Default is on.

Integer: - If Global Format is off, specify the number format for integer numbers to be displayed on this object. The choices are Decimal (e.g. 42), Octal (e.g. #Q52), Hexadecimal (e.g. #H2a), and Binary (e.g. #B00101010). Default is Decimal.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

Notes

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value(s). This input requires a Record value, either a Scalar or an Array 1D. The Constant is reconfigured to match the shape of the incoming data.

The Reset input allows you to programmatically set the value(s) to zero. If the Constant is configured as an Array 1D, all values are set to zero. (Numeric fields become zero and Text fields become null strings.) The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the value can be changed in the object’s open view.

The Default Value pin is useful for editing large record arrays (for example, a record array "pulled in" with the From DataSet object). Just send the record array into the Default Value pin to set the initial value for the Record Constant. You can then view and interactively edit the entire record. The data values may be changed, and also the type, shape, and mappings of the fields may be changed (unless the field is itself a record). Once you have edited the record, it can be output to a new dataset or file (using To DataSet or To File). The Record Constant object does not allow you to edit a field that is itself a record -- it will only allow you to view the field and its data.

Note that the Record Constant object does not allow you to create a record of records. That is, the Record Constant does not allow you to add a field that is a record. However, all other VEE record devices (such as Build Record and Set Field) do allow this. Recursion is allowed up to the limit of available user memory. That is, a record may have a field that is a record, which has a record field within it, and so forth. The shape of a record container may only be either a scalar or a one-dimensional array.

Location

Data [image] Constant [image] Record

See Also

Build Record, From DataSet, Merge Record, Set Field, To DataSet, and UnBuild Record.

To Create a Record Constant


Remote Functions

A Remote Function is a UserFunction that runs in another VEE process on a remote host computer. Remote Functions are a special case of UserFunction.

Use

The Remote Function is called from the local VEE process over the LAN. Just as for UserFunctions and Compiled Functions, import a library of Remote Functions with the Import Library object. When one or more Remote Functions have been imported, they are called by using the Call object or by including function names in expressions. You include Remote Function calls in your program just as you would UserFunctions. However, some differences and some networking technicalities are described in this section.

Create a library of Remote Functions just as you would a library of UserFunctions, but save it on the intended remote host computer. The intended remote host computer must also have VEE Pro or VEE Pro Run Time installed on it. The library of Remote Functions is imported not into the local VEE process but in a special invocation of VEE called a "service" that runs on the remote host. The local VEE process is called the "client." The client VEE process imports the Remote Function library using the Import Library object. When you select Remote Function for the Library Type field, some new fields appear as in the following graphic.

The Library Type and Library Name fields function the same as for UserFunctions and Compiled Functions. The other fields are as follows:

Remote Host Name - The name of the host on which the "service" VEE process is to run (the "remote host"). This name can be the common or symbolic name of the host (for example myhost) or the IP address of the host in this field (for example 14.13.29.99).

Remote File Name - The name of the Remote Function library file. The Remote File Name is analogous to the File Name field for a UserFunction library. However, you must specify the absolute path to the file. Hence the path and file name can be rather long. You may want to have all users place remote function library files in a common place, such as: C:\USERS\REMFUNC.

Remote Timeout - A timeout period in seconds for communication with the VEE service. If the VEE service has not returned the expected results of a Remote Function within this time period, an error occurs.

Remote Debug - When this check box is selected, all UserFunctions within the library execute in debug mode (i.e., you will be able to perform debugging on them, such as setting breakpoints and doing line probes). This setting works with UserFunctions whether or not they have panel views.

When the Import Library object is executed (either by selecting Load Lib from the object menu or during normal program execution), a VEE server process is started on the remote host specified in the Host Name field. The client process and the server process are connected over the network and are able to communicate.

When a Call object in the client VEE calls a Remote Function, the arguments (the data input pins on the Call object) are sent over the network to the remote service, the Remote Function is executed, and the results are sent back to the Call object and output on its data output pins.

If your program deletes the library of Remote Functions with the Delete Library object, the Remote Functions associated with the library are removed. You can load multiple libraries in a VEE server process, then delete each one as needed without canceling the service connection. The VEE server exists while the VEE client process continues to run.

Prerequisite

Remote Functions requires the VEE Service Manager to be running on the remote host system. Start it manually as follows:

  1. Go to the VEE installation directory

  2. Execute veesm.exe

  3. When the console window appears, you can minimize it to get it out of the way

  4. To stop the VEE Service Manager process, open the console window and press CTRL+C.

Notes

The VEE service process executes only Remote Functions that are contained in the Remote Function library named by Import Library.

Remote Functions have views associated with them. When you call a remote function, you can have a VEE window appear on the remote host if the UserFunction displays a panel view.

Global variables (declared and undeclared) are not shared between the processes.

Remote Functions do not time-slice when called.

Parameters of type object cannot be passed to or from a Remote Function (includes ActiveX Automation objects or pointers to ActiveX controls).

The Execution Mode used by the service VEE process is that of the user’s .veerc file, not that saved in the file that is imported.

Embedded .veeio file configurations in the file imported by the service VEE process are ignored. Only the global I/O configuration file is used.

See Also

Service Manager and UserFunction


Repeat

A menu item.

Use

Use Repeat to access the following iterators and iteration-control objects:

For Count

For Range

For Log Range

Until Break

On Cycle

Next

Break

Notes

You can nest iterators.

Execution of the subthread hosted by the iterator continues until one of the following occurs:

All objects that can, have operated. The subthread iterations have been completed.

A Break object operated. The subthread is deactivated and the sequence output pin is activated.

A Next object operated. The subthread is deactivated and the iteration counter is incremented.

When the iteration subthread has completed, the sequence output pin is activated.

Location

Flow [image] Repeat

See Also

Break, For Count, For Range, For Log Range, Next, On Cycle, and Until Break.

To Loop Part of a VEE Program


Replace

Replaces this object and its connections with another object.

Use

Use Replace to replace an object while retaining the connections.

Replace puts a copy of the object that is replaced in the Paste buffer.

Notes

Each Replace overwrites the previous content of the Paste buffer with the original object.

Pins are connected from top to bottom. If there were more lines connected to the original object than there are pins on the new object, the extra lines are deleted. If there were fewer lines connected to the original object than pins on the new object, the bottommost pins on the new object are left unconnected.

Replace works only within a single context. For example, to Replace an object in a UserObject, first place the replacement object in the UserObject context.

Replace is not available unless an object is connected to one or more objects.

Location

On each object menu [image] Replace

See Also

Object Menu, Cut (Object Menu), Copy, and Paste.


Restore (Object Menu)

Restores the object to its open view.

Use

Use Restore to show the open view of an object.

Notes

Restore is available from the icon view of all objects.

From a maximized UserObject, Restore will resize the open view to its non-maximized size.

Short Cuts

To restore an object, double-click on the icon.

Location

On the object menu [image] Restore

See Also

Minimize (Object Menu).


Run/Resume

Causes all suspended threads to continue running after the program has been paused.

Use

Use Run/Resume to resume program execution after the program has been paused. The program pauses if the Pause button is pressed, if a breakpoint is reached, or if a Step function is used.

Run/Resume is primarily used to continue execution between breakpoints and is usually used in conjunction with the other debugging tools.

Notes

The Run/Resume button on the toolbar is the same as the Run button. Run/Resume is not available if Stop has been pressed.

Short Cuts

Pressing the CTRL + G keys or the F5 function key will activate Run/Resume.

Location

Debug [image] Run/Resume

See Also

Pause, Run, Start, Step Into, Step Over, Step Out, Stop, and Toggle Breakpoint.

To Step through a Program


Run

Starts the execution of all threads in a program.

Use

Use Run to begin the program execution. If Start objects are used on threads in the main work area, execution begins with those objects.

When you select Run, VEE PreRuns all threads to clear data and check for feedback. If Execution Mode in Default Preferences is set to VEE 4 or higher, VEE predicts the order of execution of objects, determines what data types are flowing on certain lines, and generates a compiled code for each object.

Notes

If you have several threads in your program and want to run only one of them, connect a Start object to that thread. Press the Start object on the thread you want to run.

Short Cuts

Press CTRL+G or F5 to run the program.

Location

Debug [image] Run

See Also

Pause, Run/Resume, Start, Step Into, Step Over, Step Out, and Stop.

To Start a VEE Program


Sample & Hold

An object that stores the most recently received data container. Activating the XEQ pin outputs the stored container.

Use

Use Sample & Hold to capture the last data present on the input pin when XEQ is activated.

Example

Use Sample & Hold to preserve data generated by objects in subsequent thread segments of either If/Then/Else or Conditional flow objects that are also in an iteration sub-thread.

Notes

The Sample & Hold is generally not needed unless both iteration and flow branching are present in a thread. Objects will normally retain the most recently received data container on their input pin(s) by default.

Only the most recent data container arriving at the InData input will be saved by the Sample & Hold. As new data arrives, it over-writes the existing data.

If the Sequence In pin is connected, both the InData input and the Sequence In pin must be activated before a data container will be accepted to replace the existing stored data.

The Sample & Hold operates when the XEQ pin is activated. Propagation will proceed as far as possible before the Sequence Out pin is activated.

The contents of the Sample & Hold are cleared by PreRun and Activate. If XEQ is activated with no stored data, an error will be generated.

Because XEQ is required on the Sample & Hold, you cannot delete it or add another XEQ pin.

Multiple XEQ activations each re-send the most recent stored data if no new data has arrived.

Location

Flow [image] Sample & Hold

See Also

Repeat, If/Then/Else, Conditional, UserObject, and Properties (Object)


Save

Copies the program in the work area to a previously specified filename.

Use

Use Save periodically to write your program to a file.

Caution

A file saved in Agilent VEE Pro 7.0 format cannot be retrieved into earlier versions of VEE.

Notes

Save writes your program to the file name specified in Save As or Open. If a program was created from a New work area and no Save As was done, Save prompts you for a file name. As the program is being written, the pointer changes to a pencil.

VEE allows you to save colors and fonts (as defined by Default Preferences) in your program file. A Save colors and fonts with program check box has been added to the Save File Dialog Box.

VEE allows you to embed I/O configuration information in the program itself. To enable embedding of the configuration information, a Save I/O configuration with program check box has been added to the Save File Dialog Box. See Instrument Manager for more information on saving an I/O configuration.

Save does not ask for confirmation when overwriting a file.

Saving a file may affect its compatibility. For example, a version 5 file that is retrieved into version 6 and saved is no longer compatible with version 5.

Short Cuts

Press CTRL+S to save a program.

Location

File [image] Save

See Also

Merge, Open, Save As, and Save Objects.


Save As

Copies the program in the work area to a specific file.

Use

Use Save As to specify a file name for your program and write the program to that file.

Select Save colors and fonts with program to save all the default colors and fonts in the program file that are selected in the Default Preferences dialog box. This ensures that whoever opens your program will also get all of your default colors and fonts. If this option is not selected, only the colors and fonts explicitly set in your program are saved in your program file. This allows others using your program to retain their own default colors and fonts. If an existing program is loaded, the option is set according to how the program was saved previously.

Save As enables Save I/O configuration with program by default. You can un-check this selection if you do not want the embedded I/O configuration. VEE allows you to embed I/O configuration information in the program itself. See Instrument Manager for more information on saving an I/O configuration.

Caution

A file saved in Agilent VEE Pro 7.0 format cannot be retrieved into earlier versions of VEE.

Notes

If you attempt to overwrite an existing file, you are asked to confirm that action. As the program is being written, the pointer changes to a pencil.

The file name specified in Save As becomes the name used in subsequent Save operations.

The current file is saved as filename.bak; the new saved version is just filename. Note that if the filename already includes an extension (such as .vee) that extension is replaced with .bak.

VEE allows you to embed I/O configuration information in the program itself, rather than using the veeio resource file. To enable embedding of the configuration information, a Save I/O configuration with program check box has been added to the Save File Dialog Box. See Instrument Manager for more information on saving an I/O configuration.

Saving a file may affect its compatibility. For example, a version 5 file that is retrieved into version 6 and saved is no longer compatible with version 5.

Short Cuts

Press CTRL+W to Save As.

Location

File [image] Save As

See Also

Default Preferences, Merge, Open, Save, and Save Objects.


Save Documentation

Creates a text file containing a description of the current program.

Use

Use Save Documentation to get a listing of your program for documentation purposes. The output file from Save Documentation includes the following information:

Source file name.

Documentation date.

Current version number of VEE.

Save file version.

System preferences (except colors and fonts).

Object names and types.

Open view information on objects (such as a Constant value or transactions).

Object description text entered from Description.

Notes

Save Documentation replaces the veedoc utility which existed in prior revisions of VEE.

Do, Junction, and Gate objects are not included in the Save Documentation file unless they have description text entered from Description.

The numbers assigned to each object in the Save Documentation file correspond to the numbers printed next to the object when Print All is used.

Because constant data is printed on a single line, arrays and records are not printed so that the file can be read by commonly-used word processors.

Save Documentation does not save color and font information or I/O configuration.

Location

File [image] Save Documentation

See Also

Default Preferences, Print Program, Save, and Save As.

To Document Your Program


Save Objects

Copies the selected objects to a specific file.

Use

Use Save Objects to specify a file name for a set of objects and write the objects to that file. Save Objects is generally used to save a group of objects into a library of common functions that is included in other programs.

Notes

Use Save Objects to copy a set of objects from your program that you use in other programs. Save Objects allows you to build up a library of your own functions. As the objects are being written, the pointer changes to a pencil.

If you attempt to overwrite an existing file, you are asked to confirm that action.

Save Objects does not save color and font information or I/O configuration.

Location

File [image] Save Objects

See Also

Merge, Open, Save, and Select All.

To Create a Library of UserObjects

To Secure a UserObject


Send to Back (Object Menu)

Send to Back

Send an Object to the back of the viewable plane.

Use

An object menu choice on Panel, Send to Back places an object in the background of the viewable plane, changing the z-order of the object.

See Also

Bring to Front (Object Menu)


Select All

Selects all objects in the front window to be acted on.

Use

Before you use the object features in the Edit menu, you must select an object or a set of objects to be acted on. Choosing Select All will select all of the objects in the front or active window. When an object is selected, it has a shadow highlight. To select more than one object, but not all objects, press and hold CTRL while selecting the objects with the left mouse button. After the objects are selected , choose an editing function such as Cut or Copy.

Notes

Any objects previously selected are deselected when Select All is used.

If you select objects by mistake, deselect all objects by clicking on the work area. Or press the CTRL key while clicking on the unwanted objects to deselect them.

Only objects in the same VEE context (UserObject, UserFunction, etc) can be selected together.

Short Cuts

Press CTRL key while clicking the left mouse button on objects. Or press the CTRL key while dragging (with the left mouse button down) to rubberband select objects.

These shortcuts allow you to toggle the selection of objects. These methods do not deselect all previously selected objects before selecting other objects (as Select All does).

Pressing CTRL + A will select all objects in the active detail view/panel view.

Clicking the left button on an object selects it, however it also deselects any objects already selected.

Location

Edit [image] Select All

See Also

Add To Panel, Align, Copy, Create UserObject, Create UserFunction, Cut, Print Objects, Replace, Paste, and Save Objects.


Selection Control

Object that outputs an enumerated value from a user-defined list. Selection Control objects have a variety of display formats, but they all work the same way.

Use

Use Selection Control objects to set an enumerated constant or to get user input that is chosen from a list of acceptable choices. The first item in the list is assigned ordinal position 0; the nth item in the list is assigned ordinal position n-1.

Object Menu

Edit Enum Values - Allows you to add valid selections to the enumerated list of choices or edit existing choices. Add a choice, and then press the Tab key to move to the next entry in the list. You can move back up in the list by pressing Shift+Tab.

Properties

Format property: - Specifies the appearance of the Selection Control object and the method of selecting a choice. The default format is whichever object you chose from the menu.

Radio Buttons - The choices are all displayed. The selection is made when the radio button next to the choice is pressed.

Cyclic Button - The choices cycle as the button field is clicked on. This choice is best used if there are two choices such as On/Off or Stop/Go or in a dialog box where the choice is confirmed by another button.

List - The choices are presented in a list box with scroll bar if all choices can't be shown at once The selection is made when the choice is clicked on.

Drop-Down List - The choices are presented in a list box that drops down when the arrow to the right of the field is pressed. The selection is made when the choice is clicked on.

Pop-Up List - The enumerated choices are presented in a list box in a dialog box that is displayed when the button field is pressed. The selection is made when the choice is clicked on and OK is pressed.

Slider List - The enumerated choices are presented as tic labels on a slider. The selection is made when the slider button or the label is clicked on.

Execution group:

Wait for Input - When the check box is selected, the object does not operate until the object's value is changed. When the check box is not selected, the object operates as soon as any constraints are met, and the currently selected value is output. Default is off.

Auto Execute - When the check box is selected, the object operates and starts the rest of the program when a value is selected. If the program is already running, Auto Execute is ignored. Default is off.

FormatSliderLayout property:

Horizontal | Vertical - Sets the orientation of how the slider is displayed. These are only valid when Format is set to slider list.

Initialization category:

Initial Value - Specifies the value to be set. Default value is the first selection from the list.

Initialize At PreRun - When the check box is selected, the Initial Value is set at PreRun time. Default is off.

Initialize At Activate - When the check box is selected, the Initial Value is set at Activate time. Default is off.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting an initial value is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, Disable Editing, and Enum Values:

The Default Value input allows you to programmatically change the current value. This input requires a Text Scalar value (or any data that can be converted to a Text Scalar, including an Enum). This value must match one of the possible Enum values (case sensitive).

The Reset input allows you to programmatically set the current value to the first (0 ordinal) value in the list. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the values can be changed in the object’s open view.

The Enum Values input allows you to programmatically set the list of possible values for the Selection Control. This input requires Enum, a Text Array 1D, or any data that can be converted to a Text Array.

Enum containers are automatically converted into Text for many objects, including Collector, Concatenator, Sliding Collector, and most Formula objects.

To get the selected value’s ordinal value, connect a line to the Ordinal output rather than the selected string, or use ordinal().

Example

To use a Selection Control as a prompt on a user panel, change the name of the object to a prompt such as "Choose the type of test:".

Location

Data [image] Selection Control

See Also

Complex, Constant, Coord, Date/Time, UInt8, Int16, Int32, PComplex, Real32, Real64, Text, Toggle Control, and List Box.

ordinal(x).

To Use a Data-Selection Object


Sequencer

An object that executes a series of sequence transactions, each of which may call a UserFunction, Compiled Function, or Remote Function.

Use

Use the Sequencer to control the order of calling of a series of UserFunctions, Compiled Functions, Remote Functions or any other VEE function by specifying a series of sequence transactions. Typically, the Sequencer is used to perform a series of tests.

The Sequencer contains a list of sequence transactions. Each of these transactions evaluates a VEE expression, which may contain a call to a UserFunction, Compiled Function, or Remote Function. After evaluating the VEE expression, a transaction compares the value returned by that expression against a test specification. Depending on whether the test passes or fails, the transaction then evaluates different expressions and selects the next transaction to be executed. Transactions may optionally log their results to the Log output pin, or to a UserFunction, Compiled Function, or Remote Function specified on the Logging categories of the Properties window.

The Return output pin of the Sequencer can be used for returning a result when the sequence has completed. By default the Return output pin has a value of zero, but a transaction with a Next Operation of Then Return will set the Return output pin to the specified value.

The Log output pin of the sequencer contains a record that contains one logging record for each transaction that has logging enabled. See "Properties" below under "Logging tab" for more information.

Open View Parameters

The open view shows the list of transactions to be executed.

Dialog Information

You can change the parameters for an individual transaction. Just double-click on a transaction to display the Sequence Transaction dialog box for that transaction. The available parameters are as follows:

Sequence Mode:

TEST - Executes the specified expression and tests the result against a specification. (If the expression calls a UserFunction, a compiled function or Remote Function, the result on the top-most output pin of the corresponding UserObject is used.)

EXEC - Executes the specified expression without performing a pass/fail test against a specification. Logging is never performed on EXEC transactions.

Transaction Name - Unique name of this transaction, and cannot be the same as any UserFunction. Must be a valid VEE variable name (must begin with a letter, but may include letters and numbers). This name can be referenced by expressions in this or other transactions, and will contain the logging record for the most recent execution of this transaction.

Enable Condition Type:

ENABLED - Sequencer unconditionally executes this transaction.

DISABLED - Sequencer never executes this transaction.

ENABLED IF: - Sequencer executes this transaction only if the given expression is non-zero.

DISABLED IF: - Sequencer does not execute this transaction if the given expression is non-zero.

SPEC NOMINAL: - Nominal (expected) value of the test result. This value is not used in calculating RANGE or LIMIT specification tests, but may be included in the logging record.

Spec Type - All specification tests are done in the same manner as the Comparator object. Thus, the test result may be a waveform, and the test limit(s) may be another waveform or an array of type Coord. The spec test will automatically perform the necessary interpolation to determine if each data point is in or out of specification. Also, all tests use an "almost equal" algorithm that checks equality or inequality to at least six significant digits. See the Comparator object description for more information. Options include:

RANGE: - Specifies a lower and upper limit and the comparison operators that apply.

LIMIT: - Specifies a single limit and the comparison operator that applies. May be used to test for an upper or lower limit, or for an exact match. The limit value will be logged in the HighLimit record field.

TOLERANCE: - Specifies a plus and minus tolerance from the Nominal value. A tolerance of zero is permitted. HighLimit and LowLimit logging record fields contain the specification range after the tolerance has been applied to the Nominal value.

%TOLERANCE: - Specifies a plus and minus percent tolerance of and from the Nominal value. A tolerance of zero is permitted. HighLimit and LowLimit logging record fields contain the specification range after the tolerance has been applied to the Nominal value.

FUNCTION - A VEE expression that specifies the test. The expression may just be a call to a UserFunction, Compiled Function, or Remote Function. Or it may be a larger expression of input pin names, UserFunctions, Compiled Functions, Remote Functions, variables, and test records from previous transactions in this Sequencer. If this is a test transaction, the single result from this field will be tested against the specification. The result of a UserFunction or Remote Function call is the value of the top-most output pin of the corresponding UserObject, or nil if no output pins are present.

Logging Mode:

LOGGING ENABLED - Add a field for this transaction to the Log record output pin (if present). If a "Log Each Transaction To:" procedure has been specified on the Logging tab in the Properties window, that logging procedure will be called immediately after this transaction is completed.

LOGGING DISABLED - A log record will not be generated for this transaction, and the "Log Each Transaction To:" procedure will not be called. (See "Logging tab" under "Properties" below for options and more information.)

Pass Operation:

IF PASS - If the spec test passes (test value within limits), the specified "then" action will be performed.

IF PASS CALL: - If the spec test passes (test value within limits), the specified VEE expression -- which may include a call to a UserFunction, Compiled Function, or Remote Function -- will be evaluated and the specified "then" action will be performed. (The return value from IF PASS CALL is ignored.)

Fail Operation:

IF FAIL - If the spec test fails (test value outside of limits), the specified "then" action will be performed.

IF FAIL CALL: - If the spec test fails (test value outside of limits), the specified VEE expression -- which may include a call to a UserFunction, Compiled Function, or Remote Function -- will be evaluated and the specified "then" action will be performed.

Next Operation: (Applies to EXEC transactions, or to either "Pass" or "Fail" operations in TEST transactions.)

THEN CONTINUE - Goes to the next transaction in the Sequencer list. (This is the default operation.)

THEN RETURN - Quits executing transactions in this Sequencer and places the value of the specified expression (which can call a function) on the Return output pin of the Sequencer. The Sequencer object will then fire its output pins and execution flow within the program will continue normally.

THEN GOTO - Goes to the transaction in this Sequencer with the specified transaction name.

THEN REPEAT - Executes this transaction again, repeating up to the specified number of times. If the Pass/Fail condition still exists after the maximum number of repeats, continues to the next transaction.

THEN ERROR - Stops execution of the Sequencer by generating an error condition with the given error number. An error can be trapped with an Error output pin on this Sequencer, or on any enclosing UserObject.

THEN EVALUATE - Evaluates the given expression -- which may call a UserFunction, Compiled Function, or Remote Function -- and uses the string result to determine the next operation. Valid string results from the expression are:

CONTINUE
RETURN <expr>
GOTO <name>
REPEAT <expr>
ERROR <expr>

Where <expr> is any valid VEE expression and <name> is the name of a transaction in this Sequencer. This operation can be useful when a UserFunction, possibly with user interaction, needs to determine what action the Sequencer should perform next.

DESCRIPTION - "Comment" field for this transaction. Text entered into this field will be shown at the end of the transaction's abbreviated text in the Sequencer open view.

Object Menu

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Print Trans - Prints the detailed dialog box that describes the currently highlighted transaction.

Properties

LogRecordField: Selects which fields will be generated in the logging record for each transaction. (The Log output pin contains a record of records -- one logging record for each transaction with logging enabled. In each transaction logging record the selected fields, specified below, may be present.) The names (without spaces) are the field names of the logging record. The choices are:

 LogName - A unique string that identifies this transaction (not the procedure name).

 LogResult - The value returned from the evaluation of the test procedure.

 LogNominal - The nominal test value.

 LogHighLimit - The upper limit used in the specification test. Actual limit values, not offsets are given for Tolerance and %Tolerance specifications.

 LogLowLimit - Lower limit used in specification test. Actual limit values, not offsets, are given for Tolerance and %Tolerance specifications.

 LogPassed - An Int32 with value "1" for "Pass", "0" for "Fail".

 LogTimeStamp – A real value containing day, date, and time of completion of the test.

 LogDescription - A Text value containing the description "comment" field in the Transaction.

LoggingControl Category:

LogToOutputOnly - A logging record will be present in the record on the Log output pin for each transaction that has Logging Enabled. If a transaction is executed more than once during one execution of the Sequencer, only the last logging record for that transaction will be present in the record on the Log output pin. If a transaction has not been executed during an execution of the Sequencer, the logging record for that transaction will contain "0" (Real64) values for each field except the Name and Description fields, which contain null strings, and Pass which contains an Int32.

LogToFunction - Specify a UserFunction, Compiled Function, or Remote Function expression that will be called after each transaction that has Logging Enabled. To pass the logging record for the current transaction to the UserFunction, Compiled Function, or Remote Function, use the reserved variable name "ThisTest". The Log output pin will continue to operate in the same manner as for the "LogToOutputOnly" mode.

Notes

You can add an ExecTrans data input pin. The ExecTrans data input executes only the transaction(s) with the specified name(s) in the order given by a Text scalar or 1D array on the data input. The highlight bar will be moved to the transaction currently being executed. The If Pass or If Fail expressions will be evaluated as usual, but the result of the Then field will have no effect on the next transaction to be executed.

All field expressions (such as ENABLED IF, FUNCTION, or spec limits) may contain input pin names, UserFunction calls, Compiled Function calls, Remote Function calls, VEE math functions, or record names of previously run transactions. In test transactions with LOGGING ENABLED, the reserved variable, thisTest will contain a record of the logging fields that have been calculated. For example, to use the test value from transaction test4, which had logging enabled, use the name test4.result in any expression. Or to use the current test name in any expression, use thisTest.name. Or, an Enabled If expression might be random()<0.25 to cause the test to be executed only 25 percent of the time.

Short Cuts

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Location

Device [image] Sequencer

See Also

Build Record, Call, Comparator, Formula, Raise Error, UnBuild Record, and UserObject.


Service Manager

The Service Manager is a prerequisite for the use of Remote Functions. It manages communications between the "service" that runs on the remote host computer and the "client" that runs on the local host computer. You must start it on the remote host system prior to initiating the use of remote functions.

See Also

Remote Functions


Set Field

An object that allows you to modify a field of an existing record.

Set Field is obsolete and cannot be added to new programs, though it is still supported on older programs that already contain the object. Use the Assignment Formula object as a substitute. It is located on the Function & Object Browser under Type: Operators; Category: Assignment.

Use

Set Field as used to modify the value of a field of an existing record. The Set Field object is actually a Formula object that assigns the value specified by the right-hand expression to the field specified by the left-hand expression. The value in the right hand expression can evaluate to a scalar, an array, another record, or a field in a record.

Set Field is a short-cut for un-building a record, changing one field, and re-building the data into a record. Note that there are two output terminals, Result and Rec. Result outputs only the field referenced in the object. Rec outputs the entire record. Also, the left and right-hand expression results must match in type and shape. You cannot use Set Field to change the "schema" (type and shape) of the input record.

Open View Parameters

Expression input field -- This input field allows you to change an element of a record directly. The left-hand expression allows a subset of Formula mathematical syntax, which allows you to specify a field of a record. The A.B dot syntax, as well as a subset of the A[2] sub-array syntax, is supported to specify a particular field of the record to be changed. See "Notes" below for further details of the allowed syntax. The right-hand expression allows any mathematical expression that is allowed in a Formula object. This expression has access to all input containers, variables, and functions. The right-hand expression is evaluated and the resulting value is stored in the field of the record specified by the left-hand expression.

Notes

The name of the record output pin must match the name of the input record to be modified, and the left-hand expression must begin with that name. For example, if the record pins are named Rec, the left-hand expression must be something like Rec.A or Rec[1]. The left-hand expression must be a single expression that specifies which field of the input container is to be modified.

There may be confusion over the names of inputs, outputs, and record fields. For example, if the name of the record input pin and the record output pin is Rec (they must match), the expression Rec.A specifies the A field in the input record. On the other hand, the expression A*2 refers to the A data input of the Set Field object. Thus, Rec.B=A*2 sets the B field of the output record equal to twice the value of the A data input. On the other hand, Rec.B=Rec.A sets the B field of the output record equal to the value of the A field of the input record.

The complete input record container is output on the record output pin, but the specified field is modified. For example, suppose the input Rec is a record with two fields x and y, where x is a Text scalar with value "hello" and y is a Real64 scalar with the value 1.2. If the left-hand expression specifies Rec.y, and the right-hand expression evaluates to 5.6, the Rec output container will be a record with two fields x and y, where x is a Text scalar with value "hello" and y is a Real64 scalar with the value 5.6. The Result output will contain only the y field, in this case a Real64 scalar with a value of 5.6.

The field specified by the left-hand expression and the result of the right-hand expression must match in type and shape ("schema"). That is, the operation of the Set Field object cannot change the schema of the input record -- only the data in the specified field can be changed. For example, suppose input Rec is a record with two fields x (a Text scalar) and y (a Real64 scalar). If the left-hand expression specifies Rec.y, the right-hand expression must result in either a Real64 scalar, or something that can promote to a Real64 scalar. Otherwise, an error will result.

Record arrays require special attention. A record array is an array consisting of individual record elements, each consisting of fields. You can use Set Field to change one field of one element in a record array. For example, if you create a record 1D array and you want to change the f field of the third record element of the array, specify Rec[2].f (for a zero-based array) in the left-hand expression. In this case, the result of the right-hand expression is placed in the f field of the third element of the record 1D array. None of the other fields of Rec[2] are changed, nor are any fields of the other record elements of the array (for example, Rec[0].f and Rec[1].f).

On the other hand, you can use Set Field to modify a particular field in every record element of a record array. For example, suppose you specify Rec.f in the left-hand expression where Rec is a record 1D array with n elements. In this case, the result of the right-hand expression is copied into every Rec[x].f field, where x is from 0 through n-1. In other words, the f field is changed in every record element of the array.

The left-hand expression must be a single expression specifying which part of the input record is to be modified. For example, Rec+2 and sine(Rec) are not valid as left-hand expressions. Also variables are not allowed in the left-hand expression.

The syntax allowed for the left-hand expression is limited:

The A.B dot sub-record syntax may be used any number of times for record of record containers (there is no limit on recursion). Suppose that record A has a field b, which is itself a record. The record field b has a field c, which is a record containing field d. To specify that lowest level field d, you can use A.b.c.d as the left-hand expression.

The A[x] sub-array syntax is more limited, and may be used only once, before the last dot. For example, A.b.c[1].d is valid as a left-hand expression, but A[2].b.c.d and A[2].b[2].c are not allowed. Also, A[1] and A.b.c[1:2] are not allowed. However, the A[x] sub-array syntax, supported before the last dot, does support the "colon and asterisk" syntax. For example A[1:2].b and a.b.c[2:*].d are valid left-hand expressions.

Note the difference between A[1].b and A.b[1]. The first is a record 1D with a field b. The second is a scalar record containing a field b, which is a 1D array.

Location

Data [image] Access Record [image] Set Field

Set Field is obsolete. This menu item gets the Assignment Formula object.

See Also

Assignment, Build Record, Formula, Get Field, Record Constant, SubRecord, and UnBuild Record.

Using Assignment Operations

To Change a Field in a Record


Set Mappings

An object that assigns mapping to an array.

Use

Use Set Mappings to map one or more dimensions of an array linearly or logarithmically over a range of real values.

Open View Parameters

Num Dimensions - The number of dimensions in the input array. Num Dimensions must be an integer. Minimum is 1. Maximum is 10. Default is 1. Changing the value of Num Dimensions changes the number of rows available to set the parameters for Mapping, From, and To - one row per dimension.

Mapping - Linear or Log for each dimension. Default is Linear.

From - The lower limit of the mapping range (inclusive) for each dimension.

To - The upper limit of the mapping range (inclusive) for each dimension.

From and To may be added as data inputs.

Notes

If a Waveform or Spectrum is input, its elements are remapped to your specifications. Log mapping is not allowed on a Waveform.

There are the same number of points as sampling intervals. Each point is at the beginning of the sampling interval.

Set Mappings does not allow an array of Coord as input because the Coord array is already explicitly mapped.

The mappings on arrays are used in the XY displays for Autoscale and various math functions.

The From and To values must be different.

The value of the Num Dimensions field must match the number of dimensions of the input array.

Location

Data [image] Access Array [image] Set Mappings

See Also

Allocate Array, Collector, Get Mappings, Line Probe, Sliding Collector, and Properties (Object)


Set Values

A Formula object that allows you to change an element of an array container.

Use

Use Set Values to modify elements of an array of any type and size. This object is a Formula object pre-charged with an expression that can change an array element.

You can connect several containers to the inputs on the Set Values object: the array to be changed, the scalar data to be added, and the indices specifying the array location to put the scalar data.

Input new values for the array and the index of the element you wish to replace. When all changes are done, the object outputs the modified array as well as the individual element that was changed.

Open View Parameters

Expression input field - This input field allows you to change an element of an array directly. The left-hand side of the expression allows a subset of Formula mathematical syntax, which allows you to specify the element of the array that you wish to change. The A[2] sub-array syntax is supported to specify a particular array element to be changed.

Notes

All arrays are zero-based; all indices for arrays are zero based.

To initially create an array use the Allocate Array [image] objects.

The value to be inserted in the array must be of the same type as that of the array, or promotable to the same type.

Location

Data [image] Access Array [image] Set Values

See Also

Allocate Array, Build Data, Collector, Formula , Get Values, ramp (numElem, from,thru), Set Mappings, and Sliding Collector.

Using Assignment Operations


Set Variable

An object that sets the data value of a variable.

Use

Use the Set Variable object to set the data container (type, shape, and values) of a variable (by name). This variable can then be used by name in other parts of the VEE program.

Undeclared Global Variables created (with Set Variable) in one context of a program can be used as data in another context of that program. For example, a Set Variable in the root context of a program could create an undeclared global variable, which could then be used as data by including a Get Variable in a UserObject. This is especially useful when the program contains several nested layers of UserObjects.

Variables that are set with Set Variable may also be used by name in the expression fields of the following devices: Formula, If/Then/Else, Get Values, Get Field, Set Field, From DataSet and all devices using expressions in transactions, including To File, From File, Direct I/O, From Stdin, To/From Named Pipes, and Sequencer.

Open View Parameters

The open view displays a field for the name of the variable. The name is not case sensitive (either lower-case or upper-case letters may be used). Thus globalA is the same variable as GLOBALa. The name field may be added as a control input.

Notes

To avoid unexpected results, your program must ensure that a variable is set with Set Variable before a Get Variable object (or an object that includes the variable name in an expression) executes. Generally, the best way to ensure this is to connect the sequence output pin of the Set Variable object to the sequence input pin of the Get Variable object, or other object that uses the variable. However, there are cases when the sequence input pin need not be connected. For further information about this, refer to "Variables" in the VEE Advanced Techniques manual.

If Delete Variables at PreRun is on (the default), all variables are deleted before your program executes. If Delete Variables at PreRun is turned off, variables will not be deleted, and you must program carefully to avoid propagating invalid data.

Global variables are truly global since they are not defined at a UserObject level. A global variable that is defined in one context of a program can be used in any other context within the program. For example, you can define a global variable with a Set Variable object in the root context of the program, and then include a Get Variable to get that global variable in a UserObject or UserFunction. However, you will need to avoid name conflicts throughout the program:

If two or more Set Variable objects attempt to set the same variable (with the same name), the current value will be overwritten as each Set Variable executes. This may result in unexpected behavior if you are unaware of the duplicate names.

If there is a data terminal variable with the same name as a variable, the data terminal variable will take precedence.

For further information, refer to "Variables" in the VEE Advanced Techniques manual.

Set Variable cannot set part of a variable that is an array or record. If you want to manipulate an array using globAry[2] = 3 or a record using globRec.field = 2, then use the Assignment Formula to enter these expressions.

The differences between Assignment in a Formula and Set Variable are subtle. Set Variable can create undeclared variables, initialize declared variables, and modify all variables. An Assignment Formula cannot create undeclared globals. Also, Set Variable cannot modify part of a variable as can an Assignment such as globalAry[1] = 2.

It is better to use an Assignment Formula when setting variables for ActiveX objects. If the global variable g_cells is declared and initialized as a cell of a Microsoft Excel worksheet, the Assignment g_cells = 2 in a Formula actually performs the default property set on g_cells. This has the same effect as g_cells.item = 2, which places the value 2 into that cell in Excel. This method maintains g_cells as a pointer to that cell. If you use Set Variable, the global would actually be overwritten so that g_cells would be an integer, not a pointer to a cell in Excel.

Location

Data [image] Variable [image] Set Variable

See Also

Assignment, Default Preferences, Delete Variable, Get Variable, View Variables, and Properties (Object)

Using Assignment Operations

To Create a Variable


Shift Register

An object that outputs the previous values of the inputs.

Use

Use Shift Register to access the previous values of the input.

Notes

Add outputs to Shift Register to access previous values.

The Shift Register starts with all its outputs set to nil. Each time the object is activated, the data from the input is copied to the "current" output terminal. Data that was in the current output is moved to the 1 Prev output. The data from previous executions is shifted down the output terminals to the last output terminal.

Additional outputs may be added so the user may access the data from the "n" previous executions of a thread or program. Turn Clear at PreRun and Clear at Activate off from the Properties window to retain data over successive program executions.

Location

Device [image] Shift Register

See Also

Logging AlphaNumeric, Sliding Collector, and Properties (Object)


Show Config (Object Menu)

Displays a dialog box that shows the I/O configuration of an instrument driver panel, component driver, or a direct I/O object.

Use

From the object menu of an instrument driver panel, component driver, or a direct I/O object, select Show Config to view the configuration specified with I/O [image] Instrument Manager.

To change any configuration parameter use I/O [image] Instrument Manager. Note that any change will affect all other objects using that instrument with Direct I/O. To change the device in a Direct I/O object, edit the name field to choose a new device. Note that the transactions in the Direct I/O object may not be compatible with the new device.

Location

On an instrument driver panel, component driver, or a direct I/O object:

From the object menu [image] Show Config

See Also

Instrument Manager.


Show Data Flow

Shows the route that data takes through the program.

Use

Use Show Data Flow as a debugging tool to show the flow of data between input and output pins. A small square marker is used to trace the flow of data propagation along the lines. Even nil data is shown this way.

When Show Data Flow is set, the menu selection has a checkmark on its left.

Notes

Show Data Flow is often used with Show Execution Flow. These debugging tools will slow the execution of your program.

You can change the rate at which the marker moves by selecting File [image] Default Preferences. In the Default Preferences dialog box, in the Debug group, set the Data Flow Rate.

Location

Debug [image] Show Data Flow

See Also

Line Probe, Default Preferences, Profiler, Show Execution Flow, Step Into, Step Over, Step Out, and Toggle Breakpoint.

To View Data Flow and Program Execution


Show Execution Flow

Highlights the object that is currently executing.

Use

Use Show Execution Flow as a debugging tool to show the currently operating object. A highlighted color border (the default is light green) appears around the object and remains until the operation is complete. The currently executing transaction will also be highlighted in objects that include a list of transactions, such as Direct I/O, Sequencer, To File, From File, etc.

When Show Execution Flow is on, the menu selection has a checkmark on its left.

Notes

Show Execution Flow is often used with Show Data Flow. These debugging tools will slow the execution of your program.

Show Execution Flow also highlights objects that have already executed. To see which objects have executed after a pause or an error in the currently open window, click on Show Execution Flow.

Location

Debug [image] Show Execution Flow

See Also

Line Probe, Profiler, Show Data Flow, Step Into, Step Over, Step Out, and Toggle Breakpoint.

To View Data Flow and Program Execution


Size (Object Menu)

Changes size of an object or multiple objects.

Use

Use Size to change the size of an icon, open view, or window. After you select Size, the pointer changes shape to an arrow. Click and drag the arrow to the new size of the object; an outline rectangle shows you the size of the object. Another way to resize is to position the arrow pointer to where you want the lower right corner of the object and click. In both Panel and Detail view, you can select a group of objects using the CTRL key and the left mouse button. After selection, place your cursor over the edge of one of the objects until you get the double-headed arrow. Drag the cursor to size your objects.

Notes

In Detail view, Size retains the connections with other objects. If Automatic Line Drawing is set, it may take a few moments to redraw lines.

Short Cuts

Place the cursor over the bottom right corner of an object. After the cursor changes shape to an arrow, click the left mouse button and drag the bracket to the new object size.

You may resize an object before you place it on the work area by positioning the outline rectangle at the desired location, pressing the left mouse button, then dragging the arrow pointer to the position you want for the lower right corner of the object. Release the mouse button and you have the size and placement you need.

Location

On the object menu [image] Size

See Also

Object Menu.


Sliding Collector

An object that outputs an Array 1D.

Use

Use Sliding Collector to create an Array 1D from scalar input data.

Object Menu

Clear - Clears the contents of the Sliding Collector.

Open View Parameters

Array Size - The number of elements in the output array. Array Size can be a data input. Default is 10.

Trigger Every - The number of times the input pin must be activated before an array is output. Default is 10.

Both parameters may be set from the open view or from data input pins. Parameters must be integers.

Enum inputs are converted to type Text before the data is placed into the array.

Notes

Sliding Collector builds an Array 1D by automatically sequencing through the array index. Generally, Array Size and Trigger Every are the same size.

The output array is always an Array 1D of length Array Size. The type of the output array is determined by the first input data after a Clear.

If Trigger Every is smaller than Array Size, Sliding Collector generates intermediate outputs. For example, if Array Size is 4 and Trigger Every is 2, the Sliding Collector outputs an array four long after two data inputs. The first two elements of the output are the data elements input; the last two elements of the output are 0.

If Trigger Every is larger than Array Size, some of the input elements are discarded. For example, if Array Size is 2 and Trigger Every is 4, the output is an array two long with the last two pieces of data in it. The first two pieces of data input are discarded.

Location

Data [image] Sliding Collector

See Also

Allocate Array, Collector, Concatenator, Get Values, Set Values., and Properties (Object)

To Collect Data into an Array


Specify Object Type

A dialog box that lets you specify optional details when declaring a variable for an ActiveX automation object, control, or a .NET object.

Use

Use the Specify Object Type dialog box to set the Library and Class, and control events when declaring a variable for an ActiveX object. Also use Specify Object Type dialog box to set the Assembly, Namespace, and Type when declaring a variable for a .NET object. Before you can declare variables for ActiveX or .NET objects you must make them available to VEE. For ActiveX objects use Device [image] ActiveX Automation References or ActiveX Control References… For .NET objects use Device [image] .NET Assembly References.

Declaring variables for ActiveX objects is optional, as it is for all other variables. However, by declaring variables for ActiveX objects, and specifying the object type details, VEE will do type checking automatically to assure that the specified Library and Class are assigned only to the declared variable.

Declaring an automation object variable does not actually create the object for you. For an automation object, you must still use the CreateObject function in a Formula expression to create the object for use in a program. The following expression is an example:

Set Excel = CreateObject("Excel.Application")

Similarly, declaring a .NET object variable does not actually create the object for you. To create a .NET object, you must still use the CreateInstance function in a Formula expression to create the object for use in a program. The following expression is an example:

Set hashtable = CreateInstance("mscorlib", "System.Collections.Hashtable");

Dialog Information

ActiveX Object

Library: - Click in this area for a drop-down list of available ActiveX libraries. This list is made available when you select them using Device [image] ActiveX Automation References… and ActiveX Control References…

Class: - Click in this area for a drop-down list of available classes. The list contains those classes contained in the selected library.

Enable Events - This field is active if the selected class contains events. If you want to handle events in your program that are generated by an ActiveX object, click on this choice so a check mark appears. If you enable this choice, be sure to create an event-handler UserFunction (object menu [image] Create Event Handler).

OK - Once you have specified the object type, click OK for the choices to take effect in the Declare Variable object.

.NET Object

Assembly: - Click in this area for a drop-down list of available .NET Assemblies. This list is made available when you select them using Device [image] .NET Assembly References…

Namespace: - Click in this area for a drop-down list of available namespaces. The list contains those namespaces contained in the selected assembly

Type: - Click in this area for a drop-down list of available types. The list contains those types contained in the selected namespace.

Notes

If you enabled events when declaring an ActiveX object variable, the Declare Variable object displays Events: Enabled. You must create an event-handler UserFunction. It is easy to do this when you declare the variable by using the Create Event Handler… menu pick in the Declare Variable object menu.

.NET does not support events.

Location

Data [image] Variable [image] Declare Variable
(set Type to Object, Set Sub-Type, then click Edit…)

See Also

ActiveX Automation References, ActiveX Control References, Declare Variable.

See the VEE Advanced Techniques manual for details about using ActiveX objects and controls in VEE. See the VEE User's Guide for details about using .NET.


Spectrum (Freq)

A menu item that contains frequency-domain displays.

Use

Use Spectrum (Freq) to access the following frequency-domain displays:

Magnitude Spectrum

Phase Spectrum

Magnitude vs Phase (Polar)

Magnitude vs Phase (Smith)

Notes

Inputs must be Waveform, Spectrum, or an array of Coords.

If a Waveform is input to a Spectrum display, it is automatically transformed into a Spectrum by way of a Fast Fourier Transform (fft).

Location

Display [image] Spectrum (Freq)

See Also

Magnitude Spectrum, Magnitude vs Phase, Phase Spectrum, and Waveform (Time).


Start

An object that, when its button is pressed, starts the execution of a thread.

Use

The Start object, when its button is pressed, begins the execution of the thread to which it is connected, but has no effect on other threads. (Pressing Run starts the execution of all threads in the program, regardless of whether they have Start objects.)

Notes

If a program includes more than one independent thread, you can use Start to initiate a single thread without running the other threads.

When you press Run or Start, propagation begins with Start object(s). If more than one Start object is on a thread, propagation begins at each Start and proceeds in parallel as far as allowed by the propagation rules.

If you press Start inside a UserObject, the UserObject runs but its data output pins do not activate; therefore, propagation does not continue.

Location

Flow [image] Start

See Also

Raise Error, Exit Thread, Exit UserObject, Stop, and Properties (Object)

To Start a VEE Program


Status Bar

A toggle function on the View menu which controls the visibility of the VEE Status Bar.

Use

Use Status Bar to turn the VEE status bar on or off. A checkmark will appear to the left of the Status Bar menu selection when it is turned on.

The Status Bar is a message box located at the bottom of the VEE workspace. The Status Bar displays a variety of useful information, including:

A display of file-load progress and the name of the file being loaded.

Descriptive text for each item on an VEE pull-down menu.

Descriptive text for each button on the VEE Toolbar.

Displays temporary information such as X,Y coordinate data while you are positioning an object in the VEE workspace. It will also provide object Width and Height information for sizing the object.

Constant visible status on the execution mode of the VEE program.

Constant visible status on the state of the VEE Profiler.

Indicates whether or not the VEE program has been modified.

Provides a variety of other temporary status messages such as "File Saved" or "3 objects selected", etc.

Location

View [image] Status Bar

See Also

Toolbar


Step Into

Executes a program by operating one primitive object at a time.

Use

Use Step Into to debug your program. Step Into operates one primitive object every time it is selected. The next object to execute has a yellow border (by default).

When a UserObject or local or imported UserFunction is encountered, VEE will put the object into its detail view and execute each of its objects.

Notes

Step Into will not open remote, built-in, or compiled functions. Step Into will open UserFunctions called from Formula objects and Call objects, but not from transaction objects.

Step Into will only work in a UserFunction or a UserObject when the UserFunction or UserObject is time-sliced. A UserFunction will time-slice only when called from Call, Formula, If/Then/Else, or Sequencer objects (only from the Function field). A UserFunction will not time-slice when called from a To File, To String, or similar object, or if the formula is supplied via a control pin.

In VEE 4 and higher execution modes, a UserObject will only time-slice when invoked from separate threads.

Step Into is not available from a secured program.

PreRun occurs the first time you select Step Into.

Short Cut

F11 maps to Debug [image] Step Into

Location

Debug [image] Step Into

See Also

Call Stack, Step Over, Step Out, Default Preferences, Pause, Run/Resume, Run, Show Data Flow, Show Execution Flow, Start, Stop, and Toggle Breakpoint.

To Step through a Program


Step Out

Completes execution of the current UserObject or UserFunction, and pauses on the next object.

Use

Use Step Out to debug your program. Step Out operates one primitive object every time it is selected. The next object to execute has a yellow border (by default).

If the execution is in a UserObject or UserFunction, VEE will complete execution of all of the objects in that UserObject or UserFunction and exit the UserObject or UserFunction.

Notes

Step Out is not available from a secured program.

PreRun occurs the first time you select Step Out.

Short Cut

Shift-F11 maps to Debug [image] Step Out

Location

Debug [image] Step Out

See Also

Call Stack, Step Into, Step Over, Default Preferences, Pause, Run/Resume, Run, Show Data Flow, Show Execution Flow, Start, Stop, and Toggle Breakpoint.

To Step through a Program


Step Over

Executes a program by operating one primitive object at a time, without opening UserObjects or UserFunctions.

Use

Use Step Over to debug your program. Step Over operates one primitive object every time it is selected. The next object to execute has a yellow border (by default).

When a UserObject or UserFunction is encountered, VEE will execute the object in its entirety.

Notes

Step Over is not available from a secured program.

PreRun occurs the first time you select Step Over.

Short Cut

F10 maps to Debug [image] Step Over

Location

Debug [image] Step Over

See Also

Call Stack, Step Into, Step Out, Default Preferences, Pause, Run/Resume, Run, Show Data Flow, Show Execution Flow, Start, Stop, and Toggle Breakpoint.

To Step through a Program


Stop

Stops all threads in a program.

Use

Use Stop to stop program execution. After Stop is selected, press Resume to continue execution.

Notes

When Stop is selected, the program goes to the "stopped" state which clears any highlighting, and closes any open files and I/O channels.

Location

Debug [image] Stop

See Also

Default Preferences, Pause, Run/Resume, Run, Step Into, Step Over, Step Out, Properties (Object), Stop (Object), and Toggle Breakpoint.

To Step through a Program

To Stop a VEE Program


Stop (Object)

An object that stops the execution of a program.

Use

Use Stop to pause the execution of all threads in the program and return an error code. Stop is usually used after testing for a certain condition.

Open View Parameters

Exit Code - A number that indicates the status of the program. You can type the Exit Code in the recessed rectangle or add it as a data input. The Exit Code is an 8-bit integer that is output to the operating system; if the output is greater than 255, it is output modulo 256 (256 is output as 0).

If you run VEE with the -r option, Stop exits VEE.

Location

Flow [image] Stop

See Also

Exit Thread, Exit UserObject, Raise Error, Start, and Stop.

To Stop a VEE Program


Strip Chart

An object that displays continuously-generated data.

Use

Use Strip Chart to display the recent history of data that is continuously generated. For each y input value, the x value is incremented by the specified Step size. When new data runs off the right side of the display, the display automatically scrolls to show you the latest data.

Strip Chart saves all data sent to it until it's cleared, unless the buffer size is set to a finite value.

Unlike other graphical displays, array data will be appended to the end of the Strip Chart trace, rather than first clearing the trace.

Open View Parameters

These are the default open view parameters. Their use, and the availability of other parameters, is controlled by selections on the object menu and in the Properties dialog box (object menu [image] Properties).

Y name - The name of the Y axis.

Trace1 - The name of the first trace.

Step Size: - Distance between data points on the X axis.

X name - The name of the X axis.

Object Menu

Auto Scale [image] - Clicking these menu items immediately rescales the display to show the entire trace. (Can be added as control pins.)

Auto Scale - Automatically scales both axes.

Auto Scale X - Automatically scales the X axis.

Auto Scale Y - Automatically scales the Y axis.

Zoom [image] - Scales the display.

In - Magnifies the display to contain only the rectangular region that you selected with the pointer. You select the region after selecting this feature by dragging on the graph area. This action outlines the information with a "rubber band" box.

Out 2|5|10|20|50|100X - Expands the scales of the display by a factor in both the X and Y directions about the center.

Clear Control [image] - Parameters that specify when to clear the display.

Display - Clears the displayed trace(s). This parameter may be added as a control input.

Next Curve - Resets the display to show the next curve in a family of curves (data from the next time the display operates) without clearing the previous curve. Next Curve must be selected (or activated) before each new curve in the family. This parameter may be added as a control input.

Center Markers - If markers are available, brings them to the center of the visible part of the trace. This is useful if you've scrolled the display and markers are not visible.

Add Right Scale - Adds up to two additional Y-axis scales to permit traces to have different scale ranges. After adding a right scale, you may add a terminal for its input (object menu [image] Add Terminal [image] Data Input). Then set its properties using the Traces and Scales tabs on the Properties dialog box.

Print - Presents the Print dialog box. Pressing OK prints or plots a copy of the device's entire display on the selected output device. Print may be added as a control input.

Properties

Name - Assigns a variable name to the display. By entering a name, you can programmatically read marker values if they are turned on. The variable is an Object data type, and it is local to the context where the display exists. See Notes for details.

ClearAtPreRun - When the property is True, the display is cleared at PreRun time. Default is True.

 ClearAtActivate - When the property is True, the display is cleared at Activate time. Default is True.

ShowTracesLegend - In the open view, controls the visibility of the trace names and colors. Use EnableEditTracesAndScales to control the edit-button function of the trace legends. Default is True.

 ShowScalesLegend - In the open view, controls visibility of the scale names. Use EnableEditTracesAndScales to control the edit-button function of the scale legends. Default is True.

 ShowScaleLabels - In the open view, controls visibility of the values labeling the scale axes. Default is True.

 Show Scroll Bars - In the open view, controls visibility of the scroll bars on the X and Y scales. Default is True.

 ShowAutoScaleButton - In the open view, controls visibility of the Auto Scale Button. Default is False.

 EnableEditTracesAndScales - In the open view, controls the edit-button function of the trace and scale properties. When enabled, click on an individual trace or scale name to edit its properties. Default is True. Use ShowTracesLegend and ShowScalesLegend to control visibility of the trace(s) and scale(s) names.

GridType: - None - No grid lines are shown.

Markers Group: - Allows you to find the exact value of a data point on the displayed curve. If the data is plotted on a log scale, the values shown on the marker are the linear data points.

To move markers to a different trace, click on the open view on the button to the left of the marker values near the bottom of the display. The button cycles through the different line types and colors of the different traces.

NumMarkers - The number of markers on the graph. None is the default.

MarkerInterpolate - When the property is True, you can place markers between the displayed data points. The marker values displayed are calculated by linear interpolation. Default is False.

BufferSize - Specifies the number of points stored in memory. Default is 10000.

Display BackColor: - Allows you to select the color of the display area from a palette. You can select different colors when the display appears in the detail view and the panel view. The default Background color is set in Default Preferences on the Colors tab for Screen Element: Graph Background.

Scale Label group:

Text: - Allows you to select the font of the scale labels from the list of available fonts on your system. The default font for scale label text is set in Default Preferences on the Fonts tab for Screen Element: Graph Scale Label Text.

Traces group: (one per trace)

Name: - The name of the trace that is displayed to the left of the graph area and the name of the corresponding input terminal.

Scale: - If you have multiple Y scales, selects which Y scale is to be used for this trace.

Color: - The color of the trace. Each added trace has a different color than the existing traces. Default for the first trace is yellow.

LineStyle - The format of the line connecting data points. Default is a continuous line.

PointStyle - The symbol that marks each data point. To show unconnected data points, select the single dot LineStyle format and the desired PointStyle symbol. Default is a dot.

Scale - If it exists for more than one Y scale, choose which scale this Trace is scaled by.

Scales property: (one per X and Y scale and extra Y scales)

Show Scale: - If you have multiple Y scales, a selection (using a check box) to specify if the end points and an axis of each additional right scale is displayed to the right of the graph area.

Scale Name: - The names of the scales appearing in the open view.

Automatic Scaling: - Not adjustable. Default is off. You can add Auto Scale as a control input. You can also rescale the display using Show Auto Scale Button on the General tab, or Auto Scale on the object menu.

Maximum: - The maximum values of the scales.

Minimum: - The minimum values of the scales.

Label Spacing: - Controls which tic marks are labeled with the scale values. Default for X scale is Every Other Tic; default for Y scale(s) is Every Major Tic.

Mapping: - The way the y data is mapped to the display. The mapping may be linear or log. Not adjustable for the X axis. Default is Linear.

Log Cycles: - The maximum number of decades shown (counting down from the maximum y value) when Auto Scale is activated. Log Cycles is only used when the Mapping is Log. Log Cycles is useful when a trace contains a large dynamic range in the data. Default is 4.

Scale Color - The color of any background grid or tic marks. Default is Gray.

Step Size - The distance between data points on the X axis. Available only for the X axis. Default is 1.

ScaleNumberFormat: (a group appears for the X and Y scales, and for any additional Y scales.)

Global Format - Use the default format. Default is on.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Sat 01/Jan/1994 17:01:38). Default is Standard.

The X and Y marker values take on the same number format as the scale to which they are attached. The delta marker values for X and Y use the default number format unless you use the Time Stamp format. Then, if both markers 1 and 2 on the X scale, or both markers on the Y scale are using the Time Stamp format, the delta marker values use the Delta Time format.

Notes

Inputs must be Scalar or Array 1D that can be converted to type Real64. Complex, PComplex, and Spectrum values must be "unbuilt" before being input to a Strip Chart.

To get the best update speed and largest display area on the Strip Chart, reset certain Properties. Set Grid Type to None. In the Layout area, turn off all choices except those that you require. Set the Buffer Size as small as possible. Set the X scale Maximum value so display scrolling is infrequent.

Add traces with the Add Terminal [image] Data Input object menu selection. Up to twelve traces are allowed.

Adding Control Inputs

You can add a Title control input pin, which sets the title bar name to the specified text value. This allows programmatic control over the title shown when the display is printed.

You can add a Traces control input pin. The control input data must be an array of records (or a record scalar if you only want to control one trace). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A field named TraceNum with an integer value (1 is the first trace). The TraceNum field is required. An error occurs if it is omitted.

One or more of the following fields:

Name

Pen

LineType

PointType

The Name field must have a text value. The Pen, LineType and PointType values must be integers from 0 to n, where 0 draws nothing and n is the number of choices available.

You can add a Scales control input pin to control the scales parameters listed above. The control input data must be an array of records (or a record scalar, if you only want to control one scale). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A Text field named Scale with a value X, Y (or Y1), Y2, or Y3. The Scale field is required. An error occurs if it is omitted.

One or more of the following fields:

Name - Changes the scale name in the open view. Must be a text value.

Min - Sets the X scale minimum. Must be an integer or real value.

Max - Sets the X scale maximum. Must be an integer or real value.

Mapping - Must have a text value of Linear or Log.

AutoScale - Controls automatic scaling. Must have a text value of On or Off.

Refer to "Using Records and DataSets" in VEE Advanced Techniques for further information.

Programmatically Setting and Reading Marker Values

You can programmatically get and set marker values. To prepare the display, open its Properties dialog box. On the General tab, enter a value for Name. The value for Name implicitly declares an Object variable that is local to the display’s context. Next, turn on a setting in the Markers group. VEE assigns the following properties to the markers’ X and Y positions, including the delta values. (Marker1 points down; Marker2 points up.)

Marker1X (gets the position as a Real64)

Marker1Y (gets the position as a Real64)

Marker2X (gets the position as a Real64)

Marker2Y (gets the position as a Real64)

MarkerDX (gets the position as a Real64)

MarkerDY (gets the position as a Real64)

Marker1 (gets/sets the position as a Coord)

Marker2 (gets/sets the position as a Coord)

The Marker1 and Marker2 properties can be used to read the current marker position or move the marker to a new position. All other marker properties are read-only. If you attempt to move the marker to a coordinate that is not on the trace, the marker will "snap" to the closest point that is on the trace.

In your program, enter one or more expressions in a Formula object to set or read the marker values. Each expression must contain the display Name and the marker property of interest. Marker property names are not case-sensitive. If the display’s Name is XY, and Delta Markers is turned on, the following expressions will read all the available marker values, assigning them to the variables a through f as Real64 scalars:

a = XY.Marker1X

b = XY.Marker1Y

c = XY.Marker2X

d = XY.Marker2Y

e = XY.MarkerDX

f = XY.MarkerDY

You can assign the display Name to a global variable. Add an assignment expression to your program in a Formula object, and declare the global using the Declare Variable object. As an example, assume you declared the variable globalXY as a global, and set its Type to Object. Then, in the context where the display exists, add this expression to your program:

Set globalXY = XY

This lets you read the display’s marker values from another context in the program using an expression such as:

a = globalXY.Marker1X

As you develop a program, you may want to include a way to pause the program so you can manually reposition the markers before the program reads their values. One way to pause a program is to add a Confirm (OK) button between the display’s sequence output and the Formula object’s sequence input. Alternately, you may want to position the markers programmatically.

Location

Display [image] Strip Chart

See Also

Complex Plane, Default Preferences, Magnitude Spectrum, Polar Plot, Waveform (Time), XY Trace, and X vs Y Plot.

To Set Markers in the Display, To Get and Set Marker Properties


SubRecord

An object that allows the user to cut out a number of fields from a record.

Use

Use SubRecord to output a subset of the original record, with specified fields "cut" from the record, on the Record output pin. The record to be edited is input on the Record input pin. The list of fields to be "included" or "excluded" in the output record is input on the Fields input pin.

If Include fields is selected in the open view, the output record will consist only of those fields in the Fields input.

If Exclude fields is selected in the open view, the output record will consist of all fields in the original record excluding those listed in the Fields input.

Open View Parameters

Include fields -- (The default mode.) The output record is constructed from the input record with only those fields in the list of field names on the Fields data input pin. This selection toggles with Exclude fields.

Exclude fields -- The output record is constructed from the input record with only those fields that are not in the list of field names on the Fields data input pin.

Notes

The Fields input pin can be a text array consisting of the names of the record fields to include/exclude in the output record.

If you attempt to include/exclude a field that is not in the input record, an error will occur. If you exclude all the fields of the record, a nil output signal is sent.

Note the distinction between the UnBuild Record, SubRecord, and Get Field objects.

The UnBuild Record object has outputs for the Name List and Type List of the input record fields. The other (optional) outputs A, B, etc. of the UnBuild Record object return the same results as would multiple Get Field objects.

The Get Field object works like a Formula object, in that it uses dot syntax (A.B) to unbuild a record. Note that Get Field allows you to unbuild a record of records in one step by using an expression such as A.B.C. This process would require two UnBuild Record objects.

The SubRecord object differs from UnBuild Record and Get Field in that its output is always a record. The SubRecord device allows you to either include or exclude a list of fields from a record to form a subrecord.

Location

Data [image] Access Record [image] SubRecord

See Also

Build Record, From DataSet, Get Field, Record Constant, Set Field, To DataSet, UnBuild Record, and Properties (Object)


Tank

An object that displays a Scalar numeric value graphically using a color bar inside a graphical tank.

Use

Use Tank to display a numeric value on a analog scale with a color bar inside a graphical tank, and an optional digital numeric field.

Open View

The minimum and maximum values of the Tank are set on the open view of the object by clicking on the present value and typing in a new value. Tic marks and their labels are automatically calculated and displayed. The minimum value must be less than the maximum value.

These values may also be added as control inputs.

Properties

ClearAtPreRun - When this property is True, the contents of the Tank are cleared at PreRun. Default is True.

ClearAtActivate - When this property is True, the contents of the Tank are cleared at Activate. Default is True.

Orientation - Selects how the Tank is displayed. Default is Vertical.

ShowDigitalDisplay - If this property is True, a digital display of the input value is displayed at the bottom of the open view of the object. If the check box is not selected, the digital display is not displayed and the object operates faster. Default is True.

ShowTics - Controls visibility of scale’s tic marks and labels. Default is True.

Logarithmic - When this property is True, changes scale from linear to logarithmic. Default is False.

LabelSpacing - Controls which tic marks are labeled with the scale values. Default is Every Other Tic.

HighColor - Specifies the color used for the highest range (i.e., greater than High Limit).

High Limit - Defines the numeric lower limit for the highest range. This value must be greater than or equal to the Low Limit. You may add this value as a control input, which disables this property's edit field.

MidColor - Specifies the color used for the middle range (i.e., less than or equal to High Limit and greater than Low Limit).

Low Limit - Defines the numeric upper limit for the lowest range. This value must be less than or equal to the High Limit. You may add this value as a control input, which disables this property's edit field.

LowColor - Specifies the color used for the lowest range (i.e., less than or equal to the Low Limit).

NumberFormat:

Global Format - Use the default format. Default is on.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

Notes

The input data must be scalar and able to be converted to Real64 (Complex, PComplex, Spectrum, and Coord must be first "unbuilt".)

The Low Limit must be less than the High Limit.

To use only 2 ranges of color, set the Low Limit equal to the High Limit.

To use only 1 color, set the Low Color, Mid Color, and High Color to the same color.

Short Cuts

To quickly change the orientation of the Tank, just resize it to the desired shape. It will automatically change orientation.

Location

Display [image] Indicator [image] Tank

See Also

AlphaNumeric, Color Alarm, Fill Bar, Logging AlphaNumeric, Meter, and Thermometer.

To Show an Analog Display of Data


Text

An object that outputs a constant string Scalar or Array 1D.

Use

Use Text to set a string constant or to request user input. Click on the entry field to enter a value.

Example

To use Text as a prompt on a panel view, change the name of the Text object to a prompt such as What is your name? The user fills in the requested information in the entry field.

Properties

DataShape - Sets the initial data shape of the value(s) to be output with this object.

ArraySize: - When 1D Array is selected, ArraySize sets the length of the array.

 ArraySizeFixed - When this property is True, the array cannot have lines added or deleted. This selection is only available if 1D Array is selected.

 ShowArrayIndices - When this property is True, each line in the entry field is indexed. This selection is only available if 1D Array is selected.

 PasswordMasking - When this property is True, the text in the entry field of the open view is echoed as asterisks (*).

Wait for Input - When this property is True, the object does not operate until the object's value is changed. When the check box is not selected, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

AutoExecute - When this property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, AutoExecute is ignored. Default is False.

 InitialValue - Specifies the value to be set. Default value is a null string.

 InitializeAtPreRun - When this property is True, the InitialValue is set at PreRun time. Default is False.

 InitializeAtActivate - When this property is True, the Initial Value is set at Activate time. Default is False.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting an initial value is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value(s). This input requires a Text value, either a Scalar or an Array 1D. The Constant is reconfigured to match the shape of the incoming data.

The Reset input allows you to programmatically set the value(s) to zero. If the Constant is configured as an Array 1D, all values are set to a null string. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the value can be changed in the object’s open view.

There is no interpretation of escaped characters in this constant. Your entry is replicated exactly on the output pin.

Note that the InitialValue field is always a scalar, even if Text is configured to be an array.

Location

Data [image] Constant [image] Text

See Also

Complex, Constant, Coord, Date/Time, UInt8, Int16, Int32, PComplex, Real32, Real64, Selection Control, and Toggle Control.

To Use a Data Constant


Text Input

An object that displays a pop-up dialog box that accepts text input.

Use

Use Text Input to prompt the user to enter text, accept the text, and check the text with a user-defined test for validity.

In the pop-up dialog box, when the OK button is pressed, the text input by the user is output on the Value output pin. When the Cancel button is pressed, a 1 is output on the Cancel output pin.

Open View

  • Prompt/Label - The string that prompts the user to fill in the text field. You may add this parameter as a data input. Default is Enter Text:

  • Default Value - The text that is in the dialog's input field before anything is typed. If the user presses OK without typing anything, this text is output. You may add this parameter as a data input. Default is blank.

  • Value Constraint - The equation that tests the input text for validity. You can use any mathematical expression or call a UserFunction. You may add this parameter as a data input. Default is strLen(value)>0; which means it checks for user input of one or more characters - a null string is not acceptable. To accept any value, use the expression 1.

  • Error Message - The text that is output in a message box if the user input does not meet the Value Constraint. You may add this parameter as a data input. Default is You must enter text.

Properties

  • PopupTimeoutEnabled - When this property is True, a Timeout output pin is added to the object. Default is False.

  • PopUpDuration - Sets the length of time the pop-up dialog box is displayed. After this period of time, the dialog box times out and a value of 1 is output on the Timeout output pin. No other outputs pins have data if the Timeout pin executes. This field is only available when the Timeout Enabled check box is selected. Default is 60 seconds.

  • PopupOKLabel - Sets the button label to OK if True. You may also use alternative wording if your users are not native English speakers. Regardless of the wording, the button's function remains the same.

  • PopupCancelLabel - Sets the button label to Cancel if True. You may also use alternative wording if your users are not native English speakers. Regardless of the wording, the button's function remains the same.

  • PopupPasswordMasking - When this property is True, the input text is echoed as asterisks (*). This feature is useful when the operator is entering sensitive data such as a password. The string that is output on the Value output pin is not masked. Default is False.

Notes

The default location of the pop-up dialog box is approximately at the center of the work area. If you move it, next time it will pop-up to the new location.

The title text of the error message dialog box is the same as the Text Input object title.

To respond to the pop-up dialog box using only the keyboard: when the dialog box pops up, start typing and use Enter and Esc keys. Use the Tab key to move between the input field and the buttons and then select the buttons with the Space bar.

The pop-up dialog box and the error dialog box are only displayed while the program is running. While the pop-up dialog box is displayed, the entire program pauses execution, then continues when the dialog box is closed.

Location

Data [image] Dialog Box [image] Text Input

See Also

File Name Selection, Int32 Input, List Box, Message Box, Real64 Input, and UserObject.

To Use a Data Input Dialog Box


Thermometer

An object that displays a Scalar numeric value graphically using a color bar inside a graphical thermometer.

Use

Use Thermometer to display a numeric value on an analog scale with a color bar inside a graphical thermometer, and an optional digital numeric field.

Open View

The minimum and maximum values of the Thermometer are set on the open view of the object by clicking on the present value and typing in a new value. Tic marks and their labels are automatically calculated and displayed. The minimum value must be less than the maximum value.

These values may also be added as control inputs.

Properties

ClearAtPreRun - When this property is True, the contents of the Thermometer are cleared at PreRun. Default is True.

 ClearAtActivate - When this property is True, the contents of the Thermometer are cleared at Activate. Default is True.

Orientation - Selects the orientation of how the Thermometer is displayed. Default is Vertical.

 ShowDigitalDisplay - If this property is True, a digital display of the input value is displayed at the bottom of the open view of the object. If the check box is not selected, the digital display is not displayed and the object operates faster. Default is True.

ShowTics - Controls visibility of scale’s tic marks and labels. Default is True.

Logarithmic - When turned on, changes scale from linear to logarithmic. Default is False.

 LabelSpacing - Controls which tic marks are labeled with the scale values. Default is Every Other Tic.

HighColor - Specifies the color used for the highest range (i.e., greater than High Limit).

 High Limit - Defines the numeric lower limit for the highest range. This value must be greater than or equal to the Low Limit. You may add this value as a control input, which disables this property's edit field.

 MidColor - Specifies the color used for the middle range (i.e., less than or equal to High Limit and greater than Low Limit).

 Low Limit - Defines the numeric upper limit for the lowest range. This value must be less than or equal to the High Limit. You may add this value as a control input, which disables this property's edit field.

 LowColor - Specifies the color used for the lowest range (i.e., less than or equal to the Low Limit).

NumberFormat:

Global Format - Use the default format. Default is on.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

Notes

The input data must be Scalar and able to be converted to Real64 (Complex, PComplex, Spectrum, and Coord must be first "unbuilt".)

The Low Limit must be less than the High Limit.

To use only 2 ranges of color, set the Low Limit equal to the High Limit.

To use only 1 color, set the LowColor, MidColor, and HighColor to the same color.

Short Cuts

To quickly change the orientation of the Thermometer, just resize it to the desired shape. It will automatically change orientation.

Location

Display [image] Indicator [image] Thermometer

See Also

AlphaNumeric, Color Alarm, Fill Bar, Logging AlphaNumeric, Meter, and Tank.

To Show an Analog Display of Data


Tile Horizontally

A function for managing windows in the VEE workspace.

Use

Use Tile Horizontally to arrange all opened, non-minimized windows as non-overlapping windows. Windows will be stacked one on top of the other.

Location

Window [image] Tile Horizontally

See Also

Cascade, Close All, Minimize All, and Tile Vertically.


Tile Vertically

A function for managing windows in the VEE workspace.

Use

Use Tile Vertically to arrange all opened, non-minimized windows as non-overlapping windows. Windows will be arranged side-by-side in the VEE workspace.

Location

Window [image] Tile Vertically

See Also

Cascade, Close All, Minimize All, and Tile Horizontally.


Timer

An object that outputs the difference in seconds between the activation times of the top and bottom data input pins.

Use

Use Timer to measure how much time passes between two events, such as objects operating. This happens when the first and second inputs are activated. If the second input is activated before the first, the container on the second input is ignored and the Timer object does not execute.

Notes

Time is displayed in seconds.

On Windows, Timer uses the high-resolution performance counter if available on your system.

Location

Device [image] Timer

See Also

Date/Time, Do, and Properties (Object)


To

A menu item.

Use

Use To for accessing the following objects which are destinations for I/O operations:

To File

To DataSet

To Printer

To String

Location

I/O [image] To

See Also

From.


To DataSet

An object that allows the user to collect records into a file.

Use

Use To DataSet to collect records that have the same schema definition into a file for later retrieval. The following control pins can be added:

File Name -- This control pin allows the user to change the name of the file that the records will be written to.

Rewind -- This control pin "rewinds" the file and makes it available for rewriting with an entirely new record type. The effect is the same as sending the first record to the file with the Clear File At PreRun selection check box selected.

Close -- This control pin closes the file.

Open View Parameters

To DataSet: -- Click on the name field to display a dialog box, then select the name of the file that contains the DataSet.

Clear File At PreRun -- If this check box is selected, the entire DataSet is cleared and rewritten the first time To DataSet executes (when it receives the first record). Because the DataSet is completely erased, records with a new schema definition can be sent -- the first record establishes the new schema definition.

Notes

The records going into the To DataSet file must have the same schema (data shape and type). The first record written to the file will define the schema that all subsequent records must have.

Every time the To DataSet object executes with its one input (only one input is allowed), the new record is appended to the file. If the new record is an array, every record element of it is appended. The schema (number of fields, and each field name, type, and shape) must match for every record, but the shape of the record (scalar/array) does not matter. The To DataSet object will continue appending to the file until either a Rewind control input is activated, or Clear File At PreRun is selected and PreRun occurs. The next time the To DataSet object executes, it begins writing to the file at its beginning, again starting with the schema of the first record. This schema may be different than what was in the file.

Location

I/O [image] To [image] DataSet

See Also

Build Record, From DataSet, Record Constant, UnBuild Record, and Properties (Object)

To Write Data to a File


To File

An object that writes data to a file using transaction statements.

Use

Use To File to output a wide variety of encodings and formats to allow flexible output to files. A single pointer is maintained for each file; therefore, data output by different To File objects is written to the file in the order that the objects operated.

To File Actions:

WRITE - Writes data to a file using the specified encoding and format.

EXECUTE - Repositions the file's write pointer to the beginning of the file with (CLEAR) or without (REWIND) erasing the contents of the file. EXECUTE REWIND can only be used when Clear File at PreRun & Open is selected. Note that the file is automatically closed when the VEE program stops. However, you may use the EXECUTE CLOSE transaction to close the file during program execution. EXECUTE DELETE deletes the file.

WAIT - Waits the specified number of seconds before executing the next transaction.

To File Encodings;

TEXT - Writes all data types to human-readable files that are easily edited or ported to other software applications. VEE numeric data is automatically converted to text as it is written.

BYTE - Converts numeric data to binary integer and writes the least significant byte.

CASE - Maps an enumerated value or an integer to a string and writes the string. For example, you could use CASE to accept error numbers and write error messages.

BINARY - Writes all data types in an machine-specific binary format.

BINBLOCK - Writes all VEE data types in binary files with IEEE 488.2 definite length block headers.

CONTAINER - Writes all data types in a VEE specific text format. Use CONTAINER to export data via the "To File" object directly into PV-WAVE to perform visual data analysis.

Open View Parameters

Clear at PreRun & Open - Erases file contents and sets file pointer to the beginning of the file. When the check box is not selected, data is appended to the end of the file.

If you have multiple To File objects pointing to the same file, the check boxes are linked so that if you change it in one place, it changes in all of them.

The open view shows the list of transactions to be executed.

Object Menu

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Print Trans - Prints the detailed dialog box that describes the currently highlighted transaction.

Properties

EolSequence - Specifies the characters sent at the end of WRITE transactions that use EOL ON. The entry in this field must contain zero or more ASCII characters surrounded by double quotes. Default is "\n".

 ArraySeparator - Specifies the character string used to separate elements of an array written by WRITE TEXT transactions. The entry in this field must be surrounded by double quotes.

MultiFieldFormat: Specifies the following two formatting styles for multi-field data types for WRITE TEXT transactions. The affected data types are Coord, Complex, PComplex, and Spectrum.

Data Only - Separates each multi-field item with a comma without surrounding the group with parentheses. The complex number 2+2j would be formatted as 2,2.

(...) Syntax - (default) Separates each multi-field item with a comma and surrounds the group with parentheses. The complex number 2+2j would be formatted as (2,2).

ArrayFormat group: Determines how multidimensional arrays are formatted.

Linear - Arranges array elements linearly.

Block - (default) Arranges array elements in a block of two or more dimensions using the EOL character at the end of each row.

Short Cuts

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Location

I/O [image] To [image] File

See Also

Formula, From File

To Write Data to a File

Refer to the manual, VEE Advanced Techniques, in the chapter titled, "Using Transaction I/O".


To/From DDE

An object that exchanges data through transactions to and from a Microsoft Windows application that supports Dynamic Data Exchange (DDE).

Use

DDE is a tool for programmers who wish to implement interprocess communication.

You must add one or more transactions to To/From DDE to read or write data. To do this, click on Add Trans in the object menu.

Currently, the .NET Framework is much more fully featured, well documented, and supported.

Otherwise, ActiveX Automation will be more robust for your needs, and is better documented for most servers. For information about ActiveX, see VEE Advanced Techniques.

Open View Parameters

Application - The name of the Windows application supporting DDE. (For example, Excel.)

Topic - The application-specific identifier for the kind of data. (For example, Sheet1.)

In addition, the open view shows the list of transactions to be executed.

The Application and Topic fields can be added as control inputs.

Object Menu

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Print Trans - Prints the detailed dialog box that describes the currently highlighted transaction.

Properties

EolSequence - Specifies the characters sent at the end of WRITE transactions that use EOL ON. The entry in this field must contain zero or more ASCII characters surrounded by double quotes. Default is "\n".

 ArraySeparator - Specifies the character string used to separate elements of an array written by WRITE TEXT transactions. The entry in this field must be surrounded by double quotes.

MultiFieldFormat group: Specifies the following two formatting styles for multi-field data types for WRITE TEXT transactions. The affected data types are Coord, Complex, PComplex, and Spectrum.

Data Only - Separates each multi-field item with a comma without surrounding the group with parentheses. The complex number 2+2j would be formatted as 2,2.

(...) Syntax - (default) Separates each multi-field item with a comma and surrounds the group with parentheses. The complex number 2+2j would be formatted as (2,2).

ArrayFormat group: Determines how multidimensional arrays are formatted.

Linear - Arranges array elements linearly.

Block - (default) Arranges array elements in a block of two or more dimensions using the EOL character at the end of each row.

Notes

To/From DDE provides for communication with Windows applications that support Dynamic Data Exchange. However, the user is responsible for determining the application-specific protocols necessary for successful DDE communication from VEE to a particular application. This is an advanced programming capability.

A Windows application that supports DDE may act as either a client, a server, or both. However, VEE provides only client capabilities.

To/From DDE uses four types of transactions:

READ(REQUEST) - Reads data from a DDE transfer.

WRITE(POKE) - Writes (pokes) data to a DDE transfer.

EXECUTE - Sends a command to the DDE server that VEE is communicating with. The server then executes the command.

WAIT - Waits for the specified time (in seconds).

To/From DDE initiates and terminates DDE operations as part of its function. You do not need to explicitly initiate and terminate these transactions.

For examples of using DDE, refer to VEE Advanced Techniques.

Short Cuts

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Location

I/O [image] To/From DDE

See Also

Formula, From, From File, To File, and To.

Refer also to VEE Advanced Techniques, in the chapter titled, "Using Transaction I/O".


To/From Socket

An object that uses sockets for I/O within networked computer systems.

Use

Sockets are tools for programmers who want to implement inter-process communication. To/From Socket uses transaction I/O.

You must identify the port you want to connect or bind, and add one or more transactions to To/From Socket to read or write data.

To/From Socket Actions:

READ - Reads data using the specified encoding and format.

WRITE - Writes data using the specified encoding and format.

EXECUTE - Use the EXECUTE CLOSE transaction to specifically terminate a socket connection.

WAIT - Waits the specified number of seconds before executing the next transaction.

To/From Socket Encodings:

TEXT - Reads and writes all data types to human-readable files that are easily edited or ported to other software applications. VEE numeric data is automatically converted to text as it is written.

BYTE - Converts numeric data to binary integer and writes the least significant byte.

CASE - Maps an enumerated value or an integer to a string and writes the string. For example, you could use CASE to accept error numbers and write error messages.

BINARY - Reads and writes all data types in an machine-specific binary format.

BINBLOCK - Reads and writes all VEE data types in binary files with IEEE 488.2 definite length block headers.

CONTAINER - Reads and writes all data types in a VEE specific text format.

Open View Parameters

The open view shows the fields identifying port connections or bindings, the timeout period, and the list of transactions to be executed.

Connect/Bind Port - This button toggles between bind and connect modes. Bind Port binds a socket on the computer on which VEE is running and waits for a connection to occur. Connect Port connects to a bound socket on a remote computer. In the associated text field, enter the port number. Use port numbers between 5000 and 6000.

Host Name - In Bind Port mode, displays the name of host computer on which VEE is running. In Connect Port mode, enter the specific host name or Internet Protocol (IP) address of the remote computer to which you want to connect.

Timeout - Integer value representing the timeout period in seconds allowed for bindings to occur or connections to be accepted. After connections are made, this is the period allowed for all READ and WRITE transactions.

Object Menu

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Print Trans - Prints the detailed dialog box that describes the currently highlighted transaction.

Properties

EolSequence - Specifies the characters sent at the end of WRITE transactions that use EOL ON. The entry in this field must contain zero or more ASCII characters surrounded by double quotes. Default is "\n".

ArraySeparator - Specifies the character string used to separate elements of an array written by WRITE TEXT transactions. The entry in this field must be surrounded by double quotes.

MultiFieldFormat group: Specifies the following two formatting styles for multi-field data types for WRITE TEXT transactions. The affected data types are Coord, Complex, PComplex, and Spectrum.

Data Only - Separates each multi-field item with a comma without surrounding the group with parentheses. The complex number 2+2j would be formatted as 2,2.

(...) Syntax - (default) Separates each multi-field item with a comma and surrounds the group with parentheses. The complex number 2+2j would be formatted as (2,2).

ArrayFormat group: Determines how multidimensional arrays are formatted.

Linear - Arranges array elements linearly.

Block - (default) Arranges array elements in a block of two or more dimensions using the EOL character at the end of each row.

Short Cuts

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Notes

A To/From Socket object set to bind a socket or make a connection will block all threads in VEE while waiting the allowed timeout period for the connection to occur.

Multiple To/From Socket objects that are binding an identical port number will share the same socket. Likewise, all objects configured with identical port numbers and host names to attempt connection to the same bound socket will share the same socket. The overhead of establishing the connection is incurred in the first execution of one of the commonly configured objects.

Setting the timeout value to zero disables timeouts, making the periods waiting for connections infinitely long. Timeout violations cause errors, and halt VEE execution.

The timeout value is ignored when a connection is attempted if the remote host does not exist or it is down. In this case the VEE interface is frozen until the connection actually fails, which may take up to one minute.

All socket connections established in a VEE program are broken when a program stops executing. When connections are broken, the server and client objects must repeat the bind/connect protocols to re-establish connections.

All READ operations will block for the timeout period waiting for the amount and type of data specified in the transaction. To avoid blocking threads, use the READ IOSTATUS transaction to detect when data is available on the socket.

Location

I/O [image] To/From Socket

See Also

Formula

Refer to the manual, VEE Advanced Techniques, in the chapter titled, "Using Transaction I/O."


To/From VXIplug&play

An object that writes data to and reads data from an instrument using transaction statements which call VXIplug&play drivers.

Use

Use To/From VXIplug&play to communicate with an instrument that has a VXIplug&play driver. This instrument may be a "rack-and-stack" instrument as well as a VXI instrument.

To access the To/From VXIplug&play object, bring up the Instrument Manager from the I/O menu. Select an Instrument. Then, in the "Create I/O Object", select "Plug&play Driver".The selection is grayed out if no VXIplug&play drivers have been configured for that instrument.

Note that not all VXIplug&play drivers support all platforms. Also certain versions of VTL/VISA (supplied with your GPIB card) may not be supported on all platforms. Please check with the appropriate vendor.

Open View Parameters

The open view shows the list of transactions to be executed. Each transaction is a VXIplug&play command (a call to a C function in the VXIplug&play driver).

When an empty transaction is double-clicked on, the Select a Function Panel dialog box appears.

This dialog box allows you to select the function to execute. The text area at the bottom of the dialog box gives a description of the currently selected function panel. The hierarchical tree view of the functions shows you the different categories of function panels. A folder with a + to its left indicates there are more folders or function panels available. A folder with a - to its left indicates the folders or function panels are shown. f(x) on the left side, indicates a function panel. To completely expand a branch of the tree, select the item to expand and press the * key.

After selecting the function and clicking OK, the Edit Function Panel dialog box appears. This dialog box lets you edit the values on the function panel, set up variables, and automatically create input and output terminals. Click the right mouse button on any non-control area of this dialog box to get help about the function call. Click the right mouse button on any control to get a description of the control.

Clicking Cancel at this point will cancel the entire function panel selection process.

The Edit Function Panel dialog box contains the following fields:

Panel tab:

Controls (at the top of the dialog box) - Each control represents a parameter to the function. Editing the value in a control lets you specify a constant value for the parameter. The names of the controls are labels specified from the function panel file. To get help on a control, click the right mouse button on it. There may not be any controls for certain function panels.

Session Handle - Displays the unique session handle of each instrument.

Status - Displays a non-zero value if an error occurred when executing this function panel.

Function call (at the bottom of the dialog box) - The C function (and its parameters) that are called when the object executes. This command string is also shown as a transaction on the open view of the object.

Configuration tab: (this tab may not exist for all functions) - Allows you to specify variables for the parameters to the function.

label name group: The name of the control as specified from the function panel file.

Parameter Type: - Specifies the parameter’s type and shape.

Parameter Value: Constant | Variable - Specifies if the parameter is set as a constant value (from the Panel tab) or is input to the C function as a variable. Parameter Value is grayed out if the parameter must be a Variable (such as for an array type). If Variable is selected, the Name and Create Terminal fields are enabled.

Name - The name of the variable passed by the C function. By default, Name is set to the label name as specified from the function panel file. If the variable is an input variable, this field can also contain calls to UserFunctions that return a value (that then would be passed to the function call), variables, and expressions to be evaluated at run time.

Create Terminal - When the check box is selected, the input and/or output terminal is created if it does not currently exist. If the Name field is set to an invalid terminal name (such as a UserFunction call or an expression) this field is grayed out.

Auto-Allocate Input - If the Parameter Type is an array or type Text, memory must be allocated to send to the function to retrieve data. Edit the size field to tell VEE how much memory to allocate to accommodate the number of array elements or string length. It’s important that you set the size large enough. You can uncheck this box and allocate the memory yourself using an input terminal, but this is not recommended.

When you double-click on an existing transaction, the Edit Function Panel dialog box will appear and then you can edit the currently selected call to the function.

Object Menu

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Instrument Help - Gives you the help information associated with the VXIplug&play driver. This information was provided by the hardware manufacturer and is included with each driver.

Short Cuts

You can quickly add a data terminal by placing the cursor over the input or output terminal display area and then pressing CTRL+A. Each press of CTRL+A adds an additional data terminal.

You can quickly delete a data terminal by placing the cursor over the terminal view area and then pressing CTRL+D.

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Properties

IgnoreCautionsReturned - When the check box is selected, any cautions that are returned from transaction calls to some manufacturers' VXIplug&play drivers will not cause a caution dialog box to pop-up and pause the program. Generally, this check box should only be checked after you have gotten a caution from a VXIplug&play and modified your program to handle the caution condition.

Configured Instrument - Contains non-editable information about which configured name in the Instrument Manager this device is connected to.

Notes

When in the Edit Function Panel dialog box, click the right mouse button on the background of the Panel tab for help on the function panel.

Click the right mouse button on a control for an explanation of the parameter.

VXIplug&play does not support any of the Advanced I/O features. For example, a VXIplug&play driver ignores the live mode setting.

VXIplug&play function calls will not appear in VEE’s Bus I/O Monitor.

VXIplug&play function calls cannot be mixed with Direct I/O or Instrument Panels to communicate with the same instrument in a program. You can, however, use different types of I/O to different instruments in the same program.

You must allocate memory for array and text parameters passed into the VXIplug&play drivers. If not enough memory is allocated for these parameters, the function could overwrite memory and may cause a a General Protection Fault or Segmentation Violation. Since the VXIplug&play shared library is linked directly into VEE, this situation can cause VEE to crash and exit. You are strongly encouraged to always use the Auto-Allocate Input feature and be sure to set the memory size large enough.

Since VEE automatically calls init() and close() and takes care of the session handle for you, do not call any init() or autoconnect() functions that may be in the driver. See the Advanced I/O help topic for more information.

Location

I/O [image] Instrument Manager...

See Also

Advanced I/O, Component Driver, Formula, Instrument Manager, and Panel Driver.

To Use a Plug&play Driver Object

VEE Advanced Techniques


Toggle Control

Objects that output a 1 (pressed, checked, or selected) or a 0. Toggle Control objects have a variety of display formats, but they all work the same way.

Use

Use Toggle Control objects to set a one or a zero output. Toggle Control objects are commonly used with an If/Then object that contains an A==1 condition.

Properties

Format group: - Specifies the appearance of the Toggle Control object and the method of selecting a choice. The default format is whichever object you chose from the menu.

Button - The choice is made by pressing a button.

Check Box - The choice is made by clicking on a recessed box. A check mark indicates on (1).

Vertical Paddle - A vertical paddle switch. A green dot indicates on (1).

Horizontal Paddle - A horizontal paddle switch. A green dot indicates on (1).

Vertical Rocker - A vertical rocker switch. A green dot indicates on (1).

Horizontal Rocker - A horizontal rocker switch. A green dot indicates on (1).

Vertical Slide - A vertical slide switch. A green dot indicates on (1).

Horizontal Slide - A horizontal slide switch. A green dot indicates on (1).

<Custom> - When selected, you can specify your own bitmaps for on and off. Select the bitmaps from the Custom tab.

Execution group:

Wait for Input - When this property is True, the object does not operate until the object's value is changed. When the check box is not selected, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

AutoExecute - When this property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, Auto Execute is ignored. Default is False.

Layout group:

Scaled - If this property is True, the toggle images are scaled to the size of the object. If the property is False, the toggle images are left-justified. Default is False.

Show Caption - When the property is True, the caption on the open view of the object is shown. The caption contains the same text as on the title bar.

Initialization group:

InitialValue - Specifies the value to be set. Default value is 0 (zero).

InitializeAtPreRun - When the property is True, the Initial Value is set at PreRun time. Default is False.

InitializeAtActivate - When the property is True, the Initial Value is set at Activate time. Default is False.

CustomOnPicture - Select the graphical image file you want displayed when the Toggle Control outputs a value of 1.

CustomOffPicture - Select the graphical image file you want displayed when the Toggle Control outputs a value of 0.

Preview - Displays the current graphic images selected.

The directory shown is the bitmaps directory under the installation directory. To choose a file from another directory, press the Browse ... button.

VEE examines the file to determine the file format. The currently supported formats are:

Bitmaps (*.BMP)

GIF87a (*.GIF)

Windows MetaFile (*.WMF)

Portable Network Graphic (*.PNG)

Default bitmaps are located in the bitmaps directory under the VEE program installation directory.

Note

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin.

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value. This input requires an Int32 Scalar value. A value of 0 is a toggle off. Any other value is a toggle on.

The Reset input allows you to programmatically set the value to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the toggle position can be changed in the object’s open view.

Location

Data [image] Toggle Control

See Also

Complex, Constant, Coord, Date/Time, Selection Control, If/Then/Else, UInt8, Int16, Int32, PComplex, Real32, Real64, and Text.


Toggle Breakpoint

Sets or clears execution breakpoints at the selected objects.

Use

Use Toggle Breakpoint as a debugging tool to set or clear breakpoints. Select the objects and then select Toggle Breakpoint. This action sets breakpoints on any selected objects without breakpoints, and clears the breakpoint on any selected objects with breakpoints.

Setting a breakpoint on an object stops the execution of the program before this object. To continue execution, press the Resume button on the VEE toolbar; to operate only the object with the breakpoint, press one of the Step buttons.

After the breakpoint is set, the object is highlighted with a colored outline border (orange, by default).

Notes

To set the breakpoint of a single object, use the Breakpoint selection on the object properties window.

When an object has a breakpoint set via Toggle Breakpoint, the Breakpoint selection is checked in the Properties window.

Breakpoints are saved with the program. If you do not want the breakpoints to reappear when the program is opened, use Clear All Breakpoints before saving.

Short Cuts

To toggle breakpoints, highlight the object(s) to set, then press CTRL-B.

Location

Debug [image] Toggle Breakpoint

See Also

Activate Breakpoints, Properties (Object), Clear All Breakpoints, Run/Resume, Select All, Show Data Flow, Show Execution Flow, Step Into, Step Over, and Step Out.

To Control Breakpoints


Toolbar

A toggle function on the View menu which controls the visibility of the VEE Toolbar.

Use

Use Toolbar to turn the VEE toolbar on or off. A checkmark will appear to the left of the Toolbar menu selection when it is turned on.

When the Toolbar is visible, you have shortcut access to a number of VEE programming and debugging functions such as opening a new VEE program file, opening an existing VEE program file, or beginning, pausing and stopping a VEE program's execution.

You can determine the function of a Toolbar button by positioning the mouse cursor over the button; a tool tip will appear below the button. A tool tip is a brief description of the button's function. Simultaneously, a description of the Toolbar button's function will also appear in the Status Bar which is located at the bottom of the VEE workspace.

Location

View [image] Toolbar

See Also

Status Bar.


To Printer

An object that sends data to a printer.

Use

Use To Printer to output data to a printer using a wide variety of encodings and formats.

To Printer Actions:

WRITE - Prints data using the specified encoding and format.

WAIT - Waits the specified number of seconds before executing the next transaction.

To Printer Encodings:

In almost all cases, you should use TEXT or CASE encoding to print data. Other encodings should be used by advanced users only.

TEXT - Writes all data types in human-readable form. VEE numeric data is automatically converted to text as it is written.

BYTE - Converts numeric data to binary integer and writes the least significant byte.

CASE - Maps an enumerated value or an integer to a string and writes the string. For example, you could use CASE to accept error numbers and write error messages.

BINARY - Writes all data types in an machine-specific binary format.

BINBLOCK - Writes all VEE data types in binary files with IEEE 488.2 definite length block headers.

CONTAINER - Writes all data types in a machine-specific text format.

Open View Parameters

The open view shows the list of transactions to be executed.

Object Menu

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Print Trans - Prints the detailed dialog box that describes the currently highlighted transaction.

Properties

EolSequence - Specifies the characters sent at the end of WRITE transactions that use EOL ON. The entry in this field must contain zero or more ASCII characters surrounded by double quotes. Default is "\n".

ArraySeparator - Specifies the character string used to separate elements of an array written by WRITE TEXT transactions. The entry in this field must be surrounded by double quotes.

MultiFieldFormat group: Specifies the following two formatting styles for multi-field data types for WRITE TEXT transactions. The affected data types are Coord, Complex, PComplex, and Spectrum.

Data Only - Separates each multi-field item with a comma without surrounding the group with parentheses. The complex number 2+2j would be formatted as 2,2.

(...) Syntax - (default) Separates each multi-field item with a comma and surrounds the group with parentheses. The complex number 2+2j would be formatted as (2,2).

ArrayFormat group: Determines how multidimensional arrays are formatted.

Linear - Arranges array elements linearly.

Block - (default) Arranges array elements in a block of two or more dimensions using the EOL character at the end of each row.

Notes

If you are printing using a WRITE TEXT transaction, To Printer cannot print ASCII text with embedded control characters. Use the To File object instead, and in the file name text field, enter a port name such as LPT1.

To configure the destination printer, use Print Setup.

When the first To Printer object in a program operates, it starts a print job. The print job is shared by all To Printer objects in the program, therefore their output appears in sequence on the same printout.

The print job remains open until PostRun, or until an EXECUTE CLOSE transaction is executed or the End Job control input on any To Printer is activated. PostRun occurs when all the threads in a program complete execution or when you press Stop twice. You access the End Job control input pin by way of the Add Control Input selection in the object menu.

Short Cuts

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Location

I/O [image] To [image] Printer

See Also

Default Preferences, Formula, To, and To File.

To Send Data to a Printer

Refer to the manual, VEE Advanced Techniques, in the chapter titled, "Using Transaction I/O".


To String

An object that uses transactions to write formatted text to a string.

Use

Use To String to create formatted text using transactions.

If only one string is generated by the To String transactions, the output container is a string scalar. When more than one string is generated, the output container is an Array 1D.

WRITE transactions ending with "EOL ON" will terminate the current output string, causing the next transaction in the To String list to write data to the next array element in the output container. You cannot specify the data format's separator sequence for the End Of Line (EOL) property.

WRITE Transactions ending with "EOL OFF" will not terminate the output string, causing the characters generated by the next WRITE transaction in the To String list to be appended to the end of the current output string. The last transaction in the To String list will always terminate the output string, regardless of that transaction's "EOL" mode.

To String Actions:

WRITE - Writes data using the specified encoding and format.

WAIT - Waits the specified number of seconds before executing the next transaction.

To String Encodings:

In almost all cases, you should use TEXT encoding to write data.

TEXT - Writes all data types in human-readable form. VEE numeric data is automatically converted to text as it is written.

BYTE - Converts numeric data to binary form and writes the ASCII text equivalent that maps to the least significant byte. For example, the following transaction writes the character A (ASCII 65 decimal):

WRITE BYTE 65

CASE - Maps an enumerated value or an integer to a string and writes the string. For example, you could use CASE to accept error numbers and write error messages.

Open View Parameters

The open view shows the list of transactions to be executed.

Object Menu

Add Trans - Adds a transaction to the end of the list.

Insert Trans - Inserts a transaction before the currently highlighted transaction.

Cut Trans - Cuts (deletes) the currently highlighted transaction, but saves it in the transaction "cut-and-paste" buffer.

Copy Trans - Copies the currently highlighted transaction to the transaction "cut-and-paste" buffer.

Paste Trans - Pastes the transaction that had been previously "cut" or "copied".

Print Trans - Prints the detailed dialog box that describes the currently highlighted transaction.

EolSequence - Specifies the characters sent at the end of WRITE transactions that use EOL ON. The entry in this field must contain zero or more ASCII characters surrounded by double quotes. Default is "\n".

 ArraySeparator - Specifies the character string used to separate elements of an array written by WRITE TEXT transactions. The entry in this field must be surrounded by double quotes.

MultiFieldFormat group: Specifies the following two formatting styles for multi-field data types for WRITE TEXT transactions. The affected data types are Coord, Complex, PComplex, and Spectrum.

Data Only - Separates each multi-field item with a comma without surrounding the group with parentheses. The complex number 2+2j would be formatted as 2,2.

(...) Syntax - (default) Separates each multi-field item with a comma and surrounds the group with parentheses. The complex number 2+2j would be formatted as (2,2).

ArrayFormat group: Determines how multidimensional arrays are formatted.

Linear - Arranges array elements linearly.

Block - (default) Arranges array elements in a block of two or more dimensions using the EOL character at the end of each row.

Example

To String is a useful debug tool to explore how TEXT transactions operate. Connect a Logging AlphaNumeric display to the To String output terminal to immediately view the results.

Short Cuts

To quickly insert a transaction, place the cursor on a transaction. Press CTRL+O to insert a transaction over the transaction where you placed the cursor.

To quickly delete ("kill") a transaction, place the cursor on that transaction and press CTRL+K.

To paste a transaction from the "kill" buffer press CTRL+Y.

To quickly move to the next or previous transaction, press CTRL+N or CTRL+P respectively.

Location

I/O [image] To [image] String

See Also

Formula, To, and To File.

To Convert a Number into a String

In the manual, VEE Advanced Techniques, refer to the chapter titled, "Using Transaction I/O."


Type Conversion

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Type Conversion to access the following functions.

asClrType(x, t)
asComplex(x)
asCoord(x)
asInt16(x)
asInt32(x)
asPComplex(x)
asReal32(x)
asReal64(x)
asText(x)
asUInt8(x)
asVariant(x)
asVariantBool(x)
asVariantCurrency(x)
asVariantDate(x)
asVariantEmpty(x)
asVariantError(x)
asVariantNull(x)
isVariant(x)
isVariantBool(x)
isVariantCurrency(x)
isVariantDate(x)
isVariantEmpty(x)
isVariantError(x)
isVariantNull(x)
typeName(x)

Location: Device [image] Function & Object Browser

Type: Built-in Functions
Category: Type Conversion

See Also


UInt8

An object that outputs a constant 1-byte unsigned integer scalar or 1D array.

Use

Use UInt8 to set an integer constant or to get user input. Click on the entry field to enter a value.

Example

To use UInt8 as a prompt on a panel view, change the name of the UInt8 object to a prompt such as Enter the number of seconds to delay:. The user fills in the requested information in the entry field.

Type in the formula 12*24 into the UInt8 and it will calculate the result.

Properties

DataShape - Sets the initial data shape of the value(s) to be output with this object.

 ArraySize: - When 1D Array is selected, Size sets the length of the array.

 ArraySizeFixed - When this property is True, the array cannot have lines added or deleted. This selection is only available if 1D Array is selected.

 ShowArrayIndices - When this property is True, each line in the entry field is indexed. This selection is only available if 1D Array is selected. Default is True.

Wait for Input - When this property is True, the object does not operate until the object's value is changed. When the check box is not selected, the object operates as soon as any constraints are met, and the currently selected value is output. Default is False.

 AutoExecute - When this property is True, the object operates and starts the rest of the program when a value is selected. If the program is already running, Auto Execute is ignored. Default is False.

InitialValue - Specifies the value to be set. Default value is 0.

 InitializeAtPreRun - When this property is True, the InitialValue is set at PreRun time. Default is False.

 InitializeAtActivate - When this property is True, the Initial Value is set at Activate time. Default is False.

NumberFormat:

Global Format - Use the default format. Default is on.

Integer: - If Global Format is off, specify the number format for integer numbers to be displayed on this object. The choices are Decimal (e.g. 42), Octal (e.g. #Q52), Hexadecimal (e.g. #H2a), and Binary (e.g. #B00101010). Default is Decimal.

Notes

Initialize is most often used for initializing values inside a UserObject. The other method for setting initial values is the Default Value control pin available on most data constants.

Control inputs may be added for Default Value, Reset, Enable Editing, and Disable Editing.

The Default Value input allows you to programmatically change the current value(s). This input requires an integer value, either a Scalar or an Array 1D. The Constant is reconfigured to match the shape of the incoming data.

The Reset input allows you to programmatically set the value(s) to zero. If the Constant is configured as an Array 1D, all values are set to zero. The actual data on the Reset input is ignored.

The Enable Editing and Disable Editing inputs allow you to programmatically control whether the value can be changed in the object’s open view.

Note that the Initial Value field is always a scalar, even if UInt8 is configured to be an array.

Location

Data [image] Constant [image] UInt8

See Also

Alloc UInt8, Complex, Constant, Coord, Date/Time, Selection Control, Default Preferences, Int16, Int32, PComplex, Real32, Real64, Text, and Toggle Control.

To Use a Data Constant


UnBuild Complex

An object that outputs the real and imaginary components of a Complex number as Real64 numbers.

Use

Use UnBuild Complex to extract the real and imaginary components from a rectangular Complex number.

Notes

You can also get the components of a Complex number by using the re(x) and imag(x) functions or objects.

Even if inputs are mapped, the outputs are not.

Location

Data [image] UnBuild Data [image] Complex

See Also

Build Complex, UnBuild Data, UnBuild PComplex, and Properties (Object)


UnBuild Coord

An object that outputs the values of a Coord as Real64 numbers.

Use

Use UnBuild Coord to extract the x, y, z ... values of a Coord data type. Additional outputs can be added for the z and other coordinate dimensions. The number of outputs must match the number of coordinate dimensions of the input data.

Location

Data [image] UnBuild Data [image] Coord

See Also

Build Coord, UnBuild Data, and Properties (Object)


UnBuild Data

A menu item.

Use

Use UnBuild to access the following data type conversion objects:

Coord

Complex

PComplex

Waveform

Spectrum

Record

Location

Data [image] UnBuild Data

See Also

Access Array, Build Data, UnBuild Complex, UnBuild Coord, UnBuild PComplex, UnBuild Record, UnBuild Spectrum, and UnBuild Waveform.


UnBuild PComplex

An object that extracts the magnitude and phase components of a PComplex number and outputs them as Real64 numbers.

Use

Use UnBuild PComplex to extract the magnitude and phase components from a PComplex number.

Notes

You can also get the components of a PComplex number by using the mag(x) and phase(x) functions or objects.

Even if inputs are mapped, the output are not.

Location

Data [image] UnBuild Data [image] PComplex

See Also

Build PComplex, Default Preferences, UnBuild Complex, UnBuild Data, and Properties (Object)


UnBuild Record

An object that allows the user to unbuild a record and recover its components.

Use

Use UnBuild Record to extract the data components from a record (A, B, and so forth), and to obtain a Name List and Type List for those components.

The Name List output pin outputs a Text array of all the names of the input record field names.

The Type List output pin outputs a Text array of all the data types of the input record.

The A, B, etc. output pins output the individual data components unbuilt from the record.

Notes

You may add an arbitrary number of output pins to this object. Each output pin name must correspond to a name of a record field. Field names are not case sensitive (lowercase and uppercase letters are equivalent).

Note the distinctions between the UnBuild Record, SubRecord, Get Field, and From DataSet objects.

The UnBuild Record object has outputs for the Name List and Type List of the input record fields. The other (optional) outputs A, B, etc. of the UnBuild Record object return the same results as would multiple Get Field objects.

The Get Field object works like a Formula object, in that it uses dot syntax (A.B) to unbuild a record. Note that Get Field allows you to unbuild a record of records in one step by using an expression such as A.B.C. This process would require two UnBuild Record objects.

The SubRecord object differs from UnBuild Record and Get Field in that its output is always a record. The SubRecord device allows you to either include or exclude a list of fields from a record to form a subrecord.

From DataSet lets you read records from a file of records (a "data set") based on the constraints of a logical expression. For example, you could extract all records that have the value PASS in a record field.

Location

Data [image] UnBuild Data [image] Record

See Also

Build Record, From DataSet, Get Field, Record Constant, Set Field, SubRecord, To DataSet, and Properties (Object)

To Extract a Field from a Record


UnBuild Spectrum

An object that outputs the PComplex values and frequency range of a Spectrum.

Use

Use UnBuild Spectrum to extract an Array 1D of PComplex values and interval information from a Spectrum.

Open View Parameters

Start/Stop | Center/Span - Changes the values in the outputs that describe the frequency range of the Spectrum.

Location

Data [image] UnBuild Data [image] Spectrum

See Also

Build Spectrum, UnBuild Data, UnBuild Waveform, and Properties (Object)


UnBuild Waveform

An object that outputs the amplitude values and time span of a Waveform.

Use

Use UnBuild Waveform to extract an Array 1D of the amplitude values and a real value for the time span from a Waveform.

Notes

The Real64 array output will be unmapped.

Location

Data [image] UnBuild Data [image] Waveform

See Also

Build Waveform, UnBuild Data, UnBuild Spectrum, and Properties (Object)


Unpack (Object Menu)

A menu selection, found only in the object menu for a UserObject, which "unpacks" the UserObject. The UserObject disappears, but the objects within it become part of the main context of the program.

Use

Use Unpack to remove a UserObject and place its contents into the main context of the program. Or in the case of a nested UserObject, to place its contents into the context of the UserObject in which the unpacked UserObject resided. The functionality within the UserObject is maintained because the objects that made it up retain their lines of connection within the new context.

Notes

Unpack is the reverse of Create UserObject. If you select objects and execute Create UserObject, those objects and their connections become part of the new UserObject. If you then execute Unpack on the UserObject, the objects are returned to the main context of the program, as if you had never created the UserObject.

Location

On the object menu (UserObjects only) [image] Unpack

See Also

Create UserObject and UserObject.


Until Break

An object that repeats execution of a subthread until a Break is encountered.

Use

Use Until Break to start a set of operations that is repeated until a Break is encountered.

Notes

Execution of the subthread hosted by the Until Break output continues until one of the following occurs:

All objects that can, have operated; the subthread is deactivated. The subthread is reactivated by refiring the Until Break output until a Break object is encountered.

A Break object operates. The subthread is deactivated and the sequence output pin is activated.

A Next object operates. The subthread is deactivated then reactivated by refiring the Until Break output until a Break object is encountered.

Until Break outputs an output execution signal that has a real value of zero.

When the subthread hosted by the Until Break object finishes an iteration, all data containers sent during the previous iteration are invalidated before the next iteration. This prevents "old" data from a previous iteration from being reused in the current iteration. However, if flow branching is present within the iterative subthread, some objects may not execute on every iteration. Thus, data containers sent by those objects may be invalidated before other objects can execute on the data. To obtain the desired propagation in this case, use the Sample & Hold object.

Location

Flow [image] Repeat [image] Until Break

See Also

Break, For Count, For Log Range, For Range, Next, On Cycle, Sample & Hold, and Properties (Object)

To Loop Part of a VEE Program


UserFunction

A user-defined function created from a UserObject or a group of selected objects.

Use

You can create a UserFunction by creating a UserObject and then executing Make UserFunction (refer to UserObject for details). You can also create a UserFunction by selecting a group of objects and using Edit [image] Create UserFunction....

You can use Edit UserFunction to edit the UserFunction once it has been created. UserFunctions exist in the "background" and can be called with Call Function or from certain expressions.

An advantage of making a UserFunction out of a UserObject is that the same UserFunction can be called multiple times within the program, but it exists as source code only in one place.

Object Menu

Edit [image] - A parent menu that leads to the UserFunction's context Edit menu. This menu contains the same choices as the main menu's Edit menu. You can get the pop-up Edit menu by clicking the right mouse button on the UserFunction work area.

The following choices are context sensitive to the UserFunction:

Clean Up Lines - Routes the lines in the UserFunction around objects.

Add To Panel - Creates a panel view for the UserFunction (if a panel view does not currently exist) containing the selected objects.

Create UserObject - Creates a UserObject of the currently selected objects.

Create UserFunction - Creates a UserFunction of the currently selected objects.

Cut - Deletes the UserFunction from VEE and from memory, placing it in the paste buffer. The UserFunction, with its contents, can be pasted into another VEE session. For Windows 98, NT, 2000, and XP, this also places an image of the UserFunction edit window, with its contents, on the Clipboard, ready to paste into other applications.

Copy - Copies the UserFunction to the paste buffer. The UserFunction, with its contents, can be pasted into another VEE session. For Windows 98, NT, 2000, and XP, this also places an image of the UserFunction edit window, with its contents, on the Clipboard, ready to paste into other applications.

Make UserObject - The opposite operation from Make UserFunction. Turns the UserFunction back into a UserObject.

Save Secured Version - Saves a version of the UserFunction which cannot be edited by the user. You will be prompted to enter the name of the secured version which will be saved with a .vee extension.

Locate - Highlights the location of the UserFunction in the Program Explorer.

Generate [image] - Creates one of the following objects containing an expression referencing the UserFunction title. You can place the generated object in another part of the program:

Call creates a Call object.

Formula Call creates a Formula object.

If/Then/Else Call creates an If/Then/Else object.

ShowPanel creates a Formula object with the ShowPanel() function.

HidePanel creates a Formula object with the HidePanel() function.

Calls - Opens the Find Results dialog box containing a list of other UserFunctions called by this UserFunction.

Called By - Opens the Find Results dialog box containing a list of other UserFunctions that call this UserFunction.

Create Panel - Creates a panel view of the UserFunction without any objects added to the panel.

Delete Panel - Deletes the panel view of the UserFunction along with any objects that were added to the panel. The objects deleted with the panel are not deleted from the detail view.

Close - Hides the UserFunction edit window. The UserFunction still resides in memory. You do not need to Close the UserFunction edit window before running the program.

Properties

TrigMode group:

Degrees | Radians | Gradians - specifies the default for trigonometric units used throughout this UserFunction.

 PopupPanelTitle: - Title to be displayed on the panel in the execution window.

 ShowPanelOnExecute - When this property is True, shows the panel view associated with the UserFunction when the UserFunction operates. Default is False.

 PopupMoveable - When this property is True, the pop-up panel is not movable by the user. Default is False.

 ShowPopupPanelTitle - When this property is True, the title bar on the pop-up panel is displayed. Default is True.

 ShowPopupPanelBorder - When this property is True, the border around the pop-up panel is displayed. Default is True.

Notes

You can create a library of UserFunctions by creating several UserFunctions, and then saving them all to a file. This library then can be imported into a program using Import Library, and deleted with Delete Library.

Not only can you call a UserFunction with Call Function, but you can call it from any expression whose evaluation is delayed until run time. These include expressions in various objects, such as Formula, If/Then/Else, and Set Values, and expressions in Sequencer and I/O transactions. However, the syntax of function calls in an expression allows only a single return value. Thus, a call to a UserFunction from such an expression will return only the value on the first output. If there are additional outputs (excluding the sequence output) their values will be dropped. If there are no outputs, the returned value will be undefined.

To find the name of a panel that is showing (via showPanel() or ShowPanelonExecute), click the right mouse button on the panel and the panel name will pop up.

Location

Select the UserFunction name from Edit [image] Edit UserFunction or

from a Call Function object menu [image] Edit UserFunction or

double click on the UserFunction name in the Program Explorer.

See Also

Call, Delete
 Library, Edit UserFunction, Formula,
 hidePanel(), If/Then/Else,
 Import Library, lockPosition(),
 panelPosition(), panelSize(),
 Sequencer, showPanel(),
 unlockPosition(), Remote
 Functions, and UserObject.

To Create a UserFunction from Objects in a Program

To Create a UserFunction in a Program


UserObject

An object that may contain other objects.

Use

Use UserObject to logically and physically group objects together. A UserObject constitutes a separate "context" from the root context of a program. You can use multiple UserObjects, or nested UserObjects within a program.

To create the desired UserObject, you can move other objects into the work area of the open view of the UserObject, or you can select objects and use Create UserObject from the Edit menu.

The Make UserFunction item in the object menu allows you to make the UserObject into a UserFunction, which can then be called using the Call Function object, or from certain expressions.

Operation:

A UserObject operates just like any other object -- no objects inside of a UserObject operate until all data inputs to the UserObject are activated. All operations inside of the UserObject must be completed before the data outputs are activated.

When objects inside the UserObject are connected to objects outside the UserObject, input and output pins are automatically created when Create UserObject is selected. To add input and output pins to existing UserObjects, use Add Terminal [image] from the object menu.

Creating a UserFunction:

Once you have created a UserObject, you can use Make UserFunction (see "Object Menu," below) to create a UserFunction with the same functionality. The UserObject will disappear from the screen and will be replaced with a Call Function object containing a call to the new UserFunction and the new UserFunctions window. The UserFunction will be added to the list of available User Functions, which exists in the "background" within the program. You can call the UserFunction using the Call Function object, or from certain expressions. You can edit the UserFunction by using Edit UserFunction in the Edit menu.

Object Menu

You can select the object menu of the UserObject from the object menu button, but you cannot select it from within the work area of the UserObject open window. From within the window, the right mouse button provides a pop-up Edit menu, just like the one available in the main window. When the pointer is over an object within the UserObject, the right mouse button gives the object menu for that object. You can also get UserObject object menu by placing the pointer over the borders of the UserObject and clicking the right mouse button.

Edit [image] - A parent menu that leads to the UserObject context Edit menu. This menu contains the same choices as the main menu Edit menu. You can get the pop-up Edit menu by clicking the right mouse button on the UserObject work area.

The following choices are context sensitive to the UserObject:

Clean Up Lines - Routes the lines in the UserObject around objects.

Add To Panel - Creates a panel view (for the UserObject) containing the selected objects.

Create UserObject - Creates a UserObject of the currently selected objects.

Create UserFunction - Creates a UserFunction of the currently selected objects.

Maximize - Resizes the open window of the UserObject to occupy the entire VEE work area. Return to the previous open view size with Restore.

Cut - Deletes the UserObject from the program, placing it in the paste buffer. The UserObject and its contents can be pasted into another VEE session. For Windows 98, NT.2000, and XP, this places an image of the UserObject edit window, with its contents, on the Clipboard, ready to paste into other applications.

Copy - Copies the UserObject to the paste buffer. The UserObject, with all of its contents, can be pasted into another VEE session. For Windows 98, NT, 2000, and XP, this also places an image of the UserObject edit window, with its contents, on the Clipboard, ready to paste into other applications.

Make UserFunction - Converts the UserObject into a UserFunction. The UserObject will disappear from the work area and it is replaced with a Call Function object containing a call to the new UserFunction. Before you do this operation, enter a unique name into the title field. This name will become the UserFunction name, which will be the name by which Call Function or certain expressions can call the UserFunction. If the name is the original "UserObject" or is not unique, you will be prompted for a function name.

Unpack - Deletes the UserObject, but not the objects contained in it.

Save Secured Version - Saves a version of the UserObject which can not be modified by anyone. You will be prompted to enter the name of the secured version. This secured version will be saved with a .vee extension.

Locate - Highlights the location of the UserObject in the Program Explorer.

Calls - Opens the Find Results dialog box containing a list of UserFunctions called by this UserObject.

Create Panel - Creates a panel view of the UserObject without any objects added to the panel.

Delete Panel - Deletes the panel view of the UserObject along with any objects that were added to the panel. The objects deleted with the panel are not deleted from the detail view.

Close - Hides the UserObject edit window. The UserObject still exists as an icon in the program. You do not need to Close the UserObject edit window before running the program.

Properties

TrigMode group:

Degrees | Radians | Gradians - specifies the default for trigonometric units used throughout this UserObject.

PopUpPanelTitle: - Title to be displayed on the panel in the execution window.

ShowPanelOnExecute - When the check box is selected, shows the panel view associated with the UserObject when the UserObject operates. This is only available after the UserObject panel view has been created (using Create Panel). Default is False.

 PopupMoveable - When this property is True, the pop-up panel is not movable by the user. Default is False.

 ShowPopupPanelTitle - When this property is True, the title bar on the pop-up panel is displayed. Default is True.

 ShowPopupPanelBorder - When this property is True, the border around the pop-up panel is displayed. Default is True.

Notes

To create a UserObject of the currently selected objects, use Create UserObject.

It is convenient to save UserObjects of common functions (using Save Objects) to create a library of functions to be used again.

You can create a library of UserFunctions by creating several UserObjects, turning them into UserFunctions, and then saving them all to a file. This library then can be imported into a program using Import Library, and deleted with Delete Library.

To find the name of a panel that is showing (via ShowPanelonExecute), click the right mouse button on the panel and the panel name will pop up.

The panel view of a UserObject may be added to the Main panel view or the panel view of a UserObject that is a surrounding context. In other words, panels can be nested. When panels are added to parent panels, an exact duplicate of the source panel is generated. Whenever the source panel is modified, all duplicate panels are updated as well.

To add a UserObject panel to a parent panel, such as the Main panel:

1. After creating a UserObject and its panel, right-mouse click on the UserObject’s icon view to get its object menu.

2. Click on Restore to get the open view. It appears like a panel view. Do not delete this or you will delete the UserObject from the parent program.

3. Select the UserObject so it is highlighted.

4. Click on the Add To Panel toolbar button (Edit [image] Add To Panel). The UserObject appears in the parent panel.

Location

Device [image] UserObject

See Also

Add To Panel, Call, Create UserObject, Delete Library, Direct I/O, Edit UserFunction, Formula, If/Then/Else, Import Library, Create RunTime Version, Sequencer, and UserFunction.

To Create a UserObject from Objects in a Program

To Create a UserObject in a Program


Variable

A menu item.

Use

Use variable to access the following objects which set and get the values of variables.

Set Variable

Get Variable

Delete Variable

Declare Variable

Notes

A variable that is defined in one context of a program can be used in any other context within the program. For example, you can define a variable with a Set Variable object in the root context of the program, and then include a Get Variable to get that variable in a UserObject. You need to avoid name conflicts throughout the program:

If two or more Set Variable objects attempt to set the same variable (with the same name), the current value will be overwritten as each Set Variable executes. This may result in unexpected behavior if you are unaware that duplicate names exist.

If there is a data terminal variable with the same name as a variable, the data terminal variable will take precedence.

For further information, refer to " Variables " in the VEE Advanced Techniques manual.

Location

Data [image] Variable

See Also

Default Preferences, Declare Variable, Delete Variable, Get Variable, Set Variable, View Variables.

To Create a Variable

To Delete a Variable

To Use a Variable


Variant

Use

The Variant data type is not a distinct data type. It is used in expressions to indicate that the value it represents can be one of a number of other data types. It is the data type it holds at the moment. Any data type can promote or demote to a Variant, and a Variant can promote or demote according to the data it holds and the rules that data would follow.

If this container is passed to an ActiveX Automation Server or Control, it will be translated as VT_VARIANT instead of the data type inside the Variant container. The Variant type is only needed if the ActiveX Automation method requires a parameter of type VT_VARIANT or ByRef VT_VARIANT.

Example

In the function sin(var), data in the Variant data type (var) could be an integer, a real, or a waveform, depending on the value it is assigned to.

In the expression a=sin(var), a will receive the data type that (var) contained.

Location

The only ways to create a Variant data type are:

Data [image] Variable [image] Declare Variable
and select type Variant; or

Use the asVariant() function.

See Also

asVariant(), Declare Variable.


Vertical Paddle

See Toggle Control.


Vertical Rocker

See Toggle Control.


Vertical Slide

See Toggle Control.


View Detail

Switches the view displayed from the panel view to the detail view.

Use

When pressed, View Detail shows the detail view of the program, UserObject, or UserFunction.

Notes

On UserObjects and UserFuntions, View Detail is only visible after you've created a panel view.

After you've secured a panel view, the View Detail button is not visible.

Location

The title bar of the main VEE window, UserObject, or UserFunction (when an associated panel has been created).

See Also

Add To Panel, View Panel, and Create RunTime Version.

To Add Objects to a Panel

To Delete Objects from a Panel


View Variables

A menu item that allows you to view the list of variables that are currently defined.

Use

Use View Variables to look at the type, shape, and data values of any currently defined variables. (This menu item is "grayed" if no variables exist.)

Notes

Before you may view any variables, one or more must have been created by running a program with one or more Set Variable objects.

All variables are deleted at the beginning of every Run, Start, or auto-execution, provided Delete Variables at PreRun is on. Variables are always deleted by either File [image] New or File [image] Open. Variable values are not saved with the program.

Location

View [image] Variables

See Also

Default Preferences, Delete Variable, Get Variable, and Set Variable.


View Panel

Switches the view displayed from the detail view to the panel view.

Use

When pressed, View Panel shows the panel view you created as an interface to your program on either the main VEE window, a UserObject, or UserFunction.

Notes

On UserObjects or UserFunctions, View Panel is only visible when you've created a panel view.

After you've secured a panel view, the View Panel button is not visible.

Location

The title bar of the main VEE window, UserObject, or UserFunction (when an associated panel has been created).

See Also

Add To Panel, View Detail, and Create RunTime Version.

To Add Objects to a Panel

To Delete Objects from a Panel


View Properties

A View menu item that turns the Properties window on or off.

Use

The Properties menu selection is a toggle function that determines whether or not the Properties window is displayed. When it is active, the Properties window is located to the left of the VEE workspace.

You can resize the width of the Properties window by hovering the mouse cursor over the vertical separation between the VEE workspace and the Properties window itself. When the mouse cursor changes shape to a vertical split cursor, press the left mouse button and drag the cursor right or left to increase or decrease the size of the window.

You can resize the height of the Properties window (if both Program Explorer and Properties are visible) by hovering the mouse cursor over the horizontal separator between the Program Explorer and the Properties windows.

The purpose of the Properties window is to show the programmer the properties for the object that is currently selected. With only rare exceptions, these properties are available for modification.

Location

View [image] Properties

See Also

Properties (Object)


Virtual Source

A menu item.

Use

Use Virtual Source to access the following virtual signal generators.

Function Generator

Pulse Generator

Noise Generator

Notes

Virtual Source objects output Waveforms.

Location

Device [image] Virtual Source

See Also

Build Arb Waveform, Function Generator, Instrument Manager, Noise Generator, and Pulse Generator.


Waveform (Time)

An object that displays time-domain information (waveforms) on a two-dimensional graphical display.

Use

Use Waveform (Time) to display Waveforms or Spectrums in the time domain. Spectrums are automatically converted to waveforms by way of an Inverse Fast Fourier Transform (ifft). The X axis is in the sampling units of the input waveform (typically, seconds).

Open View Parameters

These are the default open view parameters. Their use, and the availability of other parameters, is controlled by selections on the object menu and in the Properties dialog box (object menu [image] Properties).

Mag - The name of the Y axis.

Trace1 - The name of the first trace.

Time - The name of the X axis.

Object Menu

Auto Scale [image] - Clicking these menu items immediately rescales the display to show the entire trace. (Can be added as control pins, or set using the Scales properties tab to automatically rescale the display after data is collected.)

Auto Scale - Automatically scales both axes.

Auto Scale X - Automatically scales the X axis.

Auto Scale Y - Automatically scales the Y axis.

Zoom [image] - Scales the display.

In - Magnifies the display to contain only the rectangular region that you selected with the pointer. You select the region after selecting this feature by dragging on the graph area. This action outlines the information with a "rubber band" box.

Out 2|5|10|20|50|100X - Expands the scales of the display by a factor in both the X and Y directions about the center.

Clear Control [image] - Parameters that specify when to clear the display.

Display - Clears the displayed trace(s). This parameter may be added as a control input.

Next Curve - Resets the display the next curve in a family of curves (data from the next time the display operates) without clearing the previous curve. Next Curve must be selected (or activated) before each new curve in the family. This parameter may be added as a control input.

Center Markers - If markers are available, brings them to the center of the visible part of the trace. This is useful if you've scrolled the display and markers are not visible.

Add Right Scale - Adds up to two additional Y-axis scales to permit traces to have different scale ranges. After adding a right scale, you may add a terminal for its input (object menu [image] Add Terminal [image] Data Input). Then set its properties using the Traces and Scales tabs on the Properties dialog box.

Print - Presents the Print dialog box. Pressing OK prints a copy of the device's entire display on the selected output device. Print may be added as a control input.

Properties

Name - Assigns a variable name to the display. By entering a name, you can programmatically read marker values if they are turned on. The variable is an Object data type, and it is local to the context where the display exists. See Notes for details.

ClearAtPreRun - When this property is True, the display is cleared at PreRun time. Default is True.

 ClearAtActivate - When this property is True, the display is cleared at Activate time. Default is True.

ShowTracesLegend - In the open view, controls the visibility of the trace names and colors. Use EnableEditTracesAndScales to control the edit-button function of the trace legends. Default is True.

 ShowScalesLegend - In the open view, controls visibility of the scale names. Use EnableEditTracesAnd Scale to control the edit-button function of the scale legends. Default is True.

 ShowScaleLabels - In the open view, controls visibility of the values labeling the scale axes. Default is True.

 ShowScrollBars - In the open view, controls visibility of the scroll bars on the X and Y scales. Default is True.

 ShowAutoScaleButton - In the open view, controls visibility of the Auto Scale Button. Default is False.

EditTracesAndScales - In the open view, controls the edit-button function of the trace and scale properties. When enabled, click on an individual trace or scale name to edit its properties. Default is True. Use Show Traces Legend and Show Scales Legend to control visibility of the trace(s) and scale(s) names.

GridType category:

None - No grid lines are shown.

Tic Marks - Shows tic marks at the major and minor divisions on all four sides of the graph.

Axis - Shows tic marks at the major and minor divisions on the X and Y axes of the graph. If the actual axes are scrolled off the graph area, axis lines are drawn on the edge closest to the axes.

Lines - Shows lines at the major divisions and tic marks at the minor divisions. The X and Y axes are shown as thick lines.

NumMarkers category: - Allows you to find the exact value of a data point on the displayed curve. If the data is plotted on a log scale, the values shown on the marker are the linear data points.

To move markers to a different trace, click on the button to the left of the marker values near the bottom of the display. The button cycles through the different line types and colors of the different traces.

Off - No markers are shown. This selection is the default.

One - One marker is available.

Two - Two markers are available.

Delta - Two markers are available and the x and y differences between them are displayed.

 MarkerInterpolate - When the check box is selected, you can place markers between the displayed data points. The marker values displayed are calculated by linear interpolation. Default is False.

The default marker color is yellow.

DisplayBackColor - Allows you to select the color of the display area from a palette. You can select different colors when the display appears in the detail view and the panel view. The default Background color is set in Default Preferences on the Colors tab for Screen Element: Graph Background.

 Font - Allows you to select the font of the scale labels from the list of available fonts on your system. The default font for scale label text is set in Default Preferences on the Fonts tab for Screen Element: Graph Scale Label Text.

Traces category:

Name: - The name of the trace that is displayed to the left of the graph area and the name of the corresponding input terminal.

Color: - The color of the trace. Each added trace has a different color than the existing traces. Default for the first trace is yellow.

LineStyle: - The format of the line connecting data points. Default is a continuous line.

PointStyle: - The symbol that marks each data point. To show unconnected data points, select the single dot LineStyle format and the desired PointStyle symbol. Default is a dot.

Scales category:

Show Scale: - If you have multiple Y scales, a selection (using a check box) to specify if the end points and an axis of each additional right scale is displayed to the right of the graph area.

Scale Name: - The names of the scales appearing in the open view.

Automatic Scaling: - Controls whether the display automatically rescales to show the entire trace immediately after it receives data. Default is On. If this is turned Off, you can rescale the display by using the Auto Scale button on the General tab, in the Layout group, or the Auto Scale command on the object menu.

Maximum: - The maximum values of the scales.

Minimum: - The minimum values of the scales.

Label Spacing: - Controls which tic marks are labeled with the scale values. Default for X scale is Every Other Tic; default for Y scale(s) is Every Major Tic.

Mapping: - The way the x and y data is mapped to the display. The mapping may be linear or log. To make a log-log plot, change both X and Y axes to Log. Default is Linear.

Log Cycles: - The maximum number of decades shown (counting down from the maximum x and y values) when Automatic Scaling is on. Log Cycles is only used when the Mapping is Log. Log Cycles is useful when a trace contains a large dynamic range in the data. Default is 4.

Scale Color - The color of any background grid or tic marks. Default is Gray.

ScaleNumberFormat: (a group appears for the X and Y scales, and for any additional Y scales.)

Global Format - Use the default format. Default is on.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Sat 01/Jan/1994 17:01:38). Default is Standard.

The X and Y marker values take on the same number format as the scale to which they are attached. The delta marker values for X and Y use the default number format unless you use the Time Stamp format. Then, if both markers 1 and 2 on the X scale, or both markers on the Y scale are using the Time Stamp format, the delta marker values use the Delta Time format.

Notes

Inputs must be Scalar or Array 1D.

Input data of type Coord is plotted by simply using its x and y values without first being converted to type Waveform.

Add traces with the Add Terminal [image] Data Input object menu selection. Up to twelve traces are allowed.

When the AutomaticScaling property is True (Scales category), the program executes faster if a complete set of data is sent to the display. Then, the display automatically rescales once. If a program sends one data point at a time to the display, the display may automatically rescale after each data point, which will slow down program execution. In this case, use a Collector object to create an array, then send the array to the display.

Adding Control Inputs

You can add a Title control input pin, which sets the title bar name to the specified text value. This allows programmatic control over the title shown when the display is printed or plotted.

You can add a Traces control input pin. The control input data must be an array of records (or a record scalar if you only want to control one trace). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A field named TraceNum with an integer value (1 is the first trace). The TraceNum field is required. An error occurs if it is omitted.

One or more of the following fields:

Name

Pen

LineType

PointType

The Name field must have a text value. The Pen, LineType and PointType values must be integers from 0 to n, where 0 draws nothing and n is the number of choices available.

You can add a Scales control input pin to control the scales parameters listed above. The control input data must be an array of records (or a record scalar, if you only want to control one scale). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A Text field named Scale with a value X, Y (or Y1), Y2, or Y3. The Scale field is required. An error occurs if it is omitted.

One or more of the following fields:

Name - Changes the scale name in the open view. Must be a text value.

Min - Sets the X scale minimum. Must be an integer or real value.

Max - Sets the X scale maximum. Must be an integer or real value.

Mapping - Must have a text value of Linear or Log.

AutoScale - Controls automatic scaling. Must have a text value of On or Off.

Refer to "Using Records and DataSets" in VEE Advanced Techniques for further information.

Programmatically Setting and Reading Marker Values

You can programmatically get and set marker values. To prepare the display, open its Properties window. Enter a value for Name. The value for Name implicitly declares an Object variable that is local to the display’s context. Next, turn on a setting in the Markers group. VEE assigns the following properties to the markers’ X and Y positions, including the delta values. (Marker1 points down; Marker2 points up.)

Marker1X (gets the position as a Real64)

Marker1Y (gets the position as a Real64)

Marker2X (gets the position as a Real64)

Marker2Y (gets the position as a Real64)

MarkerDX (gets the position as a Real64)

MarkerDY (gets the position as a Real64)

Marker1 (gets/sets the position as a Coord)

Marker2 (gets/sets the position as a Coord)

The Marker1 and Marker2 properties can be used to read the current marker position or move the marker to a new position. All other marker properties are read-only. If you attempt to move the marker to a coordinate that is not on the trace, the marker will "snap" to the closest point that is on the trace.

In your program, enter one or more expressions in a Formula object to set or read the marker values. Each expression must contain the display Name and the marker property of interest. Marker property names are not case-sensitive. If the display’s Name is XY, and Delta Markers is turned on, the following expressions will read all the available marker values, assigning them to the variables a through f as Real64 scalars:

a = XY.Marker1X

b = XY.Marker1Y

c = XY.Marker2X

d = XY.Marker2Y

e = XY.MarkerDX

f = XY.MarkerDY

You can assign the display Name to a global variable. Add an assignment expression to your program in a Formula object, and declare the global using the Declare Variable object. As an example, assume you declared the variable globalXY as a global, and set its Type to Object. Then, in the context where the display exists, add this expression to your program:

Set globalXY = XY

This lets you read the display’s marker values from another context in the program using an expression such as:

a = globalXY.Marker1X

As you develop a program, you may want to include a way to pause the program so you can manually reposition the markers before the program reads their values. One way to pause a program is to add a Confirm (OK) button between the display’s sequence output and the Formula object’s sequence input. Alternately, you may want to position the markers programmatically.

Location

Display [image] Waveform (Time)

See Also

Complex Plane, Magnitude Spectrum, Polar Plot, Strip Chart, X vs Y Plot, XY Trace, and Default Preferences.

To Display a Waveform, To Set Markers in the Display, To Get and Set Marker Properties


What is IVI?

IVI (Interchangeable Virtual Instrument) is a new standard put forth by the IVI Foundation. More information can be found at http://www.ivifoundation.org. The IVI Foundation's goal is to create a driver standard that allows instrument interchangeability while still providing quality and high-performance. Interchangeability means you could write a program for an Arbitrary Waveform Generator (ARB) from Fluke and substitute an Agilent ARB and driver. Your program would still work because the IVI standard for ARB drivers requires ARBs from different manufacturers to support the same exact set of function calls. Of course, there are some limitations to interchangeability.

IVI-C versus IVI-COM

There are two types of drivers currently specified by the IVI Foundation. IVI-C drivers extend the VXIplug&play driver specification and their usage is similar. IVI-COM drivers are similar to ActiveX Controls. Therefore, while the driver functionality of these two is similar, the use model is quite different.

See Also

.NET and IVI Drivers


WhichOS()

An object that outputs the operating system on which Agilent VEE Pro is currently running.

Use

Use whichOS() to determine the operating system on which Agilent VEE Pro is running. Returns one of the following strings:

Windows_NT

Windows_98

Windows_2000

Windows XP

Examples

Agilent VEE Pro for Windows 98 on a PC: whichOS() returns Windows_98.

Notes

The whichOS() object is simply a Formula object initialized without inputs and containing the whichOS() equation. You may also type whichOS() into any other Formula object or expression.

Location

Device > Function & Object Browser

Type: Built-in Functions Category: System Information Member: whichOS

See Also

Formula, whichVersion().


whichVersion()

An object that outputs the version of VEE that is currently running.

Use

Use whichVersion() to determine the version of VEE that is running. This is the same string that appears in the Help [image] About dialog box.

Examples

For VEE version 3.2, whichVersion() returns the text string 3.2.

Notes

The whichVersion() object is simply a Formula object initialized without inputs and containing the whichVersion() equation. You may also type whichVersion() into any other Formula object or expression.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: System Information
Member: whichVersion

See Also

Formula and whichOS()


X vs Y Plot

X vs Y Print

An object that displays a Cartesian print.

Use

Use X vs Y Print to graphically display values when separate data information is available for X and Y data. When you print more than one trace, each execution of the X vs Y Print object uses the single X input data with each trace's Y input data, therefore all traces share the same X input data. If you want different X data values, you must build coordinates or mapped arrays for each trace and use the X-Y Trace object.

All inputs must be the same size and shape. Mapping information on the input's data is ignored.

Open View Parameters

These are the default open view parameters. Their use, and the availability of other parameters, is controlled by selections on the object menu and in the Properties dialog box (object menu [image] Properties).

Y name - The name of the Y axis.

YData1 - The name of the first trace.

X name - The name of the X axis.

Object Menu

Auto Scale [image] - Clicking these menu items immediately rescales the display to show the entire trace. (Can be added as control pins, or set using the Scales properties tab to automatically rescale the display after data is collected.)

Auto Scale - Automatically scales both axes.

Auto Scale X - Automatically scales the X axis.

Auto Scale Y - Automatically scales the Y axis.

Zoom [image] - Scales the display.

In - Magnifies the display to contain only the rectangular region that you selected with the pointer. You select the region after selecting this feature by dragging on the graph area. This action outlines the information with a "rubber band" box.

Out 2|5|10|20|50|100X - Expands the scales of the display by a factor in both the X and Y directions about the center.

Clear Control [image] - Parameters that specify when to clear the display.

Display - Clears the displayed trace(s). This parameter may be added as a control input.

Next Curve - Resets the display to the next curve in a family of curves (data from the next time the display operates) without clearing the previous curve. Next Curve must be selected (or activated) before each new curve in the family. This parameter may be added as a control input.

Center Markers - If markers are available, brings them to the center of the visible part of the trace. This is useful if you've scrolled the display and markers are not visible.

Add Right Scale - Adds up to two additional Y-axis scales to permit traces to have different scale ranges. After adding a right scale, you may add a terminal for its input (object menu [image] Add Terminal [image] Data Input). Then set its properties using the Traces and Scales tabs on the Properties dialog box.

Print - Presents the Print dialog box. Pressing OK prints a copy of the device's entire display on the selected output device. Print may be added as a control input.

Properties

Name - Assigns a variable name to the display. By entering a name, you can programmatically read marker values if they are turned on. The variable is an Object data type, and it is local to the context where the display exists. See Notes for details.

ClearAtPreRun - When this property is True, the display is cleared at PreRun time. Default is True.

ClearAtActivate - When this property is True, the display is cleared at Activate time. Default is True.

ShowTracesLegend - In the open view, controls the visibility of the trace names and colors. Use EnableEditTracesAndScales to control the edit-button function of the trace legends. Default is True.

ShowScalesLegend - In the open view, controls visibility of the scale names. Use EnableEditTracesAndScale to control the edit-button function of the scale legends. Default is True.

 ShowScaleLabels - In the open view, controls visibility of the values labeling the scale axes. Default is True.

 ShowScrollBars - In the open view, controls visibility of the scroll bars on the X and Y scales. Default is True.

 ShowAutoScaleButton - In the open view, controls visibility of the Auto Scale Button. Default is False.

 EnableEditTracesAndScales - In the open view, controls the edit-button function of the trace and scale properties. When enabled, click on an individual trace or scale name to edit its properties. Default is True. Use Show Traces Legend and Show Scales Legend to control visibility of the trace(s) and scale(s) names.

GridType category:

None - No grid lines are shown.

Tic Marks - Shows tic marks at the major and minor divisions on all four sides of the graph.

Axis - Shows tic marks at the major and minor divisions on the X and Y axes of the graph. If the actual axes are scrolled off the graph area, axis lines are drawn on the edge closest to the axes.

Lines - Shows lines at the major divisions and tic marks at the minor divisions. The X and Y axes are shown as thick lines.

Markers group: - Allows you to find the exact value of a data point on the displayed curve. If the data is plotted on a log scale, the values shown on the marker are the linear data points.

To move markers to a different trace, click on the button to the left of the marker values near the bottom of the display. The button cycles through the different line types and colors of the different traces.

NumMarkers:

Off - No markers are shown. This selection is the default.

One - One marker is available.

Two - Two markers are available.

Delta - Two markers are available and the x and y differences between them are displayed.

 MarkersInterpolate - When this property is True, you can place markers between the displayed data points. The marker values displayed are calculated by linear interpolation. Default is False.

DisplayBackColor - Allows you to select the color of the display area from a palette. You can select different colors when the display appears in the detail view and the panel view. The default Background color is set in Default Preferences on the Colors tab for Screen Element: Graph Background.

Scale Label Text - Allows you to select the font of the scale labels from the list of available fonts on your system. The default font for scale label text is set in Default Preferences on the Fonts tab for Screen Element: Graph Scale Label Text.

Traces group: (One per trace)

Name: - The name of the trace that is displayed to the left of the graph area and the name of the corresponding input terminal.

Color: - The color of the trace. Each added trace has a different color than the existing traces. Default color for the first trace is yellow.

LineStyle: - The format of the line connecting data points. Default is a continuous line.

PointStyle: - The symbol that marks each data point. To show unconnected data points, select the single dot LineStyle format and the desired PointStyle symbol. Default is a dot.

Scale - If it exists for more than one Y scale, choose which scale this Trace is scaled by.

Scales property: (one per X and Y scale and extra Y scales)

Show Scale: - If you have multiple Y scales, a selection (using a check box) to specify if the end points and an axis of each additional right scale is displayed to the right of the graph area.

Scale Name: - The names of the scales appearing in the open view.

Automatic Scaling: - Controls whether the display automatically rescales to show the entire trace immediately after it receives data. Default is on. If this is turned off, you can rescale the display by using the Auto Scale button on the General tab, in the Layout group, or the Auto Scale command on the object menu.

Maximum: - The maximum values of the scales.

Minimum: - The minimum values of the scales.

Label Spacing: - Controls which tic marks are labeled with the scale values. Default for X scale is Every Other Tic; default for Y scale(s) is Every Major Tic.

Mapping: - The way the x and y data is mapped to the display. The mapping may be linear or log. To make a log-log plot, change both X and Y axes to Log. Default is Linear.

Log Cycles: - The maximum number of decades shown (counting down from the maximum x and y values) when Automatic Scaling is on. Log Cycles is only used when the Mapping is Log. Log Cycles is useful when a trace contains a large dynamic range in the data. Default is 4.

Scale Color - The color of any background grid or tic marks. Default is Gray.

ScaleNumberFormat properties: (a group appears for the X and Y scales, and for any additional Y scales.)

Global Format - Use the default format. Default is on.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

The X and Y marker values take on the same number format as the scale to which they are attached. The delta marker values for X and Y use the default number format unless you use the Time Stamp format. Then, if both markers 1 and 2 on the X scale, or both markers on the Y scale are using the Time Stamp format, the delta marker values use the Delta Time format.

Notes

Inputs must be Scalar or Array 1D.

Add traces with the Add Terminal [image] Data Input object menu selection. Up to twelve traces are allowed.

When the AutomaticScaling property is True (Scales category), the program executes faster if a complete set of data is sent to the display. Then, the display automatically rescales once. If a program sends one data point at a time to the display, the display may automatically rescale after each data point, which will slow down program execution. In this case, use a Collector object to create an array, then send the array to the display.

Adding Control Inputs

You can add a Title control input pin, which sets the title bar name to the specified text value. This allows programmatic control over the title shown when the display is printed.

You can add a Traces control input pin. The control input data must be an array of records (or a record scalar if you only want to control one trace). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A field named TraceNum with an integer value (1 is the first trace). The TraceNum field is required. An error occurs if it is omitted.

One or more of the following fields:

Name

Pen

LineType

PointType

The Name field must have a text value. The Pen, LineType and PointType values must be integers from 0 to n, where 0 draws nothing and n is the number of choices available.

You can add a Scales control input pin to control the scales parameters listed above. The control input data must be an array of records (or a record scalar, if you only want to control one scale). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A Text field named Scale with a value X, Y (or Y1), Y2, or Y3. The Scale field is required. An error occurs if it is omitted.

One or more of the following fields:

Name - Changes the scale name in the open view. Must be a text value.

Min - Sets the X scale minimum. Must be an integer or real value.

Max - Sets the X scale maximum. Must be an integer or real value.

Mapping - Must have a text value of Linear or Log.

AutoScale - Controls automatic scaling. Must have a text value of On or Off.

Refer to "Using Records and DataSets" in VEE Advanced Techniques for further information.

Programmatically Setting and Reading Marker Values

You can programmatically get and set marker values. To prepare the display, open its Properties dialog box. Enter a value for Name. The value for Name implicitly declares an Object variable that is local to the display’s context. Next, turn on a setting in the Markers group. VEE assigns the following properties to the markers’ X and Y positions, including the delta values. (Marker1 points down; Marker2 points up.)

Marker1X (gets the position as a Real64)

Marker1Y (gets the position as a Real64)

Marker2X (gets the position as a Real64)

Marker2Y (gets the position as a Real64)

MarkerDX (gets the position as a Real64)

MarkerDY (gets the position as a Real64)

Marker1 (gets/sets the position as a Coord)

Marker2 (gets/sets the position as a Coord)

The Marker1 and Marker2 properties can be used to read the current marker position or move the marker to a new position. All other marker properties are read-only. If you attempt to move the marker to a coordinate that is not on the trace, the marker will "snap" to the closest point that is on the trace.

In your program, enter one or more expressions in a Formula object to set or read the marker values. Each expression must contain the display Name and the marker property of interest. Marker property names are not case-sensitive. If the display’s Name is XY, and Delta Markers is turned on, the following expressions will read all the available marker values, assigning them to the variables a through f as Real64 scalars:

a = XY.Marker1X

b = XY.Marker1Y

c = XY.Marker2X

d = XY.Marker2Y

e = XY.MarkerDX

f = XY.MarkerDY

You can assign the display Name to a global variable. Add an assignment expression to your program in a Formula object, and declare the global using the Declare Variable object. As an example, assume you declared the variable globalXY as a global, and set its Type to Object. Then, in the context where the display exists, add this expression to your program:

Set globalXY = XY

This lets you read the display’s marker values from another context in the program using an expression such as:

a = globalXY.Marker1X

As you develop a program, you may want to include a way to pause the program so you can manually reposition the markers before the program reads their values. One way to pause a program is to add a Confirm (OK) button between the display’s sequence output and the Formula object’s sequence input. Alternately, you may want to position the markers programmatically.

Location

Display [image] X vs Y Plot

See Also

Complex Plane, Magnitude Spectrum, Polar Plot, Strip Chart, Waveform (Time), XY Trace, and Default Preferences.

To Display XY Values, To Set Markers in the Display, To Get and Set Marker Properties


XY Trace

An object that displays a two-dimensional Cartesian plot.

Use

Use XY Trace to display mapped arrays or a set of values when y data is generated with evenly-spaced x values. An XY Trace is useful for a quick look at data when you don't need (or have) scaled x data values.

The x value that is automatically generated depends on the data type of the trace data. For example, if trace is a real value, the x values is 0, 1, 2, and so forth. If the trace is a Waveform, the x values are time values.

Open View Parameters

These are the default open view parameters. Their use, and the availability of other parameters, is controlled by selections on the object menu and in the Properties dialog box (object menu [image] Properties).

Y name - The name of the Y axis.

Trace1 - The name of the first trace.

X name - The name of the X axis.

Object Menu

Auto Scale [image] - Clicking these menu items immediately rescales the display to show the entire trace. (Can be added as control pins, or set using the Scales properties tab to automatically rescale the display after data is collected.)

Auto Scale - Automatically scales both axes.

Auto Scale X - Automatically scales the X axis.

Auto Scale Y - Automatically scales the Y axis.

Zoom [image] - Scales the display.

In - Magnifies the display to contain only the rectangular region that you selected with the pointer. You select the region after selecting this feature by dragging on the graph area. This action outlines the information with a "rubber band" box.

Out 2|5|10|20|50|100X - Expands the scales of the display by a factor in both the X and Y directions about the center.

Clear Control [image] - Parameters that specify when to clear the display.

Display - Clears the displayed trace(s). This parameter may be added as a control input.

Next Curve - Resets to display the next curve in a family of curves (data from the next time the display operates) without clearing the previous curve. Next Curve must be selected (or activated) before each new curve in the family. This parameter may be added as a control input.

Center Markers - If markers are available, brings them to the center of the visible part of the trace. This is useful if you've scrolled the display and markers are not visible.

Add Right Scale - Adds up to two additional Y-axis scales to permit traces to have different scale ranges. After adding a right scale, you may add a terminal for its input (object menu [image] Add Terminal [image] Data Input). Then set its properties using the Traces and Scales tabs on the Properties dialog box.

Print - Presents the Print dialog box. Pressing OK prints a copy of the device's entire display on the selected output device. Print may be added as a control input.

Properties

Name - Assigns a variable name to the display. By entering a name, you can programmatically read marker values if they are turned on. The variable is an Object data type, and it is local to the context where the display exists. See Notes for details.

ClearAtPreRun - When this property is True, the display is cleared at PreRun time. Default is True.

 ClearAtActivate - When this property is True, the display is cleared at Activate time. Default is True.

ShowTracesLegend - In the open view, controls the visibility of the trace names and colors. Use EnableEditTracesAndScales to control the edit-button function of the trace legends. Default is True.

 ShowScalesLegend - In the open view, controls visibility of the scale names. Use EnableEditTracesAndScales to control the edit-button function of the scale legends. Default is True.

 ShowScaleLabels - In the open view, controls visibility of the values labeling the scale axes. Default is True.

 ShowScrollBars - In the open view, controls visibility of the scroll bars on the X and Y scales. Default is True.

 Show Auto Scale Button - In the open view, controls visibility of the Auto Scale Button. Default is False.

 EnableEditTracesAndScales - In the open view, controls the edit-button function of the trace and scale properties. When enabled, click on an individual trace or scale name to edit its properties. Default is True. Use Show Traces Legend and Show Scales Legend to control visibility of the trace(s) and scale(s) names.

GridType category:

None - No grid lines are shown.

Tic Marks - Shows tic marks at the major and minor divisions on all four sides of the graph.

Axis - Shows tic marks at the major and minor divisions on the X and Y axes of the graph. If the actual axes are scrolled off the graph area, axis lines are drawn on the edge closest to the axes.

Lines - Shows lines at the major divisions and tic marks at the minor divisions. The X and Y axes are shown as thick lines.

Markers group: - Allows you to find the exact value of a data point on the displayed curve. If the data is plotted on a log scale, the values shown on the marker are the linear data points.

To move markers to a different trace, click on the open view on the button to the left of the marker values near the bottom of the display. The button cycles through the different line types and colors of the different traces.

Markers group:

Off - No markers are shown. This selection is the default.

One - One marker is available.

Two - Two markers are available.

Delta - Two markers are available and the x and y differences between them are displayed.

 MarkerInterpolate - When this property is True, you can place markers between the displayed data points. The marker values displayed are calculated by linear interpolation. Default is False.

 MarkerColor - Lets you change the marker color on the display.

BackColor - Allows you to select the color of the display area from a palette. You can select different colors when the display appears in the detail view and the panel view. The default Background color is set in Default Preferences on the Colors tab for Screen Element: Graph Background.

Scale Label group:

Text - Allows you to select the font of the scale labels from the list of available fonts on your system. The default font for scale label text is set in Default Preferences on the Fonts tab for Screen Element: Graph Scale Label Text.

Traces groups: One per trace.

Name - The name of the trace that is displayed to the left of the graph area and the name of the corresponding input terminal.

Color - The color of the trace. Each added trace has a different color than the existing traces. Default for the first trace is yellow.

Line Type - The format of the line connecting data points. Default is a continuous line.

Point Type - The symbol that marks each data point. To show unconnected data points, select the single dot Line Type format and the desired Point Type symbol. Default is a dot.

Scale - If it exists for more than one Y scale, choose which scale this Trace is scaled by.

Scales property (one per X and Y scale and extra Y scales)

Show Scale - If you have multiple Y scales, a selection (using a check box) to specify if the end points and an axis of each additional right scale is displayed to the right of the graph area.

Scale Name - The names of the scales appearing in the open view.

Automatic Scaling - Controls whether the display automatically rescales to show the entire trace immediately after it receives data. Default is on. If this is turned off, you can rescale the display by using the Auto Scale button on the General tab, in the Layout group, or the Auto Scale command on the object menu.

Maximum - The maximum values of the scales.

Minimum - The minimum values of the scales.

Label Spacing - Controls which tic marks are labeled with the scale values. Default for X scale is Every Other Tic; default for Y scale(s) is Every Major Tic.

Mapping - The way the x and y data is mapped to the display. The mapping may be linear or log. To make a log-log plot, change both X and Y axes to Log. Default is Linear.

Log Cycles - The maximum number of decades shown (counting down from the maximum x and y values) when Automatic Scaling is on. Log Cycles is only used when the Mapping is Log. Log Cycles is useful when a trace contains a large dynamic range in the data. Default is 4.

Scale Color - The color of any background grid or tic marks. Default is Gray.

ScaleNumberFormat properties: (a group appears for the X and Y scales, and for any additional Y scales.)

Global Format - Use the default format. Default is on.

Real: - If Global Format is off, specify the number format for real numbers to be displayed on this object. The choices are Fixed (e.g. 98.6000), Scientific (e.g. 9.8600E+01), Engineering (e.g. 98.6000E0), Standard (e.g. 98.6), and Time Stamp (e.g. Wed 01/Jan/2003 17:01:38). Default is Standard.

The X and Y marker values take on the same number format as the scale to which they are attached. The delta marker values for X and Y use the default number format unless you use the Time Stamp format. Then, if both markers 1 and 2 on the X scale, or both markers on the Y scale are using the Time Stamp format, the delta marker values use the Delta Time format.

Notes

Inputs must be Scalar or Array 1D that can be converted to type Real64. You must "unbuild" Complex, PComplex, and Spectrum data before inputting to an XY Trace.

Input data of type Coord is plotted by using its x and y values without first being converted to type Real64.

Add traces with the Add Terminal [image] Data Input object menu selection. Up to twelve traces are allowed.

When the AutomaticScaling property is True (Scales category), the program executes faster if a complete set of data is sent to the display. Then, the display automatically rescales once. If a program sends one data point at a time to the display, the display may automatically rescale after each data point, which can slow down program execution. In this case, use a Collector object to create an array, then send the array to the display.

Adding Control Inputs

You can add a Title control input pin, which sets the title bar name to the specified text value. This allows programmatic control over the title shown when the display is printed.

You can add a Traces control input pin. The control input data must be an array of records (or a record scalar if you only want to control one trace). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A field named TraceNum with an integer value (1 is the first trace). The TraceNum field is required. An error occurs if it is omitted.

One or more of the following fields:

Name

Pen

LineType

PointType

The Name field must have a text value. The Pen, LineType and PointType values must be integers from 0 to n, where 0 draws nothing and n is the number of choices available.

You can add a Scales control input pin to control the scales parameters listed above. The control input data must be an array of records (or a record scalar, if you only want to control one scale). Use a Record Constant or Build Record object to create an array of records; each record must have the following fields:

A Text field named Scale with a value X, Y (or Y1), Y2, or Y3. The Scale field is required. An error occurs if it is omitted.

One or more of the following fields:

Name - Changes the scale name in the open view. Must be a text value.

Min - Sets the X scale minimum. Must be an integer or real value.

Max - Sets the X scale maximum. Must be an integer or real value.

Mapping - Must have a text value of Linear or Log.

AutoScale - Controls automatic scaling. Must have a text value of On or Off.

Refer to "Using Records and DataSets" in VEE Advanced Techniques for further information.

Programmatically Setting and Reading Marker Values

You can programmatically get and set marker values. To prepare the display, open its Properties window. Enter a value for Name. The value for Name implicitly declares an Object variable that is local to the display’s context. Next, turn on a setting in the Markers group. VEE assigns the following properties to the markers’ X and Y positions, including the delta values. (Marker1 points down; Marker2 points up.)

Marker1X (gets the position as a Real64)

Marker1Y (gets the position as a Real64)

Marker2X (gets the position as a Real64)

Marker2Y (gets the position as a Real64)

MarkerDX (gets the position as a Real64)

MarkerDY (gets the position as a Real64)

Marker1 (gets/sets the position as a Coord)

Marker2 (gets/sets the position as a Coord)

The Marker1 and Marker2 properties can be used to read the current marker position or move the marker to a new position. All other marker properties are read-only. If you attempt to move the marker to a coordinate that is not on the trace, the marker will "snap" to the closest point that is on the trace.

In your program, enter one or more expressions in a Formula object to set or read the marker values. Each expression must contain the display Name and the marker property of interest. Marker property names are not case-sensitive. If the display’s Name is XY, and Delta Markers is turned on, the following expressions will read all the available marker values, assigning them to the variables a through f as Real64 scalars:

a = XY.Marker1X

b = XY.Marker1Y

c = XY.Marker2X

d = XY.Marker2Y

e = XY.MarkerDX

f = XY.MarkerDY

You can assign the display Name to a global variable. Add an assignment expression to your program in a Formula object, and declare the global using the Declare Variable object. As an example, assume you declared the variable globalXY as a global, and set its Type to Object. Then, in the context where the display exists, add this expression to your program:

Set globalXY = XY

This lets you read the display’s marker values from another context in the program using an expression such as:

a = globalXY.Marker1X

As you develop a program, you may want to include a way to pause the program so you can manually reposition the markers before the program reads their values. One way to pause a program is to add a Confirm (OK) button between the display’s sequence output and the Formula object’s sequence input. Alternately, you may want to position the markers programmatically.

Location

Display [image] XY Trace

See Also

Complex Plane, Magnitude Spectrum, Polar Plot, Strip Chart, Waveform (Time), X vs Y Plot, and Default Preferences.

To Display XY Values, To Set Markers in the Display, To Get and Set Marker Properties


abs(x)

An object that returns the absolute value of x.

Use

Use abs(x) to obtain the absolute value of the number in a container. x may be any shape and the same shape is returned. For types Complex, PComplex, and Spectrum, the absolute value is the magnitude of the complex number; therefore, a Real64 of the same shape is returned.

Allowed Input Type Return Type

UInt8 | UInt8
Int16 | Int16
Int32 | Int32
Real32 | Real32
Real64 | Real64
Coord | Coord
Waveform | Waveform
Complex | Real64 of the same shape
PComplex | Real64 of the same shape
Spectrum | Real64 of the same shape

Example

abs(-34) returns 34.

Notes

Mappings are retained in the result. The largest negative Int32 will cause an error.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Real Parts
Member: abs

See Also

Complex Parts, mag(x), Real Parts, and signof(x).


acos(x)

An object that returns the arccosine of x.

Use

Use acos(x) to generate the arccosine of the x data, with the result in the range of 0 to PI. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform
Complex | Complex
PComplex | PComplex
Spectrum | Spectrum

Example

acos(1) returns 0 with Trig Mode set to Degrees.

acos((1.54308, @0)) returns (0.9999, @1.87079) with Trig Mode set to Radians.

Notes

Mappings are retained in the result. Using Trig Mode set to anything except Radians may result in accuracy errors beyond the 12th significant digit.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: acos

See Also

acosh(x), cos(x), sin(x), tan(x), Trig, and Default Preferences.


acosh(x)

An object that returns the hyperbolic arccosine of x.

Use

Use acosh(x) to generate the hyperbolic arccosine of the x data. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform
Complex | Complex
PComplex | PComplex
Spectrum | Spectrum

Example

acosh(1) returns 0.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: acosh

See Also

acos(x), cosh(x), Trig, sinh(x), and tanh(x).


acot(x)

An object that returns the arccotangent of x.

Use

Use acot(x) to generate the arccotangent of the x data, simply returning atan(1/x). acot(0) will return PI/2. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform
Complex | Complex
PComplex | PComplex
Spectrum | Spectrum

The return value will be in the current Trig Mode units.

Example

acot(1) returns 45 with Trig Mode set to Degrees.

acot((1.31303, @PI/2)) returns (1.00, @-1.57079) with Trig Mode set to Radians.

Notes

Mappings are retained in the result. Using Trig Mode set to anything except Radians may result in accuracy errors beyond the 12th significant digit.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: acot

See Also

acoth(x), atan2(y,x), cos(x), sin(x), tan(x), Trig, and Default Preferences.


acoth(x)

An object that returns the hyperbolic arccotangent of x.

Use

Use acoth(x) to generate the hyperbolic arccotangent of the x data. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform
Complex | Complex
PComplex | PComplex
Spectrum | Spectrum

Example

acoth(1.5) returns 0.8047.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: acoth

See Also

acot(x), cosh(x), coth(x), Trig, sinh(x), and tanh(x).


a + b (add)

An object that performs an arithmetic addition on two operands.

Use

Use a + b to add the values of two containers. The two containers may be of any type and of any shape. If one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a container of the highest type with the same shape as the operands.

If both operands are of type Coord, they must have their independent variable(s) match exactly or an error is returned. The addition is only performed on the dependent (last) variable.

Text performs addition as a concatenation. Enums convert to Text for the addition. Note that this addition on two strings is not the same as the concat(x, y) function. With the concat function, concat("hello","there") yields a one-dimensional array, two long ["hello", "there"].

Example

Array plus a scalar: [1, 2, 3] + 3 returns [4, 5, 6].

Two Complex scalars: (2,4) + (1,3) returns (3,7).

Two arrays: [1, 2, 3] + [4, 5, 6] returns [5, 7, 9].

Two Coord scalars: coord(1,3) + coord(1,5) returns coord(1,8).

Two Coord scalars: coord(1,3) + coord(2,5) returns an error.

Two Text: "hello" + "there" returns "hellothere".

Notes

If either of the containers is mapped (that is, of type Waveform, Spectrum, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings. The return value will have the same mappings as the operands; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Arithmetic
Member: +

See Also

concat(x,y), a / b (divide), a * b (multiply), and a - b (subtract).


Ai(x)

An object used to calculate the Airy fractional order Bessel function of x.

Use

Use Ai(x) to find the Fractional order Bessel function Airy of the x. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

For Coord input types, the operation is done on the dependent variable.

Example

Ai(10) returns 0.110475325528986.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: Ai

See Also

Bi(x), j0(x), j1(x), jn(x,n), y0(x), y1(x), and yn(x,n).


a ~= b (almost equal to)

An object that performs an almost equal to operation on two operands.

Use

Use a ~= b to determine whether the value(s) of one container is equal to the value(s) of another container for the first seven decimal digits. The two containers may be of any type and of any shape. Integer, Enum and Text types will be compared exactly. If one of the containers is an array (or a record), the other must be either a scalar or an array (or a record) of the same size and shape. The result is a scalar Int32 with the value 0 or 1. If the first operand is almost equal to the second, the value of the result is 1; otherwise the value is 0.

The operation of X ~= 0 (zero) is meaningless in this context since zero has an infinite number of digits of precision and no order of magnitude. This requires that any comparison to zero match exactly. Therefore, comparing any value X to 0 (zero) will always return a 0 (false) unless X exactly equals 0.

Almost equal to does not perform the same comparison as Device [image] Comparator. The Comparator should be used when comparing waveforms or arrays which contain zeros. The Comparator can derive a value for "virtual zero" from the reference data's magnitude.

If both operands are of type Coord, they must have all their dependent variables match for the first seven decimal digits for the result to be 1. If independent variables do not match, an error is returned. Complex, PComplex, and Spectrum containers must have both parts almost match for the operation to return 1. Enums are converted to Text for the comparison.

Arrays must have all the respective values of both containers almost equal for the operation to return 1.

Example

Two scalars: 3.1234560 ~= 3.1234559 returns 1.

Two scalars: 3.1234560 ~= 3.1234459 returns 0.

A scalar and an array: 3.1234560 ~= [3.1234559, 3.1234562, 3.1234563] returns 1.

A scalar and an array: 3.1234560 ~= [3.1234459, 3.1234562, 3.1234569] returns 0.

Two Complex scalars: (2.12345,3.12345) ~= (2.12344,3.12345) returns 0.

Two Complex scalars: (2.1234567,3.12345) ~= (2.1234566,3.12345) returns 1.

Two Coord scalars: coord(1,3.123456) ~= coord(1,3.123446) returns 0.

Two Coord scalars: coord(1,3.123456) ~= coord(2,3.123456) returns Values for independent variables must match.

Notes

If either of the containers is mapped (that is, of type Waveform, Spectrum, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings; otherwise an error is returned.

The test for "almost equal to" is slightly different for Complex and Polar Complex numbers. For two real values (a and b) the test for "almost equal to" is:

a - b <= a * 10E-7

However, for two Complex values (a and b) the test is:

re(a) - re(b) <= mag(a) * 10E-7

where:

re(a) is the real component of a

re(b) is the real component of b

mag(a) is the vector magnitude of a

This test is used for both Complex and Polar Complex numbers to avoid any ambiguity regarding the rectangular or polar treatment of "almost equal."

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Comparison
Member: ~=

See Also

a AND b, a == b (equal to), a > b (greater than), a >= b (greater than or equal to), a < b (less than), a <= b (less than or equal to), NOT a, a != b (not equal to), a OR b, Comparison, and a XOR b.

Comparator, Conditional, and If/Then/Else.


a AND b

An object that performs a logical AND operation on two operands.

Use

Use a AND b to determine whether the value(s) of two containers are both logically true (non-zero). The two containers may be of any type and of any shape. If one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is an Int32 of the same shape as the operands, with value(s) 0 or 1. If both operands are non-zero, the value of the AND operation is 1; otherwise the value is 0.

If both operands are of type Coord, they must have their independent variable(s) match exactly or an error is returned. Only the dependent (last) variable is considered for the AND operation.

For Complex, PComplex, and Spectrum containers, the value of the operand is true if either part is non-zero. Text is true if non-null. Enums are converted to Text for the operation.

Example

A scalar and an array: 3 AND [3, 3, 3] returns [1, 1, 1].

A scalar and an array: 3 AND [-3, 0, 3] returns [1, 0, 1].

Two arrays: [1, 2, 3] AND [0, 1, (-1)] returns [0, 1, 1].

Two arrays: (1,@90) AND (1,@85) returns 1.

Two Complex scalars: (2,3) AND (0,1) returns 1.

Two Complex scalars: (0,1) AND (1,0) returns 1.

Two Complex scalars: (0,0) AND (0,0) returns 0.

Two Coord scalars: coord(1,3) AND coord(1,5) returns 1.

Two Coord scalars: coord(1,3) AND coord(2,3) returns an error.

A Text scalar and a scalar number: "too" AND 2 returns 1.

A Text scalar and a scalar number: "" AND 0 returns 0 because one string is null and the other is not ("0").

Notes

If either of the containers is mapped (that is, of type Waveform, Spectrum, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings. The return value will have the same mappings as the operands; otherwise an error is returned.

Note that the If/Then/Else object requires the expression(s) inside it to evaluate to either a scalar or an array, which is either all zeros or all ones.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Logical
Member: AND

See Also

NOT a, a OR b, Comparison, and a XOR b.

Conditional and If/Then/Else.


Arithmetic

A Category of Operators on the Function & Object Browser dialog box.

Use

Use the Arithmetic operators to access the following objects which perform arithmetic functions on two operands:

a + b

a - b

a * b

a / b

a ^ b

a MOD b

a DIV b

Notes

Dyadic operations, which are given two different types, convert the lower type to the higher of the two types. See the type conversion information and the hierarchy of types in help topic "Using Dyadic Operators".

In the dyadic operation example below, adding an array and a scalar performs the operation on each element of the array. The result is an array of the same size and shape as the array operand. For example, a scalar plus a linear array of four elements, 5 + [1, 2, 3, 6], produces the linear array of four elements [6, 7, 8, 11]. The same is true for operations like exponentiation. Thus, 2 ^ [3, 4] produces [8, 16].

Dyadic operations, which are given two arrays, require the operands to be conformant, that is, have the same size and shape. The result is an array with the same size and shape as the operands. The operation is done on an element by element basis. For example, adding two linear arrays of three elements each results in a linear array of three elements long. [1, 2, 3] + [4, 5, 6] produces [5, 7, 9]. If the two arrays are not conformant, the result is an error.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Arithmetic

See Also

a + b (add), a / b (divide), a div b (truncated division), a ^ b (exponent), a mod b (modulo), a * b (multiply), and a - b (subtract).


Array

A Category: of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Array to access the following objects which perform various functions on arrays.

init(x,val)

totSize(x)

rotate(x,numElem)

concat(x,y)

sum(x)

product(x)

sort(x)

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Array

See Also

concat(x,y), init(x,val),
 product(x), rotate(x, numElem),
 sort(x, direction, field), sum(x),
 and totSize(x).


asComplex(x)

An object that converts the x value to a Complex value.

Use

Use asComplex(x) to convert the x data to the data type Complex. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 | Complex
Int16 | Complex
Int32 | Complex
Real32 | Complex
Real64 | Complex
PComplex | Complex
Text | Complex

If x is a Text type, it must contain values that will convert to a Complex.

Example

asComplex(4.5) returns the Complex value (4.5, 0).

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asComplex

See Also

asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asCoord(x)

An object that converts the x value to a Coord value.

Use

Use asCoord(x) to convert the x data to the data type Coord. x must be a 1D array shape and will return the same shape as x. If the array is mapped, the Coord array will use the mappings to generate the x values. If the array is not mapped, the x value will be created starting at 0 and incrementing up by 1.

Allowed Input Type Return Type

UInt8 | Coord
Int16 | Coord
Int32 | Coord
Real32 | Coord
Real64 | Coord

Example

asCoord([4, 5]) returns the Coord array [(0,4), (1,5)].

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asCoord

See Also

asComplex(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asInt16(x)

An object that converts the x value to an Int16 value.

Use

Use asInt16(x) to convert the x data to the data type Int16. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Int16

Int16 Int16

Int32 Int16

Real32 Int16

Real64 Int16

Text Int16

If x is a Text type, it must contain values that will convert to an Int16.

Example

asInt16(4.5) returns the Int16 value 4.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asInt16

See Also

asComplex(x), asCoord(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asInt32(x)

An object that converts the x value to an Int32 value.

Use

Use asInt32(x) to convert the x data to the data type Int32. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Int32

Int16 Int32

Int32 Int32

Real32 Int32

Real64 Int32

Text Int32

If x is a Text type, it must contain values that will convert to an Int32.

Example

asInt32(4.5) returns the Int32 value 4.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asInt32

See Also

asComplex(x), asCoord(x), asInt16(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asPComplex(x)

An object that converts the x value to a PComplex value.

Use

Use asPComplex(x) to convert the x data to the data type PComplex. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 PComplex

Int16 PComplex

Int32 PComplex

Real32 PComplex

Real64 PComplex

Complex PComplex

Text PComplex

If x is a Text type, it must contain values that will convert to a PComplex.

Example

asPComplex(4.5) returns the PComplex value (4,5, @0).

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asPComplex

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asReal32(x)

An object that converts the x value to a Real32 value.

Use

Use asReal32(x) to convert the x data to the data type Real32. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real32

Int16 Real32

Int32 Real32

Real32 Real32

Real64 Real32

Text Real32

If x is a Text type, it must contain values that will convert to a Real32.

Example

asReal32("3.1415") returns the Real32 value 3.1415

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asReal32

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asReal64(x)

An object that converts the x value to a Real64 value.

Use

Use asReal64(x) to convert the x data to the data type Real64. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Text Real64

If x is a Text type, it must contain values that will convert to a Real64.

Example

asReal64("3.1415") returns the Real64 value 3.1415

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asReal64

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asText(x)

An object that converts the x value to a Text value.

Use

Use asText(x) to convert the x data to the data type Text. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Text

Int16 Text

Int32 Text

Real32 Text

Real64 Text

Coord Text

Waveform Text

Complex Text

PComplex Text

Spectrum Text

Text Text

Example

asText(3.4) returns the Text value "3.4".

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asText

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asUInt8(x)

An object that converts the x value to an Unsigned Int8 (byte) value.

Use

Use asUInt8(x) to convert the x data to the data type UInt8. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 UInt8

Int16 UInt8

Int32 UInt8

Real32 UInt8

Real64 UInt8

Text UInt8

If x is a Text type, it must contain values that will convert to a UInt8.

Example

asInt32(4.5) returns the UInt8 value 4.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asUInt8

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asVariant(x)

An object that converts "x" to the ActiveX Automation type Variant. Ensures that ActiveX Automation variants created from "x" are of type VT_VARIANT.

Use

Use this function when passing a VEE data container to an ActiveX control or server that requires a parameter of type VT_VARIANT.

Returns a VEE Variant data type. If the result from this function is assigned to a record field or an array element, its VT_VARIANT nature is lost. See following examples.

Allowed Input Type Return Type

UInt8 Variant

Int16 Variant

Int32 Variant

Real32 Variant

Real64 Variant

Text Variant

Example

Works:

A = asVariant(A);
Obj.method(ByRef A);

Array = asVariant(Array);

Does Not Work:

Obj.method(ByRef asVariant(A));

Array[0] = asVariant(A);

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asVariant

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asVariantBool(x)

Ensures that ActiveX Automation variants created from "x" are of type VT_BOOL (Boolean).

Use

Use this function when passing a VEE data container to an ActiveX control or server that requires a parameter of type VT_BOOL.

Returns a VEE Int16 data type, with a "hint" flag on the data container that it wants to be a Variant Bool. If this container is passed to an ActiveX Automation Server or Control, it will be translated as VT_BOOL instead of VT_I2. This "hint" flag is only needed if the ActiveX Automation method requires a parameter of type VT_BOOL or ByRef VT_BOOL.

If the result from this function is assigned to a record field or an array element, its VT_BOOL nature is lost. See following examples.

Examples

Works:

A = asVariantBool(A);
Obj.method(ByRef A);

Array = asVariantBool(Array);

Does Not Work:

Obj.method(ByRef asVariantBool(A));

Array[0] = asVariantBool(A);

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asVariantBool

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asVariantCurrency(x)

Ensures that ActiveX Automation variants created from "x" are of type VT_CY (Currency).

Use

Use this function when passing a VEE data container to an ActiveX control or server that requires a parameter of type VT_CY.

Returns a VEE Real64 data type, with a "hint" flag on the data container that it wants to be a Variant Currency. If this container is passed to an ActiveX Automation Server or Control, it will be translated as VT_CY. This "hint" flag is only needed if the ActiveX Automation method requires a parameter of type VT_CY or ByRef VT_CY.

If the result from this function is assigned to a record field or an array element, its VT_CY nature is lost. See following examples.

Examples

Works:

A = asVariantCurrency(A);
Obj.method(ByRef A);

Array = asVariantCurrency(Array);

Does Not Work:

Obj.method(ByRef asVariantCurrency(A));

Array[0] = asVariantCurrency(A);

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asVariantCurrency

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asVariantDate(x)

Ensures that ActiveX Automation variants created from "x" are of type VT_DATE.

Use

Use this function when passing a VEE data container to an ActiveX control or server that requires a parameter of type VT_DATE.

Returns a VEE Real64 data type, with a "hint" flag on the data container that it wants to be a Variant Date. If this container is passed to an ActiveX Automation Server or Control, it will be translated as VT_DATE. This "hint" flag is only needed if the ActiveX Automation method requires a parameter of type VT_DATE or ByRef VT_DATE.

If the result from this function is assigned to a record field or an array element, its VT_DATE nature is lost. See following examples.

Examples

Works:

A = asVariantDate(A);
Obj.method(ByRef A);

Array = asVariantDate(Array);

Does Not Work:

Obj.method(ByRef asVariantDate(A));

Array[0] = asVariantDate(A);

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asVariantDate

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantEmpty(x), asVariantError(x), asVariantNull(x).


asVariantEmpty(x)

Ensures that ActiveX Automation variants created from "x" are of type VT_EMPTY.

Use

Use this function when passing a parameter to an ActiveX control or server, and you want the parameter to be interpreted as VT_EMPTY.

Can only be used on scalars. Not valid for use with a ByRef parameter. Returns the same data type, with a "hint" flag on the data container that it wants to be a Variant Empty. If this container is passed to an ActiveX Automation Server or Control, it will be translated as VT_EMPTY instead of the container's true data type. This "hint" flag is only needed if the ActiveX Automation method requires a parameter of type VT_EMPTY.

If the result from this function is assigned to a record field or an array element, its VT_EMPTY nature is lost.

Example

A = asVariantEmpty(A);
Obj.method(A);

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asVariantEmpty

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantError(x), asVariantNull(x).


asVariantError(x)

Ensures that ActiveX Automation variants created from "x" are of type VT_ERROR.

Use

Use this function when passing a VEE data container to an ActiveX control or server that requires a parameter of type VT_ERROR.

Returns a VEE Int32 data type, with a "hint" flag on the data container that it wants to be a Variant Error. If this container is passed to an ActiveX Automation Server or Control, it will be translated as VT_ERROR. This "hint" flag is only needed if the ActiveX Automation method requires a parameter of type VT_ERROR or ByRef VT_ERROR. The return value represents the error number (scode).

If the result from this function is assigned to a record field or an array element, its VT_ERROR nature is lost. See following examples.

Examples

Works:

A = asVariantError(A);
Obj.method(ByRef A);

Array = asVariantError(Array);

Does Not Work:

Obj.method(ByRef asVariantError(A));

Array[0] = asVariantError(A);

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asVariantError

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantNull(x).


asVariantNull(x)

Ensures that ActiveX Automation variants created from "x" are of type VT_NULL.

Use

Use this function when passing a parameter to an ActiveX control or server, and you want the parameter to be interpreted as VT_NULL.

Can only be used on scalars. Not valid for use with a ByRef parameter. Returns the same data type, with a "hint" flag on the data container that it wants to be a Variant Null. If this container is passed to an ActiveX Automation Server or Control, it will be translated as VT_NULL instead of the container's true data type. This "hint" flag is only needed if the ActiveX Automation method requires a parameter of type VT_NULL.

If the result from the function is assigned to a record field or an array element, its VT_NULL nature is lost.

Example

A = asVariantNull(A);
Obj.method(A);

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: asVariantNull

See Also

asComplex(x), asCoord(x), asInt16(x), asInt32(x), asPComplex(x), asReal32(x), asReal64(x), asText(x), asUInt8(x), asVariant(x), asVariantBool(x), asVariantCurrency(x), asVariantDate(x), asVariantEmpty(x), asVariantError(x).


asin(x)

An object that returns the arcsine of x.

Use

Use asin(x) to generate the arcsine of the x data with the result in the range of -PI/2 to +PI/2 for Real values. The return value will be in the current Trig Mode units. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

asin(1) returns 90 with Trig Mode set to Degrees.

asin((1.1752012, @90)) returns (1, @90) with Trig Mode set to Degrees.

Notes

Mappings are retained in the result. Using Trig Mode set to anything except Radians may result in accuracy errors beyond the 12th significant digit.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: asin

See Also

asinh(x), cos(x), sin(x), tan(x), Trig, and Default Preferences.


asinh(x)

An object that returns the hyperbolic arcsine of x.

Use

Use asinh(x) to generate the hyperbolic arcsine of the x data. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

asinh(0) returns 0.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: asinh

See Also

asin(x), cosh(x), Trig, sinh(x), and tan(x).


Assignment

A formula-type object that allows you to assign values to Local or Global variables, or assign values to part of an array or record.

Use

Use an Assignment object to assign values to Local or Global variables, or to change the value of part of an array or record. The Result output terminal on the Assignment object will contain only the newly assigned value of the Local or Global variable, or it will contain that part of the array or record that changed. For example, when using an Assignment operator such as, a[2]=4, the Result terminal would contain a[2] (which is the value, 4). It would not contain all of a. To get all of a, add an output terminal named, a.

Notes

When you have selected Category: Assignment, the Member column of the Function & Object Browser dialog box will display a variety of Assignment examples. Clicking on one of these examples will bring up a VEE object pre-loaded with that Assignment formula. The example objects include:

a[2,*,5:6,4]=b - An Assignment object to modify part of a complicated array.

a[2]=b - An Assignment object to modify part of an array.

globalA=2*b+3 - An Assignment object to modify a global/variable (to do a Set Variable).

rec.field=b - An Assignment object to modify part of a record.

rec.field[2]=b - An Assignment object to modify part of a field of a record.

rec[2].field=b - An Assignment object to modify part of an array of records.

tmp=a, a=b, b=tmp - An Assignment object to swap values using a local.

tmp=a[2], a[2]=a[3], a[3]=tmp - An Assignment object to swap values in an array, using a local.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Assignment

See Also

Function & Object Browser

To Change Values in an Array

Using Assignment Operations


atan(x)

An object that returns the arctangent of x.

Use

Use atan(x) to generate the arctangent of the x data, with the result in the range of -PI/2 to +PI/2 for Real values. The return value will be in the current Trig Mode units. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

atan(1) returns 45 with Trig Mode set to Degrees.

atan((1.5574, @0)) returns (0.999, @0) with Trig Mode set to Radians.

Notes

Mappings are retained in the result. Using Trig Mode set to anything except Radians may result in accuracy errors beyond the 12th significant digit.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: atan

See Also

atanh(x), atan2(y,x), cos(x), sin(x), tan(x), Trig, and Default Preferences.


atan2(y,x)

An object that returns the arctangent of y divided by x.

Use

Use atan2(y,x) to generate the arctangent of y divided by x, with the proper sign, in the range of -PI to +PI for Real values. If one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a container of the highest type, with the same shape as the operands. x and y are assumed to be in the current Trig Mode units. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

atan2(1, -1) returns 135 with Trig Mode set to Degrees.

atan2((1, 1), (5, 5)) returns (0.19739, 0) with Trig Mode set to Radians.

Notes

Mappings are retained in the result. Using Trig Mode set to anything except Radians may result in accuracy errors beyond the 12th significant digit.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: atan2

See Also

atan(x), cos(x), sin(x), tan(x), Trig, and Default Preferences.


atanh(x)

An object that returns the hyperbolic arctangent of x.

Use

Use atanh(x) to generate the hyperbolic arctangent of the x data. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

atanh(0.5) returns 0.5493.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: atanh

See Also

atan(x), cosh(x), sinh(x), and tanh(x).


bartlet(x)

An object used to apply a Bartlet window to a time series of values.

Use

Use bartlet(x) to filter the values in x in the same manner as convolving x with the spectral transform of the Bartlet function. This has the effect of suppressing some of the noise due to the tails of the input sequence and the potential discontinuities they represent when sampling periodic signals.

The input x must be an Array 1D.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Spectrum Spectrum

If x is a Spectrum, it is first converted to a Waveform using an ifft(x) before the window is applied. The result of the window is then converted back to type Spectrum using an fft(x).

Example

bartlet([1, 1, 1, 1, 1, 1, 1, 1]) returns
[0.125, 0.375, 0.625, 0.875, 0.875, 0.625, 0.375, 0.125].

Notes

The Bartlet function in the time domain is represented as 2*(n+0.5)/N, where n is the position (index) in the array, and N is the size of the array. The result will be an array of the same type as x and will have the same mappings as x (if any).

For a discussion of sidelobe levels and coherent gains, see: Ziemer, Tranter, and Fannin, Signals and Systems, Macmillan Publishing, New York, NY, 1983. ISBN #0-02-431650-4.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Signal Processing
Member: bartlet

See Also

blackman(x), convolve(a,b), fft(x), hamming(x), hanning(x), ifft(x), and rect(x).


baseName()

baseName(str)

An object that returns the file name portion of a file path string.

Use

Use baseName() to isolate the file name found at the end of a directory/file path.

For example, if pathStr is:

c:\Program Files\Agilent\VEE Pro 7.0\examples\apps\chaos.vee

then baseName(pathStr) returns chaos.vee.

Both forward slash ( / ) and backslash ( \ ) are treated as delimiter characters after directory (folder) names. If the entire pathStr contains only one name, that name is considered a file name.

Notes

The baseName() object is simply a Formula object initialized with one input and containing the baseName() equation. You may also type baseName() into any other Formula object or expression.

Location

Device [image] Function & Object Browser

Type: Built-in Functions
Category: System Information
Member: baseName

See Also

dirName(), Formula


Bessel

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Bessel to calculate the bessel function of input data.

i0(x)

i1(x)

j0(x)

j1(x)

jn(x,n)

k0(x)

k1(x)

y0(x)

y1(x)

yn(x,n)

Ai(x)

Bi(x)

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel

See Also

i0(x), i1(x), j0(x), j1(x), jn(x,n), k0(x), k1(x), y0(x), y1(x), yn(x,n), Ai(x), and Bi(x).


beta(x,y)

An object used to calculate the beta function of the input (x,y).

Use

Use beta(x,y) to calculate the beta function on x. The beta function is defined as the:

( gamma(x) * gamma(y) ) / gamma(x+y)

The x and y values must be positive.

The x input may be of any shape and size. The second y parameter must be of the same type or be able to be converted to the same type as the x input value. If both of the inputs are arrays, they must be of exactly the same shape and size. The same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Example

beta(3, 1) returns 0.333333333333333.

beta(8, 7) returns 4.16250416250416E-05.

beta(-1, 3) returns an error.

Notes

If both of the inputs are mapped, then the mappings must be the same. The return value has the same mappings as the input if either input is mapped. If neither of the inputs is mapped, then the output is unmapped.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: beta

See Also

comb(n,r), factorial(n), gamma(x), and perm(n,r).


Bi(x)

An object used to calculate the B-Airy fractional order Bessel function of the second kind of x.

Use

Use Bi(x) to find the Fractional order Bessel function B-Airy of the second kind of x.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

For Coord input types, the operation is done on the dependent variable.

Example

Bi(1) returns 1.20742359495287.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: Bi

See Also

Ai(x), j0(x), j1(x), jn(x,n), y0(x), y1(x), and yn(x,n).


binomial(a,b)

An object used to calculate the number of combinations of a things taken b at a time.

Use

Use binomial(a,b) to calculate the number of combinations of a things taken b at a time using the formula:

binomial(a, b) = a!/((a-b)! * b!)

The ! symbol means factorial.

a can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

The second b parameter must be of the same type or be able to be converted to the same type as the a input value. If both of the inputs are arrays, they must be of exactly the same shape and size.

The binomial(a,b) operation is only defined for integer operands so the input numbers, while of unique type, are converted to Int32 type before the calculation is done.

Example

binomial(10,3) will return 120 as given by the formula:

10!/((10-3)!*3!) = 10!/(7!*3!) =(10*9*8)/(3*2*1) = 120.

binomial(10.4,3.9) will return 210 as given by the formula:

10!/((10-4)!*4!) = 10!/(6!*4!) = (10*9*8*7)/(4*3*2*1) = 210.

The rule about converting a real to Int32 forces 10.4 to 10 and 3.9 to 4.

Notes

a and b must both be positive and a must be greater than b.

This function is identical to comb(n,r).

If both of the inputs are mapped then the mappings must be the same. The return value has the same mappings as the input if either input is mapped. If neither of the inputs is mapped, then the output is unmapped.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: binomial

See Also

beta(x,y), comb(n,r), factorial(n), gamma(x), and perm(n,r).


bit(x,n)

An object that returns the binary value in a particular bit position.

Use

Use bit(x,n) to return the bit value in the nth position of x, with a value of zero or one. If x is of type Real32, Real64, Coord or Waveform, it is converted to Int32 before the operation. n must be a container that is, or can be converted to, Int32 and has a value between 0 and 31 inclusive. n must be either scalar or match the shape of x. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Int32

Real64 Int32

Coord Int32

Waveform Int32

Example

bit(9,0) returns 1 because the binary value of 9 is 1001 and the 0 bit is set.

Notes

The return value has the same mappings as x. Mappings on n are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bitwise
Member: bit

See Also

bits(str), Bitwise, clearBit(x,n), and setBit(x,n).


bitAnd(x,y)

An object that returns the Bitwise AND of x and y.

Use

Use bitAnd(x,y) to perform a binary AND on two containers. x and y can be any shape. But if both are arrays, the shape and sizes must match. If x or y are of type Real32, Real64, Coord or Waveform, they are converted to Int32 before the operation.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Int32

Real64 Int32

Coord Int32

Waveform Int32

Example

bitAnd(5, [3, 12]) returns [1, 4].

Notes

If any of the input parameters are mapped, then those mappings must be the same. The resultant container retains the mappings of the input container. If only one of the inputs is mapped, the resultant container has those mappings.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bitwise
Member: bitAnd

See Also

a AND b, bit(x,n), bitCmpl(x), bitOr(x,y), Bitwise, bitXor(x,y), NOT a, a OR b, and a XOR b.


bitCmpl(x)

An object that returns the Bitwise 1's complement of x.

Use

Use bitCmpl(x) to perform a binary 1's complement on a container. If x is of type Real32, Real64, Coord or Waveform, it is converted to Int32 before the operation. x may be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Int32

Real64 Int32

Coord Int32

Waveform Int32

Example

bitCmpl(7) returns -8.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bitwise
Member: bitCmpl

See Also

a AND b, bit(x,n), bitAnd(x,y), bitOr(x,y), Bitwise, bitXor(x,y), NOT a, a OR b, and a XOR b.


bitOr(x,y)

An object that returns the Bitwise OR of x and y.

Use

Use bitOr(x,y) to perform a binary OR on two containers. x and y can be any shape. But if both are arrays, the shapes and sizes must match. If x or y are of type Real32, Real64, Coord or Waveform, they are converted to Int32 before the operation.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Int32

Real64 Int32

Coord Int32

Waveform Int32

Example

bitOr(5, [3, 12]) returns [7, 13].

Notes

If any of the input parameters are mapped, then those mappings must be the same. The resultant container retains the mappings of the input container. If only one of the inputs is mapped, the resultant container has those mappings.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bitwise
Member: bitOr

See Also

a AND b, bit(x,n), bitAnd(x,y), bitCmpl(x), Bitwise, bitXor(x,y), NOT a, a OR b, and a XOR b.


bits(str)

An object that returns the binary value of a string of 0s and 1s.

Use

Use bits(str) to return an Int32 with the value of the digits in the Text str, converted to Int32 as base 2. str must be a Text container of any shape. str may only contain leading white space, then 0s and 1s to form a binary number.

Example

bits("011") returns 3.

Notes

The return value has the same mappings as the input container. The least significant bit is on the right, and the most significant bit is on the left.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bitwise
Member: bits

See Also

bit(x,n), Bitwise, clearBit(x,n), and setBit(x,n).


bitShift(x,y)

An object that returns x with the bits shifted left or right y places.

Use

Use bitShift(x,y) to shift the bits of container x by y places. x may be any shape. If x is of type Real32, Real64, Coord or Waveform, it is converted to Int32 before the operation. y must be a container which is or can be converted to Int32. If y is negative, the bits are shifted right; otherwise the bits are shifted left. y must be either scalar or match the shape of x. If y is greater than 31 or less than -31, the return value will be zero.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Int32

Real64 Int32

Coord Int32

Waveform Int32

Example

bitShift([1, 7, 7], [3, 2, (-2)]) returns [8, 28, 1].

bitShift(8,2) returns 32.

bitShift(8,-2) returns 2.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bitwise
Member: bitShift

See Also

bit(x,n), bitAnd(x,y),
 bitOr(x,y), Bitwise,
 bitXor(x,y), clearBit(x,n),
 rotate(x, numElem), and setBit(x,n).


Bitwise

A Category of Built-in Functions on the Function & Object Browser dialog box

Use

Use Bitwise to access the following objects which set, clear, access, or shift bits in an Int16 or Int32, or perform binary AND, OR, and XORs on Int16s or Int32s.

bit(x,n)

bits(str)

setBit(x,n)

clearBit(x,n)

bitAnd(x,y)

bitOr(x,y)

bitXor(x,y)

bitCmpl(x)

bitShift(x,y)

Notes

The objects on the Bitwise menu make sense only for the types Uint8, Int16 or Int32. But for ease of use, most of the objects accept most types, and will convert the arguments to Int32 before performing the function. This means that the values of Real32s, Real64s, Coords, and Waveforms are truncated inside the objects.

Bits are numbered from zero.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bitwise

See Also

bit(x,n), bits(str), bitAnd(x,y), bitCmpl(x),
 bitOr(x,y), bitShift(x,y),
 bitXor(x,y), clearBit(x,n),
 setBit(x,n), a AND b, NOT a, a OR b, Comparison,
 and a XOR b.


bitXor(x,y)

An object that returns the Bitwise XOR of x and y.

Use

Use bitXor(x,y) to perform a binary XOR (exclusive or) on two containers. x and y can be any shape. But if both are arrays, the shapes and sizes must match. If x or y are of type Real32, Real64, Coord, or Waveform, they are converted to Int32 before the bitXor().

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Int32

Real64 Int32

Coord Int32

Waveform Int32

Example

bitXor(5, [3, 12]) returns [6, 9].

Notes

If any of the input parameters are mapped, then those mappings must be the same. The resultant container retains the mappings of the input container. If only one of the inputs is mapped, the resultant container has those mappings.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bitwise
Member: bitXor

See Also

a AND b, bit(x,n), bitAnd(x,y), bitCmpl(x), bitOr(x,y), Bitwise, NOT a, a OR b, and a XOR b.


blackman(x)

An object used to apply a Blackman window to a time series of values.

Use

Use blackman(x) to filter the values in x in the same manner as convolving x with the spectral transform of the Blackman function. This has the effect of suppressing some of the noise due to the tails of the input sequence and the potential discontinuities they represent when sampling periodic signals.

The input x must be an Array 1D.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Spectrum Spectrum

If x is a Spectrum, it is first converted to a Waveform using an ifft(x) before the window is applied. The result of the window is then converted back to type Spectrum using an fft(x).

Example

blackman([1, 1, 1, 1, 1, 1, 1, 1]) returns
[0.014, 0.172, 0.555, 0.938, 0.938, 0.555, 0.172, 0.014].

Notes

The Blackman function is represented in the time domain as:

0.42 - 0.5*cos(2*PI*(n+0.5)/N) + 0.08*cos(4*PI*(n+0.5)/N)

where n is the position (index) in the array, and N is the size of the array. The result will be an array of the same type as x and will have the same mappings as x (if any).

For a discussion of sidelobe levels and coherent gains, see: Ziemer, Tranter, and Fannin, Signals and Systems, Macmillan Publishing, New York, NY, 1983. ISBN #0-02-431650-4.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Signal Processing
Member: blackman

See Also

bartlet(x), convolve(a,b), fft(x), hamming(x), hanning(x), ifft(x), and rect(x).


Calculus

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Calculus to take the integral or the derivative of a one-dimensional array of simple numeric values (integer, real, Waveform, ...) or lists of two-dimensional (two field) coordinates.

integral(x)

deriv(x,1)

deriv(x,2)

deriv(x,order)

defIntegral(x,a,b)

derivAt(x,1,pt)

derivAt(x,2,pt)

derivAt(x,order,pt)

Notes

The integral and derivative functions are applicable to one-dimensional arrays of simple numeric values (integer, real, Waveform, and so forth) and lists of two-dimensional (two field) coordinates which represent equally spaced ordered data. For unmapped arrays, it is assumed that the data is equally spaced and ordered, and a value of 1 is assumed for the interval dx between points. For mapped arrays, the operation is performed with the interval value dx equal to (Xmax-Xmin)/N and is thus automatically scaled appropriately. For a coordinate list, the independent (first field) values are first checked to be sure that they are ordered and equally spaced, then the operation is performed on the dependent (second field) values using the previously determined spacing as the value for dx.

If an unmapped array is used, but it is known otherwise that the interval between points is some value dx, then the correct value for the operation can still be obtained. For the integral, multiply the result by the known dx value. For the derivative, divide the result by the known dx value.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Calculus

See Also

defIntegral (x,a,b), deriv(x, order), derivAt(x, order,pt), and integral(x).


ceil(x)

An object that returns the rounded-up value of x to the nearest integer of a container.

Use

The ceil(x) function returns the smallest integer (as the same type) greater than or equal to x; that is, the value of x rounded to the next larger integer, the nearest integer towards positive infinity.

x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Coord

Waveform Waveform

Example

ceil([23.0, 23.1, 23.9, 23.5, (-23.5)]) returns [23, 24, 24, 24, -23].

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Real Parts
Member: ceil

See Also

abs(x), Complex Parts, floor(x), fracPart(x), intPart(x), Real Parts, and round(x).


charToInt(a)

An object that converts the first character of the input string into its decimal value.

Use

Use charToInt(a) to convert the first character of the ASCII input string a into its decimal value of type Int32. The allowed characters are those convertible to values within the range 0 through 255.

Examples

charToInt("A") returns 65.

charToInt("Arthur") also returns 65.

charToInt("a") returns 97.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String
Member: charToInt

See Also

intToChar(a), and String.


clearBit(x,n)

An object that returns x with the nth bit set to 0.

Use

Use clearBit(x,n) to set a particular binary digit of a container x to 0. x can be any shape. If x is of type Real32, Real64, Coord or Waveform, it is converted to Int32 before the operation. n must be a container which is, or can be converted to, Int32 and has a value between 0 and 31 inclusive. n must be either scalar or match the shape of x.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Int32

Real64 Int32

Coord Int32

Waveform Int32

Example

clearBit(7,1) returns 5 because the binary value of 7 is 111, and the first bit is cleared yielding 101 (decimal 5). (Bit numbering starts with 0.)

Notes

The mappings of the resultant container are the same as the x parameter.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bitwise
Member: clearBit

See Also

bits(str), bit(x,n), Bitwise, and setBit(x,n).


clipLower (x,a)

An object used to clip the input data x to a certain minimum value a.

Use

Use clipLower(x,a) to clip the data to a minimum value a, that is, any data that is less than a will be changed to a.

The x input may be of any size and shape. The clip parameter a must be of the same type, or be able to be converted to the same type, as the x input value and must either be Scalar in shape or the same shape and size as x. If one of the inputs is Scalar and one of the inputs is non-Scalar, the Scalar input is treated as if it were an array of the same shape and size as the non-Scalar input.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Coord

Waveform Waveform

Text Text

Example

Using the clipLower(x,.5) function on data, where x is the array [.1, .4, .6, .9], returns [.5, .5, .6, .9].

Using clipLower([.1, .4, .6, .9],[.2, .2, .7, .7]) returns [.2, .4, .7, .9].

You can use clipLower to clip the values of a Waveform to an arbitrary lower limit. Use an array of Coords to define the limiting points on the waveform. The limiting points are the endpoints of line segments that define the limiting waveform shape. There might be just a few of these points. Send the Coord array through the Build Arb Waveform object to create a lower limit waveform with the same number of points as your actual waveform. Send that new waveform into a clipLower function as the a input. When the clipLower(x,a) is done, the input waveform x will have all values below the lower limit clipped to the minimum allowed by the a input.

Notes

If both of the inputs are mapped, then the mappings must be the same. The return value has the same mappings as the input if either input is mapped. If neither of the inputs is mapped, then the output is unmapped.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Data Filtering
Member: clipLower

See Also

clipUpper (x,a), Build Arb Waveform, and Comparator.


clipUpper (x,a)

An object used to clip the input data x to a certain maximum value a.

Use

Use clipUpper(x,a) to clip the data to a maximum value a. That is, any data that is greater than a will be changed to a.

The x input may be of any size and shape. The clip parameter a must be of the same type, or be able to be converted to the same type, as the x input value and must either be Scalar in shape or the same shape and size as x. If one of the inputs is Scalar and one of the inputs is non-Scalar, the Scalar input is treated as if it were an array of the same shape and size as the non-Scalar input.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Coord

Waveform Waveform

Text Text

Example

Using the clipUpper(x,.5) function on data, where x is the array [.1, .4, .6, .9], returns [.1, .4, .5, .5].

Using clipUpper([.1, .4, .6, .9],[.2, .2, .5, .5]) returns [.1, .2, .5, .5].

You can use clipUpper to clip the values of a waveform to an arbitrary upper limit. Use an array of Coords to define the limiting points on the waveform. The limiting points are the endpoints of line segments that define the limiting waveform shape. Send the Coord array through the Build Arb Waveform object to create an upper limit waveform with the same amount of points as your actual waveform. Send that new waveform into a clipUpper function as the a input. When the clipUpper(x,a) is done, the input waveform x will have all values above the upper limit clipped to the maximum allowed by the a input.

Notes

If both of the inputs are mapped then the mappings must be the same. The return value has the same mappings as the input if either input is mapped. If neither of the inputs is mapped, then the output is unmapped.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Data Filtering
Member: clipUpper

See Also

clipLower (x,a), Build Arb Waveform, and Comparator.


cofactor(x, row,col)

An object used to calculate the cofactor of the input matrix x, at row r and column c.

Use

Use cofactor(x,row,col) to calculate the cofactor of the square matrix x. The cofactor of a matrix is defined as the determinant of the submatrix of the input matrix x obtained by deleting the rth row and cth column, times (-1) raised to the (r+c) power.

The x input must be a square matrix shape. The input for the row and column to delete, r and c, must be an Int32 Scalar or be able to be converted to Int32 type.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Complex Complex, Scalar in shape

PComplex PComplex, Scalar in shape

A square matrix has the same number of rows as columns.

Example

cofactor(a,1,2), where a is a matrix [ [3, -1, 2], [4, 5, 6], [7, 1, 2] ], returns 34.

Notes

Mappings on the operand are ignored.

The r and c inputs are expected to be of Int32 type or be able to be converted to that type. The rows and columns of the matrix are numbered from 0 to n-1. Therefore, be careful when specifying which row and column to use.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Matrix
Member: cofactor

See Also

det(x) and minor(x,row, col).


comb(n,r)

An object used to calculate the number of combinations of n things taken r at a time.

Use

Use comb(n,r) to calculate the number of combinations of n things taken r at a time using the formula:

comb(n, r) = n!/((n -r)! * r!)

The ! symbol means factorial.

The n input may be of any shape and size. The second r parameter must be of the same type or be able to be converted to the same type as the n input value. If both of the inputs are arrays, they must be of exactly the same shape and size.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

The comb(n, r) operation is only defined for integer operands so the input numbers, while of unique type, are converted to Int32 type before the calculation is done.

Example

comb(10,3) will return 120 as given by the formula:

10!/((10-3)!*3!) = 10!/(7!*3!) = (10*9*8)/(3*2*1) = 120

comb(10.4,3.9) will return 210 as given by the formula:

10!/((10-4)!*4!) = 10!/(6!*4!) = (10*9*8*7)/(4*3*2*1) = 210

The rule about converting a real to Int32 forces 10.4 to 10 and 3.9 to 4.

Notes

Both n and r must be positive and n must be greater than r.

If both of the inputs are mapped, then the mappings must be the same. The return value has the same mappings as the input if either input is mapped. If neither of the inputs is mapped, then the output is unmapped.

This function is identical to binomial(a,b).

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: comb

See Also

beta(x,y), binomial(a,b), factorial(n), gamma(x), and perm(n,r).


Comma Operator

The "," (comma) can be used in expressions as a dyadic operator. When the "," is used to separate two expressions, the left-hand expression is evaluated, but the result is discarded. The result of the right-hand expression is returned.

Use

Use the comma operator in a Formula object with the following syntax:

expression , expression

The "," ensures that the left-hand expression will be evaluated first, but the result will be discarded. Then the result of the right-hand expression is returned.

Example

UserFunc(A),A calls the function named UserFunc, discards the result, and then returns the value of A.

Location

Must be used within a Formula object or other object that takes an expression.

See Also

Triadic Operator.


commandLine()

An object that returns the command-line parameters used to initiate this VEE session.

Use

The return value is a 1D Text array. Index 0 of the array contains the VEE program name that was used to start the VEE session. Subsequent array elements (if any) are the parameters that followed the program name on the command line.

This function is useful when you want to use the VEE command line to pass parameters (options) to your VEE program. Options intended for the VEE environment itself are preceded by a single minus sign ( - ) on the command line. See To Start Agilent VEE with Command-Line Options. Options preceded by two minus signs are ignored by the VEE environment and are made available to the VEE program using the commandLine() object. For example:

vee.exe -maximize --radians My_Trig.vee

This command line starts VEE with a maximized window, loads the program My_Trig.vee, and lets that program to use the --radians option.

Notes

The commandLine() object is simply a Formula object initialized without inputs and containing the commandLine() equation. You may also type commandLine() into any other Formula object or expression.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: System Information
Member: commandLine

See Also

installDir, programName, Formula


Comparison

A Category of Operators on the Function & Object Browser dialog box.

Use

Use Comparison to access the following objects which perform comparison operations on two operands:

a ~= b

a == b

a != b

a < b

a > b

a <= b

a >= b

Notes

All of these operations return a scalar Int32 with the value of 0 or 1, which corresponds to whether the operation is true or false.

It is possible for two operands to not be comparable, that is, the two operands are not less than, greater than, or equal to each other. Examples are Coords with mismatched mappings and arrays. For example, [1, 2, 6] != [2, 3, 4] is true, but the two operands are neither less than nor greater than each other, they are simply not equal. That is, [1, 2, 6] < [2, 3, 4] is false, and [1, 2, 6] > [2, 3, 4] is false because each element in the first array is not < or > respectively to each element in the second array.

Also note the difference between items under Comparison and under the menu item Conditional. Comparisons are formulas which output 0 or 1. Conditionals are If/Then/Else and have two outputs, of which one activates.

Note that the return value is of type Int32 and is the same shape as the operands. This is different than the conditionals such as == that always return a scalar.

The logical operators are defined for type Text only in the sense of whether the string is null or not. That is, "zoo" AND "" (null string) is logically false since the second string is null. Remember that when comparing a Text type to a non-string type, the latter is promoted to a Text type. This means that "zoo" AND 0 is true since the real 0 is promoted to the string "0" and, since both strings are non-null, the AND expression is true, returning 1.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Comparison

See Also

a ~= b (almost equal to), a AND b, a == b (equal to), a > b (greater than), a >= b (greater than or equal to), a < b (less than), a <= b (less than or equal to), NOT a, a != b (not equal to), a OR b, and a XOR b.

Comparator, Conditional, and If/Then/Else.


Complex Parts

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Complex Parts to access the following objects which return different parts of Complex and PComplex containers.

j(x)

re(x)

im(x)

mag(x)

phase(x)

conj(x)

Notes

The objects on the Complex Parts menu make sense only for the type Complex and PComplex. But for ease of use, most of the objects accept and return most types.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Complex Parts

See Also

conj(x), im(x), j(x), mag(x), phase(x), re(x), and Real Parts.

Build Complex, Build PComplex, Complex, UnBuild Complex, and UnBuild PComplex.


concat(x,y)

An object used to concatenate containers.

Use

Use concat(x,y) to concatenate two containers. The input parameters can be of any type and any shape. The concat(x,y) function will flatten arrays that are greater than one dimension into an Array 1D. The resulting 1D arrays are then concatenated together. For x and y input of all types, a 1D container of the highest type is returned.

Example

If x is a real Scalar container with 3 in it, and y is a Text array container with ["This", "is", "a", "test"] in it, then concat(x,y) will return a Text array container ["3", "This", "is", "a", "test"]. In this case, the numeric 3 has been converted to the higher type Text string "3" before the concat operation.

Notes

If the x value is mapped, the y value may be either mapped with the same point spacing, or unmapped. The result will be mapped from Xmin to Xmin+dx*N, where Xmin is the minimum value of the x mapping, dx is the distance between two consecutive points in x, and N is the size of the resultant array.

Note the difference between the concat(x,y) and sum(x) functions on Text inputs. The concat(x,y) creates an Array 1D in all cases. The sum(x) function will simply link all the text strings together to form one large output string. That is, concat(x,y), where x is the Scalar Text value "a" and y is the Scalar Text input "b", yields the Array 1D ["a","b"]. On the other hand, sum(["a","b"]) will return the Scalar container with the text value of "ab" in it.

All nil inputs are automatically converted to Real64 scalars with the value 0. Thus, where x is nil and y is an Int32 scalar value 5, concat(x,y) results in the Array 1D two long of Real64 with values [0, 5]. In contrast, the Concatenator object with two inputs with nil and an Int32 scalar value 5 will output an Int32 array one long with value [5].

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Array
Member: concat

See Also

sum(x), and Concatenator.


conj(x)

An object that returns the complex conjugate of a Complex number x.

Use

Use conj(x) to generate the complex conjugate of a Complex number x. x can be any shape and of type Complex, PComplex, or Spectrum. The complex conjugate of a Complex number simply reverses the sign of the imaginary component. The complex conjugate of a PComplex number simply reverses the sign of the phase.

Example

conj( (2, 3) ) returns (2, -3).

conj( (8, @45) ) returns (8, @-45) with Trig Mode set to Degrees.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Complex Parts
Member: conj

See Also

im(x), j(x), mag(x), phase(x), re(x), Real Parts, Build Complex, Default Preferences, and UnBuild Complex.


convolve(a,b)

An object used to convolve two arrays of data.

Use

Use convolve(a,b) to calculate the discrete aperiodic convolution of two 1D arrays a and b. The result will be an array of the same type and of size (Na+Nb)-1, where Na is the size of input array a, and Nb is the size of input array b.

The input values a and b must be an Array 1D. a and b do not have to be the same size. The resultant values are not normalized.

Allowed Input Types Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Highest type of inputs

Waveform Highest type of inputs

Example

convolve([1, 2, 3, 4, 5],[1, 1, 1]) returns [1, 3, 6, 9, 12, 9, 5].

Notes

The inputs a and b must represent equally spaced data. In addition, the interval between any two values of a must be the same as that between any two values of b. For two unmapped arrays, it is assumed that the interval is always 1. For mapped arrays, the interval is (Xmax-Xmin)/N, where Xmax and Xmin are the mappings, and N is the size of the array. When one input is mapped and the other is not, the unmapped input is assumed to be sampled at the same frequency as the mapped input. The resultant values will never be normalized to any scale factor.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Signal Processing
Member: convolve

See Also

fft(x) and xcorrelate (a,b).


cos(x)

An object that returns the cosine of x.

Use

Use cos(x) to generate the cosine of the x data. x is assumed to be in the current Trig Mode units. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

cos([0, 180]) returns [1, -1] with Trig Mode set to Degrees.

cos((1, PI/4)) returns (0.715684, -0.73096) with Trig Mode set to Radians.

Notes

Mappings are retained in the result. Using Trig Mode set to anything except Radians may result in accuracy errors beyond the 12th significant digit.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: cos

See Also

acos(x), cosh(x), sin(x), tan(x), Trig, and Default Preferences.


cosh(x)

An object that returns the hyperbolic cosine of x.

Use

Use cosh(x) to generate the hyperbolic cosine of the x data. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

cosh(0) returns 1.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: cosh

See Also

acosh(x), cos(x), sinh(x), and tanh(x).


cot(x)

An object that returns the cotangent of x.

Use

Use cot(x) to generate the cotangent of the x data. x is assumed to be in the current Trig Mode units. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

cot([45, 90]) returns [1, 61E-18] with Trig Mode set to Degrees. Note that the second number, which should be zero, is smaller than the system precision.

cot((3, @PI/2)) returns (1.0049698, @-1.57079) with Trig Mode set to Radians.

cot((3, @90)) returns (1.0049698, @-90) with Trig Mode set to Degrees.

Notes

Mappings are retained in the result. Using Trig Mode set to anything except Radians may result in accuracy errors beyond the 12th significant digit.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: cot

See Also

acot(x), atan2(y,x), cos(x), coth(x), sin(x), tan(x), Trig, and Default Preferences.


coth(x)

An object that returns the hyperbolic cotangent of x.

Use

Use coth(x) to generate the hyperbolic cotangent of the x data. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

coth(0.4) returns 2.631.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: coth

See Also

acoth(x), cot(x), sinh(x), and tanh(x).


CreateObject

CreateObject(ProgID)

Creates a new instance of the ActiveX Automation object specified by ProgID and returns a reference to it.

Use

Use CreateObject to create an automation object in your program. You will need to modify the initial expression to perform the desired action. Most of the time, you want to create a new instance of an automation object in a new instance of a server application that VEE will control.

The ProgID of an object is a name (human-readable string) assigned by the person who wrote the automation object. It is typically a library or application name, a period, and a component or object name. To find the valid ProgIDs for any ActiveX Automation Server, consult the documentation supplied with that server.

CreateObject takes an optional second parameter that specifies the name of a remote host computer (server) on which to instantiate the object. This functionality requires DCOM to be installed on both the client and the server computers. The syntax is:

createObject( ProgID [, hostName ] )

where:

hostName must be of type Text, and can be specified as either a valid UNC or DNS domain name. Some examples of valid hostName specifications:

Set obj = createObject("lib.obj",
 "server")
Set obj = createObject("lib.obj", "\\\\server")
Set obj = createObject("lib.obj", "server.domain.com")
Set obj = createObject("lib.obj", "135.5.33.19")

Example

This example starts a new instance of Microsoft Excel (even if Excel is already running), and returns a reference to a new Worksheet object:

SET excel = CreateObject ("Excel.Sheet")

Releasing ActiveX References

If your VEE program uses an Automation Server (like Excel), you may notice that the Excel (or whatever) application does not always quit when your program ends. VEE releases all ActiveX references when it exits or when you do a File [image] New operation. If you also want ActiveX references to be released at program completion, there are some programming actions you must take. The following are required to assure that an instantiated Automation Server exits when its object is deleted or the VEE program finishes.

Select Disable Debug Features in Default Preferences. With debugging enabled, VEE retains data and pointer references for use with Line Probe. (You need to decide which is more important to you: debugging and line probing, or releasing ActiveX servers at program completion.)

Delete all declared and undeclared VEE variables before the program completes. Hint: Select All Variables in the Delete Variable object.

If you made any changes to the Excel spreadsheet, Excel wants to ask, "Do you want to save changes?". Even if VEE has released all its references to Excel, Excel still wants a response from somebody before it will exit in a case like this. One way to avoid this situation is to call the Quit() method in Excel.

An alternative technique is to put all your ActiveX functions into a separate VEE library. Then use Import Library to load these functions and Delete Library to release all the ActiveX references when they are no longer needed. For example, you write all your Excel operations as VEE UserFunctions and store them in a library file named “ExcelFuncs.vee.” When the main program wants to access an Excel spreadsheet, it does an Import Library of ExcelFuncs.vee, calls the appropriate UserFunctions to manipulate and store the spreadsheet, then does a Delete Library of ExcelFuncs.vee. At this point, all the references to the Excel Automation Server are removed, and Excel quits.

This alternative involves the extra work of creating and managing a separate library of UserFunctions. However, it allows you to quit Excel programmatically with debugging and line probing enabled. As mentioned above, you still need to save spreadsheet changes or call Excel’s Quit() before calling Delete Library.

Notes

VEE must be set to VEE 5 (or higher) execution mode for ActiveX support (Default Preferences).

The type library for an ActiveX application must be made available to VEE before you can create expressions which control that application (Device [image] ActiveX Automation References…).

VEE does not provide any programmatic control over the security settings used to instantiate objects on remote computers. This can be accomplished statically via the dcomcnfg.exe program that is part of DCOM.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: ActiveX Automation
Member: CreateObject

See Also

See example programs in the ActiveX example directories
Help [image] Open Example…

ActiveX Automation References, Default Preferences, GetObject.


cubert(x)

An object that returns the cube root of the value of x.

Use

Use cubert(x) to generate the cube root of a number x. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

For PComplex, the cubert(x) is defined as the cube root of the magnitude and one third the phase. Complex is converted to PComplex before the function is applied.

Example

cubert( (8, @90) ) will return (2, @30).

cubert( (1,1) ) will return (1.08, 0.291).

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Power
Member: cubert

See Also

a ^ b (exponent), Power, sq(x), and sqrt(x).


Data Filtering

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Data Filtering to apply filtering algorithms to the data to smooth it.

polySmooth(x)

meanSmooth(x,numPts)

movingAvg(x,numPts)

clipUpper(x,a)

clipLower(x,a)

minIndex(x)

maxIndex(x)

minX(x)

maxX(x)

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Data Filtering

See Also

polySmooth (x), meanSmooth (x,numPts), movingAvg (x,numPts), clipUpper (x,a), clipLower (x,a), minIndex(x), maxIndex(x), minX(x), maxX(x), Regression, and Signal Processing.


defIntegral (x,a,b)

An object used to calculate the integral of those values of the input data which are between points a and b (inclusive) using Simpson's 1/3 rule.

Use

Use defIntegral(x,a,b) to calculate the numerical approximation of the integral of a set of ordered, equally-spaced values (x) between points a and b.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Waveform Real64

Example

defIntegral([ 0, 1, 2, 3, 4, 4, 3, 2, 1, 0 ], 2, 5) returns 10.12.

Notes

The defIntegral(x,a,b) function is applicable to one-dimensional arrays of simple numeric values and lists of two-dimensional (two field) coordinates which represent equally spaced ordered data. For unmapped arrays, the values a and b represent indices in the array (0 to N-1). For coordinate lists, the values a and b represent real values between the x-values of the first and last point in the coordinate list (inclusive). For mapped arrays, the values a and b represent real values between the Xmin mapping and Xmax-dx (inclusive), where dx is the interval between consecutive points: (Xmax-Xmin)/N.

For unmapped arrays, it is assumed that the data is equally spaced and ordered, and a value of 1 is assumed for the interval dx between points. For mapped arrays, the operation is performed with the interval value dx equal to (Xmax-Xmin)/N and is thus automatically scaled appropriately. For a coordinate list, the independent (first field) values are first checked to be sure that they are ordered and equally spaced, then the operation is performed on the dependent (second field) values using the previously determined spacing as the value for dx.

If an unmapped array is used, but it is known otherwise that the interval between points is some value dx, then the correct value for the operation can be obtained by multiplying the result of defIntegral(x,a,b) by the known dx value.

When the values represent noisy data, the result of defIntegral(x) can often be improved (in a pragmatic sense) by first filtering or smoothing the data. Smoothing removes much of the unwanted noise which is superimposed on the underlying values. See the polySmooth(x) function and related smoothing functions for examples.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Calculus
Member: defIntegral

See Also

integral(x).


deriv(x, order)

An object used to calculate the derivative of order order across all values of the input data using a sliding fourth-order (five-point) polynomial.

Use

Use deriv(x,order) to calculate the numerical approximation of the derivative of order order across all points of a set of ordered equally spaced values (x). The result is an array of the same size and shape as the input x.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Waveform Waveform

Example

deriv([0, 1, 2, 3, 3, 2, 1, 0], 1) returns
[1.25, 0.9167, 1.083, 0.5833, -0.5833, -1.083, -0.9167, -1.25].

Notes

The deriv(x,order) function is applicable to one-dimensional arrays of simple numeric values and lists of two-dimensional (two field) coordinates that represent equally spaced ordered data. For mapped arrays, the mappings of the resultant array will be identical to those of x. For coordinate lists, the values a and b represent real values between the x-values of the first and last point in the coordinate list (inclusive). For mapped arrays, the values a and b represent real values between the Xmin mapping and Xmax-dx (inclusive), where dx is the interval between consecutive points: (Xmax-Xmin)/N.

For unmapped arrays, it is assumed that the data is equally spaced and ordered, and a value of 1 is assumed for the interval dx between points. For mapped arrays, the operation is performed with the interval value dx equal to (Xmax-Xmin)/N and is thus automatically scaled appropriately. For a coordinate list, the independent (first field) values are first checked to be sure that they are ordered and equally spaced, then the operation is performed on the dependent (second field) values using the previously determined spacing as the value for dx.

If an unmapped array is used, but it is known otherwise that the interval between points is some value dx, then the correct value for the operation can be obtained by dividing the result of deriv(x,order) by the known dx value.

When the values represent noisy data, the result of deriv(x,order) can often be improved (in a pragmatic sense) by first filtering or smoothing the data. Smoothing removes much of the unwanted noise which is superimposed on the underlying values. See the polySmooth(x) function and related smoothing functions for examples.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Calculus
Member: deriv

See Also

derivAt(x, order,pt).


derivAt(x, order,pt)

An object used to calculate the derivative of order order at value pt of the input data using a sliding fourth-order (five-point) polynomial.

Use

Use derivAt(x,order,pt) to calculate the numerical approximation of the derivative of order order at some point pt in the set of ordered equally spaced values (x).

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Real64

Example

derivAt([ 0, 1, 2, 3, 3, 2, 1, 0 ], 1, 3) returns 0.5833.

Notes

The derivAt(x,order,pt) function is applicable to one-dimensional arrays of simple numeric values (integer, real, Waveform) and lists of two-dimensional (two field) coordinates that represent equally spaced ordered data. For unmapped arrays, the value a represents an index in the array (0 to N-1). For coordinate lists, the values a and b represent real values between the x-values of the first and last point in the coordinate list (inclusive). For mapped arrays, the values a and b represent real values between the Xmin mapping and Xmax-dx (inclusive), where dx is the interval between consecutive points: (Xmax-Xmin)/N.

For unmapped arrays, it is assumed that the data is equally spaced and ordered, and a value of 1 is assumed for the interval dx between points. For mapped arrays, the operation is performed with the interval value dx equal to (Xmax-Xmin)/N and is thus automatically scaled appropriately. For a coordinate list, the independent (first field) values are first checked to be sure that they are ordered and equally spaced. Then the operation is performed on the dependent (second field) values using the previously determined spacing as the value for dx.

If an unmapped array is used, but it is known otherwise that the interval between points is some value dx, then the correct value for the operation can be obtained by dividing the result of derivAt(x,order,pt) by the known dx value.

When the values represent noisy data, the result of derivAt(x,order,pt) can often be improved (in a pragmatic sense) by first filtering or smoothing the data. Smoothing removes much of the unwanted noise which is superimposed on the underlying values. See the polySmooth(x) function and related smoothing functions for examples.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Calculus
Member: derivAt

See Also

deriv(x, order).


det(x)

An object used to calculate the determinant of a square matrix.

Use

Use det(x) to calculate the determinant of the square matrix x. The x input must be a square matrix shape. A square matrix has the same number of rows as columns.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Complex Complex, Scalar in shape

PComplex PComplex, Scalar in shape

Example

Where x is a square matrix [ [1, 2], [3, 4] ], det(x) returns -2.

Notes

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Matrix
Member: det

See Also

identity(x), inverse(x), and transpose(x).


dirName()

dirName(str)

An object that returns the directory portion of file path string.

Use

Use dirName() to isolate the directory information found at the front of a directory/file path.

For example, if pathStr is:

c:\Program Files\Agilent\VEE\examples\apps\chaos.vee

then dirName(pathStr) returns:

c:\Program Files\Agilent\VEE\examples\apps

Both forward slash ( / ) and backslash ( \ ) are treated as delimiter characters after directory (folder) names. If the entire pathStr contains only one name, that name is considered a file name. In those cases, dirName() returns the null string.

Notes

The dirName() object is simply a Formula object initialized with one input and containing the dirName() function. You may also type dirName() into any other Formula object or expression.

Location

Device [image] Function & Object Browser

Type: Built-in Functions
Category: System Information
Member: dirName

See Also

baseName(), Formula


a div b (truncated division)

An object that performs an arithmetic div (truncated division) on two operands.

Use

Use a div b to determine the number of times one container divides evenly into another container, that is, the truncated division value. The two containers may be of any shape. But if one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a container of the highest type, with the same shape as the operands.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Coord

Waveform Waveform

If both operands are of type Coord, they must have their independent variable(s) match exactly or an error is returned. The div is only performed on the dependent (last) variable.

Example

A scalar div an array: 3.2 DIV [1, 2, 3, 4] returns [3, 1, 1, 0].

An array div a scalar: [1, 2, 3] DIV 2 returns [0, 1, 1].

Two scalars: 12.95 DIV 4 returns 3.

Two Coord scalars: coord(1,3) DIV coord(1,5) returns coord(1,0).

Two Coord scalars: coord(1,3) DIV coord(2,5) returns an error.

Notes

If either of the containers is mapped (that is, of type Waveform, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings. The return value will have the same mappings as the operands; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Arithmetic
Member: DIV

See Also

a + b (add), a / b (divide), a * b (multiply), and a - b (subtract).


a / b (divide)

An object that performs an arithmetic division of two operands.

Use

Use a / b to divide the value of one container by the value of another container. The two containers may be of any shape. However, if one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a container of the highest type, with the same shape as the operands.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

If both operands are of type Coord, they must have their independent variable(s) match exactly or an error is returned. The division is only performed on the dependent (last) variable.

This division operation performs a parallel division on all arrays, including matrices. For a matrix divide, see the function matDivide(numer,denom).

Example

A scalar divided by an array: 3.0 / [1, 2, 3] returns [3, 1.5, 1].

Two arrays: [4, 5, 6] / [1, 2, 3] returns [4, 2.5, 2].

Two PComplex scalars: (1,@90) / (2,@30) returns (0.5, @60) with Trig Mode set to Degrees.

Two Coord scalars: coord(1,3) / coord(1,5) returns coord(1,0.6).

Two Coord scalars: coord(1,3) / coord(2,5) returns an error.

Notes

If either of the containers is mapped (that is, of type Waveform, Spectrum, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings. The return value will have the same mappings as the operands; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Arithmetic
Member: /

See Also

a + b (add), a div b (truncated division), matDivide (numer, denom), a * b (multiply), and a - b (subtract).


dmyToDate (d,m,y)

An object that returns the value of the parameters d, m, and y converted to a date.

Use

Use dmyToDate(d,m,y) to convert three values, day, month, and year, into the date. d, m, and y can be any shape. If one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a container of the highest type, with the same shape as the operands.

Allowed Input Types Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Example

dmyToDate(25, 12, 1991) returns 62.8293999G.

Notes

If any of the input parameters are mapped, then those mappings must be the same. The resultant container retains the mappings of the input container. If only one of the inputs is mapped, the resultant container has those mappings.

Also note that dmy is specified as modern Gregorian dates.

The value of d (the day) must be in the range 1 through 31.

The value of m (the month) must be in the range 1 through 12.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Time & Date
Member: dmyToDate

See Also

hmsToHour (h,m,s), hmsToSec (h,m,s), mday(aDate), month(aDate), now(), Time & Date, wday(aDate), and year(aDate).


a == b (equal to)

An object that performs an is equal to operation on two operands.

Use

Use a == b to determine whether the value(s) of one container is equal to the value(s) of another container. The two containers may be of any type and of any shape. If one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a scalar Int32 with the value 0 or 1. If the first operand is equal to the second, the value of the result is 1; otherwise the value is 0.

If both operands are of type Coord, they must have all their independent variable(s) and dependent variables match exactly for the result to be 1. If independent variables do not match, an error is returned. Complex, PComplex, and Spectrum containers must have both parts match for the operation to return 1. Enums are converted to Text for the comparison.

Arrays must have all the respective values of both containers equal for the operation to return 1.

Example

A scalar and an array: 3.0 == [3, 3, 3] returns 1.

A scalar and an array: 3.0 == [3, 1, 3] returns 0.

Two arrays: [1, 2, 3] == [1, 2, 4] returns 0.

Two PComplex scalars: (1,@90) == (1,@85) returns 0.

Two Complex scalars: (2,3) == (2,4) returns 0.

Two Complex scalars: (2,3) == (2,3) returns 1.

Two Coord scalars: coord(1,3) == coord(1,5) returns 0.

Two Coord scalars: coord(1,3) == coord(2,3) returns an error: Values for independent variables must match.

Notes

If either of the containers is mapped (that is, of type Waveform, Spectrum, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Comparison
Member: ==

See Also

a ~= b (almost equal to), a AND b, a > b (greater than), a >= b (greater than or equal to), a < b (less than), a <= b (less than or equal to), NOT a, a != b (not equal to), a OR b, Comparison, a XOR b, Comparator, Conditional, and If/Then/Else.


erf(x)

An object used to calculate the error function of the input x.

Use

Use erf(x) to calculate the error function of x. The erf function is defined as:

(2/SQRT(PI) ) * [ the integral of ( e^(-t^2)) * dt ]

where the integral is evaluated over the range from zero to x. The x input may be of any shape and size.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Example

erf(.5) returns 0.52049987781305.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: erf

See Also

erfc(x).


erfc(x)

An object used to calculate the complementary error function of the input x.

Use

Use erfc(x) to calculate the complementary error function of x. The erfc function is defined as:

1-(2/SQRT(PI)) * [the integral of ( e^(-t^2)) * dt]

where the integral is evaluated over the range from zero to x. The x input may be of any shape and size.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Example

erfc(.5) returns 0.47950012218695.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

The erfc(x) function, which returns 1.0 - erf(x), is provided because of the extreme loss of relative accuracy if a large x is called for in erf(x), the result is subtracted from 1.0 (for example, x=5, twelve places are lost).

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: erfc

See Also

erf(x).


errorInfo()

An object that provides information about the last error trapped on an error output pin.

Use

Use errorInfo() to determine error information for the last error trapped when using error output pins. After the error is trapped, execute an errorInfo() object to create a record that contains all the information that would be displayed in an error dialog box. The record contains the following fields:

Field Name Data Type Description

Number Int32 scalar The error number

Message Text scalar The error message text associated with this error

More Text 1D array Any extra information associated with this error

Title Text scalar The title of the object that generated the error

Type Text scalar The type of the object that generated the error

Notes

The errorInfo() object is simply a Formula object initialized without inputs and containing the errorInfo() equation. You may also type errorInfo() into any other Formula object or expression.

If no error was output to an error output pin, the record created by ErrorInfo contains no data.

errorInfo() only traps run-time errors, not pre-run errors such as when an input terminal is not connected.

errorInfo() does not give information about untrapped errors (which generate an error message dialog box).

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: System Information
Member: errorInfo

See Also

Error Output (Object Menu), Formula, and Raise Error.


exp(x)

An object that returns the exponential of the value of x.

Use

Use exp(x) to generate the exponential, or natural antilogarithm (base e), of a number x; that is, e raised to the x power. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 | UInt8
Int16 | Int16
Int32 | Int32
Real32 | Real32
Real64 | Real64
Coord | Coord
Waveform | Waveform
Complex | Complex
PComplex | PComplex
Spectrum | Spectrum

Example

exp(10) returns 22.0264657948k.

exp((1,2)) returns (-1.131204384, 2.471726672).

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Power
Member: exp

See Also

exp10(x), a ^ b (exponent), log(x), log10(x), and Power.


exp10(x)

An object that returns the exponential base 10 of the value of x.

Use

Use exp10(x) to generate the common antilogarithm (base 10) of a number x; that is, 10 raised to the x power. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform
Complex | Complex
PComplex | PComplex
Spectrum | Spectrum

Example

exp10(10) returns 10G.

exp10((1, 2)) returns (-4.16146837, 9.09297427).

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Power
Member: exp10

See Also

exp(x), a ^ b (exponent), log(x), log10(x), and Power.


a ^ b (exponent)

An object that performs an arithmetic exponentiation of two operands.

Use

Use a ^ b to raise one number to the power of the other number. The two containers may be of any shape. But if one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a container of the highest type, with the same shape as the operands.

Allowed Input Types Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform
Complex | Complex
PComplex | PComplex
Spectrum | Spectrum

If both operands are of type Coord, they must have their independent variable(s) match exactly or an error is returned. The exponentiation is only performed on the dependent (last) variable.

Example

A scalar raised to an array: 3.0 ^ [1, 2, 3] returns [3, 9, 27].

An array raised to a scalar: [1, 2, 3] ^ 3 returns [1, 8, 27].

Two arrays: [4, 5, 6] ^ [1, 2, 3] returns [4, 25, 216].

Two Complex scalars: (2,3) ^ (4,5) returns (-0.753046, -0.986429).

Two Coord scalars: coord(4,3) ^ coord(4,2) returns coord(4,9).

Two Coord scalars: coord(1,3) ^ coord(2,5) returns an error.

Notes

If either of the containers is mapped (that is, of type Waveform, Spectrum, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings. The return value will have the same mappings as the operands; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Arithmetic
Member: ^

See Also

exp(x) and log(x).


exponential regression

An object used to fit an exponential curve to (x,y) data.

Use

Use the exponential regression to fit the data to the equation y = C0 + exp(C1*x), where x is the x coordinate and C0 and C1 are calculated coefficients. The exp function is the transcendental number e raised to the (C1*x) power.

The exponential regression object expects an array of Coord type of input with one independent variable, that is, an (x,y) pair. If the input array is not a Coord type, an attempt is made to convert it to Coord. If the input data is mapped (Waveform, Spectrum, or a mapped array) then the conversion to Coord uses the mapping information to create the x part of the (x,y) pairs. If the input data is not mapped (for example, an array), then the x part of the (x,y) pair is implicitly generated from its position in the array.

Open View Parameters

The Fit Type field on the open view is used to change the regression type to linear, logarithmic, exponential, power curve or polynomial regression. Clicking on the field will bring up a list of the different regression types.

Example

See Regression for a Coord conversion example.

Notes

See Regression for general notes on regression.

Location

Device [image] Regression

then select the appropriate Fit Type from the Fit Type field on the dialog box.

See Also

Regression, linear regression, logarithmic regression, meanSmooth (x,numPts), movingAvg (x,numPts), polynomial regression, polySmooth (x), power curve regression and Build Coord.


factorial(n)

An object used to calculate the factorial of the input number n.

Use

Use factorial(n) to calculate the factorial of the natural number n. The factorial is defined for any natural number n as n! = (n) * (n-1) * (n-2) . . . (3) * (2) * (1).

The n input may be of any shape and size. The n input must not be less than zero.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

The factorial(n) operation is only defined for integer operands so the input numbers, while of unique type, are converted to Int32 type before the calculation is done.

Example

factorial(6) returns 720 from the multiplication of 6*5*4*3*2*1.

factorial(6.7) returns 5040 from the multiplication of 7*6*5*4*3*2*1. The rule about converting a real to Int32 forces 6.7 to 7.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: factorial

See Also

beta(x,y), binomial(a,b),
 comb(n,r), gamma(x), and
 perm(n,r).


fft(x)

An object to compute the Discrete Fourier Transform on the input data.

Use

Use fft(x) to calculate the Discrete Fourier Transform of the values in x. The result represents the positive half of the transformed values. The size of the resultant array will be (N DIV 2)+1, where N is the size of the input array.

Allowed Input Type Return Type

UInt8 | Complex Array
Int16 | Complex Array
Int32 | Complex Array
Real32 | Complex Array
Real64 | Complex Array
Waveform | Waveform

The input x must represent an array of ordered, equally-spaced data. For non-Waveform inputs, the output will be an unmapped array of Complex values. For Waveform inputs, the output will be mapped from a minimum frequency of 0 to a maximum frequency of (1+(N DIV 2))/(Tmax-Tmin), where N is the size of the input array, and Tmin and Tmax are the mappings of the input Waveform. Also note that the output will not be normalized.

Example

fft([0, 1, 2, 3, 4, 5, 6, 7])

returns [(28,0), (-4,9.657), (-4,4), (-4,1.657), (-4,0)]

Notes

Truncation and Periodicity: A basic assumption in the use of the discrete Fourier transform is that the given waveform h(t) is periodic. If this is not the case, then the waveform must be truncated and represented as a periodic function. For a band-limited periodic function h(t), the waveform must be truncated at an integer multiple of the period; otherwise, the resulting discrete and continuous Fourier transform will differ considerably in that sidelobes, frequency leakage, and sharp discontinuities can appear. These difficulties are often reduced through the use of windows. If the waveform is not band-limited, one generally must adjust (increase) the truncation interval and use windows [0,L] to reduce time-domain truncation errors. L is defined as the period of the waveform.

Aliasing: The problem of aliasing (frequency folding) occurs when the sampling interval T is too large. One can expect a degradation in the performance of the discrete Fourier transform when the sampling rate is close to the Nyquist sampling rate. If the waveform is not periodic or not band-limited, increasing the truncation interval[0,L] and decreasing the sampling interval T can help to control truncation errors and aliasing.

A reference on the fft can be found in the book: E. Oran Brigham, The Fast Fourier Transform and Its Applications, Second Edition, Prentice-Hall, Inc., Englewood Cliffs, NJ, 1988. ISBN #0-13-307505-2.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Signal Processing
Member: fft

See Also

convolve(a,b) and ifft(x).


floor(x)

An object that returns the rounded-down value of x to the nearest integer of a value.

Use

x may be any shape. The floor(x) function returns the largest integer (as the same type) less than or equal to x; that is, the value of x rounded to the next smaller integer, the integer nearest negative infinity.

Allowed Input Type Return Type

UInt8 | UInt8
Int16 | Int16
Int32 | Int32
Real32 | Real32
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

floor([23.0, 23.1, 23.9, 23.5, (-23.5)]) returns [23, 23, 23, 23, -24].

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Real Parts
Member: floor

See Also

abs(x), ceil(x), Complex Parts, fracPart(x), intPart(x), Real Parts, and round(x).


fracPart(x)

An object that returns the value of the fractional part of x.

Use

Use fracPart(x) to obtain the fractional part of a container. x may be any shape. The fracPart(x) function returns the fractional part of x with the same sign. It returns x - intPart(x).

Allowed Input Type Return Type

UInt8 | UInt8
Int16 | Int16
Int32 | Int32
Real32 | Real32
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

fracPart([23.0, 23.1, 23.9, 23.5, (-23.5)]) returns
0, 0.1, 0.9, 0.5, -0.5].

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Real Parts
Member: fracPart

See Also

abs(x), ceil(x), Complex Parts, floor(x), intPart(x), Real Parts, and round(x).


Freq Distribution

Part of the Built-in Functions in the Category of Probability & Statistics on the Function & Object Browser dialog box.

Use

Use the Freq Distribution functions to calculate the distribution of values over a range into a fixed number of sub-ranges. The Name of these functions are:

magDist(x,from,thru,step)

logMagDist(x,from,thru,logStep)

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics

See Also

Function & Object Browser, logMagDist (x,from,thru, logStep), and magDist(x, from,thru, step).


gamma(x)

An object used to calculate the gamma function of the input x.

Use

Use gamma(x) to calculate the gamma function of x. The gamma function is defined as:

(the integral of [ t^(x-1) * e^(-t) * dt ])

where the integral is evaluated over the range from 0 to infinity. The x input may be of any shape.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

Examples

gamma(8) returns (8-1)! = 5040.

gamma(-1) returns an error.

gamma(3.7) returns = 4.17065178379660.

gamma(-3.7) returns = 0.251643995902422.

Notes

The gamma(x) function is not defined for non-positive integral values of x. When x is a positive integer, gamma(x) is defined as (x-1)! (factorial).

Mappings on the operand are ignored and the output container has the same mappings as the input.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: gamma

See Also

beta(x,y), comb(n,r), factorial(n), and perm(n,r).


Generate

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Generate to access the following objects which generate Real64 one-dimensional arrays of data with specific values.

ramp(numElem,from,thru)

logRamp(numElem,from,thru)

xramp(numElem,from,thru)

xlogRamp(numElem,from,thru)

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Generate

See Also

logRamp (numElem, from,thru), ramp (numElem, from,thru), xlogRamp (numElem, from,thru), and xramp (numElem, from,thru).


getEnv(envStr)

Part of the VEE system information Built-in Functions that allow you to access environment variables.

Use

You can use getEnv to access the values of environment variables in VEE. When you select this function, the getEnv(envStr) object will appear. The (envStr) represents a string (Text object) that identifies the name of the environment variable you are looking for. Enter the string name of the environment variable you are looking for, inside the parentheses.

When the getEnv(envStr) object executes, it will return the value of the environment variable that was specified by the string as a Text object.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: System Information
Member: getEnv

See Also

errorInfo(), getHostname(),
 installDir(), whichOS(),
 and whichVersion()


getHostname()

Part of the VEE system information Built-in Functions that allow you to determine the name of the host computer on which VEE is running.

Use

You can use getHostname() to find out the name of the host computer on which your VEE program is running. When you select the getHostname function, the getHostname() object will appear. The object does not require any parameters, but when the object is executed, it will return the name of the host computer.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: System Information
Member: getHostname

See Also

errorInfo(), getEnv(envStr),
 installDir(), whichOS(),
 and whichVersion().


GetObject

GetObject(fileName, ProgID)

Loads the ActiveX Automation object saved in fileName, using the object specified by ProgID and returns a reference to it.

Use

Use GetObject to get an ActiveX automation object that already exists in a running application, or to load an existing object from a file. An object already exists if it was created by an expression using the CreateObject function, or the object creation occurred outside the scope of the VEE program. You will need to modify the initial expression to perform the desired action.

The ProgID of an object is a name (human-readable string) assigned by the person who wrote the automation object. It is typically a library or application name, a period, and a component or object name. To find the valid ProgIDs for any ActiveX Automation Server, consult the documentation supplied with that server. The ProgID parameter is optional. If ProgID is omitted, VEE uses the Component Object Model (COM) library to determine what application is associated with the file.

Examples

The following example returns a reference to a currently running Microsoft Excel application’s Application object. Excel must be running or this expression will cause an error:

SET excel = GetObject ("","Excel.Application")

The next example loads an existing object from a file. It returns a reference to the Sheet object associated with d:\tmp\TestData.xls in the currently running Excel application. If Excel is not running, it will start before loading the object.

SET excel = GetObject ("d:\\tmp\\TestData.xls","Excel.Sheet")

Notes

VEE must be set to VEE5 or higher execution mode for ActiveX support (Default Preferences).

The automation type library for an application must be made available to VEE before you can create expressions which control that application (Device [image] ActiveX Automation References…).

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: ActiveX Automation
Member: GetObject

See Also

See example programs in the ActiveX example directories
Help [image] Open Example…

ActiveX Automation References, Default Preferences, CreateObject.


a > b (greater than)

An object that performs an is greater than operation on two operands.

Use

Use a > b to determine whether the value(s) of one container is greater than the value(s) of another container. The two containers may be of any shape.

Allowed Input Type Return Type

UInt8 | Int32
Int16 | Int32
Int32 | Int32
Real32 | Int32
Real64 | Int32
Coord | Int32
Waveform | Int32
Text | Int32
Enum | Int32

If one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a scalar Int32, with the value 0 or 1. If the first operand is greater than the second, the value of the result is 1; otherwise the value is 0.

If both operands are of type Coord, their independent variable(s) must be identical before the operation is even attempted; if not, an error is returned. Enums are converted to Text for the comparison. Text is compared using ASCII lexical ordering.

When two arrays are compared to each other, each pair of elements must satisfy the relational operator for the operation to return 1.

Example

A scalar and an array: 3.0 > [1, 3, 9] returns 0.

An array and a scalar: [5, 9, 7] > 4 returns 1.

Two arrays: [3, 4, 7] > [2, 3, 5] returns 1.

Two arrays: [3, 4, 3] > [2, 3, 5] returns 0.

Two Coord scalars: coord(1,3) > coord(1,5) returns 0.

Two Coord scalars: coord(1,3) > coord(2,5) returns Values for independent variables must match.

Two Text scalars: "too" > "zoo" returns 0.

Notes

If either of the containers is mapped (that is, of type Waveform, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Comparison
Member: >

See Also

a ~= b (almost equal to), a AND b, a == b (equal to), a >= b (greater than or equal to), a < b (less than), a <= b (less than or equal to), NOT a, a != b (not equal to), a OR b, Comparison, a XOR b, Comparator, Conditional, and If/Then/Else.


a >= b (greater than or equal to)

An object that performs an is greater than or equal to operation on two operands.

Use

Use a >= b to determine whether the value(s) of one container is greater than or equal to the value(s) of another container. The two containers may be of any shape.

Allowed Input Type Return Type

UInt8 | Int32
Int16 | Int32
Int32 | Int32
Real32 | Int32
Real64 | Int32
Coord | Int332
Waveform | Int32
Text | Int32
Enum | Int32

If one of the containers is an array, the other must be either be a scalar or an array of the same size and shape. The result is a scalar Int32, with the value 0 or 1. If the first operand is greater than or equal to the second, the value of the result is 1; otherwise the value is 0.

If both operands are of type Coord, their independent variable(s) must be identical before the operation is even attempted; if not, an error is returned. Enums are converted to Text for the comparison. Text is compared using ASCII lexical ordering.

When two arrays are mapped against each other, each set of elements must satisfy the relational operator for the operation to return 1.

Example

A scalar and an array: 3.0 >= [1, 3, 9] returns 0.

An array and a scalar: [4, 5, 6] >= 4 returns 1.

Two arrays: [3, 3, 6] >= [2, 3, 5] returns 1.

Two arrays: [1, 4, 3] >= [2, 3, 5] returns 0.

Two Coord scalars: coord(1,3) >= coord(1,5) returns 0.

Two Coord scalars: coord(1,3) >= coord(2,5) returns Values for independent variables must match.

Two Text scalars: "too" >= "zoo" returns 0.

Notes

If either of the containers is mapped (that is, of type Waveform, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Comparison
Member: >=

See Also

a ~= b (almost equal to), a AND b, a == b (equal to), a > b (greater than), a < b (less than), a <= b (less than or equal to), NOT a, a != b (not equal to), a OR b, Comparison, a XOR b, Comparator, Conditional, and If/Then/Else.


hamming(x)

An object used to apply a Hamming window to a time series of values.

Use

Use hamming(x) to filter the values in x in the same manner as convolving x with the spectral transform of the Hamming function. This has the effect of suppressing some of the noise due to the tails of the input sequence and the potential discontinuities they represent when sampling periodic signals.

The input x must be an Array 1D.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform
Spectrum | Spectrum

If x is a Spectrum, it is first converted to a Waveform using an ifft(x) before the window is applied. The result of the window is then converted back to type Spectrum using an fft(x).

Example

hamming([1, 1, 1, 1, 1, 1, 1, 1]) returns
[0.115, 0.364, 0.716, 0.965, 0.965, 0.716, 0.364, 0.115].

Notes

The Hamming function is represented in the time domain as

0.54-0.46*cos(2*PI*(n+0.5)/N)

where n is the position (index) in the array, and N is the size of the array. The result will be an array of the same type as x and will have the same mappings as x (if any).

For a discussion of sidelobe levels and coherent gains, see: Ziemer, Tranter, and Fannin, Signals and Systems, Macmillan Publishing, New York, NY, 1983. ISBN #0-02-431650-4.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Signal Processing
Member: hamming

See Also

bartlet(x), blackman(x), convolve(a,b), fft(x), hanning(x), ifft(x), and rect(x).


hanning(x)

An object used to apply a Hanning window to a time series of values.

Use

Use hanning(x) to filter the values in x in the same manner as convolving x with the spectral transform of the Hanning function. This has the effect of suppressing some of the noise due to the tails of the input sequence and the potential discontinuities they represent when sampling periodic signals.

The input x must be an Array 1D.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Spectrum Spectrum

If x is a Spectrum, it is first converted to a Waveform using an ifft(x) before the window is applied. The result of the window is then converted back to type Spectrum using an fft(x).

Example

hanning([1, 1, 1, 1, 1, 1, 1, 1]) returns
[0.038, 0.309, 0.691, 0.962, 0.962, 0.691, 0.309, 0.038].

Notes

The Hanning function is represented in the time domain as

0.5*(1-cos(2*PI*(n+0.5)/N))

where n is the position (index) in the array, and N is the size of the array. The result will be an array of the same type as x and will have the same mappings as x (if any).

For a discussion of sidelobe levels and coherent gains, see: Ziemer, Tranter, and Fannin, Signals and Systems, Macmillan Publishing, New York, NY, 1983. ISBN #0-02-431650-4.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Signal Processing
Member: hanning

See Also

bartlet(x), blackman(x), convolve(a,b), fft(x), hamming(x), ifft(x), and rect(x).


help(topic,filename)

Part of the VEE system information Built-in Functions that allow you to link to custom help topics.

Use

You can link to a custom help topic file by using the help object. The syntax is:

help(topic,filename)

topic - The name of the help topic you wish to link to.

filename - The filename that contains the help topic information.

When your VEE program starts, and this object is executed, the help system will open the filename associated with the specified topic.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: System Information
Member: help

See Also

installDir()


hidePanel()

An object that hides a UserFunction panel displayed with showPanel().

Use

Use hidePanel() to stop displaying a UserFunction panel that was shown with showPanel().

Open View

You must include the text hidePanel(). Inside the parenthesis, you type the following parameter:

"UFname" - The name of the UserFunction. You must have double quotes around this name. This parameter is required.

You may add a data input pin to the hidePanel() object to set the UserFunction name, but you must replace "UFname" with the input terminal name.

Notes

The hidePanel() object is simply a Formula object initialized without inputs and containing the hidePanel("UFname") equation. You may also type hidePanel() (and the associated parameter) into any other Formula object.

You may input the entire hidePanel() equation via control pin.

All panels are hidden once the program stops executing.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Panel
Member: hidePanel

See Also

Call, lockPosition(),
 showPanel(), panelPosition(),
 panelSize(), unlockPosition(),
 and UserFunction.


hmsToHour (h,m,s)

An object that returns the value of the parameters h, m, and s converted to hours.

Use

Use hmsToHour(h,m,s) to convert three values, hours, minutes, and seconds, into hours. h, m, and s can be any shape. If one of the containers is an array, the others must be either scalar or arrays of the same size and shape. The resulting container has the same shape as the operands.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

hmsToHour(1, [0, 12, 60], 36) returns [1.01, 1.21, 2.01].

Notes

If any of the input parameters are mapped, then those mappings must be the same. The resultant container retains the mappings of the input container. If only one of the inputs is mapped, the resultant container has those mappings.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Time & Date
Member: hmsToHour

See Also

dmyToDate (d,m,y), hmsToSec (h,m,s), mday(aDate), month(aDate), now(), Time & Date, wday(aDate), and year(aDate).


hmsToSec (h,m,s)

An object that returns the value of the parameters h, m, and s converted to seconds.

Use

Use hmsToSec(h,m,s) to convert three values, hours, minutes, and seconds, into seconds. h, m, and s can be any shape. If one of the containers is an array, the others must be either scalar or arrays of the same size and shape. The resulting container has the same shape as the operands.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

hmsToSec(1,[2, 4, 6],3) returns [3723, 3843, 3963].

Notes

If any of the input parameters are mapped, then those mappings must be the same. The resultant container retains the mappings of the input container. If only one of the inputs is mapped, the resultant container has those mappings.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Time & Date
Member: hmsToSec

See Also

dmyToDate (d,m,y), hmsToHour (h,m,s), mday(aDate), month(aDate), now(), Time & Date, wday(aDate), and year(aDate).


Hyper Bessel

See the help topic, Bessel.


Hyper Trig

See the help topic, Trig.


i0(x)

An object used to calculate the modified (hyperbolic) Bessel function of x of the first kind of order zero.

Use

Use i0(x) to find the modified (hyperbolic) Bessel function of x of the first kind of order zero. The x input may be of any size and shape. For Coord input types, the operation is done on the dependent variable.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

i0(1) returns 1.26606587775200.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: i0

See Also

i1(x), k0(x), and k1(x).


i1(x)

An object used to calculate the modified (hyperbolic) Bessel function of x of the first kind of order one.

Use

Use i1(x) to find the modified (hyperbolic) Bessel function of x of the first kind of order one. The x input may be of any size and shape. For Coord input types, the operation is done on the dependent variable.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

i1(1) returns 0.565159103992485.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: i1

See Also

i0(x), k0(x), and k1(x).


identity(x)

An object used to return the identity matrix.

Use

Use identity(x) to return the identity matrix that is the same size as the square input matrix. The x input must be a square matrix. A square matrix has the same number of rows as columns.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Complex | Complex
PComplex | PComplex

Example

Where x is a square matrix [ [1, 2], [3, 4] ], identity(x) returns
[ [1, 0], [0, 1] ].

Where x is the complex square matrix [ [(1,1), (2,2)], [(3,3), (4,4)] ], identity(x) returns [ [(1,0), (0,0)], [(0,0), (1,0)] ].

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Matrix
Member: identity

See Also

det(x), inverse(x), and transpose(x).


ifft(x)

An object to compute the Inverse Discrete Fourier Transform on the input data.

Use

Use ifft(x) to calculate the Inverse Discrete Fourier Transform of the values in x. The input x should be the positive half of a symmetric Complex, PComplex, or Spectral sequence.

Allowed Input Type Return Type

Complex Real64

PComplex Real64

Spectrum Waveform

The size of the resultant array depends on the information used to create the incoming array. As described for fft(x), an fft done on arrays of 256 and 257 points each results in arrays containing 129 points. The information in each array differs slightly based on the different number of points. Using ifft(x) on these 129-point arrays results in the original 256- and 257-point arrays. For non-Spectrum inputs, the output will be an unmapped array of Real values. For Spectrum inputs, the mapping must be linear (not log), and Fmin must be 0. The output will be mapped from a minimum time of 0 to a maximum time of N/(Fmax-Fmin), where N is the size of the input array, and Fmin and Fmax are the mappings of the input Spectrum. Also note that the output will not be normalized.

It is assumed that the values of x represent data that has not been normalized.

Example

ifft([(3.5,0), (-1,2.414), (-1,1), (-1,0.414), (-1,0)]) returns
[0, 1, 2, 3, 4, 5, 6, 7].

Notes

1. Truncation and Periodicity: A basic assumption in the use of the discrete Fourier transform is that the given waveform h(t) is periodic. If this is not the case, then the waveform must be truncated and represented as a periodic function. For a band-limited periodic function h(t), the waveform must be truncated at an integer multiple of the period; otherwise, the resulting discrete and continuous Fourier transform will differ considerably since sidelobes, frequency leakage, and sharp discontinuities can appear. These difficulties are often reduced through the use of windows. If the waveform is not band-limited, you generally must increase the truncation interval and use windows [0,L] to reduce time-domain truncation errors. L is defined as the period of the waveform.

2. Aliasing: The problem of aliasing (frequency folding) occurs when the sampling interval T is chosen too large. One can expect a degradation in the performance of the discrete Fourier transform when the sampling rate is close to the Nyquist sampling rate. If the waveform is not periodic or not band-limited, increasing the truncation interval [0,L] and decreasing the sampling interval T can help to control truncation errors and aliasing.

A reference on the ifft can be found in the book: E. Oran Brigham, The Fast Fourier Transform and Its Applications, Second Edition, Prentice-Hall, Inc., Englewood Cliffs, NJ, 1988. ISBN #0-13-307505-2.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Signal Processing
Member: ifft

See Also

fft(x).


im(x)

An object that returns the imaginary part of a Complex number x.

Use

Use im(x) to extract the imaginary part of a Complex number x. x can be any shape. (PComplex is first converted to Complex.)

Allowed Input Type Return Type

UInt8 | UInt8 | value of zero
Int16 | Int16 | value of zero
Int32 | Int32 | value of zero
Real32 | Real32 | value of zero
Real64 | Real64 | value of zero
Coord | Coord | value of zero
Waveform | Waveform | value of zero
Complex | Real64 | value of the imaginary part
PComplex | Real64 | value of the imaginary part
Spectrum | Real64 | value of the imaginary part

Example

im( (1,2) ) returns 2.

im( (1,@90) ), with Trig Mode in Degrees, returns 1.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Complex Parts
Member: im

See Also

conj(x), j(x), mag(x), phase(x), re(x), Real Parts, Build Complex, and UnBuild Complex.


inDaylightSavings()

An object that indicates if computer time is in Daylight Savings Time.

Use

Use inDaylightSavings() to determine if your computer is in Daylight Savings Time or Standard Time. It returns zero if the current computer time is Standard Time. It returns non-zero if the current computer time is Daylight Savings Time.

Notes

The inDaylightSavings() object is simply a Formula object initialized without inputs and containing the inDaylightSavings() equation. You may also type inDaylightSavings() into any other Formula object or expression.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Time & Date
Member: inDaylightSavings

See Also

now, Formula.


init(x,val)

An object used to initialize an array to a specific value.

Use

Use init(x,val) to initialize an input array x to a value of val. The x input may be of any size and shape, and of any type. For all x input types, the same output type is returned (except the Error output, which returns Text). The second val parameter must be of the same type or be able to be converted to the same type as the x input value.

If the input x is an array then the val init value parameter can be a Scalar value or an array. If val is an array, it must have the same number of dimensions and size as the x input. That is, if x is an Array 1D then val can either be a Scalar or an Array 1D of the same size. For Records, the schema of x and val must match.

Example

init(a,5) initializes the input array to a value of 5.

init(a,[1, 2, 3]) initializes an input array of three elements to the values [1, 2, 3].

Notes

The init value must be the same type as the input array or be able to be converted to the same type. That is, you cannot initialize a real array to a complex initial value because a complex number cannot be converted to a real number.

The mapping on the output container is the same as the input val.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Array
Member: init

See Also

ramp (numElem, from,thru), randomize (x,low,high), and Allocate Array.


installDir()

An object that returns the directory path where Agilent VEE is installed.

Use

You can use installDir() to determine the directory where Agilent VEE is installed on your computer. The path is retrieved from the registry on the PC.

Notes

You can use the command line option -d <dirname> to specify a starting directory different from the install directory. If you use the -d option, installDir() returns the starting directory specified on the command line.

The installDir() object is simply a Formula object initialized without inputs and containing the installDir() equation. You may also type installDir() into any other Formula object or expression.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: System Information
Member: installDir

See Also

errorInfo(), getEnv(envStr),
 getHostname(), whichVersion(),
 and commandLine().


integral(x)

An object used to calculate the integral across all values of the input data using Simpson's 1/3 rule.

Use

Use integral(x) to calculate the numerical approximation of the indefinite integral of a set of ordered, equally-spaced values (x).

Allowed Input Type Return Type

UInt8 | Real64 (same mappings, if any)
Int16 | Real64 (same mappings, if any)
Int32 | Real64 (same mappings, if any)
Real32 | Real64 (same mappings, if any)
Real64 | Real64 (same mappings, if any)
Coord | Coord
Waveform | Waveform

Example

integral([ 0, 1, 2, 3, 3, 2, 1, 0 ]) returns
[ 0, 0.5, 2, 4.5, 7.667, 10.17, 11.67, 12.17 ].

Notes

The integral(x) function is applicable to one-dimensional arrays of simple numeric values and lists of two-dimensional (two field) coordinates that represent equally spaced ordered data. For mapped arrays, the mappings of the resultant array will be identical to those of x. For coordinate lists, the values of the independent field (first field) of each coordinate will be identical to those of the corresponding values in x.

For unmapped arrays, it is assumed that the data is equally spaced and ordered, and a value of 1 is assumed for the interval dx between points. For mapped arrays, the operation is performed with the interval value dx equal to (Xmax-Xmin)/N and is thus automatically scaled appropriately. For a coordinate list, the independent (first field) values are first checked to be sure that they are ordered and equally spaced, then the operation is performed on the dependent (second field) values using the previously determined spacing as the value for dx.

If an unmapped array is used, but it is known otherwise that the interval between points is some value dx, then the correct value for the operation can be obtained by multiplying the result of integral(x) by the known dx value.

When the values represent noisy data, the result of integral(x) can often be improved (in a pragmatic sense) by first filtering or smoothing the data. Smoothing removes much of the unwanted noise which is superimposed on the underlying values. See the polySmooth(x) function and related smoothing functions for examples.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Calculus
Member: integral

See Also

defIntegral (x,a,b).


intPart(x)

An object that returns the value of the integer part of x.

Use

Use intPart(x) to obtain the integer part of a container. x may be any shape. The intPart(x) function returns the integer portion of the data. If the data is less than zero, it returns the ceil(x); otherwise it returns the floor(x). The result will have the same mappings as x.

Allowed Input Type Return Type

UInt8 | UInt8
Int16 | Int16
Int32 | Int32
Real32 | Real32
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

intPart([23.0, 23.1, 23.9, 23.5,(-23.5)]) returns
[23, 23, 23, 23, -23].

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Real Parts
Member: intPart

See Also

abs(x), ceil(x), Complex Parts, floor(x), fracPart(x), Real Parts, and round(x).


intToChar(a)

An object that converts the numeric input to an ASCII character.

Use

Use intToChar(a) to convert a numeric input to an ASCII character. The object converts the input to a long integer first, then converts the integer to a character.

Notes

The range of values converted to characters is 0 through 255. The object accommodates inputs outside this range by converting only the low-order byte of a 32-bit integer input. The upper three bytes are ignored.

VEE uses the same TEXT(String) as C and C++, so intToChar(0) is equivalent to NUL or an empty string. NUL is a string terminator. For example, the string 123NUL456 produces the string 123. The remainder of the string, 456, is ignored.

Examples

intToChar(65) returns A.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String
Member: IntToChar

See Also

charToInt(a), and String.


inverse(x)

An object used to calculate the inverse of a square matrix.

Use

Use inverse(x) to calculate the inverse of the square matrix x. The x input must be a square matrix shape (the same number of rows as columns).

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Complex | Complex
PComplex | PComplex

Example

Where x is a square matrix [ [1, 2], [3, 4] ], inverse(x) returns
[ [-2, 1], [1.5, -0.5] ].

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Matrix
Member: inverse

See Also

det(x), identity(x), and transpose(x).


isVariant(x)

Queries "x" to determine if it was created from an ActiveX variant.

Use

If "x" is an array, this function operates on the array container, not on individual array elements. For example, isVariant(A) works properly, but isVariant(A[0]) does not.

ActiveX data can be declared as type Variant, then be assigned data of a specific type. The isVariant function tells you if the variable was declared as a Variant or not. The typeName function tells you the data type currently assigned to the Variant.

Example

someMethod (ByRef x);

isVar = isVariant (x);

The isVar variable now contains a zero or nonzero value, indicating if "x" was truly of type Variant or not.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: isVariant

See Also

isVariantBool(x), isVariantCurrency(x), isVariantDate(x), isVariantEmpty(x), isVariantError(x), isVariantNull(x), typeName(x).


isVariantBool(x)

Queries "x" to determine if it was created from an ActiveX variant of type Boolean.

Use

ActiveX Automation Boolean data types (VT_BOOL) are returned to VEE as Int16 containers with a "hint" that the container is really a VT_BOOL type. The container can be queried to determine if it is truly an Int16 or a Boolean type.

If "x" is an array, this function operates on the array container, not on individual array elements. For example, isVariantBool(A) works properly, but isVariantBool(A[0]) does not. The return value is an Int16, with 0 for false and nonzero for true.

Example

someMethod (ByRef x);

isBool = isVariantBool (x);

The isBool variable now contains a zero or nonzero value, indicating if "x" was truly of type VT_BOOL or not.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: isVariantBool

See Also

isVariant(x), isVariantCurrency(x), isVariantDate(x), isVariantEmpty(x), isVariantError(x), isVariantNull(x), typeName(x).


isVariantCurrency(x)

Queries "x" to determine if it was created from an ActiveX variant of type Currency.

Use

ActiveX Automation Currency data types (VT_CY) are returned to VEE as Real64 containers with a "hint" that the container is really a VT_CY type. The container can be queried to determine if it is truly a Real64 or a Currency type.

If "x" is an array, this function operates on the array container, not on individual array elements. For example, isVariantCurrency(A) works properly, but isVariantCurrency(A[0]) does not. The return value is an Int32, with 0 for false and nonzero for true.

Example

someMethod (ByRef x);

isCurrency = isVariantCurrency (x);

The isCurrency variable now contains a zero or nonzero value, indicating if "x" was truly of type VT_CY or not.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: isVariantCurrency

See Also

isVariant(x), isVariantBool(x), isVariantDate(x), isVariantEmpty(x), isVariantError(x), isVariantNull(x), typeName(x).


isVariantDate(x)

Queries "x" to determine if it was created from an ActiveX variant of type Date.

Use

ActiveX Automation Date data types (VT_DATE) are returned to VEE as Real64 containers with a "hint" that the container is really a VT_DATE type. The container can be queried to determine if it is truly a Real64 or a Date type.

If "x" is an array, this function operates on the array container, not on individual array elements. For example, isVariantDate(A) works properly, but isVariantDate(A[0]) does not. The return value is an Int32, with 0 for false and nonzero for true.

Example

someMethod (ByRef x);

isDate = isVariantDate (x);

The isDate variable now contains a zero or nonzero value, indicating if "x" was truly of type VT_DATE or not.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: isVariantDate

See Also

isVariant(x), isVariantBool(x), isVariantCurrency(x), isVariantEmpty(x), isVariantError(x), isVariantNull(x), typeName(x).


isVariantEmpty(x)

Queries "x" to determine if it was created from an ActiveX variant that is empty.

Use

Use to determine if the returned Variant was Empty (instead of Variant containing an empty string).

If "x" is an array, this function operates on the array container, not on individual array elements. For example, isVariantEmpty(A) works properly, but isVariantEmpty(A[0]) does not. The return value is an Int32, with 0 for false and nonzero for true.

Example

someMethod (x);

isEmpty = isVariantEmpty (x);

The isEmpty variable now contains a zero or nonzero value indicating if "x" was truly an empty Variant or not.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: isVariantEmpty

See Also

isVariant(x), isVariantBool(x), isVariantCurrency(x), isVariantDate(x), isVariantError(x), isVariantNull(x), typeName(x).


isVariantError(x)

Queries "x" to determine if it was created from an ActiveX variant of type Error.

Use

ActiveX Automation Error data types (VT_ERROR) are returned to VEE as Int32 containers with a "hint" that the container is really a VT_ERROR type. The container can be queried to determine if it is truly an Int32 or an Error type. The value represents the error number (scode).

If "x" is an array, this function operates on the array container, not on individual array elements. For example, isVariantError(A) works properly, but isVariantError(A[0]) does not. The return value is an Int32, with 0 for false and nonzero for true.

Example

someMethod (x);

isError = isVariantError (x);

The isError variable now contains a zero or nonzero value indicating if "x" was truly of type VT_ERROR or not.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: isVariantError

See Also

isVariant(x), isVariantBool(x), isVariantCurrency(x), isVariantDate(x), isVariantEmpty(x), isVariantNull(x), typeName(x).


isVariantNull(x)

Queries "x" to determine if it was created from an ActiveX variant that contains a Null.

Use

Use to determine if the returned Variant contained a VT_NULL (instead of the Int32 value of 0).

If "x" is an array, this function operates on the array container, not on individual array elements. For example, isVariantNull(A) works properly, but isVariantNull(A[0]) does not. The return value is an Int32, with 0 for false and nonzero for true.

Example

someMethod (x);

isNull = isVariantNull (x);

The isNull variable now contains a zero or nonzero value indicating if "x" was truly of type VT_NULL or not.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Type Conversion
Member: isVariantNull

See Also

isVariant(x), isVariantBool(x), isVariantCurrency(x), isVariantDate(x), isVariantEmpty(x), isVariantError(x), typeName(x).


j(x)

An object that returns a Complex number with x as the imaginary part.

Use

Use j(x) to generate a Complex number of the same shape as x, with x as the imaginary part and 0 as the real part. The same shape is returned.

Allowed Input Type Return Type

UInt8 | Complex
Int16 | Complex
Int32 | Complex
Real32 | Complex
Real64 | Complex
Waveform | Complex

Example

j(5) returns the Complex number (0,5).

Notes

Mappings are retained in the result. To return a complex number with x as the real part, use the type promotions on input terminals to promote real to Complex.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Complex Parts
Member: j

See Also

Complex Parts, conj(x), im(x), mag(x), phase(x), re(x), Real Parts, Build Complex, and UnBuild Complex.


j0(x)

An object used to calculate the Bessel function of x of the first kind of order zero.

Use

Use j0(x) to find the Bessel function of x of the first kind of order zero. The x input may be of any size and shape. For Coord input types, the operation is done on the dependent variable.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

j0(10) returns -0.245935764451348.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: j0

See Also

Ai(x), Bi(x), j1(x), jn(x,n), y0(x), y1(x), and yn(x,n).


j1(x)

An object used to calculate the Bessel function of x of the first kind of order one.

Use

Use j1(x) to find the Bessel function of x of the first kind of order one. The x input may be of any size and shape. For Coord input types, the operation is done on the dependent variable.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

j1(1) returns 0.440050585744933.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: j1

See Also

Ai(x), Bi(x), j0(x), jn(x,n), y0(x), y1(x), and yn(x,n).


jn(x,n)

An object used to calculate the Bessel function of x of the first kind of order n.

Use

Use jn(x,n) to find the Bessel function of x of the first kind of order n. The x input may be of any size and shape. For Coord input types, the operation is done on the dependent variable.

The n parameter must be of Int32 type or be able to be converted to Int32. It must be Scalar in shape or the same shape as x.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

jn(1,2) returns 0.114903484931900.

Notes

If both of the inputs are mapped, then the mappings must be the same. The return value has the same mappings as the input if either input is mapped. If neither of the inputs is mapped, then the output is unmapped.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: jn

See Also

Ai(x), Bi(x), j0(x) , j1(x), y0(x), y1(x), and yn(x,n).


k0(x)

An object used to calculate the modified (hyperbolic) Bessel function of x of the second kind of order zero.

Use

Use k0(x) to find the modified (hyperbolic) Bessel function of x of the second kind of order zero. The x input may be of any size and shape. For Coord input types, the operation is done on the dependent variable.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

k0(1) returns 0.421024438240708.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

The x argument must be positive.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: k0

See Also

i0(x), i1(x), and k1(x).


k1(x)

An object used to calculate the modified (hyperbolic) Bessel function of x of the second kind of order one.

Use

Use k1(x) to find the modified (hyperbolic) Bessel function of x of the second kind of order one. The x input may be of any size and shape. For Coord input types, the operation is done on the dependent variable.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform

Example

k1(1) returns 0.601907230197234.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

The x argument must be positive.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: k1

See Also

i0(x), i1(x), and k0(x).


a < b (less than)

An object that performs an is less than operation on two operands.

Use

Use a < b to determine whether the value(s) of one container is less than the value(s) of another container. The two containers may be of any shape. But if one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a scalar Int32, with the value 0 or 1. If the first operand is less than the second, the value of the result is 1; otherwise the value is 0.

Allowed Input Type Return Type

UInt8 | Int32
Int16 | Int32
Int32 | Int32
Real32 | Int32
Real64 | Int32
Coord | Int32
Waveform | Int32
Text | Int32
Enum | Int32

If both operands are of type Coord, their independent variable(s) must be identical before the operation is even attempted; if not, an error is returned. Enums are converted to Text for the comparison. Text is compared using ASCII lexical ordering.

When two arrays are compared to each other, each pair of elements must satisfy the comparison operator for the operation to return 1.

Example

A scalar and an array: 3.0 < [1, 3, 9] returns 0.

An array and a scalar: [1, 2, 3] < 4 returns 1.

Two arrays: [1, 2, 3] < [2, 3, 5] returns 1.

Two arrays: [1, 4, 3] < [2, 3, 5] returns 0.

Two Coord scalars: coord(1,3) < coord(1,5) returns 1.

Two Coord scalars: coord(1,3) < coord(2,5) returns Values for independent variables must match.

Two Text scalars: "too" < "zoo" returns 1.

Notes

If either of the containers is mapped (that is, of type Waveform, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Comparison
Member: <

See Also

a ~= b (almost equal to), a AND b, a == b (equal to) , a > b (greater than), a >= b (greater than or equal to), a <= b (less than or equal to), NOT a, a != b (not equal to), a OR b, Comparison, a XOR b, Comparator, Conditional, and If/Then/Else.


a <= b (less than or equal to)

An object that performs an is less than or equal to operation on two operands.

Use

Use a <= b to determine whether the value(s) of one container is less than or equal to the value(s) of another container. The two containers may be of any shape. But if one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a scalar Int32, with the value 0 or 1. If the first operand is less than or equal to the second, the value of the result is 1; otherwise the value is 0.

Allowed Input Type Return Type

UInt8 | Int32
Int16 | Int32
Int32 | Int32
Real32 | Int32
Real64 | Int32
Coord | Int32
Waveform | Int32
Text | Int32
Enum | Int32

If both operands are of type Coord, their independent variable(s) must be identical before the operation is even attempted; if not, an error is returned. Enums are converted to Text for the comparison. Text is compared using ASCII lexical ordering.

When two arrays are mapped against each other, each set of elements must satisfy the comparison operator for the operation to return 1.

Example

A scalar and an array: 3.0 <= [1, 3, 9] returns 0.

An array and a scalar: [1, 2, 4] <= 4 returns 1.

Two arrays: [1, 2, 3] <= [2, 3, 3] returns 1.

Two arrays: [1, 4, 3] <= [2, 3, 5] returns 0.

Two Coord scalars: coord(1,3) <= coord(1,5) returns 1.

Two Coord scalars: coord(1,3) <= coord(2,5) returns Values for independent variables must match.

Two Text scalars: "too" <= "zoo" returns 1.

Notes

If either of the containers is mapped (that is, of type Waveform, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Comparison
Member: <=

See Also

a ~= b (almost equal to), a AND b, a == b (equal to), a > b (greater than), a >= b (greater than or equal to), a < b (less than), NOT a, a != b (not equal to), a OR b, Comparison, a XOR b, Comparator, Conditional, and If/Then/Else.


linear regression

An object used to fit a linear regression line to (x,y) data.

Use

Use the linear regression to fit a straight line to the data using the equation y = C0 + C1*x, where x is the x coordinate and C0 and C1 are calculated coefficients. This type of regression should be thought of as fitting the best straight line through the data.

The linear regression object expects an array of Coord type of input with one independent variable, that is, an (x,y) pair. If the input array is not a Coord type, an attempt is made to convert it to Coord. If the input data is mapped (Waveform, Spectrum, or a mapped array) then the conversion to Coord uses the mapping information to create the x part of the (x,y) pairs. If the input data is not mapped (for example, an array), then the x part of the (x,y) pair is implicitly generated from its position in the array.

Open View Parameters

The Fit Type field on the open view is used to change the regression type to linear, logarithmic, exponential, power curve or polynomial regression. Clicking on the field will bring up a list of the different regression types.

Example

See Regression for a Coord conversion example.

Notes

See Regression for general notes on regression.

Location

Device [image] Regression

then select the appropriate Fit Type from the Fit Type field on the dialog box.

See Also

Regression, exponential regression, logarithmic regression, meanSmooth (x,numPts), movingAvg (x,numPts), polynomial regression, polySmooth (x), power curve regression, and Build Coord.


lockPosition()

An object that prevents the UserFunction panel that is being shown from being moved.

Use

When you use showPanel() to display a UserFunction panel, and have used unlockPosition() or have unchecked the Lock Panel Position property to allow the user to move the panel, use lockPosition() to prevent the user from moving the panel.

Open View

You must include the text lockPosition(). Inside the parenthesis, you type the following parameter:

"UFname" - The name of the UserFunction. You must have double quotes around this name. This parameter is required.

You may add a data input pin to the lockPosition() object to set the UserFunction name, but you must replace "UFname" with the input terminal name.

Notes

The lockPosition() object is simply a Formula object initialized without inputs and containing the lockPosition() equation. You may also type lockPosition() into any other Formula object or expression.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Panel
Member: lockPosition

See Also

Call, hidePanel(),
 panelPosition(), panelSize(),
 showPanel(), unlockPosition(),
 and UserFunction.


log(x)

An object that returns the natural logarithm of the value of x.

Use

Use log(x) to generate the natural logarithm (base e) of a number x. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform
Complex | Complex
PComplex | PComplex
Spectrum | Spectrum

Example

log([10, 2]) will return [2.302585092994, 0.693147180559945].

log((1,2)) will return (0.804718956, 1.10714872).

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Power
Member: log

See Also

exp(x), exp10(x), a ^ b (exponent), log10(x), and Power.


log10(x)

An object that returns the common logarithm of the value of x.

Use

Use log10(x) to generate the common logarithm (base 10) of a number x. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Coord | Coord
Waveform | Waveform
Complex | Complex
PComplex | PComplex
Spectrum | Spectrum

Example

log10([10, 2]) will return [1, 0.301029995663981].

log10((1,2)) will return [0.349485, 0.480828579].

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Power
Member: log10

See Also

exp(x), exp10(x), a ^ b (exponent), log(x), and Power.


logarithmic regression

An object used to fit a logarithmic curve to data.

Use

Use the logarithmic regression to fit the data to the equation:

y = C0 + C1*log(x)

where x is the x coordinate and C0 and C1 are calculated coefficients. The log function is the natural logarithm. The input data (x) must always be greater than zero.

The logarithmic regression object expects an array of Coord type of input with one independent variable, that is, an (x,y) pair. If the input array is not a Coord type, an attempt is made to convert it to Coord. If the input data is mapped (Spectrum or a mapped array) then the conversion to Coord uses the mapping information to create the x part of the (x,y) pairs. If the input data is not mapped (for example, an array), then the x part of the (x,y) pair is implicitly generated from its position in the array.

Open View Parameters

The Fit Type field on the open view is used to change the regression type to linear, logarithmic, exponential, power curve or polynomial regression. Clicking on the field will bring up a list of the different regression types.

Example

See Regression for a Coord conversion example.

Notes

See Regression for general notes on regression.

This function will not work for unmapped arrays. Unmapped arrays are converted to Coord starting with x=0, which will fail in the log function. This function will not work with a Waveform for the same reason.

Location

Device [image] Regression

then select the appropriate Fit Type from the Fit Type field on the dialog box.

See Also

Regression, exponential regression, meanSmooth (x,numPts), movingAvg (x,numPts), polynomial regression, polySmooth (x), power curve regression, and Build Coord.


Logical

A Category of Operators on the Function & Object Browser dialog box.

Use

Use Logical to access the following objects which perform logical operations on operands:

a AND b

a OR b

a XOR b

NOT a

Notes

If logic requirements are met, a 1 is returned. If logic requirements are not met, a 0 is returned.

Note that the return value is of type Int32 and is the same shape as the operands. This is different than the conditionals, such as ==, that always return a scalar.

The logical operators are defined for type Text only in the sense of whether the string is null or not. That is, "zoo" AND "" (null string) is logically false since the second string is null. Remember that when comparing a Text type to a non-string type, the latter is promoted to a Text type. This means that "zoo" AND 0 is true since the real 0 is promoted to the string "0" and, since both strings are non-null, the AND expression is true and returns 1.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Logical

See Also

a AND b, NOT a, a OR b, a XOR b, Comparison, Conditional, and If/Then/Else.


logMagDist (x,from,thru, logStep)

An object used to calculate the distribution of numbers in the input container given a logarithmic distribution.

Use

Use logMagDist(x,from,thru,logStep) to calculate a distribution of the log10 values of the values in the input array. The distribution is done in the range of from to thru by a size of logStep. The logStep parameter is the sub-range size in the log10 domain into which the log values are sorted (for example, a logStep of 0.2 would be equivalent to 5 sub-ranges per decade).

The x input may be of any size, and the shape must be an Array. For Complex, PComplex, and Spectrum type inputs, the magnitude of the complex number is calculated first, then that magnitude is used in determining the frequency distribution.

Allowed Input Type Return Type

UInt8 Real64 Array 1D

Int16 Real64 Array 1D

Int32 Real64 Array 1D

Real32 Real64 Array 1D

Real64 Real64 Array 1D

Coord Real64 Array 1D

Waveform Real64 Array 1D

Complex Real64 Array 1D

PComplex Real64 Array 1D

Spectrum Real64 Array 1D

Since log10(x) is not defined for values of x<=0, the input values should be positive.

For input of all types, a Real64 Array 1D is returned. Each array element represents how many of the input value will fit in each distribution range.

The from, thru and logStep parameters must be Scalar in shape and of type Real64 or be able to be converted to Real64.

The from parameter must be less than the thru parameter.

The logStep parameter must be greater than zero.

Example

logMagDist(x,1,100,1), where x is the array:

[1, 2, 3, 10, 40, 50, 100, 100 ,100]

returns the array [3, 6]. In this example there are 2 sub-ranges ranging from 1 to 2 by 1. The output array shows how many of the input numbers fall into each range.

Notes

The sub-ranges for the distribution are determined by the following range parameters:

Range 1

Range Minimum: "from" parm

range: <= range1

Range Maximum: < "from" parm + "step" parm(range1limit)

Range 2

Range Minimum: range1limit

range: <= range2

Range Maximum: < range1limit + "step" parm (range2limit)

Range 3

Range Minimum: range2limit

range: <= range3

Range Maximum: < range2limit + "step" parm (range3limit)

Range n-1

Range Minimum: range(n-2)limit

range: <= range(n-1)

Range Maximum: <= "thru" parm

The log10 of the "from" and "thru" parameters is calculated before determining the range distribution.

Mappings on the operands are ignored and the return value is not mapped.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: logMagDist

See Also

magDist(x, from,thru, step).


logRamp (numElem, from,thru)

An object that generates a logarithmically ramped array.

Use

Use logRamp(numElem,from,thru) to generate a Real64 one-dimensional array of length numElem, with the values logarithmically ramped from from to thru. numElem must be a scalar container which is, or can be converted to, Int32 and with a value greater than zero. from and thru must be scalar containers which are, or can be converted to, Real. If from is less than thru the ramping is positive; otherwise it automatically ramps negatively. Both from and thru must have values greater than zero.

Example

logRamp(3, 1, 100) returns a 1D Array with values [1, 10, 100].

Notes

The return value has no mappings.

The algorithm for generating values is:

Y[I]=exp10(log10(from)+I*((log10(thru)-log10(from))/numElem-1))
for I=0..numElem-1

This has the effect that the last element in the resultant array has the value thru.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Generate
Member: logRamp

See Also

Alloc Real64 and ramp (numElem, from,thru).


mag(x)

An object that returns the magnitude of a PComplex number x.

Use

Use mag(x) to extract the magnitude of a PComplex number x. For types Integer, Real, Coord, and Waveform, the same type with the same value(s) is returned. For types Complex, PComplex, and Spectrum, mag(x) returns a Real container with the value of the magnitude of the PComplex number. (Complex is first converted to PComplex.)

Allowed Input Type Return Type

UInt8 UInt8, with the same value

Int16 Int16, with the same value

Int32 Int32, with the same value

Real32 Real32, with the same value

Real64 Real64, with the same value

Coord Coord, with the same values

Waveform Waveform, with the same values

Complex Real64

PComplex Real64

Spectrum Real64

Example

mag( (1,@45) ) returns 1.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Complex Parts
Member: mag

See Also

conj(x), im(x), j(x), phase(x), re(x), Real Parts, Build Complex, Default Preferences, and UnBuild Complex.


magDist(x, from,thru, step)

An object used to calculate the distribution of numbers in the input container.

Use

Use magDist(x,from,thru,step) to calculate a distribution of numbers in the input array. The distribution is done in the range of from to thru by a size of step. The step parameter is the size of the range of the sub-array that the numbers will go into.

The x input may be of any size. For Complex, PComplex, and Spectrum type inputs, the magnitude of the complex number is calculated first, then that magnitude is used to calculate the frequency distribution. The x input shape must be an Array.

Allowed x Input Type Return Type

UInt8 Real64 Array 1D

Int16 Real64 Array 1D

Int32 Real64 Array 1D

Real32 Real64 Array 1D

Real64 Real64 Array 1D

Coord Real64 Array 1D

Waveform Real64 Array 1D

Complex Real64 Array 1D

PComplex Real64 Array 1D

Spectrum Real64 Array 1D

Each element in the returned array represents how many of the input values will fit in each distribution range.

The from, thru and step parameters must be Scalar in shape and of type Real64 or be able to be converted to Real64.

The from parameter must be less than the thru parameter.

The step parameter must be greater than zero.

Example

magDist(x,1,5,1), where x is the array [1, 2, 3, 4, 5, 5, 3, 3, 3, 2, 2, 2], returns the array [1, 4, 4, 3]. In this example there are four sub-ranges ranging from 1 to 5 by 1. The output array shows how many of the input numbers fall into each sub-range.

Notes

The sub-ranges for the distribution are determined by the following range parameters:

Range 1

Range Minimum: "from" parm

range: <= range1

Range Maximum: < "from" parm + "step" parm(range1limit)

Range 2

Range Minimum: range1limit

range: <= range2

Range Maximum: < range1limit + "step" parm (range2limit)

Range 3

Range Minimum: range2limit

range: <= range3

Range Maximum: < range2limit + "step" parm (range3limit)

Range n-1

Range Minimum: range(n-2)limit

range: <= range(n-1)

Range Maximum: <= "thru" parm

Mappings on the operands are ignored and the return value is not mapped.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: magDist

See Also

logMagDist (x,from,thru, logStep).


matDivide (numer, denom)

This object will divide two matrices A and B. The matDivide(numer,denom) operation is defined in algebraic terms as A/B; but in matrix (linear algebraic) terms, it is defined as inv(B)*A.

Use

Use the matDivide(numer,denom) to divide one matrix into another. Given the linear system BX=A, where the B and A matrices are known, solve for the solution matrix X. In algebraic terms the solution is to solve for X by dividing A by B: X = A/B. But, by solving the system of equations with linear algebraic matrix rules, the operation is really X = inv(B)*A. This operation is useful to find the solution of a linear system of n equations in n unknowns.

If B is an n x n (square) matrix, then the linear system BX = A is a system of n equations in n unknowns. Suppose that B is non-singular. Then inv(B) (inverse of B) exists and multiplying BX = A by inv(B) on both sides, obtains X = inv(B)*A.

The solution to the multiplication of inv(B)*A is the solution to the given linear system. If B is nonsingular, then there is a unique solution to the system.

Example

matDivide(A,B), where A is a 3x1 matrix [ [8], [24], [8] ]
and B is an 3x3 matrix [ [1, 1, 1], [0, 2, 3], [5, 5, 1] ]
returns a 3x1 matrix [ [0], [0], [8] ].

Notes

Mappings on the operand are ignored and the return value is not mapped.

matDivide(A,B) uses the inverse of B; hence, B must be a square matrix. The rules for matMultiply(A,B) apply to the inv(B) * A operation.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Matrix
Member: matDivide

See Also

a / b (divide) and matMultiply (A,B).


matMultiply (A,B)

An object used to multiply two matrices together according to linear Algebra rules.

Use

Use matMultiply(A,B) to multiply together the two input matrices A and B. Let A be an m x p matrix and B be a p x n matrix. The matMultiply of A and B is a new matrix, Z, that is an m x n matrix. Notice that the multiplication is defined if and only if the matrices are of the sizes where A is an m x p matrix and B is a p x n matrix (that is, where the number of rows of the second matrix equals the number of columns of the first).

The input matrices must be of matrix shape. If the two matrices are not of the same type, the lower type matrix is promoted to the higher type and the return value is of the higher type.

Allowed Input Type Return Type

UInt8 | Real64
Int16 | Real64
Int32 | Real64
Real32 | Real64
Real64 | Real64
Complex | Complex
PComplex | PComplex

Example

matMultiply(A,B), where A is an 2x1 matrix [ [3], [1] ] and B is a 1x2 matrix [2, 4], returns a 2x2 matrix [ [6, 12], [2, 4] ].

Notes

Mappings on the operand are ignored and the return value is not mapped.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Matrix
Member: matMultiply

See Also

matDivide (numer, denom) and a * b (multiply).


Matrix

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use the Matrix operations to calculate common linear algebra operations on matrices.

det(x)

inverse(x)

transpose(x)

identity(x)

minor(x,row,col)

cofactor(x,row,col)

matMultiply(A,B)

matDivide(numer,denom)

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Matrix

See Also

cofactor(x, row,col), det(x), identity(x), inverse(x), matMultiply (A,B), matDivide (numer, denom), minor(x,row, col), and transpose(x).


max(x)

An object used to return the maximum value in the input container.

Use

Use max(x) to return the maximum value in the container.

The x input may be of any size and shape. For Coord input types, the operation is done on the dependent variable. For Text input types, the max(x) text string is the one that is the highest lexically ordered string.

Allowed Input Type Return Type

UInt8 UInt8, Scalar in shape

Int16 Int16, Scalar in shape

Int32 Int32, Scalar in shape

Real32 Real32, Scalar in shape

Real64 Real64, Scalar in shape

Coord Coord, Scalar in shape

Waveform Real Scalar

Text Text

Example

max(x), where x is the array [5, 34, 1, 54, 6, 2, 9, 7, 16, 42], returns 54.

Notes

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: max

See Also

maxIndex(x), maxX(x), mean(x), median(x), min(x), mode(x), rms(x), sdev(x), and vari(x).


maxIndex(x)

An object used to return the index in the input array of the largest element.

Use

Use maxIndex(x) to return the index of the largest element in a 1D array. The x input must be of Array 1D shape.

Allowed Input Type Return Type

UInt8 Int32

Int16 Int32

Int32 Int32

Real32 Int32

Real64 Int32

Coord Int32

Waveform Int32

Text Int32

Example

Applying the maxIndex(x) to an array, where x is the array [.1, .4, .6, .9] returns 3 because .9 is the largest element of the array.

maxIndex(x) of ["Ken", "Sue", "Randy", "Bill", "Doug"] returns 1 because "Sue" is the highest lexically ordered term.

Notes

Note that array indices start with zero.

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Data Filtering
Member: maxIndex

See Also

max(x), maxX(x), min(x), minIndex(x), and minX(x).


maxX(x)

An object used to return the x value of a maximum point of the input Array 1D where the array is mapped.

Use

Use maxX(x) to return the Xindex of the largest element in a 1D (linear) array. The x input must be of Array 1D shape.

Allowed Input Type Return Type

UInt8 Real64 Scalar

Int16 Real64 Scalar

Int32 Real64 Scalar

Real32 Real64 Scalar

Real64 Real64 Scalar

Coord Real64 Scalar

Waveform Real64 Scalar

Text Real64 Scalar

If the data is mapped, the value returned is the x value corresponding to the maximum y value of the input data. The x value is calculated using the array mappings. If the data is not mapped, then the value returned is the index in the array of the maximum y value. That is, it will return the (implicit) position in the array of maximum x value.

The Coord type returns the independent variable x at the maximum y value.

This function is only useful for mapped data or Coord types, as it is the same as maxIndex(x) for unmapped data.

Example

Take the maxX(x) of a sine waveform type that has 256 points and is mapped over 0 to 20 milliseconds. The return value is .009219.

Take the maxX(x) of an array, where x is the unmapped array. [.1, .4, .6, .9] returns 3 because .9 is the largest element of the array. This is identical to maxIndex(x).

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Data Filtering
Member: maxX

See Also

max(x), maxIndex(x), min(x), minIndex(x), minX(x), Get Mappings, and Set Mappings.


mday(aDate)

An object that returns the day of the month of the time x.

Use

Use mday(x) to transform the given time x into a container of the same shape as x with value(s) 1 - 31 corresponding to the day of the month.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Example

mday(dmyToDate(25,12,1991)) returns 25, the 25th day of the month.

Notes

mday(aDate) returns 1-31, not 0-30. This is one of the few non-zero based functions in VEE. Mappings are retained in the return value.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Time & Date
Member: mday

See Also

dmyToDate (d,m,y), hmsToHour (h,m,s), hmsToSec (h,m,s), month(aDate), now(), Time & Date, wday(aDate), and year(aDate).


mean(x)

An object used to calculate the mean value of the data in the input container.

Use

Use mean(x) to return the mean (average) value of the container. The numbers in the input container are added, then the sum is divided by the number of elements in the input. The x input may be of any size and shape.

Allowed Input Type Return Type

UInt8 Real64 Scalar

Int16 Real64 Scalar

Int32 Real64 Scalar

Real32 Real64 Scalar

Real64 Real64 Scalar

Coord Real64 Scalar

Waveform Real64 Scalar

For Coord input types, the operation is done on the dependent variable.

Example

Where x is the array [1, 2, 3, 11, 12, 34], mean(x) returns 10.5.

Notes

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: mean

See Also

max(x), median(x), min(x), mode(x), rms(x), sdev(x), and vari(x).


meanSmooth (x,numPts)

An object used to smooth input data using the mean of a specified number of data points surrounding the data point of interest to calculate the smoothed data point.

Use

Use meanSmooth(x,numPts) to perform a data smoothing similar to the polySmooth(x) routine. The algorithm calculates an arithmetic mean of the numPts data points around the point to be smoothed. For example, if numPts is 5, take the mean of: 2 points before the current point, the current point, and two points after the current point. If numPts is even, the algorithm will add one more to the number of points to make it odd. The x input must be of Array 1D shape.

Allowed x Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

The independent variables of a Coord input type must be equidistant, that is, the x-interval between adjacent points must be a constant. The smoothing is only done on the dependent variable (the y data of the Coord).

The noise suppression capability of this technique is a function of the size numPts of the averaging which you specify. Large values of numPts will suppress noise to a much greater degree than small values of numPts. Quite often this function can be used to dramatically improve the results of other functions (like deriv(x,order)) if used to preprocess the data.

Notes

Mappings on input parameters are ignored and the output has the same mappings as the input parameter x.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Data Filtering
Member: meanSmooth

See Also

movingAvg (x,numPts), polySmooth (x), Regression types, and Signal Processing.


median(x)

An object used to calculate the median value of the input container.

Use

Use median(x) to return the middle value of the container. The x input may be of any size and shape.

Allowed Input Type Return Type

UInt8 Real64 Scalar

Int16 Real64 Scalar

Int32 Real64 Scalar

Real32 Real64 Scalar

Real64 Real64 Scalar

Coord Real64 Scalar

Waveform Real64 Scalar

For Coord input types, the operation is done on the dependent variable.

Example

median([1, 2, 3, 8, 20]) returns 3.

median(x), where x is the array [1, 2, 5, 11, 12, 33], returns 8. The median value is the one in the middle of the range of numbers. In the case where there are an even number of numbers, the median is calculated as the average between the two middle numbers. In this case, the median value is the average of 5 and 11, which is 8.

median([20, 5, 10]) returns 10.

Notes

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: median

See Also

max(x), mean(x), min(x), mode(x), rms(x), sdev(x), and vari(x).


min(x)

An object used to return the minimum value in the input container.

Use

Use min(x) to return the minimum value in the container. The x input may be of any size and shape.

Allowed Input Type Return Type

UInt8 UInt8, Scalar in shape

Int16 Int16, Scalar in shape

Int32 Int32, Scalar in shape

Real32 Real32, Scalar in shape

Real64 Real64, Scalar in shape

Coord Coord, Scalar in shape

Waveform Real64, Scalar in shape

Text Text, Scalar in shape

For Coord input types, the operation is done on the dependent variable. For Text input types, the min(x) text string is the one that is the lowest lexically ordered string.

Example

min(x), where x is the array [5, 34, 1, 54, 6, 2, 9, 7, 16, 42], returns 1.

Notes

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: min

See Also

max(x), mean(x), median(x), minIndex(x), minX(x), mode(x), rms(x), sdev(x), and vari(x).


minIndex(x)

An object used to return the index in the input array of the smallest element.

Use

Use minIndex(x) to return the index of the smallest element in a 1D array. The x input must be of Array 1D shape.

Allowed Input Type Return Type

UInt8 Int32

Int16 Int32

Int32 Int32

Real32 Int32

Real64 Int32

Coord Int32

Waveform Int32

Text Int32

Example

Applying the minIndex(x) to an array, where x is the array [.1, .4, .6, .9] returns 0 because .1 is the smallest element of the array.

minIndex(x) of ["Ken", "Randy", "Doug", "Bill", "Sue"] returns 3 because "Bill" is the lowest lexically ordered term.

Notes

Note that array indices start with zero.

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Data Filtering
Member: minIndex

See Also

max(x), maxIndex(x), maxX(x), min(x), and minX(x).


minor(x,row, col)

An object used to calculate the minor of a matrix x at row r and column c.

Use

Use minor(x,row,col) to calculate the minor of the square input matrix x. The minor of matrix is defined as the determinant of the submatrix of the input matrix x obtained by deleting the rth row and cth column. The x input must be a square matrix shape (same number of rows as columns). The input for the row and column to delete, r and c, must be Int32 Scalar or be able to be converted to Int32 type.

Allowed x Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Complex Complex, Scalar in shape

PComplex PComplex, Scalar in shape

Example

minor(a,1,2), where a is a matrix [ [3, -1, 2], [4, 5, 6], [7, 1, 2] ],
returns -34.

Notes

Mappings on the operand are ignored.

The r and c inputs are expected to be of type Int32 or be able to be converted to that type. The rows and columns of the matrix are numbered from 0 to n-1 so be careful when specifying which row and column to use.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Matrix
Member: minor

See Also

cofactor(x, row,col) and det(x).


minX(x)

An object used to return the x value of the minimum point of the input Array 1D where the array is mapped.

Use

Use minX(x) to return the Xindex of the smallest y element in an 1D (linear) array. The x input must be of Array 1D shape.

Allowed Input Type Return Type

UInt8 Real64 Scalar

Int16 Real64 Scalar

Int32 Real64 Scalar

Real32 Real64 Scalar

Real64 Real64 Scalar

Coord Real64 Scalar

Waveform Real64 Scalar

Text Real64 Scalar

If the data is mapped, the value returned is the x value corresponding to the minimum y value of the input data. The x value is calculated using the array mappings. If the data is not mapped, then the value returned is the index in the array of the minimum y value. That is, it will return the (implicit) position in the array of minimum x value.

The Coord type returns the independent variable x at the minimum y value.

This function is only useful for mapped data or Coord types. It is the same as minIndex(x) for unmapped data.

Example

Take the minX(x) of a sine waveform that has 256 points and is mapped over 0 to 20 milliseconds. The return value is .0107.

Take the minX(x) of an array, where x is the unmapped array. [.1, .4, .6, .9] returns 0 because .1 is the smallest element of the array. This is identical to minIndex(x).

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Data Filtering
Member: minX

See Also

max(x), maxIndex(x), maxX(x), min(x), minIndex(x), Get Mappings, and Set Mappings.


a mod b (modulo)

An object that performs an arithmetic modulo (remainder) of two operands.

Use

Use a mod b to determine the remainder of the division of two containers. The two containers may be of any shape. But if one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a container of the highest type, with the same shape as the operands.

Allowed Input Type Return Type

UInt8 Highest type

Int16 Highest type

Int32 Highest type

Real32 Highest type

Real64 Highest type

Coord Highest type

Waveform Highest type

If both operands are of type Coord, they must have their independent variable(s) match exactly or an error is returned. The modulo is only performed on the dependent (last) variable.

Example

A scalar modulo an array: 3.2 MOD [1, 2, 3] returns [0.2, 1.2, 0.2].

An array modulo a scalar: [1, 2, 3] MOD 2 returns [1, 0, 1].

Two Coord scalars: coord(1,3) MOD coord(1,5) returns coord(1,2).

Two Coord scalars: coord(1,3) MOD coord(2,5) returns an error.

Two scalars: 12.95 mod 2 returns 0.95.

Two scalars: 12.95 mod 2.1 returns 0.35.

Notes

If either of the containers is mapped (that is, of type Waveform, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings. The return value will have the same mappings as the operands; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Arithmetic
Member: MOD

See Also

a + b (add), a div b (truncated division), a / b (divide), a * b (multiply), and a - b (subtract).


mode(x)

An object used to calculate the mode of the data in the input container.

Use

Use mode(x) to return the mode of the value in the container. The mode value is the one which is found most often in the data. In case of bimodal data (two numbers represented the same number of times) or higher modes, mode(x) returns the lowest valued mode found in the array container.

In the case where there is no mode value (that is, every number is unique), the first value in the input container is returned.

The x input may be of any size and shape.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Real64 Scalar

Waveform Real64 Scalar

For Coord input types, the operation is done on the dependent variable.

Example

Single mode: where x is the array [2, 1, 12, 11, 2, 33], mode(x) returns 2.

Bimodal: where x is the array [2, 1, 2, 12, 11, 12], mode(x) returns 2.

No mode: where x is the array [3, 2, 1, 11, 12, 33], mode(x) returns 3.

Notes

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: mode

See Also

max(x), mean(x), median(x), min(x), rms(x), sdev(x), and vari(x).


month(aDate)

An object that returns the month of the year of the time x.

Use

Use month(aDate) to transform the given time x into a container of the same shape with value(s) 1 - 12 corresponding to the month of the year. x can be any shape, and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Example

month(dmyToDate(25,12,1991)) returns 12, the 12th month of the year.

Notes

month(aDate) returns 1-12, not 0-11. This is one of the few non-zero based functions in VEE. Mappings are retained in the return value.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Time & Date
Member: month

See Also

dmyToDate (d,m,y), hmsToHour (h,m,s), hmsToSec (h,m,s), mday(aDate), now(), Time & Date, wday(aDate), and year(aDate).


movingAvg (x,numPts)

An object used to smooth the input data using the average of a specified number of data points preceding the data point of interest to calculate the smoothed data point.

Use

Use movingAvg(x,numPts) to perform a data smoothing similar to the meanSmooth(x,numPts) routine. The algorithm calculates an arithmetic mean of numPts previous data points. The x input must be of Array 1D shape.

Allowed x Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

The independent variables of a Coord input type must be equidistant, that is, the x-interval between adjacent points must be a constant. The smoothing is only done on the dependent variable (the y data of the Coord).

This technique tends to represent more of a "historical" view of the data since, for any point in the array, the average value is calculated only from earlier points. This is in contrast to the average value being calculated from points on both sides of the point in question, as is the case for polySmooth(x) and meanSmooth(x,numPts).

Example

If numPts is 5, the average of the 4 previous points and the point of interest are used to determine what the smoothed point should be.

Notes

Mappings on input parameters are ignored and the output has the same mappings as the input parameter x.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Data Filtering
Member: movingAvg

See Also

meanSmooth (x,numPts), polySmooth (x), Regression types, and Signal Processing.


a * b (multiply)

An object that performs an arithmetic multiplication on two operands.

Use

Use a * b to multiply the values of two containers. The two containers may be of any type and of any shape. If one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a container of the highest type, with the same shape as the operands.

If both operands are of type Coord, they must have their independent variable(s) match exactly or an error is returned. The multiplication is only performed on the dependent (last) variable.

If one of the containers is Text, the other must be an Int32. Text multiplication consists of repeating the string the number of times given by the value of the Int32. Enums are converted to Text for multiplication.

This multiplication operation performs a parallel multiplication on all elements of the arrays, including matrices. For a matrix multiply, see the function matMultiply(A,B).

Example

Array times a scalar: [1, 2, 3] * 3 returns [3, 6, 9].

Two arrays: [4, 5, 6] * [1, 2, 3] returns [4, 10, 18].

Two PComplex scalars: (2,@45) * (3,@90) returns (6,@135) with Trig Mode set to Degrees.

Two Coord scalars: coord(1,3) * coord(1,5) returns coord(1,15).

Two Coord scalars: coord(1,3) * coord(2,5) returns an error.

Text times a scalar: "hello" * 3 returns "hellohellohello".

A Text array times an array: ["hello", "b"] * [3, 2] returns
["hellohellohello", "bb"].

Notes

If either of the containers is mapped (that is, of type Waveform, Spectrum, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings. The return value will have the same mappings as the operands; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Arithmetic
Member: *

See Also

a + b (add), a / b (divide), matMultiply (A,B), and a - b (subtract).


NOT a

An object that performs a logical NOT operation on one operand.

Use

Use NOT a to determine the logical opposite of the value(s) of a container. The container may be of any type and of any shape. The result is an Int32 of the same shape as the operand, with value(s) 0 or 1. If the operand is false (zero), the value of the NOT operator is 1; otherwise the value is 0.

For Coord containers, only the dependent (last) variable is considered for the NOT operation.

For Complex, PComplex, and Spectrum containers, the value of the operand is true if either part is non-zero. Text is true if non-null. Enums are converted to Text for the operation.

Example

A scalar: NOT 3 returns 0.

A scalar: NOT 0 returns 1.

An array: NOT [-3, 0, 3] returns [0, 1, 0].

A PComplex scalar: NOT (1,@90) returns 0.

A Complex scalar: NOT (0,1) returns 0.

A Complex scalar: NOT (0,0) returns 1.

A Coord scalar: NOT coord(1,3) returns 0.

A Coord scalar: NOT coord(1,0) returns 1.

A Text scalar: NOT "too" returns 0.

A Text scalar: NOT "" returns 1.

Notes

The result has the same mapping as the operand.

Note that the If/Then/Else device requires the expression(s) inside it to evaluate to either a scalar or an array, which is either all zeros or all ones.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Logical
Member: NOT

See Also

Conditional and If/Then/Else.


a != b (not equal to)

An object that performs an is not equal to operation on two operands.

Use

Use a != b to determine whether the value(s) of one container is not equal to the value(s) of another container. The two containers may be of any type and of any shape. If one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a scalar Int32 with the value 0 or 1. If the first operand is not equal to the second, the value of the result is 1; otherwise the value is 0.

For Coord containers, if any of the independent variable(s) do not match exactly, an error is returned. For Complex, PComplex, and Spectrum containers, if either part or both parts do not match, the result is 1. Enums are converted to Text for the comparison.

Arrays must have one or more of their respective values not equal for the result to be 1.

Example

A scalar and an array: 3.0 != [3, 3, 3] returns 0.

A scalar and an array: 3.0 != [3, 1, 3] returns 1.

Two arrays: [1, 2, 3] != [1, 2, 4] returns 1.

Two PComplex scalars: (1,@90) != (1,@85) returns 1.

Two Complex scalars: (2,3) != (2,4) returns 1.

Two Complex scalars: (2,3) != (2,3) returns 0.

Two Coord scalars: coord(1,3) != coord(1,5) returns 1.

Two Coord scalars: coord(1,3) != coord(2,3) returns Values for independent variables must match.

Notes

If either of the containers is mapped (that is, of type Waveform, Spectrum, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Comparison
Member: !=

See Also

a ~= b (almost equal to), a AND b, a == b (equal to), a > b (greater than), a >= b (greater than or equal to), a < b (less than), a <= b (less than or equal to), NOT a, a OR b, Comparison, a XOR b, Comparator, and Conditional.


now()

An object that returns the current time.

Use

Use now() to generate a Real64 scalar container with the value of the current time. The value of the Real64 is the number of seconds since 00:00 hours 1 January 0001 AD given in UTC.

Example

now() returns around 62.802G.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Time & Date
Member: now

See Also

dmyToDate (d,m,y), hmsToHour (h,m,s), hmsToSec (h,m,s), mday(aDate), month(aDate), Time & Date, wday(aDate), and year(aDate).


a OR b

An object that performs a logical OR operation on two operands.

Use

Use a OR b to determine whether the value(s) of either of two containers is logically true (non-zero). The two containers may be of any type and of any shape. If one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is an Int32 of the same shape as the operands, with value(s) 0 or 1. If either or both operands are non-zero, the value of the OR operation is 1; otherwise the value is 0.

If both operands are of type Coord, they must have their independent variable(s) match exactly or an error is returned. Only the dependent (last) variable is considered for the OR operation.

For Complex, PComplex, and Spectrum containers, the value of the operand is true if either part is non-zero. Text is true if non-null. Enums are converted to Text for the operation.

Example

A scalar and an array: 3 OR [3, 3, 3] returns [1, 1, 1].

A scalar and an array: 0 OR [-3, 0, 3] returns [1, 0, 1].

Two arrays: [1, 0, 0] OR [0, 1, (-1)] returns [1, 1, 1].

Two PComplex scalars: (1,@90) OR (1,@85) returns 1.

Two Complex scalars: (0,0) OR (0,1) returns 1.

Two Complex scalars: (0,1) OR (1,0) returns 1.

Two Complex scalars: (0,0) OR (0,0) returns 0.

Two Coord scalars: coord(1,3) OR coord(1,5) returns 1.

Two Coord scalars: coord(1,3) OR coord(2,3) returns an error.

A Text scalar and a scalar number: "too" OR 0 returns 1.

A Text scalar and a scalar number: "" OR 0 returns 1 because the 0 is promoted to the string "0", which is non-null.

Notes

If either of the containers is mapped (that is, of type Waveform, Spectrum, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings. The return value will have the same mappings as the operands; otherwise an error is returned.

Note that the If/Then/Else device requires the expression(s) inside it to evaluate to either a scalar or an array, which is either all zeros or all ones.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Logical
Member: OR

See Also

a AND b, NOT a, Comparison, a XOR b, Conditional, and If/Then/Else.


ordinal(x)

An object that returns the ordinal value of x.

Use

Use ordinal(x) to obtain the ordinal value of a container. x may be any shape. For integers, reals, Coord, and Waveform, the result is the same as the argument with the same mappings.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Coord

Waveform Waveform

Enum Int32

For Enum, the result is an Int32 of the same shape as x with the value of the ordinal value of the Enum. Enums created from the Enum Constant have their ordinal values starting at 0 and going to n-1, where n is the number of Enum values in the list.

Example

If an Enum constant is created with the strings ordered "a", "b", and "c", and the current value "a" is selected, ordinal(x) on that container would return 0 since the first value is selected. Remember that VEE is zero-based. If, with the same Enum constant, the currently selected value is "c", then ordinal(x) on that container would return 2, the offset of the currently selected value.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Real Parts
Member: ordinal

See Also

Complex Parts, Selection Control, and Real Parts.


panelPosition()

An object that outputs the location of a UserFunction panel.

Use

When you use showPanel() to display a UserFunction panel, use panelPosition() to output the location of the panel. The output is a Coord that contains the location of the upper-left corner of the UserFunction panel (excluding the border and title area, if they exist on the panel) as the number of pixels from the upper-left corner of the work area.

Open View

You must include the text panelPosition(). Inside the parenthesis, you type the following parameter:

"UFname" - The name of the UserFunction. You must have double quotes around this name. This parameter is required.

You may add a data input pin to the panelPosition() object to set the UserFunction name, but you must replace "UFname" with the input terminal name.

Notes

If the UserFunction does not have a panel view or the panel view has not yet been shown in the program, panelPosition() returns the Coord (0, 53).

If the UserFunction panel is not currently shown, panelPosition() returns the panel position of the last time it was shown.

The panelPosition() object is simply a Formula object initialized without inputs and containing the panelPosition() equation. You may also type panelPosition() into any other Formula object or expression.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Panel
Member: panelPosition

See Also

Call, hidePanel(),
 lockPosition(), panelSize(),
 showPanel(), unlockPosition(),
 and UserFunction.


panelSize()

An object that outputs the size of a UserFunction panel.

Use

When you use showPanel() to display a UserFunction panel, use panelSize() to output the size of the panel. The output is a Coord that contains the size of the UserFunction panel in pixels. The size does not include the size of the border and title area (if they exist on the panel).

Open View

You must include the text panelSize(). Inside the parenthesis, you type the following parameter:

"UFname" - The name of the UserFunction. You must have double quotes around this name. This parameter is required.

You may add a data input pin to the panelSize() object to set the UserFunction name, but you must replace "UFname" with the input terminal name.

Notes

If the UserFunction does not have a panel view or the panel view has not yet been shown in the program, panelSize() returns the Coord (0, 0).

If the UserFunction panel is not currently shown, panelSize() returns the panel size from the last time it was shown.

The panelSize() object is simply a Formula object initialized without inputs and containing the panelSize() equation. You may also type panelSize() into any other Formula object or expression.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Panel
Member: panelSize

See Also

Call, hidePanel(),
 lockPosition(), panelPosition(),
 showPanel(), unlockPosition(),
 and UserFunction.


perm(n,r)

An object used to calculate the permutations of n numbers taken r at a time.

Use

Use perm(n,r) to calculate the number of permutations of n things taken r at a time using the formula:

Perm(n, r) = n! / (n - r)!

The ! symbol means factorial. The n input may be of any shape and size. The second r parameter must be of the same type or be able to be converted to the same type as the n input value. If both of the inputs are arrays, they must be of exactly the same shape and size.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

The perm(n, r) operation is only defined for integer operands so the input values, while of unique type, are converted to Int32 type before the calculation is done.

Example

perm(10,3) will return 720 as given by the formula
10!/(10-3)! = 10!/7! = 10*9*8 = 720.

perm(10.4,3.9) will return 5040 as given by the formula
10!/(10-4)! = 10!/6! = 10*9*8*7 = 5040. The rule about converting a real to Int32 forces 10.4 to 10 and 3.9 to 4.

Notes

Both n and r must be positive and n must be greater than r. If both of the inputs are mapped, then the mappings must be the same. The return value has the same mappings as the input if either input is mapped. If neither of the inputs is mapped, then the output is unmapped.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: perm

See Also

beta(x,y), binomial(a,b), comb(n,r), factorial(n), and gamma(x).


phase(x)

An object that returns the phase of a PComplex number x.

Use

Use phase(x) to extract the phase of a PComplex number x. x can be any shape. For types Complex, PComplex, and Spectrum, phase(x) returns a Real64 container with the value of the polar phase angle of the PComplex number. (Complex is first converted to PComplex.)

Allowed Input Type Return Type

UInt8 UInt8, value of zero

Int16 Int16, value of zero

Int32 Int32, value of zero

Real32 Real32, value of zero

Real64 Real64, value of zero

Coord Coord, value of zero

Waveform Waveform, value of zero

Complex Real64

PComplex Real64

Spectrum Real64

The phase(x) value is returned in the units of the current Trig Mode.

Example

phase((1,@45)) returns 45.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Complex Parts
Member: phase

See Also

conj(x), im(x), j(x), mag(x), re(x), Real Parts, Build PComplex, Default Preferences, and UnBuild PComplex.


poly(x,vec)

A summary notation for objects poly(x,[a0, a1]), poly(x,[a0, a1, a2]), poly(x,[a0, a1, a2, a3]), and poly(x,[a0, a1, ... aN]). These objects return the polynomial value of the x and vec values.

Use

Use poly(x,vec) to generate the polynomial result of the x data and vec coefficients. x can be any shape and the same shape is returned. vec must be either a scalar or a one-dimensional array. poly(x,vec) takes the elements of vec as the polynomial coefficients, and x as the data. vec starts with a0, then a1, and so on, out to the length of vec.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

The polynomial equation computes:

a0 + a1*x + a2*x*x + a3*x*x*x + ...

Example

poly([10, 2], [3, 2, 4]) generates [423, 23].

Notes

Mappings of the resultant container are the same as the input container x.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Power
Member: poly

See Also

ramp (numElem, from,thru).


polynomial regression

An object used to fit a polynomial curve of arbitrary degree to (x,y) data.

Use

Use the polynomial regression to fit the data to the equation
y = C0 + C1*x + C2*x^2 + ... , where x is the x coordinate and C0, C1, and so forth, are calculated coefficients. Polynomial curve fitting requires the degree of the polynomial to be set on the Order input field on the regression object.

The polynomial regression object expects an array of Coord type of input with one independent variable, that is, an (x,y) pair. If the input array is not a Coord type, an attempt is made to convert it to Coord. If the input data is mapped (Waveform, Spectrum, or a mapped array), then the conversion to Coord uses the mapping information to create the x part of the (x,y) pairs. If the input data is not mapped (for example, an array), then the x part of the (x,y) pair is implicitly generated from its position in the array.

Open View Parameters

The Fit Type field on the open view is used to change the regression type to linear, logarithmic, exponential, power curve or polynomial regression. Clicking on the button will bring up a list of the different regression types.

The Order input field is used to set the order of the polynomial to which the data is fitted. The order of the polynomial fit must be greater than or equal to one. A polynomial fit of order one fits the data to a straight line and is the same as the linear regression choice.

Example

See Regression for a Coord conversion example.

Notes

See Regression for general notes on regression.

Location

Device [image] Regression

then select the appropriate Fit Type from the Fit Type field on the dialog box.

See Also

Regression, exponential regression, linear regression, logarithmic regression, meanSmooth (x,numPts), movingAvg (x,numPts), polySmooth (x), power curve regression, and Build Coord.


polySmooth (x)

An object used to smooth data using a polynomial fit of the data.

Use

Use polySmooth(x) to smooth out data. A fourth order polynomial is fitted to the data and a new data point is calculated based on the curve fit using the polynomial. To do the 4th order curve fit, 5 points are used, two on either side of the data point being fitted and the data point itself, with special consideration for the two end points. The x input must be of Array 1D shape.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

The independent variables of a Coord input type must be equidistant. That is, the x-interval between adjacent points must be a constant. The smoothing is only done on the dependent variable (the y data of the Coord).

Notes

The method used is to take a 5-element sliding window and apply the standard formula for a 4th-degree Stirling collocation polynomial. Refer to Francis Scheid, Schaum's Outline of Theory and Problems of Numerical Analysis, McGraw Hill, New York, NY, 1968. ISBN #07-055197-9.

Mappings on the operand are ignored and the output container has the same mappings as the input.

The filtering operation which results from this technique has a fixed "frequency response" which suppresses only the noisiest part of the data. If more noise suppression is required, see the meanSmooth(x,numPts) function, which you can use to suppress much more noise.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Data Filtering
Member: polySmooth

See Also

meanSmooth (x,numPts), movingAvg (x,numPts), Regression types, and Signal Processing.


Power

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Power to access the following objects which perform power functions such as square root, square, log, exp, and log base 10.

sq(x)

sqrt(x)

cubert(x)

recip(x)

log(x)

log10(x)

exp(x)

exp10(x)

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Power

See Also

cubert(x), exp(x), exp10(x), log(x), log10(x), recip(x), sq(x), sqrt(x), a + b (add), a / b (divide), a ^ b (exponent), a * b (multiply), and a - b (subtract).


power curve regression

An object used to fit a power curve to (x,y) data.

Use

Use the power regression to fit the data to the equation y = C0 * x^C1, where x is the x coordinate and C0 and C1 are calculated coefficients.

The power curve regression object expects an array of Coord type of input with one independent variable. That is, an (x,y) pair. If the input array is not a Coord type an attempt is made to convert it to Coord. If the input data is mapped (Waveform, Spectrum, or a mapped array), then the conversion to Coord uses the mapping information to create the x part of the (x,y) pairs. If the input data is not mapped (for example, an array), then the x part of the (x,y) pair is implicitly generated from its position in the array.

Open View Parameters

The Fit Type field on the open view is used to change the regression type to linear, logarithmic, exponential, power curve or polynomial regression. Clicking on the field will bring up a list of the different regression types.

Example

See Regression for a Coord conversion example.

Notes

See Regression for general notes on regression.

This function will not work for unmapped arrays. Unmapped arrays are converted to Coord starting with x=0, which fails in the conversion in the log function. The log function is used in the internal regression calculation.

Location

Device [image] Regression

then select the appropriate Fit Type from the Fit Type field on the dialog box.

See Also

Regression, exponential regression, linear regression, logarithmic regression, meanSmooth (x,numPts), movingAvg (x,numPts), polynomial regression, polySmooth (x), and Build Coord.


Probability & Statistics

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use the Probability & Statistics functions in problems dealing with random numbers, probabilities and statistical calculation.

beta(x,y)

binomial(a,b)

comb(n,r)

erf(x)

erfc(x)

factorial(n)

gamma(x)

logMagDist(x,from,thru,logStep)

magDist(x,from,thru,step)

max(x)

mean(x)

median(x)

min(x)

mode(x)

perm(n,r)

random(low,high)

randomize(x,low,high)

randomSeed(seed)

rms(x)

sdev(x)

vari(x)

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics

See Also

beta(x,y), binomial(a,b), comb(n,r), erf(x), erfc(x), factorial(n), gamma(x), logMagDist (x,from,thru, logStep), magDist(x, from,thru, step), max(x), mean(x), median(x), min(x), mode(x), perm(n,r), random (low,high), randomize (x,low,high), randomSeed (seed), rms(x), sdev(x), and vari(x)


product(x)

An object used to multiply all the elements of the input array.

Use

Use product(x) to multiply together all the elements of the input array. The x input may be of any size and shape.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Real64 Scalar

Waveform Real64 Scalar

Complex Complex

PComplex PComplex

Spectrum PComplex Scalar

The output of this object is the arithmetic product of all the data contained in the input container and is Scalar in shape.

Example

Where x is an array [1, 2, 3, 4], product(x) returns 24.

Notes

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Array
Member: product

See Also

a * b (multiply) and sum(x).


programName()

An object that returns the name of the VEE program currently executing.

Use

Returns the complete path, including the name, of the VEE program currently executing. This function takes no parameters.

Notes

The programName() object is simply a Formula object initialized without inputs and containing the programName() equation. You may also type programName() into any other Formula object or expression.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: System Information
Member: programName

See Also

installDir, commandLine, Formula


ramp (numElem, from,thru)

An object that generates a linearly ramped array.

Use

Use ramp(numElem,from,thru) to generate a Real64 one-dimensional array of length numElem, with the values linearly ramped from from to thru (inclusive). numElem must be a scalar container that is, or can be converted to, Int32 and with a value greater than zero. from and thru must be scalar containers that are, or can be converted to, Real64.

If from is less than thru, the ramping is positive; otherwise it automatically ramps negatively.

Example

ramp(3, 0.5, 0) returns a one-dimensional array with values [0.5, 0.25, 0].

ramp(5, 2, 10) returns a one-dimensional array with values [2, 4, 6, 8, 10].

Notes

The return value has no mappings.

The algorithm for generating values is:

Y[I] = from + I*(thru-from/numElem-1)
for I=0..numElem-1

This has the effect that the last element in the resultant array has the value thru.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Generate
Member: ramp

See Also

Alloc Real64, logRamp (numElem, from,thru), and xramp (numElem, from,thru).


random (low,high)

An object used to generate random numbers between a low and high value. This function generates pseudo-random numbers using the linear congruential algorithm and 48-bit integer arithmetic.

Use

Use random(low,high) to generate pseudo-random numbers between the low and high value. The numbers generated are in the interval including the low value, but not including the high value, which is denoted as "[l h)". The l and h inputs must be Scalar in shape.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

A Real64 Scalar is returned in all cases that are in the range of "[l h)".

This function only outputs a single Scalar value. Use the randomize(x,low,high) function with an array input to generate an array of scaled random numbers.

If the l value is greater than the h value, then the range of random numbers returned is in the interval "(l h]".

Example

random(0,1) will generate real numbers in the range (0.0 1.0). That is, including 0.0, but excluding 1.0.

Notes

random(low,high) will return a Real Scalar container in the range "(0.0 1.0)".

Also, random(low,high) will return a different number each time it is used in a program or if it is activated several times by an iterator object.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: random

See Also

randomize (x,low,high) and randomSeed (seed)


randomize (x,low,high)

An object used to randomize the values of a numeric input container in the range of [low high). The numbers generated are in the interval including low, but not including high, which is denoted as "[low high)". This function generates pseudo-random numbers using the linear congruential algorithm and 48-bit integer arithmetic.

This object can also be used to randomize strings in Text input containers within the range of [low high].

Use

For numeric values:

Use randomize(x,low,high) to generate pseudo-random numbers between low and high, that is, between the low and high value. All of the data in the input container, x is overwritten with the pseudo-random numbers. The x input may be of any size and shape.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Coord, see following

Waveform Waveform

Complex Complex

PComplex see following

Spectrum see following

For PComplex and Spectrum types, only the magnitude of the number is in the range [low high). The phase is random in the range (-PI to PI). For type Coord, only the dependent variable is randomized.

The low and high inputs must be Scalar in shape and of a type that can be converted to the type of x. The random numbers generated are in the range of [low high).

If the low value is greater than the high value, then the range of random numbers returned is in the interval (low high].

For string values:

To randomize a string, use randomize(x,low,high) with input values of the Text data type. The input string (the data container on the x input) will be overwritten by an output string of ASCII characters in pseudo-random order, within the range [low high], where low is the first character in the low input container and high is the first character in the high input container. (Note that the range is inclusive of both low and high, which is different than for numeric values.) The length of the output string is the same as that of the input string.

The default values for low and high are the space (" ", ASCII 32) and the tilde ("~", ASCII 126).

Note
Default values are used for strings when the input data for low or high is "" (null string).

Examples

Numeric example:

If the container on the x input is of the Real64 data type, randomize(x,0,10) will randomize all the values of the input container x to real numbers in the range (0.0 10.0). That is, including 0.0, but excluding 10.0.

String examples:

randomize("abcdef","a","b") might return "abbaba".

randomize("abcabcabcab","a","z") might return "pterodactyl". (Well -- it might!)

randomize("abcabc","","") might return "Al@z~#". (With null strings for low and high, the default limits -- ASCII 32 through 126 -- are used.)

randomize("aaaaa","go","stop") might return "smjpg". (Only the first characters in low and high count in determining the range.)

randomize("aaaaa","97","99") returns "99999". (The low and high values are interpreted as strings, not ASCII decimal values.)

Notes

Mappings on input parameters are ignored and the output has the same mappings as the input parameter x.

For a numeric x input, randomize(x) will return a container the same size and shape as x, but with the data randomized in the range (0.0 - 1.0).

For string operations, the character set for output cannot be defined outside the limits low = ASCII 32 and high = ASCII 126. That is, the ASCII characters below 32 and above 126 are not allowed for output in the randomized string.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: randomize

See Also

random (low,high) and randomSeed (seed).


randomSeed (seed)

An object used to set initial values for the random(low,high) and the randomize(x,low,high) functions.

Use

Use randomSeed(s) to input a random seed entry point for the linear congruential algorithm used by the random(low,high) and the randomize(x,low,high) functions.

The seed input s must be Scalar in shape and of the type Int32 or of a type able to be converted to Int32. The return value of this function is the s seed value.

Example

randomSeed(97) initializes the pseudo-random number algorithm.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: randomSeed

See Also

random (low,high) and randomize (x,low,high).


re(x)

An object that returns the real part of a Complex number x.

Use

Use re(x) to extract the real part of a Complex number x. x can be any shape.

Allowed Input Type Return Type

UInt8 UInt8, with same value

Int16 Int16, with same value

Int32 Int32, with same value

Real32 Real32, with same value

Real64 Real64, with same value

Coord Coord, with same value

Waveform Waveform, with same value

Complex Real64, value of the real part of the Complex number

PComplex Real64, value of the real part of the Complex number

Spectrum Real64, value of the real part of the Complex number

PComplex is first converted to Complex.

Example

re( (1,2) ) returns 1.

re(1,@180), with Trig Mode in Degrees, returns -1.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Complex Parts
Member: re

See Also

Complex Parts, conj(x), im(x), j(x), mag(x), phase(x), and Real Parts.

Build Complex and UnBuild Complex.


Real Parts

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Real Parts to access the following objects which return different real parts of a container.

abs(x)

signof(x)

ordinal(x)

round(x)

floor(x)

ceil(x)

intPart(x)

fracPart(x)

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Real Parts

See Also

abs(x), ceil(x), floor(x), fracPart(x), intPart(x), ordinal(x), round(x), signof(x), and Complex Parts.


recip(x)

An object that returns the reciprocal of the value of x.

Use

Use recip(x) to generate the reciprocal of a number; that is, one divided by the number x. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

For PComplex, the recip(x) is defined as the reciprocal of the magnitude, and the phase's sign is reversed. Complex is converted to PComplex before the function is applied.

Example

recip( (5, @45) ) returns (0.2, @-45).

recip( (1,-1)) ) returns (0.5, 0.5).

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Power
Member: recip

See Also

a / b (divide), Power, sq(x), and sqrt(x).


rect(x)

An object used to apply a rectangular window to a time series of values.

Use

Use rect(x) to filter the values in x in the same manner as convolving x with the spectral transform of the rectangular function. This has the effect of suppressing some of the noise due to the tails of the input sequence and the potential discontinuities they represent when sampling periodic signals. The input x must be an Array 1D.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Spectrum Spectrum

If x is a Spectrum, it is first converted to a Waveform using an ifft(x) before the window is applied. The result of the window is then converted back to type Spectrum using an fft(x).

Example

rect([1, 1, 1, 1, 1, 1, 1, 1]) returns [1, 1, 1, 1, 1, 1, 1, 1].

Notes

The rect function is represented in the time domain as 1 for all values, where
0 <= n <= N -1, where n is the position (index) in the array, and N is the size of the array. The result will be an array of the same type as x and will have the same mappings as x (if any).

For a discussion of sidelobe levels and coherent gains, see: Ziemer, Tranter, and Fannin, Signals and Systems, Macmillan Publishing, New York, NY, 1983. ISBN #0-02-431650-4.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Signal Processing
Member: rect

See Also

bartlet(x), blackman(x), convolve(a,b), fft(x), hamming(x), and hanning(x).


Regression

A menu item.

Use

Use Regression to fit various types of regression equations to data.

linear

logarithmic

exponential

power curve

polynomial

Notes

All the Regression objects expect an array of Coord type for input. If the input array is not a Coord type it is converted to Coord. The conversion to Coord type follows standard type conversion rules summarized here. If the input array is not mapped, then an implicit x parameter is generated from the array indices. That is, the regression must be done on (x,y) pairs. The x values will start at zero and range to n - 1, where n is the number of data points. If the input array is mapped then the generated x data will range from the low value of the mapping to the high value of the mapping.

The regression gives as output an array of data fitted to the equation chosen. The number of points of the output array is the same as in the input data array. It also outputs an array of coefficients that corresponds to the derived constants for each regression type. See the individual regression type to determine to which equation the data is fitted. The third output is the R-squared or "goodness of fit" coefficient. It ranges between -1 and 1. A fit of -1 or 1 is an exact fit and numbers in between -1 and 1 represent varying degrees of goodness of fit.

Example

You have an unmapped array input [10, 20, 30, 40, 50]. It would be converted to Coord array:

[ (0, 10), (1, 20), (2, 30), (3, 40), (4, 50) ].

If an input array is the array [1, 2, 3, 4, 5], and it is mapped from 1 to 2 (seconds for instance), it would be converted to Coord array:

[ (1, 1), (1.25, 2), (1.5, 3), (1.75, 4), (2, 5) ].

Location

Device [image] Regression

See Also

exponential regression, linear regression, logarithmic regression, polynomial regression, power curve regression, meanSmooth (x,numPts), movingAvg (x,numPts), and polySmooth (x).

Properties (Object)


rms(x)

An object used to return the rms (Root Mean Square) value of the data in the input container.

Use

Use rms(x) to calculate the Root Mean Square value of the input container. The rms value is defined as the square root of [(The sum of x^2)/N], where N is the number of the points. The x input may be of any size and shape.

Allowed Input Type Return Type

UInt8 Real64 Scalar

Int16 Real64 Scalar

Int32 Real64 Scalar

Real32 Real64 Scalar

Real64 Real64 Scalar

Coord Real64 Scalar

Waveform Waveform

For Coord input types, the operation is done on the dependent variable.

Example

Where x is the array [1, 2, 3, 4, 5, 11, 12, 13, 14, 34], rms(x) returns 13.319159.

Notes

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: rms

See Also

max(x), mean(x), median(x), min(x), mode(x), sdev(x), and vari(x).


rotate(x, numElem)

An object used to rotate elements in an array.

Use

Use rotate(x,n) to rotate the elements of the input array x by n positions. The x input may be of any size and shape.

Allowed x Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Text Text

The input n must be a scalar Int32 or be able to be converted to Int32 type. If the n rotate value is a positive value, the rotation direction is down the array (forward). For example, if n was 2, then the first element of the array would end up in the third position (x[2]) , the second element ends up in the fourth position (x[3]), and so on. If the n value is negative, the array elements are rotated up the array (backward).

If the rotate number n is larger than the number of elements in the array, then the number of places to rotate is calculated by taking the modulo of the rotate number by the number of array elements. For example, if the input array has 5 elements and you want to rotate the array 13 places, the modulo operation (13 MOD 5 = 3) determines that the array should be rotated 3 places.

Example

rotate(x,5) rotates the input array elements 5 positions further to the right in the array.

rotate(x,15), where the input array x has 15 elements, does nothing because you have rotated the array back on top of itself.

rotate([1, 2, 3, 4, 5], 1) returns [5, 1, 2, 3, 4].

Notes

You might think of the array as a circular list when using the rotate function, meaning that the last element in the array is connected to the first array element. When you rotate array elements past the end of the array, they wrap back around to the top of the list. For example, if the array is 10 elements long and you do a rotate(A,5), then the tenth array element number will end up in fifth position in the array.

Mappings on input parameters are ignored and the output has the same mappings as the input parameter x.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Array
Member: rotate

See Also

concat(x,y) and init(x,val).


round(x)

An object that returns the rounded value of x.

Use

Use round(x) to obtain the rounded value, to the nearest integer, of a container. x may be any shape. The round(x) function returns the closest integer (as the same type) to x. The dividing line is at 0.5, which rounds up.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Coord

Waveform Waveform

Example

round([23.0, 23.1, 23.9, 23.5, (-23.5)]) returns
[23, 23, 24, 24, -23].

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Real Parts
Member: round

See Also

abs(x), ceil(x), Complex Parts, floor(x), fracPart(x), intPart(x), and Real Parts.


savePanelImage(UFName, fileName, numColors)

Saves the panel image of the UserFunction named UFName to the file fileName using a pixel depth of numColors.

Use

Use savePanelImage(UFName, fileName, numColors) to programmatically render a VEE UserFunction panel to a standard graphics file. This lets you refer to a VEE UserFunction panel in a report. UserObject panels are not supported in the savePanelImage function.

When running a program repeatedly, the graphics file will be overwritten without notifying you, unless you change fileName.

Open View

The function includes three parameters; only UFName is required:

"UFName" - (required) The name in the UserFunction title bar. You can also use the special name "Execution Window" (entered exactly as shown here) in place of "UFName". Double-quotes must surround this name.

"fileName" (optional) The target file name for the rendered image, which can include a destination drive and directory. Double-quotes must surround this name. The default file name uses UFName’s base name. If UFName is Execution Window, the default file name will be Execution. The default destination is the VEE default working directory, which is "C:\My Documents" in the standard VEE installation.

The file name extension for fileName determines the output file’s graphics format. The default graphics format is JPEG. Supported formats are

.bmp - Bitmap

.jpg/.jpeg - Joint Photographic Experts Group (JPEG)

numColors (optional) The color-depth, specifying the maximum number of colors per pixel. This number is a power of two (2, 4, 8, ... 2M). The default is 256.

Note
numColors applies only to Bitmap graphics files (.bmp). Specifying a smaller number will reduce the resulting file size, and will degrade the image clarity.

Examples

The following example renders an image of the local UserFunction named my_userfunc, writing a file using the defaults for the optional parameters. The file is saved as my_userfunc.jpeg, in VEE's current working directory.

savePanelImage("my_userfunc")

The following example is similar to the previous one, except the expressions will save the Execution Window in its current state.

savePanelImage("Execution Window")

The following example renders an image of the local UserFunction named someUF, writing a file named myimage.jpeg in the destination d:\tmp\somedir using the JPEG format.

savePanelImage("someUF", "d:/tmp/somedir/myimage.jpeg")

The following example renders an image of the local UserFunction named someUF, writing a file named myimage.bmp in the destination d:\tmp\somedir using the BMP format. It writes the file using 16 colors per pixel instead of the default 256.

savePanelImage("someUF", "d:/tmp/somedir/myimage.bmp", 16)

The following example renders an image of the imported UserFunction named statusPanel, which is located in the library lib1. It writes a file named status.jpeg using the JPEG format in the directory /usr/lib/veepanels.

savePanelImage("lib1.statusPanel", "/usr/lib/veepanels/status.jpeg")

Notes

The savePanelImage() function is created in a Formula object that is preconfigured with a data input for each of the three parameters. You can enter a savePanelImage() function call in any other Formula object.

You can enter the entire expression programmatically by adding the control input named Formula.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Panel
Member: savePanelImage

See Also

Call, Execution Window, hidePanel(), showPanel(), and UserFunction.


sdev(x)

An object used to return the standard deviation of the data in the input container.

Use

Use sdev(x) to calculate the standard deviation of the container. sdev(x) is defined as the square root of the vari(x). The x input may be of any size and shape.

Allowed Input Type Return Type

UInt8 Real64 Scalar

Int16 Real64 Scalar

Int32 Real64 Scalar

Real32 Real64 Scalar

Real64 Real64 Scalar

Coord Real64 Scalar

Waveform Real64 Scalar

For Coord input types, the operation is done on the dependent variable.

Example

Where x is the array [1, 2, 3, 4, 5, 11, 12, 13, 14, 34], sdev(x) returns 9.50789.

Notes

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: sdev

See Also

max(x), mean(x), median(x), min(x), mode(x), rms(x), and vari(x).


setBit(x,n)

An object that returns x with the nth bit set to 1.

Use

Use setBit(x,n) to set a particular binary digit of a container x to 1. x can be any shape. If x is of type Real32, Real64, Coord or Waveform, it is converted to Int32 before the operation.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Int32

Real64 Int32

Coord Int32

Waveform Int32

n must be a container which is, or can be converted to, Int32 and have a value between 0 and 31 inclusive. n must be either scalar or match the shape of x.

Example

setBit(8,0) returns 9.

setBit(8.24,0.9) also returns 9.

Notes

The mappings of the return value are the same as the x parameter.

The least significant bit is on the right, and the most significant bit is on the left.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bitwise
Member: setBit

See Also

bit(x,n), bits(str), Bitwise, and clearBit(x,n).


showPanel()

An object that displays a UserFunction panel.

Use

Use showPanel() to display a UserFunction
 panel until hidePanel() is executed or
 the program finishes running. showPanel()
 allows you to have a status panel up for as long as you need it. To use
 showPanel(), Show
 Panel on Execute must not be selected on the UserFunction.

Open View

The three versions of showPanel() objects exist to show you the syntax to use. You must include the text showPanel() in the edit field. Inside the parenthesis, you can type the following parameters in any of the objects:

"UFname" - The name of the UserFunction. You must have double quotes around this name. This parameter is required.

x, y - The location (in pixels) for the upper-left corner of the UserFunction panel (including the area for the border and title bar if they exist). This parameter is optional; if you do not specify the x and y coordinates, the panel is displayed in the center of the work area.

width, height - The size of the panel (in pixels). This parameter is optional; if you specify width and height, you must specify the x, y parameters. If you do not specify width and height, the current panel size is used. width and height settings add and delete space from the right and lower sides of the panel view and include the title bar and border if they exist.

You may add data input pins to the showPanel() object to set any of the parameters if you replace the parameter with the input terminal name.

Notes

showPanel() does not run the UserFunction, it only displays the Panel View. To see the panel and run the UserFunction, first use showPanel() and then call the UserFunction.

If you only want to see the Panel View when the UserFunction operates, select Show Panel on Execute from the UserFunction Properties window instead of using showPanel().

The showPanel() object is simply a Formula object initialized without inputs and containing the showPanel(...) equation. You may also type showPanel() (and the associated parameters) into any objects that allow expressions, such as the Formula and Sequencer objects.

You may input the entire showPanel() equation via control pin.

VEE does not limit the location of the pop-up panel to the size of your work area, it is possible to specify an x and y that are "off screen" (out of the visible window).

All panels shown with showPanel() are only shown while the program is running.

You can have only one copy of a UserFunction panel showing at a time. If you call showPanel() additional times with the same UserFunction name, the latest call of the panel is shown and the previous is hidden.

To find the name of a panel that is showing, click the right mouse button on the panel and the panel name pops up.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Panel
Member: showPanel

See Also

Call, hidePanel(),
 lockPosition(), panelPosition(),
 panelSize(), unlockPosition(),
 and UserFunction.


Signal Processing

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Signal Processing to access one of several signal processing functions that can be applied to one-dimensional arrays (UInt8, Int16, Int32, Real32, Real64, Complex, PComplex, Waveform, Spectrum) for some functions, and lists of two-dimensional (two field) coordinates.

fft(x)

ifft(x)

convolve(a,b)

xcorrelate(a,b)

bartlet(x)

hamming(x)

hanning(x)

blackman(x)

rect(x)

Notes

The Built-in Functions under Signal Processing are applicable to one-dimensional arrays of values that represent ordered, equally spaced data.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Signal Processing

See Also

bartlet(x), blackman(x), convolve(a,b), fft(x), hamming(x), hanning(x), ifft(x), rect(x), and xcorrelate (a,b).


signof(x)

An object that returns the sign of x.

Use

Use signof(x) to obtain the sign of a container. x may be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Int32

Real64 Int32

Coord Int32

Waveform Int32

The return will have a value of -1, 0, or +1, depending on whether the x value is negative, zero, or positive. If x is negative, -1 is returned; if x is zero, 0 is returned; if x is positive then +1 is returned.

Example

signof([23, 0, -1]) returns [1, 0, -1].

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Real Parts
Member: signof

See Also

abs(x), Complex Parts, and mag(x).


sin(x)

An object that returns the sine of x.

Use

Use sin(x) to generate the sine of the x data. x is assumed to be in the current Trig Mode units. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

sin([0, PI/2]) returns [0, 1] with Trig Mode set to Radians.

sin((1, @PI)) returns (0.84147, @3.14159) with Trig Mode set to Radians.

Notes

Mappings are retained in the result. Using Trig Mode set to anything except Radians may result in accuracy errors beyond the 12th significant digit.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: sin

See Also

asin(x), cos(x), tan(x), sinh(x), Trig, and Default Preferences.


sinh(x)

An object that returns the hyperbolic sine of x.

Use

Use sinh(x) to generate the hyperbolic sine of the x data. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

sinh(1.2) returns 1.509.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: sinh

See Also

asinh(x), cosh(x), Trig, sin(x), and tanh(x).


sort(x, direction, field)

A function that sorts an array of data (any data type).

Use

Use the sort function in a Formula object to sort an array of data on input x. All data types are allowed, and by default the data is sorted in ascending order. If you use sort in a Formula object the syntax is:

sort(x [,direction [,field] ] )

where:

direction (optional) specifies the direction of sort. The default is ascending order, and any non-zero value will specify ascending order. A value of 0 specifies a sort in descending order.

field (optional) specifies the field on which to sort the array:

For the real, integer, and Text data types, this parameter is ignored.

For the Complex data type, specify 0 or "real" to sort on the real field. Specify 1 or "imag" to sort on the imaginary field. All three parameters must be specified.

For the PComplex data type, specify 0 or "mag" to sort on the magnitude field. Specify 1 or "phase" to sort on the phase field. All three parameters must be specified.

For the Coordinate data type, the array will be sorted by the dependent field by default ("y" in an x-y pair, "z" in an x-y-z triplet). Specify 0 or "x" to sort on the x field, 1 or "y" to sort on the y field, and so forth. (Note that for the Coordinate data type, the field names will always be x, y, z, w, v, u, t, s, r, q even though you may change the input terminal names.)

For the Record data type, the array will be sorted by the first field by default. Or you can specify the field by number (0, 1, and so forth) or by name ("operator", "date", etc.).

Examples

sort(x) will sort a real array x in ascending order.

sort(x,0) will sort a real array x in descending order.

sort(x,1,"real") or sort(x,1,0) will sort a Complex array x by the real field in ascending order.

sort(x,0,"phase") or sort(x,0,1) will sort a PComplex array x by the phase field in descending order.

sort(x,1,"A") or sort(x,1,0) will sort a Coordinate array x by the "A" field in ascending order.

sort(x,1,1) will sort a Record array x by the second field in ascending order.

Notes

Text data is sorted by the standard ASCII character-code order. Thus, uppercase letters come before lowercase letters.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Array
Member: sort

See Also

Formula.


sq(x)

An object that returns the square of the value of x.

Use

Use sq(x) to perform the squaring of a number x (multiplies the value of x times itself). x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

sq([1, 4]) returns [1, 16].

sq((1,2)) returns the complex number (-3,4).

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Power
Member: sq

See Also

Power and sqrt(x).


sqrt(x)

An object that returns the square root of the value of x.

Use

Use sqrt(x) to generate the square root of a number x. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

For PComplex, the sqrt(x) is defined as the square root of the magnitude and half the phase. Complex is converted to PComplex before the function is applied.

Example

sqrt( (16, @90) ) will return (4, @45).

sqrt( (1,1) ) will return (1.1, 0.455).

sqrt([4, 9, 64]) will return [2, 3, 8].

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Power
Member: sqrt

See Also

cubert(x), a ^ b (exponent), Power, and sq(x).


Statistics

See Probability & Statistics.


strDown(str)

An object that changes all uppercase alphabetic characters in a string to lowercase characters.

Use

Use strDown(str) to change the case of an input string str to lowercase. All uppercase alphabetic characters ("A" through "Z") are converted to the corresponding lowercase characters ("a" through "z"). Non-alphabetic ASCII characters are left unchanged.

Examples

strDown("ABCdefg%+#") returns "abcdefg%+#"

strDown("123456") returns "123456"

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String
Member: strDown

See Also

strRev(str), strTrim (str,trimlist), strUp(str), and String.


strFromLen (str,from,len)

An object that returns a substring of a specified length and starting point.

Use

Use strFromLen(str,from,len) to return a substring from the input string str, beginning at index position from and of length len in bytes. If from = 0, the substring starts at the beginning of the input string. Base 0 indexing of the string is used.

Notes

If the value of len is less than or equal to 0, a nil string will be returned.

If the value of from is greater than the length of the input string str, a nil string will be returned.

If the value of len is greater than the length of the input string str, the returned string stops at the end of the input string.

If the input string is an array of strings, each element of the input array is operated on as a separate string. The return value is a string array.

Examples

strFromLen("Now is the time",0,6) returns "Now is"

strFromLen("Now is the time",6,9) returns " the time"

strFromLen("Now is the time",0,30) returns "Now is the time"

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String
Member: strFromLen

See Also

strFromThru (str,from, thru), strPosChar (str,char), strPosStr (str1,str2), and String.


strFromThru (str,from, thru)

An object that returns a substring of a specified starting point and ending point.

Use

Use strFromThru(str,from,thru) to return a substring from the input string str, beginning at index position from and ending at index position thru. If from = 0, the substring starts at the beginning of the input string. Base 0 indexing of the string is used.

Notes

Negative values of from or thru are converted to 0.

Values of from or thru that are greater than the length of the input string str are converted to the index position of the last character in the input string.

If the value of from is greater than the length of the input string str, or greater than thru, a nil string is returned.

If the input string is an array of strings, each element of the input array is operated on as a separate string. The return value is a string array.

Examples

strFromThru("Now is the time",0,6) returns "Now is "

strFromThru("Now is the time",0,0) returns "N"

strFromThru("Now is the time",6,9) returns " the"

strFromThru("Now is the time",0,30) returns "Now is the time"

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String
Member: strFromThru

See Also

strFromLen (str,from,len), strPosChar (str,char), strPosStr (str1,str2), and String.


String

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use the String functions to perform these operations on string data:

strDown(str)

strFromLen(str,from,len)

strFromThru(str,from,thru)

strLen(str)

strPosChar(str,char)

strPosStr(str1,str2)

strRev(str)

strTrim(str)

strUp(str)

intToChar(a)

charToInt(a)

Notes

All of the string functions are capable of operating on inputs that are string arrays. The results will be a text or number array. Operations are done on each individual element of the input string array.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String

See Also

charToInt(a), intToChar(a), strDown(str), strFromLen (str,from,len), strFromThru (str,from, thru), strLen(str), strPosChar (str,char), strPosStr (str1,str2), strRev(str), strTrim (str,trimlist), and strUp(str).


strLen(str)

An object used to determine the length of a string in bytes.

Use

Use strLen(str) to determine the length of an input string str. The return value is an Int32 Scalar giving the number of bytes present. Kanji characters and other 16-bit characters count as two bytes each.

Notes

If the input string is an array, the length of each element will be returned in an output array.

Examples

strLen("ABCdefg%+#") returns 10

strLen("123456") returns 6

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String
Member: strLen

See Also

String.


strPosChar (str,char)

An object that returns the index within the input string str of any character in the character list char.

Use

Use strPosChar(str,char) to return the index within the input string str of the first occurrence of any character in character list char. Base 0 indexing of the string is used.

Notes

If there is more than one occurrence of more than one listed character, only the index of the first listed character found is returned.

If none of the characters listed in char are found in the input string str, a value of -1 is returned.

If either str or char is the nil string, a value of -1 is returned.

Note that the character match is case sensitive.

If the input string is an array, each element of the array is searched as a separate string. The positions of characters in the string elements are put in an output array.

Examples

strPosChar("Now is the time","Nwme") returns 0

strPosChar("Now is the time","nwme") returns 2

strPosChar("Now is the time","x yz ") returns 3

strPosChar("Now is the time","") returns -1

strPosChar("Now is the time","xyz") returns -1

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String
Member: strPosChar

See Also

strFromLen (str,from,len), strFromThru (str,from, thru), strPosStr (str1,str2), and String.


strPosStr (str1,str2)

An object that returns the index of string str2 within string str1.

Use

Use strPosStr(str1,str2) to return the index of the first occurrence of string str2 within string str1 -- that is, the index position within str1 where str2 begins. Base 0 indexing is used.

Notes

If str2 occurs more than once in str1, only the index of the first occurrence is returned.

If an occurrence of str2 is not found within str1, a value of -1 is returned.

If either str1 or str2 is the nil string, a value of -1 is returned.

Note that the character match is case sensitive.

If the input string is an array, each element of the array is searched as a separate string. The positions of strings in the string elements are put in an output array.

Examples

strPosStr("Now is the time","Now") returns 0

strPosStr("Now is the time","is the") returns 4

strPosStr("Now is the time","") returns -1

strPosStr("Now is the time","is The") returns -1

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String
Member: strPosStr

See Also

strFromLen (str,from,len), strFromThru (str,from, thru), strPosChar (str,char), and String.


strRev(str)

An object used to reverse the order of a string.

Use

Use strRev(str) to reverse the order in which the characters in a string appear.

Notes

If the input string is an array, the return value is a string array with each element reversed.

Examples

strRev("ABCdefg%+#") returns "#+%gfedCBA"

strRev("123456") returns "654321"

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String
Member: strRev

See Also

strDown(str), strTrim (str,trimlist), strUp(str), and String.


strTrim (str,trimlist)

An object used to trim spaces and tab characters from the front and back of a string.

Use

Use the strTrim(str) object to trim leading and trailing spaces and tab characters from an input string str. All spaces and tab characters that precede the first non-space/non-tab character, or follow the last non-space/non-tab character, are trimmed. In a Formula object the complete syntax is:

strTrim(str [,trimlist] )

Use strTrim(str,trimlist) to trim off any characters from str that are contained in trimlist. Note that these characters are trimmed only if they are leading or trailing characters in str.

Notes

You can extend the syntax of this function to strTrim(str,trimlist) by using it in a Formula object with two inputs: str and trimlist. In this case, any characters listed in the trimlist string, if leading or trailing, are trimmed from the str input string.

If the input string is an array, the return value is a string array with each element trimmed.

Examples

strTrim(" ABCdefg%+#") returns "ABCdefg%+#"

strTrim("eeeABCdefg%+#","eg#") returns "ABCdefg%+"

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String
Member: strTrim

See Also

strDown(str), strRev(str), strUp(str), and String.


strUp(str)

An object used to change all lowercase alphabetic characters in a string to uppercase characters.

Use

Use strUp(str) to change the case of an input string str to uppercase. All lowercase alphabetic characters ("a" through "z") are converted to the corresponding uppercase characters ("A" through "Z"). Non-alphabetic ASCII characters are left unchanged.

Notes

If the input string is an array, the return value is a string array with each element treated as a separate string.

Examples

strUp("ABCdefg%+#") returns "ABCDEFG%+#"

strUp("123456") returns "123456"

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: String
Member: strUp

See Also

strDown(str), strRev(str), strTrim (str,trimlist), and String.


a - b (subtract)

An object that performs an arithmetic subtraction on two operands.

Use

Use a - b to subtract the value of one container from another container. The two containers may be any shape, and the same shape is returned.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

If one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is a container of the highest type.

If both operands are of type Coord, they must have their independent variable(s) match exactly or an error is returned. The subtraction is only performed on the dependent (last) variable.

Example

Array minus a scalar: [1, 2, 3] - 3 returns [-2, -1, 0].

Scalar minus an array: 3 - [1, 2, 3] returns [2, 1, 0].

Two arrays: [4, 5, 6] - [3, 2, 1] returns [1, 3, 5].

Two Complex scalars: (2,4) - (1,3) returns (1,1).

Two Coord scalars: coord(1,3) - coord(1,5) returns coord(1,-2).

Two Coord scalars: coord(1,3) - coord(2,5) returns an error.

Notes

If either of the containers is mapped (that is, of type Waveform, Spectrum, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings. The return value will have the same mappings as the operands; otherwise an error is returned.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Arithmetic
Member: -

See Also

a + b (add), a / b (divide), and a * b (multiply).


sum(x)

An object used to sum up (add) all the elements of the input array.

Use

Use sum(x) to add together all the elements of the input array. The x input may be of any size and shape.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Coord Real64 Scalar

Waveform Real64 Scalar

Complex Complex

PComplex PComplex

Spectrum PComplex

Text Text Scalar

The output of this object (for numeric types) is the arithmetic sum of all the data contained in the input container and is a Scalar. For Text type input, the output is a Scalar Text container and contains the concatenation of all of the Text elements together to form one large string.

The sum(x) object obeys the same rules for Text string addition as the dyadic operator +.

Example

Where x is an array [1, 2, 3, 4], sum(x) returns 10.

Where x is an array ["first", "second", "third"], sum(x) returns "firstsecondthird".

Notes

Mappings on the operand are ignored.

Note the difference between the concat(x,y) and sum(x) functions on text inputs. The concat(x,y) creates an Array 1D in all cases. The sum(x) function will simply link all the text strings together to form one large output string. That is, concat(x,y), where x is the Scalar Text value "a" and y is the Scalar Text value "b", yields the Array 1D ["a","b"]. On the other hand, sum(["a","b"]) will return the Scalar container with the Text value of "ab" in it.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Array
Member: sum

See Also

a + b (add), concat(x,y), and product(x).


tan(x)

An object that returns the tangent of x.

Use

Use tan(x) to generate the tangent of the x data. x can be any shape and the same shape is returned. x is assumed to be in the current Trig Mode units.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

tan([0, 45]) returns [0, 1] with Trig Mode set to Degrees.

tan((1, 2)) returns (33.8128m, 1.01479) with Trig Mode set to Radians.

tan((3, @PI/2)) returns (0.99505, @1.57079) with Trig Mode set to Radians.

Notes

Mappings are retained in the result. Using Trig Mode set to anything except Radians may result in accuracy errors beyond the 12th significant digit.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: tan

See Also

atan(x), atan2(y,x), cos(x), cot(x), sin(x), tanh(x), Trig, and Default Preferences.


tanh(x)

An object that returns the hyperbolic tangent of x.

Use

Use tanh(x) to generate the hyperbolic tangent of the x data. x can be any shape and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Complex Complex

PComplex PComplex

Spectrum Spectrum

Example

tanh(0.6) returns 0.537.

Notes

Mappings are retained in the result.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig
Member: tanh

See Also

atanh(x), cosh(x), Trig, sinh(x), and tan(x).


Time & Date

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Time & Date to access the following objects which perform date and time conversions.

now()

wday(aDate)

mday(aDate)

month(aDate)

year(aDate)

dmyToDate(d,m,y)

hmsToSec(h,m,s)

hmsToHour(h,m,s)

Notes

The now() and dmyToDate(d,m,y) functions will output a time as the number of seconds since the beginning of the Epoch (00:00 hours 1 January 0001 AD) and is stored in UTC (Universal Coordinated Time). That is, a correction is applied for the time zone difference between your local time and GMT (Greenwich Mean Time). Since the wday(), mday(), month(), and year() functions expect a UTC type of time as input (from the now(), dmyToDate,(), Time Stamp or Date Time constant), they will remove the correction before doing the calculation.

The hmsToSec(h,m,s) and hmsToHour(h,m,s) are only doing conversion to delta (elapsed) time and do not apply any UTC correction. You may notice that output from one of these functions displayed in an alpha display (in some Time format) is off by the number of hours between your time zone and UTC. You will need to display this information with the Delta Time: time selection on the alpha Time Stamp display on transactions.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Time & Date

See Also

dmyToDate (d,m,y), hmsToHour (h,m,s), hmsToSec (h,m,s), mday(aDate), month(aDate), now(), wday(aDate), year(aDate), and To String.


totSize(x)

An object that returns an Int32 value that is the total size of a container.

Use

Use the totSize(x) function in a Formula object to determine the size of the container on input x. If x is a scalar or an array with one element, totSize(x) will return a value of 1.

Examples

For x= scalar: totSize(x) returns 1.

For x= [1]: totSize(x) returns 1.

For x= [1, 2]: totSize(x) returns 2.

For x= [ [1, 2] ,[3 ,4] ]: totSize(x) returns 4.

Notes

The totSize(x) function performs the same function as the TotSize pin in the Get Values object.

This object does not accept zero-element arrays.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Array
Member: totSize

See Also

Formula, and Get Values.


transpose(x)

An object used to calculate the transpose of a 2D array (a matrix).

Use

Use transpose(x) to return the transpose of a matrix. The x input must be any 2-Dimensional matrix. It does not have to be square.

Allowed Input Type Return Type

UInt8 UInt8

Int16 Int16

Int32 Int32

Real32 Real32

Real64 Real64

Complex Complex

PComplex PComplex

Text Text

Examples

Where x is a square matrix [ [1, 2], [3, 4] ], transpose(x) returns
[ [1, 3], [2, 4] ].

Where x is a matrix [ [1, 2, 3], [4, 5, 6] ], transpose(x) returns
[ [1, 4], [2, 5], [3, 6] ].

Notes

Mappings on the operand are ignored and the output container has its mappings transposed.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Matrix
Member: transpose

See Also

det(x), identity(x), and inverse(x).


Triadic Operator

An operator that returns the result of one expression if a condition is true, but returns the result of another expression if that condition is false.

Use

Use the triadic operator in a Formula object with the following syntax:

(condition ? expression : expression)

If the condition is true, the result of the first expression is returned.

If the condition is false, the result of the second expression is returned.

The triadic operator must be used within a Formula object or other object that takes an expression.

Example

(A<10 ? A*2 : A*3) returns the result of A*2 if A<10 is true, but returns the result of A*3 if A<10 is false.

Notes

The enclosing parentheses are required.

The triadic operator is useful in setting up "IF/THEN/ELSE" conditional tests. The syntax is the same as for the C language triadic operator.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Miscellaneous
Member: (a ? b : c)

See Also

Comma Operator, Formula, If/Then/Else, and Miscellaneous Operators.


Trig

A Category of Built-in Functions on the Function & Object Browser dialog box.

Use

Use Trig to access the following objects which perform trigonometric functions on data.

acos(x)

acosh(x)

acot(x)

acoth(x)

asin(x)

asinh(x)

atan(x)

atan2(y,x)

atanh(x)

cos(x)

cosh(x)

cot(x)

coth(x)

sin(x)

sinh(x)

tanh(x)

tan(x)

Notes

All Trig operations are performed in Radians. If Trig Mode is set to Degrees, all containers must be converted from Degrees to Radians before the function can be performed. Therefore, for the best performance, use Trig Mode set to Radians.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Trig

See Also

acos(x), acosh(x), acot(x), acoth(x), asin(x), asinh(x), atan(x), atan2(y,x), atanh(x), cos(x), cosh(x), cot(x), coth(x), sin(x), sinh(x), tanh(x), tan(x), and Default Preferences.


typeName(x)

An object that returns the data type of x.

Use

Use typeName(x) to report the data type currently in a container. x may be of any size and shape. Returns one of the following names as Text:

VEE 6 Mode All Other Modes

Uint8 | Uint8
Int16 | Int16
Int32 | Int32
Real32 | Real32
Real64 | Real
Complex | Complex
PComplex | PComplex
Text | Text
Enum | Enum
Coord | Coord
Waveform | Waveform
Spectrum | Spectrum
Record | Record
Object | Object

Example

Where x is a Complex array,
typeName(x) returns Complex.

Notes

If x is declared as a Variant, typeName(x) returns the data type of the contents of x. For example, if x is a Variant that currently contains an Int32, typeName(x) returns Int32.

Location

Location: Device [image] Function & Object Browser

Type: Built-in Functions
Category: Type Conversion

See Also

isVariant(x), isVariantBool(x), isVariantCurrency(x), isVariantDate(x), isVariantEmpty(x), isVariantError(x), isVariantNull(x).


unlockPosition()

An object that allows a user to move the UserFunction panel that is currently being shown.

Use

When you use showPanel() to display a UserFunction panel, and have used lockPosition() or have checked the Lock Panel Position property to prevent the user from moving the panel, use unlockPosition() to allow the user to move the panel.

Open View

You must include the text unlockPosition(). Inside the parenthesis, you type the following parameter:

"UFname" - The name of the UserFunction. You must have double quotes around this name. This parameter is required.

You may add a data input pin to the unlockPosition() object to set the UserFunction name, but you must replace "UFname" with the input terminal name.

Notes

The unlockPosition() object is simply a Formula object initialized without inputs and containing the unlockPosition() equation. You may also type unlockPosition() into any other Formula object or expression.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Panel
Member: unlockPosition

See Also

Call, hidePanel(),
 lockPosition(), panelPosition(),
 panelSize(), showPanel(),
 and UserFunction.


vari(x)

An object that returns the variance of the data in the input container.

Use

Use vari(x) to calculate the variance of the data in the input container. x may be of any size and shape.

Allowed Input Type Return Type

UInt8 Real64 Scalar

Int16 Real64 Scalar

Int32 Real64 Scalar

Real32 Real64 Scalar

Real64 Real64 Scalar

Coord Real64 Scalar

Waveform Real64 Scalar

For Coord input types, the operation is done on the dependent variable.

The vari(x) is defined as:
[The SUM of (Xi - Xmean)^2] divided by (numPts - 1)
where Xi is the individual data point, Xmean is the mean of the data points, and numPts is the number of elements in the input array x.

Example

Where x is the array [1, 2, 3, 4, 5, 11, 12, 13, 14, 34],
vari(x) returns 90.4.

Notes

Mappings on the operand are ignored.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Probability & Statistics
Member: vari

See Also

max(x), mean(x), median(x), min(x), mode(x), rms(x), and sdev(x).


wday(aDate)

An object that returns the weekday of the time x.

Use

Use wday(aDate) to transform the given time x into a container of the same shape with value(s) 0 - 6, corresponding to the day of the week. The value 0 corresponds to Sunday, 1 to Monday, and so on, with 6 as Saturday. x may be any shape, and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Example

wday(dmyToDate(2,1,2003)) returns 4, so Jan 2, 2003 is a Thursday.

Notes

Mappings are retained in the return value.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Time & Date
Member: wday

See Also

dmyToDate (d,m,y), hmsToHour (h,m,s), hmsToSec (h,m,s), mday(aDate), month(aDate), now(), Time & Date, and year(aDate).


xcorrelate (a,b)

An object used to cross-correlate two arrays of data.

Use

Use xcorrelate(a,b) to calculate the discrete cross-correlation of two 1D arrays a and b. The result will be an array of the same type and of size (Na+Nb)-1, where Na is the size of input array a, and Nb is the size of input array b.

The input values a and b must be an Array 1D, and do not have to be the same size.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

The return type is the same as the highest type of the inputs. The resultant values are not normalized.

Example

xcorrelate([1, 2, 3, 4, 5],[3, 2, 1]) returns [1, 4, 10, 16, 22, 22, 15].

Notes

The inputs a and b must represent equally spaced data. In addition, the interval between any two values of a must be the same as that between any two values of b. For two unmapped arrays, it is assumed that the interval is always 1. For mapped arrays, the interval is (Xmax-Xmin)/N, where Xmax and Xmin are the mappings and N is the size of the array. When one input is mapped and the other is not, the unmapped input is assumed to be sampled at the same frequency as the mapped input. The resultant values will not be normalized.

Note that the xcorrelate(a,b) algorithm is essentially identical to the standard algorithm for discrete convolution, except that the second operand is not sequence-reversed as it is in convolution.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Signal Processing
Member: xcorrelate

See Also

convolve(a,b).


xlogRamp (numElem, from,thru)

An object that generates a logarithmically ramped array in the same manner used to generate x values for coordinate conversions of log mapped 1D Arrays.

Use

Use xlogRamp(numElem,from,thru) to generate a Real64 one-dimensional array of length numElem, with the values logarithmically ramped from from to thru. numElem must be a scalar container which is, or can be converted to, Int32 and with a value greater than zero. from and thru must be scalar containers which are, or can be converted to, Real64. If from is less than thru the ramping is positive; otherwise it automatically ramps negatively. Both from and thru must have values greater than zero.

Example

xlogRamp(3, 1, 100) returns a 1D Array with values [1, 10, 100].

Notes

The return value has no mappings.

The algorithm for generating values is:

Y[I]=exp10(log10(from)+I*((log10(thru)-log10(from))/numElem))
for I=0..numElem-1

This has the effect that the last element in the resultant array has a value which is less than thru by:

exp10(log10(thru)-log10(from)/numElem).

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Generate
Member: xlogRamp

See Also

Alloc Real64, logRamp (numElem, from,thru), and xramp (numElem, from,thru).


a XOR b

An object that performs a logical exclusive OR operation on two operands.

Use

Use a XOR b to determine whether one and only one of the value(s) of two containers is logically true (non-zero). The two containers may be of any type and of any shape. If one of the containers is an array, the other must be either a scalar or an array of the same size and shape. The result is an Int32 of the same shape as the operands, with value(s) 0 or 1. If either operand is non-zero, but not both, the value of the XOR operation is 1; otherwise the value is 0.

If both operands are of type Coord, they must have their independent variable(s) match exactly or an error is returned. Only the dependent (last) variable is considered for the XOR operation.

For Complex, PComplex, and Spectrum containers, the value of the operand is true if either part is non-zero. Text is true if non-null. Enums are converted to Text for the operation.

Example

A scalar and an array: 3 XOR [3, 3, 3] returns [0, 0, 0].

A scalar and an array: 3 XOR [-3, 0, 3] returns [0, 1, 0].

Two arrays: [1, 2, 3] XOR [0, 1, (-1)] returns [1, 0, 0].

Two PComplex scalars: (1,@90) XOR (1,@85) returns 0.

Two Complex scalars: (0,0) XOR (0,1) returns 1.

Two Complex scalars: (0,1) XOR (1,0) returns 0.

Two Complex scalars: (0,0) XOR (0,0) returns 0.

Two Coord scalars: coord(1,3) XOR coord(1,5) returns 0.

Two Coord scalars: coord(1,3) XOR coord(2,3) returns an error.

A Text scalar and a scalar number: "too" XOR 0 returns 1.

A Text scalar and a scalar number: "" XOR 0 returns 1 because the real 0 is promoted to "0", which is a non-null string.

Notes

If either of the containers is mapped (that is, of type Waveform, Spectrum, Coord, or a mapped array of any other type), the other container must be unmapped or have identical mappings. The return value will have the same mappings as the operands; otherwise an error is returned.

Note that the If/Then/Else device requires the expression(s) inside it to evaluate to either a scalar or an array, which is either all zeros or all ones.

Location

Device [image] Function & Object Browser

Type:  Operators
Category: Logical
Member: XOR

See Also

a AND b, NOT a, a OR b, Comparison, Conditional and If/Then/Else.


xramp (numElem, from,thru)

An object that generates a linearly ramped array in the same manner used to generate x values for coordinate conversions of mapped 1D Arrays (for example, Waveform).

Use

Use xramp(numElem,from,thru) to generate a Real64 one-dimensional array of length numElem, with the values linearly ramped from from to thru (not inclusive of thru). numElem must be a scalar container that is, or can be converted to, Int32 and with a value greater than zero. from and thru must be scalar containers that are, or can be converted to, Real64.

If from is less than thru, the ramping is positive; otherwise it automatically ramps negatively.

Example

xramp(3, 0.5, 0) returns a one-dimensional array with values
[0.5, 0.3333, 0.1667].

xramp(5, 2, 10) returns a one-dimensional array with values
[2, 3.6, 5.2, 6.8, 8.4].

Notes

The return value has no mappings.

The algorithm for generating values is:

Y[I] = from + I*(thru-from/numElem)
for I=0..numElem-1

This has the effect that the last element in the resultant array has a value which is less than thru by the size of the sampling interval: (thru-from)/numElem.

If you want a ramp that is inclusive of the thru value, use the ramp(numElem,from,thru) function instead.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Generate
Member: xramp

See Also

Alloc Real64, ramp (numElem, from,thru), and xlogRamp (numElem, from,thru).


y0(x)

An object used to calculate the Bessel function of x of the second kind of order zero.

Use

Use y0(x) to find the Bessel function of x of the second kind of order zero. x may be of any size and shape.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

For Coord input types, the operation is done on the dependent variable.

Example

y0(2) returns 0.510375672649745.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

The value of x must be positive.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: y0

See Also

Ai(x), Bi(x), j0(x), j1(x), jn(x,n), y1(x), and yn(x,n).


y1(x)

An object used to calculate the Bessel function of x of the second kind of order one.

Use

Use y1(x) to find the Bessel function of x of the second kind of order one. x may be of any size and shape.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

For Coord input types, the operation is done on the dependent variable.

Example

y1(9) returns the value 0.104314575196715.

Notes

Mappings on the operand are ignored and the output container has the same mappings as the input.

The value of x must be positive.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: y1

See Also

Ai(x), Bi(x), j0(x), j1(x), jn(x,n), y0(x), and yn(x,n).


year(aDate)

An object that returns the year of the time x.

Use

Use year(aDate) to transform the given time x into a container of the same shape with the value of the year of the time x. x may be any shape, and the same shape is returned.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

Example

year(dmyToDate(25,12,1991)) returns 1991.

Notes

Mappings are retained in the return value.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Time & Date
Member: year

See Also

dmyToDate (d,m,y), hmsToHour (h,m,s), hmsToSec (h,m,s), mday(aDate), now(), month(aDate), Time & Date, and wday(aDate).


yn(x,n)

An object used to calculate the Bessel function of x of the second kind of order n.

Use

Use yn(x,n) to find the Bessel function of x of the second kind of order n. x may be of any size and shape.

Allowed Input Type Return Type

UInt8 Real64

Int16 Real64

Int32 Real64

Real32 Real64

Real64 Real64

Coord Coord

Waveform Waveform

For Coord input types, the operation is done on the dependent variable.

The n parameter must be of Int32 type or be able to be converted to Int32. The n parameter also must be a Scalar in shape or the same shape as x.

Example

yn(10,4) returns -0.144949511868093.

Notes

If both of the inputs are mapped, then the mappings must be the same. The return value has the same mappings as the input if either input is mapped. If neither of the inputs is mapped, then the output is unmapped.

The value of x must be positive.

Location

Device [image] Function & Object Browser

Type:  Built-in Functions
Category: Bessel
Member: yn

See Also

Ai(x), Bi(x), j0(x), j1(x), jn(x,n), y0(x), and y1(x).


To Visit VEE on the World Wide Web

To Visit Agilent VEE Pro on the World Wide Web

The VEE Web site is packed with helpful resources. To visit us, see the Help menu in VEE:

Help [image] Agilent VEE on the Web

VEE Users Group (vrf)
provides a you with a wealth of information gathered through the interaction of thousands of VEE users. You can post questions, search for tips, and find other expert VEE users.

Support
provides a variety of services for downloading drivers and product updates, technical information, and other resources to improve your productivity.

Instrument Drivers
provides a variety of services for downloading drivers. Available drivers include IVI Drivers, VXIplug&play Drivers for HP/Agilent instruments, and Panel Drivers.

Education/Training
provides information on Agilent worldwide education and training.

Agilent VEE Home Page
provides a central location for access to news, information, applications, and other support for VEE.

Agilent Developers Network
provides a variety of services for downloading drivers and product updates, technical information, white papers, and other resources to improve your productivity.

Agilent Technologies Home Page
provides access to news and information about Agilent Technologies with links to other sites providing measurement and analysis solutions.

The Agilent Home Page is:

http://www.agilent.com

The VEE Home Page is:

http://www.agilent.com/find/vee


To Get Support and Download Instrument Drivers

To Download Instrument Drivers

You can get Complimentary Startup Support from the VEE Support Web site.

To visit the VEE Support Web site, see the Help menu in VEE:

Help [image] Agilent VEE on the Web [image] Support

-and-

You can download drivers from http://www.agilent.com/find/adn

This is a free service from Agilent that offers 24/7 access to drivers, white papers, and other free services.


Call Centers

Designated locations provide support for major regions of the world. These Call Centers offer Complimentary Startup Assistance, online technical support, information, and sales assistance. Please call the phone number listed for your region.

Contacts can be found on the Web site:

http://www.agilent.com/find/assist


About the VEE Pro RunTime Product

The VEE Pro RunTime product provides an environment to run VEE programs, and is separate from the VEE Pro development environment. You cannot develop programs with VEE Pro RunTime. You create, test, debug, and save VEE programs with a VEE development environment. Then, you install VEE Pro RunTime on the systems that will run the VEE programs; for example, to control processes or operate test systems. Operators can use the VEE programs, but they cannot modify them. They see the programs only in their panel views.

In most situations, you develop a VEE program to help people test or monitor something. The system that runs a VEE program will typically need interface cards that interact with instruments. While a VEE program can be developed "without documentation," you should know which interface cards are required for the program to work in a run-time context, and you should provide necessary information to the people who will use the program. (If you have questions about supported interface cards, see your Agilent Technologies sales representative.)

Besides interface cards, the system that runs a VEE program might need the Agilent I/O Libraries (Version M.01.01.04 or higher). For more information about controlling instruments, see the VEE Pro User's Guide and the VEE Pro Advanced Techniques manuals.

The VEE Pro RunTime product ships on the same CD-ROM that contains the VEE Pro development environment. When you run setup.exe from your VEE Pro CD, you can choose to install VEE Pro RunTime or the VEE Pro development environment.

Distributing a VEE Program

For topics describing techniques to develop VEE programs for distribution, see VEE Help under the heading How Do I … Build an Operator Interface. Under the heading, Preparing a Program for Distribution to Others, see the topics under Creating a Distribution Package. For specific information about moving a program to run on another system see To Include All Needed Files.

Very Important

The version of VEE Pro RunTime used to run a program must be the same or newer than the version of VEE used to develop the program.

The version of the Agilent I/O Libraries must be compatible with the version of the VEE Pro development environment used to develop your program, and with VEE Pro RunTime. (For VEE 7.0 you need Agilent I/O Libraries version M.01.01.04 or higher.) To ensure this compatibility, use the Agilent I/O Libraries that is shipped with VEE. If you upgrade VEE using downloadable patches from our Web site, be sure to verify the Agilent I/O Libraries compatibility.

Note

Agilent VEE Pro licensees are allowed unlimited installation and distribution rights for VEE Pro RunTime and the Agilent I/O Libraries that are included with the VEE Pro product. You may install VEE Pro RunTime and the Agilent I/O Libraries on systems inside and outside your company when you distribute your VEE programs.

For VEE Pro RunTime system requirements, see System Requirements for VEE Pro RunTime. For installation instructions, see To Install VEE Pro RunTime. For configuration instructions, see To Configure VEE Pro RunTime.


System Requirements for VEE Pro RunTime

The minimum system requirements for VEE Pro RunTime are:

.NET Framework

PC with a Pentium 120 MHz processor (266 MHz Pentium II or higher recommended)

Windows 98SE, WindowsME, Windows NT 4.0(SP6a), Windows 2000(SP4), or Windows XP(SP1) operating system

24 MB RAM with Windows 98, 48 MB RAM with Windows NT/Windows 2000

Hard disk free space: 70 MB minimum (105 MB with MATLAB and tutorials)

CD-ROM drive

15-inch monitor 800x600 Super VGA (17-inch 1024x768 Ultra VGA or larger recommended)

PC keyboard

2-button mouse (3rd button, if present, is not used)

Desired instruments, interface cards, and other peripherals as needed


To Install VEE Pro RunTime

After developing a VEE program, you may want to run it on other systems. VEE programs are not self-contained .exe files. A version of VEE must be installed on any system that runs VEE programs. Of course, the full VEE Pro development environment can be used to run VEE programs, but VEE Pro RunTime is a more economical alternative for those "run-only" systems.

This topic explains how to install VEE Pro RunTime on a Windows system that does not already have VEE installed.

Note

VEE Pro owners are allowed unlimited installation and distribution rights for the VEE Pro RunTime product. You may install VEE Pro RunTime on systems inside and outside your company when you distribute your VEE programs. You may need to provide installation instructions with your program.

The VEE Pro development environment may be installed on systems as allowed by the VEE Pro Software License Agreement and License to Use.

Be aware that you must have system administrator capability to install VEE Pro RunTime on computers running a Windows NT, Windows 2000, or Windows XP operating system.

To begin an installation, have Windows running, and stop all applications. Insert the CD-ROM in the CD-ROM drive. Wait for the installation to begin automatically. One of two things can happen:

1. A screen appears on your monitor that lets you install the development environment or the run-time environment.

Select the run-time environment. After this, work through the series of screens that let you install the environment.

2. The CD-ROM installation process does not start automatically. Therefore, you need to run the following command to start the run-time environment installation:

e:\runtime\setup.exe

This assumes the CD-ROM drive is drive E:. To run this command, select the Start button in the Windows taskbar. Then, select Run and type the command.


To Configure VEE Pro RunTime

The run-time environment is intended to run programs, not develop them. Therefore, the main VEE window and workspace are not accessible on systems that have only VEE Pro RunTime installed. Characteristics of the VEE environment that are typically accessed by menu picks on the main VEE window must be set using a different mechanism for VEE Pro RunTime. Two important configuration areas can be accessed by command-line options. These same features are also available as icons in the Agilent VEE Pro 7.0 RunTime Config Start menu group.

To modify the instrument configuration, run the following command:

veerun.exe -ioconfig

This runs VEE Pro RunTime and opens the Instrument Manager to allow the user to change and save the I/O configuration. This is important when the program does not have an embedded I/O configuration.

To modify the Default Preferences, run the following command:

veerun.exe -prefconfig

This runs VEE Pro RunTime and opens the Default Preferences dialog to allow the user to change and save the default preferences. Some settings that may be important to the RunTime user include:

Web Server configuration

Execution Mode (primarily for Remote User Functions)

Check Instrument Addresses at PreRun

Delete Variables at PreRun

Printing configuration

Colors and Fonts (if they were not saved with the program)

Note

On systems that have both VEE Pro and VEE Pro RunTime, the two versions may or may not share the same configuration settings. If the current user has a HOME environment variable set, both VEE versions will look for configuration files in that HOME directory. This means they will both have the same Default Preferences, etc. If the current user has no HOME environment variable, then VEE Pro and VEE Pro RunTime store their configuration data in different places. In this case, the configuration of each version must be set separately.


VDC Array Format

Many VEE Data Containers package data in an array. Inside VEE, objects like Build Coordinate isolate you from the internal structure of these arrays. Outside VEE (in a Visual Basic client, for example), you must declare and populate these arrays correctly to avoid errors or confusion.

Consider the example of a VEE 1D array of 3D Coordinates. Immediately, you see one source of confusion: the term "dimension" is used to describe two different concepts. For coordinates, a dimension is an axes (typically referred to as "X", "Y", and "Z"). For arrays, a dimension is organization index (typically referred to as "row" and "column"). In VEE, this data type is one row of storage locations, and each storage location holds one Coordinate. Assuming a variable named "MyVeeData", the first Coordinate is MyVeeData[0], the tenth Coordinate is MyVeeData[9], etc.

Because Visual Basic does not have a "3D Coordinate" data type, a single storage location cannot hold an entire Coordinate. Packaging all the data from the "MyVeeData" array requires a 2-dimension array in Visual Basic. The rows of this array represent the coordinates; the columns of this array represent the three "X,Y,Z" values of each coordinate.

Assuming a variable named "MyVbData", the Z component of the first coordinate is MyVbData(0,2), the X component of the tenth coordinate is MyVbData(9,0), etc.

A similar arrangement is used for other VEE data types. When building a VB array for VEE Complex data, MyVbData(Element, 0) is the real component and MyVbData(Element, 1) is the imaginary component. Following is a summary of the applicable VEE data types and their array format:

VDC Data Type Array Format

Complex 1D Array Rows are complex numbers.
Column 0 is real component.
Column 1 is imaginary component.

Polar Complex 1D Array Rows are polar complex numbers.
Column 0 is magnitude component.
Column 1 is phase component.

2D Coordinate 1D Array Rows are coordinates.
Column 0 is X component.
Column 1 is Y component.

3D Coordinate 1D Array Rows are coordinates.
Column 0 is X component.
Column 1 is Y component.
Column 2 is Z component.

Coordinate 1D Array Rows are coordinates.
Column 0 is X component.
Column 1 is Y component.
Column N is Nth-dimension component.


.topic 400
When the Profiler is started, it provides comparative information about the execution time of each UserObject and UserFunction. Clicking on any column label (such as Name, or Time) displays the Profiler data sorted on that field. Clicking again reverses the sort. Double-click on any UserObject or UserFunction shown in the Name field, and its view opens in the VEE workspace.

.topic 420
When this box is checked, data is written to the data file with commas as delimiters (separators) between the various Profiler data fields. Using comma delimiters makes it easier to import the data into some other applications, such as spreadsheets.  When this box is not checked, the data fields are aligned using multiple spaces.

.topic 1064
Specifies the local directory that will be accessible to the remote Web browser. VEE uses the file index.html in the Root Directory as its home page. A default homepage is installed as ~installDir/www/index.html. This file can be modified and/or copied to a different Root Directory.

.topic 1072
When OK is pressed, any changes to Default Preferences become valid for the current work session only. When you exit and restart VEE, the previous Default Preferences(saved in the "veerc" file) are restored.

.topic 1044
The Fonts property allows you to choose the default font for any screen element in your VEE program.

.topic 258
The Program Explorer button shows or hides the Program Explorer window. The Program Explorer shows the hierarchical structure of the current VEE program.

.topic 256
The Delete Line button provides the Delete Line cursor, which you then click on the line to be deleted. (A handy shortcut to delete lines is Ctrl-Shift-Click.)

.topic 230
The Call Stack button aids debugging by displaying the hierarchy of UserObjects or UserFunctions invoked to reach the current paused UserObject or UserFunction. Clicking on any entry in the Call Stack dialog opens that UserObject or UserFunction in the VEE workspace.

.topic 30
Click the (Interface) Properties button to view specific details about the currently selected interface. Note that VEE cannot modify the hardware characteristics of an interface or alter the configuration performed by the operating system or the I/O Config utility. If you enter different values in any of the Interface Properties fields, you must use values that match an existing, configured interface.

.topic 42
Click the Save button to save the instrument configuration to disk and close the Instrument Manager. This overwrites the vee.io file with the current configuration.  If the instrument configuration is embedded in the program, a Save from the InstrumentManager is not necessary, because an embedded configuration is saved when the programis saved.

.topic 406
The Clear button resets all Profiler data values to 0 (zero).

.topic 1046
The Number tab allows you to choose the default format for displaying numbers in your VEE program.

.topic 220
The Stop button stops execution of all program threads and closes any open files.  When a program is in the stopped state, pressing Step or Run/Resume restarts program execution from the beginning.

.topic 224
The Step Over button aids debugging by executing one primitive object at a time.  When a UserObject or UserFunction is encountered, it is executed in its entirety and is not opened into a detail view.

.topic 216
The Run button starts execution of all threads in a program. If your program has several threads, and you want to run only one of them, use a Start object to that thread instead of the Run button.

.topic 244
The Instrument Manager button provides the Instrument Manager dialog. This dialog provides convenient editing, viewing, and creating of I/O resources such as instrument transactions and drivers.

.topic 254
The Add To Panel button places the selected objects onto the panel view of the program.  If a panel view does not already exist, one is created. Panels are associated with the current context and can be nested.

.topic 22
Click the Add button to add an instrument to your I/O configuration. A manual Add operation is needed for instruments that are not discovered by the Find Instruments button. For example, RS-232 instruments or instruments connected via a LAN gateway.(An interface entry is automatically added when you add an instrument associated with that interface.)

.topic 196
The bottom line of the VEE window is a status message area. This status line shows various types of information, depending upon the current operation. For example, the program run state, error messages, pixel position of moved objects, and helpful hints.

.topic 1068
Specifies the maximum time (in seconds) that the Web server will wait for VEE to respond.

.topic 1062
When Enable Server is checked, VEE's built-in Web server is activated. The Web server allows you to monitor a VEE program from a remote Web browser.

.topic 226
The Step Out button aids debugging by executing one primitive object at a time. If the execution is in a UserObject or UserFunction, VEE completes execution of all objects in that UserObject or UserFunction.

.topic 218
The Pause button stops execution of all program threads temporarily. When a program is in the paused state, either Step or Run/Resume can be used to proceed with program execution from the point it was paused.

.topic 434
This field indicates the scope of the search. The default is the Entire Program.  If you want to limit the scope of a search, open the Find dialog from the ProgramExplorer by clicking with the right mouse button on a particular context, such as a UserFunction or UserObject.

.topic 408
The Save button writes the Profiler data to the file name specified using the Options button.

.topic 1036
When instrument checking is enabled, VEE checks the configured instruments during prerun to verify that they are accessible. If an address does not respond, you are iven the opportunity to power-on the instrument, choose a different bus address, etc. When this box is not checked, disconnected or improperly configured instruments will probably cause a timeout error when the program is running.

.topic 232
The Show Execution Flow button aids debugging by highlighting the currently executing object(s) while the program is running. In the paused or error state, Show Execution Flow highlights all objects that have already executed.

.topic 250
The Copy button places a copy of the selected objects in the Paste buffer and on the Windows Clipboard.

.topic 440
When this box is checked (the default), the search traverses all levels of nested User Objects. If not checked, only the current level is searched.

.topic 470
Creates a Formula object to Set the value of the currently selected member (property).Place the Formula in a program context. It is simply a template which can be edited as desired.

.topic 34
Click the Plug&play Driver button to create a VXIplug&play driver object for the instrument currently selected. (A VXIplug&play driver is an industry standard API based upon VISA.)

.topic 46
The Settings dialog controls some of the actions performed during instrument discovery.  If Detect only is selected, the Find Instruments button simply detects whether a device is present at each bus address. If Detect, identify, and configure... is selected, the Find Instruments button also performs an identification and driver configuration for each instrument detected. If Ask before sending... is checked, a confirmation dialog is presented before *IDN? is sent to identify each instrument. If not checked, *IDN? is sent to all instruments without operator confirmation. You may want the confirmation dialog if your system contains old, non-IEEE-488.2 instruments.

.topic 414
When this box is checked, Profiler data is shown only for those UserObjects and UserFunctions that executed.

.topic 1070
Specifies the file path to the http.log file. This file records all incoming requests processed by the Web server and can grow without bounds.

.topic 1030
The Execution Mode selection can be used to force backward compatibility for certain programs written in older versions of VEE. Execution Mode is stored with a VEE program, and can be changed in the Default Preferences dialog.  If the Execution Mode is set lower than the current version, the program cannot use newer VEE features. Using the highest possible Execution Mode is recommended, except in the rare cases when the higher mode causes program behavior to change in undesirable ways.

.topic 1040
When Binary RunTime File Format is checked, .vxe files are saved using a binary formatwhich gives improved security and smaller file size. When this box is not checked, .vxe files are stored in ASCII format (similar to .vee files).

.topic 444
When this box is checked, the Find text must match the entire field of the text being searched.

.topic 448
When this box is checked, a match is reported if the Find text occurs at the end of the text being searched.

.topic 1038
Specifies the number of pixels placed between objects when you perform an Edit  Align... operation. This Alignment Spacing value is used only when Space Equally is enabled.

.topic 206
The New button clears the VEE workspace. You will be prompted if there are any unsaved changes in the current program.

.topic 242
The Default Preferences button provides the Default Preferences dialog. This dialog has six tabs containing many and varied customizable VEE settings.

.topic 452
The Property buttons can be used to constrain the search according to various object properties. Once a Property is selected, specify the desired constraint in the Value column. For example, if you select Breakpoint/On, then only objects with active break points are searched.

.topic 412
This field specifies the number of digits displayed to the right of the decimal point.

.topic 1028
The Trig Mode selection chooses the default trigonometric units used in the program.  Radians are VEE's default (and fastest) units.

.topic 1076
When Reset is pressed, any pending changes to Default Preferences are discarded, and the previous Default Preferences (saved in the "veerc" file) are restored.

.topic 1052
Specifies the magnification used when printing a VEE program. Smaller numbers create a smaller image. The value you specify might be rounded by some printer drivers.

.topic 228
The Toggle Breakpoint button aids debugging by setting or clearing execution breakpoints at the selected objects. A breakpoint on an object pauses program execution immediately before that object. Breakpoints can also be accessed in the Object Menu Properties.

.topic 402
The Start Profiling button is a toggle function that starts or stops profiling.

.topic 404
Profile data is collected whenever the Profiler is running, but the data displayed in the dialog box is not updated automatically. You must click the Refresh button to cause the Profiler to display the latest profile data.

.topic 222
The Step Into button aids debugging by executing one primitive object at a time.  When a UserObject or local or imported UserFunction is encountered, VEE puts it into its detail view and executes each object in that view.

.topic 214
This area displays the run state of the program. Indicators are: Blank, Ready (stopped), Green Arrow Running, Yellow Bars Paused, Red Bars Error

.topic 246
The Function & Object Browser button provides the Function & Object Browser dialog.  This browser provides convenient access to various math operations, objects, and properties.

.topic 466
Creates a Formula object for the currently selected function or operator.  Place the Formula in a program context. It is simply a template which can be edited as desired.

.topic 202
This field indicates if the currently loaded program has any unsaved changes (modifications).When the box is "grayed out," no unsaved changes are pending.

.topic 198
This field shows the Execution Mode of the currently loaded VEE program. ExecutionMode allows newer versions of VEE to run older VEE programs with complete backwards compatibility. The possible modes are VEE 3, VEE 4, etc. up through the current VEE version. Execution Mode is saved with the VEE program and can be changed in the Default Preferences dialog.

.topic 194
The Program Explorer window shows you the hierarchical structure of the VEE program currently loaded. Different icons are used to represent different elements of the program, such as UserObject, Remote User Function, compiled library, global variable, etc.  If you move the pointer over a program element in the Program Explorer window and click the right-hand mouse button, a menu is presented. This menu provides useful information and operations for that element. The contents of this menu depend upon the type of element selected.

.topic 416
This field specifies the file name where Profiler data is saved. Click this field to bring up the Save data filename dialog box.

.topic 1042
The Appearance Property Group allows you to choose the default color for any screen element in your VEE program.

.topic 450
The Object Type property constrains the search to objects of the type(s) selected in the Value list. The default is all object types. To constrain the search, click the Value button and check or uncheck the desired types. Select All and Clear All buttons are provided for convenience.

.topic 468
Creates a Formula object to Get the value of the currently selected member (property).Place the Formula in a program context. It is simply a template which can be edited as desired.

.topic 38
Click the Component Driver button to create a Component Driver object for the currently selected instrument. (A Component Driver is an efficient link to one component of an instrument's Panel Driver.)

.topic 28
Click the (Instrument) Properties button to view or modify the I/O-related properties of the currently selected instrument. The interface type determines the set of properties available. For example, RS-232 instruments have a Properties field for setting the Baud rate, while GPIB instruments have a Properties field for setting the bus address.

.topic 48
If Detect only is selected, the Find Instruments button simply detects whether a device is present at each bus address. If Detect, identify, and configure... is selected, the Find Instruments button also performs an identification and driver configuration for each instrument detected.

.topic 410
The Options button brings up the Profiler Options dialog box. These options customize the format of displayed and saved data.

.topic 384
When this box is checked, the printout includes an open view of all nested UserObjects.

.topic 1058
When Print Cover Page is checked, a cover section is generated at the beginning of the printout. This default format choice can be overridden in the Print Program dialog.

.topic 192
The Main window is the root UserObject in VEE programs. It is required in programs and cannot be deleted. Other UserObject and UserFunction windows are created from the Main window.  If the Main window has been minimized or closed, it can be re-opened by selecting it from the View menu. It can also be reopened by clicking on Main in the VEE ProgramExplorer window.

.topic 208
The Open button loads a program file into the VEE workspace, replacing any existing program. You will be prompted if there are any unsaved changes in the current program.

.topic 248
The Cut button deletes the selected objects and places them in the Paste buffer and on the Windows Clipboard.

.topic 238
The Find button provides a dialog box used to search for text strings and certain object properties in your VEE program. Various search properties, such as Match Case and Object Type, can be used to constrain your searches. To limit the scope of a search, open Find from the Program Explorer by clicking a specific context with the right-hand mouse button.

.topic 18
The Configure Drivers button identifies the selected instrument and configures any available VXIplug&play and Panel Drivers for that instrument. (Only IEEE 488.2 (and most VXI) instruments can be identified.)

.topic 32
Click the Direct I/O button to create a Direct I/O object for the instrument currently selected. (A Direct I/O object allows low-level transactions with the instrument.)

.topic 40
Click the OK button to save the instrument configuration in an internal cache and close the Instrument Manager. The current configuration is used by the program, but is not yet saved to disk.

.topic 1034
When Disable Debug is checked, all debugging features are disabled, giving the fastest program execution speed.

.topic 1024
When Auto Line Routing is checked, the lines between objects are automatically rerouted when an object is connected, moved, or resized. Auto-routing uses only horizontal and vertical lines, and gives the same results as Edit -> Clean Up Lines. When auto-routing is off, lines are drawn directly from pin to pin, often diagonally.

.topic 260
The Profiler button provides the Profiler dialog. The Profiler provides comparative information about the execution time of each UserObject and UserFunction.

.topic 212
The Print Screen button sends the visible contents of the VEE window to a printer.  To configure the printer, use File -> Print Screen.

.topic 16
When the root node is selected, click the Find Instruments button to search for available interfaces and instruments. When a specific interface is selected, click this button to search for all instruments connected to the selected interface. The exact operations performed by the Find Instruments button are controlled by the Settings dialog.

.topic 44
The Print button brings up a standard Windows Print dialog. The Instrument Manager printout is a bitmap dump of the full Instrument List tree view.

.topic 200
This field indicates if Profiling is currently enabled. When the box is "grayed out, "profiling is stopped.

.topic 388
When this box is checked, each printout page is given a page number and other header information, and an Index is generated at the end of the printout.

.topic 1032
Sets the speed at which the Data Flow markers move. Select a rate from 1 to 10. The default is 6 and the fastest is 10.

.topic 1
Save colors and fonts with program saves all the default colors and fonts in the program file that are selected in the Default Preferences dialog box. This ensures that whoever opens your program will also get all of your default colors and fonts.  If this option is not selected, only the colors and fonts explicitly set in your program are saved in your program file. This allows others using your program to retain their own default colors and fonts. If an existing program is loaded, the option is set according to how the program was saved previously.

.topic 204
This field indicates if the VEE Web Server is currently enabled. When the box is "grayed out," the Web Server is disabled. The VEE Web Server is controlled in the Default Preferences dialog.

.topic 1066
Specifies the port number used by VEE's Web server. This port number must be allocated in your system's services file and must not be used by any other Web server.

.topic 1026
When Delete Variables at PreRun is checked, the values stored in all variables are deleted before each program runs. Therefore, Get Variable objects will error if their values have not been properly set. When this box is not checked, Get Variable objects can access old data left from the previous program run. Such old data may or may not be valid for the new program run.

.topic 2
Save I/O configuration with program saves the veeio I/O configuration information with the program file, and not in the veeio resource file. The configuration information is specified in the Instrument Manager. If this option is not selected, the current program's configuration information is saved in the veeio file. If an existing program is loaded, the option is set according to how the program was saved previously.

.topic 236
The View Variables button displays a list of all variables that are currently defined.  Double-click a variable's name to view details such as type, shape, and data values.

.topic 436
When this box is checked, the search is constrained to exact matches of the letter-case specified in the Find line. The default is off, which treats upper-case and lower-case letters as equal.

.topic 26
Click the Remove button to delete an instrument entry from the I/O configuration.(An interface entry is automatically removed when all the instruments associated with that interface are removed.)

.topic 442
When this box is checked, a match is reported if the Find text occurs anywhere in the text being searched.

.topic 438
When this box is checked, all matches are reported for each object. The default is off, which reports only the first match found for each object.

.topic 472
Creates a Call object for the currently selected function. Place the Call in a program context. It is simply a template which can be edited as desired.

.topic 418
When this box is checked, each click of the Save button overwrites the data previously saved in the Profiler data file. When this box is not checked, each Save appends to the existing data.

.topic 386
When this box is checked, the printout includes a detailed view of each object in the program. All but the simplest objects are printed in open view form.

.topic 1074
When Save is pressed, any changes to Default Preferences become valid for the curren work session and are saved in the "veerc" file. When you exit and restart VEE, the new saved Default Preferences are used. (The exact path to the "veerc" file is system dependent.)

.topic 1054
When Print Header and Index Page is checked, each printout page is given a page number and other header information, and an Index is generated at the end of the printout.  This default format choice can be overridden in the Print Program dialog.

.topic 1056
When Print Program Explorer is checked, the printout includes the overview information contained in the Program Explorer window. This default format choice can be overridden in the Print Program dialog.

.topic 240
The Find Results button displays the results from the most recent Find search. You can change the sorting order of a column by clicking on the column header.

.topic 432
Enter the text string you want to find in your VEE program. If you leave this line blank, the search will match any text.

.topic 446
When this box is checked, a match is reported if the Find text occurs at the beginning of the text being searched.

.topic 24
Click the Remove button to delete an instrument entry from the I/O configuration.(An interface entry is automatically removed when all the instruments associated with that interface are removed.)

.topic 392
When this box is checked, the printout includes the overview information contained in the Program Explorer window.

.topic 390
When this box is checked, a cover section is generated at the beginning of the printout.

.topic 1060
When Print I/O Configuration is checked, the printout includes the expanded treeview of the I/O configuration (from the Instrument Manager). This default format choice can be overridden in the Print Program dialog.

.topic 1050
The B&W Printer Darkness setting allows you to choose a shade of gray for each screen element in your VEE program. This shade of gray is used when you print the program on a non-color printer. (The settings in the Appearance Property Group are used for a color printer.)

.topic 234
The Show Data Flow button aids debugging by visually indicating the route that data takes through the program. The speed of the small square data marker is set in the Default Preferences   General tab, Debug area.

.topic 210
The Save button writes the current program to the previously specified file name.  Save uses the file shown in the VEE window title bar. If this is a New program that has not been saved previously, you will be prompted for a file name. To change filenames, use File -> Save As.

.topic 394
When this box is checked, the printout includes the expanded tree view of the I/O configuration (from the Instrument Manager).

.topic 50
If Ask before sending... is checked, a confirmation dialog is presented before *IDN? is sent to identify each instrument. If not checked, *IDN? is sent to all instruments without operator confirmation. You may want the confirmation dialog if your system contains old, non-IEEE-488.2 instruments.

.topic 252
The Paste button places a copy of the Paste buffer onto the VEE workspace. You can Paste objects that were accidentally Cut, and connections to those objects will be restored.

.topic 454
The Reset button restores the default Property/Value list, which is all object typeswith no constraints.

.topic 464
This browser presents functions and objects in a hierarchical arrangement. Choose the broad classification from the left column, the sub-category from the middle column, and the specific function or object from the right column. Then click one of the Create... buttons (or double-click the selection) to create a VEE object from your selection. Place this VEE object in a program context and edit it as desired.

.topic 474
Displays Help for the currently selected function or object (not Help about the Browser).

.topic 36
Click the Panel Driver button to create a VEE Panel Driver object for the currently selected instrument. (A Panel Driver is the full-featured graphical simulation of an instrument's front panel.)


.NET and COM

Using .NET objects and COM objects inter-operatively means you have to reconcile how the two exist in memory. .NET objects exist in managed memory, which is controlled by the CLR, and they can be moved during runtime as needed to improve performance. COM objects reside in unmanaged memory and their pointers are to locations in memory that do not move.

Since the two manage memory very differently, a wrapper is needed to help them communicate. The diagram below shows how .NET makes use of wrappers to make the communication between the two transparent. These two wrappers are the foundation of the .NET Framework's COM interop strategy. For in-depth and understandable reviews of the Runtime Callable Wrapper and the COM Callable Wrapper, see the articles in MSDN by Mike Gunderloy. They are entitled “Calling COM Components from .NET Clients” and “Calling a .NET Component from a COM Component”.


Activate

1. To send a container to a terminal. See also Container and Terminal.

2. The action that resets the context of a UserObject before it operates each time. See also Context and PreRun.


Allocate

To initialize a VEE array. Allocation sets the number of dimensions, the number of elements in each dimension, and fills the array with initial data. For example, a two-dimensional integer array is filled with 0 values by default.


Array

A data shape corresponding to a mathematical array, which contains a grouping of data items (all of the same data type) in one or more dimensions. The data items are accessed by means of array indexes. In VEE, a one-dimension array is called Array 1D, a two-dimension array is Array 2D, and so forth. See also Data Shape.


Asynchronous

In asynchronous operation, a device operates without a common signal to synchronize events -- the events occur at unspecified times. VEE control pins (for example, the Clear pin on a display object) are asynchronous.


Auto Execute

An option on the object menus of the data constant objects. If Auto Execute is set, and if the program is not already running, the object operates when its value is edited. Auto Execute is ignored while the program is running.


Bitmap

A bit pattern or picture. In VEE you can display a bitmap with a Picture object or on any icon. You can also display a bitmap on the background of a main program panel view, a UserObject panel view, or a UserFunction panel view.


Breakpoint

A tool for debugging a program. If you set a breakpoint for an object, the program will pause just before that object executes.


Buffer

An area in memory where information is stored temporarily.


Button

A graphical object in VEE that simulates a momentary switch or selection button, and which appears to pop out from your screen. When you "press" a button in VEE, by clicking on it with the mouse, an action occurs. (May also refer to the left or right mouse button.)


Cascading Menu

A sub-menu on a pull-down or pop-up menu that provides additional selections.


Checkbox

A recessed square box on menus and dialog boxes that allows you to select a setting. To select a setting, click on the box so a check mark appears in the box to indicate a selection has been made. To cancel the setting, simply click on the box again.


Click

To press and release a mouse button. Clicking usually selects a menu feature or object in the VEE window. See also Double-Click and Drag.


Clone

A menu item on object menus that duplicates objects and their interconnections, placing a copy of them in the Paste buffer. Clone copies all the attributes of the cloned objects including pins, parameters, and size.


Compiled Function

A user-defined function created by dynamically linking a program, written in a programming language such as C, into the VEE process. The user must create a DLL (Dynamically Linked Library) file and a definition file. The Import Library object attaches the DLL to the VEE process and parses the definition file declarations. The Compiled Function can then be called with the Call Function object, or from certain expressions. See also UserFunction and Remote Function.


Component

A single instrument function or measurement value in a VEE instrument panel or component driver. For example, a voltmeter driver contains components that record the range, trigger source, and latest reading. See also Component Driver, Driver Files, State, and Instrument Panel.


Component Driver

An instrument control object that reads and writes values to components you specifically select. Use component drivers to control an instrument using a driver by setting the values of only a few components at a time. (Component drivers do not support coupling.)


Composite Data Type

A data type that has an associated shape. See also Data Shape and Data Type.


Container

See Data Container.


Context

A level of the work area that can contain other levels of work areas (such as nested UserObjects), but is independent of them.


Control Pin

An asynchronous input pin that transmits data to the object without waiting for the object's other input pins to contain data. For example, control pins in VEE are commonly used to clear or autoscale a display.


Coupling

The inter-relationship of certain functions in an instrument. If, in an instrument panel, functions A and B are coupled, changing the value of A may automatically change the value of B, even though you do not change B explicitly.


Cursor

A pointer (caret) in an entry field that shows where alphanumeric data will appear when you type information from the keyboard.


Cut Buffer

The buffer that holds objects that you cut or copy. You can then paste the object back into the work area with Edit [image] Paste


Data Container

The data package that is transmitted over lines and is processed by objects. Each data container contains data and the data type, data shape, and mappings (if any).


Data Field

The field within a transaction specification in which you specify either the expression to be written (WRITE transactions), or the variable to receive data that is read (READ transactions). See also Transaction.


Data Flow

The flow of data through and between VEE objects. Data flows from left to right through objects, but an object does not execute until it has data on all of its data input pins. Data is propagated from the data output pin of one object to the data input pin of the next object. Data flow is the chief factor that determines the execution of a VEE program.


Data Input Pin

A connection point on the left side of an object that permits data to flow into the object.


Data Output Pin

A connection point on the right side of an object that propagates data flow to the next object and passes the results of the first object's operation on to the next object.


DataSet

A collection of "Record" containers saved into a file for later retrieval. The To DataSet object collects Record data on its input and writes that data to a named file (the DataSet). The From DataSet object retrieves Record data from the named file (the DataSet) and outputs that data as Record containers on its Rec output pin. See also Record.


Data Shape

Each data container has both a shape and type. The data shape can be either a scalar or an array. The data shape can be either a scalar or an array of one or more dimensions. In VEE, a one-dimension array is called Array 1D, a two-dimension array is Array 2D, and so forth.


Data Type

Each data container has both a type and shape. VEE supports several data types including Text, Int16, Real64, Complex, Waveform, etc.


DDE (Dynamic Data Exchange)

A communication mechanism that allows processes to communicate on the Windows platform. DDE is an older mechanism that was superceded by ActiveX .


Default

A value or action that is selected automatically. For example, VEE uses certain default colors and fonts, which you can change using the Default Preferences dialog box.


Default Button

The button in a dialog box that is activated by default if Enter or Return is pressed, or the selection is double-clicked. The label of the default button is in bold text.


Demote

To convert from a data type that contains more information to one that contains less information. See also Data Type and Promote.


Detail View

The view of a VEE program that shows all the objects and the lines between them.


Instrument

An electronic device used for measurement and/or test stimulus. Instruments are connected to a computer with a GPIB, RS-232, GPIO, VXI, LAN, or USB interface. Specific VEE objects, such as the Direct I/O object and Panel Drivers, communicate with instruments.


Device Driver

See Interface Driver.


Dialog Box

A secondary window displayed when VEE requires information from you before it can continue. For example, a dialog box may contain a list of files from which you may choose.


Direct I/O Object

An instrument control object that allows VEE to directly control an instrument without using a dedicated driver.


DLL (Dynamically Linked Library)

A collection of functions written in C that can be called from VEE for Windows. DLLs can be created by experienced C programmers using tools available from Microsoft.


Double-Click

To press and release a mouse button twice in rapid succession. Double-clicking is usually a short-cut to selecting and performing an action. For example, double-clicking on a file name from File [image] Open will select the file and open it.


Drag

To press and continue to hold down a mouse button while moving the mouse. Dragging moves something (for example, an object or scroll bar).


Driver

Software that allows a computer to communicate with other software or hardware. See also Component Driver, Driver Files, Interface Driver, and Instrument Panel.


Driver Files

A set of files included with VEE that contains the information needed to create instrument panel and component driver objects for instrument control.


Drop-Down List

A list of selections obtained by clicking on the arrow to the right of a selection field.


Entry Field

A field that is typically part of a dialog box or an editable object, which is used for data entry. An entry field is editable when its background is white.


Error Message

Information that appears in an error dialog box, explaining that a problem has occurred.


Error Pin

A pin that traps any errors that occur in an object. Instead of getting an error message, the error number is output on the error pin. When an error is generated, the data output pins are not activated.


Execute

The action of a program (or its parts) running.


Execution Flow

The order in which objects operate. See also Data Flow.


Expression

An equation in an entry field that may contain input terminal names, local or global variable names, math operators, built-in functions, and user-defined functions. An expression is evaluated at run time. Expressions are allowed in Formula, If/Then/Else, Get Values, Get Field, Set Field, Sequencer, and Dialog Box objects, and in I/O transaction objects.


Feedback

A continuous thread path of sequence and/or data lines that uses values from the previous execution to change values in the current execution.


Flow

See Data Flow and Execution Flow.


Font

The size and style of a typeface.


Function

The name and action of objects where the output is a function of the input. These objects are located in the Function & Object Browser (Device [image] Function & Object Browser) and may be used in the Formula object. For example sqrt(x) is a function; + is not.


Global Variable

A named variable that is set globally, and which can be used by name in any context of a VEE program. For example, a global variable can be set with Set Variable in the root context of the program, and can be accessed by name with Get Variable or from certain expressions within the context of a UserObject. However, a local variable with the same name as the global variable takes precedence in an expression. See Variable.


Grayed Feature

A menu feature that is displayed in gray rather than black, indicating that the feature is not active or not available. Dialog box items such as buttons, checkboxes, or radio buttons may also be grayed.


Logical Unit

A number used to identify the logical address of a hardware interface. For example, the factory default logical unit for most GPIB interfaces is 7.


Highlight

1. The colored band or shadow around an object that provides a visual cue to the status of the object.

2. The change of color on a menu feature that indicates you are pointing to that feature.


Host

1. To begin a thread or subthread. For example, the subthread that is hosted by For Count is the subthread that iterates.

2. In a distributed system, the computer running (or serving) a facility or an application.


Hypertext

A system of linking topics so that you can jump to a related topic when you want more information. In online help systems, typically hypertext links are designated with underlined text. When you click on such text, related information is presented.


Icon

1. A small, graphical representation of a VEE object, such as the representation of an instrument, a control, or a display.

2. A small, graphical representation of an application, file, or folder.


Instrument Driver

See Driver Files, Component Driver, and Instrument Panel.


Instrument Panel

An instrument control object that forces all the function settings in the corresponding physical instrument to match the settings in the control panel displayed in the open view of the object.


Interface

A shared boundary between objects in different hardware (or software ) systems. GPIB, RS-232, GPIO, LAN, USB, and VXI are referred to as interfaces used for instrument I/O. Specific VEE objects, such as the Interface Event object, can only send commands to an interface.


Interface Driver

Software that allows a computer to communicate with a hardware interface, such as GPIB or RS-232.


Iterate

To repeat (loop) part of a VEE program using one of the Repeat objects (for example, For Count).


Library

A collection of often-used objects or programs grouped together for easy access.


Line

A link between two objects in VEE that transmits data containers to be processed. See also Thread.


Loop

To repeat part of a VEE program using one of the Repeat objects (for example, For Count).


Main Menu

The menus located in the VEE menu bar. To open a main menu, click on the appropriate menu title in the menu bar. You can also use accelerators. For example, use Alt+F to open the File menu.


Main Work Area

Also known as the Main Window.


Main Window

The root, or primary, work area in which you develop a VEE program. This Main Window work area, resides in the work space of the VEE window, and is the parent context of all other contexts.


Mapping

A set of continuous or discrete values that express the independent variables for an array (for example, the time span of a waveform).


Maximize

To enlarge a window such as Main, UserObject, or UserFunction to fill all of the available work space in the VEE window using a maximize button. For the VEE window, this fills all of the available screen space.


Maximize Button

A button on a UserObject, UserFunction, and the Main window, that enlarges the window to fill all of the available work space in the VEE window. For the VEE window, this enlarges the window to fill all of the available screen space.


Menu

A collection of features that are presented in a list. See also Cascading Menu, Main Menu, Object Menu, Pop-Up Menu, and Pull-Down Menu.


Menu Bar

The bar at the top of the VEE window that displays the titles of the pull-down, main menus, from which you select features.


Menu Title

The name of a menu within the VEE menu bar. For example, File or Edit.


Minimize

1. To reduce an open view of an object to its smallest size -- an icon.

2. To reduce a window to its smallest size -- an icon.


Minimize Button

A button on an object, or the VEE window, that iconifies the object, or the VEE window.


Mouse

A pointing device that you move across a surface to move a pointer within the VEE window.


Mouse Button

One of the buttons on a mouse that you can click or double-click to perform a particular action with the corresponding pointer in the VEE window.


Network

A group of computers and peripherals linked together to allow the sharing of data and work loads.


Object

A graphical representation of an element in a program, such as an instrument, control, display, or mathematical operator. An object is placed in the work area and connected to other objects to create a program.


Object Menu

The menu associated with an object that contains features that operate on the object (for example, moving, sizing, copying, and deleting the object). To obtain the object menu, click on the object menu button at the upper-left corner of the object, or click the right mouse button with the pointer over the object.


Object Menu Button

The button at the upper-left corner of an open view object, which displays the object menu when you click on it.


Open

To start an action or begin working with a text, data, or graphics file. When you select Open from VEE, a program is loaded into the work area.


Open View

The representation of a VEE object that is more detailed than an icon. Most object open views have fields that allow you to modify the operation of the object.


Operate

The action of an object processing data and outputting a result. An object operates when its data and sequence input pins have been activated. See Activate.


Operator Interface

The interface that the VEE programmer creates to allow the operator (end-user) to control the program. A typical operator interface involves panel views and dialog boxes.


Outline Box

A box that represents the outer edges of an object or set of objects and indicates where the object(s) will be placed in the work area.


Palette

The set of possible colors available in VEE.


Panel Driver

An instrument control object that forces all the function settings in the corresponding physical instrument to match the settings in the control panel displayed in the open view of the object.


Panel View

The view of a VEE program, a UserObject, or a UserFunction that shows only those objects needed for the user to run the program and view the resulting data. You can use panel views to create an operator interface for your program.


Pin

An external connection point on an object where you can attach a line.


Pointer

The graphical image that maps to the movement of the mouse. The pointer allows you to make selections and provides you feedback on a particular process underway. VEE has pointers of different shapes that correspond to process modes, such as an arrow, cross hairs, and hourglass.


Pop-Up Menu

A menu that is raised by clicking the right mouse button. For example, you can raise the Edit menu by clicking the right mouse button in an empty area within the work area. Or you can raise the object menu by clicking the right mouse button on an inactive area of an object.


PostRun

The set of actions that are performed when the program is stopped.


Preferences

Preferences are attributes of the VEE environment that you can change using the Default Preferences button on the toolbar, or the menu File [image] Default Preferences. For example, you can change the default colors, fonts, and number format.


PreRun

The set of actions that resets the program and checks for errors before the program starts to run.


Program

In VEE, a graphical program that consists of a set of objects connected with lines. The program typically represents a solution to an engineering problem.


Program Explorer

A facility in the VEE window that permits exploration of a program, especially the parts of a program that might not be visible on the physical screen. (The Program Explorer is available in VEE Pro only.)


Promote

To convert from a data type that contains less information to one that contains more information. See also Data Type and Demote.


Propagation

The rules that objects and programs follow when they operate or run. See also Data Flow.


Properties

Object properties are attributes of VEE objects that you can change using Properties on the object menu. Properties can be changed for the Main, UserObject, and UserFunction windows using Properties on their object menus. Properties include colors, fonts, and titles.


Pterodactyl

Any of various extinct flying reptiles of the order Pterosauria of the Jurassic and Cretaceous periods. Pterodactyl are characterized by wings consisting of a flap of skin supported by the very long fourth digit on each front leg.


Pull-Down Menu

A menu that is pulled down from the menu bar when you position the pointer over a menu title and click the left mouse button.


Radio Button

A diamond-shaped button in VEE dialog boxes that allows you to select a setting that is mutually exclusive with other radio buttons in that dialog box. To select a setting, click on the radio button. To remove the setting, click on another radio button in the same dialog box.


Record

A VEE data type that has named data fields which can contain multiple values. Records are typically used to group related articles of information. However, each record field can contain a different data type. Each field can contain another Record container, a Scalar, or an Array. The Record data type has the highest precedence of all VEE data types. However, data cannot be converted to and from the Record data type through the automatic promotion/demotion process. Records must be built/unbuilt using the Build Record and UnBuild Record objects.


Remote Function

A UserFunction which is callable from the local host. (Remote functions are supported in VEE Pro only.) The Import Library object starts the process on the remote host and loads the UserFunctions into the VEE process on the remote host. You can then call the Remote Function with the Call Function object, or from certain expressions. See also UserFunction, Remote Functions, and Compiled Function.


Restore

To return a minimized window or an icon to its full size as a window or open view by double-clicking on it.


Run

To start the objects on a program or thread operating.


Save

To write a file to a storage device, such as a hard disk.


Scalar

A data shape that contains a single value. See also Data Shape.


Schema

The structure or framework used to define a data record. This includes each field's name, type, shape (and dimension sizes), and mapping.


Screen Dump

A graphical printout of a window or part of a window.


Scroll

The act of using a scroll bar either to move through a list of data files or other choices in a dialog box, or to pan the work area.


Scroll Arrow

An arrow that, when clicked on, scrolls through a list of data files or other choices in a dialog box, or moves the work area.


Scroll Bar

A rectangular bar that, when dragged, scrolls through a list of data files or other choices in a dialog box, or moves the work area.


Select

To choose an object, an action to be performed, or a menu item. Usually you select by clicking with your mouse.


Select Code

A number used to identify the address of a hardware interface. The term "select code" has been superceded by the term Logical Unit.


Selection

1. A menu selection (feature).

2. An object or action you have selected in the VEE window.


Selection Field

A field in an object or dialog box that allows you to select choices from a drop-down list.


Sequence Input Pin

The top pin of an object. When connected, execution of the object is held off until the pin receives a container (is "pinged").


Sequence Ouput Pin

Sequence Output Pin

The bottom pin of an object. When connected, this output pin is activated when the object and all data propagation from that object finishes executing.


Sequencer

An object that controls execution flow through a series of sequence transactions, each of which may call a UserFunction, Compiled Function, or Remote Function. The sequencer is normally used to perform a series of tests by specifying a series of sequence transactions. (The Sequencer is available in VEE Pro only.)


Sleep

An object sleeps during execution when it is waiting for an operation or time interval to complete, or for an event to occur. A sleeping object will allow other parallel threads to run concurrently. Once the event, time interval, or operation occurs, the object will execute, allowing execution to continue.


Startup Directory

See Working Directory.


State

A particular set of values for all of the components related to a VEE instrument panel, which represents the measurement state of an instrument. For example, a digital multimeter uses one state for high-speed voltage readings and a different state for high-precision resistance measurements. See also Instrument Panel.


Status Bar

A line at the bottom of the VEE window where information about the current status of and information about VEE is displayed.


Status Field

A field displaying information that cannot be edited. A status field looks like an entry field, but has a gray background.


Step

The action of operating a VEE program one object at a time (to debug the program). The object that will operate next is indicated by a yellow highlight. VEE provides three ways to step through a program, Step Into, Step Over, and Step Out, to control operation of objects in a UserObject and a UserFunction.


Terminal

The internal representation of a pin that displays information about the pin and the data container held by the pin. Double-click on a terminal to view the container information.


Terminal Area

The areas on the left and right sides of an object where terminals are displayed when Show Terminals is active for that object. The input terminal area is on the left, and the output terminal area is on the right side of an object.


Thread

A set of objects connected by solid lines in a VEE program. A program with multiple threads can run all threads simultaneously.


Title Bar

The rectangular bar at the top of the open view of an object or window, which shows the title of the object or window. You can turn off an object title bar using Properties on the object menu.


Toolbar

The rectangular bar at the top of the VEE window which provides buttons for quick access to frequently used commands. The buttons run commands from menus such as File, Edit, View, Debug, and Device.


Transaction

The specifications for input and output (I/O) used by certain objects in VEE. These include the To File, From File, Direct I/O, and Sequencer objects. Transactions appear as phrases listed in the open view of these objects.


Trig Mode

The Trig Mode is an attribute that determines whether trigonometric values are displayed in degrees, radians, or gradians. Note that VEE automatically converts trigonometric values to radians for calculation purposes.


User-Defined Function

A function that you can create, and then call in a VEE program. You can create three types of user-defined functions that can be called using the Call Function object, or from certain expressions. See also UserFunction, Compiled Function, and Remote Function.


UserFunction

A user-defined function created directly in a UserFunction window or from an existing UserObject. The UserFunction exists in the background of the VEE process, but provides the same functionality as a UserObject. You can call a UserFunction with the Call Function object, or from certain expressions. A UserFunction can be created and called locally, or it can be saved in a library and imported into a VEE program with Import Library. (Import of UserFunctions is supported in VEE Pro only.) See also Compiled Function, Remote Function, and UserObject.


UserObject

An object that can encapsulate a group of objects to perform a particular purpose within a program. A UserObject allows you to use top-down design techniques when building a program, and to build user-defined objects that can be saved in a library and reused.


Variable

A named variable that is either declared or undeclared. Variables can be declared as local, global to context, or global to library using Declare Variable. Local and global variables can have values set at run time without being declared; however, programs run faster with declared variables.


View

VEE can present programs and objects in various views. Programs can appear in detail or open views, objects can appear in open or icon views. See Detail View, Icon, Open View, and Panel View.


Wait

See Sleep.


Window

A rectangular area on the screen that contains a particular application program, such as Agilent VEE.


Windows 98

An operating system using a windowing interface, developed by Microsoft Corporation, in which VEE runs. Windows 98 systems run 32-bit applications, but are not designed with a distinct user/kernel boundary.


Windows NT, 2000, and XP

Operating systems using a windowing interface, developed by Microsoft Corporation, in which VEE runs. Windows NT, Windows 2000, and Windows XP systems run 32-bit applications and are characterized by a distinct user/kernel boundary.


Work Area

The area within the Main, UserObject, or UserFunction windows in which you place VEE objects and wire them together to create a VEE program. When you Open a program, it is loaded into the Main window's work area.


Work Space

The space in the VEE application window that contains the programming or editing windows such as Main, UserObject, and UserFunction. These windows contain work areas in which you place VEE objects and wire them together to create a VEE program.


Working Directory

The directory in which VEE runs. For example, "C:\Program Files\Agilent\VEE Pro 7.0" is the default working directory of VEE Pro for Windows. The working directory is sometimes called the "startup directory," because it is specified in the shortcut used to start VEE.


XEQ Pin

A pin that forces the operation of the object, even if the data or sequence input pins have not been activated. Only available on the Collector and Sample & Hold objects. See also Control Pin, Data Input Pin, and Sequence Input Pin.


ActiveX

A communication mechanism that allows processes to communicate on the Windows platform. ActiveX is family of technologies, based on Microsoft COM, that includes various aids to distributed computing, such as ActiveX Controls and ActiveX Automation Servers.


Error 756

Error 756 is generated when VEE fails to create a .NET object with the CreateInstance built-in function. The following check list might help you debug and fix the error.

Error 756 Checklist

  1. Did you add a reference to the assembly that the .NET class is in?

  2. Open the Function & Object Browser, select the assembly, the namespace and the class type you want, if you do not see the class that you want, then you cannot create a .NET object of that class type.

  3. Do you see any constructors for that class? If there is no constructors for that class, you are not able to create a .NET object of that class type.

  4. Did you use the Create Instance button to create the formula template? If you did, you should be able to avoid a lot of common mistakes such as mistyping the assembly name or class name.

  5. Unlike CreateObject in COM, constructors of .NET classes may take any number of parameters. So make sure you provide the correct number of parameters with correct types to the CreateInstance call. If you use the Function & Object Browser, VEE helps you select the right constructor and provides placeholders for the correct number of input parameters. You must make sure the parameter types are correct as well.

  6. Read the VEE error box. .NET exceptions typically provide a lot more content than COM. If the content does not help, check MSDN if the class is from the .NET common class library.


Error 300
The input terminal number <n> is not connected

Resolution

You may get this error message in three different situations:

1. When a data input pin is not connected.

All data input terminals on an object must be connected before a program can run. Find the object that caused the error (the object with a red outline) and make the necessary connections.

2. On a UserObject/UserFunction when an inside pin of an output terminal is not connected.

You may get this message on a UserObject or UserFunction when the error message mentions the input terminal of an output buffer. This means the inside pin of an output terminal is not connected to an object inside the UserObject or UserFunction. All inside pins of output terminals must be connected before a program can run.

To determine which pin is not connected, look at the open view of the UserObject or the editing view of the UserFunction. From the Properties Window, select Show Terminals to view the terminal area.

3. When importing a UserFunction.

If you've gotten this message when importing a UserFunction, there is an object inside the UserFunction that has an unconnected input terminal. You need to load the UserFunction via File [image] Open File [image] Merge Library, modify the UserFunction, and save it. Open the previous program and run it; the UserFunction will import properly.


Error 553
An ActiveX object returned an error during <action> <name>.

Resolution

This error happens when an ActiveX object returns the error code DISP_E_EXCEPTION. This error can be caused by passing bad values to a property or method. It can also be caused when an ActiveX object is requested to "error" in certain situations. For instance, the Windows Common Dialog control provides access to several common dialog boxes. You can set these dialog boxes to "error" if the user presses the Cancel button. In this case, the ActiveX object returns an error indicating that the Cancel button was pressed.


Error 557
ActiveX object could not be created.

Resolution

There are various reasons why VEE may not be able to create an ActiveX object. A resolution to the problem depends on the reported error code:

If the error code reported by VEE is 0x80080005, then Windows was unable to load the ActiveX server or control based on the information in the registry. This error can occur when the server or control is registered in a directory with a long file name that contains a space and a similar directory name exists at the same level. For more information see Microsoft Knowledge Base Article Q179690. The recommended solution is to install the server or control in a directory without spaces in the path or in a directory that isn't named similar to other directories at the same level.

If the ActiveX object indicates an error code of 0x80040112, then the control is licensed. This error can appear if the licensed control is not installed properly. When the full control package is installed properly, a license exists that lets you create an instance of the control when developing a VEE program. VEE requests a license key from the control and saves this key with your VEE program. This method lets you distribute a copy of the control’s file with your program to one or more target computers. VEE presents this key to the control on a target computer, allowing VEE to create an instance of the control.

This error message can appear if you try to use the control on target computers. You cannot use the control to create new programs, and you cannot clone or copy/paste the control in an existing program. Remember, the control is not licensed on the target computer for you to use; the license key only allows VEE to reference the control. You must purchase and install the full control package.


Error 593
MATLAB Script execution error

Resolution

Numerous MATLAB run-time errors are all mapped to VEE Error 593, and the "Go To" button on the VEE error box shows only the MATLAB Script Object, not individual MATLAB program lines. This means you must do some troubleshooting to find and correct the actual problem which caused error 593. Two helpful hints are: Read the MATLAB error message text, and use the msgbox function. These are demonstrated in the following example.

This small VEE example reads a vector of "Y" values from a file, generates a linear ramp of "X" values, and plots an X-Y graph using those two vectors. Assume that the following error occurs when this program is run.

Note the second paragraph in this dialog box contains the error message generated by MATLAB Script, in this case, Invalid fid. This means the fscanf function was given an invalid file identifier. To investigate further, display the value returned by the fopen function. For example, insert a line as shown below:

dfile=fopen('C:sineWave.txt','r')
uiwait(msgbox(int2str(dfile)))
ydat=fscanf(dfile,'%f')

The second line shows some useful debugging techniques for MATLAB Script. The combination uiwait(msgbox(...)) displays a text box and waits for you to press its OK button. Since there are no "line probes" or "watch windows" to view MATLAB variables, message boxes are a convenient way to display values while debugging. The msgbox function requires a string parameter, so the int2str function is used to convert the numeric file ID.

When the example is run with the added debug line, the message box reports a file ID of -1. The MATLAB Help Desk topic for fopen says that -1 is the value returned when an fopen fails. In other words, the fscanf function saw an invalid file ID because no file was opened. This could happen for any of the typical file-system reasons, such as no permissions, misspelled path name, etc. Assume that you correct the file path and rerun the example. The following error results.

Again, the second paragraph shows the MATLAB error message. In this case, the plot function failed because the X and Y vectors are not the same length. You could use msgbox to inspect the length of xdat and ydat, or you could review the semantics of the MATLAB colon operator. Either way, you would be reminded that MATLAB arrays start with element "0". Therefore, if length(ydat) is 256, then the xdat ramp is created with 257 elements: 0..256. The corrected statement is:

xdat=0:1:length(ydat)-1;

This is just an imaginary example, but it introduces techniques which are helpful when debugging any MATLAB Script object. In summary:

Look for details in the MATLAB error message. The second paragraph in the "VEE Run Time Error" dialog lists the failed MATLAB function and a line about the nature of the problem.

Insert msgbox to display values. Convert numeric values to strings before displaying. Remember to remove any unneeded msgbox lines after they are no longer needed for debugging.

Make liberal use of the MATLAB documentation. To view MATLAB Help from the VEE Window, select: Help [image] MATLAB Script [image] Help Desk


Error 601
Invalid expression: <description>

Resolution

If this error appears with a <description> referring to a syntax error in a Formula object expression, check the following conditions:

1. Be sure each expression ends with a ";" (semi-colon). Though the message indicates the error’s location, a semi-colon may be missing from the end of the previous expression, and that expression may be on the previous line.

2. Avoid using variable names in lower execution modes that are unique keywords in a higher execution mode. This includes keywords such as Set and ByRef. To check the program’s execution mode setting, look in the status bar in the lower right corner of the VEE window.

3. Avoid assigning a value to a built-in constant. VEE defines the following built-in constants in VEE 5 (or higher) execution mode: TRUE, FALSE, PI.

4. Triadic operators require parentheses around the whole statement:

Right:
(a==0 ? TRUE : FALSE)

Wrong:
a==0 ? TRUE : FALSE

5. In an expression that builds or modifies an array, the syntax requires comma-separated indices:

Right:
[1,1,0]

Wrong:
[1 1 0]


Error 739
Stack pointer corrupted after return from compiled function <function_name>

Resolution

The most common cause of stack pointer corruption is using the wrong calling convention for a function’s prototype. This declaration is found in your definition (.h) file. If no calling convention is specified, VEE assumes the _cdecl convention by default. For example, these two declarations are the same to VEE, and both result in a _cdecl function:

long func1(long a, long b)
long _cdecl func1(long a, long b)

The most common alternative is the __stdcall convention. It can be specified explicitly or with a common macro. For example, these two declarations both result in a __stdcall function:

long __stdcall func2(long x)
long WINAPI func2(long x)

One primary purpose of a calling convention is to determine who "cleans up" the stack. Either the caller (VEE) or the callee (your function) can perform this cleanup. It is essential that stack cleanup be performed in one, and only one place. If the function prototype does not match the function code in the DLL, the stack pointer might be repositioned twice or not at all. Either form of mismatch is potentially fatal to program execution.

Almost all Win32 API functions use the __stdcall calling convention. Only those Win32 API functions that take a variable number of arguments are _cdecl. Any DLL that works with Visual Basic, uses the __stdcall calling convention. Most DLLs written in C use the _cdecl calling convention, unless the function is declared as __stdcall, or the DLL is compiled with the /Gz Microsoft compiler option.

Another potential cause of stack pointer corruption for a __stdcall function is if the wrong number or the wrong type of parameters are declared in the function prototype.

The quickest fix for this error is to modify the definition (.h) file, making it properly describe the behavior of the DLL. VEE will read the new definition the next time you run your program. (To see the name of the definition file, check VEE’s Import Library object.)


Error 751

The most common cause of error 751 is a System.MissingMemberException or System.MissingMethodException has been thrown during a .NET operation. In this case, there are several things that might help you debug and fix the error.

Checklist for Error 751

1. Did you use the Function & Object Browser to generate the template? You should be able to avoid a lot of 751 errors by using the Function & Object Browser.

2. Check the spelling for the member you want to invoke.

3. Do you mean to invoke a method or a property? A method requires “(“ and “)” even if it has no parameters. A property typically does not have “(“ and “)” unless it is an indexed or parameterized property.

4. Did you provide the right number of parameters?

5. Does each parameter have the correct type? .NET operations in VEE will usually accept a precision-widening data type as a parameter, but not a precision narrowing data type, e.g., you may pass VEE’s UInt8 to a .NET operation that requires a parameter of type Int16, but not the other way around. Also, if the .NET operation requires a ByRef parameter and you want to retrieve its result back, then the data type has to be exactly as required, e.g., if the .NET method requires a parameter of type ByRef Int32, then you can only pass VEE’s ByRef Int32 data type. If you don’t care about retrieving the result back, then you may skip the ByRef keyword and the normal parameter rule would apply.

6. If you are calling a Static (aka Shared) member, indicated by an 'S' in the icon within the Function & Object Browser, you must not use an instance variable. Use the class name to call a Static (aka Shared) member. The Function & Object Browser automatically generates the correct syntax using the class name (even taking into account namespace imports) for you for static (AKA Shared) members.

See Also

About .NET Errors in VEE


Error 810
Instrument driver error <n>: <description>
Refer to your instrument manual for further information

Resolution

An instrument error has occurred. This error shows the instrument error that was passed from the instrument, to the instrument driver, into VEE

For example, the error may look like:
Instrument driver error 1051: Device xxx reported error nnn

"xxx" - is the name you assigned to the instrument under I/O [image] Instrument Manager.

"nnn" - is the instrument's error message to look up in your instrument manual to find what the error really is. Your instrument manual will give details.


Error 811
I/O error or timeout occurred

Resolution

This error occurs when VEE cannot communicate with the instrument. The following actions often solve this problem:

Double-check that the instrument is plugged in and turned on.

Check the cable connections, make sure they're tight.

Make sure the I/O address is correct.

When using instrument drivers, make sure you've specified the correct driver file for the instrument.

Note: If transferring a large amount of data or the instrument is slow, increase the timeout value via the I/O [image] Instrument Manager.


Error 851
There is no Service Manager on host, <name>

Resolution

The Service Manager could not be started. You may get this error message in when:

1. The Service machine does not have the Service Manager started.

For Programs Running on Windows NT:

The Service Manager is a console application named veesm.exe found in the VEE installation directory. Start it by using Run from the Start Menu:

"C:\Program Files\Agilent\VEE 5.0\veesm.exe"

If you prefer, put the Service Manager in the Startup group so that it is automatically started when Windows starts running. Set the shortcut properties to so that the Service Manager will run minimized.


Error 906
Thread with feedback requires START object

Resolution

Feedback allows you to set initial values or access values from previous iterations of a loop.

To use feedback, you must have a Start object connected to an object in the feedback loop to indicate which object (or subthread) should execute first.


Error 910
Process is out of memory, save your program IMMEDIATELY

Resolution

Save your program to a different file name immediately.

For Programs Running on Windows NT:

The program has used up all available swap space.

One possible cause is if the program allocates very large arrays or records, and performs operations on these structures in their entirety. If so, you may want to modify the program to perform operations on only parts of the structures.

Otherwise, you will need to allocate more swap space before you can run the VEE program that used all the swap space.

On Windows NT: Click the right mouse button on My Computer and select Properties. Select the Performance tab, and choose the Virtual Memory button to adjust your virtual memory settings.


Error 935
A Junction is required inside of feedback cycles.

Resolution

In VEE 4 (or higher) compatibility mode, a Junction object is required inside of a feedback cycle. Start objects are no longer required.

Refer to Appendix A of the Agilent VEE Advanced Programming Techniques manual for an example.


Error 937
Sample & Hold was not given any data.

Resolution

The XEQ pin of a Sample & Hold object has been hit, but the object does not contain data. Therefore there is no data to output. Change your program to ensure data is sent to the Sample & Hold object before the XEQ pin is executed. This error is only generated in VEE 4 (or higher) compatibility mode.


Error 938
VEE was unable to compile this part of the program.

Resolution

In VEE 3.x and older versions, you could intersect iteration objects. The execution order was undefined but was affected by the order the connections were made. This is also true for programs running in VEE 3 compatibility mode.

In VEE 4.x and newer versions, when compatibility mode is set to VEE 4 (or higher), only loops that intersect via a Junction object are allowed. Any other intersecting loops generate this error.

Refer to Appendix A of the Agilent VEE Advanced Programming Techniques manual for more information.


Error 939
Cannot push START when thread is connected to input terminals.

Resolution

You have a UserObject or UserFunction that contains a Start object that, when pressed, would try to run a thread that depended on data generated outside the context. Because only objects inside the context execute when Start is pressed, the missing data prevents one or more objects from executing; the missing data generates this error. This error is only generated in VEE 4 (or higher) compatibility mode.

Solutions include:

Provide data to the objects. Temporarily disconnect the inputs from the UserObject or UserFunction input terminals and connect them to Constant object or other objects that output data. Or use a Junction to provide an initial value.

Separate the section of thread you were trying to debug by putting it in a separate UserObject and running it by itself.


Error 940
Illegal form of feedback

Resolution

This error is generated in VEE 4 (or higher) compatibility mode when a feedback loop exists without an iterator. Because there is no iterator, the feedback loop is not complete.

Either insert an iterator into the program to complete the loop or take out the Junction object to eliminate the feedback.


Error 941
T1 must be activated before T2.

Resolution

In VEE 4 (or higher) compatibility mode, the top-most data input pin (T1) of a Timer object must be executed before the bottom data input pin (T2). Either switch the line connections (between T1 and T2) or change the program logic so that the pins are executed in the correct order.


Error 950 through 999

These error codes are used by Agilent VEE internal operations, and should not appear in normal operation. If one of these error codes appears, you will see the following box:

The Internal Error type, error number, Object title, and Object type will vary. Please enter your name, email address, and then press the Send Error Report button. A mini-dump will be sent to Agilent. Mini dumps help Agilent track reliability issues and quickly identify and correct these problems. In some cases, Agilent may need your help to reproduce the defect, in these cases you will be contacted using the email address you provide. If you do not want to be contacted, please leave these fields blank. In any case, please send the error report. Even without the ability to reproduce an error, these reports provide valuable information about the product. Please review the additional information regarding mini-dumps at the end of this topic.

Caution

Before you proceed, you should be aware that VEE will not let you save over the existing program file when you encounter this type of error. However, you can save the broken program with a different name. It may load and run for several days without problems, and later execute a corrupt part of the program, repeating this or a similar error.

The original program saved on the hard disk is not affected by this error. Follow these steps to decide how to proceed with your programming:

1. Save the program to a new file name, and exit VEE.

2. Check if the new program is corrupt, by opening and running it in a new VEE window, making sure to exercise all of its threads. Choose one of the following options, depending on the results:

a. If the new program opens and runs without errors, you can continue using it. Be aware that a corrupted area may still exist. If the program continues to perform reliably, then it probably is not corrupt.

b. If the new program opens and runs without errors, you can choose not to use it to avoid potential problems. You can still refer to it for programming changes not saved in the original program. You should not copy threads from the new program to the original, since the copy may contain corrupted areas. Keep the new program for reference when explaining the problem to Agilent Support.

c. If the new program is corrupt, please do not delete it. Keep the new program for reference when explaining the problem to Agilent Support. Certain program artifacts may exist that will be useful. Exit VEE without saving the program, then open the original program in a new VEE window to continue programming.

Mini-Dumps

VEE uses mini-dumps to save enough information to recreate most of the details concerning the process that is currently running. This information includes the values of parameters to each function, local variable values in each of these functions as well as memory associated with local variables that are pointers, and more. This information allows Agilent to more easily determine the cause of the error.

Mini-dumps also include the full path to all the executable modules including the VEE executable and any DLLs that may also be loaded including any that have been imported into VEE via the Import Library object. Note also that if there is sensitive information in your VEE program such as passwords, code names, etc., that information could wind up in the mini-dump that is sent back to Agilent. Agilent will take reasonable precautions to protect the privacy of the information contained in these error reports. However, you are under no obligation to send these error reports to Agilent.


HC_BrowserCall

Creates a Call object for the currently selected function. Place the Call in a program context. It is simply a template which can be edited as desired.


HC_BrowserFormula

Creates a Formula object for the currently selected function or operator. Place the Formula in a program context. It is simply a template which can be edited as desired.


HC_BrowserGet

Creates a Formula object to Get the value of the currently selected member (property). Place the Formula in a program context. It is simply a template which can be edited as desired.


HC_BrowserHelp

Displays Help for the currently selected function or object (not Help about the Browser).


HC_BrowserSelectArea

This browser presents functions and objects in a hierarchical arrangement. Choose the broad classification from the left column, the sub-category from the middle column, and the specific function or object from the right column. Then click one of the Create... buttons (or double-click the selection) to create a VEE object from your selection. Place this VEE object in a program context and edit it as desired.


HC_BrowserSet

Creates a Formula object to Set the value of the currently selected member (property). Place the Formula in a program context. It is simply a template which can be edited as desired.


HC_FindAllMatches

When this box is checked, all matches are reported for each object. The default is off, which reports only the first match found for each object.


HC_FindMatchCase

When this box is checked, the search is constrained to exact matches of the letter-case specified in the Find line. The default is off, which treats upper-case and lower-case letters as equal.


HC_FindNested

When this box is checked (the default), the search traverses all levels of nested User Objects. If not checked, only the current level is searched.


HC_FindObjectType

The Object Type property constrains the search to objects of the type(s) selected in the Value list. The default is all object types. To constrain the search, click the Value button and check or uncheck the desired types. Select All and Clear All buttons are provided for convenience.


HC_FindOtherProperty

The Property buttons can be used to constrain the search according to various object properties. Once a Property is selected, specify the desired constraint in the Value column. For example, if you select Breakpoint/On, then only objects with active breakpoints are searched.


HC_FindReset

The Reset button restores the default Property/Value list, which is all object types with no constraints.


HC_FindSearchIn

This field indicates the scope of the search. The default is the Entire Program. If you want to limit the scope of a search, open the Find dialog from the Program Explorer by clicking with the right mouse button on a particular context, such as a UserFunction or UserObject.


HC_FindShowBegin

When this box is checked, a match is reported if the Find text occurs at the beginning of the text being searched.


HC_FindShowContain

When this box is checked, a match is reported if the Find text occurs anywhere in the text being searched.


HC_FindShowEnd

When this box is checked, a match is reported if the Find text occurs at the end of the text being searched.


HC_FindShowExact

When this box is checked, the Find text must match the entire field of the text being searched.


HC_FindTarget

Enter the text string you want to find in your VEE program. If you leave this line blank, the search will match any text.


HC_IconAddToPanel

The Add To Panel button places the selected objects onto the panel view of the program. If a panel view does not already exist, one is created. Panels are associated with the current context and can be nested.


HC_IconBreakpoint

The Toggle Breakpoint button aids debugging by setting or clearing execution breakpoints at the selected objects. A breakpoint on an object pauses program execution immediately before that object. Breakpoints can also be accessed in the Object Menu Properties.


HC_IconCallStack

The Call Stack button aids debugging by displaying the hierarchy of UserObjects or UserFunctions invoked to reach the current paused UserObject or UserFunction. Clicking on any entry in the Call Stack dialog opens that UserObject or UserFunction in the VEE workspace.


HC_IconCopy

The Copy button places a copy of the selected objects in the Paste buffer and on the Windows Clipboard.


HC_IconCut

The Cut button deletes the selected objects and places them in the Paste buffer and on the Windows Clipboard.


HC_IconDefaultPrefs

The Default Preferences button provides the Default Preferences dialog. This dialog has six tabs containing many and varied customizable VEE settings.


HC_IconDelLine

The Delete Line button provides the Delete Line cursor, which you then click on the line to be deleted. (A handy shortcut to delete lines is Ctrl-Shift-Click.)


HC_IconFind

The Find button provides a dialog box used to search for text strings and certain object properties in your VEE program. Various search properties, such as Match Case and Object Type, can be used to constrain your searches. To limit the scope of a search, open Find from the Program Explorer by clicking a specific context with the right-hand mouse button.


HC_IconFindResults

The Find Results button displays the results from the most recent Find search. You can change the sorting order of a column by clicking on the column header.


HC_IconFuncBrowser

The Function & Object Browser button provides the Function & Object Browser dialog. This browser provides convenient access to various math operations, objects, and properties.


HC_IconInstrMgr

The Instrument Manager button provides the Instrument Manager dialog. This dialog provides convenient editing, viewing, and creating of I/O resources such as instrument transactions and drivers.


HC_IconNew

The New button clears the VEE workspace. You will be prompted if there are any unsaved changes in the current program.


HC_IconOpen

The Open button loads a program file into the VEE workspace, replacing any existing program. You will be prompted if there are any unsaved changes in the current program.


HC_IconPaste

The Paste button places a copy of the Paste buffer onto the VEE workspace. You can Paste objects that were accidentally Cut, and connections to those objects will be restored.


HC_IconPause

The Pause button stops execution of all program threads temporarily. When a program is in the paused state, either Step or Run/Resume can be used to proceed with program execution from the point it was paused.


HC_IconPrint

The Print Screen button sends the visible contents of the VEE window to a printer. To configure the printer, use File [image] Print Screen.


HC_IconProfiler

The Profiler button provides the Profiler dialog. The Profiler provides comparative information about the execution time of each UserObject and UserFunction.


HC_IconProgExplorer

The Program Explorer button shows or hides the Program Explorer window. The Program Explorer shows the hierarchical structure of the current VEE program.


HC_IconRun

The Run button starts execution of all threads in a program. If your program has several threads, and you want to run only one of them, use a Start object to that thread instead of the Run button.


HC_IconRunState

This area displays the run state of the program. Indicators are:

Blank Ready (stopped)
Green Arrow Running
Yellow Bars Paused
Red Bars Error


HC_IconSave

The Save button writes the current program to the previously specified file name. Save uses the file shown in the VEE window title bar. If this is a New program that has not been saved previously, you will be prompted for a file name. To change file names, use File [image] Save As.


HC_IconShowData

The Show Data Flow button aids debugging by visually indicating the route that data takes through the program. The speed of the small square data marker is set in the Default Preferences [image] General tab, Debug area.


HC_IconShowExec

The Show Execution Flow button aids debugging by highlighting the currently executing object(s) while the program is running. In the paused or error state, Show Execution Flow highlights all objects that have already executed.


HC_IconStepIn

The Step Into button aids debugging by executing one primitive object at a time. When a UserObject or local or imported UserFunction is encountered, VEE puts it into its detail view and executes each object in that view.


HC_IconStepOut

The Step Out button aids debugging by executing one primitive object at a time. If the execution is in a UserObject or UserFunction, VEE completes execution of all objects in that UserObject or UserFunction.


HC_IconStepOver

The Step Over button aids debugging by executing one primitive object at a time. When a UserObject or UserFunction is encountered, it is executed in its entirety and is not opened into a detail view.


HC_IconStop

The Stop button stops execution of all program threads and closes any open files. When a program is in the stopped state, pressing Step or Run/Resume restarts program execution from the beginning.


HC_IconViewVars

The View Variables button displays a list of all variables that are currently defined. Double-click a variable's name to view details such as type, shape, and data values.


HC_InstrMgrDlgAdd

Click the Add button to add an instrument to your I/O configuration. A manual Add operation is needed for instruments that are not discovered by the Find Instruments button. For example, RS-232 instruments or instruments connected via a LAN gateway. (An interface entry is automatically added when you add an instrument associated with that interface.)


HC_InstrMgrDlgComponent

Click the Component Driver button to create a Component Driver object for the currently selected instrument. (A Component Driver is an efficient link to one component of an instrument’s Panel Driver.)


HC_InstrMgrDlgConfigDrivers

The Configure Drivers button identifies the selected instrument and configures any available VXIplug&play and Panel Drivers for that instrument. (Only IEEE 488.2, and most VXI, instruments can be identified.)


HC_InstrMgrDlgDirectIO

Click the Direct I/O button to create a Direct I/O object for the instrument currently selected. (A Direct I/O object allows low-level transactions with the instrument.)


HC_InstrMgrDlgFindInstr

When the root node is selected, click the Find Instruments button to search for available interfaces and instruments. When a specific interface is selected, click this button to search for all instruments connected to the selected interface. The exact operations performed by the Find Instruments button are controlled by the Settings dialog.


HC_InstrMgrDlgOK

Click the OK button to save the instrument configuration in an internal cache and close the Instrument Manager. The current configuration is used by the program, but is not yet saved to disk.


HC_InstrMgrDlgPanel

Click the Panel Driver button to create a VEE Panel Driver object for the currently selected instrument. (A Panel Driver is the full-featured graphical simulation of an instrument’s front panel.)


HC_InstrMgrDlgPnP

Click the Plug&play Driver button to create a VXIplug&play driver object for the instrument currently selected. (A VXIplug&play driver is an industry standard API based upon VISA.)


HC_InstrMgrDlgPrint

The Print button brings up a standard Windows Print dialog. The Instrument Manager printout is a bitmap dump of the full Instrument List tree view.


HC_InstrMgrDlgPropertiesInstr

Click the (Instrument) Properties button to view or modify the I/O-related properties of the currently selected instrument. The interface type determines the set of properties available. For example, RS-232 instruments have a Properties field for setting the Baud rate, while GPIB instruments have a Properties field for setting the bus address.


HC_InstrMgrDlgPropertiesIntf

Click the (Interface) Properties button to view specific details about the currently selected interface.

Note that VEE cannot modify the hardware characteristics of an interface or alter the configuration performed by the operating system or the I/O Config utility. If you enter different values in any of the Interface Properties fields, you must use values that match an existing, configured interface.


HC_InstrMgrDlgRemoveInstr

Click the Remove button to delete an instrument entry from the I/O configuration. (An interface entry is automatically removed when all the instruments associated with that interface are removed.)


HC_InstrMgrDlgRemoveIntf

Click the Remove button to delete an instrument entry from the I/O configuration. (An interface entry is automatically removed when all the instruments associated with that interface are removed.)


HC_InstrMgrDlgSave

Click the Save button to save the instrument configuration to disk and close the Instrument Manager. This overwrites the vee.io file with the current configuration.

If the instrument configuration is embedded in the program, a Save from the Instrument Manager is not necessary, because an embedded configuration is saved when the program is saved.


HC_InstrMgrDlgSettings

The Settings dialog controls some of the actions performed during instrument discovery.

If Detect only is selected, the Find Instruments button simply detects whether a device is present at each bus address. If Detect, identify, and configure... is selected, the Find Instruments button also performs an identification and driver configuration for each instrument detected.

If Ask before sending... is checked, a confirmation dialog is presented before *IDN? is sent to identify each instrument. If not checked, *IDN? is sent to all instruments without operator confirmation. You may want the confirmation dialog if your system contains old, non-IEEE-488.2 instruments.


HC_InstrMgrDlgSettingsId

If Ask before sending... is checked, a confirmation dialog is presented before *IDN? is sent to identify each instrument. If not checked, *IDN? is sent to all instruments without operator confirmation. You may want the confirmation dialog if your system contains old, non-IEEE-488.2 instruments.


HC_MainContext

The Main window is the root UserObject in VEE programs. It is required in programs and cannot be deleted. Other UserObject and UserFunction windows are created from the Main window.

If the Main window has been minimized or closed, it can be re-opened by selecting it from the View menu. It can also be reopened by clicking on Main in the VEE Program Explorer window.


HC_PrefsAutoLineRoute

When Auto Line Routing is checked, the lines between objects are automatically rerouted when an object is connected, moved, or resized. Auto-routing uses only horizontal and vertical lines, and gives the same results as Edit [image] Clean Up Lines. When auto-routing is off, lines are drawn directly from pin to pin, often diagonally.


HC_PrefsBinaryRunTime

When Binary RunTime File Format is checked, .vxe files are saved using a binary format which gives improved security and smaller file size. When this box is not checked, .vxe files are stored in ASCII format (similar to .vee files).


HC_PrefsCheckAddrs

When instrument checking is enabled, VEE checks the configured instruments during prerun to verify that they are accessible. If an address does not respond, you are given the opportunity to power-on the instrument, choose a different bus address, etc. When this box is not checked, disconnected or improperly configured instruments will probably cause a timeout error when the program is running.


HC_PrefsColors

The Appearance Property Group allows you to choose the default color for any screen element in your VEE program.


HC_PrefsDelVars

When Delete Variables at PreRun is checked, the values stored in all variables are deleted before each program runs. Therefore, Get Variable objects will error if their values have not been properly set. When this box is not checked, Get Variable objects can access old data left from the previous program run. Such old data may or may not be valid for the new program run.


HC_PrefsDisableDebug

When Disable Debug is checked, all debugging features are disabled, giving the fastest program execution speed.


HC_PrefsExecMode

The Execution Mode selection can be used to force backward compatibility for certain programs written in older versions of VEE. Execution Mode is stored with a VEE program, and can be changed in the Default Preferences dialog.

If the Execution Mode is set lower than the current version, the program cannot use newer VEE features. Using the highest possible Execution Mode is recommended, except in the rare cases when the higher mode causes program behavior to change in undesirable ways.


HC_PrefsFlowRate

Sets the speed at which the Data Flow markers move. Select a rate from 1 to 10. The default is 6 and the fastest is 10.


HC_PrefsFonts

The Fonts tab allows you to choose the default font for any screen element in your VEE program.


HC_PrefsNumberFormat

The Number tab allows you to choose the default format for displaying numbers in your VEE program.


HC_PrefsOKButton

When OK is pressed, any changes to Default Preferences become valid for the current work session only. When you exit and restart VEE, the previous Default Preferences (saved in the "veerc" file) are restored.


HC_PrefsPrintCover

When Print Cover Page is checked, a cover section is generated at the beginning of the printout. This default format choice can be overridden in the Print Program dialog.


HC_PrefsPrintDarkness

The B&W Printer Darkness setting allows you to choose a shade of gray for each screen element in your VEE program. This shade of gray is used when you print the program on a non-color printer. (The settings in the Appearance Property Group are used for a color printer.)


HC_PrefsPrintExplorer

When Print Program Explorer is checked, the printout includes the overview information contained in the Program Explorer window. This default format choice can be overridden in the Print Program dialog.


HC_PrefsPrintHeaderIdx

When Print Header and Index Page is checked, each printout page is given a page number and other header information, and an Index is generated at the end of the printout. This default format choice can be overridden in the Print Program dialog.


HC_PrefsPrintIOConfig

When Print I/O Configuration is checked, the printout includes the expanded tree view of the I/O configuration (from the Instrument Manager). This default format choice can be overridden in the Print Program dialog.


HC_PrefsPrintMag

Specifies the magnification used when printing a VEE program. Smaller numbers create a smaller image. The value you specify might be rounded by some printer drivers.


HC_PrefsResetButton

When Reset is pressed, any pending changes to Default Preferences are discarded, and the previous Default Preferences (saved in the "veerc" file) are restored.


HC_PrefsSaveButton

When Save is pressed, any changes to Default Preferences become valid for the current work session and are saved in the "veerc" file. When you exit and restart VEE, the new saved Default Preferences are used. (The exact path to the "veerc" file is system dependent.)


HC_PrefsSpacing

Specifies the number of pixels placed between objects when you perform an Edit [image] Align... operation. This Alignment Spacing value is used only when Space Equally is enabled.


HC_PrefsTrigMode

The Trig Mode selection chooses the default trigonometric units used in the program. Radians are VEE's natural (fastest) units.


HC_PrefsWebEnable

When Enable Server is checked, VEE's built-in Web server is activated. The Web server allows you to monitor a VEE program from a remote Web browser.


HC_PrefsWebLogFile

Specifies the file path to the http.log file. This file records all incoming requests processed by the Web server and can grow without bounds.


HC_PrefsWebPortNum

Specifies the port number used by VEE's Web server. This port number must be allocated in your system's services file and must not be used by any other Web server.


HC_PrefsWebRootDir

Specifies the local directory that will be accessible to the remote Web browser. VEE uses the file index.html in the Root Directory as its home page. A default home page is installed as ~installDir/www/index.html. This file can be modified and/or copied to a different Root Directory.


HC_PrefsWebTimeout

Specifies the maximum time (in seconds) that the Web server will wait for VEE to respond.


HC_PrintPrgCover

When this box is checked, a cover section is generated at the beginning of the printout.


HC_PrintPrgExplorer

When this box is checked, the printout includes the overview information contained in the Program Explorer window.


HC_PrintPrgHeaderIdx

When this box is checked, each printout page is given a page number and other header information, and an Index is generated at the end of the printout.


HC_PrintPrgIOConfig

When this box is checked, the printout includes the expanded tree view of the I/O configuration (from the Instrument Manager).


HC_PrintPrgNested

When this box is checked, the printout includes an open view of all nested UserObjects.


HC_PrintPrgObjects

When this box is checked, the printout includes a detailed view of each object in the program. All but the simplest objects are printed in open view form.


HC_ProfilerClear

The Clear button resets all Profiler data values to 0 (zero).


HC_ProfilerCommas

When this box is checked, data is written to the data file with commas as delimiters (separators) between the various Profiler data fields. Using comma delimiters makes it easier to import the data into some other applications, such as spreadsheets. When this box is not checked, the data fields are aligned using multiple spaces.


HC_ProfilerFileName

This field specifies the file name where Profiler data is saved. Click this field to bring up the Save data filename dialog box.


HC_ProfilerNumDigits

This field specifies the number of digits displayed to the right of the decimal point.


HC_ProfilerOnlyExecuted

When this box is checked, Profiler data is shown only for those UserObjects and UserFunctions that executed.


HC_ProfilerOptions

The Options button brings up the Profiler Options dialog box. These options customize the format of displayed and saved data.


HC_ProfilerOverwrite

When this box is checked, each click of the Save button overwrites the data previously saved in the Profiler data file. When this box is not checked, each Save appends to the existing data.


HC_ProfilerRefresh

Profile data is collected whenever the Profiler is running, but the data displayed in the dialog box is not updated automatically. You must click the Refresh button to cause the Profiler to display the latest profile data.


HC_ProfilerResults

When the Profiler is started, it provides comparative information about the execution time of each UserObject and UserFunction. Clicking on any column label (such as Name, or Time) displays the Profiler data sorted on that field. Clicking again reverses the sort. Double-click on any UserObject or UserFunction shown in the Name field, and its view opens in the VEE workspace.


HC_ProfilerSave

The Save button writes the Profiler data to the file name specified using the Options button.


HC_ProfilerStart

The Start Profiling button is a toggle function that starts or stops profiling.


HC_ProgramExplorer

The Program Explorer window shows you the hierarchical structure of the VEE program currently loaded. Different icons are used to represent different elements of the program, such as UserObject, Remote User Function, compiled library, global variable, etc.

If you move the pointer over a program element in the Program Explorer window and click the right-hand mouse button, a menu is presented. This menu provides useful information and operations for that element. The contents of this menu depend upon the type of element selected.


HC_SaveAsDlgColorsFonts

Save colors and fonts with program saves all the default colors and fonts in the program file that are selected in the Default Preferences dialog box. This ensures that whoever opens your program will also get all of your default colors and fonts. If this option is not selected, only the colors and fonts explicitly set in your program are saved in your program file. This allows others using your program to retain their own default colors and fonts. If an existing program is loaded, the option is set according to how the program was saved previously.


HC_SaveAsDlgDeviceConfig

Save I/O configuration with program saves the veeio I/O configuration information with the program file, and not in the veeio resource file. The configuration information is specified in the Instrument Manager. If this option is not selected, the current program's configuration information is saved in the veeio file. If an existing program is loaded, the option is set according to how the program was saved previously.


HC_StatusExecMode

This field shows the Execution Mode of the currently loaded VEE program. Execution Mode allows newer versions of VEE to run older VEE programs with complete backwards compatibility. The possible modes are VEE 3, VEE 4, etc. up through the current VEE version. Execution Mode is saved with the VEE program and can be changed in the Default Preferences dialog.


HC_StatusModified

This field indicates if the currently loaded program has any unsaved changes (modifications). When the box is "grayed out," no unsaved changes are pending.


HC_StatusMsg

The bottom line of the VEE window is a status message area. This status line shows various types of information, depending upon the current operation. For example, the program run state, error messages, pixel position of moved objects, and helpful hints.


HC_StatusProfiler

This field indicates if Profiling is currently enabled. When the box is "grayed out," profiling is stopped.


HC_StatusWebServer

This field indicates if the VEE Web Server is currently enabled. When the box is "grayed out," the Web Server is disabled. The VEE Web Server is controlled in the Default Preferences dialog.


GPIB Instrument Properties

The following properties are programmatically accessible for instruments connected via a GPIB interface.

Property Data Type Description

address | Int16 | The VEE-style I/O address for this instrument. For example: 723
enableEOI | Text | Enable EOI on last byte of write transactions. zero = enable; non-zero = disable. Default is disabled.
eolSequence | Text | The character sequence that is sent at the end of a write transaction. Default is a new-line character.
hostname | Text | Remote server's hostname or IP address (if applicable).
interfaceType | Text | Returns "GPIB" for GPIB instruments.
pnpResource | Text | The VISA-style I/O address for this instrument. For example: GPIB0::23::INSTR
readTerm | Int32 | The character that will terminate a read transaction. Default is a new-line character.
timeout | Real64 | Transaction timeout value in seconds. Default is 5 seconds.

Location

Device [image] Function & Object Browser [image] Instruments

See Also

Instrument Manager, GPIO Instrument Properties, Serial Instrument Properties, VXI Instrument Properties.


GPIO Instrument Properties

The following properties are programmatically accessible for instruments connected via a GPIO interface.

Property Data Type Description

address | Int32 | The VEE-style I/O address for this instrument. For example: 12
eolSequence | Text | The character sequence that is sent at the end of a write transaction. Default is a new-line character.
hostname | Text | Remote server's hostname or IP address (if applicable).
interfaceType | Text | Returns "GPIO" for GPIO instruments.
pnpResource | Text | Not applicable for GPIO.
readTerm | Int32 | The character that will terminate a read transaction. Default is a new-line character.
timeout | Real64 | Transaction timeout value in seconds. Default is 5 seconds.

Location

Device [image] Function & Object Browser [image] Instruments

See Also

Instrument Manager, GPIB Instrument Properties, Serial Instrument Properties, VXI Instrument Properties.


Serial Instrument Properties

The following properties are programmatically accessible for instruments connected via a serial (RS-232) interface.

Property Data Type Description

address | Int32 | The VEE-style I/O address for this instrument. For example: 9
baudRate | Int32 | Current Baud rate of the RS-232 interface. Default is 9600.
charSize | Int32 | Data bits per character frame. Can be 5 through 8. Default is 8.
eolSequence | Text | The character sequence that is sent at the end of a write transaction. Default is a new-line character.
handshake | Text | Pacing mechanism for current connection. Can be None, XonXoff, RtsCts, or DtrDsr. Default is none.
hostname | Text | Remote server's hostname or IP address (if applicable).
interfaceType | Text | Returns "Serial" for RS-232 instruments.
parity | Text | Parity bit generation/checking. Can be None, Even, Odd, Mark, or Space. Default is none.
pnpResource | Text | The VISA-style I/O address for this instrument. For example: ASRL0::INSTR
readTerm | Int32 | The character that will terminate a read transaction. Default is a new-line character.
timeout | Real64 | Transaction timeout value in seconds. Default is 5 seconds.

Location

Device [image] Function & Object Browser [image] Instruments

See Also

Instrument Manager, GPIO Instrument Properties, GPIB Instrument Properties, VXI Instrument Properties.


TCPIP Instrument Properties

The following properties are programmatically accessible for instruments connected via a TCPIP interface.

Property Data Type Description

eolSequence | Text | The character sequence that is sent at the end of a write transaction. Default is a new-line character.
hostname | Text | Remote server's hostname or IP address (if applicable).
interfaceType | Text | Returns "TCPIP" for TCPIP instruments.
readTerm | Int32 | The character that will terminate a read transaction. Default is a new-line character.
timeout | Real64 | Transaction timeout value in seconds. Default is 5 seconds.
visaAddress | Text | The VISA address of the device. For example, TCPIP::[Instrument IP Address]::inst0::INSTR

Location

Device [image] Function & Object Browser [image] Instruments

See Also

Instrument Manager, GPIO Instrument Properties, Serial Instrument Properties, VXI Instrument Properties.


USB Instrument Properties

The following properties are programmatically accessible for instruments connected via a USB interface.

Property Data Type Description

eolSequence | Text | The character sequence that is sent at the end of a write transaction. Default is a new-line character.
hostname | Text | Remote server's hostname or IP address (if applicable).
interfaceType | Text | Returns "US B" for USB instruments.
readTerm | Int32 | The character that will terminate a read transaction. Default is a new-line character.
timeout | Real64 | Transaction timeout value in seconds. Default is 5 seconds.
visaAddress | Text | The VISA address for the instrument. For example, USB0::2391::1031::123456789::0::INSTR
visaAlias | Text | The VISA alias for the instrument. The visaAddress is very long and awkward to work with, so an alias is used to make working with the instrument much easier.

Location

Device [image] Function & Object Browser [image] Instruments

See Also

Instrument Manager, GPIO Instrument Properties, Serial Instrument Properties, VXI Instrument Properties.


VXI Instrument Properties

The following properties are programmatically accessible for instruments connected via a VXI interface.

Property Data Type Description

address | Int32 | The VEE-style I/O address for this instrument. For example: 16
enableEOI | Int16 | Enable EOI on last byte of write transactions. zero = enable; non-zero = disable. Default is disabled.
eolSequence | Text | The character sequence that is sent at the end of a write transaction. Default is a new-line character.
hostname | Text | Remote server's hostname or IP address (if applicable).
interfaceType | Text | Returns "VXI" for VXI instruments.
pnpResource | Text | The VISA-style I/O address for this instrument. For example: VXI0::24::INSTR
readTerm | Int32 | The character that will terminate a read transaction. Default is a new-line character.
timeout | Real64 | Transaction timeout value in seconds. Default is 5 seconds.

Location

Device [image] Function & Object Browser [image] Instruments

See Also

Instrument Manager, GPIO Instrument Properties, Serial Instrument Properties, GPIB Instrument Properties.


22861 BRB caused by Paste 22830 BRB changing output name on UO or UF 22915 In I

KNOWN PROBLEMS

ID | Description
22861 | BRB caused by Paste
22830 | BRB when changing the output name on a UO or UF
22915 | In I/O menu, Instrument Manager, function Find Instruments always ends with BRB
22816 | 'Find Instrument' in Instrument Manager gives BRB (segmentation violation)
22746 | Add instrument with fully qualified DNS name. Remove then causes VEE to quit (no BRB)
22899 | CalendarQuery example causes kernel32 page fault error
22913 | Listview ActiveX Control causes BRB
22917 | Clone of UF causes VEE Serious Error
22784 | Too many items in .mnu file causes Object Context menu to give error after pick
22818 | Example Calendarquery.vee under ActiveXControls crashes the whole VEE task
21961 | Hanning window does not work correctly for an odd number of sample data
22121 | Support whatever version of MATLAB is installed on user system
22544 | Break or Next on other side of JCT doesn't modify flow properly
22721 | Beep objects ignores params, generates only a fixed beep
22871 | Interface event SRQ wait VEE still keeps 100% CPU power
22891 | BRB setting local to library via new property box
22898 | Exception using OpenFileDialog example with events
22902 | While modal dialog is up, can leftButtonDown & modify Formula & PropertyGrid values
22903 | Cannot select a Start, Button, or OkButton on panel, for properties, move, size...
22910 | 'Insert Template' in any objects (or Main's) Description gives BRB.
22762 | Incorrect data flow in UF, sequence out fires before subthread completes
22790 | Allow customers to use Pro to debug on test machines without costing a fortune
22896 | Enh request for UDP support in To/From Socket
22802 | Internal "Personal Product Keys" need obfuscation for training use
22804 | Double-clicking on the Workspace title bar does the wrong thing
22808 | Add to the new PropertyGrid, a combobox
22838 | Program Explorer icon on toolbar vs Properties box
22840 | Must click Workspace after formula edits
16137 | VEE 6.1 Japanese Help files are in English, not Japanese
22524 | Error codes help enhancements
22534 | Need better doc on inability to send SAFE ARRAY from VEE to ActiveX
22570 | Cannot set breakpoint when using CallServer
22638 | Installer crashes build
22673 | MATLAB Helpdesk help content not appropriate
22772 | User would like fine control of VEE graph ticmark location/spacing
22714 | Formula that turns input array to scalar will BRB during later try to index that input
22752 | To/From Socket needs timeout input pin, currently have to hardwire
22857 | VEE .Net formula fails to treat Enum as a value
22864 | Min/Max and tic labels doesn't update on Meter indicator IF Min/Max are control inputs and Min/Max values are modified via pro
22873 | VEE exits importing DLL thru .Net references COM tab
22878 | Pasting IO object referencing instrument not in config can revert config to vee.io
22893 | Upgrade the File From/To objects using System.IO.File .Path .Directory
22894 | Lots of properties are available and editable in Imported UF's via PropertyGrid from contextMenu
22904 | UnDo of ReSize not happening in Detail View
22907 | UO/UF properties don't show up in Property grid unless you explicitly right-click-select them
22908 | Notepad & Description template enhancement idea - RTF format for these
22766 | Instrument Manager does not find E5810A interface when configured in IOConfig
22773 | After change mapping of graph, Y-axis scaling can't be set correctly
22806 | Search needed in Object Browser
22807 | Inputs to User Function should be pre-defined as local variables
22827 | Tab key has incorrect behavior
22847 | CTRL-Z inserts bogus character into Widget fields


Introduction to VEE

Introduction to Agilent VEE Programming

What Is Agilent VEE?

Welcome to Agilent VEE Pro. Agilent VEE is a graphical programming environment optimized for use with electronic instruments. The simplest way to state its value is the phrase, "Better measurements faster." Software prototyping is noticeably faster with Agilent VEE than with lower-level languages, and hundreds of powerful functions are available to help you analyze your measurement data.

Agilent VEE Building Blocks

Agilent VEE programs are created by placing graphical objects on the work area and wiring them together with lines. This graphical view is your program. You do not need to perform any cryptic and error-prone steps like preprocessing, compiling, or linking. Just make a "block diagram" and press Run.

VEE uses the term "objects" for the building blocks used in your program. VEE objects perform a wide variety of tasks, from adding numbers, to making logical decisions, to reading files, to displaying microwave spectra, to controlling instruments, and more. There are two general ways to create VEE objects: from VEE's Function & Object Browser and from VEE's drop-down menus.

The Function & Object Browser organizes over 200 VEE functions by category, such as "Trig," "Matrix," and "Data Filtering." It creates a Formula object preconfigured with the function you choose. Also available in the Function & Object Browser are over 500 MATLAB functions.

An easy way to access the Function & Object Browser is to press the [image] button on the toolbar. Just click the desired Type, Category, and Function. Then press the Create Formula button to get an object which you place on the work area.

Over 100 other VEE objects are organized in five drop-down menus. Just click a main menu, follow the appropriate submenu (if any), click the desired object, and place it on the work area. Here is brief overview of the five drop-down object menus:

Flow These objects influence program flow. Some objects perform traditional execution control, such as conditional branching and looping. Others alter program and data timing with operations like delay and gate.

Device This is a grouping of miscellaneous objects. It includes useful submenus like Virtual Sources and ActiveX Controls. There are handy utility objects, like a counter, timer, and comparator. The Import Library and Sequencer objects are here. (If the object you want is not found in the first menu you check, look for it in the Device menu.)

I/O These objects interact with software and hardware outside the VEE application. This menu includes objects that communicate with instruments, files, printers, other processes, and more. The first menu pick is the powerful Instrument Manager.

Data These objects declare, generate, and access data. This menu includes graphical input objects (push buttons, knobs, sliders, etc.), constants of every data type, global variables, and handy functions like Unbuild Array, Merge Record, Concatenator, and more.

Display These objects help you view data. This menu includes graphical indicators (meters, thermometers, etc.), alphanumeric displays, waveform (oscilloscope) displays, various X-Y plots, polar spectrum displays, and more.

For an alphabetical listing of all VEE functions and objects, select the Contents of this Help file and click on the "Reference" section.

Agilent VEE Programming Basics

VEE objects, the building blocks of a program, appear as rectangular boxes in the work area. These boxes perform the program actions. The boxes are connected by lines. These lines carry program data. Data travels out from the right side of an object (the output pins) and enters the next object on the left side (the input pins). Data always flows from left to right (as viewed by any given object).

An object performs its action(s) after all of its input pins have received data. After performing its action(s), the object sends data to all of its output pins. This cycle continues through the program diagram until all objects have finished all their actions. For a more detailed description of VEE program flow, see the Understanding Propagation topic.

Program flow in VEE's data propagation model is different from program flow in textual languages like C. Traditional languages forced programmers to define execution order at too low a level. Consider the simple example of assigning values to variables and calculating a sum. The C code segment for this task is:

a = 2;
b = 3;
c = a + b;

The syntax of C requires you to decide if "a" should be assigned first or if "b" should be assigned first. However, that detail really doesn't matter. Any order is OK, provided "a" and "b" both have data before they are added together. Programmers new to VEE are sometimes distracted by a perceived "lack of control" in a data flow model. Experienced VEE programmers become more efficient because they do not need to control these details.

Because an object cannot do its job until it receives all its data, all input pins must be connected to some data source. This calls attention to another important VEE feature: data type/shape conversions are handled automatically by the input terminals. For example, if an object expects floating-point data, and it receives integer data, its input terminals automatically convert the received data to the correct type. Although VEE provides optional ways to enforce type checking, the default behavior of input terminals frees you from the details of type checking and type conversion. The same is true for data shapes. An input pin can receive an array or a scalar value, and the object automatically takes the appropriate action. For more details about VEE's automatic data conversions, see the topic Converting Data Types on Input Terminals.

Agilent VEE and Instruments

The VEE programming environment strongly supports electronic instrumentation and measurement tasks. For those early prototyping stages, VEE provides simulated signal sources and displays. You can experiment with program flow and data processing without any external hardware. For more information, see the Virtual Source and Waveform Display topics, then follow their links to other simulated devices.

When you are ready for real-world data, VEE provides an Instrument Manager and a Dynamic I/O Server to simplify the tasks of discovering, configuring, and managing external instruments. VEE supports several types of instrument drivers and lets you choose the driver that best suits your preferences and/or the characteristics of an instrument. For those times when the instruments are not available, just press one button in the Instrument Manager to take a driver "off line" and continue developing your program. For more information:

See the Instrument Manager topic.

Select "How Do I..." [image] "Control Instruments" in the Contents of this Help file.

Read the "Easy Ways to Control Instruments" chapter in the VEE User's Guide.

Read the topics about controlling instruments and transaction I/O in VEE Advanced Techniques.

Agilent VEE Programming Hints

Agilent VEE is a unique programming environment with some characteristics you may not have seen in other applications. If you are new to Agilent VEE, most of these unique characteristics will be pleasant surprises. Even so, many new VEE users find the following hints helpful:

The toolbar provides convenient buttons for program control, including:
(Run), [image] (Pause), [image] (Stop), and [image] (Step).

If you accidentally close the Main window, you can recover it with View [image] Main (or Ctrl-M).

A VEE program cannot run if any input pins are unconnected. If you do not want to connect an input pin, delete it.

If you accidentally pick the wrong object, press the Esc key to cancel. The remedy is the same for those rare times when you pick an object with no work area open to receive it. Press the Esc key to cancel the object and restore normal mouse operation.

The bottom line of the VEE window is a status bar. Develop the habit of checking that bottom status line for state information and helpful hints.

Learning More about Agilent VEE

Many resources are available to help you learn more about Agilent VEE. For example:

On-Line Tutorials
VEE provides multi-media tutorials which appeal to new VEE programmers. You can view them by selecting "Tutorials" from the Welcome Window. The Welcome Window appears (by default) when you start the VEE development environment. If VEE is already running, you can access the Welcome Window by selecting Help  [image] Welcome from VEE's main menu bar.

Example Programs
VEE provides more than 100 working programs as examples of various concepts. You can browse these examples by selecting "Example Programs" from the Welcome Window. Alternately, you can select "Guide to Agilent VEE Example Programs" in the Contents of this Help file.

On-Line Help Topics
This Help file provides many ways to locate information. The Contents tab presents an alphabetical "Reference," a "Tell Me About..." section on concepts, a "How Do I..." guide to tasks, and other useful sections. The Index tab makes it easy to search for specific topics, and a full-text search is available in the Find tab (for locating any word that didn't get its rightful place in the Index).

Printed Manuals
VEE provides two volumes of information in a paper format that travels anywhere. The VEE User's Guide presents an easy-to-understand overview of VEE's major features. Its "learn by doing" format is well suited to new VEE programmers. The VEE Advanced Techniques manual presents an in-depth view of those powerful features which appeal to seasoned VEE programmers.

Classes
Agilent Technologies conducts many customer classes, including classes about VEE. For more information, select:
Help [image] Agilent VEE on the Web [image] Education/Training


No Help Topic Available

The Help topic for this object or dialog box is not implemented yet.


Polynomial

A menu item.

Use

Use Polynomial to access the following objects which generate a Real64 polynomial result from the data and coefficient values. These objects are summarized as poly(x,vec).

poly(x,[a0, a1])

poly(x,[a0, a1, a2])

poly(x,[a0, a1, a2, a3])

poly(x,[a0, a1, ... aN])

Location

Math [image] Polynomial

See Also

Generate, and poly(x,vec).


RGB Values for Agilent VEE Colors

Use these RGB values when you're making a custom bitmap and need to match a VEE color, for example, to match a panel background color.

This list of colors and their RGB values may change in future releases of VEE

Black | r:0 | g:0 | b:0
Dark Beige | r:105 | g:95 | b:80
Darkest Gray | r:96 | g:96 | b:96
Dark Gray | r:128 | g:128 | b:128
Med Dark Gray | r:160 | g:160 | b:164
Gray | r:192 | g:192 | b:192
Med Light Gray | r:208 | g:208 | b:208
Light Gray | r:224 | g:224 | b:224
Lightest Gray | r:240 | g:240 | b:240
White | r:255 | g:255 | b:255
Darkest Red | r:121 | g:0 | b:21
Dark Red | r:128 | g:0 | b:0
Med Red | r:207 | g:14 | b:48
Warning Red | r:230 | g:30 | b:30
Red | r:255 | g:0 | b:0
Light Warning Red | r:229 | g:64 | b:93
Med Light Red | r:247 | g:102 | b:129
Light Red | r:255 | g:128 | b:128
Med Pale Red | r:253 | g:164 | b:181
Pale Red | r:255 | g:197 | b:207
Darkest Orange | r:113 | g:32 | b:0
Dark Orange | r:188 | g:55 | b:0
Med Dark Orange | r:243 | g:91 | b:27
Med Orange | r:245 | g:123 | b:73
Orange | r:255 | g:128 | b:0
Golden Orange | r:239 | g:145 | b:0
Light Orange | r:255 | g:162 | b:124
Light Golden Orange | r:246 | g:191 | b:105
Pale Orange | r:252 | g:209 | b:193
Pale Golden Orange | r:253 | g:227 | b:186
Dark Brown | r:96 | g:64 | b:64
Med Brown | r:113 | g:68 | b:0
Golden Brown | r:163 | g:105 | b:0
Dark Gold | r:149 | g:108 | b:54
Brown | r:150 | g:110 | b:75
Gold | r:176 | g:145 | b:91
Beige | r:148 | g:139 | b:123
Golden Beige | r:175 | g:160 | b:126
Light Gold | r:203 | g:182 | b:128
Light Beige | r:220 | g:211 | b:184
Darkest Yellow | r:78 | g:79 | b:0
Darkest Green Yellow | r:118 | g:121 | b:0
Dark Green Yellow | r:150 | g:150 | b:0
Med Green Yellow | r:179 | g:185 | b:0
Dark Yellow | r:192 | g:192 | b:0
Med Dark Yellow | r:213 | g:213 | b:45
Med Yellow | r:234 | g:236 | b:94
Yellow | r:255 | g:255 | b:0
Light Yellow | r:255 | g:255 | b:128
Pale Yellow | r:252 | g:254 | b:185
Dark Green | r:0 | g:96 | b:0
Forest Green | r:49 | g:101 | b:1
Med Dark Green | r:0 | g:130 | b:70
Med Green | r:67 | g:142 | b:0
Green | r:0 | g:193 | b:19
Med Yellow Green | r:64 | g:229 | b:10
Yellow Green | r:128 | g:255 | b:0
Light Yellow Green | r:163 | g:242 | b:95
Light Green | r:128 | g:255 | b:128
Pale Green | r:219 | g:255 | b:184
Darkest Teal | r:0 | g:78 | b:71
Med Dark Teal | r:0 | g:107 | b:97
Dark Teal | r:0 | g:128 | b:128
Med Teal | r:0 | g:150 | b:136
Teal | r:0 | g:160 | b:160
Med Light Teal | r:0 | g:183 | b:165
Light Teal | r:0 | g:192 | b:192
Blue Gray | r:120 | g:184 | b:210
Cyan | r:0 | g:255 | b:255
Pale Cyan | r:140 | g:244 | b:234
Dark Blue | r:0 | g:0 | b:128
Med Dark Blue | r:70 | g:0 | b:240
Blue | r:0 | g:0 | b:255
Dark Sky Blue | r:51 | g:101 | b:251
Med Light Blue | r:0 | g:128 | b:255
Lavender | r:128 | g:128 | b:255
Light Blue | r:96 | g:192 | b:255
Sky Blue | r:162 | g:193 | b:254
Pale Blue | r:193 | g:206 | b:255
Light Blue Gray | r:195 | g:211 | b:219
Darkest Purple | r:80 | g:0 | b:147
Dark Purple | r:90 | g:0 | b:170
Med Purple | r:123 | g:0 | b:228
Purple | r:128 | g:0 | b:255
Violet Purple | r:146 | g:52 | b:219
Light Violet Purple | r:183 | g:96 | b:249
Med Light Purple | r:200 | g:120 | b:253
Light Purple | r:212 | g:159 | b:255
Med Pale Purple | r:227 | g:190 | b:255
Pale Purple | r:240 | g:210 | b:255
Dark Magenta | r:128 | g:0 | b:128
Dark Pink Magenta | r:181 | g:0 | b:105
Hot Pink | r:255 | g:0 | b:128
Light Pink Magenta | r:217 | g:49 | b:146
Med Magenta | r:236 | g:24 | b:200
Magenta | r:255 | g:0 | b:255
Light Magenta | r:255 | g:128 | b:255
Pink | r:255 | g:128 | b:192
Light Pink | r:243 | g:159 | b:209
Pale Pink | r:253 | g:192 | b:229


Tab Index

Active only on Panel view, Tab Index lets you set the tab order for Objects on the Panel.

Use

Accessed through the Properties Window, the Tab Index lets you set the tab order of the Objects on the Panel view. This is very useful when operators have only a keyboard.

See Also

Panel View Navigation Techniques


General Tips

When developing your program, use a screen resolution the same as (or similar to) the destination system. The Panel View is a specific-sized window (by the number of pixels) that does not scroll. You need to make sure that the Panel View will fit on the destination system's screen.

You can specify the size of the VEE Window before you create it. When you start VEE, use the command line option -geometry, to specify the size of the Detail View, and therefore specifying the size of the Panel View when it is created. For information about using command-line options, see To Start Agilent VEE with Command-Line Options.

If there are multiple destination system types, when developing your program use a system that is the lowest common denominator so you can get a realistic feel for the worst case for resolution (text readability), execution speed, and color use.

Test your program on the destination system before finalizing the program.

There may be keyboard differences that are important when giving instructions to your user. For example, Esc may be in a different location on the keyboard.

Don't use binary data files. Save data files as ASCII.