Able OF Ontents: IMAGE Base Language
Able OF Ontents: IMAGE Base Language
TABLE OF CONTENTS
1. Getting Started
2. UNIX and Solaris
3. IMAGE Tester Environment
4. Configuring IMAGE
5. Loading and Running Test Programs
6. Data Collection
7. Debugging Test Programs
8. Production Environment
9. Production Menu Control
10. Wafer Mapping
11. GPIB Programming
12. Simulator
13. IMAGE Test Language Overview
14. Test Program Structure
15. Testing and Classifying Devices
16. Input and Output Functions
17. Multisite Testing
18. Digital Signal Processing
19. Checkers
20. Device Focussed Checkers
21. Calibration
22. Test System Alarms
23. Reserved Word List
24. Standard Test Data Format
25. STDF Utilities and Filters
26. Base IMAGE Functions
27. FlexDSP Programmer’s Reference
28. Tester API
29. Custom Directory
Index
1 GETTING STARTED
This section provides an overview of the basic procedures for using IMAGE and the test
system. It presents the major features of the Catalyst and Catalyst Tiger hardware and
IMAGE software. It describes basic procedures you must follow to use the hardware and
software and where you can go from that point.
This section includes the following:
• “Catalyst Hardware” on page 1-2
• “Catalyst Software” on page 1-3
• “Getting Started—Logging In and Using the Test System” on page 1-5
• “What to Read Next” on page 1-7
Catalyst Hardware
Catalyst test systems use a dual computer architecture. This architecture, based on Sun
Microsystems’ Sun computer, uses two separate computers with dedicated functions.
The user/network computer is dedicated to user and network functions. It provides a user-
friendly and interactive interface for fast test program development. Because it is dedicated
to user functions, it can handle CPU-intensive graphics tools required for developing test
programs and managing device data.
The test computer is dedicated to controlling the tester hardware. This means that A5xx
test systems can provide the memory and high processing speed required in testing. At the
same time, you can use the tester’s graphics tools without affecting throughput.
A Sun Microsystems workstation provides your communications link to the tester, its test
heads, and ultimately the device under test (DUT). Through it, you convey instructions to
the test system computer, which, in turn, activates the test system hardware to carry out
your instructions.
Catalyst Software
The Interactive Menu Assisted Graphics Environment (IMAGE) is based on a set of
software programs known collectively as Solaris. Solaris includes the Solaris operating
system and the OpenWindows 3.0 window system. Solaris is based on the UNIX operating
system. Solaris manages the software and hardware resources of the test system
computer.
OpenWindows 3.0 is based on the X Window System, Version 11 Release 4 (X11R4), an
industry-standard windowing system. OpenWindows allows you to divide your Sun
workstation screen into work areas (windows) for performing general purpose activities,
such as editing ASCII files, running Solaris shell commands, running and debugging C
programs, and sending and receiving mail.
Running in the OpenWindows environment, IMAGE adds additional features for device
testing. IMAGE is an integrated collection of programs that allows you to load, compile, and
run test programs written in the IMAGE Test Language (ITL), examine and analyze test
program output, gather data, modify hardware, and debug programs. IMAGE is fully
integrated with OpenWindows. Any task performed in OpenWindows can be performed in
IMAGE.
The IMAGE software system has the following basic components:
• Test system executive software that controls the following IMAGE and Solaris software:
– Solaris operating system and standard utility programs
– High-resolution graphics window system
– Customized ATE dual-computer operating environment
– Instrumentation drivers to control tester instrumentation. One version of IMAGE
controls advanced mixed-signal and Catalyst test systems
– Ethernet TCP/IP Networking Software with Network File System (NFS)
• Test program language compiler that is interactive and includes:
– Incremental compilation
– C language
– Test program organization structured around specific functions
– Device pin-oriented language oriented toward the device
• Interactive test program editor and debugger for developing test programs, including:
– Complete source level debugger
– Mouse-oriented, window-based editor
– Immediate statement execution that allows you to try out code during debugging
• Interactive digital and analog design and debug tools that include:
– Digital pattern spreadsheet-style editor which understands digital patterns
– Digital pattern debugger that provides pattern debug and edit capability from the
same window
– History RAM for storing the history of pattern execution
Invoking IMAGE
The first step in using the test system, whether you are writing test programs or testing
devices or performing system maintenance, is to invoke IMAGE:
1. Enter your username after the system login prompt.
2. Enter your password after the password prompt.
3. In response to the operating system command prompt, type image to invoke IMAGE.
(See “Solaris and the Shell” on page 2-2.)
Help
For quick reference to programming syntax, IMAGE includes an on-line help system. To
bring up the on-line help window, click SELECT on the HELP button in the station window.
IMAGE also uses the Spot Help utility, allowing you to place the pointer over a feature in an
IMAGE window and press the Help button on the keyboard.
For complete on-line information (including this manual), select USER MANUALS from the
help button menus or type imagesolutions -manuals in any station window. This brings
up the IMAGE Solutions on-line documentation. It includes the complete set of IMAGE
manuals, as well as search, hypertext links, and other features. For help in navigating
IMAGE Solutions, click the HELP link at the top of any page. For reference to Sun
information, use the AnswerBook utility. To bring up AnswerBook, type answerbook in any
station or shell window.
Catalyst and Catalyst Tiger test systems use the Solaris operating system, a version of the
UNIX operating system that includes other Sun enhancements.
Most work performed at the tester (writing, debugging, and running test programs) is done
using the IMAGE window environment. (See “IMAGE Tester Environment” on page 3-1.)
Solaris, however, is always present, and a fundamental knowledge of the operating system
is needed to do the common tasks associated with any user account.
This section includes the following:
• “Introduction to Solaris” on page 2-2
• “File and Directory Commands” on page 2-17
• “Stopping and Rebooting the Test System” on page 2-32
Introduction to Solaris
Sun UNIX on-line documentation (AnswerBook) is included with the test system. Sun
manuals are issued on CD-ROM disk to allow you to access the documentation on line. To
bring up AnswerBook, select PROGRAMS>ANSWERBOOK... from the Workspace menu or type
answerbook in any station or shell window. In CDE, you can also get help for the
environment and Sun-supplied tools by selecting PROGRAMS>HELP... from the Workspace
menu.
root
/
dir1 dir2
/home/bob/dir1 /home/bob/dir2
codedir
/home/bob/dir2/codedir
Think of the directory within a directory structure in terms of levels. A directory contained
within another directory is one level “down” from the directory where it resides. In figure 2-
1 directory dir2 is contained in or resides in directory bob, so directory dir2 is one level
below directory bob. Directory codedir resides in directory dir2, therefore, directory
codedir is one level below directory dir2 and two levels below directory bob.
Going from level to level traces a path to a directory where you want to do some work,
perhaps create a file to be stored in that directory or create another directory. The route to
a specific directory or to a file in a specific directory is called a path. A path describes the
route to follow through the levels of directories to a desired directory or file. The path
provides the information, “Begin at this directory and end at this directory.”
The path not only tells how to get somewhere in the directory structure but also locates
where in the directory structure the work is to be done.
In figure 2-2 the path to the file goodfile is:
/home/bob/dir2/codedir/abcdir/goodfile
root
/
dir1 dir2
/home/bob/dir1 /home/bob/dir2
codedir
/home/bob/dir2/codedir
myfile1 myfile2
abcdir
/home/bob/dir2/codedir/myfile1 /home/bob/dir2/codedir/abcdir
/home/bob/dir2/codedir/myfile2
goodfile
/home/bob/dir2/codedir/abcdir/goodfile
The first / stands for the root directory; the following /’s are delimiters for each succeeding
directory in the path to reach file goodfile. Because this path begins with the root directory,
it is a rooted path.
File and directory commands always use some sort of path. Depending on where you are
in the directory structure, you may need to use a rooted path to get to a directory or file, or
you may only need to use a relative path. A rooted path always begins at the root directory,
so a / always begins a rooted path. A relative path begins at the directory that you are
working in at that moment, the current working directory. In figure 2-2, if you are working
in directory dir2, the relative path to file goodfile is:
codedir/abcdir/goodfile
Getting Help
For help with Solaris commands, an on-line manual (a duplicate of the Solaris Reference
Manual) is available. To display information from the manual, type man man at a command
prompt and press Return. (You must always press the Return key after entering a
command. This lets the operating system know that you are finished typing.) The header for
the manual appears on your screen and you can page forward through the information by
pressing the space bar or backward by pressing b. To get information about a specific
command, type man followed by the command you are interested in, then press Return.
Information on that command is displayed. To exit from the on-line manual at any time, type
q.
When working in the IMAGE environment, you can get help with Solaris commands by
selecting Help from the IMAGE Workspace menu. This displays Sun’s on-line help utility.
You can also get help on line from Sun’s AnswerBook. Select PROGRAMS>ANSWERBOOK
from the Workspace menu or type answerbook to invoke this utility.
Typing help at the station window prompt or clicking on the HELP button displays the IMAGE
Help window. This window can display information for basic Solaris commands, IMAGE
commands, or IMAGE test program syntax. IMAGE also includes Spot Help, allowing you
to place the pointer over any IMAGE window feature and press the Help key. (See “Getting
Help in IMAGE” on page 3-25.)
Login Procedures
The two login procedures for working with the tester Sun terminal are:
• The standard Solaris login which logs you in to Solaris (including CDE)
• The IMAGE station window login which logs you in to a specific test station
On login, whether directly to Solaris or an IMAGE station window, you are placed by the
operating system in the home directory of your account. Your home directory is part of the
system’s directory structure and is the same directory regardless of how you log in.
If your terminal or workstation screen looks like figure 2-3, Teradyne’s IMAGE environment
is not running and you must perform a standard login to Solaris before calling the IMAGE
environment and logging in to a test station.
ariel login:
IMAGE Environment—Access
How you start IMAGE depends on where the system leaves you after you log in to Solaris.
If you have only a command prompt after a standard login to Solaris, type image at a
command prompt and press Return to enter the IMAGE environment. The operating system
starts the OpenWindows window manager, then invokes IMAGE.
If you have a graphical environment (either OpenWindows or CDE) after a standard login to
Solaris, you need a command prompt from which to start IMAGE. If there is not one already
open, invoke a Console window. (To invoke a Console window, right click on the desktop,
then choose PROGRAMS>CONSOLE... from the Workspace Menu.) At the command prompt,
type image and press Return to enter the IMAGE environment. The operating system starts
IMAGE.
A pointer and a station window containing the station window login prompt appear on your
screen. The station window is similar to figure 2-4. Use the same user account name and
password to log in to the station window.
Logging Off
When you finish your work, log off so the terminal is available for other users. If you called
the IMAGE window environment after your standard login to Solaris (that is, you did not start
IMAGE from within a Console or Shell Tool), you must exit IMAGE before logging out. To
exit the IMAGE environment, move the pointer to the gray area of the screen and hold down
the MENU button of the mouse. This displays the IMAGE Workspace menu (figure 2-5).
Choose EXIT from this menu. (See “IMAGE Workspace Menu” on page 3-5.)
If you started IMAGE from within a graphical environment (that is, you started the program
from within a Console or Shell Tool), you need to exit IMAGE before you can log out. To exit
IMAGE but not the underlying graphical environment, close all programs and tools, then
click the Exit IMAGE button on the IMAGE Control Window.
Table 2-1. Differences between OpenWindows and Common Desktop Environment (CDE)
Login method Command line login only Choice of graphical login screen
(allows command line,
OpenWindows, or CDE) or
command line only login
Sourcing of Automatic Manual or by inclusion of directive
$HOME/.login in $HOME/.dtprofile
Window X Windows style Motif style (follows CDE
management conventions, as does Microsoft
procedures Windows)
Table 2-1. Differences between OpenWindows and Common Desktop Environment (CDE)
Login Method
The Common Desktop Environment (CDE) provides a number of ways to log in to the
system. You can use the standard text-only login, or you can use the graphical login screen.
If you use the text-only login, the system works as it does without CDE installed; you can
start OpenWindows alone or you can invoke IMAGE and OpenWindows together. If you use
the graphical login screen (see figure 2-8), you can choose OpenWindows, CDE, or a one-
time use of the text-only login. Figure 2-7 describes your login choices.
CAUTION
Do not use the graphical login screen on any computer connected directly to a tester.
Enabling the graphical login screen on the user computer can cause unpredictable
results and is not supported.
CDE Installed
Login Screen
Login Screen Enabled
Disabled
If you use the graphical login screen, the IMAGE additions to the WorkSpace Menu do not
appear.
Figure 2-8. The graphical login screen provided with the Common Desktop Environment
To choose your window manager from the graphical login screen, click Options>Session,
then select the window manager you want to use for this session. If you do not select a
window manager, the login sequence uses the same one you used in your previous
session.
If you want to use the text-only login for one session, choose OPTIONS>COMMAND LINE LOGIN
from the Desktop Login screen. If you log in this way, you cannot start either window
manager or IMAGE.
See “Disabling and Enabling the Desktop Login” on page 2-10 for instructions on disabling
and enabling the graphical login screen. The IMAGE install process disables the graphical
login screen.
Starting IMAGE
How you start IMAGE depends largely on how you started your window manager.
If you use the text-only login, type image to launch OpenWindows with IMAGE together.
You can also start OpenWindows separately, then invoke IMAGE from within a shell tool.
If you use the graphical login screen, your window manager starts automatically as soon as
the system authenticates you. Therefore, OpenWindows or CDE will already be running
when you want to start IMAGE. To invoke IMAGE from within the window manager, open a
terminal window (or shell tool) and type image there. See “Sourcing of Local Configuration
Files”, “IMAGE-Specific WorkSpace Menus”, and “Displaying Alarm and Error Messages”
for more information about starting IMAGE after using the graphical login.
Changing Passwords
NOTE
Before changing your password, check with your system manager. Your system may be
networked to other systems, requiring a different command to change passwords.
To give yourself a password or to change your existing password, type passwd. The system
prints a message on your screen that a password change for your account is in progress.
If you have a current password, the system prompts you to enter it. Type in your old
password and press RETURN. If you do not have an existing password, you do not receive
the prompt for an old password.
The system then prompts you for your new password. Type in the new password, (the
system requires passwords of six or more characters) and press RETURN. The system
prompts you again for the new password. Type in your new password a second time and
press RETURN. The system checks the spelling against the first new password entry. If the
spelling of both entries matches, the system accepts your new password as the password
for your future logins.
root
/
bill
/home/bill
dir1 dir2
/home/bill/dir1 /home/bill/dir2
codedir
/home/bill/dir1/codedir
myfile1.tl myfile2.tl
/home/bill/dir1/codedir/myfile1.tl /home/bill/dir1/codedir/myfile2.tl
At that point, directory dir1 becomes his working directory. To get to directory codedir,
which is where his source code programming files are, he types cd codedir. At that point,
directory codedir becomes his working directory. He can issue commands or use an editor
and all his work will be associated with directory codedir.
Using the cd command with a directory name contained within the current working directory
only shifts one level downward at a time. To jump to a subdirectory several levels
downward, or to go upwards by several levels, you must use a relative or rooted path. In
figure 2-10, for example, to move directly from directory bill to subdirectory codedir, you
would type cd dir1/codedir.
To return to your home directory from any subdirectory, simply type cd and press Return.
Removing Directories
To delete empty directories (containing no files or other directories), you must be in the
directory that contains the directory you want to delete or use a path.
Type rmdir then the names or paths of the directories to be deleted and press Return. If
the directories are empty, you can delete one or more directories with the rmdir command.
For example, the following command deletes directories dir1, dir2, and dir3:
rmdir dir1 dir2 dir3
To delete a directory and all its contents, type rm -r and the name or path of the directory
where you want deletion to begin and press Return. Beginning with the named directory,
that directory and all its contents, including all subdirectories and files, will be deleted.
begins with a period (.) (The period is used for certain system files. So, for protection’s
sake, it cannot be matched.)
% mkdir sourcedir % ls % ls
sourcedir testpro1 testpro2 testpro3
% cd sourcedir
% mkdir testpro1 testpro2 testpro3
root root root
/ / /
sourcedir sourcedir
/home/bill/sourcedir /home/bill/sourcedir
testpro1
/home/bill/sourcedir/testpro1
testpro2
/home/bill/sourcedir/testpro2
testpro3
/home/bill/sourcedir/testpro3
For example, to list all files beginning with lower case “a” type
ls a*
The display shows only the names that match, such as: abcfile, abigfile, a1_file,
a_new_directory.
Creating Files
You have several ways of getting files into your directories. You can create your own files
using one of the available text editors (such as TextEdit, the window environment editor,
and vi, a standard Solaris editor). For information on Text-Edit see Sun’s on-line Help
Viewer.
Redirection Operator
To quickly create a small text file in your current working directory, you can use the
command cat with the redirection operator greater-than (>). Type cat > and a filename and
press Return. The cursor drops down one line on your screen and you can type in any text
you wish, pressing Return to end each line. When you finish typing in the text, press Return
and Control-D. The system prompt returns to the screen. Use the ls command to verify that
the file has been stored.
To combine text files, adding one or more files to the end of another file, type cat and the
name or names of the files you want to be appended, >>, then the name of the file to which
you want to append. For example, if you have a file called records and you want to add the
text of a file called extrarecords, type:
cat extrarecords >> records
This command appends the text of extrarecords to the text of records. For more
information on redirection operators, refer to AnswerBook.
noclobber prevents overwriting of files when using redirection operators. It does not
prevent overwriting when using commands such as cp, the copy command.
Copying Files
To make a duplicate copy of a file, type cp and the name of the file to be copied, followed
by the name of the duplicate. For example, to duplicate a file called text and name the copy
duptext, type:
cp text duptext
You now have an exact duplicate of the file text under the name duptext in your current
working directory.
To copy a file from a directory on one level to a directory on another level, use the correct
path in front of each filename.
The -i or query option for cp causes Solaris to check if the duplicate filename you have
chosen already exists. If it does, Solaris displays a message asking if you want to overwrite
the contents of the existing file. If you answer y (yes) the file is overwritten. Any other answer
aborts cp.
Deleting Files
To delete a file or a group of files in a current working directory, type rm followed by the
name of the file or the names of a group of files you wish to delete, and press RETURN.
To delete files in a directory other than the current working directory, use the appropriate
paths in front of the file names.
rm has three options: -i, -r, and -f. -i is a query option. For each file in the list, Solaris
asks whether to delete or not. Type y for yes (delete), n for no (do not delete). -r deletes a
directory and all its contents (files and subdirectories). -f forces files to be deleted without
asking questions or reporting errors.
To rename files outside the current working directory, you must use a path in front of both
the present filename and the new filename.
An option for mv is -i. This queries you if the new filename already exists.
You can also use the mv command to transfer files from a current working directory to any
directory one level down. The command mv newfile xdir moves the file newfile from the
current working directory to directory xdir as long as xdir resides in the current working
directory. A group of files can be moved in this same manner. For example:
mv file1 file2 file3 file4 xdir
To move files from a current working directory to a directory several levels down, you must
use a path in front of the directory name. Files can only be moved within the same file
system.
File Protection
See the AnswerBook documentation for information on file and directory security using the
chmod command.
Text Utilities
Printing Files
To print a file in a current working directory, type lpr and the name of the file and press
Return. For example, for a file called goodfile, type: lpr goodfile. The lpr command
sends the file to the default printer queue. Your file is printed with any other files in the
queue. To print a file in a directory other than the current working directory, you must use a
path in front of the file.
To print several files, type lpr and the names of the files you want printed and press
RETURN.
To check the contents of a printer queue, type lpq. A message appears on your screen
giving the files queued up to be printed by rank, owner, queue file number, filename, and
number of characters in the file.
To delete a file from a queue, use the lpq command to find out the ID number, then type
lprm and the file ID number for your file, and press RETURN. Your file is removed from the
queue. If you have several files in a queue, you can remove all of them by typing lprm -.
If you are using Solaris 2, the print commands are different. Use the command lp to print a
file. Use the lpstat command to get the status of the queue, and use the cancel command
to remove a file from the print queue. You can also select PROGRAMS>PRINT TOOL from the
Workspace menu to access these printer functions.
Formatting Files
The lpr (or lp) command sends the file as it is to the printer. There is no paginating or other
formatting of the contents of the file. Simple formatting can be done using the pr command
and the > redirection operator, as in:
pr myfile > myfile.pr
This formats the file myfile by pr and places the results in a file called myfile.pr. Adding
the extension .pr is a convention that tells you that the contents of a file have been
formatted by pr. Once a file is formatted, the formatted version can be sent to the printer.
The pr command formats are:
• 66 lines to a page with a two line margin at the top
• Heading of: date/time, filename, page number after top margin
• Two blank lines after heading
• Five line bottom margin
After formatting a file, you can send the formatted version to the printer using lpr, for
example, lpr myfile.pr. (If you are using Solaris 2, the command would be lp
myfile.pr.)
Locating Files
Starting from a named directory, find begins at the named directory and recursively
searches through that directory and all subdirectories downward from the named directory
to try to locate a file or group of files. If find is successful in its search, it displays the path
or paths where the search criterion found a match. A model for the find command is:
find <directory path> <search criterion> <action>
For example, in a system called temple, the path for the home directory of a user named
bill is: /user/temple/bill. (To find your user path, use the pwd command when you are
in your home directory.) Bill has over twenty subdirectories in his directory structure and
hundreds of files. He has forgotten where a file named textfile44 is and wants to use the
find command to search out, locate, and report to him textfile44’s path. He types:
find /home/temple/bill -name textfile44 -print
The path for the search begins in his home directory, /home/temple/bill. The -name
option followed by textfile44 means “match this name.” The -print option means “print
to the screen the full path or paths of the location of any match of textfile44.”
When the search is finished, the display shows:
/home/temple/bill/newdir/textdir/textfile44
This means that textfile44 resides in subdirectory textdir, one level down from
subdirectory newdir which resides in the home directory.
For more uses of find, see the AnswerBook documentation.
Comparing Files
You may want or need to compare the contents of two files. Perhaps you have edited a file
and kept a copy of the original. You would like to compare the original file against the edited
file to learn what edits you made. The diff command does this by providing you with line
numbers and markers plus displaying nonmatching lines on the screen.
For example, two files are named firstfile and secfile. The contents of firstfile is:
able
baker
charles
donald
The contents of secfile is:
able
baker
charles
douglas
Typing diff firstfile secfile causes diff to compare the files and put this message
on the screen:
4c4
<donald
---
>douglas
This needs some interpretation. 4c4 means there is a change between line 4 of the first file
(firstfile) and line 4 of the second file (secfile). <donald means the text donald is the
contents of line 4 from the first file. >douglas means the text douglas is the contents of line
4 from the second file. This allows you to quickly scan through and find the differences
between the two files. For more information on diff see the AnswerBook documentation.
Directory Abbreviations
Three short forms for directories are:
. (period) Is the current working directory.
.. (double period) Is the directory one level above the current working directory.
~ (tilde) Is the home directory.
A user named bill has the following directory path:
/home/temple/bill/dirA/dirB/dirC
His home directory is /home/temple/bill. Contained in his home directory is dirA.
Contained in dirA is subdirectory dirB. Contained in dirB is subdirectory dirC.
Bill is working in dirC, so dirC is the current working directory. Bill wants a quick check on
the contents of his home directory. He could go to his home directory and then do an ls
command, but then he would have to get back to dirC. Instead, he just types ls ~. The
contents of his home directory appear on his screen because ~ represents the full path of
his home directory.
He then wants to check the contents of dirB. To do this he must go to dirB or use a path.
However, dirB is one level above his current working directory so he just types:
ls ..
and the contents of dirB are displayed on his screen.
While doing this work, bill has remained in dirC. At this point, he would like to copy a file
named goodtext from his home directory to dirC. Rather than having to type out the full
paths for both directories, he types:
cp ~/goodtext .
The system interprets this command as “get the file goodtext from the home directory
(/home/temple/bill) and put a copy of goodtext, using the same filename, into the
current working directory (/home/temple/bill/dirA/dirB/dirC).”
Now any time you issue the command ls it will be interpreted as the alias and will execute
using the designated options.
to modify your path to include a local binary search path, to create site-specific aliases, to
modify users’ shell prompt, and so on.
Administrators should be careful to check the state of an environment variable before
setting it to avoid clobbering any user’s specific setup. (Examples of this are in the
/image/common/.login file.)
You can start a different version of IMAGE by changing one or two environment variables.
For example, to create an alias for starting the version of IMAGE you commonly use, use a
statement such as:
alias Image.5.6 'setenv IMAGEBIN /image/bin.5.6;image'
This statement creates an alias for starting IMAGE V5.6.
IMAGE also functions using the Korn shell (ksh). The implementation is similar to the way
csh is organized. In your .profile file, insert the lines:
if [-f /image/common/.profile]; then
. /image/common/.profile
fi
The /image/common/.profile file executes the site-specific /image/custom/.profile
file if it exists.
Versions of IMAGE before V6.0 have no built-in method to allow subshells to inherit aliases.
Therefore, once a window system (OpenWindows) is started from the console, the
predefined aliases in /image/[common|custom]/.login are no longer defined in most
windows. This is confusing and makes site-specific aliases difficult to set up.
IMAGE V6.0 and later includes built-in support for site-specific aliases for the csh and the
ksh shells. A predefined /image/common/.cshrc file sources a site-specific
/image/custom/.cshrc file if it exists. To use this feature, add the following line to the
beginning of your .cshrc file:
source /image/common/.cshrc
If you frequently work on testers or workstations that do not have IMAGE installed, check
for this file before sourcing it to prevent errors. You can use:
if (-e /image/common/.cshrc) then
source /image/common/.cshrc
endif
/image/common/.cshrc defines aliases for starting all supported versions of IMAGE.
export ENV
ENV=$HOME/.kshrc
Note that the execution order of .login/.cshrc is different than that of .profile/.kshrc.
When a csh login shell executes, the .cshrc file is executed first followed by .login. When
using ksh, the .profile is executed first followed by .kshrc if you have set the ENV
environment variable.
Note that the files /image/custom/.login and /image/custom/.cshrc are not included
on your IMAGE distribution media. They need not exist at all. These files can be created by
site administrators to implement site customizations and will be checked for by the existing
Teradyne startup files.
Reboot Procedure A
Use the following procedure to reboot the tester if the terminal still responds to keyboard
strokes or mouse movement:
1. Type reboot_sys or reboot_sys -fast. (The -fast parameter reboots the tester
without doing disk checks. Take the time, however, to do disk checks if you suspect file
system corruption.) You will see a series of messages that tell you that the tester is
rebooting. If you cannot type any command, or if you get the message command not
found, go to reboot procedure B.
2. When the tester reboots and the login prompt appears, log in to the tester.
Reboot Procedure B
Use the following procedure to reboot the tester if you cannot type commands or you get a
command not found message when you enter the command reboot_sys:
CAUTION
The following procedure issues an uncontrolled halt that can be dangerous to the
test system software and to any data you have on your disk. An emergency halt can
corrupt the disk, forcing you to reinstall the software. Use of this command is not
advisable under most circumstances.
1. Hold down the STOP (L1) key on the left side of the keyboard and press a. The display
reads:
Abort at <address>
2. When you see the ok prompt, type sync and press Return. (You may get the > prompt
at this point. If you do, type n to change the > to the ok prompt.) The display reads:
Panic Zero
3. This command synchronizes the file systems, dumps all pages, and performs the
reboot.
4. When the tester reboots and the login prompt appears, log in to the tester.
complete, reboots both computers, and gives you the Solaris login prompt. You can now
issue the image command to start the Solaris and get back to the IMAGE environment.
The reboot_sys command proceeds in the following order:
1. Halt the tester computer (the client).
2. Halt the user computer (the server).
3. Reboot the user computer.
4. Reboot the tester computer.
Once this process is complete, you may want to check that the tester computer has been
rebooted. To do this, log in to the user computer and use the tip hardwire command to
log in to the tester computer. (See “Connecting to the Tester CPU” on page 2-35.)
reboot_tst Command
The reboot_tst command allows you to reboot only the tester computer. The tester
computer’s bootup log is displayed as the tester reboots. If the bootup is successful, a
confirmation message is displayed on the screen. The syntax is:
reboot_tst [-q] [-o <filename>]
where:
-q Stops the bootlog from echoing on the screen.
-o Specifies the name of an output file. This file contains a copy of
the bootlog information.
You can interrupt the bootup process, by pressing the letter q on the keyboard three times
in a row.
Once the tester computer is rebooted, use the tip hardwire command to check it. (See
“Connecting to the Tester CPU” on page 2-35.)
Halting in IMAGE
Sometimes you may need to halt the tester or user computers without rebooting. For this
purpose, IMAGE includes the following commands:
halt_sys
halt_tst
The halt_sys command halts both the tester computer and the user computer. The
halt_tst command halts only the tester computer. When you issue one of these
commands, you are asked to confirm your choice:
Are you sure? (y/n)
Type y to confirm your choice and start the halt. Type n to cancel the operation.
These commands are somewhat similar to the halt command in Solaris. Like reboot_sys
and reboot_tst, there are no restrictions on the halt_sys and halt_tst command.
When you use the halt_tst command, a few lines from the tester computer are displayed
on the screen. If the halt is successful, a confirmation message is also displayed on the
screen. The syntax is:
halt_tst [-q] [-o <filename>]
where:
-q Stops the messages from echoing on the screen.
-o Specifies the name of an output file. This file contains a copy of
the messages displayed on the screen.
You can interrupt the bootup process by pressing the letter q on the keyboard three times
in a row.
Both the halt_sys and the halt_tst commands provide a controlled halt. They stop all
jobs, synchronize the system to make sure that all data writes to disk are complete, and give
you the Solaris greater-than prompt (also called the “PROM monitor” prompt). At this point,
you can reboot the user computer by entering b and pressing Return. (The benefit of using
the reboot_sys and reboot_tst commands is that the reboot is performed automatically.)
Emergency Halt
One other command available is an emergency halt (abort) command. This command
performs an uncontrolled halt.
CAUTION
Issuing an uncontrolled halt can be dangerous to the system software and to any
data you have on your disk. An emergency halt can corrupt the disk, forcing you to
reinstall the software. Use of this command is not advisable under most
circumstances.
To perform an emergency halt on a SPARC terminal, press STOP+A. This gives you the
greater-than prompt and the system prompts you with the following menu:
>Select one: b (boot) n (new command) c (continue)
To sync the system files, enter n. The system will display ok. You must then type sync.
To use tip hardwire, execute the following sequence of commands (user entries are in
bold print):
Login: <username><cr>
Password: xxxxxx<cr>
hostnamet# tip hardwire<cr>
connected
When you press Return, the response on the screen varies, depending on the state of the
tester CPU. You see one of the following displayed:
• PROM monitor prompt (>)—the tester CPU is halted and is at the PROM monitor. It has
not rebooted.
• Text about the boot process—the tester CPU is booting.
• Login prompt—the tester CPU is up and running.
In this mode of operation, you can use escape sequences listed in table 2-2. Of these
sequences, only ~# (send break) and ~. (exit from tip) are typically used.
Command Action
~! Shell
~< Receive file from remote host
~> Send file to remote host
~t Take file from remote UNIX
~p Put file to remote UNIX
~| Pipe remote file
~C Connect program to remote host
~c Change directory
~. Exit from tip
~^D Exit from tip
~^Z Suspend tip
~s Set variable
~? Get this summary
~# Send break. This command brings you back to the >
prompt and connects to the test computer. Type b at this
point to boot.
The Interactive Menu-Assisted Graphics Environment (IMAGE) is the interface between the
test system user and the test system hardware. It is an integrated collection of programs
that allows you to load and run test programs, look at program output, gather data, modify
hardware operation, and debug programs. This section describes major features of IMAGE.
This section includes the following:
• “Features of the Tester Environment” on page 3-2
• “Invoking IMAGE” on page 3-3
• “Using the IMAGE Control Window” on page 3-8
• “Using Station Windows” on page 3-12
• “Getting Help in IMAGE” on page 3-25
• “Changing IMAGE” on page 3-33
• “Changing IMAGE Display Modes” on page 3-49
• “Exiting IMAGE” on page 3-54
• “IMAGE Licensing” on page 3-56
• “Using IMAGE From Remote Terminals” on page 3-67
• “Using IMAGE With FIRMS” on page 3-76
Invoking IMAGE
Once you log in to a workstation (see “Login Procedures” on page 2-6), invoke IMAGE by
typing image from a command prompt. The syntax for this command is:
image [-production | -engineering] [-source <dir>] [-nographics]
[-nomouse] [-help]
where:
-production Starts IMAGE in production mode. (See “Starting IMAGE in
Production Mode” on page 8-5.)
-engineering Starts IMAGE in engineering mode. This mode is described in
this chapter. (This is the default.)
-source <dir> Specifies the directory from which to start IMAGE. You may need
to use this command when starting IMAGE from other than the
standard directory.
-nographics Starts IMAGE in the mode used with nongraphics terminals.
(See “Shell Station” on page 3-73.)
-nomouse Starts IMAGE in the type of production mode that does not use
a mouse. (This option requires that you also use the
-production option in the same command.)
Station
IMAGE Control Icon
window
Station
window
Console
window
When the station window first appears, the control panel is blank as shown in figure 3-1.
When you log in to the window (by entering your account name and password), the station
changes to include control panel buttons, as shown in figure 3-6 on page 3-12.
Figure 3-2 on page 3-5 shows a CDE desktop with a new station window.
Station
window
Front
Panel
Authentication Security
By default, Solaris 2 starts IMAGE or OpenWindows with authentication security (the -auth
switch) which prevents another user from logging in to the station window. To override this
do either of the following:
• On IMAGE startup, enter xhost + <hostname> (do xhost - <hostname> on exit).
• When starting IMAGE or OpenWindows, use the -noauth switch.
NOTE
The IMAGE-specific Workspace menu is available only if you start IMAGE from a text-only
login. If you start IMAGE any other way, it uses the window manager’s default Workspace
menu, which does not include the IMAGE-specific items.
Six menu items are the same as for OpenWindows. INITIALIZE, NEW STATION, and IMAGE
CONTROL are specific to IMAGE. Items on the IMAGE Workspace menu include:
PROGRAMS> Gives you a menu of tools, including TextEdit, CommandTool,
and Sun Desktop items.
NEW STATION> Creates a new IMAGE station window. (See “Opening a New
Station” on page 3-15.)
UTILITIES> Provides a menu of services helpful in daily work, including
refresh, screen locking, and saving the workspace.
PROPERTIES> Modifies OpenWindows and IMAGE defaults. See “Setting
IMAGE Properties” on page 3-34.
IMAGE CONTROL... Displays the IMAGE Control window. The IMAGE Control
window is used to configure the IMAGE simulator (see “Using
the IMAGE Control Window” on page 3-8), modify IMAGE
properties, create a new IMAGE station window, access Help,
and exit IMAGE.
INITIALIZE Initializes the test system hardware. This command scans the
tester to determine the hardware configuration so that IMAGE
can communicate with the hardware properly. After invoking
INITIALIZE, a confirmation message appears in the console
window telling you initialization is complete. See “Initialize
Command” on page 4-15.
HELP Provides help on the Sun Desktop programs and utilities.
DESKTOP INTRO Provides help to new users of the OpenWindows environment.
File Menu
READ CONFIG FROM FILE...
Displays a window that allows you to read a confsim file from
any directory. (This is the default.)
$HOME Reads a confsim file from your home directory. You can change
this accelerator to another directory using the PROPERTIES
button. See “Changing Configuration Properties” on page 4-15.
$IMAGEBIN/CUSTOM Reads a default confsim file from the directory
$IMAGEBIN/custom.
$IMAGEBIN/CUSTOM/CFG_BDS
Reads a confsim file for a config board description file from the
directory $IMAGEBIN/custom/cfg_bds.
$IMAGEBIN/CUSTOM/DIB_ADAPTORS
Reads a confsim file for a config board description file from the
directory $IMAGEBIN/custom/dib_adaptors.
WRITE CONFIG TO FILE...
Brings up a window that allows you to write the current IMAGE
configuration to any directory. For a more information on
configuring IMAGE, see “Reading and Writing Configuration
Files” on page 4-3.
INITIALIZE Initializes the test system (see “Initialize Command” on page
4-15).
IMAGE PROPERTIES Brings up the IMAGE properties window (see “Changing IMAGE”
on page 3-33).
View Menu
The VIEW menu options include the following:
SHOW BASE CONFIGURATION...
Shows a summary of the hardware in the current configuration.
(This is the default.)
SHOW DETAILED CONFIGURATION...
Shows a detailed report of the current configuration in confsim
file format.
SHOW SKELETON PINMAP
Shows a pinmap for the current configuration and station with
entries for all available channels.
SHOW CURRENT CONFIG BOARD FILE
Shows the contents of the configuration board file corresponding
to the currently mounted configuration board.
SHOW OTHER CONFIG BOARD FILE
Shows the contents of any configuration board description file
either in your home directory or in the directory
$IMAGEBIN/custom/cfg_bds.
Stations
The STATIONS menu includes the following:
NEXT STATION... Allows you to open a new station window. Station windows are
numbered 1-10 (see “Opening a New Station” on page 3-15).
Help
HELP Allows you to access the IMAGE Help window (QUICK HELP) or
IMAGE Solutions (MANUALS). (See “Getting Help in IMAGE” on
page 3-25.)
Exit IMAGE
EXIT IMAGE Exits the current IMAGE session. The OpenWindows
environment does not exit. (See “Exiting IMAGE” on page 3-54.)
Namestripe
Control Panel
Terminal pane
Each station window initially appears with the station login prompt in the terminal pane. (You
can disable this login prompt. See “Global Station Window Options” on page 3-34.) Log in
to each station separately. (See “Logging In and Out of Station Windows” on page 3-23.)
• TIGER
If a test program is loaded into the station, the icon shows the name of a test program.
(Because of limited space, only the first nine letters of a program name are displayed.)
Auxiliary station icons only include the name of any program loaded.
When stations connected to a test head are open, the icon (located in the control panel)
always lists the test head type. Any test program loaded is displayed in the namestripe of
an open window. Auxiliary stations only display loaded test programs in the namestripe.
DISPLAY> Selects a debug display for debugging a test program. This item
is grayed out if no program is loaded. See “Debug Displays” on
page 7-47.
USER> Available for user-defined commands. To change this menu,
copy $IMAGEBIN/custom/.usermenu to $HOME and edit it. See
“Defining the User Button” on page 3-45.
PROD Changes from engineering environment to production
environment. See “Switching Between Production Mode and
Engineering Mode” on page 8-5.
CHECKERS> Loads and runs programs which check test system hardware.
See “Checkers” on page 19-1.
COMM> Allows you to select the handler/prober communications
displays. See “Debugging the Handler/Prober Interface” on page
3-1 in the Handler/Prober Manual.
Station window buttons work by issuing a command line. When you click on a button, you
see the equivalent IMAGE command line displayed in the terminal pane. (The exception is
the abort command. See “Aborting a Test Program” on page 5-28.)
Terminal Pane
The terminal pane allows you to enter command lines, either IMAGE commands or Solaris
commands. Test program inputs and outputs (such as commands you input and datalog or
summary output) are displayed in this region. By default, tester commands refer to the
station at which they were typed. The terminal pane has its own pop-up menu that allows
you to control such functions as scrolling and editing.
If you issue this command with any parameters, output is returned on one line without
keywords. An example would be:
% station_info -debugmode -program
DEBUG dc_dual_site
If you issue the station_info command with no parameters, all station information is
returned. An example would be:
% station_info
Mode: ENGINEERING
Debug: DEBUG
Program: dc_dual_site
Type: Tiger
NOTE
Directory listings and other listings in the station window may appear uneven. Type stty
-tabs in the station window to correct the tab stops.
4. Change the SIZE OF COMMAND LOG option by clicking SELECT on the number and
changing it. This option determines how many bytes are saved in a scrollable station
window. The default is 50,000 bytes. The maximum size is 100,000 bytes.
5. Click SELECT APPLY to set the new defaults or click RESET to set the defaults to the
values as they were set the last time your clicked APPLY.
NOTE
When switching between scrolling and nonscrolling station windows, previously displayed
output is lost.
file or to any printer you specify and to control color printing. The display includes the
following items:
CAPTURED WINDOW Lists the type of window.
OUTPUT WINDOW IMAGE TO
Selects whether to send the window to a POSTSCRIPT PRINTER
(the default) or to a POSTSCRIPT FILE. If you select a printer, you
need to fill in the PRINTER NAME item. If you select a file, the
PRINTER NAME item changes to DIR and FILE entries. You can
specify a directory and a filename in these fields. You can also
navigate directories using the menu for the DIR item.
COLOR OUTPUT Selects color printing. OFF produces a gray scale image or file.
The default is OFF.
COMPRESSION Reduces the size of the PostScript file. This option saves disk
space but increases the time needed to print the file. The default
is OFF.
PRINTER NAME Specifies the name of the printer to print the PostScript image.
The display puts the lw entry in this field by default. If you do not
change this entry, the image is sent to the lw printer.
PRINT COMMAND (TO $DEST)
Specifies the command line of the process to use for printing. All
occurrences of the keystring $DEST in the command line are
replaced by the printer name. If left blank, the print command
defaults to
lpr -P$DEST in Solaris 1 or
lp -d$DEST in Solaris 2.
PRINT Sends the image to a printer or file. Click on this button when you
finish specifying items in the display.
CANCEL Cancels the print request. The window disappears.
Tips on Printing
Because the print option takes screen snapshots of the window, it will not print the entire
contents of a scrollable window. It only prints what you see on the screen.
Parts of a window obscured by other windows or off-screen are not printed correctly. IMAGE
detects this and warns you with a pop-up if you are printing to the default printer or with a
message in the footer of the printing pop-up if you are printing to another destination.
When using a color monitor and a gray scale printer, choose window colors carefully. Some
colors map to the same or similar gray scale value, making the printout difficult to read.
Color PostScript files are large. If you are using a color monitor but are printing to a gray
scale printer (standard level 1 PostScript), choosing the CONVERT TO GRAY SCALE option
converts the display colors to gray scale. The resulting file is about 1/3 the size of a color file.
Leave the COLOR PRINTING option set to CONVERT TO GRAY SCALE unless you are using a
color printer. At print time, IMAGE automatically detects whether the destination printer can
print color. If the printer is a gray scale printer, IMAGE converts the color image to gray scale
at the printer. This takes additional time.
If you log out with a test program loaded in the station that has unsaved changes, a warning
is displayed in the station window. You can ignore this warning by typing logout -nosave.
(See “Exiting IMAGE” on page 3-54.)
To display help information on a topic, press MENU on a help window control panel button
and select a topic from the pull-right menu. This displays the beginning of the help text for
that topic. Use the scrollbar to scroll through the text.
The header (namestripe) of the Help window displays the type of help you are using, such
as CATALYST or CATALYST TIGER. The window’s footer displays the title of the help file you
are viewing.
You can use only one of these methods at a time. If the custom.menu file exists, a
custom.buttonlist file is ignored.
The syntax of the custom.menu file is similar to that of the description files for the station
window USER buttons (see “Defining the User Button” on page 3-45) and the IMAGE
Workspace menu (see “Changing the IMAGE Workspace Menu” on page 3-44). The set of
legal keywords differs, reflecting the different purpose.
The following keywords are legal at the beginning of a line:
# This line is a comment.
NEWLINE Starts a new line of buttons.
SPACE <n> Specifies the number of screen pixels of horizontal space to put
before buttons specified after this point. For example, SPACE 2
produces a tight layout. The default spacing is 10 pixels.
GAP <n> Specifies the interline gap. This is the number of screen pixels of
vertical space to put above lines started after this point. For
example, GAP 20 gives a loose layout. The default interline gap
is 5 pixels.
MENU Begins a menu description section. The next string (usually in
double quotes) is the label for a button which invokes a menu. All
buttons specified between this line and the matching END line are
on this menu or a submenu. You can nest MENUs to any depth.
END [PIN] Indicates the end of the menu started by the last unmatched
MENU line. The optional keyword PIN, following END, makes the
menu pinnable. That is, the menu will have a pushpin on it.
"any other string" A button label. Begins a line which specifies a button or menu
item and its function.
The following button function keywords are legal on a line beginning with a button label:
SHOW_FILE The next string is the name of a help file to display. IMAGE looks
for this first in $IMAGEBIN/helpdir, then the customer help
directory $IMAGEBIN/custom_helpdir. The file name should
have a .help extension to distinguish it from other types of files
in these directories, but this is not required.
EXEC The remainder of the line (stripped of leading spaces) is
executed as a UNIX command line. Use this keyword carefully.
The command’s output goes to the associated station or terminal
window. It will not always be clear which window this is. Only run
commands which either produce no output (such as mv or lpr)
or which, like help itself, create a window for all user interaction.
Note that the custom.menu file’s syntax is line oriented. For example, PIN only has meaning
when it is the second word on a line whose first word is END. Spacing, however, is
unimportant. The amount of space before, between, or after words is ignored.
Most “words” are delimited by spaces, tabs, and newline characters. For use in specifying
button and menu labels, quoted strings are also treated as one word; the quotes are not
part of the string. Within quoted strings, spacing matters. Thus, the line
MENU " My Menu "
produces a larger-than-normal menu button, useful if you want to make all your buttons of
uniform size.
Following are the contents of the custom.menu.example file in $IMAGEBIN/helpdir:
# Example Help customer button/menu definition file.
# For illustrative purposes, the "DC Inst." menu is left unpinnable.
# In most cases all menus should be pinnable.
# This menu has three items on it; two of them have pull-right menus.
MENU "A few instruments"
MENU "AC Inst."
"Reference source" SHOW_FILE
REFsource_syntax.help
The remainder of this section discusses IMAGE support for Spot Help. This discussion does
not refer to the behavior of Spot Help in any other application.
A MORE button associated with an IMAGE window opens the IMAGE Help window with the
appropriate file displayed. This window looks much like the Help window displayed by
clicking on the station window’s HELP button. However, it has a pushpin in its header and
behaves a little differently.
Normally, you can bring up several copies of an IMAGE Help window, allowing you to look
at several files at once. Using MORE buttons, however, only brings up one window. This
window is used to display all requests from Spot Help MORE buttons associated with IMAGE
windows. This allows you use Spot Help as an alternative to IMAGE help menu buttons for
displaying help files.
-quick Brings up the IMAGE Help window. (See “Using the IMAGE Help
Window for Quick Help” on page 3-25.)
-station # Selects the station from which to bring up the IMAGE Help
window. You can omit this parameter if you use the -quick
parameter and run the command from a station window.
-whatis Brings up a window with a brief explanation of IMAGE Solutions.
-usage Displays the command syntax. For additional help on
manswitches, type imageanswers -manuals -usage.
When you start Answers in IMAGE versions before V6.4, a menu bar appears (figure 3-15)
with the following selections:
Changing IMAGE
You can change properties of both OpenWindows and IMAGE. Many of these properties
can be changed using the Properties utility. Others can be changed using certain
environment files. These changes are discussed in this section. (For more information on
the OpenWindows Properties window, see the Sun manual OpenWindows Version 3 User’s
Guide.)
The general procedure for changing a default property using the Properties window is as
follows:
1. Open the Properties window (figure 3-16) in any of the following ways:
– Select FILE>IMAGE PROPERTIES... in the IMAGE Control window.
– Select PROPERTIES>IMAGE PROPERTIES or PROPERTIES>OPENWINDOWS
PROPERTIES from the IMAGE Workspace menu.
– Type the image_props command in any station window.
2. Press MENU on the CATEGORY abbreviated menu button at the top of the window and
select a category.
3. Change the option in the window.
4. Click APPLY to set the new defaults or click RESET to set the property to its original value
(the value you set the last time you clicked APPLY).
The following sections describe changes you can make using the IMAGE Properties
window, as well as other features of IMAGE you can customize.
ENABLE FUNCTION KEYS Defines whether function keys F1 to F5 are mapped to the
IMAGE functions RUN, HALT, CONT, STEP, and NEXT. (See “Using
Function Keys” on page 7-20.) The default is TRUE. (To remap
keyboard function keys, see “Remapping Function Keys” on
page 3-47.)
MAXIMUM MENU ITEMS BEFORE SUB-MENU CREATION
Defines the number of menu items to display before creating a
submenu for any IMAGE button. The presence of the submenu
is indicated by MORE at the end of the menu. The default is 60.
Legal values are 20 to 90. Any submenu created will contain at
least 12 items. For example:
<60 menu items = one menu
61 menu items = 49 items on main menu + 12 items on submenu
This property affects the LOAD button menus, the change file (in
station debug), CHECKERS button menus, DISPLAY button menu,
and the usermenu.
ACTION ON PMC ATTACH
Controls the station window when Production Menu Control
(PMC) attaches. (See “IMAGE Properties” on page 9-4.) The
settings are
DO NOTHING TO STATION
Nothing is done to the station window (default).
ICONIFY STATION WINDOW
Causes the station window to close down to an icon.
UNICONIFY STATION WINDOW
Reverses the iconify action.
ACTION ON PMC DETACH
Controls the station window when Production Menu Control
(PMC) detaches. (See “IMAGE Properties” on page 9-4.) The
settings are
DO NOTHING TO STATION
Nothing is done to the station window (default).
ICONIFY STATION WINDOW
Causes the station window to close down to an icon.
UNICONIFY STATION WINDOW
Reverses the iconify action.
SHOW USED LICENSES Shows or hides all licenses used by the current test program.
Select TRUE to enable display of licenses. Select FALSE (default)
to disable display of licenses.
closes, but not to close the command region when you close the
source region. You can also have them close separately, have
the command region close when you close the source window,
or have them always close together.
Miscellaneous Options
The miscellaneous properties are as follows:
DEBUG DISPLAY OPTIONS
SCALE
Selects the size of debug display windows. Default size is
MEDIUM.
ERROR HANDLING
Selects the way in which debug display windows handle test
program runtime errors. DEFAULT (the default setting) handles
runtime errors in the normal way. IGNORE ignores errors. (See
“Run-Time Errors” on page 7-54.)
IMMEDIATE WINDOW OPTIONS
IMMEDIATE WINDOW FEEDBACK
Specifies the feedback given in an immediate window after an
immediate command. (See “Changing the Immediate Display
Prompt” on page 7-66.) You can change this to feedback in
comment form where the message is inserted as an IMAGE
comment (/*- imm -*/). Or you can select the message form
(--- imm ---). The default is no feedback.
CONSOLE OPTIONS TESTER OUTPUT ACTION
Specifies what the console does when a message is sent to it.
The console can open from an icon, beep, open and beep, or do
nothing. Default is OPEN.
GPIB OPTIONS ASSERT IFC DURING RESET
Specifies assertion of the IFC signal to GPIB-based handlers
and probers during a GPIB reset. FALSE asserts IFC only at
IMAGE startup. Default is TRUE. (See “Resetting the GPIB” on
page 11-13.)
CONFIG OPTIONS CONFIG DIRECTORY
Allows you to set the second item in the FILE button menu of the
IMAGE Control window. The default for this item is $HOME, but
you can use another directory to store confsim files.
HANDLER/PROBER STARTUP OPTIONS
RESET MAPPING ON STARTUP
When set to TRUE, forces IMAGE to start with all handlers and
probers disconnected. The default is FALSE, in which case
IMAGE tries to connect to whatever handlers and probers it was
connected to before exiting IMAGE.
Datalog/Summary Options
The datalog/summary properties are as follows:
DEFAULT DATALOG FORMAT
Specifies the default format for datalog output sent to the station
window or to a text file. Options are LABEL ONLY, NO LIMITS and
LABEL, LIMITS AND TESTNAME. The default is LABEL ONLY, NO
LIMITS. For more information on datalog formats, see “Output
Format” on page 6-41. (This does not change the default format
or the options available when using tl_set_datalog.)
DEFAULT DATAWIN VERSION
Specifies the version of the Datalog Output Window that IMAGE
should start. Options are XVIEW (OpenWindows-style) and
MOTIF (CDE-style). For more information on configuring the
PRINTER NAME Specifies a printer name to use. This selection is grayed out if
$GFXPRINTER is chosen.
PRINT COMMAND Specifies the command line of the process to use for printing. All
occurrences of the keystring $DEST in the command line are
replaced by the printer name. If left blank, the print command
defaults to
lpr -P$DEST in Solaris 1 or
lp -d$DEST in Solaris 2.
COMPRESSION Specifies whether to reduce the size of the PostScript file. This
option saves disk space but increases the time needed to print
the file. The default is OFF.
For more information, see “Printing Windows in IMAGE” on page 3-19.
Color Properties
The color properties are as follows:
PASS/FAIL/ERROR COLORS
Specifies the color of pass, fail, and error items.
INTERACTIVE DISPLAY COLORS
Specifies the color of panel items in IMAGE interactive debug
displays. The STORED color appears if the current state of an
item does not differ from its stored state. The RUNNING color
appears when you select an item and the display is executing the
resulting command. The MODIFIED color appears if an item is not
currently running and its state differs from its stored state.
Interactive items use the ERROR color if selecting an item causes
an error.
MODIFY... Access the IMAGE Color Manager to change colors.
Highlighted items in a debug display do not change color. They appear inverted in their
default color or in the color appropriate to their state.
Color Manager
The Color Manager window (figure 3-17) displays colors you can apply to the color
properties.
The Color Manager window has eight pages of colors, with 64 colors each, for a total of 512
selections. It also includes the following controls that allow you to move from one page to
another and to apply your color selections:
Properties button Selects which property to assign a color. Press MENU to see the
menu.
PREVIOUS PAGE Takes you back one page in the color palette. On the first page,
this item is grayed out.
PREVIOUS PAGE>ONE PAGE BACK
Takes you one page back in the color menu.
PREVIOUS PAGE>TO FIRST PAGE
Takes you back to the first page in the color menu.
NEXT PAGE Takes you forward in the color menu. On the last page, this item
is grayed out.
Table 3-1. IMAGE V6.X and OpenWindows Environment Default Files (Continued)
.image-xinitrc .xinitrc Window system init file, for advanced use only.
See “Using an IMAGE Simulator on a Sun3” on
page 3-68.
.Xdefaults .Xdefaults Window system defaults. See “Other Window
System Defaults” on page 3-43.
OpenWindows Properties
The IMAGE Workspace menu has an OpenWindows properties selection that allows you to
change some properties associated with OpenWindows. See the OpenWindows Version 3
User’s Guide for more information on these options.
If you start IMAGE without an .image-menu file in your home directory, IMAGE uses the
.image-menu file in $IMAGEBIN/custom.
You can create a copy of this file in your home directory and edit it. Copy
$IMAGEBIN/custom/.image-menu to $HOME/.image-menu and make changes. (Users of
STEPS compatibility mode must do this to add entries for STEPS station windows to the
NEW STATION menu.)
The first time you create an .image-menu file in your home directory, you must restart
IMAGE to use the new file. If you start IMAGE with an .image-menu file in your home
directory, IMAGE uses it immediately. If you then edit that file, the changes take effect right
away without the need to restart IMAGE.
For more information on the Workspace menu, see the OpenWindows Version 3 User’s
Guide.
NOTE
The IMAGE-specific Workspace menu is available only if you start IMAGE from a text-only
login. If you start IMAGE any other way, it uses the window manager’s default Workspace
menu and does not include the IMAGE-specific items.
"Calibration" MENU
"dc" calibrate -dc;
"vhfawg" calibrate -vhfawg;
"Autocal" calibrate -station 1 -autocal
"HSD50 Cal" calibrate -station 1 -hsd50
"Disable hsd50 calfile" imm "tl_h50_disable_calfile(1)"
"Enable hsd50 calfile" imm "tl_h50_disable_calfile(0)"
"Calibration" END PIN
"Datalog" MENU
"SHOW" datalog -show
"TO FILE" datalog -on -file
"TO STATION" datalog -on -statwin
"FAIL TESTS" datalog -test fail
"PASS TESTS" datalog -test pass
"ALL TESTS" datalog -test all
"LONG FORM" datalog -format fulldlgfmt
"SHORT FORM" datalog -format dlgfmt
"OFF" datalog -off
"TO WINDOW" datalog -on -station 1 -statwin -test all -format fulldlgfmt&
"Datalog" END PIN
"Debug Tools" MENU
"First_run=1" imm First_run=1
"First_run=0" imm First_run=0
"tl_init()" imm "tl_init()"
"Switchvars" MENU
"Read values" switchvar
"switchvar 1" MENU
"switchvar 1=0" switchvar 1=0
"switchvar 1=1" switchvar 1=1
"switchvar 1=2" switchvar 1=2
"switchvar 1=3" switchvar 1=3
"switchvar 1=4" switchvar 1=4
"switchvar 1=5" switchvar 1=5
"switchvars to 1" END PIN
"switchvar 2" MENU
"switchvar 2=0" switchvar 2=0
"switchvar 2=1" switchvar 2=1
"switchvar 2=2" switchvar 2=2
"switchvar 2=3" switchvar 2=3
"switchvar 2=4" switchvar 2=4
"switchvar 2=5" switchvar 2=5
"switchvars to 2" END PIN
"Switchvars" END PIN
"dsim -ignore_errors" dsim -ignore_errors
"Debug Tools" END PIN
"DSP" MENU
"Show memory usage" imm "tl_dsp_check_mem();"
"Dump the data dictionary" imm "tl_dsp_dump_dd();"
"Consistency check" imm "tl_dsp_dd_check();"
"DSP" END PIN
Note that the .usermenu file’s syntax is line oriented. For example, PIN only has meaning
when it is the second word on a line whose first word is END. Spacing, however, is
unimportant. Any space before, between, or after words is ignored.
These functions will not appear in the Function Keys display window (select
UTILITIES>FUNCTION KEYS from the IMAGE Workspace menu) but will now work for every
station window that is open.
where <depth> is 8 or 24. For example, to set the display to 24-bit-color, type the
command $IMAGEBIN/custom/fb_setup -setup -24 and press RETURN.
fb_setup displays information about the second framebuffer and issues the following
menu:
Please enter:
s - if you have a single monitor
l - if you have two monitors and this monitor is on the left
r - if you have two monitors and this monitor is on the right
s, l, or r ->
3. Select the letter that represents your configuration and press RETURN.
Because of problems in Solaris drivers, some types of display controllers must be the
primary video board. fb_setup notifies you in this case and assigns the primary and
secondary video boards according to the driver restrictions.
4. Verify that your changes have taken effect:
$IMAGEBIN/custom/fb_setup -status
5. Restart the system.
• If you use CDE, start the desktop login monitor:
/etc/init.d/dtlogin start
• If you use OpenWindows, reboot the computer to implement the changes:
boot
When the computer starts, it uses the settings you specified.
NOTE
You must include the dash (“-”) before each option even when you issue the option at a
menu prompt; for example, -v.
-24 Sets the framebuffers and saved files into 24-bit-color mode. The
command is silent except certain conditions (see the description
of the -8 option). You cannot specify -24 and -8 on the same
command line.
-v Sets verbose mode; this displays additional information when
combined with the -8 or -24 options.
-debug Displays the contents of the files written directly by the script.
Also turns on verbose mode.
-usage Prints all command line options to the screen.
fb_setup Messages
fb_setup displays two types of messages: informational messages and errors. This section
describes these messages.
Informational Messages
• DISPLAY is set to <status>, not to :0, :0.0, $host:0, or $host:0.0 as
expected. Any current frame buffer resolutions displayed will be for
$host, not for <status>, and may be incomplete. The current windows
resolution, however, will be for $disp.
This usually indicates that you are running fb_setup after telnet or rlogin to another
computer.
• You have a PGX32 board as a second video board. Because of errors in
the Solaris drivers, we will treat this board as if it is the primary
video board
This occurs on specific framebuffers and explains why the designation of “primary video
board” may be reassigned.
• DISPLAY is not set, indicating that you are running this on the
system console. The current framebuffer resolution may not be the
the same as the resolution that will be used in windows
This confirms that you are not executing the script inside a windowing environment.
Error Messages
• Only root may setup or change display modes
You are not logged in as root. Log in as root and try again.
• DISPLAY is set, indicating that you are not running this on the system
console. If you are on the console use unsetenv or unexport DISPLAY
(for csh or sh/ksh command shells) and try again
You are probably not in a command line mode login, and you are attempting to set up
or change the display mode. Drop to a command line login (see “Before You Check or
Change Your Setup”) and try again. Unset DISPLAY only if you are sure you are at a
command line login (that is, without the graphical login monitor running in the
background); otherwise this procedure may adversely affect the windowing system.
• The graphical login process, dtlogin, is running, you can not setup or
change display modes. You can stop dtlogin by entering:
/etc/init.d/dtlogin stop
When the desktop login monitor, dtlogin, is running, the procedure labeled “command
line login” is actually a simulation of a command line login but maintains dtlogin in the
background. Halt dtlogin with the /etc/init.d/dtlogin stop command and try
again.
• More than 2 framebuffers!! Exiting.
fb_setup does not support more than two framebuffers.
• IMAGEBIN needs to be set
fb_setup needs files that are in IMAGE 7.0.D3, 7.0.tiger6, or later.
• /image/bin.x.y/m64size not found, check IMAGE version
fb_setup needs files that are in IMAGE 7.0.D3, 7.0.tiger6, or later.
Exiting IMAGE
IMAGE runs within the OpenWindows and CDE windowing systems, but it is not part of
either system. Therefore, you can exit IMAGE and the windowing system entirely or only
exit from IMAGE while keeping the windowing system running.
0 Success
1 No permission to exit IMAGE session
2 User answered NO to confirmation question
3-7 are only used in noninteractive mode
3 Unsaved edits exist (test program or a combination of
test program, pattern, and VX)
4 Unsaved pattern edits
5 IMAGE is not running
6 Unsaved VX edits
7 Unknown edits
If you started IMAGE from the text-only command prompt, you can exit IMAGE without
quitting the windowing system. To do this, use the following command in the console
window:
imageexit -keep_windows
You can also exit IMAGE without exiting OpenWindows by pressing the EXIT button on the
IMAGE Control window.
To restart IMAGE while still in OpenWindows, type image. IMAGE then uses the settings in
the .image-tools file to start and configure IMAGE.
IMAGE Licensing
To use IMAGE software, you must purchase an IMAGE license. If you have purchased a
license, a valid IMAGE password is installed at your site when you install IMAGE. A
separate license is also required to use some IMAGE software options, including Advanced
Shmoo, ProGen, IMAGE ExPress, and IMAGE ExChange.
You can load IMAGE and even log in to a station window without a valid password. When
you load a test program, however, IMAGE checks the password file and validates your
password. If the password is invalid, a message saying that no licenses were available is
displayed and test program loads are disabled.
IMAGE uses the FLEX license manager (FLEXlm) from Macrovision (formerly
GLOBEtrotter Software) to handle licenses. This common license manager may already be
in use at your location. This section describes the features of FLEXlm and is intended for
system administrators and other users who have sufficient test system privileges to manage
licenses. For additional information on installing FLEXlm, see the Software Installation
Guide.
License Daemons
The Macrovision FLEXlm security system uses two daemons to administer IMAGE licenses.
The first daemon is called lmgrd. With the default Teradyne installation this daemon is
located in /etc on your security server. If you already have the FLEXlm installed on your
network, you need not install this daemon unless you install the Teradyne-specific license
daemon.
The second license daemon is specific to Teradyne and is called icdterd. It is located in
/image/common. The IMAGE install script creates a link to the appropriate executable in
/image/common called icdterd. If you upgrade this, you must also upgrade lmgrd (the
lmgrd version must be equal to or greater than the icdterd version).
License Files
FLEXlm uses an environment variable called LM_LICENSE_FILE to store the path of the
license file or files. The default path for the Teradyne license file is
/image/common/license.dat. To see the location of license.dat, use the command:
ls $LM_LICENSE_FILE
If you are already using FLEXlm, /image/common/.login appends this Teradyne license
path to the LM_LICENSE_FILE path. If the variable is not set, it is set to Teradyne’s default
path. If you need to append another path to the Teradyne default path, do this in
/image/custom/.login by duplicating the code that sets the variable in
/image/common/.login.
You can also specify the license path in a local file. This gives you greater flexibility in setting
licensing options for each user. To do this, create a file called .flexlmrc in the user’s $HOME
directory. The contents of this file have the same format (a colon-separated list of paths) as
the data in the $LM_LICENSE_FILE environment variable. Settings in .flexlmrc override
settings in the $LM_LICENSE_FILE environment variable.
Note that the license file is only read when icdterd is started. If changes are made to the
license file, the daemon must be informed to reread the license file with the lmreread
command. (See “Rereading the License File” on page 3-61.)
You can set up the FLEXlm license server to use redundant machines as license servers.
If all end user data is on a single file server, redundant servers are not needed, and
Macrovision recommends using a single server node for the FLEXlm daemons. The default
Teradyne installation for FLEXlm does not use redundant servers. If your site is already
using FLEXlm in a redundant configuration, you must give Teradyne the hostid and name
of each server for your licenses to work.
Performance-on-Demand Licensing
On Catalyst Tiger test systems, you can enable additional features or speeds temporarily
without having to purchase additional permanent licenses. Performance-on-Demand
Licensing allows you to purchase a license for a software feature or other enhancement for
a specified amount of time, in one-week increments. After the time has passed, the license
expires and you must purchase an additional license if you want to continue to use the
enhancement.
For more information on Performance-on-Demand Licensing, contact your local Teradyne
sales representative.
icdterd: UP v7.0
suntechd: UP v6.1
gibbens buzz /dev/pts/2 (v2.000) (galleon/7310 27442), start Tue 11/7 13:21
checkers qit /dev/pts/4 (v2.000) (galleon/7310 41847), start Tue 11/7 14:06
hsieh fiedlerpp /dev/pts/2 (v2.000) (galleon/7310 34006), start Tue 11/7 14:57
hahn vogon /dev/pts/10 (v2.000) (galleon/7310 11980), start Tue 11/7 14:58
chowc a570 /dev/pts/2 (v2.000) (galleon/7310 5715), start Tue 11/7 15:13
bakr avatar /dev/pts/9 (v2.000) (galleon/7310 53693), start Tue 11/7 15:22
trunk souzapp /dev/pts/2 (v2.000) (galleon/7310 13371), start Tue 11/7 15:24
joels mrburns /dev/pts/2 (v2.000) (galleon/7310 2702), start Tue 11/7 15:25
The lmstat utility replaces the image_check command used in older versions of IMAGE.
NOTE
Protect the execution of lmdown, since shutting down the servers causes loss of licenses.
When IMAGE loses its license, it waits 10 minutes before disabling test program loads.
IMAGE tries to reconnect to the icdterd every two minutes and prints a warning on the
console if it cannot connect. If the connection is established before the 10 minute timeout
limit, test program loads are not disabled.
If the server comes back up after the 10 minute time limit, you can get a new license using
the initialize command.
NOTE
Protect execution of lmremove since removing a user’s license can be disruptive.
For example, we want to remove a mixed-signal simulator license from user lyle. First, we
can check licensing status using the lmstat command for the feature
ENABLE_uWave6000_PNA to see what license lyle is using:
lyle@sunterm% lmstat -f ENABLE_uWave6000_PNA
friery holmes /dev/console (v2.000) (galleon/7310 58116), start Fri 11/10 12:10
orlep t5 /dev/pts/3 (v2.000) (galleon/7310 20544), start Fri 11/10 12:38
NOTE
If you use the -c option, lmreread (not lmgrd) reads the specified license file. lmgrd
rereads the file it read originally. Also, you cannot use lmreread to change server node
names or port numbers. Vendor daemons do not reread their option files as a result of
lmreread.
Simulator Licenses
Simulators request a specific license based on the confsim file. Licenses exist for Catalyst
and Catalyst Tiger configurations. Catalyst licenses are valid for Catalyst simulators.
Catalyst Tiger licenses are valid for Catalyst Tiger simulators.
When a simulator is initialized (either by loading a test program, by using the Configtool,
or by typing initialize), the confsim file is read and the security daemon is called. If the
exact license, based on the confsim file, is not available, the daemon looks for a higher-
level license that supports the configuration. If it finds such a license, it grants the higher-
level license.
If the confsim file is changed, you must reinitialize. (If you change files using Configtool,
reinitializing is done automatically. See “Selecting a Configuration File” on page 4-4.) If a
simulator does not get a license when IMAGE is first started, loads are disabled. The
console window displays a message saying that no license was available.
Option Licenses
A software option also calls the security daemon, but requests a license for the specific
option. If the host raymond starts IMAGE with an A565 confsim file and then brings up three
IMAGE ExPress Code Producing Displays (CPDs), the lmstat command displays an entry
for one MIXSIG_SIM license and one ENABLE.CPD license for raymond.
All licenses that a specific simulator signs out are returned when IMAGE exits.
Tester Licenses
A tester requests a tester license that matches the hostid of the user computer. The value
of that license is returned if there is a valid license. If not, test program loads are disabled.
SERVER Lines
A SERVER line has the following format:
SERVER <nodename> hostid [<port_number>]
where:
<nodename> Is the string returned by the UNIX hostname command.
hostid Is the string returned by the hostid command.
<port_number> Specifies the TCP port number to use.
You can edit the nodename and specify the optional port number. The hostid is part of the
input to the encryption algorithm and cannot be edited.
DAEMON Lines
A vendor DAEMON line has the following format:
DAEMON daemon_name <pathname> <options_path>
where:
daemon_name Is the name of the daemon used to serve some feature or
features in the file.
<pathname> Is the pathname to the executable code for this daemon.
<options_path> Is the pathname of the options file for this daemon. (See
“Additional License Options” on page 3-65.)
You can edit the pathname and the options pathname. The daemon_name is part of the input
to the encryption algorithm and cannot be edited.
FEATURE Lines
A FEATURE line has the following format:
FEATURE <name> <daemon> <version> START=<start_date> <exp_date> <#users>
<code> <hostid>
where:
<name> Is the name of the feature.
<daemon> Is the daemon name from a DAEMON line. The specified daemon
serves this feature.
<version> Is the latest (highest-numbered) version of this feature that is
supported (three decimal places).
<start_date> Is the starting date in the format:
dd-mmm-yyyy
<exp_date> Is the expiration date in the format:
dd-mmm-yyyy
For example:
31-mar-2003
If the year is set to 0, the license has no expiration date.
<#users> Is the number of licenses for this feature.
<code> Is the encryption code for this feature. Note that the start date is
encoded into the code. Thus, identical codes with different start
dates will be different.
<hostid> Is the string returned by the hostid command. Use if this feature
is to be bound to a particular host, whether its use is counted or
not. (Case insensitive).
All entries on this line are part of the input to the encryption algorithm and cannot be edited.
Node Locking
Specify node locking (that is, single node use) by using a hostid on the FEATURE lines that
represents node-locked features. If the number of users is set to 0, then unlimited use on
the specified host is allowed and no daemons are required. (The license file can contain only
FEATURE lines in this case.). The following license file would allow unlimited usage of feature
f1 on the nodes with host IDs of 12001234 and 1700ab12:
FEATURE f1 xxx1.000 1-jan-90 0 code1 "" 12001234
FEATURE f1 xxx 1.000 1-jan-90 0 code2 "" 1700ab12
NOLOG Filters out messages of the specified type from the daemon’s log
output.
Lines beginning with the pound sign (#) are ignored and can be used as comments. If the
filename in the REPORTLOG line starts with a + character, the old report log file will be opened
for appending.
The following is an example options file:
RESERVE 1 ENABLE_CPD USER pat
RESERVE 3 ENABLE_CPD USER lee
RESERVE 1 ENABLE_CPD HOST terry
EXCLUDE ENABLE_CPD USER joe
NOLOG QUEUED
This file reserves a copy of feature ENABLE_CPD for user pat, three copies for user lee, and
a copy for anyone on a computer with the hostname terry. It also causes QUEUED
messages to be omitted from the log file and does not allow user joe to use the feature
ENABLE_CPD.
If this data were in file /usr/local/icdterd.options, you would modify the license file
DAEMON line to read:
DAEMON icdterd /image/bin.rls/icdterd /usr/local/icdterd.options
NOTE
IMAGE must still run on a Sun system, but windows such as station windows and the pattern
editor can appear on any platform that supports X.
The method for running X applications remotely is described in the OpenWindows User’s
Guide. It involves three basic steps:
1. Allow remote access to your display using the xhost command.
2. Log in remotely to the machine where you want to run your application.
3. Set the environment variable DISPLAY to point to your display:
setenv DISPLAY <myhost>
Once you complete these steps, any X application started on the remote host will appear
on your display.
The /image/common/.login login initialization tries to set the DISPLAY variable
automatically when you log in remotely to another machine. When you log in remotely, you
will see a message indicating what your DISPLAY environment variable has been set to. For
example:
myhost% rlogin remotehost
Last login: Fri Sep 4 17:18:23 from myhost
Sun Microsystems Inc. Solaris 5.0 fcs June 1992
DISPLAY is myhost:0
remotehost%
Once DISPLAY is set, you should be able to start any X application on the remote host (such
as a ShellTool or a Text Editor) and have them appear on your display.
You can now load and edit test programs as with a normal IMAGE simulator. To start
additional station windows, you must invoke them by typing:
station &
in the ShellTool or Command Tool that is logged in remotely to the server. You cannot start
remote station windows from the IMAGE Workspace menu.
When you finish using the remote simulator, type imageexit in the ShellTool or Command
Tool logged in remotely to the server. You can also type imageexit in your remote station
window. You cannot exit a remote IMAGE session from the background menu. When you
type imageexit, any station windows or other IMAGE windows disappear. You can then log
out from the remote host.
NOTE
When using IMAGE simulators on a remote host, do not change any files in the
/image/tester/<servername> directory. For example, if you need to change confsim
files, edit a copy of the confsim file you want in your home directory. Do not edit the
confsim file (or other files) in /image/tester/<servername> since this may affect other
users running IMAGE on that machine.
When using IMAGE simulators on a remote host, you cannot type IMAGE commands in any
window except the station window. For example, if you bring up a ShellTool or Command
Tool from a remote host, you cannot type load testprog -station 1 in the ShellTool to
load a test program in station 1. You must type the load command in the station window.
NOTE
The image_sun3 script does not work properly if you are running IMAGE under Solaris 2.
You can, however, start OpenWindows on the Sun3 host and run IMAGE using an X-
window remote session.
First, before you can use the image_sun3 startup script, you or the system administrator
must do the following:
1. Copy the image_sun3 script from the /image/common directory on the Sun4 server to
the /image/common directory on your Sun3 machine.
2. Copy the file called .image-xinitrc.sun3 into the Sun3’s /image/custom or
/image/bin/custom or into your own directory. This file is located in
/image/bin.5.X/custom.
3. Mount the /image/bin.5.X directory from the Sun4 server on your Sun3 machine as
/image/bin.5.X. This will create a link in /image pointing to the Sun4’s
/image/bin.5.X.
station window does not exit IMAGE. You must type imageexit in the IMAGE console
window. Also note that the IMAGE console window remains even after you exit IMAGE.
To restart IMAGE at this point, type image in the console window. Or exit the window system
by selecting the EXIT option on the IMAGE Workspace menu.
or by using the -display command line switch to the station window. The remote user can
then operate the tester normally. The remote user can exit the session when finished by
typing imageexit.
WARNING
Remote tester operation is dangerous, since a remote operator directly controls
potentially lethal tester voltages and currents. Be careful when operating a tester
remotely. Notify all other tester users. If possible, have someone near the tester to
warn others while it is operated remotely. If possible, use the “attended” method of
remote operation described above instead of “unattended” operation.
For safety and security, remote use of IMAGE on testers is password protected. To use
IMAGE remotely, an account called IMAGERMT must exist on the tester. This account is not
created automatically, so, by default, remote use of IMAGE on testers is disabled. Have the
system administrator open the account and set a password. An example entry in the
password file is:
IMAGERMT:EA2q/gcTkSuPg:-2:-2:Remote tester access:
/bin/false:/bin/false
Since this account is not used for logging in to the tester, set the UID to -2 and the shell to
/bin/false. This prevents the account from being used for anything but its intended
purpose.
To operate a tester remotely do the following:
1. In a ShellTool or Command Tool, type xhost +<servername>, where <servername> is
the name of the machine you want to run IMAGE on.
2. Log in remotely to the tester by typing rlogin <servername> and enter your password
if necessary. You should see the message DISPLAY is <myhost>:0 during the remote
login initialization.
3. If necessary, set up IMAGEBIN with your usual alias, such as image.5.0.
4. Type image to start IMAGE.
When you try to start IMAGE on the tester from a remote terminal, IMAGE checks to ensure
that the tester is not already in use. If the tester is in use, an error message appears
indicating that IMAGE is already running. Otherwise, you are prompted to enter the
password for the IMAGERMT account. (To allow unconditional remote use of the tester, set
the IMAGERMT password to null. However, we strongly recommend that this password be
set. If this password is set to null, you still receive a warning message and a confirmation
request before IMAGE is started.)
If the password is correct, IMAGE starts as it would during remote operation of a simulator.
IMAGE applications in the .image-init.remote file are started, and tester operation can
proceed normally.
When you finish operating the tester remotely, type imageexit in the window in which you
started IMAGE. This makes the tester available for the next user.
WARNING
This method of operating a tester can be dangerous. It is most appropriate when the
workstation being used to replace the system computer is in the same room as the
tester, so that you can warn other people that the tester is in use.
Before you can use the remote station window feature, the system administrator must
ensure that the /image/tester/<testcomp_name> directory, where <testcomp_name> is
the name of the tester computer, is mounted on the workstation that will serve as the system
computer.
NOTE
In some older IMAGE releases, starting IMAGE using a remote station window required that
you create a .cluster_setup configuration file. Remove this file. It is no longer useful.
Shell Station
In some cases, you may need to run IMAGE from a nonwindowing environment. For
example, you may wish to run IMAGE from a VT100-style terminal or from a remote modem
connection. The “shell station” feature addresses this need. You can use this feature with
both IMAGE simulators and testers.
WARNING
Operating a tester from a remote shell station can be dangerous. If you must operate
remotely (for example, using a modem for diagnostic purposes), be sure that
someone is near the tester to warn other users that the tester is in use.
Starting IMAGE
When you log in to a workstation or a tester, the /image/common/.login initialization tries
to determine if you are using a windowing or nonwindowing environment, and sets the
IMAGE_GRAPHICS environment variable accordingly. For example, if you are logged in on a
VT100-style terminal, IMAGE_GRAPHICS is set to FALSE.
If IMAGE_GRAPHICS is set correctly, you should be able to simply type image to start IMAGE.
If necessary, you can type the command image -nographics to indicate that you are
starting in a nonwindowing environment.
NOTE
If you try to start a nonwindowing IMAGE session on a tester, you will be asked to enter the
IMAGERMT password as described in “Remote Use of a Test System” on page 3-70.
When you start a nonwindowing IMAGE session, no applications are invoked automatically
(the .image-init.remote file is not used). If the variable IMAGE_GRAPHICS is set correctly,
you should be able to type station to start a shell station. If necessary, you can type
station -nographics to ensure that a shell station is started.
Once the station login process is complete, you can load and run any test programs,
including checkers, from the shell station. Any IMAGE or Solaris commands that try to bring
up windows are ignored or generate error messages. You cannot enter debug in the shell
station; however, commands for controlling test heads and datalog are accepted.
Exiting IMAGE
To exit the shell station when you are finished, type logout. You may get a Solaris error
message after you log out from the shell station. You can ignore this message.
To exit IMAGE after using the shell station, type imageexit. (The command imageexit
-nographics still exists, but it is identical to a normal imageexit.)
NOTE
This section is written mostly for system administrators.
When many users are running IMAGE on a Sun4 server, some users may forget to exit
IMAGE before they log out. (Note that quitting all IMAGE windows does not cause IMAGE
to exit. You must use the imageexit command to exit IMAGE.) Thus, you may have several
unused copies of IMAGE running on your server.
To list all copies of IMAGE running on a server, use the imageexit -list command. For
example:
serverhost% imageexit -list
User user1 is running IMAGE on tester number 1
User user2 is running IMAGE on tester number 4
User user3 is running IMAGE on tester number 6
serverhost%
If no copies of IMAGE are running on a server, the following is displayed:
serverhost% imageexit -list
IMAGE is not running on this host.
serverhost%
Each copy of IMAGE on a server is given a virtual “tester number” which identifies it. Virtual
tester number 0 (zero) is always assigned to the local copy of IMAGE which is started on
the console. Remote sessions are assigned tester numbers based on the tty number on
which they were started, plus one. You can find out who is logged in to which tty using the
finger command:
serverhost% finger
Login Name TTY Idle When Where
NOTE
The imageexit -tester_num command can only be used by the user who started the copy
of IMAGE or by the super-user.
NOTE
Be careful when using the imageexit -tester_num command. It can cause users to lose
unsaved edits to their test programs.
4 CONFIGURING IMAGE
IMAGE supports multiple A5xx, Catalyst, and Tiger testers and testing environments. This
flexibility requires that IMAGE determine at startup on what type of tester it is running to
provide the correct software tools for that tester’s environment. On the tester this decision
is made by interrogating the hardware to determine what type of tester is present.
On a simulator workstation, determination of testing environment is made by reading a file
called a confsim file in place of interrogating the hardware. A confsim file provides detailed
information on the configuration of a given tester. Once the file is read, IMAGE behaves
identically for a test system or a simulator workstation simulating that tester.
On the tester, you may need to make hardware changes while continuing to use IMAGE for
testing. For example, you may need to remove a board for repair. At such times, you can
write a confchanges file that, in effect, tells IMAGE about hardware changes. This file
allows you to continue as if the hardware you removed is still present or as if the hardware
you added does not exist. (See “confchanges Files” on page 4-18.)
IMAGE provides commands to help you configure IMAGE for both simulator and tester
operation. They are described in this section.
This section includes the following:
• “IMAGE Control Window” on page 4-2
• “Hardware Configuration Checking” on page 4-18
$IMAGEBIN/CUSTOM/CFG_BDS
Reads a confsim file for a config board description file from the
directory $IMAGEBIN/custom/cfg_bds.
$IMAGEBIN/CUSTOM/DIB_ADAPTORS
Reads a confsim file for a config board description file from the
directory $IMAGEBIN/custom/dib_adaptors.
WRITE CONFIG TO FILE...Brings up a window that allows you to write the current IMAGE
configuration to any directory.
tcinit: Cannot change test head type with test program loaded on any station.
(Attempt to change test head 1 from type Adv_MixSig to type Catalyst)
tcinit: configuration changes ignored
Note, however, that the initialize command uses the standard search path when looking
for confsim files. If you read a confsim file outside that search path and then type
initialize, IMAGE reads the first file named confsim found in the standard path and
initializes using that configuration. A configuration change using the IMAGE Control window
is not retained by an ordinary initialization. (See “Initialize Command” on page 4-15.)
advanced mixed-signal DIB and a test program developed for the device on an advanced
mixed-signal tester.
IMAGE also includes a confsim file for every config board description file. Each confsim
file illustrates a typical (although not the only) system configuration which might use the
corresponding config board.
These confsim files are stored in $IMAGEBIN/custom/cfg_bds and $IMAGEBIN/custom/
dib_adaptors. They are also available on a pull-right menu from the FILE menu of the
IMAGE Control window.
To select a confsim file for a config board description file:
1. Select FILE>$IMAGEBIN/CUSTOM/CFG_BDS or FILE>$IMAGEBIN/CUSTOM/DIB_ADAPTORS
and pull right. This displays the lists of config board description files. If you are working
on a tester, no files are displayed.
2. Select a confsim file and release. IMAGE is initialized with the new confsim file.
As new config boards are added, new confsim files will be added to this directory.
To write a file:
1. Select FILE>WRITE CONFIG TO FILE... The Write Configuration window is displayed (figure
4-3).
2. Select a directory and enter a filename. The name must start with confsim to be read
by the configuration accelerators.
3. Click WRITE CONFIGURATION.
The tconfig -compare command exits with nonzero status if differences are found. This
can be useful in UNIX scripts.
The syntax is:
tconfig [-create [-outfile <file>] | -compare [-infile <file>]]
where:
tconfig Writes current hardware configuration as a confsim file to the
standard output.
tconfig -create Writes the current hardware configuration to the file /image/
tester/<host>/system_config.
tconfig -compare Compares the current hardware configuration to the default file
in /image/tester/<host>/system_config.
tconfig -compare -infile <file>
Compares the current hardware configuration to <file>.
For example, you load a test program that loaded without error in a previous version of
IMAGE and get a warning that a crosspoint is not present behind a particular pin. If your
confsim file did not specify the DC configuration, you must edit the file to specify explicitly
the DC configuration you wish to simulate. All confsim formats are backwards-compatible
to previous versions of IMAGE.
configuration board for each station (if any), and a list of the instrument subsystems in the
configuration. Figure 4-4 shows an example.
You can get the same listing in a station window by typing the command show_tconfig.
You can also see the test-head type of a given station window by looking at the icon, if the
window is closed, or at the icon embedded in the button region, if the window is open.
You can also display the skeleton pinmap for any station using the dump_pinmap command.
The syntax is:
dump_pinmap [-station #]
where:
station # Specifies a station. Use this parameter when outside a station
window.
2. Pull right and select STATION 1 or STATION 2. Each station will have the backplane listed
for that station (either A or B).
This displays a listing of the current configuration board description file in a scrollable
window that allows you to view the entire file (figure 4-7).
Note that only backplane A config board files are viewable. Digital config boards are all the
same and are hardwired to digital channels.
In the Extract Configuration window, type the config board file name (excluding the .cfbd
extension) and click EXTRACT. If the config board file is not found in the standard directory
($IMAGEBIN/custom/cfg_bds or $IMAGEBIN/custom/dib_adaptors), IMAGE extracts it
from the Config Board Archive (CBA) if it exists there. Extraction is from the archive /image/
CBA/cfbd_arch.tar.
To specify a config board file from the command line, from the shell prompt (possible in a
station window), type:
extract_cfbd XXxxx
XXxxx is the config file or DIB adaptor file name (excluding the .cfbd or confsim.
extension). XX is CB (for config file) or DA (for DIB adaptor file).
If the file already exists, it is renamed with a .old extension. For example, XXxxx.cfbd
becomes XXxxx.cfbd.old.
To specify multiple files, use:
extract_cfbd XXxxx1 XXxxx2 ... XXxxxN
XXxxx# represents each file.
Do this with caution because it will populate the custom/cfg_bds and dib_adaptors
directories with all the config board files in the CBA. Complete extraction takes several
minutes to complete.
The syntax for the extract_cfbd command is:
extract_cfbd [-test] [-quiet] -all
extract_cfbd [-test] [-quiet] <namelist>
extract_cfbd -ls_archname
extract_cfbd -ls_all
where:
-test Prints to the screen which action the extraction would take. No
files are extracted or renamed.
-quiet Suppresses output to the screen.
-all Extracts all *.cfbd and confsim.* files.
<namelist> Extracts each <name>.cfbd and confsim.<name> file.
-ls_archname Prints out the full pathname of the Config Board Archive.
-ls_all Prints out all possible files to extract.
NOTE
You may need to run as root when extracting files from the Config Board Archive. Also, be
sure that no test programs are running when you extract config board files.
Upon successful extraction, the file will appear under the FILE menu button in the IMAGE
Control window, in either $IMAGEBIN/custom/cfg_bds or $IMAGEBIN/custom/
dib_adaptors. Although the confsim file will not be displayed in the menu, it is also
extracted along with the config board file.
NOTE
You must create confchanges files manually. They are searched for using the same search
path as confsim files (see “Location of confsim Files” on page 4-3).
To see a confchanges file, press MENU on VIEW and select SHOW CONFCHANGES. (If you
are not working on a tester, this item is grayed out.) A window with the confchanges file
appears. (See “Overriding Hardware Configuration Checking” on page 4-19 for more
information.)
Initialize Command
The initialize command scans the tester or confsim file to determine the hardware
configuration so that IMAGE can communicate with the hardware properly. Initialization
performs the following:
• Instructs all loaded test programs to execute a power-up reset.
• Reads the confsim file for the simulator or the confchanges file for the hardware.
• Sets the tl_powerup flag to 1. This is reset to zero for each test program when that
program runs to completion the first time.
The initialize command can be important for some configurations of linear test systems
if you cycle power (that is, turn power off and on again). Testers affected are A530 and A560
testers without the following hardware:
• High Speed Digital Subsystem
• Advanced Linear Test Head
• AC Subsystem
• Synchronized Power Subsystem
Since linear testers without any of this hardware do not automatically detect power being
cycled, use the initialize command each time you cycle test system power.
Invoke initialization by selecting INITIALIZE from the IMAGE Workspace menu or by typing
initialize in a station window. Syntax for the initialize command is:
initialize [-tester <tester_name>] [-dir <path>] [-file <file>]
where:
<tester_name> Is a test system name.
<path> Is a directory name to look for the confsim or confchanges file.
<file> Is a filename to use instead of a confsim or confchanges file.
Examples of initialize commands on an IMAGE simulator workstation are as follows:
initialize
This command searches for confsim or confchanges files in the following directories
in the following order:
$HOME/confsim
/image/tester/<host>/confsim
$IMAGEBIN/custom/confsim
initialize -file fleetfoot
This command searches for confsim or confchanges files in the following directories
in the following order:
$HOME/fleetfoot
/image/tester/<host>/fleetfoot
$IMAGEBIN/custom/fleetfoot
initialize -dir /h/ferret/frisky/confsims
This command searches for confsim or confchanges files in the following directories
in the following order:
/h/ferret/frisky/confsims/confsim
/image/tester/<host>/confsim
$IMAGEBIN/custom/confsim
initialize -dir .
This command searches for confsim or confchanges files in the following directories
in the following order:
<expanded cwd>/confsim
/image/tester/<host>/confsim
$IMAGEBIN/custom/confsim
initialize -dir $HOME/confsims -file bar
This command searches for confsim or confchanges files in the following directories
in the following order:
$HOME/confsims/bar
/image/tester/<host>/bar
$IMAGEBIN/custom/bar
Note that the initialize command (without the -dir or -file options) uses the standard
search path when looking for confsim files. If you read a confsim file outside that search
path and then type initialize, IMAGE reads the first file named confsim found in the
standard path and initializes using that configuration. A configuration change using the
IMAGE Control window is not retained by an ordinary initialization.
When initialization is complete, a confirmation appears informing you of this fact:
Initialization Complete
If you attempt initialization illegally (such as trying to change test-head types with a test
program loaded), you get an error in the station window:
Initialization FAILED (see console)
Errors telling you about unrecognized or missing hardware also appear in the console
window but do not cause the initialization to fail.
confchanges Files
At times, you may need to make hardware changes, such as removing a board. Yet you still
want the remaining hardware and IMAGE to function normally. IMAGE must be able to
make allowances for missing boards and missing instruments.
Just as a confsim file allows you to use IMAGE without a test system, a confchanges file
allows you to run the tester hardware without certain boards being present. A confchanges
file has exactly the same syntax as a confsim file. Instead of listing all the hardware in the
tester, however, it lists the slot numbers and names of boards that are missing from the
tester. IMAGE reads this file and simulates the listed boards.
NOTE
IMAGE simulates the boards for configuration purposes only. The functionality of the
instruments is not simulated.
acmapchanges Files
The LFAC Dual Channel Card includes Source and Digitizer functionality on the same
board, but you may want to hide one or the other function to save mainframe card hardware
cost. IMAGE allows you to mask either the Source or the Digitizer portion of a LFAC Dual
Channel Card. To do this, place a file called acmapchanges in your home directory or in the
/image/tester/<host> directory.
Conf Function
IMAGE includes the function read_configuration_status that you can use in a test
program to read the results of a configuration check. This function returns 1 if the last
configuration check passed and 0 if it failed. It is useful for preventing execution of a test
program on a tester without all the instruments required to run the test. (See
“read_configuration_status” on page 26-55.)
when configuration conflicts exist. You can, however, use the override_config command
in the station window. The syntax is:
override_config [-station #]
Once override_config is in effect, IMAGE ignores all configuration conflicts and executes
normally.
CAUTION
IMAGE inhibits test program execution to protect tester hardware. By overriding this
feature, you risk damaging tester hardware.
When loading a test program into the simulator, IMAGE still checks for configuration
conflicts but does not inhibit you from running the test program.
See “Types of Files Used With load” on page 5-9, “Using .load Files to Load Test Programs”
on page 5-11, and “Using make When Loading a Test Program” on page 5-12 for more
information.
When a test program is loaded in a station window, the program name is displayed in the
station window namestripe and at the bottom of the station icon. You can also display what
test program is loaded into a station window using the command station_info -program.
See “Displaying Station Window Information” on page 3-14 for more information on the
station_info command.
If you select LOAD from the LOAD button menu, the Load Test Program window is displayed
(figure 5-1). This window has the following features:
DIR Specifies a directory name. You can also press MENU on the
menu button and choose a directory.
FILE Specifies a file name. You can also press MENU on the menu
button and choose a file.
OPTIONS: NEW FILE Loads the selected file as a new test program, enter debug, and
bring up the source window. If a file with the specified name and
an extension of .tl or .bin already exists, the load fails.
OPTIONS: DEBUG Loads the selected file, enter debug, and bring up the source
window.
OPTIONS: NO CD ON LOAD
Loads the test program using a rooted filename derived from the
directory and file information in the load window. IMAGE will not
change directory (cd) into the directory that the program is
located in as it does normally.
OPTIONS: AUTOCALIBRATION
Loads the selected file and turn on autocalibration.
OPTIONS: NO CAL. FILE Does not use the calibration data files for instruments which
support them. (See “Controlling Calibration at Test Program
Load” on page 5-11.)
OPTIONS: CAL. PINMAP ONLY
Calibrates only those copies used in the current pinmap. (See
“Controlling Calibration at Test Program Load” on page 5-11.)
HEAD TYPE: Loads the file into the selected test head type. The choices are
MIXSIG (mixed-signal), ADV_MIXSIG (advanced mixed-signal),
PATH_II (PATH II), and CATALYST (Catalyst and Catalyst Tiger).
This selection is only displayed when loading on an auxiliary test
station.
To load a test program using the Load Test Program window:
1. Press MENU on LOAD and select LOAD. The Load Test Program window appears.
2. Move the pointer to the window and select a directory. You can either type a directory
name or press MENU on the DIR menu button to select one.
3. Select a test program file by either entering a file name or pressing MENU on the FILE
button to select one.
4. Check any options, such as DEBUG.
5. Click LOAD TEST PROGRAM.
Note that the LOAD button and Load Test Program window lack some options of the load
command. If you need an option not on this menu, you must enter the load command with
that option in a station window. For example, defining flags for use in conditional compiling
requires the -define parameter and so cannot be loaded using the LOAD button. (You can,
however, include such commands in a .load file and use the Load window. See “Using
.load Files to Load Test Programs” on page 5-11.)
where:
<test_prog> Specifies test program <test_prog>. This name is required. It
appears in the station window namestripe when the program is
loaded. The test program name is usually specified with no
extension, but .tl and .load are legal extensions. (You must
load .make files without the .make extension.)
<modules> Specifies other modules that are part of the test program. These
files must have an extension of .tl or .c or no extension.
<libraries> Specifies user libraries (with .a extension).
<other_files> Specifies digital patterns (.pat files) and all other files with
extensions other than .tl, .c, or .a.
-define <flag>[=<val>]
-localdef <flag>[=<val>]
Defines the symbol <flag> as a compiler flag to be used with
conditional compile directives. If -localdef is specified, define
the symbol only for the preceding module.
-object <name> Looks for the binary file for the preceding source file under the
name <name> rather than using the source name to create the
binary file name.
-debug Enters debug after loading. If the program has incomplete or
missing binary files, this must be present or the load fails.
-new Creates a new test program and enters debug. If a file with the
specified name and an extension of .tl or .bin already exists,
the load fails.
-source <dir> Specifies a directory for program source files. Use this option to
specify an additional directory for source files not in the current
directory. You can use several -source parameters to specify
more than one directory. Directories are searched in the order
listed.
-switchvar_<n> # Sets a switch variable (switchvar_1 to switchvar_64) to a
value. This option allows you to affect program execution. (See
“Switch Variables” on page 7-46.)
-sites # ... Loads a multisite test program into the specified site or sites. For
example, to load a program into sites 1, 2, and 3, use:
-sites 1 2 3
By default a multisite test program is loaded into all sites
specified in the program. (See “Loading a Multisite Test
Program” on page 17-20.)
-station # Loads the program into the specified station.
-incdir <dir> Adds the directory specified in <dir> to the list of directories
searched to locate header files. You can use several -incdir
parameters to specify more than one directory. The header files
must be listed in angle brackets.
In IMAGE V6.3 and later, you can define an environment
variable named TL_INCLUDE_PATH that adds to the include file
search path and behaves exactly like the -incdir switch. (See
“Including a Search File Path” on page 14-5.)
-behavior version <ver>|compiled|latest
NOTE
Using this parameter allows you to run the test system uncalibrated. This may result in
incorrect testing of some devices.
-cal_after Calibrates after test program run. The default is to run calibration
before the test program run. (See “Controlling Calibration at Test
Program Load” on page 5-11.)
-nocalfile Does not use the calibration data files for instruments which
support them. (See “Controlling Calibration at Test Program
Load” on page 5-11.)
-frc_calfile Forces use of calibration data files even if the calibration file may
not be valid. (See “Controlling Calibration at Test Program Load”
on page 5-11.)
NOTE
This parameter allows you to run the test system uncalibrated. This may result in incorrect
testing of some devices. Production testing is disabled in this mode.
-pinmap_only Calibrates only those copies used in the current pinmap. (See
“Controlling Calibration at Test Program Load” on page 5-11.)
-tl_init_debug Inhibits all calls to tl_init() until the first call to main(). You
can then set a breaktrap in tl_init(), execute runtotrap, and
step through code you may need to debug.
-compat_mode adv_mix_mode | config_mode
Used with the Catalyst test system so that the system operates
as though it were an advanced mixed-signal system (as an
A580). The config_mode parameter (default) specifies that the
hardware behaves to its full capability in Catalyst native mode.
-debug_imagemain tba_free_on | tba_free_off
Sets the TBA timer to be free-running across job runs
(tba_free_on), allowing interjob timing measurements. By
default, the TBA timer is reset between job runs
(tba_free_off).
-halt_on_config_mismatch true | false
Tells IMAGE whether to halt or continue test program loading if
it detects a configuration mismatch. The default value is false.
This performs the same function as the IMAGE property
image.load.halt_on_config_mismatch.
-stacksize [program_stack]
Allocates [program_stack] bytes of stack space for the test
program. If you omit this option, IMAGE allocates 16MB for stack
space. You can increase this number if your test program uses
large arrays or other data structures. You can append the scaling
factors K (kilobytes) and M (megabytes) to the number.
-thread_stacksize [thread_stack]
For multithreaded test programs, allocates [thread_stack]
bytes of stack space per thread. You must specify memory in
multiples of the Solaris page size; for example, if the page size
is 512 bytes, [thread_stack] must be a multiple of 512. If you
omit this option, Solaris allocates 1MB of stack space per thread.
(If you specify less than 1MB, Solaris allocates the full
megabyte.) You can append the scaling factors K (kilobytes) and
M (megabytes) to the number.
NOTE
Using this parameter allows you to run the test system uncalibrated. This may result in
incorrect testing of some devices.
NOTE
This parameter allows you to run the test system uncalibrated. This may result in incorrect
testing of some devices. Production testing is disabled in this mode.
The load command accepts parameters in any order. To avoid ambiguity, however, the test
program name must precede any module names without an extension.
NOTE
You need not specify -textlimit when loading a large test program. The -textlimit
option is used in some older releases as an option to the load command or in a .load file
to specify the amount of space to allocate for the test program. This is no longer necessary.
For backwards compatibility the option is still accepted but is ignored.
NOTE
If you try to load a test program using load -head adv_linear on a tester without an
advanced linear test head, you get an error. If, however, this tester has an advanced mixed-
signal test head, this command will load the program without an error.
Before running a test program on the tester from an auxiliary station, you must connect it to
a test head using the testhead command:
testhead {1 | 2 | 3 | 4} [-show] [-station #]
where:
{1 | 2 | 3 | 4} Specifies the test head to connect the auxiliary station to.
-show Shows the current test-head connection.
-station # Specifies the test station to connect.
NOTE
Sun3 testers are not supported by IMAGE V5.0 and later.
NOTE
The pinmap_only mode is available only for instruments which support calibration by
instance (see table 21-1 on page 21-7).
1. See also “Using a .load File To Tailor a Test Program” on page G3-1.
for existence and read access. This allows a check at load time for files used in the test
program such as digital pattern files (.pat files).
• Parameters to the load command
• Shell-style environment variables
• Comments following a pound sign (#). Anything on a line following a pound sign is
ignored.
This window includes the item LOAD FILE SELECTS. The default (LOAD_AND_TL_FILES) is to
show all .tl and .load files when you use the LOAD button. You can change this default to
show only .load files or only .tl files.
• Customize behavior of your test programs so that new IMAGE options do not interfere
with old programs
• Copy a program or ship a program to another site and be confident that it will behave in
the same way
• Selectively turn on and off certain new behaviors in a release for a test program.
NOTE
Only selected IMAGE changes in each release are controlled by the IMAGE Behavior
Chooser. The complete list is in IMAGE Quick Help.
The IMAGE Behavior Chooser runs programs using the default value for each option for the
version the program was last compiled under, unless you specified otherwise. Therefore, a
program compiled under V5.7 uses the V5.7 default values, even if it is running under a later
version of IMAGE. A new or a recompiled program runs using the defaults for the version of
IMAGE it is running. So, for example, a test program created under V5.7 uses V5.7 defaults.
The IMAGE Behavior Chooser allows you to specify a value other than the default value for
an option. Beginning with V5.7, each release of IMAGE include options you can set. A
complete list of these options and their possible values is in IMAGE Quick Help under BASE
LANGUAGE>IMAGE BEHAVIOR CHOOSER. This selection lists the options you can customize
for this version and their default values.
latest Uses the IMAGE behavior for the latest IMAGE version. This
sets all IMAGE options to the value for the version of IMAGE you
are running.
For example, to have all options run as they would under V5.7, use:
-behavior version V5.7
To keep the options as they were for the version the test program was compiled under use:
-behavior version compiled
To use all the latest values use:
-behavior version latest
IMAGE locates the .image_behavior file, if one exists, using the above search paths and
reads the first file it encounters. For example, if a file exists in both $HOME and in /image/
custom, IMAGE reads the file in $HOME.
The precedence for IMAGE Behavior Chooser commands from highest to lowest is as
follows:
• -behavior <option>... in a .load file
• -behavior version ... in a .load file
• -behavior <option>... in a .image_behavior file
• -behavior version ... in a .image_behavior file
This means that choosing a value for a specific option behavior overrides choosing behavior
for a version. It also means that nothing in a .image_behavior file overrides behavior
specified in a .load file.
% im_behavior accept_aapu_syntax
Default Values are the defaults for version: V6.
OPTION NAME CURRENT VALUE DEFAULT VALUE OTHER VALUES
----------------------------------------------------------------------------
accept_aapu_syntax disable disable enable
im_behavior -get <option_name> displays the option name and its current value. An
example would be:
% im_behavior -get accept_aapu_syntax
accept_aapu_syntax disable
You can also use the im_behavior command to set behavior options. The command
im_behavior -set <option_name> <value_name> sets the requested option to the
requested value. To use this command, the test program must be in debug mode.
An example would be:
% im_behavior -set accept_aapu_syntax enable
% im_behavior
Default Values are the defaults for version: V6.
OPTION NAME CURRENT VALUE DEFAULT VALUE OTHER VALUES
----------------------------------------------------------------------------
accept_aapu_syntax enable disable
apu_alarm_mode normal normal guard_only
variable_labels_in_repeat enable enable disable
hsd50_ppmu_pad_disabled_sites disable disable enable
meter_default_wmd on on off
dec_overflow_is_uint enable enable disable
thads_instr_indep_disconn enable enable disable
auto_dual_sequencer_control auto auto force_dual
force_single
reuse_equiv_handles disable disable enable
Note that im_behavior -set only sets the option for this load of the test program. To set it
permanently for a test program, edit the <progname>.load file for that program. (See
“Specifying Behavior for an Option Using the load Command” on page 5-14.) To set it
permanently for all test programs, edit the hidden file named .image_behavior. (See
“Specifying Behavior Using a .image_behavior File” on page 5-14.)
directory the test program is in. If write permissions do not exist for that directory, the file is
created in the $HOME directory.
The .ibclog file contains the last date and time the file was loaded after being compiled
under a different version of IMAGE. An example would be:
load test_prog.tl
% ls *.ibclog
test_prog.ibclog
% more test_prog.ibclog
Last loaded using a different version: V5.7 on DATE: 09/16/95 TIME: 7:54:47
Each time you load the program, a new entry is created in this file if the program was
compiled under a different version of IMAGE than the last version recorded in the .ibclog
file.
NOTE
Sun3 computers are not supported by IMAGE V5.0 and later. This capability is included for
backward compatibility with IMAGE V4.4.
-reprobe Runs parts in reprobe mode indicating that they have been
previously tested. (See “Running a Test Program in Reprobe
Mode” on page 5-25.)
The run command runs the test program once.
If your pointer is anywhere in the station window, you can press the F1 function key to run
a loaded test program.
If your tester is equipped with a Start Switch, you can run a program and retest using this
switch. (See “The Start Switch” on page 9-1 in the Handler/Prober Manual.)
NOTE
To make execution of test statements repeatable, IMAGE software is run in high priority
mode under UNIX/Solaris. This technique eliminates interrupts when running a test
program. You may notice, however, that the LEDs on the back of the test computer do not
flash in sequence when you are running a test program. This does not indicate a hardware
or software problem. It is the result of the program running in high priority mode.
• Looping a test program using the loop command with the option NO MESSAGES selected
from the LOOP button menu
• The tester is connected to a handler or prober and the station window is not in debug
• The -nostats option is used with the run command
sites. Sites are not disabled if the test program mode is continue-on-error. The test program
is only stopped if there are no more active sites after an error.
In continue-on-fail mode the test program continues past any fail bins. The sequencer
stores the fail-bin value, and, when it completes, returns that value. This state is used to
guarantee full datalogs, despite failing tests. When a single site in a test program hits a
relevant run-time error, the site on which the error occurred is disabled and testing
continues on the remaining sites. Sites are not disabled if the test program mode is
continue-on-error. The test program is only stopped if there are no more active sites after
an error.
In continue-on-error mode the test program operates as in the continue-on-fail mode. Test
programs continue past relevant run-time errors and errors are printed on the screen. This
feature is useful in debugging. It allows you to force a program to continue past errors to a
later section of greater interest. (See “Controlling Run-Time Errors” on page 15-31.)
CAUTION
Before using continue-on-error mode evaluate the errors to be sure that continuing
will not harm the hardware or the device. Do not run test programs in the continue-
on-error state during production testing.
You can also change the program termination mode from a test program using the function
call tl_set_tmode_cod(). (See “tl_set_mode_cod” on page 26-369.)
the test program. Coordinates can be set by using the run command -site0 argument,
which specifies the x and y coordinates of site 0.
NOTE
CONTROL-C does not affect looping.
The action of the force_test command is the same as using the pass and fail options to
the IMAGE test statement without a test statement value. See “Test Functions” on page
14-18.
Finally, the device must be binned. This involves two stages. First, the handler must be told
to bin the part (serial/parallel communication time); then the handler must actually perform
the binning. This is counted as intertest time and the length of this phase varies depending
on the type of handler communication and the length of time the handler takes to perform
binning.
Multiplexing Tests
IMAGE can multiplex tests over more than one station. This method allows device testing
to occur on one station while the handler on another station is indexing to the next device.
The overhead involved in this process is insignificant (1–2 ms). Typically, multiplexing is
used when device test times are on the same order of magnitude as indexing times.
However, you cannot reduce handler communication time using this technique.
Datalogging Tests
The way in which you datalog test results can also affect test time. In particular, using the
Datalog Output window when datalogging large amounts of data can add to test time.
IMAGE requires extra time to send data to this display window, and the additional time can
be as much as several seconds. Outputting the data to a file or an STDF file does not cause
this problem.
The total test time (phases 2, 3, and 4) is 185 ms. The total intertest time (phases 1, 5, and
6) is 106 ms.
The first utilization period begins when IMAGE is first started, and the last one ends when
IMAGE is exited. IMAGE tries to send a message when it exits, but this cannot be
guaranteed.
NOTE
A tester utilization event always generates 0.00% when you are using the IMAGE simulator.
Figure 5-2. Tester Events Based on Test Program Load and Unload.
TIME BASED Send an event according to the period specified. If you choose
this option, two additional fields become active:
SEND TIME BASED TESTER UTIL:
Specifies events are to occur at the same time every day spaced
by time increments. Time increment can be every 15 minutes,
half hour, hour, 2 hours, 3 hours, 4 hours, 6 hours, 8 hours, 12
hours, or daily.
ALIGN EVENT TO OCCUR AT:
Specifies the time of the first event. Enter the time in normal
format:
hour[1-12]:minute [am/pm]
or in military format:
hour[0-23]:minute
Time is always converted to normal format in the text field
whenever you click on the APPLY button or press Return, Tab, or
linefeed. Formats without am or pm are taken to occur from 1:00
am to 12:00 pm. Figure 5-3 shows an example of setting the
utilization period to 8 hours aligned to occur at 9:00 am.
IMAGE IMAGE
START EXIT
7:00 AM 9:00 AM 5:00 PM 1:00 AM 9:00AM 12:00 PM
u1 u2 u3 u4 u5
Figure 5-3. Tester Events Set to Start at 9:00 AM and Occurring Every Eight Hours.
JOB AND TIME BASED Tester utilization message is sent at both the specified times and
whenever a test program is loaded or unloaded. Note that
Figure 5-4. Tester Events Set to Start on Program Load, at 9:00 AM, and Every Eight Hours.
Stack Space
Memory used by a test program is roughly divided into the following categories:
• Text—memory space which holds instructions for each program function.
• Data—memory space used by the program’s global variables
The Pre-Test bin is the time required to prepare to run the test program before the main()
function is called. Much of this time is spent resetting test system instruments before they
are used. The length of this time depends on how many different test system instruments
are used in the test program. In addition, some instruments take a long time to reset. An
example is the Precision Multimeter (PMM), which takes about 150 ms to reset.
When using the Sequencer Profiler, Non TESTF Code is the time required to execute all
code in the test program which is not in a TESTF.
When using the Custom Profiler, Unprofiled Code is the time required to execute all code
not enclosed by tl_profile_mark() and tl_profile_end().
Post-test is the time required to shut down test system instruments and clean up from the
execution of the test program.
Profile Overhead is the time required to mark each bin into the profiling data structure.
This code executes only when profiling is enabled.
The sum of execution time of these bins with test program bins approximately equals
execution time of the entire test program. This time should agree with the time reported in
the test status message (if this message is enabled).
When using profile utilities, keep in mind the extra time required for output to station
windows. Due to the A5xx dual computer architecture, sending output (from printf() and
output due to test status messages) requires that the tester computer synchronize with the
user computer. This takes at least 100 ms for the first character.
If, therefore, you are trying to optimize test time, avoid sending output through printf()
and run in production mode with test status messages off. Count the time necessary to
synchronize and send such output as test time. Due to the fact that the device test time is
itself part of the output, however, it must be calculated before the printf(). Therefore, the
time necessary to pass the output is not included in the printed device test time in the test
status message or in profiler output.
Memory Profiler
The Memory Profiler determines memory usage of the test computer and reports page
faulting during test program run and initialization. The Solaris architecture used on the test
computer allows memory pages to be swapped out to disk when physical RAM is low.
Reading and writing pages to and from disk (page faulting) is extremely slow and affects
test program repeatability and throughput.
The Memory Profiler prints the number of page faults which occurred during the test
program run after each run. Such page faults indicate that the test program is too large to
fit into physical memory at once. Recording of page fault statistics during test program run
is enabled by default.
The Memory Profiler can also print the number of page faults which occurred during test
program initialization. This type of page fault indicates that the test program is too large to
fit into physical memory along with other components of IMAGE which must execute
between test program runs. Because recording page fault statistics during test program
initialization requires test system overhead (specifically, two system calls per run), it is
disabled by default.
Page fault statistics are never printed during the first run of a test program. This is because
the program must be read from disk for the initial run, so page fault statistics at this time
would be misleading.
Page faulting problems have two common solutions. You can reduce the size of the test
program or install more memory on the test computer. To determine how much memory is
required, the Memory Profiler can display a report of memory usage on the test computer.
This report lists memory usage for various components of IMAGE, for the operating system
software, and for each test program currently loaded. It also estimates the maximum test
program size which will not cause page faulting.
NOTE
Determining exact memory allocation is not possible due to the way UNIX memory
allocation works. Memory allocation reported by the Memory Profiler (using the profile
-meminfo command) will not exactly match the memory use reported on the test program
status message line or the output from the pstat command when run on the test computer.
Profile Command
Profiling options are controlled by the profile command. The syntax of this command is
as follows:
profile [-station #] [-on | -off] [-print #] [-sequencer | -custom]
[-bytime | -byname | -byexec] [-fixed | -scaled] [-mem_info]
[-mem_check on | off | full] [-read <file>] [-writestation]
[-nostation] [-writetext [-textfile <filename>] [-notext]
[-writeinsight [-insightfile <filename>]] [-noinsight]
[-compare <filename>]] [-nocompare]
where:
-station # Specifies a test station.
-on Turns sequencer or custom profiling on. If neither sequencer
mode nor custom mode is specified, the default sequencer mode
is used. If the profiler is turned off, then turned back on, the state
of the profiling mode is the previous profiling mode.
-off Turns sequencer or custom profiling off. The profiler does
nothing. This is the default.
-print # Limits the number of bins listed in the report. Specify a positive
number to list only that number of bins. Specify 0 to list all bins.
You cannot use a negative number. When listing a limited
number of bins, the bins listed are those at the top of the list, by
whatever sorting criterion is in effect. (The default is 0, print all
bins.)
-sequencer Sets profiling mode to sequencer mode. The profiler records the
time required to execute each TESTF each time the TESTF is
called. At the end of the test program, the profiler produces a
report including the TESTF name, its datalog number, its
execution time, and the fraction of total test time the execution
time represents. (This is the default mode of the profiler.)
-custom Sets profiling mode to custom mode. The profiler records the
time required to execute each section of the code specified by
tl_profile_mark() and tl_profile_end() in the test
program. At the end of the test program, the profiler produces a
report including the name of the section specified, its profiler bin
number, its execution time, and the fraction of total test time the
execution time represents. (See “Custom Profiler Example” on
page 5-45.)
NOTE
Some IMAGE releases before V5.6 use the function tl_profile_enable() to turn on test
program profiling. This function is not used in IMAGE V5.6 and later. Remove it from any
test programs. Use of this function may interfere with some functions of the profile
command.
-bytime Sorts the report at the end of the test program by execution time,
placing the slowest bins at the beginning. You cannot use this
option with -byname or -byexec. (This is the default.)
-byname Sorts the report by name in alphabetical order. You cannot use
this option with -bytime or -byexec.
-byexec Sorts the report by execution order, placing bins executed first at
the beginning of the report. You cannot use this option with
-byname or -bytime.
-fixed Sets the output display unit for all times to be microseconds (the
base unit).
-scaled Sets the output display unit for all times to be scaled. This option
scales all times to a base unit which can be expressed as:
xxx.yyy <unit>
where there is at least one and no more than three digits before
the decimal point. Examples are:
35.62 ms
1.04 sec
876.45 usec
(This is enabled by default.)
-mem_info Displays a report of memory usage on the test computer. Not
available on the simulator. (See “Using The Memory Profiler to
Display Memory Usage” on page 5-46.)
-mem_check on Enables recording of page fault statistics during test program
run. This is enabled by default. (See “Using The Memory Profiler
to Display Page Faults” on page 5-46.)
-mem_check off Disables recording of page fault statistics during test program
run.
-mem_check full Enables recording of page fault statistics for both test program
run and test program initialization. (This is disabled by default.)
-read <file> Reads the named text file so it can be compared to another text
file. When using this option, the profiler is limited to comparing
two files. That is, no changes to the internal state of the IMAGE
NOTE
Some IMAGE software drivers also use profile -custom. This may cause the appearance
in the profile output of bins you did not create.
You can compare two files using -read and -compare. Note that you do not need a test
program loaded to compare two files. (In fact, you do not even need to have IMAGE
running.)
test% profile -off
test% delete
delete: Test program has been deleted
test% profile -read comparison -compare baseline
Name # time % time old time % change
------------------------------------------------------------------------------------
Pre-Test 33.846 msec 43.8% 25.619 msec 32.1%
Post-Test 26.462 msec 34.3% 27.078 msec -2.3%
eol 3 4.376 msec 5.7% 1.073 msec 307.8%
Profile Overhead 3.470 msec 4.5% 2.802 msec 23.8%
loop 10002 3.361 msec 4.4% 313.503 msec -98.9%
loop 10003 914.000 usec 1.2% 488.115 msec -99.8%
loop 10000 776.000 usec 1.0% 31.000 usec 2403.2%
loop 10007 669.000 usec 0.9% 2.264 sec -100.0%
loop 10001 554.000 usec 0.7% 165.963 msec -99.7%
loop 10008 543.000 usec 0.7% 1.304 sec -100.0%
loop 10006 542.000 usec 0.7% 948.425 msec -99.9%
loop 10009 542.000 usec 0.7% 1.469 sec -100.0%
loop 10004 541.000 usec 0.7% 616.329 msec -99.9%
loop 10005 541.000 usec 0.7% 862.833 msec -99.9%
Unprofiled Code 56.000 usec 0.1% 62.000 usec -9.7%
startup 1 24.000 usec 0.0% 24.000 usec 0.0%
--------------- --------------- --------
Total test time: 77.217 msec 8.489 sec -99.1%
6 DATA COLLECTION
This section describes using IMAGE to organize, collect, and analyze device test results. It
includes the following topics:
• “Organizing Test Data” on page 6-3
• “Datalog Reports” on page 6-13 including:
– “Datalog Setup Using the Data Collection Setup Display” on page 6-14
– “Using the Enhanced Functional Datalog Display” on page 6-26
– “Datalog Setup Using the datalog Command” on page 6-31
– “Creating Datastreams” on page 6-48
– “Controlling Datalog From a Test Program” on page 6-57
– “Controlling Enhanced Functional Datalog (EFD) from a Test Program” on page 6-62
– “Changing Datalog Setup Information” on page 6-66
– “Changing Datalog Output” on page 6-67
– “Retrieving Datalog Setup Information” on page 6-68
– “Controlling Datalog Sampling” on page 6-75
– “Additional Methods of Controlling Datalog From a Test Program” on page 6-75
– “Additional Methods for Retrieving Datalog Setup Information in a Test Program” on
page 6-77
– “Custom Datalog Filters” on page 6-82
– “Monitoring Disk Space During Datalog” on page 6-84
• “Summary Reports” on page 6-89
• “Device Interface Board and Probe Card Information in Datalog” on page 6-107
• “Real Time Yield Trend Monitor” on page 6-112
• “Histogram Plots” on page 6-120
The main graphical tool for organizing and collecting data in IMAGE is the Data Collection
Setup display. This display allows you to specify how to collect datalog and histogram data.
It includes the following subwindows:
• Lot Setup Manager (see page 6-5)
• Enhanced Functional Datalog display (see page 6-26)
• Datastream Setup window (see page 6-48)
Lot Identification
When testing a lot of devices, you will commonly have IMAGE record an identification
number for the lot (a lot ID) to clearly identify any datalog output, summary reports, and
STDF files produced by testing that batch of parts. Typically, when doing package testing,
each batch of parts is identified by a single number or alphanumeric string (usually called
the lot ID). In wafer-probe, however, you often have an ID for a cassette or boat of wafers
and also an ID (or wafer number) for each wafer.
1 <unset> 2 <unset>
1 1 1 2
abc <unset> abc <unset>
abc 1 abc 2
<unset> <unset> 1 <unset>
For example, in most wafer-probe applications you can set the lot ID to the ID for the entire
cassette of wafers and set the sublot ID to 1 at the beginning of the cassette. The sublot ID
then acts as the wafer number and is incremented at the end of each wafer (using the endlot
signal from the prober). For testing packaged devices, you can set the lot ID but leave the
sublot ID unset. In this case, the lot ID is incremented once the lot of packed parts is
complete.
Anytime you open the Lot Setup Manager, it displays the current information for the current
lot. If lot information changes while the Lot Setup Manager is open, however, the new
information is not shown in the display. To update the Lot Setup Manager (and all other
open data windows), use the menu item SETTINGS>REFRESH DISPLAY WITH DATA
COLLECTION SETTINGS in the Data Collection Setup display. (See “Control Panel Items” on
page 6-15.)
The Lot Setup Manager includes the following items:
LOT ID: Sets the lot ID for a new lot. The default is 1. (See “Lot
Identification” on page 6-3.)
SUBLOT ID: Sets the sublot ID for a new lot. This is concatenated with the lot
ID on the command line that this window produces. The final
form of an entire lot ID is either the lot ID itself or the lot ID
followed by a colon and the sublot ID.
ENGINEERING LOT ID:
Specifies the engineering lot ID.
DEVICE ID: Sets the starting device ID number when starting a new lot. Each
device is given a unique number. The device number is
automatically incremented each time the test program runs
(testing a new device). This entry takes positive integers only.
The default is 1.
SET ID BUTTON Sets the DEVICE ID to the number specified without starting a
new lot.
PART TYPE: Text describing the part type or product ID.
PACKAGE TYPE: Text describing the package type.
DESIGN REVISION: Text describing the device design revision.
DEVICE FAMILY ID: Specifies the product family ID.
OPERATOR: Specifies the operator name or ID. This must be a string. If you
do not specify a name, the operator name is automatically set to
the name used at login when the test program is loaded.
SUPERVISOR: Specifies the supervisor name or ID.
TEST FLOOR ID: Specifies the test floor ID.
FACILITY ID: Specifies the test facility ID.
TEST CONDITION: Specifies the test condition to switch the currently loaded test
program to. You define test conditions in the test program
header (usually near the pinmap). (See “Test Conditions” on
page 15-27.) If you enter a test condition and have not specified
this condition in your program, you get an error when you run the
program.
PROCESS ID: Specifies the fabrication process ID.
RETEST CODE: Specifies the retest code.
TEST TEMP.: Specifies the test temperature. It can be stored as degrees
Celsius, Fahrenheit, Kelvin, or any scale. It also can be
expressed in terms such as HOT, ROOM, and COLD if
preferred.
BURN IN TIME: Specifies the burn-in time in minutes.
OPERATION FREQ.: Specifies the operation frequency or step.
JOB REVISION: Specifies the test program revision number.
TEST SETUP ID: Specifies the test setup ID.
TEST SPEC. NAME: Specifies the test specification name.
TEST SPEC. VERSION: Specifies the test specification version number.
TEST FLOW ID: Specifies the test flow ID.
-lotid <XX> Specifies the lot and sublot ID number. (See “Lot Identification”
on page 6-3.) Lot ID can be any series of alphanumeric
characters that identifies the lot. The default is 1. Multiple words
must be enclosed in double quotes ("). You can also write the lot
ID as
<lot_id:sublot_id>
-parttype <XX> Text describing the part type or product ID.
-testcond <XX> Specifies a test condition for the currently loaded test program.
You define test conditions in the test program header (usually
near the pinmap). (See “Test Conditions” on page 15-27.) If you
enter a test condition and have not specified this condition in
your program, you get an error when you run the program.
-operator <XX> Specifies the operator name. This must be a string. If you do not
specify a name, the operator name is automatically set to the
name used at login when the test program is loaded.
-retestcode <XX> Specifies the retest code.
-supervisor <XX> Specifies the supervisor name or ID.
-jobrev <XX> Specifies the test program revision number.
-processid <XX> Specifies the fabrication process ID.
-dsgnrev <XX> Specifies the device design revision.
-famlyid <XX> Specifies the product family ID.
-facilid <XX> Specifies the test facility ID.
-floorid <XX> Specifies the test floor ID.
-operfrq <XX> Specifies the operation frequency or step.
-specnam <XX> Specifies the test specification name.
-specver <XX> Specifies the test specification version number.
-flowid <XX> Specifies the test flow ID.
-setupid <XX> Specifies the test setup ID.
-noconfirm Each time you issue the startlot command, you are asked if
you want to start a new lot. If you answer yes, a new lot is started.
-noconfirm bypasses this confirmation.
-fullstats Provides mean, standard deviation, (one, three, and six) sigma
values, Cp, and Cpk. See “Summary Statistics” on page 6-105.
-usrtext <XX> Specifies the contents of the USER_TXT field of the Master
Information Record (MIR). Text should be enclosed in quotes.
NOTE
If the sublot ID is previously set, issuing the lot <lot_id> command will not reset the
sublot ID. The sublot ID will retain its previous value. To reset the sublot ID, use the
command
lot <lot_id>:
The colon, without any following arguments, resets the sublot ID field.
When you issue a startlot command and close the current lot, you get a summary report
for that lot as if you had typed summary -final. (See “Automatic Summary Reports Using
the setauto Command” on page 6-96.) You can override this default by using the SUMMARY?
option in the Lot Setup Manager or the -nosummary option to the startlot command.
Datalog Reports
Datalogging allows you to monitor the results of each execution of all tests in a test program,
or tests you select, and produces a list of the values returned by those tests. In addition to
the test value, a datalog report contains other information about the execution of a test, such
as the test limits and whether tests failed or alarmed. Figure 6-2 shows a sample datalog
report.
Control Panel
Histogram
items
Datalog
output
items
Datalog
criteria Datalog
items format
items
Datalog
options
items
Message Area
You can also bring up the window by typing the command dacldisp in a station window. If
for some reason the display does not come up (for example, you did not load a test
program), a message appears in the station window.
You can close the Data Collection Setup display to an icon. When you iconify this display,
all subwindows disappear with it.
The Data Collection Setup display closes when the station window closes because you
must monitor the commands in the station window to be sure that your command went
through. This display also opens the station window whenever you open (deiconify) the
Data Collection Setup display.
You can also select a directory and filename for the setup file. The default is the current
directory and <program_name>.dlg. Click on SAVE SETUP(S) to finish your selection.
The SETTINGS menu also includes an item to allow you to load a setup you have saved. If
you choose LOAD DATA COLLECTION SETUP FROM FILE, the Data Collection Setup Load
window is displayed (figure 6-5). This window allows you to load any .dlg file to restore
datalog setups. You may also run .dlg files as scripts.
STDF FILE: Selects the name of the STDF file to receive datalog data. This
item shows the current STDF filename if you have assigned one.
It is grayed out (inactive) if DATALOG TO:STDF FILE is not
selected. If you leave this item blank, IMAGE generates a
filename. (This name does not appear in the display.)
TEXT FILE: Selects the name of the text file to receive datalog data. This item
shows the current text filename if you have assigned one. It is
grayed out (inactive) if DATALOG TO:TEXT FILE is not selected. If
you leave this item blank, IMAGE generates a filename. (This
name does not appear in the display.)
PRINTER: Selects the name of the printer to print the datalog data. This
item shows the default printer name if you have assigned one.
The default printer name is assigned using IMAGE Properties
(see “Datalog/Summary Options” on page 3-38). It is grayed out
(inactive) if DATALOG TO: PRINTER is not selected. When
datalogging to a printer, a separate file with the extension
.printtmp is created. This file is spooled at the end of the lot or
when datalogging is turned off. The .printtmp file is deleted
after printing.
If you omit a filename, datalog to a standard test data format (STDF) file creates a default
name based on the test program name and station number. The format of the default
filename is:
node_station#_<test_program>_<lot_id>_timestamp.stdf
An example would be:
constance_1_volt_reg2_23_Feb16_09:57.stdf
If you omit a filename, datalog to a text file creates a default name with the format:
node_station#_<test_program>_<lot_id>_timestamp.data
When enabling datalog to a text or STDF file, if the filename exists it is moved to a backup
file called <filename>% and a new file is started.
DATALOG/SUMMARY OPTIONS category (see figure 6-6) or specify the value in your
.Xdefaults file.
If you set this property to TRUE, the datalog and datastream commands return an error if
the STDF filename does not conform to STDF V4 specifications. This property also affects
STDF filenames specified in the Data Setup window and the tl_set_datalog() command.
If you set this property to FALSE, or if you do not specify it in your .Xdefaults file, all
programs retain their default behavior (off).
Current test criteria settings for the data stream are loaded into the TESTS TO DATALOG
scrolling list. You can edit the list with the following setting controls:
ADD Adds a test set to the list. Define test sets with the following
INCLUDE options:
TEST NUMBERS: ALL or TESTS ON LIST
TEST TYPES: ANALOG, DIGITAL, or BOTH
TEST RESULTS: ANALOG, DIGITAL, or BOTH
Only active when there are fewer than nine test sets defined.
CHANGE Changes a selected test set’s settings to those you specify in the
INCLUDE options. Only active when a test set is selected.
DELETE Removes a selected test set from the list. Only active when a test
set is selected.
Commit changes to datalog test selection by clicking APPLY in the Data Collection Setup
(dacldisp) main display window (figure 6-3).
SAMPLE RATE Specifies a sampling rate for datalog—how often devices are
datalogged. The default is 1, every device datalogged. (See
“Sampled Datalog” on page 6-47.)
INCL. WAFER MAP INFO Specifies collection of all information relevant to wafer mapping.
(See “Generating Wafer Map Information” on page 6-47.)
SAMPLE LIMIT Specifies a sampling limit for datalog—the total number of
devices to be datalogged. The default is no limit. (See “Sampled
Datalog” on page 6-47.)
SPACE BETWEEN PINS OFF minimizes the space between pins in a pin list. If you are
using enhanced functional datalog, space between pins is
eliminated. The default is ON. A setting of OFF corresponds to
the -no_pin_space filter command line option.
TRUNCATE PIN NAMES ON restricts pin names in datalog output to six characters
(default). OFF shows full pin names and corresponds to the
-full_pin_names filter command line option.
For more information on the command line filters, see “Command Line Filter Syntax” on
page 6-83.
command is generated, which brings up the Datalog Output window. All datalog data is then
sent to that window.
2. In the DATAWIN VERSION item, click the version of the Datalog Output window you want
to use. Choose XVIEW for an OpenWindows-style display; choose MOTIF for a CDE-style
display.
3. When you are finished configuring the collection parameters, click APPLY.
To set the version of the Datalog Output window that IMAGE uses as its default, set the
DATALOG/SUMMARY OPTIONS>DEFAULT DATAWIN VERSION option in IMAGE Properties to
XVIEW (for OpenWindows-style) or MOTIF (for CDE-style). (For more information on how to
set IMAGE properties, see “Changing IMAGE” on page 3-33). You can also change the
default Datalog Output window version by including the following line in your .Xdefaults
file:
image.datawin.version:
After the property name, add xview (for OpenWindows-style) or motif (for CDE-style). If
you do not include this line in your .Xdefaults file, IMAGE uses the XView version.
The Motif version of the Datalog Output window supports wide displays, making it easier to
read lengthy output from programs with large numbers of pins.
In order for the Motif version of the Datalog Output window to scroll automatically as new
data appears, the cursor must be at the end of the existing data. You can position the cursor
in the appropriate place by selecting VIEW>END OF LOG or pressing CONTROL+E.
The Motif version of the Datalog Output window can be divided into no more than two
viewable text areas, and the view areas are not writable.
The Datalog Output window disappears if datalog to the window is disabled with the
datalog -off command. You can also disable datalog to this window by selecting QUIT
from its window menu, or FILE>EXIT.
Datalogs of digital data made from the Data Collection Setup display show the vector and
cycle number after the pattern halts, which may not be the failing vector and cycle number.
In the EFD, however, the additional failure information is read from the History RAM.
Datalogs produced by the EFD, therefore, show the failing vector and its cycle number. Also
the vector and cycle number at the beginning of datalogs set up by the EFD display are the
vector and cycle numbers after the pattern halted. (See “EFD Output Format” on page 6-44.)
However, reading additional data from History RAM uses test time. Use this EFD display
only when you want more failure information. (See “Pattern Execution History RAM” on
page 37-52 in the Catalyst Instrumentation Manual.)
In the EFD display, you can:
• Specify different datalog setups for different tests or groups of tests
• Select all vectors in HRAM or only the failing vectors
• Put the HRAM into multiple failures mode (advanced mixed-signal only)
• Specify the number of vectors to datalog before a failing vector
• Specify the number of vectors to datalog after a failing vector
• Specify the number of failing vectors to datalog, and if multiple failures occur, specify all
vectors
• Include programmed channel data when a vector is datalogged
• Include tset and loop count information when a vector is datalogged
• Specify the pins, list of pins, failing pins, or all pins to be datalogged. If datalogging a list
of pins, you can datalog only the failing pins in the list or all pins in the list.
• Specify the grouping of vector data: pattern column groups or pattern column order
• Specify the radix of the vector data when pattern column groups are used
All these features (except the advanced mixed-signal HRAM multiple failure mode) can be
specified on a per-test basis. Datalog setups can have different EFD setups for different
tests or groups of tests.
When you open the Enhanced Functional Datalog display, it displays the current datalog
information. If datalog information changes while the EFD display is open, however, the new
information is not shown in the display. To update this display (and all other open data
windows), use the menu item SETTINGS>REFRESH DISPLAY WITH DATA COLLECTION
SETTINGS in the Data Collection Setup display. (See “Control Panel Items” on page 6-15.)
REMOVE Selects the EFD setup to remove. Choices are CURRENT EFD
SETUP or ALL EFD SETUPS.
SHOW Displays all EFD setups and allows you to select one to be
displayed.
HRAM FAIL MODE Specifies A580 or Catalyst HRAM failure mode as on or off. ON
puts the HRAM in multiple failure mode, allowing the HRAM to
capture up to 63 failing vectors. The failure mode can be
specified only for all EFD setups, not for individual EFD setups.
Setting HRAM fail mode ON is the same as the following
statements:
set hsd50 hram_failmode:on;
set hsd50 ignore_halt_on_fail:always;
set hsd50 hram_stop_on_full:on;
This setting appears only with advanced mixed-signal, Catalyst,
or Catalyst Tiger test systems.
DISPLAY Groups the vector data in the datalog by PIN ORDER, PATTERN
COLUMN GROUPS, or PATTERN COLUMN ORDER. PIN ORDER
displays the information by numerical pin order (pin 1 to pin N).
PATTERN COLUMN ORDER displays the pins in the order they
appear in the pattern with no groups. PATTERN COLUMN GROUPS
displays the pin groups. The default is PIN ORDER.
RADIX Shows the datalog in OCTAL, HEX (hexadecimal), DECIMAL,
BINARY, or SYMBOLIC. You can change the radix only if you select
PATTERN COLUMN GROUPS from the DISPLAY menu above. This
item is grayed out (inactive) unless PATTERN COLUMN GROUPS
are selected. The default is the radix used in the pattern file. If
groups are not used, the vector data is shown in symbolic.
LOOP COUNT Specifies whether the loop count is shown with the vector data in
the datalog. The default is ON.
TIMING SETS Specifies whether the timing set is shown with the vector in the
datalog. The default is ON.
APPLY Applies the currently displayed setup to the data server.
Generates a datalog statement in the station window. You must
click SELECT on this button to make any EFD changes take
effect.
RESET Resets the display to its last-saved values (the values in the
display when you last clicked APPLY).
EFD Restrictions
Observe the following restrictions when using enhanced functional datalog:
• The -channels and -add_efd pat_col_grp options are incompatible. If both are
selected, the datalog or datastream commands or both fail.
• To display information by pin groups, the pin group names in the pattern file must match
the pin groups in the pin map. Otherwise, individual pins are displayed.
• The test program must have a pinmap.
• EFD cannot datalog passing tests.
• You can have only one EFD setup per test.
• EFD cannot be programmed using the datalog test program statement.
• EFD can be paused and resumed from the display or the command line and enabled or
disabled using the tl_set_dlg_enable() function.
• EFD reads back the HRAM. Reading and reconstructing HRAM on advanced mixed-
signal testers (A570 and A580) takes about 700 ms per SCM. HRAM need only be read
once for each failing test for which EFD is on; it does not need to be read again for each
failing vector.
• For a failing vector to be datalogged, both the failing vector itself and the vector where
the fail flag is set (60 or 62 cycles later on advanced mixed-signal test systems, 34
cycles later on mixed-signal test systems) must be captured in HRAM.
• The number of vectors datalogged before and after a failing vector may not always be
the number you requested; it is limited by how many vectors before and after the failing
vector were captured in HRAM. For instance, with A580 fail mode, only three vectors
before the failing vector and 60 vectors after the failing vector are generally available. If
the longer pipeline depth is used, one vector before the failing vector and 62 vectors
after the failing vector are available.
• Setting up HRAM to capture logic rather than fail may result in an incorrect list of failing
pins for datalogged vectors. The list of failing pins printed at the beginning of the datalog
output for each test is still correct, but the failing pins listed for individual vectors could
be incorrect.
• EFD setups apply to all datalogs and datastreams. You cannot associate an EFD setup
with any single datastream or datalog output.
[all_pins | fail_pins]
Specifies that all pin values or only failing pin values are included
in the datalog output. (See “Leakage Selection” on page 6-40.)
-off Turns datalog off. This closes all output streams, deletes all
setup information, and turns off all EFD setups.
-show Displays the current datalog setup in the station window. This
includes the outputs selected, the format (brief or full), what tests
are enabled for datalog, and the sample rate. If data collection is
paused, the output includes the line:
Data Collection is PAUSED
-pause Pauses all data collection temporarily.
-resume Resumes data collection.
-change [(includes) | (tests) | -notests]
(samples) (mode) (leakage)
Allows you to modify parts of the datalog setup without turning
off datalog or respecifying the entire datalog setup.
-add_output (outputs)
Allows you to add an output (for example, -stdf) without
respecifying the entire datalog setup.
-remove_output (outputs)
Allows you to remove an output without turning off datalog or
respecifying the entire datalog setup.
-add_efd <efd_setup_name> (efd_info)
Add EFD setups. You can specify multiple EFD setups by
repeating this statement. If two setups conflict, the latest
specification overrides.
You cannot use this option when datalogging passing tests. If
passing tests are selected, the datalog command fails and an
error message is displayed. As with other datalog setups, you
must use the -test option.
You cannot use this option without specifying an output on a
command line. If no outputs are specified in a datalog
command, the EFD setup is incrementally added to any
previously opened outputs. If no outputs are open, the setup is
[fail_vect | all_vect]
Specifies whether failing vectors or all vectors captured in HRAM
should be datalogged. (The default is fail_vect.)
[num_fail_vect #]
Specifies how many failed vectors to datalog when datalogging
failing vectors. You can specify a specific number or use all to
datalog all failing vectors captured in HRAM.
[loop_cnt_on | loop_cnt_off]
Shows the loop count along with the vector data in the datalog.
(The default is loop_cnt_on.)
[vect_before_fail #]
Specifies the number of vectors before the failing vector to
datalog. (The default is 0.)
[vect_after_fail #]
Specifies the number of vectors after the failing vector to datalog.
(The default is 0.)
[hram_failmode_on | hram_failmode_off]
Specifies A580 or Catalyst HRAM failure mode as on or off.
When on, the HRAM is in multiple failure mode and allows the
HRAM to capture up to 63 failing vectors. You can specify HRAM
failure mode only for all EFD setups, not for each EFD setup.
[prog_data_on | prog_data_off]
prog_data_on displays the programmed channel data with the
failing data. (The default is prog_data_on.)
[tset_on | tset_off]
Shows the timing set along with the vector in the datalog. (The
default is tset_on.)
[pat_col_grp | pat_col_ord | pin_ord]
Groups the vector data in the datalog by pattern column groups
or pattern column order. Pin order displays the information by
numerical pin order (pin 1 to pin N). Pattern column order
displays the pins in the order they appear in the pattern with no
groups. Pattern column groups displays the pin groups. (The
default is pin_ord.)
[display_radix [octal hex dec bin sym]]
Shows the datalog in octal, hexadecimal, decimal, binary, or
symbolic. The default is the radix used in the pattern file. If
groups are not used, the vector data is shown in symbolic.
-remove_efd <efd_setup_name>
Deactivates the named EFD setup. It is analogous to datalog
-off. The -remove_efd and -efd_off options need not be
used with any other option, such as -test or -stdf. If
deactivating a specific EFD setup, you must provide the setup
name.
This option removes EFD setups from all datalog and
datastream output setups.
-efd_off Deactivates EFD and all EFD setups. This option removes EFD
setups from all datalog and datastream output setups.
-station # Specifies a station number to collect datalog data.
Output Selection
Possible output selections for the datalog command are:
-stdf Write output in STDF (binary) format to a disk file.
-stdf_file <stdf filename>
Write output in STDF format to a file you specify.
-statwin Display output in the station window.
-datawin Display output in the Datalog Output window. Can be
abbreviated -dwin.
-datawin_display <host>
Display output in the Datalog Output window on the specified
host.
-file <filename> Write output as ASCII text to a disk file.
-printer [<printername>]
Write output to a separate file with the extension .printtmp.
NOTE
Each time you modify the datalog setup using the datalog command you must respecify
output selections. Omitted selections are automatically turned off.
Datalog to a standard test data format (STDF) file sends data to a file called
<node>_<station#>_<test_program>_<lot_id>_<timestamp>.stdf
For example:
constance_1_volt_reg2_23_Feb16_09:57.stdf
The -stdf_file option allows you to set your own file name for an STDF file. (For
information on STDF filenames, see “Naming STDF Files” on page 6-19.) For example, to
turn on STDF datalog for all tests and collect the STDF data into the file myfile.stdf, use
the following command:
datalog -test all -stdf_file myfile.stdf
Datalog to an STDF file lets you maintain large amounts of data that consume less disk
space. Files can also be transferred to a FIRMS host for storage.
When setting up datalog to a text file, the <filename> specification is optional. If you omit
it, a default filename is created based on the test program name and station number. The
format of the default filename is
<node>_<station#>_<test_program>_<lot_id>_<timestamp>.data
When enabling datalog to a text or STDF file, if the filename exists it is moved to a backup
file called <filename>% and a new file is started.
Test Selection
Use the -include switch of the datalog command to select tests to be datalogged. The
-test switch works as before, but -include is preferred and provides extended
functionality for specifying sets of tests to datalog.
You can specify analog or digital tests using the analog and digital keywords. You can
use either of these keywords with existing keywords, such as pass, fail, or all. For
example, to datalog all digital tests, use the command
Switch Definition
-include analog list <A> Analog Tests on List A and Digital Tests on List
-include digital list <B> B
The -include switch and the -test switch cannot be used together on a datalog command
line. When turning data streams on (using the -on switch), either -include or -test can
be used to define the test criteria. When changing the setup for a data stream (using the
-change switch), test criteria defined with -test or -include replaces the current test
criteria for that data stream. If neither -test nor -include is specified with the -change
switch, the test criteria for that data stream remains unchanged.
Leakage Selection
The -lkg switch takes up to two arguments:
-lkg [<testspec>] [<pinspec>]
where <testspec> can be off, all (default), or fail, and <pinspec> can be all_pins
(default) or fail_pins.
Take care when using the defaults. The default action when turning a data-stream on is to
use the default values for any values not specified. The default action when changing an
existing datastream is to leave the value unchanged if it is not specified. However, if neither
value (<testspec> or <pinspec>) is specified when changing an existing datastream, both
default values are used.
For example:
-on -lkg -on -lkg all all_pins
Output Format
The format of a datalog report is controlled by the format test program. You can change the
report format by selecting the following test format programs:
• Brief format (dlgfmt) displays the test number, label, and result (see figure 6-2 on page
6-13).
• Full format (fulldlgfmt) displays the test name, number, label, result, and limits (see
figure 6-12).
• EFD one-line format (efddlgfmt) displays the test number, label, result, and additional
EFD information in a one-line format (see “Wafer Output Format” on page 6-43).
Specify the format test program for the text output streams using one of the following
switches with the datalog command:
-format dlgfmt
-format fulldlgfmt
-format efddlgfmt
The default format test program is dlgfmt. The -format switch applies to all output streams
created by a single datalog command, including output to the station window, the Datalog
Output window, and an STDF file, and a text file.
Sequencer: first_level_tests
10 leak_vcc leak_vcc 10 volts < 54 volts (F) < 50 volts
20 lcap_vcc lcap_vcc 24.9 uf (F) < 20.0 uf
30 ac_rip ac_rip 20 Khz < 30 Khz (F) < 30 Khz
40 sig_amp sig_amp -1.25
50 saturate saturate 500 ma < 495 ma (F)
Sequencer: second_level_tests
100 leak_vcc leak_vcc 5 volts < 60 volts (F) < 55 volts
200 lcap_vcc lcap_vcc 17.9 uf < 30.0 uf
300 ac_rip ac_rip 15 Khz < 28 Khz < 40 Khz
400 sig_amp sig_amp -8.52
500 saturate saturate 400 ma < 288 ma (F)
Bin: 20
Sequencer: first_level_tests
10 leak_vcc leak_vcc 10 volts < 40 volts < 50 volts
20 lcap_vcc lcap_vcc 22.4 uf (F) < 20.0 uf
30 ac_rip ac_rip 20 Khz < 18 Khz (F) < 30 Khz
40 sig_amp sig_amp -2.65
50 saturate saturate 500 ma < 500 ma (F)
Sequencer: second_level_tests
100 leak_vcc leak_vcc 5 volts < 61 volts (F) < 55 volts
200 lcap_vcc lcap_vcc 10.0 uf < 30.0 uf
300 ac_rip ac_rip 15 Khz < 15 Khz < 40 Khz
400 sig_amp sig_amp 6.95
500 saturate saturate 400 ma < 308 ma (F)
Bin: 20
Sequencer: first_level_tests
10 leak_vcc leak_vcc 10 volts < 31 volts < 50 volts
20 lcap_vcc lcap_vcc -3.9 uf < 20.0 uf
30 ac_rip ac_rip 20 Khz < 33 Khz (F) < 30 Khz
40 sig_amp sig_amp -4.66
50 saturate saturate 500 ma < -33 ma (F)
Sequencer: second_level_tests
100 leak_vcc leak_vcc 5 volts < 61 volts (F) < 55 volts
200 lcap_vcc lcap_vcc 17.9 uf < 30.0 uf
300 ac_rip ac_rip 15 Khz < 29 Khz < 40 Khz
400 sig_amp sig_amp 10.87
500 saturate saturate 400 ma < 283 ma (F)
H or 1 /
L or 0 .
M -
V @
To specify the one-line EFD format, click MENU on the FORMAT list in the Data Collection
Setup Window and select. (You must also have the EFD enabled and have defined a setup.)
You can enable one-line EFD output on the command line by specifying the -add_efd and
-format efddlgfmt parameters on the same command line.
Two-Line EFD Format. For passing vectors, the two-line EFD format output is the same
as the one-line EFD format shown above. For failing vectors, the expected value is shown
on the first line and the actual received value appears on the second line under each failed
pin. (“Actual mode” is available only on testers that support this feature, such as the Catalyst
and Catalyst Tiger test systems. Earlier systems that do not support actual mode display an
F under the failed pin.) Any pin that fails anywhere in the pattern is marked with a pound
sign (#) under the pin name, even if the failure is outside the selected range of vectors. For
example:
Lot: 1 Tester: hudson Program: my
Device: 4 Station: 1 Site: 0
Sequencer: flow_1
100 Functional Pattern Halt Vector: 268 Halt Cycle: 269 Failing Pins: 7 (F)
Pattern: 16PinPat_ro
Failed Pins:
PIN009 : 1 PIN003 : 3 PIN005 : 5 PIN007 : 7
PIN009 : 9 PIN011 : 11 PIN013 : 13 PIN015 : 15
P P P P P P P P P P P P P P P P
I I I I I I I I I I I I I I I I
N N N N N N N N N N N N N N N N
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1
1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6
Vector Tset Cycle # # # # # # # #
2 ro_ts 3 L 0 L 0 L 0 L 0 L 0 L 0 L 0 L 0
3 ro_ts 4 F H 1 H 1 H 1 H 1 H 1 H 1 H 1 H 1
L L
4 ro_ts 5 L 0 L 0 L 0 L 0 L
0 L 0 L 0 L 0
6 ro_ts 7 L 0 L 0 L 0 L 0 L
0 L 0 L 0 L 0
7 ro_ts 8 F H 1 H 1 H 1 H 1 H
1 H 1 H 1 H 1
L L L L
8 ro_ts 9 L 0 L 0 L 0 L 0 L
0 L 0 L 0 L 0
9 ro_ts 10 F H 1 H 1 H 1 H 1 H
1 H 1 H 1 H 1
L L
10 ro_ts 11 L 0 L 0 L 0 L 0 L 0 L 0 L 0 L 0
Bin: 2
Note that pin 1 is marked as failing although the displayed vectors show no failure data.
To specify the two-line EFD format, click MENU on the FORMAT list in the Data Collection
Setup Window and select LABEL, LIMITS AND TESTNAME (you must also have the EFD
enabled and have defined a setup). You can enable two-line EFD output on the command
line by specifying the -add_efd and -format fulldlgfmt parameters on the same
command line.
Test number 6 6
Test label 16 18
Test name – 11
Lower test limit (includes scale factor and units) – 9
Sampled Datalog
When datalogging, you can select a datalog sample rate and sample limit. This allows you
to adequately characterize a lot or wafer, while limiting the disk space for data files. Use the
-samprate # and -samplimit # switches to specify that only 1 in every N devices is to be
datalogged, up to a maximum of L logged devices.
For example, to datalog 1 in 10 devices include the following on the datalog command line:
-samprate 10
If the rate and the limit are not specified, the rate defaults to 1 (every device is logged), and
the limit defaults to “no limit.” You can use sample rate and sample limit independently. The
maximum value for rate and limit is 232; the minimum value for rate is 1.
When the sample rate is changed, the sample index count (the number of devices tested
since the last datalog) is reset to 1. The sample index is incremented following each run of
the test program. When the index count reaches the sample rate, a datalog record for that
device is created. Then the sample index is reset to 1 and the count begins again. When
the sample limit is reached, no more datalog data is sent to the output streams. To reset the
“no limit” condition, set the limit to 0.
Creating Datastreams
The datalog command and the Data Collection Setup display allow you to create data
streams. These data streams, however, must include the same test criteria or same
sampling information, and you can send the stream to only a limited number of outputs.
The datastream command and the Datastream Setup window allow you to simultaneously
create multiple data collection streams with different characteristics, such as test criteria,
sampling rates, and limits. You can also send the datastreams to different output
destinations. (See “Controlling Data Collection From a Test Program” on page G8-1 for
more on the differences between streams set up using the datalog and datastream
commands.)
This window has a scrollable list of all currently active datastream setups at the top (if any
are set up). Only streams set up using the datastream command are listed. (See also
“Showing Current Datastreams” on page 6-56.) This list displays each datastream's output
mode and ID. Datastreams outputting to STDF files have:
STDF:<filename>
listed on the right side of the list. Datastreams outputting to external programs have:
PGM:<filename>
listed on the right side of the list. If the datastream uses the default (system) filename, it has
DEFAULT FILE NAME as the filename. To perform operations on a particular setup, select
the setup from the list.
Anytime you open the Datastream Setup window, it displays the current datalog information.
If datalog information changes while the Datastream Setup window is open, however, the
new information is not shown in the display. To update the Datastream Setup window (and
all other open data windows), you must use the menu item SETTINGS>REFRESH DISPLAY
WITH DATA COLLECTION SETTINGS in the Data Collection Setup display. (See “Control Panel
Items” on page 6-15.)
The Datastream Setup window has the following controls:
DATASTREAM ID Identifies a particular datastream. Note that this identifier is not
created or modified in the active datastream setups until you
click on ADD, CHANGE, or DELETE. If you delete a setup from the
list of active setups, you delete the setup whose datastream ID
is currently modified. You are warned if you try to add a stream
when another stream with the same ID exists or try to change a
datastream’s ID to an ID already in use. Changing the
datastream ID of a stream requires that the stream be restarted.
DESTINATION Selects either an STDF file or a program as the destination of the
datastream.
FILE/PROGRAM NAME Specifies the name of the STDF file or program name. If you
specify STDF FILE, you can fill in this line with the name of the
destination file (see “Naming STDF Files” on page 6-19) or leave
it blank to have IMAGE choose the filename. System-generated
filenames do not appear in this field. If you specify PROGRAM as
the destination, fill in this field with the name of the program to
send the datastream data to. If you leave this blank, you get a
default datalog filter, datalogging to a file whose name is based
on the current test program and stream name. IMAGE searches
along the path specified by your $PATH environment variable for
the program to run. You also specify all command-line
arguments to run the program on this line. Fill in the program
name as you would when running the program from the
command line of a shell. Changing the output destination
requires that the stream be restarted for your changes to take
effect.
TEST CRITERIA INTERFACE
Determines which tests are selected for datalog. Standard
options include:
TEST CRITERIA>ALL TESTS
Datalogs all tests. (This is the default.)
TEST LIST Specifies a list of tests to datalog. This is the LIST OF TESTS
referred to in the CRITERIA item. You can use test names, test
numbers, ranges of test numbers, and sequencer names. See
“Test Selection” on page 6-38 for more information.
EXTENDED TEST CRITERIA INTERFACE
Brings up the Extended Datastream Test Selection window
(Figure 6-14).
Current test criteria settings for the data stream are loaded into the TESTS TO DATALOG
scrolling list. You can edit the list with the following setting controls:
ADD Adds a test set to the list. Define test sets with the following
INCLUDE options:
Only active when there are less than nine test sets defined.
CHANGE Changes a selected test set’s settings to those you’ve specified
in the INCLUDE options. Only active when a test set is selected.
DELETE Removes a selected test set from the list. Only active when a test
set is selected.
Commit changes to datastream test selection by clicking ADD or CHANGE in the Datastream
Setup display (figure 6-13).
SAMPLE RATE Specifies a sampling rate for datalog, how often devices are
datalogged. The default is 1, every device datalogged. (See
“Sampled Datalog” on page 6-47.)
SAMPLE LIMIT Specifies a sampling limit for datalog, the total number of devices
to be datalogged. The default is no limit. (See “Sampled Datalog”
on page 6-47.)
MODE Specifies the STDF mode of the datastream. HEAVY specifies
that each test result record (PTR, MPR, or FTR) will contain all
information about a test, including test number, test name and
label, test limits, and test result. In LIGHT mode, much of the
static data for each test, including the limits, is only contained in
the first result record for each test. In Extra-Light (XLIGHT) mode,
the test name and label (test_txt) is also only contained in the
first result record for each test. The lighter the mode, the smaller
the STDF file will be. The default is LIGHT. (See
“tl_set_test_condition_during_lot” on page 26-382 for the side
effects of changing the test conditions during the run of a lot.)
LEAKAGE DATALOG Enables datalogging for HSD50 pin leakage values. Leakage
datalog is output in a special format. (See “Leakage Output
Format” on page 6-43.) Choices are
OFF Leakage tests are included in normal datalog
output.
ALL LEAKAGE TESTS All leakage tests are datalogged with
the values for pins specified by the LEAKAGE PINS option.
FAILING LEAKAGE TESTS Only failing leakage tests are
datalogged with the values for pins specified by the LEAKAGE
PINS option. Passing tests are included in normal datalog output.
LEAKAGE PINS Specifies which pin leakage values to datalog. This option is
active only when leakage datalogging is turned on. Choices are
ALL PINS Values for all pins are included in the datalog
output.
FAILING PINS ONLY Only values for those pins that failed the
leakage limits are included in the datalog output.
ADD Adds a new stream to the list of active datastreams. Change the
current setup (including datastream ID) using the window control
items, then click ADD.
CHANGE Changes the currently selected streams attributes to be the
attributes selected using the previously described controls. To
change a stream, select it and modify the desired items on the
display. Click on CHANGE. Some changes require that the stream
be restarted. You are notified when this is the case and given an
opportunity to go back.
NOTE
Be careful when restarting a stream that is outputting to a file. The file may be overwritten
when the stream is restarted.
NOTE
When using the DELETE button, the setup you select in the list of currently active setups is
removed. If you have modified the datastream ID, the stream ID selected in the list of
currently active setups is be removed, not the modified datastream ID.
[all_pins | fail_pins]
Specifies all pin values or only failing pin values are included in
the datalog output. See “Leakage Selection” on page 6-40.
-off Stops the datastream command processor for the specified
datastream or test station.
-show Displays the datastream setup in a station window. See
“Showing Current Datastreams” on page 6-56.
-change <sid> (tests) (samples) (mode) (leakage)
Allows you to modify parts of the datastream setup without
turning off datalog or respecifying the entire datalog setup.
(-change_mode is considered obsolete, but still works to change
modes: Heavy>Light, Light>Heavy, XLight>Heavy.)
-station # Specifies a station number.
-wafer_map Collect X/Y coordinate and binning information for every device
(used in wafer mapping). Use this option with the -samprate #
option. See “Generating Wafer Map Information” on page 6-47.
You can perform the following stream operations:
• Create a stream with a particular set of characteristics
• Change the characteristics of a stream (except the output program which receives the
data)
• Delete a stream
When you create a new datastream, you must specify one output selection:
-stdf Output goes to an STDF file with a default system name.
-stdf_file Output goes to an STDF file you name (see “Naming STDF
Files” on page 6-19).
-program_name Output goes to a particular process.
tl_set_datalog Syntax
The function tl_set_datalog() sets the state of data collection. You must call
tl_set_datalog() before any tests for the current device are executed. Use this function
in your program before calling the first sequencer.
tl_set_datalog() returns one of three values when called:
1. See also “Controlling Data Collection From a Test Program” on page G8-1
When the program successfully invokes tl_set_datalog(), the datalog buffer is dumped,
the command is processed, and the datalog command is sent to IMAGE. This ensures no
data is lost.
The syntax is:
err = tl_set_datalog(<macro_parameter_list>, NULL);
Table 6-6 shows the relationship between datalog command parameters and
tl_set_datalog() syntax.
tl_set_datalog() Syntax
datalog Command
Notes
Parameter Argument
Test Program Macro
Data Type
-on TL_DLG_ON
-off TL_DLG_OFF
-statwin TL_DLG_O_STATWIN
-datawin TL_DLG_O_DWIN
Table 6-6. datalog Command Options and Equivalent tl_set_datalog() Syntax (Continued)
tl_set_datalog() Syntax
datalog Command
Notes
Parameter Argument
Test Program Macro
Data Type
TL_DLG_PIN_NAMES
TL_DLG_PIN_NUMBERS
analog TL_DLG_ANALOG_TEST
Table 6-6. datalog Command Options and Equivalent tl_set_datalog() Syntax (Continued)
tl_set_datalog() Syntax
datalog Command
Notes
Parameter Argument
Test Program Macro
Data Type
-station No macro.
tl_set_datalog() can be
used only for the station in
which the test program is
loaded.
-wafer_map TL_DLG_WAFER_MAP
The datalog command allows you to specify several tests or test ranges following the
keyword list. The command has separate macros to deal with test lists and test ranges.
Test lists consist of an array of test numbers terminated by a zero-valued element (test
number 0 is illegal). The input for test ranges is an array of unsigned integer pairs specifying
the start and ending test number for a range. This array is terminated by an element whose
value is zero. However, several ranges can be specified during one invocation of
tl_set_datalog().
tl_set_datalog Examples
The following examples compare datalog commands to tl_set_datalog() statements.
The definition of NULL is taken from stdio.h, which is assumed to be included.
• The following outputs all passing tests to the station window and a text file. datalog
command syntax would be:
datalog -on -test all -statwin -file
tl_set_datalog function syntax would be:
tl_set_datalog(TL_DLG_ON, TL_DLG_TEST, TL_DLG_ALL_TEST,
TL_DLG_OUTPUT, TL_DLG_O_STATWIN | TL_DLG_O_FILE, NULL);
• The following outputs test results for tests 1 to 8 to the STDF file Wafer_test_results,
a text file, and the Datalog Output window, where the test both passes and is an analog
test. datalog command syntax would be:
datalog -on -test pass analog list 1 to 8
-stdf_file Wafer_test_results -file -datawin
tl_set_datalog function syntax would be:
tl_set_datalog(TL_DLG_ON, TL_DLG_TEST,
TL_DLG_PASS_TEST | TL_DLG_ANALOG_TEST, TL_DLG_TEST_RNG,
tlist, TL_DLG_OUTPUT, TL_DLG_O_DWIN | TL_DLG_O_FILE,
TL_DLG_STDF_NAME, stdf_filename, NULL)
where:
unsigned int tlist[3] = {1, 8, 0}
char *stdf_filename = "Wafer_test_results"
• The following outputs test results (whether passing or failing) for tests 1 through 5 and
8 through 9 to the station window. Nothing is output to STDF, the Datalog Output
window, or a text file. datalog command syntax would be:
datalog -on -test list 1 to 5 8 to 9 -statwin
tl_set_datalog function syntax would be:
tl_set_datalog(TL_DLG_ON, TL_DLG_TEST_RNG, tlist, TL_DLG_OUTPUT,
TL_DLG_O_STATWIN, NULL);
where:
unsigned int tlist[5] = {1, 5, 8, 9, 0}
• The following outputs test results (whether passing or failing) for tests 1, 5, 9, 11, and
14 to the station window. datalog command syntax would be:
datalog -on -test list 1, 5, 9, 11, 14 -statwin
tl_set_datalog function syntax would be:
tl_set_datalog(TL_DLG_ON, TL_DLG_TEST_LIST, tlist, TL_DLG_OUTPUT,
TL_DLG_O_STATWIN, NULL);
where:
unsigned int tlist[6] = {1, 5, 9, 11, 14, 0}
tl_set_efd_datalog Syntax
tl_set_efd_datalog() returns one of three values:
TL_DLG_EFD_REMOVE removes the EFD setup you name from the list that the EFD Setup
dialog maintains; it has the same functionality as the dialog’s REMOVE button. You can use
this function, either in a test program or in the Immediate Window, to remove a setup from
the EFD dialog. Removing an inactive setup does not affect the current setup.
To turn off enhanced functional datalogging entirely, specify TL_DLG_EFD_OFF and omit the
setup name and all values for the macro_parameter_list. This removes all setups from
the EFD dialog.
Table 6-7 lists EFD-related datalog command parameters and the equivalent
tl_set_efd_datalog() macros.
tl_set_efd_datalog() Syntax
hram_failmode_off TL_DLG_EFD_HRAM_FM_OFF
(hr_fm_off)
prog_data_on TL_DLG_EFD_PROG_DATA_ON
(pd_on)
prog_data_off TL_DLG_EFD_PROG_DATA_OFF
(pd_off)
Table 6-7. EFD Command Options and Equivalent tl_set_efd_datalog() Syntax (Continued)
tl_set_efd_datalog() Syntax
pat_col_ord TL_DLG_EFD_PAT_COL_ORD
(pc_ord)
pat_col_grp TL_DLG_EFD_PAT_COL_GRP
(pc_grp)
The tl_set_efd_datalog function uses the same default settings as the datalog
command. To use a default setting, omit the appropriate macro from the function call. For
example, you can invoke the default EFD setup:
datalog -add_efd efd_setup_1 hr_fm_off fail_v fail_p pd_on lpc_on ts_on num_fv
1 v_aft_f 0 v_bef_f 0 in_ord -test all
by specifying an empty parameter list:
tl_set_efd_datalog(TL_DLG_EFD_ADD, “efd_setup_1”, NULL);
tl_set_efd_datalog Examples
The following examples compare datalog commands to tl_set_datalog() statements.
The definition of NULL is taken from stdio.h, which is assumed to be included.
• To enable enhanced functional datalogging with the default settings and a specific list
of pins, you can use the command:
datalog -add_efd efd_setup_1 hr_fm_off fail_v fail_p pd_on lpc_on ts_on
num_fv 1 v_aft_f 0 v_bef_f 0 pin_ord -test list 2000 to 2003
2006 to 2009
or the function:
tl_set_efd_datalog(TL_DLG_EFD_ADD, “efd_setup_1”, TL_DLG_EFD_TEST_RNG,
tlist, NULL);
where:
unsigned int tlist[5] = { 2000, 2003, 2006, 2009, 0 };
• To run a specific list of tests and capture four failing vectors from any pin, with two
vectors before and one vector after each failure, you can use the command:
datalog -add_efd efd_setup_8 hr_fm_off fail_v all_p pd_on lpc_on ts_on
num_fv 4 v_aft_f 1 v_bef_f 2 pin_ord -test list 200 300 400 500
or the function:
tl_set_efd_datalog(TL_DLG_EFD_ADD, "efd_setup_8", TL_DLG_EFD_FAIL_VECT,
TL_DLG_EFD_NUM_FAIL_VECT, 4, TL_DLG_EFD_VECT_BEF_FAIL,
2, TL_DLG_EFD_VECT_AFT_FAIL, 1, TL_DLG_EFD_TEST_LIST,
tlist, NULL );
where:
tl_change_datalog Syntax
Parameters for tl_change_datalog() are listed in table 6-8.
tl_change_datalog() Syntax
Notes
Argument Data
Test Program Macro
Type
TL_DLG_FAIL_TEST
TL_DLG_DIGITAL_TEST
TL_DLG_ANALOG_TEST
tl_change_datalog() Syntax
Notes
Argument Data
Test Program Macro
Type
TL_DLG_SEQ_NAME char *
TL_DLG_O_STDF
TL_DLG_O_DWIN
tl_get_datalog Syntax
Macros used by tl_get_datalog() are, for the most part, the same as those used by
tl_set_datalog(), with some additions. If you request the test criteria, you can determine
if the criteria includes a test list or range of test numbers, sequencer names, if sample
datalog is enabled, or if wafer mapping is selected. A set of macros is provided to test the
big flag returned. If you determine that a test range or test list was used, you can retrieve
the exact information by a subsequent call of tl_get_datalog() and passing the
There are two differences in function argument usage between tl_get_datalog() and
tl_set_datalog() flags. The flag for TL_DLG_TEST can contain more information than was
used to set datalog test criteria. You receive all information used to set datalog but can also
test the flag returned to determine if a test list was being used (this includes a test range),
test names, sequencer names, sampled datalog, and if wafer mapping was used.
If more information is needed (like the exact test list, test names, or sampling criteria) it can
be retrieved by a subsequent function call.
Parameters for tl_get_datalog are listed in table 6-10. Note that TL_DLG_ON and
TL_DLG_OFF are actually return values for TL_DLG_STATE. When these macros are used in
tl_set_datalog(), they can be used alone for brevity. tl_get_datalog() must be
passed pointers to the variable which will store the data.
TL_DLG_OFF
TL_DLG_FAIL_TEST
TL_DLG_ALL_TEST
TL_DLG_ANALOG_TEST
TL_DLG_DIGITAL_TEST
TL_DLG_TEST_LIST_SEL
TL_DLG_TEST_FILE_SEL
TL_DLG_TEST_RNG_SEL
TL_DLG_TEST_NAME_SEL
TL_DLG_SEQ_NAME_SEL
TL_DLG_SAMP_RATE_SEL
TL_DLG_SAMP_LIMIT_SEL
TL_DLG_WAFER_MAP_SEL
TL_DLG_O_DWIN
TL_DLG_O_STDF
TL_DLG_O_FILE
TL_DLG_O_HISTO
TL_DLG_O_PRINTER
TL_DLG_O_PMC
TL_DLG_PIN_NUMBERS
TL_DLG_TEST_NAME char **
TL_DLG_SEQ_NAME char **
TL_DLG_STDF_NAME char *
TL_DLG_FILE_NAME char *
TL_DLG_OUTPUT_FMT char *
tl_get_datalog Examples
The following examples illustrate use of each individual get option. The ... before and after
each option illustrate that more than one option can be requested with every call to
tl_get_datalog().
• TL_DLG_STATE
unsigned int state;
error = tl_get_datalog(TL_DLG_STATE, &state, ...)
if (state & TL_DLG_ON)
printf("Datalog enabled.\n");
else
printf("Datalog disabled.\n");
• TL_DLG_TEST
unsigned int test_crit;
error = tl_get_datalog(...,
TL_DLG_TEST, &test_crit,
...,
NULL);
if (!error) {
/* Error Processing */
}
else {
if (test_crit & TL_DLG_ALL_TEST)
printf("Datalog all tests.\n");
else if (test_crit & TL_DLG_FAIL_TEST)
printf("Datalog Failing tests\n");
else if (test_crit & TL_DLG_PASS_TEST)
printf("Datalog Passing tests\n");
if (test_crit & TL_DLG_WAFER_MAP_SEL)
printf("X/Y coords collected for all parts\n");
if (test_crit & TL_DLG_TEST_LIST_SEL)
printf("Datalog test list being used.\n");
if (test_crit & TL_DLG_SAMP_RATE_SEL)
printf("Sample rate has been set.\n");
• TL_DLG_OUTPUT
unsigned int dlg_output;
error = tl_get_datalog(...,
TL_DLG_OUTPUT, &dlg_output,
...,
NULL);
if (!error) {
/* Error Processing */
}
else {
if (dlg_output & TL_DLG_O_STATWIN)
printf("Datalog to station window.\n");
if (dlg_output & TL_DLG_O_DWIN)
printf("Datalog to datalog window.\n");
.
.
.
}
• TL_DLG_TEST_RNG
unsigned int *rngPtr = (unsigned int *) NULL;
error = tl_get_datalog(...,
TL_DLG_TEST_RNG, &rngPtr,
...,
NULL);
if (!error) {
/* Error Processing */
}
else {
while (rngPtr[i]) {
printf("Range start %d Range End %d\n", rngPtr[i++],
rngPtr[i++]);
}
}
• TL_DLG_TEST_LIST
unsigned int *listPtr = (unsigned int *) NULL;
error = tl_get_datalog(...,
TL_DLG_TEST_LIST, &listPtr,
...,
NULL);
if (!error) {
/* Error Processing */
}
else {
while (*listPtr) {
printf("Test number is %d\n", *listptr);
listptr++;
}
}
• TL_DLG_TEST_NAME
char ** testNames = (char **) NULL;
error = tl_get_datalog(...,
TL_DLG_TEST_NAME, &testNames,
...,
NULL)
if (!error) {
/* Error Processing */
}
else {
while (testNames[i]) {
printf("Test name is %s.\n", testNames[i]);
.
.
.
i++;
}
}
• TL_DLG_SEQ_NAME
char **seqNames
error = tl_get_datalog(...,
TL_DLG_SEQ_NAME, &seqNames,
...,
NULL);
if (!error) {
/* Error Processing */
}
else {
while (seqNames[i]) {
printf("Sequencer name is %s.\n", seqNames[i]);
.
.
.
i++;
}
}
• TL_DLG_STDF_NAME
char *stdf_file = (char *) NULL;
error = tl_get_datalog(...,
TL_DLG_STDF_NAME, &stdf_file,
...,
NULL);
printf("STDF file name %s.\n", stdf_file);
• TL_DLG_FILE_NAME
char *text_file = (char *) NULL
error = tl_get_datalog(...,
TL_DLG_FILE_NAME, &text_file,
...,
NULL);
if (!error) {
/* Error Processing */
}
else
printf("Datalog file name %s.\n", text_file);
Alternatively, you can also first determine if datalog to a file was enabled before
processing the datalog file name.
char *text_file = (char *) NULL
error = tl_get_datalog(...,
TL_DLG_OUTPUT, &dlg_output,
TL_DLG_FILE_NAME, &text_file,
...,
NULL);
if (!error) {
/* Error Processing */
}
else if (dlg_output & TL_DLG_O_FILE)
printf("Datalog file name %s.\n", text_file);
• TL_DLG_SAMP_RATE
unsigned int sample_rate;
error = tl_get_datalog(...,
TL_DLG_SAMP_RATE, &sample_rate,
...,
NULL);
if (!error) {
/* Error Processing */
}
else
printf("Sample rate %d.\n", sample_rate);
Alternatively, you can execute only the sample rate code if the sample rate was set:
Datalog Format
Use the <datalog format> field of a sequencer line to specify the format for the datalog
output line and the units associated with the test value. (See “Datalogging Program Variable
Values” on page 14-24.) The datalog format string (figure 6-15) is enclosed in double quotes
and has two components:
• A field specification, starting with %, that includes a field width specifier, a precision
modifier, and a conversion character
• A six-character units string. The first character of the units string can be a multiplier
such as u for micro (E-06).
conversion character
precision modifier
(digits after the decimal point)
a brief explanation of what each function does. For more information, see “Base IMAGE
Functions” on page 26-1.
The test criteria for all datalog streams must be the same. Retrieving the test criteria for one
datalog stream retrieves the test criteria for all datalog streams.
Datastream streams, on the other hand, can have different criteria and each stream may be
different. Criteria for datastreams must be retrieved individually by stream.
The following macros can be used to determine the test criteria being used:
TL_NOTEXIST No data collection streams.
TL_PASS Stream datalogging passing tests.
TL_FAIL Stream datalogging failing tests.
TL_ALL Stream datalogging all tests.
TL_PASSANALOG Stream datalogging passing analog tests.
TL_FAILANALOG Stream datalogging failing analog tests.
TL_PASSDIGITAL Stream datalogging passing digital tests.
TL_FAILDIGITAL Stream datalogging failing digital tests.
If test lists are enabled for a particular data collection stream, the number of streams is
returned through the argument list in numListElements.
If numListElements is nonzero (that is, a test list has been used), an array of test list
elements is returned. This array can be examined to determine which tests have been
selected in the list. A test list element looks like:
enum tl_setup_type {TL_TEST_NUM, TL_TEST_RANGE, TL_TEST_NAME,
TL_SEQ_NAME};
struct tl_tlist_element {
enum tl_setup_type type;
unsigned int test_num, last_test;
char name[TL_MAXNAME+1];
};
If the type field is set to TL_TEST_NUM, the test_num field is set to the test number.
This function returns the sample rate and limit for the stream identified by streamName.
Programming Example
The following program excerpt shows a possible use of the datalog functions.
main()
{
int sampRate = 0,
sampLimit = 0,
tlistCount = 0;
char *sname = (char *) NULL,
**stream = (char **) NULL,
*streamFileName = (char *) NULL,
*streamDLdir = (char *) NULL;
/* Get the current data collection state from the dataserv process.
If there is some error in retrieving this information the function
will return 0. */
if (!tl_update_data_collection_state()) {
printf("Error updating data collection state.\n");
exit(1);
}
/* Retrieve an array of pointers to the names of each datalog stream
currently enabled. The data collection functions take care of
managing all of the memory used for the list so it isn't necessary
to allocate or free any memory. */
stream = tl_get_data_collection_streams();
printf("Default Datalog Directory: '%s'\n", tl_get_datalog_directory(1));
while (*stream) {
switch (tl_get_stream_criteria(*stream, &lptr, &tlistCount)) {
case TL_NOTEXIST: printf("Existing stream %s doesn't exist.\n",
*stream);
break;
case TL_PASS: printf("'%s' enabled for Passing tests.\n", *stream);
break;
case TL_FAIL: printf("'%s' enabled for Failing tests.\n", *stream);
break;
case TL_ALL: printf("'%s' enabled for All tests.\n", *stream);
break;
case TL_PASSANALOG:
printf("'%s' enabled for passing analogtests.\n", *stream);
break;
case TL_FAILANALOG:
printf("'%s' enabled for failing analog tests.\n", *stream);
break;
case TL_PASSDIGITAL:
printf("'%s' enabled passing digital tests.\n", *stream);
break;
case TL_FAILDIGITAL:
printf("'%s' enabled passing digital tests.\n", *stream);
break;
}; /* end switch */
/* * Print the test list information, if it exists. */
while (tlistCount--) {
switch (lptr->type) {
case TL_TEST_NUM:
printf("Test Number: '%d'\n", lptr->test_num);
break;
case TL_TEST_RANGE:
printf("Test Range: '%d' to '%d'\n",
lptr->test_num, lptr->last_test);
break;
case TL_TEST_NAME:
printf("Test Name: '%s'\n", lptr->name);
break;
case TL_SEQ_NAME:
printf("Sequencer: '%s'\n", lptr->name);
}
lptr++;
}
if (tl_get_stream_sample_info(*stream, &sampRate, &sampLimit)) {
printf("Sample rate: %d\n", sampRate);
printf("Sample limit: %d\n", sampLimit);
}
else
printf("'%s' does not exist.\n", *stream);
if (streamFileName = tl_get_stream_filename(*stream))
printf("'%s' writing file: '%s'\n", *stream, streamFileName);
else
printf("'%s' NOT writing a file\n", *stream);
if (streamDLdir = tl_get_datalog_directory_for_stream(*stream))
printf("'%s' datalogging to: '%s'\n", *stream, streamDLdir);
else
printf("'%s' Not datalogging to any directory.\n", *stream);
stream++;
} /* end while */
seq1();
sort bin;
}
-file Specifies the path and file name of the output file.
-pins_per_line Specifies the number of pins or channels on each line of the
datalog. Corresponds to the PINS PER LINE field in the EFD
graphical setup.
-no_pin_space Minimizes the space between pins in a pin list. Corresponds to
the SPACE BETWEEN PINS field in the EFD graphical setup.
-full_pin_names Shows full pin names (which are normally truncated at six
characters). Corresponds to a value of OFF in the TRUNCATE PIN
NAMES field in the EFD graphical setup.
-no_wrap Displays output on one line. Corresponds to a value of OFF in the
WRAP OUTPUT field in the EFD graphical setup.
-channels_on | -channels_off
Specifies whether channel numbers are displayed in the datalog.
Corresponds to the CHANNELS field in the EFD graphical setup.
-usage Displays a summary of the filter command line options.
<stdf_file_name> Is the path and file name of the input STDF file.
For more information on the options in the EFD graphical setup, see “Datalog Format Items”
on page 6-22.
The message area of the window displays suggestions on what you should do. (You can
change this text. See “Changing Disk Monitor Window Text” on page 6-88.) The window
footer displays error messages with handler status on the left and looping status on the right.
While the warning window is displayed, you can still type commands in the test station
window, and you can restart the test program. However, the disk monitor will stop the test
station if the amount of free space on the disk is at or below the limit.
NOTE
After the disk monitor stops a test window and you have cleared enough disk space to
continue, you must dismiss the warning window before using the test station. The disk
monitor will not allow further test program runs unless you dismiss this window.
You can specify the amount of disk space remaining and the frequency that disks are
checked before the disk monitor stops a test station by changing or creating the contents of
the diskmon_config file (see “Specifying the Disk Space Limit and Sampling Rate” on page
6-86). You can also change the warning message that appears in the window by editing or
creating the file image_disk_warning (see “Changing Disk Monitor Window Text” on page
6-88).
-on Turns the disk monitor on. You will see a message that the
monitor has started.
-off Turns the disk monitor off. You will see a message that the
monitor has stopped.
-show Displays all the active files and the current limits for disk
checking.
-usage Prints a usage message showing all parameters.
-reinit Reinitializes the disk monitor checking parameters (the limit and
sampling information). You will see a message that the monitor
has started. (See “Reinitializing the Disk Monitor” on page 6-87.)
The command diskmon -show displays whether the disk monitor is active and a list of all
active stations and their active file. The following is an example:
Total # of Active Files: 0 Total # of Active File Systems: 0
Checking Against Limit of 5120 KB remaining disk space
Checking Period Range: 5 Seconds to 40 Seconds
Summary Reports
A summary report provides a summary of the status of a device lot during or after testing. It
includes information on the number of devices tested, the number of devices sorted into
each bin, the number of executions for each test, and the failing percentage for each test.
IMAGE provides three types of summary reports:
• A partial summary is a report of a device lot before the completion of testing the lot.
• A final summary (figure 6-17) shows information for an entire lot of devices after testing
is complete.
• An accumulated summary shows summary information for two or more lots.
The basic summary mechanism in IMAGE is always active while a test program is loaded.
Unlike datalog, you need not turn it on.
Parts of a Summary
A summary report is composed of several parts:
• The summary header at the top of the report lists the lot, the operator, the time of
testing and other details. You can set some of these items using IMAGE commands.
(See “Organizing Test Data” on page 6-3.)
• The bin totals show the number of devices placed in the bins you have defined and the
percentage in each bin. Hardware bins (also called handler bins) are bins that
correspond to physical bins in a handler. Software bins are additional bins that you set
up that do not exist on the handler or prober you are using. (See “Assigning Bin
Numbers” on page 15-6.)
• The test summary shows the number of times each test in the test program was
executed and the number and percentage of failures.
Summary bin and fail counts are cleared when a test program is first loaded and at the
beginning of each lot. They are updated after each device is tested.
A device lot is closed when a device handler or prober or the Start Switch sends an endlot
signal to the tester, or when you a request a final summary report. Requesting a final
summary clears the bin and failure counters, resets the device number, and increments the
lot number.
Lot: xyz111
Sublot:
Started at: Mon Jan 29 14:19:56 1990
Program: cd1711
Version:
Part Type:
Operator: casper
Station Number: 1
Station Mode: E
Tester Type: A500
Node Name: mom5
Executive: IMAGE V3.0 012990
Test Code: R7J
Retest Code:
Handler or Prober:
DIB Type:
DIB ID: 0
the Properties window. This option does not affect how data is
collected.
-accum Generates and displays an accumulated summary for all full
device lots tested since the accumulation counters were
enabled. (See “Setting Up Accumulated Summary Reports” on
page 6-100.)
-auto Sends an auto endlot and generates a .summary file. Cannot be
used with -prev or -accum switches. (See “Automatic Summary
Reports Using the setauto Command” on page 6-96)
-final Generates and displays a final summary report. This switch also
closes the device lot, clears all counters, resets the device
number, and increments the lot number.
-partial Generates and displays a partial summary report.
-prev Displays the final summary of the last full lot tested. This is useful
if the last final summary report is lost after beginning to test the
next device lot.
-no_lot_incr Disables automatic increment of lot or sublot number at the end
of a lot when you specify -final. Can be used only with -final
or -auto.
Summary reports generated using the summary command are sent to a station window
(except for summary -auto, which is sent to a file). To send reports elsewhere, use Solaris
redirection operators (> and |). For example, to send a final summary report to a line printer
use:
summary -final | lpr
tl_summary Syntax
The tl_summary controls the summary from a test program. Arguments used by
tl_summary can be unsigned integer flags or character strings. Terminate the entire
argument list by NULL. The syntax is:
int tl_summary (unsigned int key …)
tl_summary() returns one of two values when called:
Arguments and parameters accepted by this function correspond to some of the parameters
and values accepted by the summary command. For example, the ACCUM argument
corresponds to the –accum parameter for the summary command.
This function is designed to accept a variable number of arguments (listed in table 6-11).
The two types of arguments are:
flags Indicate an on or off state for a particular parameter or that value
is being provided as the next argument. These correspond to
flag values for the summary command.
values These arguments are values for a particular parameter and must
immediately follow the parameter (flag) being used.
tl_summary Example
The following is an example of the tl_summary command. To print an accumulated
summary to a file, use the following syntax:
err = tl_summary(ACCUM, SMRY_FNAME, “my_accum_summary”, NULL);
Anytime you open the Auto-Summary Setup window, it displays the current datalog
information. If datalog information changes while the Auto-Summary Setup window is open,
however, the new information is not shown in the display. To update the Auto-Summary
Setup window (and all other open data windows), you must use the menu item
SETTINGS>REFRESH DISPLAY WITH DATA COLLECTION SETTINGS in the Data Collection Setup
display. (See “Control Panel Items” on page 6-15.)
The Auto-Summary Setup window includes the following items:
AUTO SUMMARY TO: STATION WINDOW
Sends the auto-summary to the station window.
AUTO SUMMARY TO: STDF FILE
Sends the auto-summary to an STDF file.
AUTO SUMMARY TO: TEXT FILE
Sends the auto-summary to a text file.
AUTO SUMMARY TO: LINE PRINTER
Sends the auto-summary to a printer. This is the default output.
NEW STDF FILE You cannot specify an STDF file name as IMAGE will try to
attach the summary information to the current STDF file output.
If you select an STDF as an output, you can set this control to
YES, and IMAGE tries to create a new STDF file if none exists. If
a current STDF file exists and you select YES, you end up with
two identical files. The default is YES. This item is grayed out
(inactive) if STDF is not selected as an output.
TEXT FILE NAME Specifies the name of a text file for output. Leaving this blank
causes IMAGE to select a default file name. This item is grayed
out (inactive) if a text file is not selected as an output.
PRINTER NAME Specifies a printer name for output. Leaving this blank causes
IMAGE to select the default printer.
TESTS Specifies ALL TESTS or FAILED TESTS ONLY. Selecting FAILED
TESTS ONLY produces a summary that only contains information
on devices that failed. The default is ALL TESTS.
SITE SPECIFIC SUMMARYSpecifies whether or not to generate a site-specific summary in
addition to the standard combined (merged) summary. (See
“Setting Up the Summary Site Data Mode” on page 6-102.)
FORMATTER Specifies STANDARD FORMATTER (SUMFMT) or CUSTOM
FORMATTER. The default is SUMFMT.
CUSTOM FORMATTER Specifies the name of a custom formatter. IMAGE searches for
this formatter using your current $PATH environment variable.
(See “Custom Summary Filters” on page 6-103.)
APPLY This button puts the current setup into effect.
RESET This button reverts to the previous setup (the setup before you
made any changes).
If you change the current setup, the message -- MODIFIED -- appears in the lower right
hand corner of the display.
To turn off automatic summaries, make sure no outputs are selected.
-all_tests Includes all tests in a summary report. You can set IMAGE to
include only failed tests using the Datalog/summary options in
IMAGE Properties window. (See “Datalog/Summary Options” on
page 3-38.) You can use this parameter to override the setting in
the Properties window. This option does not affect how data is
collected.
-fail_tests_only Includes only failed tests in a summary report. You can also set
IMAGE to include only failed tests using the Datalog/Summary
Options in IMAGE Properties window. (See “Datalog/Summary
Options” on page 3-38.) You can use this parameter to override
the setting in the Properties window. This option does not affect
how data is collected.
-sites Generates a site-specific summary, plus a combined summary
for all the sites. (The combined summary is the standard merged
summary.)
-merged Generates only the merged summary, the default unless
modified in the Auto-Summary Setup window (see figure 6-18 on
page 6-95).
-stdf_on Reverses the action of -stdf_off and allows IMAGE to create
summary STDF files.
-stdf_off Disables creation of an STDF file for summary records only.
Summary records are still written to open STDF files. This option
disables summary STDF file creation for all summaries,
including those created using the summary command
processor, until re-enabled using -stdf_on.
-autosum_off Completely disables generation of automatic summaries. Most
useful if many summaries are being generated during
engineering or debugging and if the summaries are not useful.
-show Displays the current destination and format for automatic
summaries in a station window. The default destination is the
standard printer and an STDF file. The default format program is
sumfmt.
-format <program_name>
Formats the summary report using a filter. The standard IMAGE
format name is sumfmt. You can also enter a custom formatter
name, and IMAGE searches for this name in $PATH. This option
requires that you specify a destination. If you do not, you get an
error message. (See “Custom Summary Filters” on page 6-103.)
-printer <printer_name>
Specifies an alternate printer to send the summary to.
-station # Specifies a station number to display the summary.
A final summary has four possible destinations: the station window, an STDF file, a text file,
and a printer. You can select any or all of these options.
When using the -lpr option, you can select an alternate printer for the summary sheet
using the -printer option. For example, the following command sends a summary report
to the station window and a laser writer (printer lw):
setauto -statwin -lpr -printer lw
The automatic summary feature is also useful for generating multiple final summary reports
when a lot is ended by an operator. To do this, you can use the command summary -auto
to generate an endlot report from the keyboard. When you issue this command, the display
shows:
Auto Endlot Occurred on station #<n> at <date and time>
tl_set_autosummary Syntax
The tl_set_autosummary controls the summary from a test program. You can use a
variable number of arguments, generally in pairs of the form:
<flag, argument>
Arguments can be unsigned integer flags or character strings. Terminate the entire
argument list by NULL. The syntax is:
int tl_set_autosummary (unsigned int key ...)
tl_set_autosummary() returns one of two values when called:
Like the setauto command, whenever this function is called it sets the auto-summary setup
to whatever criteria was used in the most recent call of the function. The AUTOSUM_OFF flag
cannot be used with any other parameter. It must be used alone. Example:
tl_set_autosummary(AUTOSUM_OFF, NULL);
The FAIL_TESTS_ONLY and ALL_TESTS flags cannot be used at the same time, that is, in
the same invocation of tl_set_autosummary.
Beyond these two exceptions there are no restrictions on the use of arguments. The
SMY_FORMATTER applies to formatted (ASCII) outputs (these are FILE, STATWIN, and
PRINTER).
tl_set_autosummary Examples
The following are examples of the tl_set_autosummary command.
To turn autosummary to the station window, file, and printer using printer speedy and
summary formatting process, my_formatter use:
err = tl_set_autosummary(SETAUTO_FILE,SETAUTO_STATWIN,
SETAUTO_PRINTER_NAME, "speedy",
SETAUTO_SMY_FORMATTER, "my_formatter", NULL);
Note that since the printer name for the summary is being specified, it is unnecessary to use
the SETAUTO_LPR argument.
To enable autosummary to an ASCII file called my_ascii_file and to the default line
printer, for failing tests only use:
err = tl_set_autosummary(SETAUTO_FILE_NAME, "my_ascii_file", SETAUTO_LPR,
SETAUTO_FAIL_TESTS_ONLY,NULL);
Again, note that since the name of the ASCII file for the summary is being specified, there
is no need to also use the SETAUTO_FILE parameter.
tl_set_accsum Syntax
The tl_set_accsum controls the accumulated summary report from a test program. You
can use the following arguments of type unsigned integer. The argument does not need to
be terminated by NULL. The syntax is:
int tl_set_accsum (unsigned int key)
tl_set_accsum() returns one of two values:
tl_set_accsum Example
The following is an example of the tl_set_accsum command. To enable the accumulated
summary counters, use the following syntax:
err = tl_set_accsum(SMY_ASUME);
INCLUDE MULTI-SITE RECORDS, like the -site_recs switch, generates site-specific summary
records in addition to the IMAGE standard combined site records.
MERGED DATA RECORDS ONLY, like the -no_site_recs switch, generates only the
combined site records. Once set, all future summary generation will be affected by which
mode has been chosen.
For example, if MERGED DATA RECORDS ONLY is chosen, you cannot generate site-specific
summaries by using the -sites switch to the summary or setauto commands because
none of the records required for site-specific summaries will be in the information stream.
where # is the number of the station window in which the test program was run. See
$IMAGEBIN/custom/sum_filters/README for more information on creating custom
summary filters.
You can also set checkpoint frequency from a station window using the command summary
-smy_checkpoint #. (See “Using the summary Command” on page 6-91.)
Summary Statistics
Summaries can include statistical information about each test, including the mean, standard
deviation, (one, three, and six) sigma values, Cp, and Cpk. This option can be used with
datalog enabled or disabled.
Cp and Cpk are indices used to measure process capability.
Cp is the specification width divided by the process width. For example, if Cp = 1.0, the
process width equals the specification width. If Cp = 2, the process specification width is
twice the process width. Cp does not take into account any noncentering of process relative
to the specification limits.
Cpk includes noncentering of process relative to specification limits. For example, a process
may have a Cp = 2, but if the center of this distribution (the mean) is not centered on the
target value (or the center of distribution), Cpk is < Cp. If the process is perfectly centered,
Cp = Cpk.
Calculation for Cp or Cpk requires that both upper and lower test program limits be present
and remain constant during execution of the program. If either limit is not specified, Cp or
Cpk is not calculated. If the program changes either limit during a particular lot, the
calculation for Cp or Cpk is invalidated and not printed. No message is printed on the
summary sheet informing you of this, and Cp or Cpk simply vanishes.
Statistical information can be calculated and displayed on the summary sheet at the
beginning of a lot using the startlot -fullstats on command. This command enables
statistics at the start of a particular lot. Use the command startlot -fullstats off to
disable statistics at the start of a particular lot.
If a test has one result or no result, no statistics are printed because the statistics are
meaningless. No warning message is printed.
accurate_eeprom_strings
The two possible values for accurate_eeprom_strings are enable and disable. In
IMAGE V6.4 and later, the default value is enable. This option allows you to choose
whether to use the older, previous definitions for certain datalog fields in IMAGE or the
newer, more accurate and consistent definitions now available.
Regardless of how this option is set, you can use the functions
tl_read_and_set_dib_info() and tl_read_and_set_prb_info() to get the new
behavior. The IMAGE Behavior Chooser option setting (enable or disable) only affects the
behavior of the older functions tl_write_dib_id_to_stdf() and
tl_read_probe_card(), which you should no longer use unless you want the older
behavior.
When accurate_eeprom_strings is enabled, the following fields can be set:
Sets These
This Function From This Format
Variables
Formatted ASCII for the dib_typ and prb_typ fields can be selected by using one of two
parameters in the call to tl_read_and_set_dib_info() or
tl_read_and_set_prb_info():
Parameter Format
EEPROM_LONG_STRING 876-543-21 (5445 [TE]) 9701-B.P1
EEPROM_SHORT_STRING 87654321
In this example, the Board Type is 876-543-21, the Company ID is 5445, which is ASCII for
TE (Teradyne’s company ID), the Revision Code date is 9701, and the Artwork Revision
Code is B.P1.
For compatibility, the following functions work as described below:
Function Will Call
tl_write_dib_id_to_stdf() tl_read_and_set_dib_info(EEPROM_LONG_STRING)
tl_read_probe_card() tl_read_and_set_prb_info(EEPROM_LONG_STRING)
All four variables, dib_typ, dib_id, prb_typ, and prb_card, are available for display in
showlot, the Station Monitor (statmon), and summary reports.
Sets This
This Function From This Format
Variable
NOTE
These functions can only be called before the first sequencer starts. If called after, no set is
done, an error is returned, and an error message is generated.
Test Head
tl_dib_typ[ ] / tl_prb_typ[ ] tl_dib_id[ ] / tl_prb_card[ ]
Type
tl_get_dib_typ()
tl_get_dib_id()
tl_get_prb_typ()
tl_get_prb_card()
Each of the four global variables is stored in the Site Description Record (SDR) in the
following location:
tl_dib_typ[] --> SDR.dib_typ[]
tl_dib_id[] --> SDR.dib_id[]
tl_prb_typ[] --> SDR.card_typ[]
tl_prb_card[] --> SDR.card_id[]
You can connect up to two Real Time Yield Trend Monitors to a single station window and
have up to eight yield charts displayed on each monitor. Each chart is individually set up
with respect to the data shown on the X and Y axes. You control the layout of the chart by
indicating what you want displayed horizontally and vertically.
ADD Allows you to add charts to your display. Click SELECT to add
the first chart listed. Press MENU to select one of the following
chart options:
DEVICE YIELD BY DEVICES
DEVICE YIELD BY WAFER
DEVICE YIELD BY LOT
BIN YIELD BY DEVICES
BIN YIELD BY WAFER
BIN YIELD BY LOT
TEST YIELD BY DEVICES
TEST YIELD BY WAFER
TEST YIELD BY LOT
Device yield is calculated by taking the number of devices that
pass and dividing by the number of devices tested.
Bin yield is calculated by taking the number of devices in
specified bins that pass and dividing by the total number of
devices in all bins.
Test yield is calculated by taking the number of devices that pass
specified tests and dividing by the total number of devices for all
tests.
After you select a chart option, the Yield Chart Properties
window is displayed (see “Yield Chart Properties Window” on
page 6-118). This window allows you to modify the chart
properties before adding the chart to the display.
EDIT Edits the properties using the Yield Chart Properties window.
Click SELECT to edit the properties of CHART A, or press MENU
and choose a different chart.
DELETE Removes charts from the display. Click SELECT to delete Chart
A, or press MENU to select a different chart. Display is redrawn
when a chart is deleted.
QUIT Quits the Real Time Yield Monitor display.
NOTE
Loading a setup file deletes all the currently displayed charts.
Setup files have a .yld filename extension. These files are ASCII files. Editing them directly
(using a text editor) is not recommended.
This window allows you to easily set up the Yield Monitor program to display the desired
charts, without needing to add new charts and set up their individual chart properties.
The Display Properties panel allows you to adjust the number of devices per cell and the
orientation of the charts. It has the following controls:
DEVICES PER CELL Changes the number of devices shown on the X axis. If you are
using more than one chart, the number of devices is changed on
all charts.
CHART LAYOUT Allows you to display charts either horizontally or vertically when
using multiple charts. HORIZONTAL displays the charts side by
side. VERTICAL displays the charts one on top of the other.
Figure 6-24. Yield Display Properties Window Showing the Display Properties Panel
The Default Chart Properties panel in the Yield Display Properties window (figure 6-25)
allows you to specify default values for all charts. Changing default chart properties does
not affect the current charts being displayed. However, it does affect the default values used
the next time the program is run. This panel has the following controls:
# OF CELLS Specifies the number of cells to show on the X axis.
GRAPH STYLE Allows you to show individual bars or a cumulative graph or both.
Y AXIS HIGH LIMIT Specifies the highest value displayed on the Y axis.
Y AXIS LOW LIMIT Specifies the lowest value displayed on the Y axis.
YIELD UPPER CONTROL LIMIT
Specifies upper control limit used to identify a yield problem.
YIELD LOWER CONTROL LIMIT
Specifies lower control limit used to identify a yield problem.
Figure 6-25. Yield Display Properties Window Showing the Default Chart Properties Panel
5. Add a second chart to your display by clicking MENU on the ADD menu item and
dragging to DEVICE YIELD BY LOT.
This adds a second chart to the display that shows device yield as each lot completes.
The second chart is labeled Chart B. It inherits the Y axis limits and the control limits
from Chart A, see figure 6-28.
6. Begin testing devices and observe the yield in the display. As each lot ends another bar
is added to Chart B indicating the yield for that lot.
7. Save the chart setup to a .yld file. Select FILE>SAVE SETUP.... In the Yield Display Save
Setup window enter a file name and location and click SAVE.
To use the saved chart setup to configure other charts, select FILE>LOAD SETUP... . The
Yield Display Load Setup window appears. From the DIRECTORY and FILE menu buttons,
select the .yld file with the desired setup and click LOAD. The setup file defines the
individual chart properties that the yield monitor program uses.
Histogram Plots
IMAGE includes a histogramming package as a standard data analysis tool. This tool allows
you to collect test results in a standard test data format (STDF) disk file and later plot the
distribution of these results as a histogram. You can print histogram plots as high-definition
plots in a Histogram Tool window (see “Histogram Tool” on page 6-124). You can also print
them as ASCII plots in any station window (see“Generating ASCII Histograms” on page
6-135). A histogram plot also produces statistics about the results, such as the mean and
standard deviation.
To produce a histogram use the following steps:
1. Set up histogramming to collect results from the desired tests.
2. Run the test program to generate and collect data.
3. Process the data and generate the histogram plots.
The histogram capability comprises setting up the data collection for a histogram (step 1)
and generating the plots (step 3). You can perform each of these steps using either a
window-based method or a command line method. The window-based utilities are the Data
Collection Setup display and the Histogram Tool. Their command line counterparts are the
histoset and histoplot commands. (See also “Two General-Purpose Histogram
Functions” on page G10-1 for another histogramming technique.)
off. (See “Control Panel Items” on page 6-15 for a listing of control panel buttons in this
display.)
Histogram
items
The Data Collection Setup display includes the following histogram items:
HISTOGRAM: OFF/ON Shows whether histogramming is enabled or disabled. Press
MENU and select from the menu to change.
NOTE
The option ON, APPEND TO FILE and the FILE field do not appear in the Data Collection Setup
display in IMAGE V5.7 and later.
-samprate # Set the sampling rate for histogram data. (The default is 1—
every device sampled.)
-samplimit # Set the sampling limit for histogram data. (The default is no limit.)
-show Display the current histogram setup in the station window.
-station # Specifies a station number to collect histogram data.
-off Turns histogramming off.
The following examples show examples of histoset commands:
• Collect test results for test ALPHA on every device:
histoset -on -test list ALPHA
• Collect test results for all tests at every fifth device until data on 1000 devices has been
collected (that is, until 5000 devices have been tested):
histoset -on -test all -samprate 5 -samplimit 1000
NOTE
Each time histogram data collection is enabled (or the test selection is changed), the data
file is reset to begin collecting data for the specified setup, unless the setup was specified
as ON, APPEND TO FILE. The previous data file (if any) is renamed <filename>% (note the %).
Data Output
When histogramming is turned on (test result data is being collected), the test results
collected are by default sent to a disk file called:
node_station#_<test_program>_<lot_id>_timestamp.histo
An example file for lot #23 for the program volt_reg2 run on node constance would be:
constance_1_volt_reg2_23_feb16_09:57.histo
These histogram files conform to the Teradyne STDF format and are created in the directory
where the test program was loaded.
The histogram tool stores one part’s worth of data in a buffer so that it can detect retests.
Each time you test a part, the tool compares the current data with the previous part’s data
in the buffer. If the current part is a retest, the previous data is discarded.
Generating Histograms
Once you have turned histogramming on and collected data in an STDF file (by running a
test program), you can plot a histogram. IMAGE has two utilities to analyze data and
construct histogram plots: the Histogram Tool (histodisp) and the histoplot command
for ASCII displays. These utilities allow you to specify:
• A single test for a histogram plot (for any test for which data was, or is, being collected)
• The number of histogram cells to be plotted
• Whether the Y axis should display percent or absolute counts
• That the first N results for a test are to be ignored (used for ignoring devices at the edge
of a wafer)
• Plot limits to limit the baseline axis of the plotted histogram (control the visible range of
the data plotted)
• Population limits to determine the statistical significance of a result (whether or not it will
be included in the mean and standard deviation calculations)
• The full-scale percentage for the Y axis of the plot
• A cumulative percentage line for the plot
• An STDF file to be processed
These utilities automatically look for an STDF file when invoked under IMAGE. Histograms
can be plotted while data is being appended to the file. You can use this to examine a
snapshot of the data distribution at any point during testing.
Real-Time Histogram
In addition to plotting from a file, you can use the histodisp utility to connect to a station
while running a test program and analyze the data in real time (while parts are being tested).
When running histodisp in real-time mode, the tool collects all test data while parts are
being tested. This includes all tests in the test program (not only the test being viewed). You
can change the test number to view different distributions. You can also view test results
specific to a particular site or bin or both.
In real time mode, you must specify:
• Tests using test numbers (rather than test names)
• A station number to connect
• The frequency at which the display should be refreshed
Histogram Tool
The Histogram Tool (histodisp) is a window-based interface to the histogramming
function (figure 6-30). Features of this window utility include:
• High-resolution graphics
• The ability to send a “snapshot” of the plot to a file
• The ability to specify that the test limits be used to limit the baseline axis of a plot
Control Panel
Statistical area
Display area
Message area
NOTE
Disconnecting from a station causes all data collected by the histogram tool to be lost.
PLOT Click SELECT on this button to plot the current test. Press
MENU to display the Plot file history menu. This is a list of the
histogram files that have been loaded in the display. If you select
a file from this menu, it is loaded in the display and plotted. When
the histogram tool is in real-time mode this button is grayed out
(inactive).
Plotting a Histogram
To plot a histogram:
1. Load a histogram file into the Histogram Tool window. Do this in any of the following
ways:
a. Select FILE>LOAD. This displays the Load window (figure 6-31) and allows you to
load a file from any directory.
b. Select FILE>READ FILE, then pull right. This displays a menu of all the .histo and
.stdf files in the current directory and allows you to load one of these files.
c. Press MENU on the PLOT button. This displays a history menu of all files that have
been loaded into the display and allows you to select one, load it, and plot it.
2. Enter a test name or test number in the TEST field. If you do not specify a test and try to
plot, an error is displayed.
3. Enter or change any of the optional histogram parameters using selections in the VIEW
button menu.
4. Click PLOT. IMAGE retrieves test results for the test you specified and plots a histogram.
LOAD... Load the specified file into the histogram window. When you
select this option, the Load window is displayed (figure 6-31).
Select a directory and a file and click LOAD FILE.
READ FILE Read the specified file from the current directory into the
histogram display. Pull right on the selection to display the list of
available .histo files in the current directory.
SEND PLOT TO FILE... Send the current plot on the display to a file you specify. The plot
must first have been generated before it can be sent to a file. The
output is the same as the histoplot output, an ASCII plot.
When you select this option the Save window appears (figure 6-
32). Select a directory and click SELECT on SAVE FILE.
SHOW: TEST LIMITS Display the test limits. If selected, lines representing the test
limits are drawn on the plot. The plot is not resized to show test
limits outside the plot limits. (Default is not selected.)
SHOW: CUMULATIVE% Display the cumulative percentage curve on top of the
histogram. If displayed, the corresponding axis is displayed on
the right side of the plot and is always labelled in percentages
from 0% to 100%. (Default is not selected.)
NOTE
The cumulative percentage always represents the displayed data, not all data within the
population limits.
BAR: SHADED/STRIPED/HOLLOW/SOLID
Display the bars of the histogram as shaded (gray, as in figure 6-
34), striped, hollow (unfilled), or solid (black). (The default is
shaded.)
GRID: ON Display display horizontal grid lines. (The default is not selected.)
REFRESH AFTER...RESULTS
This setting specifies the number of parts that will be tested
before the tool updates the display. The default value is 5.
Setting this to a smaller value results in the display being
updated more frequently. This field only affects real time mode.
• Test limits are used if you choose the PLOT USING: TEST LIMITS option from the Display
settings window.
• If a test limit is not set, the corresponding plot boundary (plot high or low limit) is used.
• If a plot boundary is not set, the corresponding population limit is used.
• If the population limit is not set, the minimum (or maximum, whichever is appropriate)
test result value is used.
In theory, a limit that is not set implies that the limit is infinity (which is what is shown in the
statistics region), but this is not a plottable value.
Zoom Bars
Figure 6-35. Placing Zoom Bars on Histogram Plot (top) to Generate New Plot of Selected Area (bottom)
If you use only one bar, the plot zooms in on the area to the left of the bar.
You can also place plot limits by entering values into the PLOT LIMIT fields and clicking PLOT.
You cannot drag the left zoom bar over the right one (or the right one over the left) since
one bar is automatically dropped as the other is picked up. This preserves the right and left
handedness of the bars.
To remove a bar, place the pointer on it and press SELECT. Move the bar left or right out
of the display. The bar disappears.
To display the full plot again, unselect the high and low plot limits in the PLOT LIMIT fields
and click PLOT.
NOTE
The cumulative percentage always represents the displayed data, not all data within the
population limits.
BAR>SHADED/STRIPED/HOLLOW/SOLID
Display the bars of the histogram as shaded (gray, as in figure 6-
34 on page 6-130), striped, hollow (unfilled), or solid (black).
(Default is shaded.)
GRID>ON/OFF Display display horizontal grid lines. (Default is OFF.)
REFRESH AFTER...RESULTS
This setting specifies the number of parts that will be tested
before the tool updates the display. The default value is 5.
NOTE
The cumulative percentage always represents the displayed data, not all data within the
population limits.
.................................................................
. H I S T O G R A M R E P O R T .
.................................................................
- DISTRIBUTION STATISTICS -
Lower Pop Limit= -Infinity Upper Pop Limit= +Infinity
Total Results= 24 Results Accepted= 24
Underflows= 0 Overflows= 0
Mean= 32.5 Std Deviation= 1.03799
Minimum Value= 30.3 Maximum Value= 33.82
- PLOT STATISTICS -
Lower Plot Limit= 30.3 Upper Plot Limit= 33.82
Cells= 15 Cell Width= 0.234667
Full Scale Percent= 33.33% Full Scale Count= 8
The histoset and histoplot commands work independently. Therefore, you can be
running a test program and collecting data and still generate “intermediate” (snapshot)
histogram plots using histoplot.
The Station Plot window automatically fills in the FILENAME field on the window if the
histogramming is activated. It also copies the first test listed in the histogram criteria test if
it is filled in. You can change either of these items.
You can only specify one test to display in the station window.
Once you choose the filename to plot from and the test you wish to plot, click the PLOT
button. This creates the ASCII plot in the station window.
-hard_bin <integer>
Specifies a hardware bin. (See “Assigning Bin Numbers” on
page 15-6.)
-soft_bin <integer>
Specifies a software bin to be displayed. (See “Assigning Bin
Numbers” on page 15-6.)
-pop <LOW> <HI> Specifies low and high limits for data used in calculating the plot.
LOW and HIGH can be specified as two floating point values or as
X for none. (Default is minus and plus infinity.)
-plot <LOW> <HI> Specifies low and high boundaries for the plot. LOW and HIGH can
be specified as two floating point values or as X for none. (Default
is minus and plus infinity.)
-skip <integer> Skip the specified number of results at the beginning of the data
file.
-station <integer> Specifies a station number to display the plot.
-testlimits Use the test limits to limit the X axis. This overrides any plot limits
you may also have specified.
-site <integer> Selects the site in a multisite test program.
-sigmas <integer> Selects the number of sigmas (from 1 to 20) to plot around the
mean. (Default is 3.)
To send a plot to a file or to a line printer (or anywhere but the station window), include
Solaris redirection operators in the command.
The following are examples of histoplot commands:
• Plot a histogram of test 25:
histoplot 25
• Plot a histogram of test 25 and limit the highest result plotted (not the statistical values)
to 5.25:
histoplot 25 -plot X 5.25
• Print a histogram of test 25 on the line printer:
histoplot 25 | lpr
• Plot a histogram of test 25 with 30 cells:
histoplot 25 -cells 30
This would result in a merged file containing more occurrences of one test than certain
other tests.
IMAGE includes a debugger for developing, debugging, and modifying test programs. The
debugger supports incremental edit and recompile, setting breaktraps, and immediate
commands. When you enter debug:
• A source window (figure 7-1) appears. This window is where the test program you
loaded in the station is displayed and edited.
• The station window displays a third row of buttons in its control panel. These buttons are
used to control debug functions.
• The DISPLAY button on the station window control panel is activated. This provides
access to a variety of debug displays covering test system functions and instruments
and functions.
This section discusses editing, debugging, and recompiling test programs. It includes the
following topics:
• “Entering Debug” on page 7-2
• “Using the Source Window” on page 7-5
• “Viewing Test Programs” on page 7-7
• “Breaktraps” on page 7-11
• “Editing and Compiling Functions” on page 7-23
• “Manipulating Test Program Files” on page 7-31
• “Exiting Debug” on page 7-37
• “Standalone IMAGE Compiler” on page 7-38
• “Libraries” on page 7-45
• “Switch Variables” on page 7-46
• “Debug Displays” on page 7-47
• “Interactive Debug Displays” on page 7-49
• “Variables Display” on page 7-56
• “Immediate Commands” on page 7-64
Entering Debug
You can enter debug in several ways:
• When creating a new test program:
– Check NEW FILE in the Load test program window. (See “Loading Using the Load
Window” on page 5-2.)
– Enter the command load -new. (See “Loading Using the load Command” on page
5-4.)
• When loading an existing test program:
– Check DEBUG in the Load test program window. (See “Loading Using the Load
Window” on page 5-2.)
– Use the LOAD AND ENTER DEBUG option in the LOAD button pull-right menu. (See
“Loading Using the Load Window” on page 5-2.)
– Enter the load -debug command. (See“Loading Test Programs” on page 5-2.)
– Enter the load -tl_init_debug command to debug the optional test-program
function, tl_init(). (See“Loading Using the load Command” on page 5-4.)
• After loading a test program:
– Enter the debug command in a station window.
– Click the DEBUG button.
The debug command has the following syntax:
debug [-source <dir>] [-station #]
where:
-source <dir> Specifies the location of the source files.
-station # Specifies the test station to use for debug.
Namestripe
Control Panel
Text pane
Source
window
Message area
Source
window
icon
You must have a program loaded to enter debug. The debug command fails if source files
for a loaded program cannot be located or if source files have changed since the binary was
loaded. Source files from a test program are assumed to be in the same directory as the
binary files.
If source files are in a different directory, you must specify that directory to the debugger.
Do this using the command debug -source <dir> or, when loading the program, you can
use the -source option of the load command. Use multiple -source parameters if all the
source files that make up a test program are not in the same directory. Source directories
are searched in the order listed.
You can determine if a station window is in debug using the command:
station_info -debugmode
See “Displaying Station Window Information” on page 3-14 for more information on the
station_info command.
Changing files can affect immediate commands, since the header section of the current file
is used by the compiler when executing these commands. (See “Immediate Commands” on
page 7-64.)
You can also list function by typing the list command in a station window. The list
command has the following syntax:
list [-xref | -files | -sort | <filename>]
where:
-xref Displays a cross-reference listing all global variables and
functions in the test program.
-files Lists all the files that constitute a program but not the functions
in those files.
You can also determine the number of a test program line using the VIEW>WHAT LINE
NUMBER?. To determine a line number, click on a line (or click SELECT and ADJUST to
select several lines). Then select VIEW>WHAT LINE NUMBER?. You see a box with a
message similar to this:
Selection begins in line 24.
Press "Continue" to proceed.
Breaktraps
You can request that a test program stop at specified lines in a program or under certain
program conditions. Such stop points are called breaktraps. When a program has stopped
for a breaktrap, you can examine variables or hardware or execute immediate commands.
If a program is stopped for a program fault or user interrupt by CONTROL-C, you can execute
immediate commands or print commands. But if the program is stopped for a fault, it cannot
be continued. You can distinguish between these states by the shading of the breaktrap
arrow. (See “Stepping Through a Test Program” on page 7-16.)
Setting a Breaktrap
You set traps using the SET menu button in the station window control panel. This button
has the following menu:
TRAP ON SELECTED LINE
Stop the test program at the selected line. (This is the default.)
TRAP IN FUNCTION Stop the test program at the selected function.
TRAP ON TEST Stop the test program at the selected test.
TRAP ON FAILED TEST Stop the test program at the first failing test.
TRAP ON PASSED TEST Stop the test program at the first passing test.
TRAP ON PATTERN START
Stop the test program at the beginning of a digital pattern. (Used
to debug a digital pattern.)
TRAP ON ALARM Stop the test program at an alarm.
TRAP ON READ METER Stop the test program at a read meter statement.
TRAP ON RUN TIME ERROR
Stop the test program at a run-time error. (See “Setting
Breaktraps on Run-Time Errors” on page 7-13.)
TRAP ON TEST NUMBER Stop the test program at the selected test number.
LIST TRAPS List all traps set in the test program.
To set a line number trap using the mouse:
1. Make the test program line you want visible in the source window.
2. Select (highlight) any character in the line by clicking SELECT at the beginning and
ADJUST at the end of the selection.
You can also set traps by typing the settrap command in the station window. This
command has the following syntax:
settrap [-function <func>] [-line <line>] [-test] [-failedtest] [-passedtest]
[-patternstart] [-alarm] [-readmeter] [-error] [-test <number>]
where:
-function <func> Stops the test program at function <func>.
-line <number> Stops the test program at line <number>.
-test Stops the test program at the selected test.
-failedtest Stops the test program at the first failing test.
-passedtest Stops the test program at the first passing test.
-patternstart Stops the test program at the beginning of a digital pattern.
-alarm Stops the test program at an alarm.
-readmeter Stops the test program at a read meter statement.
-error Stops the test program at a run-time error.
-test <number> Stops the test program at the specified test number.
Sometimes the trap does not appear on the line you specify. This is because not all source
lines have executable code. Exactly which source lines are trappable is not always obvious.
(See “Breaktrap Placement” on page 7-21.) If the line specified cannot be trapped on,
IMAGE selects the next trappable line and sets the trap there. If the program contains no
further trappable lines, it is an error.
Listing Breaktraps
List the current traps set, including the trap numbers, using the SET>LIST TRAPS selection.
When you issue this command, a list of current traps and the current state of the program
similar to the following is displayed in the station window:
Program is stopped in function vout1() at line 97
->trap 1: function vout1 line 97: "set meter input:pin = vout src:v;"
You can also list traps using the listtrap command. The syntax is:
listtrap [-current]
where:
-current Changes the output format of the trap list to a form that can be
executed as a command file.
You can use the listtrap -current command to save breaktraps by first listing and
directing the output to a scratch file. Then you can restore them by executing that scratch
file. For example, to save your breaktraps to the test program file saved_traps use:
listtrap -current > saved_traps
You can then log off and leave your station. When you return, reload using:
Deleting Breaktraps
To delete breaktraps, use the UNSET button in the station window control panel. Press
MENU on UNSET to display the following menu:
UNSET AT SELECTED LINE
Delete the trap at the selected line. (This is the default for the
UNSET button.)
NOTE
The IMAGE debugger does not support running to breaktraps during multi-threaded
execution. The debugger runs programs single-threaded if you use one or more breaktraps
and run to trap.
Figure 7-4 on page 7-12 shows the source window stopped at a trap with the arrow next to
the stop sign. When you singlestep with step or next commands, the arrow follows the path
of execution.
This section describes commands you can use to run a test program with breaktraps.
or the station ABORT button will stop the test program right where
it is.
You can also enter the runtotrap command in the station window. This command has the
following syntax:
runtotrap [-station #] [-retest] [-nostats] [-loop] [-args ...]
where:
-station <#> Specifies the station number to run the test program.
-retest Retests the device using the same serial number.
-nostats Suppresses printing run-time statistics for the test program after
the run.
-loop Reruns the test program until either a breaktrap is encountered
or the program experiences an exception of some sort (such as
a run-time error or a SEGV). This parameter works with other
runtotrap command options. A CONTROL-C in the station
window or the station ABORT button stops the test program right
where it is.
-args ... Pass one or more parameters to main(). (See “Passing
Command Line Parameters to main()” on page 5-23.)
NOTE
The function tl_read_char_nowait can cause a problem during debugging. If you are
stopped in a trap and step into this function, you will lose IMAGE and have to reboot.
Whenever a program stops at a breaktrap, the source window changes to display the trap
and an arrow appears next to the trap. If a program stops because it has run to trap or
because you have used the step or next commands, the arrow is hollow with a white
outline. If it stops from using CONTROL-C, a program fault, or a run-time error, the arrow is
solid and grey.
Thus, the arrow tells you whether the program is active or not. If the arrow is white it is
active, and you can use the cont, step, or next commands or examine hardware or look
at local variables. If the arrow is gray, it is inactive and you cannot use cont, step, or next;
power is turned off to the DUT. (This may indicate a run-time error.)
Another command you can use to change the display is VIEW>TRAP ARROW TO TOP in the
source window. If you are stopped at a trap, this command changes the display to put the
trap arrow to the top of the window, changing files if necessary.
Each function in a function calling sequence is called a “frame.” For instance, main() calls
aa(), which calls bb(), and the program stops in bb(). In this case there are active frames
for main, aa, and bb. Each time a test program stops, at a trap or for some other reason
(such as a CONTROL-C or a SEGV), IMAGE sets the “current frame” to the stopped frame.
The IMAGE debugger includes commands that allow you to move within a function-calling
sequence in a test program. The up command allows you to move up in the sequence. The
down command allows you to move down. You must type these commands. They are not
available as buttons.
Each up command resets the current frame to the previous calling frame which is a user
function and highlights the source line for that frame. The next up command moves the
current frame one more user frame and highlights that source. The where command shows
a > at the start of the where output line which is the current frame.
The down command works in reverse. Each down command moves the frame toward the
stopped function.
If you use up at the top frame (main()) or down at the bottom frame, the current frame text
is highlighted again without error.
Figure 7-5. Station Window and Function Keys Window Showing Key Functions
You can disable these key functions if you wish to use the keys in other ways. Select GLOBAL
STATION WINDOW OPTIONS from the IMAGE Properties window and set ENABLE FUNCTION
KEYS to FALSE. (See “Global Station Window Options” on page 3-34.)
Breaktrap Placement
Where can you place a breaktrap? Generally, the ending semicolon of an ITL statement is
the trappable symbolic line number for that statement. When a statement extends over
several source lines, the trap point is on the line containing the semicolon of the statement.
You can trap on the “return” statement of a function or the closing curly brace of a function
which does not return a value. If the function returns a value, a breaktrap on the closing curly
brace will not be hit.
You can also set traps on an initialized automatic variable declaration. (The act of assigning
a value to the variable is executable and so trappable.)
SEQUENCER functions have a line of “invisible” executable code (code not displayed in the
source window) on the same line as the opening brace of the function. If you step into the
function, you will stop at that invisible line before stepping to your own visible line.
When you set a trap on a for() statement, the program traps on the initialization part (the
first part) of the statement.
You cannot set a breaktrap at an end brace with a return(val) statement. If you place a
breaktrap on the closing brace of a function, it will not be hit if an explicit return statement is
executed.
When a program is edited, traps do not “move.” That is, IMAGE tries to associate each trap
with the text of the line on which the trap originally appeared. (However, always check the
locations of breaktraps after editing.)
If a function is deleted, all traps in it are deleted.
As you edit, IMAGE can compile your changes incrementally, reducing the time needed to
edit and compile files. The debugger also keeps an edit history of your changes, allowing
you to undo changes. For instance, you can command the debugger to revert to an older
version of a program. You can also save the current state of a test program on disk at any
time while in debug.
When you finish editing and exit the editor, the new source is compiled and linked into the
test program. You must save (or discard) changes when exiting debug. (See “Exiting
Debug” on page 7-37.)
Compiling Changes
Test programs, either new programs or edited programs, must be compiled before they can
be run. Use the COMPILE menu button in the source window control panel to compile test
programs. You can also type the compile command in the station window.
NOTE
A test program must be compiled (or recompiled if it has been edited) before it can be run.
QUIT (IGNORE EDITS) Exit the editor and do not save any edits made to the test
program.
The file header (the top of the file containing macro definitions, declarations, and so on)
must compile correctly before file functions can compile. Therefore, you may see the
following message when compiling if the header has errors:
Cannot compile. Bad header section.
You must correct the errors before other functions in the file can be compiled.
Header files should not contain definitions of variables, only declarations. That is, a header
file can contain extern int i; but should not contain int i;. Loading a header file
containing variable definitions gives a warning.
If you exit the editor without compiling and the file contains certain errors, functions with
these errors cannot be compiled. If you try to compile, the following message appears:
Errors after line #. Cannot compile.
You must correct these errors before the functions will compile.
Incremental Recompiling
IMAGE includes an incremental recompile feature. With this feature, you make edits to a
program loaded in the station window. Then, when you edit a program, only those functions
you changed are recompiled. This speeds up the edit/recompile/run cycle.
In general, you recompile each function as you edit it. Editing comments between two
functions does not cause the functions to be recompiled, but editing comments within a
function does. When recompiling a function, any static variables declared in the function are
reinitialized to the initial value following the equal sign or to zero if no initial value is
specified.
Editing global variables in the header causes all global variables to be recompiled. When
recompiled, initialized variables (variables followed by an equal sign) are reinitialized to the
specified initial value, but uninitialized variables (variables not followed by an equal sign)
retain their current value.
NOTE
Uninitialized variables always start with a value of zero. They are initialized to zero when the
test program is loaded or when a new variable is created while editing.
Some changes made while editing cannot be handled incrementally because they cause
global changes. These changes include edits to:
• A pinmap
• A header file
• A macro definition (#define)
Duplicate Compiling
At times, the compiler may behave as if it is compiling a function more than once. The
standalone compiler (itlc) only compiles each function once. (See “Standalone IMAGE
Compiler” on page 7-38.) The compiler used during edit/recompile, however, occasionally
compiles a function more than once. The following example functions show why this may
happen:
int func1()
{
double d;
d = func2();
}
double func2()
{
return 2.0;
}
If both functions in this example are not compiled, func1 is compiled first and then func2 is
compiled as a result of either the compile or exitedit command. When func1 is compiled
the compiler does not know the type of the return value of func2 and, therefore, assumes
that it returns an integer. When func2 is compiled, the compiler learns that func2 returns a
double. Since func1 references func2, it must be recompiled. IMAGE, therefore,
invalidates the first compile of func1 and compiles it again.
This recompile results from not declaring functions before referencing them. In standard C
when this situation occurs, func2 must be declared at the top of the file using extern
double func2();. IMAGE does not require this.
NOTE
IMAGE V5.0 and later does not support Sun3 test systems.
To use this feature, keep the different binaries in separate subdirectories below the test
program directory. Name the subdirectories sun3, sun4, and/or sun4V. Commands that
read or write test program files (load, itlc, load_file, chfile, save, and store)
automatically read or write binary files from or to these subdirectories.
Architecture and operating system specific files are kept in the sun3, sun4, and sun4V
subdirectories. Architecture- and operating-system-specific files are files with these
extensions:
.bin Binary test program files.
.a Library files (created with the ar command or itlc -archive).
.o Object files (created with the cc command or itlc -ofile).
.exec Special binary files used for test system checkers only.
Other files, such as .tl, .load, .pat, .wav, and .h, are independent of the computer
architecture and operating system. Their location is not affected by the machine type or
operating system, so they are kept in the main test program directory. In general, whenever
a filename is specified, the name is changed if the following criteria are met:
• The name ends in .bin, .o, .a, or .exec
• A sun3 subdirectory exists if running on a SUN3
• A sun4 subdirectory exists if running on a SUN4 (SPARC) under OS 4.1
• A sun4V subdirectory exists if running on a SUN4 (SPARC) under Solaris 2
• A sun3, sun4, or sun4V subdirectory is not already specified in the filename
Examples:
• If using itlc to compile x102.tl on a SUN3 system, the binary is written to sun3/
x102.bin if the sun3 subdirectory exists.
• Executing load x102 mylib.a on a SPARC system running OS 4.1 reads sun4/
x102.bin and sun4/mylib.a if the sun4 subdirectory exists.
• Executing load x102 on a SPARC system running Solaris 2 reads sun4V/x102.bin if
the sun4V subdirectory exists.
• Executing either load /h/green/harry/job/x102 or load /h/green/harry/job/
sun4/x102 results in the file /h/green/harry/job/sun4/x102.bin being read,
assuming the command is executed on a SPARC computer running OS 4.1 and the
sun4 subdirectory exits. Note, however, that in the first case the source file is assumed
to be in /h/green/harry/job, but in the second case it is assumed to be in /h/green/
harry/job/sun4.
In a debug session, after making source-level changes, the changes are usually compiled
and the binary saved. This only updates binaries for the architecture or operating system of
the machine used during the debug session. To update binaries for another architecture or
operating system, log in to a machine of the other architecture or operating system and use
itlc to compile. You can specify the name of a .load file to itlc to simplify compiling all
files in a test program.
Use the rlogin command to log in to another machine without leaving your workstation.
You cannot accidentally use an out-of-date binary file. The load command checks that the
binaries being read are up to date and rejects any that are out of date with respect to the
source files.
In one case, however, this consistency check does not take place. This is if you load a test
program in production (not using the -debug switch), and the source files are not available
to the load command. The source files are not available if the load command cannot find
them in the directories used to load the test program and you do not use the -source option
to specify the location of the sources. The -source option, in a .load file, allows you to
specify additional directories in which to look for source files. (See “Loading Using the load
Command” on page 5-4.)
NOTE
A test program must be compiled (or recompiled if it has been edited) before it can be run.
QUIT (IGNORE EDITS) Exit the editor and ignore all changes made to the test program.
The test program remains as it was before entering the editor.
You can also display this menu using the EXIT EDITOR command in the source window pop-
up menu. Place the pointer in the text pane of the source window and press MENU. Select
EXIT EDITOR and pull right to display the menu.
You can also exit the editor by typing the exitedit command in the station window. This
command has the following syntax:
exitedit [-quit] [-nocomp]
where:
-quit Exits the editor and ignores all changes made to the test
program. The test program remains as it was before entering the
editor.
-nocomp Exits the editor regardless of errors and does not compile the
test program.
-change_name Saves the source and binary of the test program to a new file
called <filename>.
Storing a test program writes a copy of the source and binary of the test program file to a
filename different from the filename used when loading the program. You can use this to
save a temporary copy of a file on disk without changing the original program files or to put
a file in a different directory. If the specified filename contains an extension (.h, .tl, .c, or
.bin), only the source or binary is written, but not both. If you do not specify an extension,
the source is written to <filename>.tl and the binary is written to <filename>.bin. To
store a header file, you must use the .h extension.
Use the STORE>USE NEW FILENAME FOR SAVE option or the command store -change_name
to change the name of a currently loaded file as well as saving it. When you use this option,
the file is written to the specified filename, and in addition the file is now known by this new
name in the loaded test program. If you made no edits to other files in the test program, the
(EDITED) message in the station window header stripe is removed because all changes are
now saved to disk. You can now delete the test program without using the -nosave option
since all edits are saved. If you make additional edits and use save, the new changes are
saved to the new filename.
When using this option, do not specify an extension unless you are saving a header file.
Both the source and binary files will be written (.tl and .bin). If saving a header file, use
the .h extension.
This option is especially useful when working with released test programs whose files are
write-protected. You can make a change and save it as a new version of the program in one
of two ways:
• Use the EDIT -NOSAVE menu item or command and edit the write protected file. Then use
the CHANGE NAME OF CURRENT FILE AND SAVE menu item or the store -change_name
command to save the changed file to a new name.
• Use the USE NEW FILENAME FOR SAVE option in the Store window or the store
-change_name command to create a copy of the write-protected file. Edit the file. Then
use SAVE to save your changes.
With either method, you now have both the original version of the program and the modified
version on disk. Note that if you use a .load file, you must copy this and edit it by hand.
STORE writes binaries to separate SUN3 and SUN4 (SPARC) OS 4.1 and SUN4 Solaris 2
directories if they exist. (See “Managing Binaries for Different CPU Types or Operating
Systems” on page 7-27.)
Listing Versions
Edit history versions are numbered starting at 1. Use the VERSIONS>LIST VERSIONS to
display a list of all edit history versions. An example would be as follows:
EDIT HISTORY ( ==> - Current version D - Saved on disk)
D 1 09:42 (Original program.)
2 12:25 (Prior to loading 'pinmap.h'.)
==> 3 12:25 (After loading 'pinmap.h'.)
...Changes have been made to version 3.
You can also type the versions command in the station window. This command has the
following syntax:
versions [<from> [<to>]] [-fdiff | -diff [-context]]
where:
<from> Specifies the starting version of the list.
<to> Specifies the ending version of the list.
-fdiff Lists all test program functions that have changed.
-diff Lists any differences between two versions.
-context Puts context lines around changed lines. (Used with -diff.)
If the history list is large, you can use the command:
versions [<from> [<to>]]
to specify a starting and ending version to display a part of the list. The list of versions
indicates which version is current, whether changes have been made to that version, and
which version is stored on disk.
The command versions -fdiff lists the names of all functions in the program that have
changed between the versions, as in:
FUNCTIONS CHANGED FROM VERSION 3 TO CURRENT VERSION.
File: pinmap.h
HEADER
The command versions -diff runs the Solaris diff program on two versions of the
current file (the file displayed in the source window) and displays any lines that have
changed. This output can be redirected to a file.
The command versions -diff -context changes the format of the output and puts lines
of context around the changed lines.
By default, the differences shown are the changes made to the program since the last
version. If no changes were made since the last version, the differences shown are the
differences between the last two versions. To see differences between two other versions,
you can specify one or two version numbers. If you specify one number, the difference is
between that version and the current state of the program. If you specify two numbers, the
difference is between those two versions.
Loading a File
While in debug, you can load a file that exists on disk but is currently not a part of the loaded
test program. (This is similar to using the chfile command with the name of a file that exists
on disk but is not currently a part of the loaded test program.)
To load a file:
1. Select FILE>LOAD FILE. The Load File window (figure 7-8) appears.
2. Select the directory and filename.
3. Click on a check box to select options: NEW loads a new file; RELOAD loads a file that was
already loaded; FORCE reloads the file, discarding any edits.
4. Click LOAD FILE.
The NEW option allows you to start a new file not currently on disk. If the file exists, an error
message is issued.
The RELOAD option reloads a file already loaded. This command fails if edits were made to
the file in the station window.
The FORCE option forces reload of a file, discarding any edits and overwriting the file using
the file on disk. This option is most useful when using a tool external to the station window
that modifies the source files, such as an automatic program generation tool that writes
source files.
You can load a file by typing the load_file command in the station window. This command
has the following syntax:
load_file <filename> [-reload [-force] | -new]
where:
<filename> Specifies the file to load.
-reload Reloads a file already loaded.
-force Reloads a file, discarding any edits and overwriting the file on the
disk.
-new Loads a new file.
This command also loads the appropriate binary for separate SUN3 and SUN4 (SPARC)
OS 4.1 and SUN4 Solaris 2 directories if they exist. (See “Managing Binaries for Different
CPU Types or Operating Systems” on page 7-27.)
Exiting Debug
Once you are in debug, the DEBUG button in the station window changes to EXIT DEBUG. To
exit debug, click this button. If you have unsaved changes, you are warned. At this point,
you can either save your edits or exit without saving.
You can also exit debug using the exitdebug command. The syntax is:
exitdebug [-nosave] [-station #]
where:
-nosave Exits debug without saving any edits.
-station # Specifies a test station to use for exiting debug.
You cannot exit debug if you are editing a test program. You must exit the editor first. (See
“Exiting the Editor” on page 7-29.)
When a station is not in debug, the loaded program must be identical to the one on disk.
Therefore, if you edited the test program but have not saved the edits, typing the exitdebug
command in a station window fails. (Clicking on the EXITEDIT button prompts you to save or
not save your edits.) At this point you can do one of the following:
• Save your changes using the SAVE command in the editor.
• Return to the version last saved using the revert command.
• Type exitdebug -nosave or click on EXIT DEBUG and select to ignore any changes at
the prompt. This discards the changes and reverts the program to match the version
already on disk.
• Stay in debug.
Some IMAGE commands take a station out of debug: DELETE (command or station window
button) and the imageexit command or EXIT on the IMAGE Workspace menu. If a loaded
program has unsaved edits, you are prompted to save the edits or to exit without saving.
-lint Used to check IMAGE test programs for bugs and nonportable,
wasteful code. You can also define -lintflags to modify the
parameters of the -lint switch. (See “Using Lint” on page 7-40.)
Important differences between compiling files in the debugger and compiling them with itlc
are:
• Both itlc and the compiler used in the debugger allow forward references of functions
and global variables, both within files and between files, without explicitly declaring
these as extern. However, itlc can only handle references to other files mentioned to
the itlc command.
• When itlc is compiling a file and an error is detected, it continues to compile the file,
except for certain classes of errors. (The debugger aborts the compile at the end of the
function with the error.) This allows you to produce a partial object file (one containing
binary code for a subset of a file’s functions). You can load partial object files into the
debugger using the -debug switch of the load command.
Forcing Compilation
The -force option causes itlc to compile all files listed regardless of whether binary files
exist for them or whether those binary files are up to date. Without -force, itlc does a
consistency check for each file having a binary file. If the binary file is consistent (matches
its source file), itlc prints a message to that effect and does not compile the file.
Diagnostic Messages
Unlike the Solaris C compiler and similar to the interactive debugger compiler, itlc
produces diagnostic output for each file it compiles, even if no errors are found. Diagnostic
output for a successful compile looks like this:
...reading file myprog.tl
...compiling file myprog.tl
...compiling HEADER
...compiling main
.
.
These messages indicate how far the compilation has proceeded and also help in
determining where errors occur. Errors look like:
<stage>: "<filename>", line <number>: <message>
where:
<stage> Indicates the part of the compile that encountered the error.
Possible stages include: splitfmt, cpp, tlp, and ccom
(Solaris1) or acomp (Solaris2).
<filename>/<number>
Is the name of the file with the error and the line it appears on.
<message> Is the explanation of the error.
An example is as follows:
tlp:"tms_demo.tl", line 120: comma operator in expression
NOTE
The Sun3 is not supported in IMAGE V5.0 and later.
Using Lint
You can use lint to check IMAGE test programs for bugs and nonportable, wasteful code.
lint issues an error or warning if it finds any of these conditions in a test program. You can
use lint if you are running the Solaris 1 or 2 operating system. For more information on
lint, see its man page in the Solaris environment.
To run lint on a test program, use the itlc command followed by the -lint switch, as in:
itlc -lint file1.tl file2.tl file3.c
itlc outputs the following:
The default lint flags are the lint flags itlc uses if you do not specify the -lintflag
switch. These flags are described below for both the Solaris 1 and 2 operating systems.
Solaris 2 operating system flags are as follows:
-h Do not apply heuristic tests that try to intuit bugs, improve style,
and reduce waste.
-m Suppress complaints about external symbols that could be
declared static.
-u Suppress complaints about functions and external variables
used and not defined or defined and not used. This option is for
running lint on a subset of files of a larger program.
-x Do not report variables referred by external declarations but
never used.
Solaris 1 operating system flags are:
-u Do not complain about functions and external variables used and
not defined or defined and not used. This is for running lint on
a subset of files comprising part of a larger program.
-v Suppress complaints about unused arguments in functions.
-z Do not complain about structures that are never defined (for
example, using a structure pointer without knowing its contents).
NOTE
When Teradyne forces all files to be recompiled, both itlc and the IMAGE load
mechanism enforce this. If, however, files are compiled into .o or .a files, this cannot be
enforced, and it is your responsibility to recompile the files.
If a subroutine aa() exists in file1.tl, and this file has been compiled into mylib.a as in
the above command, and there is a test program prog.tl which calls aa(), then file.tl
will be linked and aa() resolved with the load command line:
%load prog.tl mylib.a
If mylib.a is being shared among many users or among many work directories, use a full
file specification.
If you try to compile a SEQUENCER function into a .o or .a file, you get incorrect results when
running a test program. Therefore, if you try to use itlc to compile a SEQUENCER function
into a .o or .a file you get an error message.
Libraries
The library command allows you to list the libraries IMAGE searches to resolve
unresolved references for the currently loaded test program. The command has the
following syntax:
library [<filename> ...]
This command without parameters lists current libraries. (If no test program is loaded, you
get an error message.) The following is a sample list:
smith% library
Library 1: /image/bin.5.0/libdummy.a
Library 2: /image/bin.5.0/libitldrivers.a
Library 3: /image/bin.5.0/liba5drivers.a
Library 4: /image/bin.5.0/libdrivers.a
Library 5: /image/bin.5.0/libsimdummy.a
Library 6: /image/bin.5.0/libsim.a
Library 7: /image/bin.5.0/libutil.a
Library 8: /image/bin.5.0/libshmoo.a
Library 9: /image/bin.5.0/libmathadv.a
Library 10: /image/bin.5.0/librs232.a
Library 11: /image/bin.5.0/libhandler.a
Library 12: /image/bin.5.0a/m218/libs/handler/libm218handler.a
Library 13: /image/bin.5.0/libmter.a
Library 14: /image/bin.5.0/libcter.a
Library object file: /image/bin.5.0/link_always_a500.o
Library object file: /image/bin.5.0/imagemain.o
You can add a new library to the list of libraries searched while in debug by using the
library command followed by the name of the library.
Switch Variables
Switch variables are variables with preset names that are always linked to a test program.
Unlike other variables, their values can be displayed and set using debug commands. Sixty-
four switch variables are available, all of type int. They are named switchvar_1 through
switchvar_64. To use them, you must declare the ones you use as extern in the header
section of your file. The command to display or set switch variables is:
switchvar [<variable #>[=<value>]] [-station <#>]
where:
<variable #> Specifies a switch variable number from 1 to 64.
<value> Specifies a value for the switch variable.
-station <#> Specifies a station window.
With no arguments, this command prints out the values of all switch variables. If you specify
one or more variable numbers, the contents of the specified variables are printed. For
example switchvar 2 prints out the current setting of the variable switchvar_2.
To set a switch variable, use the syntax:
switchvar <variable #>=<value>
For example, switchvar 4=100 sets the variable switchvar_4 to the value 100 in the test
program. Multiple settings and readings are possible with one command. For example,
switchvar 1 2 3 4=5 prints out the settings for variables 1, 2, and 3, and also sets variable
4 to the value 5.
Switch variables can be used outside the debugger. They are often used to set the “mode”
a test program runs in, or as a way of turning on and off some special test-program function.
For example, you could include code in a test program which checks the value of a switch
variable and uses this to determine whether to write out test data files for the run.
You can also set switch variables to a particular value when loading a test program using
the command load -switchvar_<i> #. See “Loading Using the load Command” on page
5-4.
Debug Displays
Debug displays are programs that display, and can sometimes change, the current state of
a test program and tester hardware. They receive new data from the tester after every
immediate, run, cont, step, or next command.
You can invoke debug displays only when a station is in debug. To invoke a display, press
MENU on the DISPLAY button in the station window and select a display from the following
menu:
PROGRAM DEBUG> Brings up general displays used in debugging including the
Immediate, Variables, Sync Pulse, and Simulator Database
displays. (See “Immediate Commands” on page 7-64, “Variables
Display” on page 7-56, and “Simulator” on page 12-1.)
INSTRUMENTS> Brings up instrument debug displays.
DIGITAL TOOL EXEC... Brings up the Digital Tool Executive. (See “Digital Tool
Executive” on page 12-1 in the IMAGE Software Tools Manual.)
PATTERN TOOLS> Brings up digital pattern displays.
DIBVIEW... Brings up the DIBView tool. (See “DIBView” on page 2-1 in the
IMAGE Software Tools Manual.)
SHMOO... Brings up the Shmoo tool. (See “Shmoo Plots” on page 9-1 in the
IMAGE Software Tools Manual.)
MARGIN... Brings up the Margin display. (See “Margin Testing” on page 8-1
in the IMAGE Software Tools Manual.)
SMITH DISPLAY... Brings up the Smith display. (See “Using the Smith Display Tool”
on page 20-38 in the Catalyst Instrumentation Manual.)
CALIBRATION TOOLS... Brings up the RF Calibration tools. (See “Calibrate Fixture Tool”
on page 23-25 in the Catalyst Instrumentation Manual.)
DATASHEET> Brings up the Datasheet windows. (See “Datasheet Tool” on
page 7-1 in the IMAGE Software Tools Manual.)
TEMPLATES... Brings up the Templates Tool window. (See “Digital Templates”
on page 6-1 and “Wireless Templates” on page 5-1 in the IMAGE
Software Tools Manual.)
TEST ANALYZER... Brings up the IMAGE Expert Test Analyzer. (See “IMAGE Expert
Test Analyzer” on page 16-1 in the IMAGE Software Tools
Manual.)
WAVEFORM... Brings up the Wave display. (See “Wave Display” on page 10-1
in the IMAGE Software Tools Manual.)
WAVEFORM ANALYZER...Brings up the Waveform Analyzer. (See “Waveform Analyzer” on
page 11-1 in the IMAGE Software Tools Manual.)
Note that some of these menu choices only appear only if you have a compiled test program
loaded.
You can also bring up a debug display by typing its program name in a station window.
Instrument Displays
Catalyst and Catalyst Tiger station windows have separate debug display menus. The
menu for each type of tester includes the appropriate instrument and digital pattern tools for
that tester. Instrument displays, pattern tools, the Sync Pulse display, and Tester Setup
display are described in the instrumentation and test-head manuals for each type of test
system.
Create an .enterdebug file using the debugplaces utility. This program examines the
contents of the screen and prints out a listing of the debug displays currently running, with
their positions. To create your own .enterdebug file:
1. Load a test program into the debugger.
2. Bring up any debug displays you want.
3. Type the command debugplaces. This prints out the information that must go in the
.enterbug file.
4. cd to your home directory.
5. Type debugplaces > .enterdebug.
For example, you may have the tester setup, variables, and waveform displays in iconic
form on the screen. If you type debugplaces, you might see:
setupdisp -Wp 18 190 -Ws 577 285 -WP 256 0 -Wi
vardisp -Wp 36 72 -Ws 577 285 -WP 136 0 -Wi
wave -Wp 108 100 -Ws 423 437 -WP 0 0 -Wi
If you put this list into your .enterdebug file, the next time you enter debug the same
displays will appear in the same sizes and in the same positions.
The Low Frequency Source (lfsrc) on the AC Instrument Setup display (vbacdisp) is used
to illustrate examples in this section. Figure 7-9 shows this display with interactive
parameters highlighted.
Figure 7-9. AC Instrument Display of Low Frequency Source, Interactive Parameters Highlighted
Choice Selections
Many instrument programming parameters are choices of one of several possible
selections. The Low Frequency Source low-pass filter (LPFILT), for example, can have nine
different values or be bypassed. Anything that can be expressed this way is implemented
as a choice-panel item.
To see all the choices, press MENU and move the pointer to the desired choice. You can
also use SELECT to cycle through all the choices. Pressing SELECT previews the next
choice, and releasing the button selects it. (If you press SELECT and decide the next choice
is not the one you want, move the pointer off the item entirely. The item remains
unchanged.)
NOTE
Toggling through the selections actually programs each selection momentarily and may,
therefore, cause run-time errors as other programmed parameters become “out of range.”
A choice item may appear as words, such as in ACLOCK:A0, or as a picture, such as an open
or closed relay.
Sometimes the same parameter appears more than once on the display. For example
LOCALGND is shown both as ON/OFF and as a relay. When either is programmed, both
change.
Push-Buttons
The third type of user interface is the familiar panel button. These are used to initiate
actions, such as starting and stopping an S_MEM, and are identified by the familiar button
image. If the button has an arrow, press MENU to bring up a menu (usually containing
variations on the function). Selecting something from the menu executes the command.
Clicking SELECT chooses the first item in the menu. If there is no menu, click SELECT to
initiate the action.
DC Matrix Connections
Some displays include a special item which allows connections to the DC matrix, identified
by a DC MATRIX label which has a menu behind it listing possible DC connections. Press
MENU and select an instrument to connect or disconnect it. The DC MATRIX label changes
to show which instrument is connected.
To support having more than one instrument connected, the menu displays a check mark
to show the instruments currently connected. If you have connected more than one, the
label changes to read <N> DC CONNS. to tell you how many matrix connections you have
made.
Custom Interfaces
Some instruments have parameters that do not fit well into any of the above programming
models. In these cases, custom panel items are used. These are explained in the sections
about the individual instruments’ displays.
Color Support
Display items appear in color if you are running IMAGE on a color monitor. Items are shown
in one of three colors:
• Stored. The item state does not differ from the stored state. The default color is blue.
• Running. The display is executing a command. The default color is firebrick.
• Modified. The item is not currently running and its state differs from its stored state. The
default color is yellow.
The highlight state of a display item does not affect the color. In other words, if the highlight
selection is currently ALL INTERACTIVE PARAMETERS, each item appears inverted in whatever
color applies to its state. If the highlight selection is currently DIFFERENCES FROM STORED
STATE, all modified items appear inverted in the modified color. All other items appear
normally in their appropriate color.
You can change the default colors of display items using IMAGE Properties. (See “Setting
IMAGE Properties” on page 3-34.) The procedure for display color defaults is as follows:
1. Select PROPERTIES>IMAGE PROPERTIES from the IMAGE Workspace menu. The
Properties window appears.
2. Press MENU on the CATEGORY menu button at the top of the window and select COLOR.
The color properties page appears.
3. Click SELECT on MODIFY. The Color Manager window is displayed.
4. Press MENU on the menu button and select a property from the menu.
5. Click SELECT to select a color.
6. Click SELECT on the APPLY button to confirm your choice.
The display colors are also listed in the .Xdefaults file in $IMAGEBIN/custom as the
following entries:
color.stored
color.running
color.modified
The display highlights all differences between the current state and the stored state.
This feature is useful during debugging sessions to look for instrument setup errors. First, it
can help you to verify that all differences between two instrument setups are intentional.
This procedure is valuable when debugging two similar tests where one is working and the
other is not.
Second, you can compare displays of different instruments at the same or different points
in the test program. Click STORE while looking at one instrument, SELECT the other
instrument, and highlight differences. This only works for comparing copies of the same
instrument (such as two DC Sources).
Error Conditions
When running interactive displays, several error conditions can occur. These are described
in the following sections.
Run-Time Errors
As with test-program statements, interactive display commands can try to put an instrument
in an invalid state. When such a run-time error occurs, the default behavior is:
• The run-time error message appears both in the footer of the display and in the station
window.
• The default error handler or a user-defined error handler (if one is set in the program
using set error handler=<function>;) is called. (See “Intercepting Errors in a Test
Program” on page 15-32.)
• The test program stops, the test system is reset, and the program must be rerun to a
trap (stop on fail termination mode). If the program is set to continue on error
mode, the program remains at the trap.
You can change the way displays handle run-time errors using the IMAGE Properties
window. Select the Miscellaneous page of that display and modify the property DEBUG
DISPLAY OPTIONS: ERROR HANDLING. (See “Miscellaneous Options” on page 3-36.) If you
change this option from DEFAULT to IGNORE, display-generated errors are now handled as
follows:
• The run-time error message appears both in the display footer and in the station
window.
• A user error handler (if installed) is not called.
• The test program is not reset (as with program termination mode continue on error).
The effect of ignoring run-time errors from the display is that any display errors will not stop
the test program.
Compiler Errors
When expressions are used in text items, the text is error-checked by the IMAGE compiler
in the same way as if it were compiled as part of the test program. If any errors occur, such
as undefined variables or values out of range, the first compiler error that would occur is
shown in the message region of the display.
Variables Display
The Variables display (figure 7-10) is a window that shows the current values of variables in
a test program. The display is refreshed with the latest data whenever the program changes
state (at each run, cont, step, next, or immediate command). This enables you to examine
the value of variables as you debug a program.
UNREQUEST Deletes variables from the display. Press MENU on this button
to display all the selected variables. Select the one to unrequest.
DECIMAL/OCTAL/HEX/BINARY
Change the radix in which variable integers are displayed. Press
MENU on the abbreviated menu button and select from the pop-
up menu. Default is DECIMAL. (See “Specifying the Radix for
Integers” on page 7-60.)
QUIT Quit the Variables display.
ARRAY LINES Specify the maximum number of array elements to display. (The
default is 4.)
REQUESTED ONLY Display only requested variables. (The default is all variables.)
ADJUST Have the display automatically position the view into the display
region to show the last changed variable. (The default is not
adjusted.)
SCALED/UNSCALED/EXTENDED PRECISION
Display variables as scaled (in scientific notation), unscaled, or
with extended precision. See “Scaling Variables” on page 7-59.
(The default is unscaled.)
When printing pointers, arrays, or structures whose elements are pointers, indirection is
limited to three levels. For example, a pointer to a structure (one of whose elements is an
array of pointers to character pointers) is expanded to only three levels of indirection.
Character arrays and pointers to strings are shown as strings.
Dynamically allocated arrays are usually pointed to by a pointer. The declaration is either of
the following:
int *arrayname;
int arrayname[];
rather than either of the following:
int arrayname[30];
int arrayname[]= {1,4,23,56,22};
One element or range of elements of such an array can be displayed using the same syntax
as in a normal array. The only difference is if the compiler does not know the size of the
array. Specifying only the name of the array, without any index, gives only the first element,
not the first four.
In the Variables display, DARRAYs are displayed as simple variables (ints), much the same
as it displays DSPBUFFERs or SEGMENTs. In the current IMAGE version, you cannot view
the contents of a data array in the Variables display.
Scaling Variables
Using the Variables display, you can display variables as scaled, unscaled, or with extended
precision. The PRINT command (see “Printing Variables in a Station Window” on page 7-63)
also prints variables to the station window in these formats.
Scaled variables are displayed as scaled to the nearest third exponent of 10 and printed with
the standard letter. Thus, 1.234E-8 would be displayed as 12.34N.
Extended precision scales the value to engineering units, and the value is output showing
18 digits for doubles and eight digits for floats. (Double variables have 56 bits of mantissa,
which can be expressed in 18 decimal digits. Float variables have 23 bits of mantissa, which
requires 8 decimal digits to represent.)
The following example uses scaled_pi as the variable and shows the effect on the output
using the print -xprec command:
double scaled_pi = M_PI * 1e-6;
float f_pi = M_PI;
print scaled_pi
scaled_pi = 3.14159e-06
print scaled_pi -xprec
scaled_pi = 3.1415926535897931160u
print f_pi
f_pi = 3.14159
print f_pi -xprec
f_pi = 3.14159274101
For the data type char, if you select the hex, octal, or binary radix, the char value is printed
first in ASCII, then in the selected radix. The following shows the variable byte_mask printed
as decimal, hex, and binary:
char byte_mask = 0x61;
print byte_mask
byte_mask = 'a'
print byte_mask -r x
byte_mask = 'a' 0x61
print byte_mask -r b
byte_mask = 'a' B 0110 0001
NOTE
When a program is not stopped, no automatic variable is active. If the variable was
requested, this is only an informative message.
Immediate Commands
To execute any ITL statement immediately without editing your test program, use an
immediate command. This facility allows you to quickly examine or change hardware and
call functions and to reference or change variables.
An “immediate” command is essentially a temporary test-program section consisting of one
or more statements. If the program is stopped at a breaktrap, you can reference local
variables. You can also call library functions not previously referenced and, therefore, not a
part of the program. The new library function is located and linked into the program when
the immediate command is executed. (Most tester instruments can also be programmed
using their interactive displays. See “Interactive Debug Displays” on page 7-49.)
You can also type the command immedwin in a station window. This command has the
following syntax:
immedwin [-station <#>]
where:
-station <#> Specifies a station window.
You can only use Immediate windows in debug, and only one can be used at a time. It
disappears automatically when you exit debug or delete the program.
The Immediate Window is a text window and can be manipulated like any other text window.
It can be stretched, moved, opened, or closed. The display region (where immediate
commands are displayed) has a pop-up edit menu for such things as splitting the screen or
finding selected text. The window control panel includes the following buttons:
NEW TEXT Execute an immediate command using the new text in the
immediate window. Click SELECT on this button after you enter
the text.
SELECTION Execute an immediate command using selected text in any
window. Click SELECT on this button after you select (highlight)
the text.
AGAIN Execute the most recent immediate command again.
STOP Stop the compile/execution of the immediate command.
To execute an immediate command, type in one or more statements and click NEW TEXT. Or
invoke the command by typing it in the window and pressing the escape key (ESC). All text
following the last --- IMM --- prompt is used (if the window is set to display prompts). This text
can include multiple lines and multiple statements. The text executed is highlighted in
reverse video. While the immediate command is being compiled and run, the bottom portion
of the window displays the message STATE: RUNNING. This message is removed when
execution is complete.
If the text you want to execute is not at the end of the immediate window, you can select it,
then execute it by clicking SELECTION. For example, if you type a complicated immediate
command in the window and it contains errors, you can edit it in place, select it, and click
SELECTION. (You can also select the text, put it on the shelf, get it back at the end of the
window, edit it, and press F1 key or click on NEW TEXT.) Again, when the STATE: RUNNING
item disappears from the bottom portion of the window, and a new prompt appears, the
command is complete.
If you get errors from immediate commands invoked by either of these methods, the error
messages appear in the immediate window. The line number of the error message
corresponds to the window the text was in. Usually, this is a line number in the immediate
window. However, the text can come from a different window. For example, you can select
a statement in the source window and click SELECTION. The line numbers in any error
message refer to the lines in the source window. This allows you to select the number, go
to the window the text came from, and find the line with the error using the VIEW>SELECT
LINE AT NUMBER in the source window.
Immediate commands are like small test programs. Therefore, any output from immediate
commands goes to the station window. If you execute printf statements, the text appears
in the terminal pane of the station window. If you execute a sequencer statement, any
datalog values are output to the station window (unless otherwise specified).
To stop an immediate statement, you can either type CONTROL-C or click SELECT on STOP.
This stops the immediate command as fast as the CONTROL-C can get through, whether it
is compiling, executing, or just partially typed in.
Since the Immediate Window is a text window, you can edit in it. You can put and get
commands from other windows, save your immediate session to a file, or reset the text to
clear out old commands.
8 PRODUCTION ENVIRONMENT
IMAGE has two operating modes: engineering mode and production mode.
In engineering mode, the mode described throughout most of this manual, IMAGE operates
in a way which allows engineers the full capabilities of the window environment.
Production mode offers limited capability suitable for production operators. This mode alters
the windowing system and the way in which users interact with the tester (including whether
or not to use the mouse). This mode does not affect the tester or test programs.
The IMAGE production environment is designed to permit simultaneous testing of different
products in as many stations as the tester can accommodate. Interaction with the tester in
production mode is primarily through a handler or prober, with the keyboard being used for
brief periods of time for activities such as setting up lots. IMAGE also allows you to use the
keyboard to access the engineering capabilities of the tester while the test system is still
running in production.
This section describes invoking the environment and ways in which you can customize the
environment for production operators. It includes the following topics:
• “Features of the Production Environment” on page 8-2
• “Setting Up Files for the Production Environment” on page 8-4
• “Production Mode With Mouse” on page 8-5
• “Production Mode Using Menus” on page 8-15
• “Run-Time Error and Alarm Messages” on page 8-43
• “Setting Up Production Environment Defaults” on page 8-46
• “The Station Monitor” on page 8-49
Another type of production environment in IMAGE is also available. This environment,
called the Production Menu Control (PMC) system, offers greater programming flexibility
and additional menu features. For information on PMC, see “Production Menu Control” on
page 9-1.
Station Monitor
Station Window
NOTE
To log in to the operator2 account, you must type oper2. The shorter login name is needed
because the maximum length of an account name is eight characters.
engineering mode. If you have no account or type the incorrect password, the request is
denied.
Changing from engineering to production mode has no lockout.
NOTE
You cannot change to or from production mode on any station while any station is in debug.
If you try, IMAGE prompts you to exit debug.
RUN Run the loaded test program. This button also includes a pull-
right menu item, RETEST, that allows the operator to rerun the
program using the same device number.
Station Monitor
When you load and run a test program, a station monitor (see figure 8-2 on page 8-15)
appears in the upper left part of the workspace showing:
• Bin number for the device and site number (for a multisite test)
• Test program name
• Insertion
• Lot and sublot ID
• Number of devices tested and device number
• Software bin number (SBIN)
• Current yield percentage for all sites
• Cumulative yield percentage for all sites
• Numbers used to calculate the current and cumulative percents
To customize the station monitor, see “The Station Monitor” on page 8-49.
• Setting the operator name (see “Setting Lot and Sublot Using the lot Command” on page
6-9):
operator [<operator_name>] [-station #]
• Redrawing the screen:
refresh
• Selecting the station window to display:
select [-station # | -console] [-tester <test_name>]
• Showing the lot setup parameters (see “Displaying Lot Information” on page 6-11):
showlot [-station #] [-lotid | -program]
• Starting a new lot (see “Opening a Lot Using the startlot Command” on page 6-7):
startlot [-lotid <XX>] [-parttype <XX>] [-testcond <XX>]
[-operator <XX>] [-retestcode <XX>] [-supervisor <XX>]
[-jobrev <XX>] [-processid <XX>] [-noconfirm] [-nosummary]
[-show] [-station #] [-fullstats <on/off>]
When you issue a startlot command, you get a summary report for the previous lot
as if you had typed the command summary -auto. This default can be overridden using
the -nosummary option to startlot.
• Showing station window information, including whether the window is in production or
engineering mode (see “Displaying Station Window Information” on page 3-14):
station_info [-station #] [-mode] [-debugmode] [-program] [-type]
• Turning user power on or off (see “Controlling User Power” on page 5-28):
usrpower [-off | -on] [-show] [-station #]
• Reread the buttons file (production or engineering):
newbuttons [-station <snum>] [-all]
This can only happen when no test program is loaded in the station. If you specify the
-all switch, an attempt is made to reread the buttons files for all the currently existing
stations. However, only stations that do not have a program loaded are updated.
The layout of IMAGE production windows can be specified on a “per tester” basis using the
.production_window_info file. When first executed, IMAGE first searches for this file in
the /image/tester/<tester name>_s directory. If the file is not found there, IMAGE uses
the default .production_window_info file in the $IMAGEBIN/custom directory. Put
customized window information files in the /image/tester directory to assure the file is
used. This file specifies the production window layout of the entire tester, regardless of the
user executing IMAGE.
processed sequentially and each item appears in the window in that order. The keywords
used in the file are as follows:
INCLUDE Specifies the absolute pathname of a station button description
file to be read as if its text appeared at this point in this file. This
keyword allows you to put an engineering_station_buttons
file in your home directory which first includes the system-wide
file and then specifies only the additional custom buttons you
want.
Note that if the system-wide file includes the FONT keyword, as it
usually does, the INCLUDE statement which refers to it must
appear at the start of the user’s station_buttons file. This is
because no buttons can be created before the FONT keyword
appears.
Usage: INCLUDE <absolute path name>
Example:
INCLUDE /image/bin/custom
/.engineering_station_buttons
FONT Specifies the font to use for labeling station window buttons.
Usage: FONT <fontname>
Example: FONT /screen.b.16
GAP Specifies how may pixels to leave between rows of buttons. (The
default for engineering buttons is 10. The default for production-
window buttons is 32.)
Usage: GAP <integer>
Example: GAP 50
SPACE Specifies how many horizontal pixels to skip between buttons.
Usage: SPACE <integer>
Example: SPACE 20
NEWROW Defines the start of a new row of buttons. The number of rows is
unlimited, but note that additional rows will enlarge the height of
the control panel and decrease the size of the terminal pane.
Usage: NEWROW
Example: NEWROW
BUTTON Defines a button image, help string, and command to be issued.
Usage:
BUTTON "<label>" "<help string>"
<command>
Example:
BUTTON "Endlot" "Print a final summary"
summary -final | print
MENU/END Defines a button with a pull-right menu and the selections in that
menu. (Menus can be nested.)
Usage:
MENU "<menu label>"
"<selection label>" <selection command>
"<selection label>" <selection command>
: :
"<selection label>" <selection command>
END
Example:
# Define a "Select" Menu for selecting the
# console, OR station 1, 2, or Aux station 5
MENU "Select"
"Console" select -console
MENU "Station"
"Station 1" select -station 1
"Station 2" select -station 2
"Aux Station 5" select -station 5
END
END
NOTE
Comment lines can be added to a file by placing a # as the first character of the line.
Although you cannot change the functions of standard buttons, you can modify their
graphical features. You can specify button labels, fonts, and positioning using the keywords
described in “Changing the Station-Window Control Panel” on page 8-10.
To include or modify a standard IMAGE button, you must use the correct keyword listed in
table 8-1:
STANDARD_CONT_BUTTON STANDARD_HALT_BUTTON
STANDARD_COMMUNICATIONS_BUTTON
STANDARD_LOAD_BUTTON
STANDARD_RUN_BUTTON
STANDARD_LOOP_BUTTON
STANDARD_DEBUG_BUTTON
STANDARD_ABORT_BUTTON
STANDARD_HELP_BUTTON
STANDARD_CATD_BUTTON
#
# Define the second row of buttons
NEWROW
STANDARD_UPOWER_BUTTON
STANDARD_DATAC_BUTTON
STANDARD_DISPLAY_BUTTON
STANDARD_USER_BUTTON
STANDARD_PROD_ENG_BUTTON
STANDARD_CHECKER_BUTTON
################################################
# DEBUGGER BUTTONS - SHOULD ALWAYS BE LAST
################################################
NEWROW
STANDARD_TOTRAP_BUTTON
STANDARD_SETTRAP_BUTTON
STANDARD_UNSET_BUTTON
STANDARD_STEP_BUTTON
STANDARD_NEXT_BUTTON
STANDARD_CONT_BUTTON
STANDARD_HALT_BUTTON
# If the 'disappearing' print button is undesirable,
# It can be removed and replaced with ...
# BUTTON "print" "Print value of selected variable" print "$SELECTION"
STANDARD_PRINT_BUTTON
##################################################################
########################## E O F #########################
##################################################################
Station monitor
Station window
The .login file for the production mode account determines the type of production operator
interface used. To set up your test system for production mode without the mouse, you can
either instruct operators to log in under the operator2 accounts, or you can create new
accounts and copy the operator2 home directories to your new accounts. The new
accounts need new entries to the password file, /etc/passwd.
NOTE
You cannot change to production mode from any station while any station is in debug. If you
try, IMAGE prompts you to exit debug.
Station Monitor
When you load and run a test program, a station monitor window (see figure 8-2) appears
in the upper left part of the workspace showing:
• Bin number for the device and site number (for a multisite test)
• Test program name
• Insertion
• Lot ID and sublot ID
• Number of devices tested and device number
• Software bin number (SBIN)
Main Menu
The Main menu consists of the following items:
MAIN MENU:
(1) DISPLAY CURRENT SETUP
(2) DISPLAY TEST HEAD CONFIGURATION
(3) DELETE CURRENT SETUP
(4) SELECT TEST PROGRAM
[5] SELECT HANDLER/INSERTION
(6) SELECT LOT ID
TESTING-IN-PROGRESS OPTIONS
Brings up a submenu, including a selection that enables the
handler or prober to begin testing, as well as items that can be
executed while testing is in progress. Items include:
(1) BEGIN TESTING
(2) SUSPEND TESTING
(3) PRINT PARTIAL SUMMARY TO LINE PRINTER
(4) DISPLAY PARTIAL SUMMARY ON SCREEN
(5) FINAL SUMMARY
(H) HELP FOR THIS MENU
[Q] QUIT MENU
TESTER UTILITIES Brings up a submenu with the following items:
(1) CHANGE STATION NUMBER
(2) CHANGE TO ENGINEERING MODE
(3) EXIT TESTER EXECUTIVE
(4) RE-INITIALIZE TESTER HARDWARE
(5) VIEW UNIX CONSOLE
(6) TERMINATE MENU INTERFACE
(H) HELP FOR THIS MENU
[Q] QUIT MENU
CHANGE TO ENGINEERING MODE and TERMINATE MENU INTERFACE
prompt you for a password.
Selecting Stations
Select or change stations from the Main menu or from the Tester Utilities menu by selecting
CHANGE STATION NUMBER. When you select a new station, IMAGE switches to the new
station. You can also see the console window by selecting VIEW UNIX CONSOLE from the
Tester utilities menu.
Setting Up a Lot
To set up a lot of parts for testing, use the following procedure:
Partial Summaries
While a lot is being tested, you can request partial summaries by selecting the PRINT PARTIAL
SUMMARY item. Partial summaries have no effect other than to show a snapshot of the lot
results at the time of the request.
Closing a Lot
When a lot is complete, select the FINAL SUMMARY item from the TESTING IN PROGRESS
menu. This item closes the lot and prints a final summary. After the final summary is printed,
you can either test a new lot of parts or change the setup for a different type of parts. If the
new lot of parts uses the same test program, handler, and fixtures, only the lot ID needs to
be changed. If the setup must be changed, you must clear the current setup by selecting
DELETE CURRENT SETUP from the Main menu.
Any characters after a #, but up to the next newline, are considered to be comments. White
space (spaces, tabs, and newlines) is allowed between keywords.
The following conventions are recommended for use when developing menu description
files:
• Menu names are lower case
• Environment variables are all upper case
• A tab is four spaces
• Indent one tab setting within clauses with curly braces ({})
• Within a MENU_ITEM definition, HELP appears before the COMMAND definition
• Within a file, environment variable declarations appear first, followed by the STARTUP
and MENU_DEFAULTS clause, and then the MENU definitions. The top-level menu is
defined last.
TITLE
An example of a menu option is the TITLE option:
TITLE <string_specifier>
This item specifies the title to display for this menu. The title is the text printed above the list
of menu selections. The argument to this option, <string_specifier>, can be either a
single double-quoted string followed by a semicolon, or a list of double-quoted strings
enclosed in curly braces ({}). Examples of legal string specifiers are:
TITLE "this is one line";
TITLE {
"this is the first line"
"this is the second line"
}
HELP
A second option is the HELP option:
HELP <string_specifier>
Use this option to specify the strings printed if you ask for help while this menu is being
displayed. The <string_specifier> argument uses the same format as described above.
For example:
MENU empty_menu {
TITLE "Title goes here";
HELP {
"This menu contains commands which"
"allow you to ..."
}
<menu items>
}
MENU_ITEM
The most important options in a MENU clause are the ones that determine the appearance
and function of the individual selections (or “menu items”) in the menu. For each selection
in a menu, a MENU_ITEM clause is defined. This clause is made up of the keyword
MENU_ITEM, followed by the name and then a series of optional keywords or clauses
surrounded by curly brackets. For example:
MENU dummy {
MENU_ITEM "<name>"{
HELP <string_specifier>
COMMAND {
<list of commands>
}
}
}
When the menu is printed so you can make a selection, the <name> string is printed as the
text that describes the item.
COMMAND
The COMMAND section lists the commands executed when you choose that menu item. The
elements that appear in the COMMAND clause can be UNIX or IMAGE keyboard commands,
such as ls, date, or run or one of a set of special keywords corresponding to predefined
commands.
For example:
MENU simple_menu {
TITLE "Simple";
MENU_ITEM "print date"
COMMAND {
PRINT
The first command in this example is a PRINT command. PRINT is a predefined command
that causes its argument (a string) to be printed to the screen. The second command is the
UNIX command date, which prints the current date to the screen. If the menu above were
displayed, the menu would look like:
SIMPLE
(1) PRINT DATE
(H) HELP FOR THIS MENU
[Q] QUIT MENU
SELECTION:
If item 1 were selected from this menu, first the PRINT command would be executed, and
then date would be run, resulting in the following being printed (the date varies, of course):
The date today is as follows:
Tue Oct 10 10:40:41 EDT 2000
SUBMENU
Instead of a COMMAND clause, a MENU_ITEM can have a SUBMENU clause. The SUBMENU clause
links a submenu to a menu item. If the item is selected, the system switches to displaying a
new menu until you quit from that menu. Syntax for this construct is as follows:
SUBMENU <menu name>;
For example:
MENU date_menu {
TITLE "Date" ;
MENU_ITEM "print date" {
COMMAND {
PRINT "The date today is as follows:"
"date"
}
}
}
MENU simple_menu {
TITLE "Simple" ;
MENU_ITEM "Bring up date menu" {
SUBMENU date_menu ;
}
}
Note the use of the SUBMENU keyword in the second MENU clause. When selected, this item
brings up the submenu date_menu, rather than executing a command.
MENU_ITEM HELP
The MENU_ITEM clause can contain a HELP construct for supplying on-line help for the
selection. The syntax of the HELP construct for menu items is identical to that used in the
MENU clause. For example:
MENU_ITEM "print date" {
HELP {
"If you select this item, it will"
"cause the date to be printed."
}
COMMAND {
PRINT "The date today is as follows:"
"date"
}
}
"FOO=def"
PRINT "The value of 'Foo' is $FOO"
}
}
In the above example, the environment variable FOO is used to store a string which is used
in subsequent PRINT commands.
READ_RESPONSE
You can use environment variables to store your response to a question. The menu
description language provides a special command for this purpose, READ_RESPONSE, which
reads a single line of your response and stores the text in an environment variable. The
syntax is as follows:
READ_RESPONSE $<variablename> ;
For example:
MENU_ITEM "Echo response" {
COMMAND {
PRINT "Enter a line of text"
READ_RESPONSE $User_response ;
PRINT "You just typed $User_response"
}
}
When executed, this command prompts you for a line of input, stores the text in the
environment variable User_response, and then echoes the text to the screen.
DECLARE_VARIABLE
Certain environment variables are already defined and used by IMAGE. For example, the
environment variable STATION_NUMBER is defined when a shell program is within the
command area of a station window. Altering the value of these environment variables can
have hazardous results. To ensure that no environment variable “collisions” occur, declare
all environment variables to be used in a menu program at the beginning of the menu
description file using the DECLARE_VARIABLE statement. The syntax is as follows:
DECLARE_VARIABLE <variablename>;
In this syntax, <variablename> is an environment variable which is to be used later in the
description file. If the variable name conflicts with an IMAGE environment variable, a
warning is issued by the menu file compiler.
STARTUP
All user environment variables start with no value assigned to them. If a variable must be
initialized before the start of the menu interface, use the STARTUP clause to set the variable
to a value. The syntax is as follows:
STARTUP {
<commands>
}
When you place this construct into the menu description file, commands specified in the
construct are executed as the menu interface is started, before any user interaction. In the
following example, the variable MYNAME is set to Terwillicker:
DECLARE_VARIABLE MYNAME ;
STARTUP {
"MYNAME=Terwillicker"
}
MENU ...
CHECK_STATUS
The CHECK_STATUS keyword allows you to execute a command and take some action if the
command passes or fails. Most Solaris and IMAGE commands end with an “exit status,” a
number passed back to the calling program to indicate whether the called program was
successful or failed. The CHECK_STATUS construct uses this “exit status.” The syntax is as
follows:
CHECK_STATUS "<testcommand>" {
IF_PASS <passcommands>
IF_FAIL <failcommands>
}
The command <testcommand> is executed and the exit status of this command is
examined. In Solaris, an exit status of 0 is considered successful. If the exit status is 0, any
commands in the IF_PASS clause are executed. If the exit status is nonzero,
<testcommand> fails, and commands specified in the IF_FAIL clause are executed instead.
For example:
CHECK_STATUS "date -illegal_flag" {
IF_FAIL {
PRINT "the command ‘date -illegal_flag‘ failed"
}
IF_PASS {
PRINT "the command ‘date -illegal_flag‘"
" completed successfully"
}
}
In this example, the command date -illegal_flag is executed, the exit status of the
command is checked, and the commands in one of the two following clauses are executed.
In this case, since -illegal_flag is an invalid option to the Solaris date command, the
exit status is always nonzero. Hence, commands in the IF_FAIL clause are always
executed.
ABORT
You can halt execution of a command sequence if a check or test fails using the ABORT
keyword. If ABORT is encountered at any point during execution of a command sequence,
processing of commands is terminated for the menu item. For example:
COMMAND {
CHECK_STATUS "load myprogram" {
IF_FAIL {
#
# We were not able to load program
# ‘myprogram’, so do not proceed any
# further.
#
ABORT
}
CHECK_VARIABLE
Another language construct, the CHECK_VARIABLE clause, can be used to take conditional
action based on the value of an environment variable. The syntax is as follows:
CHECK_VARIABLE $<variable_name> <op> "<stringvalue>" {
IF_TRUE <truecommands>
IF_FALSE <falsecommands>
}
where:
<variable_name> Is the name of an environment variable to evaluate.
<op> Is one of the logical operators: == | !=.
<stringvalue> Is a string to use for comparison.
The environment variable’s value is compared against the string given. If the comparison
yields TRUE, <truecommands> is executed, otherwise <falsecommands> is executed. For
example:
CHECK_VARIABLE $MYVAR== "1" {
IF_TRUE {
PRINT "Variable MYVAR is set to 1"
}
IF_FALSE {
PRINT "Variable MYVAR is not set to 1"
ABORT
}
}
When this construct is executed as part of the COMMAND clause of a menu item, this construct
tests the environment variable MYVAR. If MYVAR is set to 1, IF_TRUE is executed. If MYVAR is
not equal to 1, IF_FALSE is executed.
Command Execution
Solaris and IMAGE commands in a COMMAND clause are passed to the Bourne shell when
executed. This allows the Bourne shell to be used for such things as input/output
redirection, wildcard expansion, and so on. The following sections cover some of the
Bourne shell features you can use for command execution.
Quoting
Different types of quotes have special meaning to the Bourne shell. The three types of
quotes which can be used in a Bourne shell command are double quote ("), single quote
('), and back quote (‘).
Back quotes are used to capture the output of a command and to use the output as an
argument for another command. For example:
"MYVAR=‘hostname‘"
In the above command, the Bourne shell treats the contents of the backquotes as a
command to be executed, and runs the command and replaces the back-quoted section
with the output of the command. In effect, the hostname command is executed and the
output put into the environment variable MYVAR. You do not have to use a temporary file
when initializing an environment variable using the output of a program.
Text placed inside double quotes is not subjected to wildcard expansion by the Bourne
shell. For example:
"MYVAR=foo*"
"MYVAR=\"foo*\""
In the first example, the Bourne shell tries to expand the * wildcard by trying to match any
files which begin with foo and placing the names of these files into the environment variable
MYVAR.
In the second example, since the * is surrounded by double quotes, the * is interpreted
literally and the environment variable MYVAR is set to the string foo*. Since double quotes
are already used as delimiters for strings in the menu description file language, you must
enclose foo* with escape characters (\) to use them within a command string.
Text placed inside single quotes is not subject to wildcard expansion and does not have
environment variable references expanded. For example:
"echo $MYVAR"
"echo '$MYVAR'"
In the first example, the expression $MYVAR is replaced with the value of the environment
variable MYVAR, and that string is passed to the UNIX program echo. In the second example,
because of the single quotes, no environment variable substitution takes place, resulting in
the literal string $MYVAR being passed to the program echo.
The SELECTION_ERROR item determines the message printed when the user makes an
illegal menu selection. The default is:
""
"Illegal selection."
""
The QUITITEM_NAME and HELPITEM_NAME items determine the text displayed when each
menu is displayed which describes the q and h items. (These selections appear by default
for every menu.) The defaults for these items are QUIT MENU and HELP FOR THIS MENU,
respectively.
The NOHELP_ERROR item determines the error message printed if a user asks for help on a
menu or menu item for which no help was given in the menu description file. The default for
this item is the following:
""
"No help available for this menu or menu item."
""
Menu Keywords
Following is a list of all keywords which can appear in a menu description file. Also included
are syntax descriptions and a few examples. More examples are in the default
$IMAGEBIN/custom/menufile.
ABORT
ABORT is a predefined command which is used in the IF_FAIL, IF_PASS, IF_TRUE, or
IF_FALSE clauses of a CHECK_STATUS or CHECK_VARIABLE clause. If executed, this keyword
causes processing to be terminated for the commands in the current COMMAND sequence.
Syntax: ABORT
Example:
COMMAND {
CHECK_STATUS "<command1>" {
IF_FAIL {
"<command2>"
ABORT
}
}
"<command3>"
}
In this example, <command1> is always executed. If <command1> passes, <command3> is
executed. If <command1> fails, the IF_FAIL clause is processed, which causes <command2>
to be executed and then an ABORT. The ABORT terminates processing, which means that
<command3> (and any subsequent commands, if any) are not executed.
CHECK_STATUS
CHECK_STATUS executes a command, determines whether the command passes or fails,
and takes some action based on the pass/fail result. In the syntax description, <command>
is a Solaris or IMAGE command (surrounded by double quotes) that is to be executed. For
the IF_PASS and IF_FAIL clauses, <cmds> is either a single command followed by a
semicolon, or a list of commands enclosed in curly braces.
When this construct is executed, the first <command> is executed and the exit status is
checked. If the exit status is 0, commands in the IF_PASS clause are executed (if present).
If the exit status is nonzero, commands in the IF_FAIL clause are executed (if present).
Note that you must specify at least one of the IF_FAIL or IF_PASS clauses, but you need
not specify both.
Syntax: CHECK_STATUS "<command>" {
[IF_FAIL <cmds>]
[IF_PASS <cmds>]
}
CHECK_VARIABLE
CHECK_VARIABLE performs a logical test on the value of an environment variable. The name
of the environment variable to examine is given by <variablename>, the logical operation
(either != or ==) is given by <op>, and the string to compare the value against is given by
<comparestring> (a string enclosed in double quotes). If the comparison is successful
(that is, the value of the environment variable is equal/not-equal to the compare string),
commands in the IF_TRUE clause are executed. If the comparison fails, commands in the
IF_FALSE clause are executed. For the IF_TRUE and IF_FALSE clauses, <cmds> is either a
single command followed by a semicolon, or a list of commands enclosed in curly braces.
Note that you must specify at least one of the IF_FAIL or IF_PASS clauses, but you need
not specify both.
Syntax:
CHECK_VARIABLE $<variablename> <op> "<comparestring>"
{
[IF_TRUE <cmds>]
[IF_FALSE <cmds>]
}
CLEAR
CLEAR is a predefined command which clears the window (screen) when executed. After a
clear, all subsequent messages printed to the window (screen) start at the top of the output
area.
Syntax: CLEAR
COMMAND
The keyword COMMAND is part of the definition for a menu item; it appears as an option within
the MENU_ITEM clause. It specifies the commands to be executed if the user selects the item.
In the syntax description, <cmds> can be either a single command followed by a semicolon
or a list of commands enclosed in curly braces.
A command is either a quoted string containing a Solaris or IMAGE command (example:
date), or one of a set of predefined commands made available by the menu description
language. Predefined commands include PRINT, PRINT_N, READ_RESPONSE,
READ_PASSWORD, CLEAR, ABORT, CHECK_STATUS, and CHECK_VARIABLE.
Example:
COMMAND "date" ; #Simple command
COMMAND { #Compound command
PRINT "the date is: "
"date"
}
DECLARE_VARIABLE
DECLARE_VARIABLE is used to declare an environment variable for later use in the menu file.
In the syntax description, <variablename> is the name of the variable to be used. This
statement is provided primarily as a means of avoiding collisions between user variables
and variables used by IMAGE or by the menu interface itself. The menu description file
compiler does not make it mandatory to declare environment variables before use. You
must ensure that all variables are declared properly.
Syntax: DECLARE_VARIABLE <variablename> ;
HELP
The HELP construct specifies help string(s) to be provided to the user for a given menu or
menu item. It appears as an option in the MENU or MENU_ITEM clauses.
Example:
MENU_ITEM "example item" {
HELP {
"If you select this item, it will"
"print the current date and time."
}
COMMAND {
"date"
}
}
If the user were to ask for help on the menu item in the example above, the messages
printed in response would be the ones specified in the HELP clause.
HELPITEM_NAME
HELPITEM_NAME is one of the options appearing in the MENU_DEFAULTS clause (see “Using
a Different Language” on page 8-31). In the syntax description, <string> is an ASCII string
surrounded by double quotes. By default, the help selection is displayed along with each
of the menu selections when a menu is displayed:
<Menu title>
<Menu selections>
...
(h) Help message for this menu
When the HELPITEM_NAME is placed in a MENU_DEFAULTS clause, the string specified is used
in place of the description used above (Help message for this menu). This keyword is
used primarily for creating menus in a language other than English.
Syntax: HELPITEM_NAME "<string>" ;
IF_FAIL
The IF_FAIL keyword is used only in the CHECK_STATUS clause. For more information, see
“CHECK_STATUS” on page 8-27.
Syntax: IF_FAIL <commands>
IF_FALSE
The IF_FALSE keyword is used only in the CHECK_VARIABLE clause. For more information,
see “CHECK_VARIABLE” on page 8-28.
Syntax: IF_FALSE <commands>
IF_PASS
The IF_PASS keyword is used only in the CHECK_STATUS clause. For more information, see
“CHECK_STATUS” on page 8-27.
Syntax: IF_PASS <commands>
IF_TRUE
The IF_TRUE keyword is used only in the CHECK_VARIABLE clause. For more information,
see “CHECK_VARIABLE” on page 8-28.
Syntax: IF_TRUE <commands>
MENU
The MENU keyword is used to define a menu. In the syntax description, <menuname> is a
unique alphanumeric name assigned to the menu being defined. (This name is used to refer
to the menu later on.) The <options> section of the MENU clause can contain the following
clauses: TITLE and HELP. The <menu items> section which follows contains one or more
MENU_ITEM clauses, which describe the selections in the menu. The <options> must
precede the definitions of the menu items.
Syntax: MENU <menuname> {
<options>
<menu items>
}
MENU_DEFAULTS
The MENU_DEFAULTS construct is used to modify certain prompt strings and error messages
used by the menu interface. It is usually used for creating a menu description file which uses
a language other than English. Legal options in the <options> section of this construct are
HELPITEM_NAME, NOHELP_ERROR, QUITITEM_NAME, SELECTION_ERROR, and
SELECTION_PROMPT. This clause must contain at least one of these options, but not all are
mandatory.
Syntax: MENU_DEFAULTS {
<options>
}
MENU_ITEM
The MENU_ITEM keyword appears within a MENU clause. It is used to define a new menu item
for the enclosing MENU. In the syntax description, <menu item name> is a string that gives
the name of the menu item as it is to be shown when the selections for the menu are
displayed. The <options> for a menu item are a HELP clause and a COMMAND or SUBMENU
clause. Typically, a menu item has a single HELP clause and either a SUBMENU clause or a
COMMAND clause.
NOHELP_ERROR
The NOHELP_ERROR keyword is one of the options appearing in the MENU_DEFAULTS clause
(see “Using a Different Language” on page 8-31). In the syntax description, <strings> is
either a single string followed by a semicolon or a list of strings enclosed by curly braces.
The NOHELP_ERROR specifies the error message the menu interface prints if the user asks
for help on a menu or menu item for which no help was specified. By default, this message
is:
""
"No help available for this menu or menu item."
""
This option is usually used to translate this error message into a language other than
English.
Syntax: NOHELP_ERROR <strings>;
OPTIONS
The OPTIONS clause is used to specify optional information about a menu definition. The
OPTIONS clause, similar to the TITLE and HELP clauses, must appear before any menu
items in the menu definition. Currently, the only option available for a menu is
QUIT_MENU_ON_SELECTION.
PRINT
The PRINT keyword is a predefined command which you can use in a COMMAND clause (or a
subclause) in the definition of a MENU_ITEM. In the syntax description, <string> is a string
surrounded by double quotes. The specified string is output to the user (the string is treated
as an entire line of output). This command is usually used to prompt the user or convey a
set of instructions.
Syntax: PRINT "<string>"
PRINT_N
The PRINT_N keyword is identical to the PRINT keyword with one exception. When the text
string is printed, no newline is printed after it. (Hence, any subsequent output or input
appears on the same line.)
Syntax: PRINT_N <string>
QUIT_MENU_ON_SELECTION
The QUIT_MENU_ON_SELECTION keyword appears in the OPTIONS clause within a menu
definition. If this keyword is present, the menu being defined becomes a “temporary” menu.
When you enter the menu, the selections are displayed as with normal menus, but when
you make a selection, after the selection is through, control switches back to the previous
menu immediately. In a normal menu, this happens only when you quit from the menu.
The top level menu cannot be specified as a temporary menu. Temporary menus cannot
have menu items which invoke submenus.
Syntax: QUIT_MENU_ON_SELECTION ;
QUITITEM_NAME
The QUITITEM_NAME keyword is one of the options appearing in the MENU_DEFAULTS clause
(see “Using a Different Language” on page 8-31). In the syntax description, <string> is an
ASCII string surrounded by double quotes. By default, the quit selection is displayed along
with each of the menu selections when a menu is displayed:
<Menu title>
<Menu selections>
...
(q) Quit menu
When the QUITITEM_NAME is placed in a MENU_DEFAULTS clause, the string specified is used
in place of the description used (Quit menu) for the quit selection. This keyword is used
primarily for creating menus in a language other than English.
Syntax: QUITITEM_NAME "<string>" ;
READ_PASSWORD
The READ_PASSWORD statement is used to read back a password from the user. When the
password is typed, the characters typed are not echoed, and the user’s response is placed
into an environment variable. In the syntax description, <variablename> receives the text
of the response.
Syntax: READ_PASSWORD $<variablename> ;
This keyword is typically used to restrict access to a particular menu item to only those users
who know a certain password.
Example:
MENU_ITEM "Remove all files in current directory" {
HELP {
"Selecting this item will remove all"
"files in the current directory. You"
"must give a password to use"
"this item."
}
COMMAND {
PRINT_N "Enter the password to continue: "
READ_PASSWORD $PASSWD ;
CHECK_VARIABLE $PASSWD == "apple" {
IF_FALSE {
PRINT ""
PRINT "Incorrect password. No action
taken."
PRINT ""
ABORT
}
}
PRINT "Removing all files...."
"rm *"
}
}
In the example, READ_PASSWORD is used in combination with the CHECK_VARIABLE
statement to make sure the user gives the correct password before a sensitive command
(removing all files) is executed.
READ_RESPONSE
The READ_RESPONSE command provides a way to read back a response from the user.
When executed, it reads back a line of input from the user and stores that input in the
environment variable specified. In the syntax description, the environment variable is given
by <variablename>.
Syntax: READ_RESPONSE $<variablename> ;
The following example, in which a line of input is read from the user and then echoed,
illustrates its use:
COMMAND {
PRINT "Enter a line of input:"
READ_RESPONSE $TMP_RESPONSE ;
PRINT "The line was: $TMP_RESPONSE"
}
SELECTION_ERROR
The SELECTION_ERROR keyword is one of the options appearing in the MENU_DEFAULTS
clause (see “Using a Different Language” on page 8-31). In the syntax description,
<strings> is either a single string followed by a semicolon or a list of strings enclosed by
curly braces.
The SELECTION_ERROR specifies the error message that the menu interface prints if the user
tries to select a menu item that does not exist. For example: selecting menu item 9 if there
are only four choices. By default, this message is as follows:
""
"Illegal selection. Type ‘h’ for help."
""
This option is used primarily to translate an error message into a language other than
English.
Syntax: SELECTION_ERROR <strings>;
SELECTION_PROMPT
The SELECTION_PROMPT keyword is one of the options appearing in the MENU_DEFAULTS
clause (see “Using a Different Language” on page 8-31). In the syntax description,
<strings> is either a single string followed by a semicolon or a list of strings enclosed by
curly braces.
SELECTION_PROMPT specifies the prompt printed when the menu interface asks the user for
a selection. By default, this prompt is set to the string Selection:. This option is used
primarily to translate a system message into a language other than English.
Syntax: SELECTION_PROMPT <strings>;
STARTUP
The STARTUP clause specifies a command or list of commands to be executed when the
menu interface is started, before displaying any menus. It is usually used to do things like
initialize environment variables or perform other one-time initializations. In the syntax
description, <commands> is a command list similar to the argument to the COMMAND keyword
(either a single command or a list of commands enclosed by curly braces).
Syntax: STARTUP <commands>;
Example:
STARTUP {
PRINT "Starting menu interface..."
# Print startup message
"COUNT=0" # Initialize environment variable
}
SUBMENU <name> ;
SUBMENU
The SUBMENU keyword is used as part of the MENU_ITEM clause. It is used to specify that
when a particular menu item is selected, a submenu should be brought up (as opposed to
executing a command). The <name> given as the argument to SUBMENU must be the name
of a menu which is defined somewhere in the menu description file.
Syntax: SUBMENU <name> ;
TITLE
The TITLE construct specifies the title to be used for a particular menu; it must appear as
an option inside a MENU clause. The title for a menu is the text printed immediately before
the menu selections are printed. In the syntax description, <strings> is either a single
string followed by a semicolon or a list of strings enclosed in curly braces.
Syntax: TITLE <strings>;
Example:
MENU my_menu {
TITLE {
"***MY MENU***"
}
...
}
Menuprogram
The file menuprogram resides in the directory $IMAGEBIN/custom. The .login file of the
account used for production invokes menuprogram. If you make changes to the menu
description file and recompile the file to produce a new output file, you must copy this output
file to the home directory of the production account.
If you are running IMAGE under Solaris 2, the output file is called menuprogram.svr4.
Accelerator Keys
Some Sun keyboards have function keys at the top of the keyboard. You can use these keys
(such as F1 and F2) as accelerators. Typing function key F1 is equivalent to 1 followed by
Return, typing function key F2 is equivalent to 2 followed by Return, and so on. The top row
of keys on the right hand side of the keyboard, R1, R2, and R3, are accelerators for quit,
help, and qa (quit to top) respectively.
6. Exit IMAGE Properties. If more than one account is used for production, you must repeat
this procedure for each account, since default settings are kept on an account-by-
account basis.
NOTE
Error logging applies only to test programs loaded when IMAGE is in production mode. All
programs loaded in engineering mode generate error and alarm messages in the station
window, or in Alarm Manager if you enable it.
When a station is in engineering mode, the directories listed in the TEST PROGRAM DIRS
defaults item are no longer automatically searched when the load command is given. If
these directories are needed in the search path, use the -production option when invoking
the load command.
For example, assume a station has been changed to engineering mode to debug a
production test program stored in one of the directories listed in TEST PROGRAM DIRS. To add
these directories to the search path, execute the load command in the following way:
load -production <test_program_name>
Window Defaults
The defaults specified in the previous sections are inherited from the user currently logged
into the station window. For example, if two users with completely different sets of defaults
log in to different station windows, each user can access his own production test data and
test program directories. Also, users can inherit other defaults they have specified, such as
scroll bar, button layout, and font.
Bin
region
Monitor
region
NOTE
Bin assignment in the yield_monitor.yield file (see “Specifying Hardware or Software
Bins” on page 8-63) overrides the bin assignment from the command line.
• The bin region at the top shows the results of the last bin assignment for the device
tested for each active test site in large type. It also can display the first failed test for each
device that failed.
• The monitor region at the bottom of the window displays the current settings of
production related variables within the test program. It also includes yield monitor items.
Label on
Keyword Definition
Display
Label on
Keyword Definition
Display
Label on
Keyword Definition
Display
The following statmon.data file was used to create the station monitor in figure 8-4. (This
figure also includes yield monitor fields. See “Using Yield Monitor Items” on page 8-54.)
##################################################################
# statmon.data
# "@(#)statmon.data /main/9 02/06/96 09:35:26 Teradyne, Inc."
#
# This is the layout file for the Test Station Monitor
# Utility (statmon).
# The layout of an item is specified as follows:
#
# ( <row> , <column> ): <fieldwidth> "<Label>" <KEYWORD>
#
# See also "yield_monitor.yield".
#
##################################################################
#
# Some example fonts:
# FONT gallant.r.19
# FONT courier.16
# FONT cmr.r.8
# FONT screen.b.14
# FONT serif.r.14
# FONT screen.b.12
# FONT times-bold10
# FONT times-italic14
# FONT times-roman16
# FONT statmon_font.r.19
# FONT times-bolditalic12
# FONT screen.b.12
# FONT lucidasans12
# FONT -adobe-courier-bold-r-normal--10-100-75-75-m-60-iso8859-1
#
#
FONT lucidasans12
(0,0):25 "Program" JOB_NAM
#FONT times-bold10
(0,27):3 "Insertion" TEST_COD
#(0,27):25 "Operator" OPER_NAM
#(1,0):50 "Lot Started" START_T
#FONT times-italic14
(1,0):25 "Lot Id" LOT_ID
#FONT times-roman16
(1,27):25 "Sub Lot Id" SBLOT_ID
#FONT times-bolditalic12
(2,0):15 "Tested" PART_CNT
(2,27):15 "Device" PART_ID
#FONT helvetica-bold14
#(4,0):5 "Test Head" HEAD_NUM
#(4,34):10 "Handler" HAND_ID
#(5,0):50 "Message" MEMO
#
##################################################################
# The following options are on if present and off if commented out:
# PARALLEL_BIN_LARGE_FONT... Use full size bin font even for parallel test
# SHOW_FIRST_FAIL........... Show first failed test number
# SHOW_BINS_IN_COLOR........ Show bin values using IMAGE pass/fail colors
#
#PARALLEL_BIN_LARGE_FONT
SHOW_FIRST_FAIL
#SHOW_BINS_IN_COLOR
In this file, any line beginning with a # is a comment line and is ignored. Note that some
variables in the example are commented out, providing a default set of variables for the
display. The FONT keyword specifies a particular font to use when displaying monitor
information. Fonts are not restricted to those listed in the file, but you must use a valid Sun
font or an error occurs.
NOTE
In the statmon.data file, select fonts so that all information can be displayed in the space
allowed. If you use large fonts, some information may not fit in the monitor region of the
display.
The yield monitor displays two types of yield (see figure 8-4 on page 8-49):
• Current yield is the percentage of parts falling into a particular bin in the recent past,
where the recent past is the last n number of parts (n is a user-selectable number). Think
of the number as a sliding window that specifies the most recent history of testing.
• Cumulative yield is the percentage of all parts tested since a particular lot was started.
In addition to displaying the current and cumulative percents for each selected bin, the
actual numbers used to calculate these values are also displayed. For example:
SBIN 0 1
CURR% 80.0 20.0
CUM% 60.0 40.0
CURR# 20 5
out of: 25
CUM# 120 80
out of: 200
In this example, the window size is set to 25, and 20 of the last 25 were bin 0. But out of the
full lot of 200 tested so far, 120 were bin 0. Before you have tested 25 parts (or whatever
your window size is), the display will look as follows:
SBIN 0 1
CURR% N/A N/A
CUM% N/A N/A
CURR# 10 2
out of: <25
CUM# 10 2
out of: 12
The bins displayed on the yield monitor portion of the station monitor can be individual bins
or several bins grouped together and treated as a single unit. The yield monitor can display
up to 40 different bins per column.
For example, assume bins 5, 6, 7, and 8 are failing bins and bins 1 and 2 are passing bins.
You can specify a label such as Fail and have the yield monitor calculate the yield based
on three bins: Fail, 1, and 2. Whenever a part is binned in bins 5, 6, 7, or 8, the count and
percentages for Fail are incremented and updated.
The station monitor can also show yield-by-site information, which appears in the bin region
of the window. Including yield-by-site information may increase the size of the monitor
window by up to three lines.
Yield-by-site information options are:
Cum% - Cumulative yield percentage by site
Cur% - Current yield percentage by site
Cnt: - Number of parts tested on a particular site
You specify these display options by placing any or all of the following tags on a line by itself
anywhere in the .yield file:
CUM_YIELD_BY_SITE Displays cumulative yield percentage by site. This field displays
the percentage of all parts tested on each site since a particular
lot was started. This data is not available until after the first n
parts are tested.
CUR_YIELD_BY_SITE Turns on the current yield percentage by site feature. This field
displays the passing percentage of the last n tested parts. This
feature is similar to the current yield per bin except that it is
calculated per site. n is the size of the sliding window which
specifies the most recent history of testing. This data is not
available until after the first n parts are tested.
COUNT_BY_SITE Turns on a display of the number of parts tested per site.
Yield-by-site information is available for multisite test programs only and is not displayed for
single site test programs. There are no alarms to be set or triggered for each site's yields.
Figure 8-5 shows a sample station monitor window with yield-by-site information.
Yield-by-site
Bin Region
Information
Monitor Region
The following setup file was used to create the yield monitor fields in figure 8-5:
########################################################
#yield_monitor.yield
#
#This is the layout file for the Yield Monitor Utility
#(part of Statmon) for the Stamon window shown above.
########################################################
WINSIZE 10
FONT lucidasans12
#
CUM_YIELD_BY_SITE
CUR_YIELD_BY_SITE
COUNT_BY_SITE
#
BIN 0 LABEL 0
CUM_ULIM CUM_LLIM LABEL 0
CUR_ULIM CUR_LLIM LABEL 0
CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL 0
CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL 0
#
BIN 1 LABEL 1
CUM_ULIM CUM_LLIM LABEL 1
CUR_ULIM CUR_LLIM LABEL 1
CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL 1
CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL 1
#
PASS_BINS LABEL PASS
CUM_ULIM CUM_LLIM LABEL PASS
CUR_ULIM CUR_LLIM LABEL PASS
CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL PASS
CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL PASS
#
FAIL_BINS LABEL FAIL
CUM_ULIM CUM_LLIM LABEL FAIL
CUR_ULIM CUR_LLIM LABEL FAIL
CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL FAIL
CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL FAIL
#
##################################################################
NOTE
In the yield monitor setup file, select fonts so that all yield information can be displayed in
the space allowed. If you use large fonts, some yield information may not fit in the yield
monitor region of the display.
##################################################################
# yield_monitor.yield
#
# This is the layout file for the Yield Monitor Utility
# (part of statmon).
#
# See also "statmon.data".
#
##################################################################
#
# Some example fonts:
# FONT gallant.r.19
# FONT courier.16
# FONT cmr.r.8
# FONT screen.b.14
# FONT serif.r.14
# FONT screen.b.12
# FONT times-bold10
# FONT times-italic14
# FONT times-roman16
# FONT statmon_font.r.19
# FONT times-bolditalic12
# FONT screen.b.12
# FONT lucidasans12
# FONT -adobe-courier-bold-r-normal--10-100-75-75-m-60-iso8859-1
#
WINSIZE 10
FONT lucidasans12
#
BIN 0 LABEL 0
CUM_ULIM CUM_LLIM LABEL 0
CUR_ULIM CUR_LLIM LABEL 0
CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL 0
CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL 0
#
BIN 1 LABEL 1
CUM_ULIM CUM_LLIM LABEL 1
CUR_ULIM CUR_LLIM LABEL 1
CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL 1
CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL 1
#
BIN 2 LABEL 2
#CUM_ULIM CUM_LLIM LABEL 2
#CUR_ULIM CUR_LLIM LABEL 2
#CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL 2
#CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL 2
#
BIN 3 LABEL 3
#CUM_ULIM CUM_LLIM LABEL 3
#CUR_ULIM CUR_LLIM LABEL 3
#CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL 3
#CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL 3
#
BIN 4 LABEL 4
#CUM_ULIM CUM_LLIM LABEL 4
#CUR_ULIM CUR_LLIM LABEL 4
#CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL 4
#CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL 4
#
BIN 5 LABEL 5
#CUM_ULIM CUM_LLIM LABEL 5
#CUR_ULIM CUR_LLIM LABEL 5
#CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL 5
#CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL 5
#
#PASS_BINS LABEL PASS
#CUM_ULIM CUM_LLIM LABEL PASS
#CUR_ULIM CUR_LLIM LABEL PASS
#CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL PASS
#CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL PASS
#
#FAIL_BINS LABEL FAIL
#CUM_ULIM CUM_LLIM LABEL FAIL
#CUR_ULIM CUR_LLIM LABEL FAIL
#CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL FAIL
#CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL FAIL
#
#PASS_FAIL_PANEL
#
#CUM_ULIM CUM_LLIM LABEL PASS_INFO
#CUR_ULIM CUR_LLIM LABEL PASS_INFO
#CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL PASS_INFO
#CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL PASS_INFO
#
#CUM_ULIM CUM_LLIM LABEL FAIL_INFO
#CUR_ULIM CUR_LLIM LABEL FAIL_INFO
#CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL FAIL_INFO
#CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL FAIL_INFO
##################################################################
In this setup file, any line beginning with a # is a comment line and is ignored. The FONT
keyword specifies a particular font to use when displaying yield information. Fonts are not
restricted to those listed in the file, but you must use a valid Sun font or an error occurs.
The WINSIZE <integer value> line specifies the sample size used to calculate the current
yield. This is the size of the sliding data window. No yield information is displayed until at
least WINSIZE parts are tested.
Each statement following the WINSIZE declaration ends with the LABEL <value>
declaration. Information on that line is assigned to a particular bin or bin group. The BIN
<integer value1> ...<integer valuen> statement assigns the particular bins to a
particular bin group named LABEL <value>. The value for the label can be an integer or a
character, but more than two characters may not fit in the yield monitor region. The minimum
number of arguments to use with the BIN statement is one, and a maximum of 40 bins can
be grouped together. Bins exceeding the limit are ignored.
Use the CUM_ULIM <float> and CUM_LLIM <float> keywords to specify the upper and
lower yield alarm values. Yield values (and alarms) are calculated to one decimal point
accuracy. To specify the current upper and lower yield alarm values use the CUR_ULIM
<float> and CUR_LLIM <float> keywords. Each of these statements must be terminated
with a LABEL <value> statement. You must group the statements for a particular bin group
together with the BIN statement as the first statement. The yield alarm statements must also
precede the statements specifying the yield alarm values. Within each type of statement,
you can place the keywords in any order.
Figure 8-6. Station Monitor Display Window with Pass and Fail Columns
To have the Station Monitor display the pass and fail columns, add the following lines to the
setup file:
PASS_BINS LABEL PASS
CUM_ULIM CUM_LLIM LABEL PASS
CUR_ULIM CUR_LLIM LABEL PASS
CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL PASS
CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL PASS
Figure 8-7. Station Monitor Display Window With Pass and Fail Panel
To have the station monitor display the pass and fail panel, add the following lines to the
setup file:
PASS_FAIL_PANEL
#
CUM_ULIM CUM_LLIM LABEL PASS_INFO
CUR_ULIM CUR_LLIM LABEL PASS_INFO
CUM_HYIELD_ALARM CUM_LYIELD_ALARM LABEL PASS_INFO
CUR_HYIELD_ALARM CUR_LYIELD_ALARM LABEL PASS_INFO
#
CUM_ULIM CUM_LLIM LABEL FAIL_INFO
CUR_ULIM CUR_LLIM LABEL FAIL_INFO
Specifying Alarms
Each bin group you select comes with four different alarms. Each group can have:
• Cumulative high-yield alarm
• Cumulative low-yield alarm
• Current high-yield alarm
• Current low-yield alarm
Specify alarms using the following keywords:
CUM_HYIELD_ALARM <scriptname>
Specifies cumulative high-yield alarm.
CUM_LYIELD_ALARM <scriptname>
Specifies cumulative low-yield alarm.
CUR_HYIELD_ALARM <scriptname>
Specifies current high-yield alarm.
CUR_LYIELD_ALARM <scriptname>
Specifies current low-yield alarm.
If the script names are short enough, the cumulative or current statements for each type of
alarm can appear on the same line or they can be separated. Each line must end with the
LABEL statement.
The high-yield alarms can be set at a yield percentage and be triggered if the yield is
unusually high. For example, a 100% yield may indicate a good part is stuck in the jaws of
a handler and is being retested over and over. A high-yield alarm appears as a + (plus) sign
to the left of the yield being displayed.
You can also set the low-yield alarms to occur if the current or cumulative yields fall below
values that you select. A low-yield alarm appears as a - (minus) sign to the left of the yield
that is alarming.
You can select distinct values for either high or low yields. You can also have a script file
execute if a particular yield alarms. The default script provided by Teradyne sends a
T_ALARM event to the FIRMS host, if one exists. You can also edit these scripts to perform
other functions. At the end of a lot you must undo anything an alarm script has performed.
Therefore, create another script that is executed at the end of every lot to undo the actions
of the alarm scripts. In a future release, Teradyne will provide an option to specify such a
script to be executed.
NULL values for particular types of alarms are ignored, so that a particular keyword can
appear on a line without any scriptname specified. Alarm scripts are executed, if specified,
if the yield goes above or below a particular value, depending on the type of alarm. If the
yield value hovers below (or above) a particular threshold so that the yield remains alarmed,
the alarm script is executed only once. If the yield alarm returns to acceptable limits the
alarm is reset and executed again if the yield falls into unacceptable limits.
The Production Menu Control (PMC) allows you to design a custom graphic user interface
with menus and buttons for production operation. Using a PMC interface, test system
operators can run tests and collect data while having a minimum of technical interaction with
the test system computer.
PMC consists of a programming language (Menu Description Language, or MDL), a library
of functions and program definitions, and a graphic tool (PMCtool) configured to your
requirements. PMC can use IMAGE commands, UNIX commands, and scripts to perform
operations. You can partition menus into many files so that product-specific choices are
reflected in a particular PMC.
This section includes the following topics:
• “How to Use PMC” on page 9-3
• “Elements of a PMC Interface” on page 9-9
• “A Simple MDF” on page 9-15
• “MDF Structure” on page 9-18
• “Steps for Creating an MDF” on page 9-22
• “Using Collection and Auxiliary Files” on page 9-37
• “PMC Library” on page 9-43
• “MDL Keywords” on page 9-46
You can use the PMCtool for your production needs with minor changes to a database file,
see “Starting PMC” on page 9-4, or you can design your own PMC interface, see “Steps for
Creating an MDF” on page 9-22.
IMAGE also includes a production environment. For information on the IMAGE production
environment, see “Production Environment” on page 8-1.
Display
items
Menu
selections
Control
buttons
Figure 9-2. PMCtool Screen Using an MDF that References a Product Database
Starting PMC
To start the PMCtool, enter the following command in a station window:
pmctool [-station <#>][-file_name <file>] [-nomouse] [-j9_paths]
where:
-station <#> Starts the PMCtool in the station number specified. The PMCtool
automatically attaches to the station where it is started. If starting
from outside the station window, identify the station number.
-file_name <file> Specifies the Menu Description File (MDF) to load. If no file
name is specified, the default is:
$IMAGEBIN/custom/menufile.mdl
-nomouse Indicates you want to use the keyboard for input and not the
mouse.
-j9_paths Specifies J9 style (IG900) path variable settings (see “Variable
Styles” on page 9-14).
After typing pmctool, two screens appear asking for the following information:
1. Enter the database directory by typing:
/image/bin.6.3/custom
2. Enter the operator name by typing:
Test
The initial PMC screen appears (see figure 9-2).
NOTE
When entering the database directory, the PMCtool does not accept $IMAGEBIN. Use the
path /image/bin.6.3/custom.
IMAGE Properties
Set PMCtool properties using IMAGE properties, GLOBAL STATION WINDOW OPTIONS (see
figure 9-3) and MISCELLANEOUS options (see figure 9-4 on page 9-6).
For example, you are running the PMC to control multiple stations and do not want to use
the Job I/O screen. You can have the station window displayed whenever the PMC
attaches. To do this, select UNICONIFY STATION WINDOW from the ACTION ON PMC ATTACH
and ICONFIY STATION WINDOW from the ACTION ON PMC DETACH.
From the Miscellaneous window, you can choose the ICD (default) or J9 style (IG900) path
variable settings in MDL files (see “Variable Styles” on page 9-14).
Quitting PMC
Normally, a quit function is written into the Menu Description File (MDF), but you can also
select QUIT from the PMCtool window menu to exit the program.
FollowMenu (For nomouse operation) If true, the Job I/O window follows the main
menu window so that input typed from the keyboard is received into it.
font Font to use in the window. Takes the name of any valid font.
height The vertical size of the window, in pixels. (One inch = 83 pixels,
SPARC)
lock Prevents the window from being moved. (It snaps it back into place
according to its x, y, width, and height properties.) May be set to True
or False.
title Title for the window’s name bar. Takes any string.
scrolling Whether the named window should scroll as incoming data is
received. The following values are specified for this field:
True — the window scrolls, so that data is displayed as it is received.
After it is completely received, the end of the data remains displayed.
False — the window does not scroll the data. The first screenful of
data remains displayed until the user manually scrolls the window.
show If the value is True, the named window is displayed when PMCtool is
started up.
width The horizontal size of the window, in pixels. (One inch = 83 pixels,
SPARC)
x,y The horizontal (x) and vertical (y) coordinates for the upper left corner
of the named window, in pixels, with (0,0) indicating the upper left
corner of the user’s screen.
Field
Window name Value
Tool name
PMCtool.control.x: 0
PMCtool.control.y: 430
PMCtool.control.width: 640
PMCtool.menu.x: 0
PMCtool.menu.y: 0
PMCtool.menu.width: 640
PMCtool.menu.height: 400
PMCtool.menu.show: True
PMCtool.jobio.x: 0
PMCtool.jobio.y: 470
PMCtool.jobio.width: 640
PMCtool.jobio.height: 400
PMCtool.jobio.scrolling: True
PMCtool.jobio.FollowMenu: True
PMCtool.datalog.x: 500
PMCtool.datalog.y: 470
PMCtool.datalog.width: 640
PMCtool.datalog.height: 400
PMCtool.datalog.scrolling: True
PMCtool.status.x: 650
PMCtool.status.y: 0
PMCtool.bin.x: 650
PMCtool.bin.y: 122
NOTE
Do not initiate automatic window scrolling if running Solaris 1. Initiation of the scrolling
command can cause a system malfunction.
Menu
screens
Control
buttons
Figure 9-6. PMCtool Main Menu Showing Control Buttons and Menu Screens
Menu Screens
Operators use PMC screens to communicate with the test system. They can input
parameters, select actions, or receive information. Three screens are available for use with
the PMCtool (see figure 9-6). You can minimally customize two of these screens:
• Job I/O screen
• Datalog screen
To add either of these screens to a PMC interface see, “Job I/O and Datalog Screens” on
page 9-31.
A major portion of the third screen can be customized:
• Runtime/Binning screen
To add this screen to a PMC interface see, “Runtime/Binning Display Screen” on page 9-34.
Control Buttons
PMC screens feature control buttons used to execute certain predefined functions (see
figure 9-6). Each predefined control button is associated with an MDL standard variable
(see table 9-3).
Buttons with functions not appropriate for certain screens are individually suppressed in
either of two ways:
• Use the keyword SUPPRESS in the MENU clause for that menu. (See “SUPPRESS” on
page 9-81.)
• Set the value of a button’s variable to zero. (To reactive the button set the variable to
one.)
Control buttons are activated by clicking with the mouse or pressing the associated function
key (F1 through F8) if you are in nomouse mode.
Nomouse Standard
Button Action
Mode Variable
Command Sequence
Command sequences contain executable actions. A single command sequence (in Menu
Description Language, known as a COMMAND clause) is associated with a single menu item
and contains the actions executed when that item is selected by the user.
A command sequence can contain IMAGE commands, UNIX commands, and MDL
keywords that perform actions or functions. For a description and examples of defining a
command sequence, see “Defining Menus and Menu Items” on page 9-25. For the syntax
and description of MDL keywords, see “MDL Keywords” on page 9-46.
When a command sequence is executed, the following events occur:
1. The screen is cleared and ABORT becomes the only available control button on the user’s
screen.
2. The command sequence begins execution. Anything typed after this point becomes
input to the currently executing command. Sometimes input is needed by the command
itself or by a script.
3. If any output is produced by the command sequence, the output is displayed on the
screen.
4. The command sequence can be terminated in any of the following ways:
a. You select the control button labeled ABORT or (F8) for nonmouse mode.
b. The ABORT command is encountered in the command sequence.
c. The end of the command sequence is reached.
5. Once the command sequence has terminated, if output has been generated, the user is
prompted to continue.
6. After the user responds to the prompt, the menu from which this item was selected
reappears, unless the sequence terminated because of a CHANGE_MENU or SUBMENU
command. In this case, the menu specified in the SUBMENU command is displayed.
NOTE
IMAGE and UNIX commands are generally all lowercase characters, while MDL keywords
are always all uppercase characters.
Variables
Variables are used in the MDF to pass or generate values used by the PMCtool. MDL uses
environmental variables in the form $<variablename> where a quoted string is required.
Wherever they are found, variables are replaced by their values before the string is used.
Variable names are all uppercase alphanumeric characters, including underscore
characters. The prefix MDL_ is reserved for Teradyne use in standard variables.
Two types of variables are used in an MDF:
• User variables, which are not predefined in the PMCtool
• Standard variables, which are predefined in the PMCtool
To set and declare variables, see “Setting Variables” on page 9-22.
User Variables
User variables are defined in the MDF as needed, see “Setting Variables” on page 9-22.
They are also defined in collections and auxiliary files, see “Using Collection and Auxiliary
Files” on page 9-37.
Standard Variables
A standard variable is predefined in the PMCtool. It has the same meaning whenever it is
used and cannot be changed. You can write to some of the variables and set their values.
After setting their values, you can read those values. Other standard variables are read-only
variables that receive information from IMAGE. For a listing of the standard variables see
table 9-4.
Read or
Standard Variable Possible Values Description of Variable
Write
Read or
Standard Variable Possible Values Description of Variable
Write
MDL_LOT_ID Set by startlot and read only String identifying the lot
lot commands on the station
MDL_OPER_NAME Set by startlot read only Test system operator
command name
MDL_PERIPHERAL_ID Set by startlot read only Handler or prober
command identification
MDL_SUBLOT_ID Set by startlot and read only Number of the lot on the
lot commands station
MDL_SUPV_NAME Set by startlot read only Test floor supervisor
command name
MDL_TEST_CODE Set by startlot read only Three-character user-
command defined field specifying
phase of device testing or
test conditions (such as
WFR for wafer test)
MDL_TESTER_TYPE A5xx read only String identifying test
system type
MDL_WAFER_ID Set by startlot read only String identifying wafer
command on the station
MDL_USR_HOMESCR menu identifier write (and Set this variable to
read after contain the identifier of
written) the menu that appears
when the user presses
the HOME control button
(either in a mdl_startup
function or in a startup
clause in the MDF).
Read or
Standard Variable Possible Values Description of Variable
Write
Variable Styles
Note that the IMAGE PMC variables, MDL_JOBNAME and MDL_JOBPATH, differ from the
variable names used by the Teradyne J9 series. The ICD/IMAGE job name variable is the
name of the file used to load the test program. The J9 equivalent is the fully rooted
pathname for the test program. The ICD/IMAGE job path variable is the fully rooted
pathname from which the test program was loaded. The J9 equivalent is the fully rooted
directory in which the test program resides. You can choose the ICD style or J9 style
settings by using the IMAGE properties tool (see Miscellaneous Options section on page
3-36) or by starting the PMCtool with the -j9_paths switch (see “Starting PMC” on page
9-4).
A Simple MDF
This section describes the MDF that created the PMC interface in figure 9-7. This interface
does not call a collection database as in the default MDF. However, it does use all menu
screens available to the PMCtool.
MDF Syntax
The following MDF created the PMCtool menu interface in figure 9-7:
DECLARE_VARIABLE JOBNAME;
DECLARE_VARIABLE STATION;
DECLARE_VARIABLE SITES;
DECLARE_VARIABLE TMP;
STARTUP {
"MDL_USR_HOMESCR = control"
"MDL_USR_INITSCR = control"
"JOBNAME = /u/writers/Programs/adv_mixed/tester_util"
"SITES = """
}
RUNTIME {
BINNING_ITEM {
FONTSIZE 36
LABEL "Hardware Bin"
LAST_SORT
}
BINNING_ITEM {
FONTSIZE 24
LABEL "Software Bin"
LAST_BIN
}
STATUS_ITEM {
ROW 1
COL 1
FONTSIZE 36
SIZE 12
VARIABLE $MDL_JOBNUM
LABEL "STATION:"
}
STATUS_ITEM {
ROW 2
COL 1
FONTSIZE 18
SIZE 25
VARIABLE $MDL_JOBNAME
LABEL "JOB NAME:"
}
STATUS_ITEM {
ROW 3
COL 1
FONTSIZE 18
SIZE 25
VARIABLE $MDL_JOBREV
LABEL "JOB REV:"
}
}
MENU control {
DISPLAY "STATION: $MDL_JOBNUM" {
COL 4
}
MDF Structure
A menu description file (MDF) contains any or all of the following:
• MDL keywords (all uppercase)
• Operators (such as {)
• Strings (enclosed in double quotes)
• Variables (properly defined, uppercase, preceded by $)
• Comments (characters following # until the next newline)
• White space (spaces, tabs, and newlines)
The file is free-form. White space (spaces, tabs, and newlines) and comments are allowed
between keywords. Figure 9-8 shows an example of MDF structure using comments and
formatting.
Comments in an MDF
Liberal use of comments helps you (and others) understand your MDF. Any characters
between a pound sign (#) and a new-line character are treated as comments and are not
interpreted by the compiler.
Horizontal placement To move text to the right on the user’s screen, use blank spaces
before the text. For example, the text in a TITLE phrase usually
appears in the extreme upper left hand corner of a menu screen.
By adding blank spaces, you can place the title closer to the
center of the screen where it is more visible, as in
TITLE " CONTROL MENU" ;
Vertical placement Within STARTUP and COMMAND clauses, text is moved downwards
by inserting a blank line before the text. Use the keyword PRINT
to insert a new-line character before your text. For example:
PRINT ""
PRINT "Now this line is one line lower on the screen."
Direct placement Within DISPLAY or MENU_ITEM clauses, use the MDL keywords
ROW and COL to position text in specific locations on the menu
screen. For example:
DISPLAY "Select one item from the group above." {
ROW 25
COL 15
}
See “MDL Keywords” on page 9-46 for more information on keywords.
Setting Variables
All variables (including write-only standard variables) can be set in any of the following
ways:
• In a DECLARE_VARIABLE statement (sets initial value; do not use for write-only standard
variables since they do not need to be declared)
• In the mdl_startup function (sets initial value; use for any variable that can be set)
• In a COMMAND clause of a menu item (use for any variable that can be set)
– Sets value to a predetermined value named in the COMMAND clause
– Sets value to a user-response read in the COMMAND clause
NOTE
MDL_USR_INITSCR and MDL_USR_HOMESCR are predefined (standard) variables and do not
need to be declared in your MDF.
1. In previous versions of PMC, a STARTUP clause performed this function. STARTUP will continue to be
supported for backwards compatibility.
FUNCTION mdl_startup {
PRINT "Welcome to PMC"
PRINT "The current date is "
"date"
"MYNAME=Terwillicker"
"MDL_USR_HOMESCR = control"
"MDL_USR_INITSCR = signin"
}
MENU
A menu is defined by a MENU clause, which contains one or more MENU_ITEM clauses. For
example:
MENU <identifier> {
<optional keywords>
<menu items>
}
Give each menu a unique identifier immediately following the MENU keyword. Use
alphanumeric and underscore characters (lowercase letters for identifiers is a convention).
Inside the curly braces of the MENU clause are a series of options for that menu and one or
more MENU_ITEM clauses. The MENU_ITEM clauses describe the items (selections) in the
menu.
The MENU clause can contain the following keywords:
TITLE
HELP
OPTIONS
DISPLAY
SUPPRESS
MENU_ITEM
For a complete listing of keywords, see “MDL Keywords” on page 9-46.
TITLE
The TITLE keyword specifies the title to display with a particular menu.
TITLE <string_specifier>
The title is the text printed in a menu above the list of menu selections. The argument,
<string_specifier> is either a single double-quoted string followed by a semicolon or a
list of double-quoted strings enclosed in curly braces ({}).
TITLE "this is one line" ;
TITLE {
"This is the first line"
"this is the second line"
}
HELP
The HELP keyword specifies strings to print if the user selects the HELP control button.
HELP <string_specifier>
The argument <string_specifier> is either a single double-quoted string followed by a
semicolon or a list of double-quoted strings enclosed in curly braces ({}).
MENU empty_menu {
TITLE "Title goes here" ;
HELP {
"This menu contains commands that"
"allow you to ..."
}
<menu items>
}
OPTIONS
The OPTIONS keyword is used to specify a temporary menu (also called a quit-on-selection
menu). These menus disappear after the user makes a selection from them, returning the
user to the previously displayed menu. Use them if you want the user to select a single
menu item from a list of menu items.
OPTIONS { QUIT_MENU_ON_SELECTION ; }
You might have a menu containing setup parameters
SETUP:
(1) Stage
(2) Product
(3) Station(s)
Selection:
If the user selects Stage, a temporary menu appears
STAGE:
(1) Probe
(2) Final
(3) Manual Test
Selection:
When a user selects an item from the STAGE menu, the menu disappears and the screen
displays the previously displayed SETUP menu. None of the items in the STAGE menu can
bring up a submenu.
MENU_ITEM
For each selection in a menu, a MENU_ITEM clause is defined. This clause is made up of the
keyword MENU_ITEM, followed by the item’s text, and then a COMMAND clause.
Optional keywords are defined within a menu item. (See “Advanced Commands” on page
9-29.) For example:
MENU menu1 {
MENU_ITEM "Print my name." {
COMMAND {
PRINT ""
PRINT "Your name is $MYNAME."
}
}
MENU_ITEM "Bring up the Control Menu." {
COMMAND SUBMENU "control" ;
}
}
The text that follows MENU_ITEM is the text that appears for an item when the menu is
displayed.
COMMAND
The COMMAND clause lists the commands executed when a menu item is chosen by the user.
Elements that appear in a COMMAND clause are IMAGE commands, UNIX commands, or one
of the MDL keywords that represent predefined commands. For example:
MENU simple_menu {
TITLE "Simple Menu" ;
MENU_ITEM "print date" {
COMMAND {
PRINT "The date today is"
"date"
}
}
}
The first command in the clause above, is the MDL keyword, PRINT, which prints a string
on the screen. The second command is the UNIX command, date, which prints the current
date to the screen.
The above example displays the following menu:
Simple Menu
Selection:
If the user selects item 1, PRINT and date execute resulting in the following:
The date today is
Thu Jul 16 10:40:41 EDT 2000
SUBMENU
The SUBMENU keyword links a menu item to another menu.
When a user selects a menu item containing the command SUBMENU, the current menu
disappears and the named submenu is displayed.
The SUBMENU is displayed until the user quits, unless it is designated as a temporary menu.
(See “OPTIONS” on page 9-26.) You cannot place another command after the SUBMENU
command.
Define the menu name of the SUBMENU in the MDF.
SUBMENU <menu name> ;
The following example shows two MENU clauses. The first clause describes a MENU called
date_menu, which is called as a submenu by the second MENU clause.
MENU date_menu {
TITLE "Date Menu" ;
MENU_ITEM "print date" {
COMMAND {
PRINT "The date is as follows:"
"date"
}
}
}
MENU simple_menu {
TITLE "Simple Menu" ;
MENU_ITEM "Bring up date menu" {
COMMAND SUBMENU date_menu ;
}
}
The above example produces the following menu on the user’s screen:
Simple Menu
(1) Bring up date menu
Selection:
If the user selects item 1, the following menu appears:
Date Menu
Selection:
If the user selects item 1, PRINT and date execute, printing the following to the screen:
The date is as follows:
Thu Jul 16 10:40:41 EDT 2000
Advanced Commands
When the user chooses a particular menu item, sometimes checks and tests must run
before execution of a command. At other times, checks make sure a previous command
had the desired effect. For example, if a menu contains an item that turns on datalog for a
test program, the PMCtool checks before performing this operation to see if a test program
is loaded.
Use the following commands in the COMMAND clause for a menu item: CHECK_STATUS,
CHECK_VARIABLE, and ABORT. Use CHECK_STATUS and CHECK_VARIABLE to implement
checks.
CHECK_STATUS
Within a COMMAND clause, the CHECK_STATUS keyword provides a way to take action based
on whether a previous command passed or failed. CHECK_STATUS uses the exit status, a
number passed back to the calling program to indicate whether the called program was
successful.
CHECK_STATUS <testcommand> {
IF_PASS <passcommands>
IF_FAIL <failcommands>
}
The command specified, <testcommand>, is executed and the exit status of this command
is examined. If the exit status indicates a successful execution (by UNIX convention, an exit
status of 0 is considered successful), the command in the IF_PASS clause is executed.
If <testcommand> fails for some reason (signaled by a nonzero exit status), the command
specified in the IF_FAIL clause is executed. For example:
CHECK_STATUS "date -illegal_flag" {
IF_FAIL {
PRINT "the command 'date -illegal_flag'"
PRINT "failed"
}
IF_PASS {
PRINT "the command 'date -illegal_flag'"
PRINT "completed successfully"
}
}
In this example, the command date -illegal_flag is executed, the exit status of the
command is checked, and the commands in one of the two following clauses are executed.
(In this case, since -illegal_flag is an invalid option to the UNIX date command, the exit
status is always nonzero, and the commands in the IF_FAIL clause are executed.)
CHECK_VARIABLE
A CHECK_VARIABLE clause takes conditional action based on the value of a variable. The
syntax is:
CHECK_VARIABLE $<variable_name> <op> "<stringvalue>" {
IF_TRUE <truecommands>
IF_FALSE <falsecommands>
}
where:
<variable_name> The name of a variable to evaluate.
<op> One of the logical operators, == or !=.
<stringvalue> A string used for the comparison.
The variable is compared to the string. If the comparison yields true, <truecommands>
executes. Otherwise, <falsecommands> executes. For example:
CHECK_VARIABLE $MYVAR == "1" {
IF_TRUE {
PRINT "Variable MYVAR is set to 1"
}
IF_FALSE {
PRINT "Variable MYVAR is not set to 1"
ABORT
}
}
This example tests the variable MYVAR to see if it is set to 1. Then it executes one of the two
clauses depending on the outcome.
ABORT
To halt the execution of a command, use the ABORT keyword.
If the ABORT keyword is used in a command sequence, it terminates the commands for that
menu item. Therefore, use it as the last item in any command sequence.
COMMAND {
CHECK_STATUS "load myprogram" {
IF_FAIL {
#
# We were not able to load program
# 'myprogram', so do not
# proceed any further.
#
ABORT
}
}
PRINT "Load completed."
}
In the COMMAND clause above, if the load command in the CHECK_STATUS clause fails, ABORT
halts the program and Load completed is not printed.
NOTE
Do not use the Job I/O window while using the PMC to multiplex across stations. This can
confuse the operator if input is required.
Job I/O MDL_SVC_JOBIO Handles all input to and output from the test
program. Any input entered from this screen, other
than activation of control buttons, is passed to the
standard input of the test program.
Do not use this window when using PMC for
multiplexing. See note.
Active control buttons on this screen are BACK,
HOME, ABORT, and RUN.
Figure 9-11. Selecting the Enable Datalog To PMC Datalog Screen and Show Datalog Output Screen
The Datalog Service Window displays the data collection results (see figure 9-12).
Runtime/Binning MDL_SVC_RUNTIME Displays the binning item, site number, and status
Display information for a test program.
Site Numbers in the binning display window have the
following color coding:
Green—Last device passed
Yellow— No device tested on this site during last run
Red—Last device failed
Pink—Site currently running
Active control buttons on this screen are BACK,
HOME, ABORT, and RUN.
RUNTIME {
BINNING_ITEM {
FONTSIZE 36
LABEL "Hardware Bin"
LAST_SORT
}
BINNING_ITEM {
FONTSIZE 24
LABEL "Software Bin"
LAST_BIN
}
STATUS_ITEM {
ROW 1
COL 1
FONTSIZE 36
SIZE 12
VARIABLE $MDL_JOBNUM
LABEL "STATION:"
}
STATUS_ITEM {
ROW 2
COL 1
FONTSIZE 18
SIZE 25
VARIABLE $MDL_JOBNAME
LABEL "JOB NAME:"
}
STATUS_ITEM {
ROW 3
COL 1
FONTSIZE 18
SIZE 25
VARIABLE $MDL_JOBREV
LABEL "JOB REV:"
}
2. Create a menu item in the MDF. For example:
MENU_ITEM "Show Runtime/Binning Display" {
COMMAND SHOW_SERVICE "MDL_SVC_RUNTIME";
}
3. Run the test program using the RUN control key.
4. Select SHOW RUNTIME/BINNING DISPLAY screen from the menu (see figure 9-13).
The Bin and Status windows display the test program results and status (see figure 9-14).
Site number
Collection Files
A PMC collection file is a set of records each containing a list of field-value pairs of data (see
figure 9-15). All the records contain the same fields, but they can contain different values
associated with the fields. An example of a collection file is:
$IMAGEBIN/custom/product_db
PMC
Database Files
Job-Specific
Product Data
product: cgb458
product_variation: cgb458_1
stage: probe
periph: kla1007r
Record setup: xyz_grade
test_program: $IMAGEBIN/custom/mdl_sample_job
periph_script: "$IMAGEBIN/custom/start_remote.script"
setup_script: cgb458_probe.script
kill_periph: "$IMAGEBIN/custom/kill_remote.script"
Separated by blank line aux_mdl: cgb458_probe.mdl
product: cgb458
product_variation: cgb458_1
stage: final
periph: AET3000handler
Record setup: xyz_grade
test_program: $IMAGEBIN/custom/mdl_sample_job
periph_script: "$IMAGEBIN/custom/start_remote_script"
setup_script: cgb458_package.script
kill_periph: "$IMAGEBIN/custom/kill_remote.script"
aux_mdl: cgb458_package.mdl
Field Value
Separated by colon (:)
The main purpose of a collection file is to generate menus. An operator makes a selection
which triggers the generation of a menu. You can use collection files in several ways:
• Create collection files from text files
• Create collection files from directory contents
• Create collection files from existing collections
• Rename collection files
• Delete collection files
• Count the number of records in a collection file or unique values in a field
• Select values for a given field for all records in a collection file
• Create menu items based on all unique field values
MERGE_COLLECTIONS "new_collection_name" {
COLLECTIONS {
"old_collection_name"
}
}
DELETE_COLLECTION "old_collection_name"
COLLECTION_MENU "station_collection" {
FIELD "station"
RESULT_VARIABLE "STATION_VALUE"
COMMAND {
PRINT "Station Selected is $STATION_VALUE"
}
}
In this example, when one of these menu items is selected, the value of station for that menu
item is stored in the variable STATION_VALUE and the command clause is executed.
Auxiliary Files
Auxiliary files are appended to an MDF. The auxiliary file gives additional instruction to the
MDF. Auxiliary files are written in Menu Description Language (MDL) and contain variable
declarations, function definitions, and menu definitions.
An example of an auxiliary file that specifies a runtime/binning display is in:
$IMAGEBIN/custom/cgb458_package.mdl
#include "display_items.h"
.
.
.
MENU datacollection {
TITLE "Data Collection Menu";
COMMON_DISPLAY_ITEMS
MENU_ITEM "$DATALOG_ITEM" {
ROW 9
COMMAND {
IF_FALSE {
PRINT "This selection will TURN OFF data collection."
PRINT_N "Are you sure you want to continue(Y/N):"
READ_RESPONSE $RESPONSE;
CHECK_VARIABLE $RESPONSE != "Y" {
IF_TRUE {
CHECK_VARIABLE $RESPONSE != "y" {
IF_TRUE {
PRINT "Data collection has NOT been turned off."
ABORT
}
}
}
}
PMC Library
PMCtalk is a static .a library written in C, with EXTERN_FUNCTION declarations provided for
use with C++. This section describes programs and functions used in an MDF.
The following activities are provided by this library. The functions are encapsulated in
transients to make these activities available to shell scripts.
• Updating MDL variables
• Displaying an error or informational message to the user
• Loading and executing MDFs
All functions are prefaced by pmct_. A return value of one indicates success, and a return
value of zero indicates failure. Any memory allocated by these functions is deleted on the
next call to the function.
PMCtalk’s file name is $IMAGEBIN/libpmctalk.a.
Program Definitions
Program definitions communicate with the PMC process from which they were started. If
they were not started from a PMC process, you must specify the station number attached
to a particular PMC process, or -all_pmcs to specify all PMC processes.
The following command outputs the value of the named MDL variable:
pmc_get_var [-variable <string>] [-station <#> | -all_pmcs]
The following command sets the named variable to the specified value:
pmc_set_var [-variable <string>] [-value <string>]
[-station <#> | -all_pmcs]
PMC Functions
The following sections describe functions that communicate with the PMC.
pmct_init
The pmct_init function initializes communication to a specified PMC or PMCs. All other
functions talk to the PMC or PMCs specified in this function call. The syntax is:
pmct_init <int station>
where:
<int station> Is one of the following:
PMCT_NOSTATION_ATTACHED Talks to PMCs not
attached to a station.
PMCT_ALL_PMCS Talks to all PMCs attached to a station.
pmct_load_mdl_file
The pmct_load_mdl_file function tells PMC to pull in an auxiliary file. The syntax is:
pmct_load_mdl_file (char *filename)
where:
*filename Is a pointer to the filename string of the file to load. Returns one
for success and zero for failure.
pmct_call_function
The pmct_call_function function tells PMC to call the specified function clause. User
action is required (press ACTION button). This function does not return until the
ANSWER_REMOTE_CALL clause is reached in the MDL flow. The syntax is:
pmct_call_function (char *func_name)
where:
*func_name Is a pointer to the function string of the function to load. Returns
one for success and zero for failure.
pmct_auto_call_function
The pmct_auto_call_function function tells PMC to call the specified function clause
without any user action required. This function does not return until the
ANSWER_REMOTE_CALL clause is reached in the MDL flow. The syntax is:
pmct_auto_call_function (char *func_name)
where:
*func_name Is a pointer to the function string of the function to load. Returns
one for success and zero for failure.
pmct_update_mdl_varlist
The pmct_update_mdl_varlist function updates the named MDL variables for all PMCs
specified in pmct_init. The syntax is:
pmct_update_mdl_varlist (Pmct_mdl_var list *var_list)
where:
*var_list[] Is a structure containing the variables to update and their new
values. Returns one for success and zero for failure. The
structure definition is:
typedef struct {
u_int Pmct_mdl_varlist_len; //the number of variables
Pmct_mdl_var *Pmct_mdl_varlist_val //an array of variables
} Pmct_mdl_varlist; //and their values
struct Pmct_mdl_var {
char *keyword;
char *value;
};
pmct_get_mdl_varlist
The pmct_get_mdl_varlist function retrieves the values for a list of MDL variables. The
syntax is:
pmct_get_mdl_varlist (Pmct_vars *var_list)
where:
var_list Is a structure containing the list of MDL variable names. The
structure definition is listed below. Returns a structure containing
the variables and their values or null if the call fails. (See
pmct_update_mdl_varlist above for the structure definition.)
typedef char *Pmct_string;
typedef struct {
u_int Pmct_vars_len; // the number of variables
Pmct_string *Pmct_vars_val; // an array of variable
// names
} Pmct_vars;
pmct_display_message
The pmct_display_message function sends a message to the PMCs specified by
pmct_init(). The priority of the message tells PMC how to display it. The highest priority
messages display immediately. The syntax is:
pmct_display_message (int priority, char *msg)
where:
priority Is the priority of the error message.
*msg Is the message to display. Returns one for success and zero for
failure.
enum Pmct_msg_pri {
PMCT_PRI_EMG = 0,
PMCT_PRI_ERROR = 1,
PMCT_PRI_INFO = 2
};
MDL Keywords
This section lists all MDL keywords that appear in a menu description file (MDF) with their
syntax and a brief description of their actions. A listing shows how each keyword is used in
an MDF; see “Listing of MDL Keywords” on page 9-46.
MDF Conventions
Follow these guidelines when developing Menu Description Files:
• Use menu names that are all lower case.
• Use variable names that are all upper case.
• Indent one tab setting within clauses with curly braces ({}).
• Avoid using the Job I/O window if you are using the PMC to multiplex across stations.
• Use this order within an MDF:
a. Declare variables (DECLARE_VARIABLE statements).
b. Define runtime (binning) displays, if any (RUNTIME clauses).
c. Define menus (MENU clauses).
d. Define the top-level, or initial, menu last.
e. Define functions, if any (FUNCTION clauses).
f. Specify initial conditions by defining a function named mdl_startup. If
mdl_startup exists, it is called to set up initial conditions.
ABORT
Used in COMMAND clauses to terminate processing.
ABORT
Example:
COMMAND {
CHECK_STATUS "<command1>" {
IF_FAIL {
"<command2>"
ABORT
}
}
"<command3>"
}
In this example, <command1> is always executed. If <command1> passes, the sequence
continues on to execute <command3>. If <command1> fails, the IF_FAIL clause is processed,
causing <command2> and then ABORT to be executed. Any subsequent commands are not
executed.
ABORT is a predefined command used in the IF_FAIL, IF_PASS, IF_TRUE, or IF_FALSE
clauses of a CHECK_STATUS or CHECK_VARIABLE clause. See “Advanced Commands” on
page 9-29.
ACTIVE
Used in COMMAND clauses. In the example below, ACTIVE is used in a MENU_ITEM clause to
set the active state of the MENU_ITEM. If the quoted string evaluates to zero the item is not
active, otherwise the item is active.
ACTIVE <variable>
where:
<variable> A string that evaluates to zero or one.
Example:
MENU_ITEM "Display Help screen for this menu."{
ACTIVE "$ACTIVE_STATE"
COMMAND {
<commands>
}
}
If a menu item is active, the user can select it. If a menu item is not active, it is grayed out
and cannot be selected.
ANSWER_REMOTE_CALL
Used in COMMAND clauses. If the current command sequence is initiated from a
pmct_call_function, this command answers the calling process back. If no call is waiting,
this clause does nothing.
ANSWER_REMOTE_CALL
Example:
COMMAND <command_name> {
"<command1>"
"<command2>"
ANSWER_REMOTE_CALL
"<command3>"
}
ATTACH
Used in COMMAND clauses to attach a PMC interface to a station.
ATTACH $<variable>
where:
<variable> Contains the station number to connect to the PMC.
Example:
COMMAND {
ATTACH "$NUM"
}
BACK
Used in COMMAND clauses to change the current screen to the previous one.
BACK
Example:
MENU_ITEM "Return to previous menu."{
COMMAND BACK ;
}
This keyword is not used in a menu that appears as the initial screen or in a menu that is
accessed by using the HOME control key.
BAD_UNITS
Used in BINNING_ITEM clauses to name the type of binning used for this item.
BAD_UNITS
Example:
BINNING_ITEM {
FONTSIZE 15
LABEL "Bad Units"
BAD_UNITS
}
BINNING_ITEM
Defines a binning item for the runtime display.
BINNING_ITEM {
<options>
}
where:
<options> Can contain one or all of the following elements:
FONTSIZE Is the point size of the binning item characters in the runtime
display. Default is 12 points.
LABEL<type_of_binning>
Is an optional label to display with the binning item. Enclose in
double quotes. <type_of_binning> can be one of the following
keywords:
UNITS_TESTED
LAST_SORT
LAST_BIN
PERCENT_GOOD
PERCENT_BAD
GOOD_UNITS
BAD_UNITS
Example:
BINNING_ITEM {
FONTSIZE 15
LABEL "Bad Units"
BAD_UNITS
}
CALL_FUNCTION
Used in COMMAND clauses to call a named function.
CALL_FUNCTION "<function_name>"
where:
<function_name> Is the name of a function surrounded by double quotes.
Example:
COMMAND {
CALL_FUNCTION "get_lot_id"
}
FUNCTION get_lot_id {
PRINT_N "Enter the lot id"
READ_RESPONSE $LOT_ID
}
CALLHELP
Used in COMMAND clauses to call up the help screen for the current menu.
CALLHELP
Example:
MENU_ITEM "Display Help screen for this menu." {
COMMAND CALLHELP ;
}
CHANGE_MENU
Used in COMMAND clauses to start a new menu hierarchy.
CHANGE_MENU "<menu_name>"
where:
<menu_name> The name of a menu surrounded by double quotes.
Example:
MENU date_menu {
TITLE "Date" ;
MENU_ITEM "print date" {
COMMAND {
PRINT "The date is as follows:"
"date"
}
}
}
MENU simple_menu {
TITLE "Simple" ;
MENU_ITEM "Bring up date menu" {
COMMAND {
PRINT_N "Are you sure? y or n: "
READ_RESPONSE $TMP ;
CHECK_VARIABLE $TMP == "y" {
IF FALSE {
ABORT
}
}
CHANGE_MENU "date_menu"
}
}
}
The menu named in CHANGE_MENU appears in quotation marks. Menus are defined in any
order. This command is preceded by CHECK_VARIABLE so that the menu a user changes to
is based on the value of a variable or on the return status of a command.
CHECK_STATUS
Used in COMMAND clauses to determine whether a command passes or fails and take action
based on the result.
CHECK_STATUS "<command>" {
[IF_FAIL <cmds>]
[IF_PASS <cmds>]
}
where:
<command> Is a command enclosed in double quotes.
<cmds> Is either a single command followed by a semicolon or a list of
commands enclosed in curly braces.
Example:
COMMAND {
PRINT_N "Enter the letter \"u\": "
READ_RESPONSE $FLAG ;
CHECK_STATUS "date -$FLAG" {
IF_PASS {
PRINT "This is Greenwich Mean Time."
}
IF_FAIL {
PRINT "This command failed."
}
}
}
Example:
COMMAND {
PRINT_N "Enter the letter \"u\": "
READ_RESPONSE $FLAG ;
CHECK_STATUS "date -$FLAG" {
IF_FAIL {
PRINT "This command failed."
ABORT
}
PRINT "This is Greenwich Mean Time."
}
}
When CHECK_STATUS is executed, the first <command> is executed and the exit status is
checked. If the exit status is zero, commands in the IF_PASS clause are executed (if
present). If the exit status is nonzero, commands in the IF_FAIL clause are executed (if
present).
Specify at least one of the IF_FAIL or IF_PASS clauses. It is not required that you specify
both. (See “Advanced Commands” on page 9-29.)
CHECK_VARIABLE
Used in COMMAND clauses to perform logical tests on a variable.
CHECK_VARIABLE $<variable> <op> "<comparestring>" {
[IF_TRUE <cmds>]
[IF_FALSE <cmds>]
}
where:
<variable> Is the variable to examine.
<op> Is the logical operation != or ==.
<comparestring> Is the string to compare the value against. Enclose the string in
double quotes.
<cmds> Is either a single command followed by a semicolon or a list of
commands enclosed in curly braces.
Example:
MENU_ITEM "Remove all files in current directory" {
COMMAND {
PRINT_N "Enter password to continue: "
READ_PASSWORD $PASSWD ;
CHECK_VARIABLE $PASSWD == "apple" {
IF_FALSE {
PRINT ""
PRINT "Incorrect password."
PRINT "No action taken."
PRINT ""
ABORT
}
}
PRINT "Removing all files . . . "
"rm *"
}
}
If the comparison is successful, the commands in the IF_TRUE clause are executed. If the
comparison fails, the commands in the IF_FALSE clause are executed.
Specify at least one of the IF_FAIL or IF_PASS clauses. Both are not required. The example
shows a case in which only an IF_FALSE clause is specified. See “Advanced Commands”
on page 9-29.
CLEAR
Used in COMMAND clauses to clear the window (screen).
CLEAR
This is a predefined command. After the window is cleared with this command, all
subsequent messages printed to the window (screen) start at the top of the output area.
COL
Used in MENU_ITEM, STATUS_ITEM, or DISPLAY clauses to indicate the starting column for
the menu item or display text. Often used together with ROW.
COL <column>
where:
<column> Is a column number on the screen.
Example:
MENU_ITEM "Go to the Stage Menu." {
ROW 5
COL 5
SUBMENU "stage" ;
}
COLLECTIONS
Used in MERGE_COLLECTION clauses to specify the collections to merge.
COLLECTIONS {
"collection_1"
"collection_2"
}
Example:
MERGE_COLLECTIONS "new_collection" {
COLLECTIONS {
"collection_1"
"collection_2"
}
}
COLLECTION_MENU
Used in MENU clauses to create menu items based on the contents of the named collection.
COLLECTION_MENU "<collection>" {
<item_options>
}
where:
<collection> Names the collection from which this item is drawn. Enclose the
collection name in double quotes.
<item_options> Selects the data to create the item and indicates the action to
occur when this item is selected.
Example:
COLLECTION_MENU "collection_1" {
FIELD "field"
RESULT_VARIABLE "RESULT"
COMMAND {
PRINT "Item selected = $RESULT"
}
}
COMMAND
Used in MENU_ITEM or COLLECTION_MENU clauses to specify the commands executed if the
user selects the menu item.
COMMAND <cmds>
where:
<cmds> Is either a single command followed by a semicolon or a list of
commands enclosed in curly braces.
Example:
MENU date {
MENU_ITEM "Print the date." {
COMMAND "date" ;
}
CREATE_COLLECTION
Used in COMMAND clauses to create a new collection file based on the contents of a file or
directory.
CREATE_COLLECTION "<collection>" {
<specifications>
}
where:
<collection> The name of the new collection file enclosed in double quotes.
<specifications> Either the file name used or the directory and file extension used.
Example:
CREATE_COLLECTION "products" {
FILENAME "$MDL_DIR/product_db"
}
CREATE_COLLECTION "workspaces" {
DIRECTORY "$JOB_DIR"
EXTENSION ".tl"
}
The following keywords can appear in a CREATE_COLLECTION clause:
FILENAME A file formatted for use in a collection, see “Collection Files” on
page 9-37. The name must be enclosed in double quotes.
DIRECTORY A list of files in a directory used as a collection. Use this keyword
to specify the directory’s path name. Enclose the path name in
double quotes. This creates a collection that uses the field name
BASENAME, like this:
basename:file_1
basename:file_2
basename:file_3
EXTENSION The collection is the list of files in a directory that has this
extension. The extension is enclosed in double quotes.
DECLARE_VARIABLE
Used at the beginning of an MDF to declare variables used in your MDF.
DECLARE_VARIABLE <variablename> [ = <initial_value> ]
where:
<variablename> Is the name of the variable used.
<initial value> Is the starting value for the variable (optional), enclosed in
double quotes.
Example:
DECLARE_VARIABLE OPERATOR_NAME = "no operator" ;
DECLARE_VARIABLE LINEPRODUCT = "Product: " ;
DECLARE_VARIABLE PRODUCT ;
DECLARE_VARIABLE LINESTATE = "Tester Status: " ;
DECLARE_VARIABLE STATE = "No Job" ;
DECLARE_VARIABLE STAGE ;
<startup conditions>
<menus>
You can also specify variables in the STARTUP clause. Specifying initial values for variables
is optional. (See “Setting Variables” on page 9-22.)
DELETE_COLLECTION
Used in COMMAND clauses to delete a collection.
Format:
DELETE_COLLECTION "<collection>"
where:
<collection> Is the name of the collection deleted enclosed in double quotes.
Example:
DELETE_COLLECTION "products"
DETACH
Used in COMMAND clauses to detach the PMC from a station.
DETACH "$<variable>"
where:
<variable> Contains the station number currently attached to the PMC.
Enclose in double quotes.
Example:
COMMAND {
DETACH "$NUM"
}
DISPLAY
Used in MENU clauses to display text or variables (or both) in specified locations on the menu
screen. Defines content and location of display-only areas on a menu screen.
MENU menu_name {
DISPLAY "<string and/or $VARIABLE>"{
ROW N
COL N
}
<menu items>
}
Example:
MENU menu1 {
TITLE "Menu 1" ;
DISPLAY "$LINEPRODUCT" ;
<menu items>
}
MENU menu2 {
TITLE "Menu 2" ;
DISPLAY "Select an item from this group." {
ROW 20
COL 5
}
<menu items>
}
You can use ROW and COL to specify the starting point for the display. If you do not specify
a row, the display is placed on the next available line. If the location of a menu item conflicts
with the location of a display item, the last item listed is displayed.
The value of a displayed variable can be changed from outside the program, thereby
changing the contents of the display area.
The SIZE keyword is used to truncate DISPLAY text or variable contents as specified.
EXIT
Used in COMMAND clauses to exit the PMC interface.
EXIT
Example:
COMMAND {
EXIT
}
This is a predefined command which causes the PMCtool to exit.
EXTENSION
Indicates the file extension of files selected for a collection file with CREATE_COLLECTION.
EXTENSION "<extension>"
Example:
CREATE_COLLECTION "workspaces" {
DIRECTORY "$JOB_DIR"
EXTENSION ".tl"
}
FIELD
Names the field used to select a subset of records from an existing collection file to create
a new collection file.
FIELD "<fieldname>"
Example:
SELECT_SUBSET "old_collection" {
FIELD "field"
VALUE "$RESULT"
RESULT_COLLECTION "new_collection"
}
FILENAME
Names a file whose contents are used for a new collection created with
CREATE_COLLECTION.
FILENAME "<filename>"
Example:
CREATE_COLLECTION "products" {
FILENAME "$MDL_DIR/product_db"
}
FONTSIZE
Used in BINNING_ITEM and STATUS_ITEM clauses to specify the point size of the characters
for the binning display or status item.
FONTSIZE <number>
where:
<number> The point size used for characters in the binning display.
Example:
BINNING_ITEM {
FONTSIZE 15
LABEL "Bad Units"
BAD_UNITS
}
The default is 12 if FONTSIZE is not specified.
FUNCTION
Specifies the commands executed when CALL_FUNCTION is executed.
FUNCTION <function> <cmds>
where:
<function> A string naming the FUNCTION.
<cmds> A list of COMMANDs enclosed in curly braces.
Example:
COMMAND {
CALL_FUNCTION "get_lot_id"
}
FUNCTION get_lot_id {
PRINT_N "Enter the lot id"
READ_RESPONSE $LOT_ID
}
Keywords used in COMMAND clauses can also be used in FUNCTION clauses.
GOOD_UNITS
Names the type of binning used for this item.
GOOD_UNITS
Example:
BINNING_ITEM {
FONTSIZE 15
LABEL "Good Units"
GOOD_UNITS
}
HELP
Used in MENU clauses, appearing before menu items, or MENU_ITEM clauses, before the
commands for that item. Specifies help string(s) provided to the user for a given menu.
HELP "<strings>"
where:
MENU_ITEM {
HELP {
"This is help for the menu item"
<cmds>
}
}
}
When the user activates the HELP function button with a menu displayed on the screen, the
messages printed in response are the strings specified in the HELP clause for that menu.
The user can then select help for an item.
HOME
Used to change the screen to the HOME screen.
HOME
Example:
MENU_ITEM "Change to the Home menu." {
COMMAND HOME ;
}
If the HOME screen is not defined in the MDF, the screen changes to the initial screen when
this item is chosen.
IF_FAIL
Names the command(s) to execute if the command specified in CHECK_STATUS exits with a
nonzero status.
IF_FAIL <cmds>
where:
<cmds> Is either a single command followed by a semicolon or a list of
commands enclosed in curly braces.
Example:
COMMAND {
PRINT_N "Enter the letter \"u\": "
READ_RESPONSE $FLAG ;
CHECK_STATUS "date -$FLAG" {
IF_PASS {
PRINT "This is Greenwich Mean Time."
}
IF_FAIL {
PRINT "This command failed."
}
}
}
See “CHECK_STATUS” on page 9-54 and “IF_PASS” on page 9-64.
IF_FALSE
Names the command(s) executed if the comparison specified in CHECK_VARIABLE fails.
IF_FALSE <cmds>
where:
<cmds> Is either a single command followed by a semicolon or a list of
commands enclosed in curly braces.
Example:
MENU_ITEM "Remove all files in current directory" {
COMMAND {
PRINT_N "Enter password to continue: "
READ_PASSWORD $PASSWD ;
CHECK_VARIABLE $PASSWD == "apple" {
IF_FALSE {
PRINT ""
PRINT "Incorrect password."
PRINT "No action taken."
PRINT ""
ABORT
}
}
PRINT "Removing all files . . . "
"rm *"
}
}
See “CHECK_VARIABLE” on page 9-55 and “IF_TRUE” on page 9-65.
IF_PASS
Names command(s) executed if the command specified in CHECK_STATUS exits with a zero
status.
IF_PASS <cmds>
where:
<cmds> Is either a single command followed by a semicolon or a list of
commands enclosed in curly braces.
Example:
COMMAND {
PRINT_N "Enter the letter \"u\": "
READ_RESPONSE $FLAG ;
CHECK_STATUS "date -$FLAG" {
IF_PASS {
PRINT "This is Greenwich Mean Time."
}
IF_FAIL {
PRINT "This command failed."
}
}
}
See “CHECK_STATUS” on page 9-54 and “IF_FAIL” on page 9-63.
IF_TRUE
Names command(s) to execute if the comparison specified in CHECK_VARIABLE is true.
IF_TRUE <cmds>
where:
<cmds> Is either a single command followed by a semicolon or a list of
commands enclosed in curly braces.
Example:
CHECK_VARIABLE $STAGE == " " {
IF_TRUE {
PRINT "no stage"
ABORT
}
}
See “CHECK_VARIABLE” on page 9-55 and “IF_FALSE” on page 9-64.
LABEL
Provides a string displayed for a binning item in the runtime window.
LABEL "<string>"
where:
<string> Is the label you want displayed, enclosed in double quotes.
Example:
BINNING_ITEM {
FONTSIZE 15
LABEL "Bad Units"
BAD_UNITS
}
See “BINNING_ITEM” on page 9-52.
LAST_BIN
Names the type of binning used for this item.
LAST_BIN
Example:
BINNING_ITEM {
FONTSIZE 15
LABEL "Software Bin"
LAST_BIN
}
See “BINNING_ITEM” on page 9-52.
LAST_SORT
Names the type of binning used for this item.
LAST_SORT
Example:
BINNING_ITEM {
FONTSIZE 15
LABEL "Hardware Bin"
LAST_SORT
}
See “BINNING_ITEM” on page 9-52.
LOAD_MDL_FILE
Used in COMMAND clauses to load an auxiliary file.
LOAD_MDL_FILE "<filename>"
where:
<filename> Is the name of the file surrounded by double quotes.
Example:
COMMAND {
LOAD_MDL_FILE "/u/test/jobs/$PRODUCT/$PRODUCT.mdl"
SUBMENU "SPECIAL_MENU"
}
The contents of the named file are added to the list of menus and functions available to the
SUBMENU and CALL_FUNCTION clauses.
If the file contains a runtime display, its runtime display overrides the previous runtime
display.
This action is also available using the PMC talk library. See “PMC Library” on page 9-43.
MENU
Defines a menu. A MENU clause can contain the following elements: TITLE, HELP, and
OPTIONS. They must precede definitions of menu items.
MENU <identifier> {
<options>
<menu items>
}
where:
<identifier> Is a unique alphanumeric identifier assigned to the menu being
defined.
<options> Can contain the following clauses: HELP, TITLE, OPTIONS,
DISPLAY, SUPPRESS.
COMMAND {
CHECK_VARIABLE $JOBNAME== "" {
IF_TRUE {
PRINT "You must enter a program name."
}
PRINT "Loading Program ..."
"load $JOBNAME"
}
}
}
<identifier> Is the menu identifier (required), a unique name composed of
lowercase alphanumeric characters. It can include the
underscore character.
TITLE clause Is optional. The title text starts in row zero, column zero of the
screen. To move the title toward the center, add blank spaces
after the opening quotation mark, as shown in the example. See
“TITLE” on page 9-82.
HELP clause Is optional. Enter one or more lines of text, each line surrounded
by quotation marks. This text appears if the user activates the
HELP control button while this menu is being displayed. See
“HELP” on page 9-62.
OPTIONS clause Is optional. This clause can contain QUIT_MENU_ON_SELECTION.
Use it if this menu is one that will revert to the previous menu
after the user makes a selection. See “OPTIONS” on page 9-70.
DISPLAY clause Is optional. Enter one or more lines of text and/or variables you
want displayed when this menu is on the screen. See “DISPLAY”
on page 9-60.
SUPPRESS clause Is optional. Enter the names of function buttons you do not want
to appear while this menu is on the screen. See “SUPPRESS”
on page 9-81.
COLLECTION_MENU Is optional. Creates menu items based on the contents of the
named collection.
<menu items> Define the selections in the menu. Each menu item is made up
of the keyword MENU_ITEM, followed by the menu item name in
quotes (which is displayed on the menu as the menu selection),
and then a series of optional keywords and/or clauses
surrounded by curly brackets (which represent the actions to
occur if the item is selected). See “MENU_ITEM” on page 9-68.
MENU_ITEM
Defines a new menu item for the menu enclosing it.
MENU_ITEM "<item_name>" {
<options>
COMMAND {
<cmds>
}
}
where:
<item_name> Is a quoted string displayed as the item selection. Enclose in
double quotes.
<options> Include COL, ROW, SIZE, and HELP.
<cmds> Consists of one or more commands that appear in a COMMAND
clause. See “COMMAND” on page 9-57.
Example:
MENU_ITEM "Lot ID"
COMMAND {
PRINT_N "Enter Lot ID: "
READ_RESPONSE $LOTID ;
}
}
A MENU_ITEM clause can contain the following:
"<item_name>" Required. This quoted string appears on the menu screen as the
menu item.
COL Optional. Specifies column number in which the item starts.
ROW Optional. Specifies row number in which the item starts.
SIZE Optional. Specifies the maximum number of characters that a
menu item name can have. Subsequent characters are not
displayed.
HELP Optional. Specifies strings to be displayed when user requests
help.
COMMAND clause Contains the commands and/or checks executed if this item is
selected.
MERGE_COLLECTIONS
Used to combine all named collection files into one collection file.
MERGE_COLLECTIONS "<new_collection>" {
COLLECTIONS {
"<collection_a>"
"<collection_b>"
}
}
where:
"<new_collection>" Is the name used for the resulting merged collection file,
enclosed in double quotes.
"<collection_X>" Names the collection files merged.
Example:
MERGE_COLLECTIONS "all_products" {
COLLECTIONS {
"abc"
"xyz"
}
}
Collections are renamed by specifying the old collection file name after COLLECTIONS.
Example:
MERGE_COLLECTIONS "new_name" {
COLLECTIONS {
"old_name"
}
}
NUM_COLS
Used in MENU clauses. Cannot be used with ROW or COL. Specifies the maximum number of
columns to display menu items or display items in the PMC window. Default value is one.
NUM_COLS <number>
Example:
MENU menu1 {
TITLE "DATE MENU" ;
NUM_COLS 2
<menu items>
}
OPTIONS
Specifies optional information about a menu definition. OPTIONS appears in a MENU clause,
before the definition of a menu item.
OPTIONS { <option keywords> }
Example:
MENU menu1 {
TITLE "DATE MENU" ;
OPTIONS { QUIT_MENU_ON_SELECTION ; }
<menu items>
}
PERCENT_BAD
Names the type of binning used for this item.
PERCENT_BAD
Example:
BINNING_ITEM {
FONTSIZE 15
LABEL "Percent Bad"
PERCENT_BAD
}
See “BINNING_ITEM” on page 9-52.
PERCENT_GOOD
Names the type of binning used for this item.
PERCENT_GOOD
Example:
BINNING_ITEM {
FONTSIZE 15
LABEL "Percent Good"
PERCENT_GOOD
}
See “BINNING_ITEM” on page 9-52.
PGDN
Used in COMMAND clauses to page down when information does not fit on one screen.
PGDN
Example:
MENU_ITEM "Go to next page of data." {
COMMAND PGDN ;
}
PGUP
Used in COMMAND clauses to page up when information does not fit on one screen.
PGUP
Example:
PRINT
Outputs the specified string to the user.
PRINT "<string>"
where:
"<string>" Is an ASCII string, which can include variables, surrounded by
double quotes.
Example:
MENU_ITEM "Sign In" {
COMMAND {
PRINT_N "Sign in to continue: "
READ_RESPONSE $SIGNIN ;
PRINT "Welcome to the system, $SIGNIN."
}
}
PRINT is used in COMMAND clauses within menu items, to display text and/or variable
contents. The displayed string is treated as an entire line of output.
To display text or variable contents associated with a menu rather than with a menu item,
use DISPLAY.
PRINT_N
PRINT_N is used in COMMAND clauses within menu items to display text and/or variable
contents. Outputs the specified string to the user with no new-line character.
PRINT_N "<string>"
where:
<string> Is an ASCII string surrounded by double quotes, which can
include variables.
Example:
MENU_ITEM "Sign In" {
COMMAND {
PRINT_N "Sign in to continue: "
READ_RESPONSE $SIGNIN ;
PRINT "Welcome to the system, $SIGNIN."
}
}
The string displayed does not have a new-line character at its end. Subsequent output or
input will appear on the same line.
To display text or variable contents associated with a menu rather than with menu items,
use DISPLAY.
QUIT_MENU_ON_SELECTION
Appears in the OPTIONS clause of a menu definition. Defines the current menu as
temporary, control switches back to the previous menu immediately after a selection is
made from the current menu.
OPTIONS { QUIT_MENU_ON_SELECTION ; }
Example:
MENU menu1 {
TITLE "DATE MENU" ;
OPTIONS { QUIT_MENU_ON_SELECTION ; }
<menu items>
}
When this keyword is present, the menu defined is considered a temporary, or transient,
menu. Although selections and format appear similar to other menus, the screen display
reverts to the previous menu immediately after a user makes a selection from a temporary
menu. With normal menus, the menu display remains until the user explicitly chooses to exit
the menu.
The top level (initial) menu cannot be specified as a temporary menu. Temporary menus
cannot have menu items that invoke submenus.
READ_PASSWORD
Used in a COMMAND clause to read input from the user without echoing it on the screen. The
user’s entry is placed into a variable for later use.
READ_PASSWORD $<variable>
where:
<variable> Is a variable that receives the text of the user’s input.
Example:
MENU_ITEM "Remove all files in current directory" {
COMMAND {
PRINT_N "Enter password to continue: "
READ_PASSWORD $PASSWD ;
CHECK_VARIABLE $PASSWD == "apple" {
IF_FALSE {
PRINT ""
PRINT "Incorrect password."
PRINT "No action taken."
PRINT ""
ABORT
}
}
READ_RESPONSE
Used in a COMMAND clause to read input from the user into a variable that can be used later.
READ_RESPONSE $<variable>
where:
<variable> Is the variable where the line of input is stored.
Example:
COMMAND {
PRINT "Enter a line of input:"
READ_RESPONSE $TMP_RESPONSE ;
PRINT "The line was: $TMP_RESPONSE"
}
RESULT_COLLECTION
Used in SELECT_SUBSET items, which are found in COMMAND clauses. Names a new
collection resulting from the selection of a subset of records from an existing collection
based on the matching of a value in a field.
RESULT_COLLECTION "<string>"
where:
<string> Is the name for the new collection file, surrounded by double
quotes.
Example:
SELECT_SUBSET "old_collection" {
FIELD "field"
VALUE "$RESULT"
RESULT_COLLECTION "new_collection"
}
RESULT_VARIABLE
Names a variable holding the result of a PMC action in one of the following clauses:
COLLECTION_MENU, TOTAL_UNIQUE_VALUES, SELECT_FIELD, or TOTAL_RECORDS.
RESULT_VARIABLE "<variable>"
where:
<variable> Names the variable in which to put the result of the previous
action.
Example:
CHECK_VARIABLE $TOTAL == "1" {
IF_TRUE {
SELECT_FIELD "y_col" {
FIELD "Y"
RESULT_VARIABLE "Y_VAR"
}
PRINT "X = $X_VAR, Y = $Y_VAR"
}
IF_FALSE {
SUBMENU "y_menu"
}
}
ROW
Used in a MENU_ITEM, STATUS_ITEM, or DISPLAY clauses to place the menu item, status
item, or display text in a specific row on the screen. Often used with COL to specify an exact
location on the screen.
ROW <row>
where:
<row> Is a row number on the screen.
Example:
DISPLAY "Select a menu item by entering its number." {
ROW 20
<commands>
}
MENU_ITEM "Stage: $STAGE" {
ROW 5
COL 5
<commands>
}
RUNTIME
Defines status items and binning items for the runtime display.
RUNTIME {
BINNING_ITEM {
<bin_setup>
}
STATUS_ITEM {
<status_setup>
}
}
where:
<bin_setup> Includes the binning setup keywords FONTSIZE, LABEL, and their
values, as well as the type of binning: BAD_UNITS, GOOD_UNITS,
LAST_BIN, LAST_SORT, PERCENT_BAD, PERCENT_GOOD, and
UNITS_TESTED.
<status_setup> Includes the status setup keywords ROW, COL, FONTSIZE, SIZE,
VARIABLE, and LABEL.
Example:
RUNTIME {
BINNING ITEM {
FONTSIZE 12
LABEL "Hardware Bin"
LAST_SORT
}
STATUS_ITEM {
ROW 1
COL 1
FONTSIZE 12
SIZE 25kill
VARIABLE $product
LABEL "Part Type"
}
}
Only one runtime display is allowed. If an auxiliary file is loaded and contains a runtime
display, that runtime display overrides the previous runtime display. (The last runtime
display loaded is always the one displayed.)
SCRIPT
Used in COMMAND clauses to execute a block of shell script code.
SCRIPT "<shell_program>" {
<shell_code>
}
where:
<shell_program> Is the shell program, such as /bin/sh or /bin/csh, surrounded
by double quotes.
SELECT_FIELD
Used in COMMAND clauses to stuff RESULT_VARIABLE with the values of FIELD found in the
named collection.
SELECT_FIELD "<collection_name>" {
FIELD "<field_name>"
RESULT_VARIABLE "<variable>"
}
where:
<collection> Is the collection from which you want to select values. The
collection name is surrounded by double quotes.
<field> Names the field from which unique values are selected. The field
name is surrounded by double quotes.
<variable> Names the variable into which the values are placed. The
variable name is surrounded by double quotes.
Example:
CHECK_VARIABLE $TOTAL == "1" {
IF_TRUE {
SELECT_FIELD "y_col" {
FIELD "Y"
RESULT_VARIABLE "Y_VAR"
}
PRINT "X = $X_VAR, Y = $Y_VAR"
}
IF_FALSE {
SUBMENU y_menu
}
}
If there are multiple values for the field, each unique value will appear once in
RESULT_VARIABLE, separated from other values with a space.
SELECT_SUBSET
Selects from an existing collection, records in which the value of a specified field matches
a given value and creates a new collection file composed of that subset.
SELECT_SUBSET "<old_collection>" {
<selection_items>
}
where:
<old_collection> Is the collection from which you want to select a subset of
records, enclosed in double quotes.
<selection_items> Includes: FIELD, VALUE, and RESULT_COLLECTION.
Example:
SELECT_SUBSET "old_collection" {
FIELD "field"
VALUE "$RESULT"
RESULT_COLLECTION "new_collection"
}
SHOW_SERVICE
Used in COMMAND clauses to bring up the named service window.
SHOW_SERVICE "<service_window>"
where:
<service_window> Is one of the following enclosed in double quotes:
MDL_SVC_JOBIO
MDL_SVC_DATALOG
MDL_SVC_RUNTIME
Example:
SHOW_SERVICE "MDL_SVC_DATALOG"
SIZE
Used in a MENU_ITEM, STATUS_ITEM, or DISPLAY clause to limit the number of characters
displayed.
SIZE <number>
Example:
DISPLAY "The job is $JOBNAME" {
ROW 20
COL 40
SIZE 20
}
Often used with ROW and COL to specify the exact beginning and ending location of text on
the screen. Any text that does not fit into the specified area is truncated. The default size is
(maximum columns - starting column).
STARTUP
Specifies a command or commands to be executed and a variable or variables to be
initialized when the menu interface is started up.
STARTUP <commands>
where:
<commands> Is either a single command followed by a semicolon or a list of
commands enclosed in curly braces.
Example:
DECLARE_VARIABLE USER_NAME ;
STARTUP {
PRINT "Starting menu interface..." #Print startup message
PRINT ""
PRINT_N "The current date is: "
"date"
"USER_NAME = unknown" #Initialize variable
"MDL_USR_HOMESCR = control" #Specify home screen
"MDL_USR_INITSCR = signin" #Specify initial screen
}
MENU menu1{
<menu items>
}
See “Specifying Startup Conditions” on page 9-24.
STATUS_ITEM
Defines a status item to appear in the runtime display.
STATUS_ITEM {
<descriptors>
}
where:
<descriptors> Is the set of values that define where and how the item appears
in the display, as well as the content it holds.
ROW Is the starting row on the screen for the item.
COL Is the starting column on the screen for the item.
FONTSIZE Is the size of characters displayed in points. The default is 12.
SIZE Is the maximum number of characters to appear in the item.
VARIABLE Is the variable whose content appears in the item.
LABEL Is a string to appear with the item, surrounded by double quotes.
Example:
STATUS_ITEM {
ROW 1
COL 1
FONTSIZE 12
SIZE 25
VARIABLE $product
LABEL "Part Type:"
}
SUBMENU
Used in COMMAND clauses to specify a menu displayed at the end of a command sequence.
SUBMENU "<menu_name>"
where:
<menu_name> Is the name of the menu displayed when this item is selected.
Enclose the menu in double quotes.
Example:
MENU date_menu {
TITLE "Date" ;
MENU_ITEM "print date" {
COMMAND {
PRINT "The date is as follows:"
"date"
}
}
}
MENU simple_menu {
TITLE "Simple" ;
MENU_ITEM "Bring up date menu" {
COMMAND {
PRINT_N "Are you sure? y or n: "
READ_RESPONSE $TMP ;
CHECK_VARIABLE $TMP == "y" {
IF FALSE {
ABORT
}
}
SUBMENU "date_menu"
}
}
}
This command can be preceded by a CHECK_VARIABLE or CHECK_STATUS command so that
the menu the display changes to (the one named with SUBMENU) is based on the value of a
variable or on the return status of a command rather than the user’s explicit selection of a
new menu. See “Defining Menus and Menu Items” on page 9-25.
SUPPRESS
Inhibits the appearance of the named function buttons on the menu screen in which the
command appears.
SUPPRESS {
<string>
}
where:
<string> Consists of one or more of the following keywords:
MDL_BTN_HELP
MDL_BTN_BACK
MDL_BTN_HOME
MDL_BTN_PREV
MDL_BTN_NEXT
MDL_BTN_RUN
MDL_BTN_ABORT
Example:
MENU setup {
TITLE "Setup" ;
SUPPRESS {
MDL_BTN_HOME
MDL_BTN_RUN
MDL_BTN_ABORT
}
<menu items>
}
Functions and positions of PMC function buttons are predefined and fixed. You cannot
change them. You can, however, suppress the appearance of the labels of one or more of
the buttons on any menu screen. See “Control Buttons” on page 9-9.
The label on the button INFO/ERROR appears only when there are pending informational
messages (INFO) or error messages (ERROR) from the test system.
Buttons can also be suppressed by setting the variable corresponding to the button’s name
to zero. For example, to suppress the HOME button:
MDL_BTN_HOME = 0
TITLE
Used in a MENU clause, before the menu items are defined to specify the title displayed for
a particular menu.
TITLE <strings>
where:
<strings> Is a single string followed by a semicolon or a list of strings
enclosed in curly braces. Each string on a different line is
enclosed in double quotes.
Example:
MENU stage {
TITLE "Stages" ;
HELP {
"Select your Production Stage from these"
"choices: Probe, Final, or Manual Test"
}
<menu items>
}
MENU signin {
TITLE {
" ** WELCOME TO PMC ** "
""
" Sign-In Screen "
}
<menu items>
}
The title for a menu is the text printed on the screen above the menu selections. For
instance, the first example above would display
Stages
(1) Item 1
Selection:
Titles normally start in the same column as menu items. To move a title to the right (toward
the center of the screen), add spaces after the opening quotation mark, before the text. The
second example above would create this display:
** WELCOME TO PMC **
Sign-In Screen
(1) Item 1
Selection:
TOTAL_RECORDS
Used in COMMAND clauses to count the number of records in the named collection file.
TOTAL_RECORDS "<collection>" {
RESULT_VARIABLE "<variable>"
}
where:
<collection> Is the collection file for which you want to know the total number
of records, surrounded by double quotes.
<variable> Is the variable into which you want the number placed,
surrounded by double quotes.
Example:
TOTAL_RECORDS "all_products" {
RESULT_VARIABLE "total_records"
}
This example uses RESULT_VARIABLE to place the number of records in a variable.
TOTAL_UNIQUE_VALUES
Used in COMMAND clauses to count the number of unique values in the named field.
TOTAL_UNIQUE_VALUES "<collection>" {
FIELD "<field>"
RESULT_VARIABLE "<variable>"
}
where:
<collection> Is the collection file for which you want to know the total number
of unique values in a field, surrounded by double quotes.
<field> Is the field of unique values you want counted, enclosed in
double quotes.
<variable> Is the variable in which you want the number placed, surrounded
by double quotes.
Example:
TOTAL_UNIQUE_VALUES "all_products" {
FIELD "Product_ID"
RESULT_VARIABLE "total_products"
}
This example uses RESULT_VARIABLE to place the number of unique values in a variable.
UNITS_TESTED
Names the type of binning used for this item.
UNITS_TESTED
Example:
BINNING_ITEM {
FONTSIZE 15
LABEL "Units Tested"
UNITS_TESTED
}
UNLOAD_MDL_FILE
Used in COMMAND clauses to unload an auxiliary file.
UNLOAD_MDL_FILE "<filename>"
where:
<filename> Is the name of the file, surrounded by double quotes.
Example:
COMMAND {
UNLOAD_MDL_FILE "/u/test/jobs/$PRODUCT/$PRODUCT.mdl"
}
If the file contained the active runtime display, the active runtime display reverts to what it
was before this file was loaded.
The contents of the named file are removed from the list of menus and command clauses
available to the SUBMENU and CALL_FUNCTION clauses.
This action is also available through the PMC talk library. See “PMC Library” on page 9-43.
UNSHOW_SERVICE
Used in COMMAND clauses to close the named service window.
UNSHOW_SERVICE "<service_window>"
where:
<service_window> Is one of the following enclosed in double quotes:
MDL_SVC_JOBIO
MDL_SVC_DATALOG
MDL_SVC_RUNTIME
Example:
UNSHOW_SERVICE "MDL_SVC_DATALOG"
VALUE
Used in SELECT_SUBSET items, which are found in COMMAND clauses. Specifies a value to
match to create a new collection file containing a subset of records from an existing
collection file.
VALUE "<$var>"
where:
<$var> Contains the value you want to match enclosed in double
quotes.
Example:
SELECT_SUBSET "old_collection" {
FIELD "field"
VALUE "$RESULT"
RESULT_COLLECTION "new_collection"
}
VARIABLE
Used in STATUS_ITEM clauses. Defines a variable to appear in a status item in the runtime
display.
VARIABLE <$var>
where:
<$var> Contains the value of a defined variable.
Example:
STATUS_ITEM {
ROW 1
COL 1
FONTSIZE 12
SIZE 25
VARIABLE $product
LABEL "Part Type:"
}
10 WAFER MAPPING
This section describes IMAGE utilities for wafer mapping. It includes the following topics:
• “IMAGE Real Time Wafermap” on page 10-2
• “FIRMS Wafer Mapping” on page 10-19
• “Wafer Mapping for Off-Line Inking” on page 10-23
4. Connect the Real Time Wafermap to the station where the test program is loaded. (See
“Connecting to a Station” on page 10-4.) If the wafermap is started from a station window
that has a test program loaded, the wafermap will automatically connect. The
appropriate preview file is also loaded.
5. Run the test program.
At this point, wafer results begin to appear. The default wafermap shows pass/fail results in
color. If your wafer preview file includes coordinate pairs for the wafer die, you will also see
a map of the entire wafer showing both tested and untested dice.
NOTE
Restart the wafermap each time a new test program is loaded. If the wafermap is not
restarted, it may display an incorrect quadrant directional.
color Display test results for each die using a color. (This
is the default.)
code Display test results for each die using a code. (See
“Creating a Scramble File” on page 10-8.)
value Display test results for each die using a bin value.
Value displayed is the one selected using -variable.
texture Display test results for each die using a texture.
(Used for monochrome monitors.)
color+code Display test results for each die using a color
and a code. (See “Creating a Scramble File” on page 10-8.)
color+value Display test results for each die using a color
and a bin value. Value displayed is the one selected using
-variable.
Connecting to a Station
The Real Time Wafermap automatically tries to connect to the station specified by the
environmental variable STATION_NUMBER when you start it, unless you use the -station
switch. If you start the wafermap from a station window, it is set to the current station
number. If you start the program outside a station window, the wafermap comes up not
connected to any station unless you use the -station switch. The current station is shown
in the title bar.
To connect to a station after the tool is started, select the desired station number using the
STATION>CONNECT menu. This menu lists all 10 possible stations.
An error can occur during connection if you try to connect to a station and:
• That station does not exist
• No test program is loaded
NOTE
If the TESTER_NUMBER environment variable is not set before the Real Time Wafermap is
started, the station menu is grayed out and connections are not allowed. This variable is
required to retrieve information on IMAGE stations. This is only an issue when running
IMAGE remotely.
original preview file does not include coordinates, a preview map is displayed by the
time the second wafer is tested.
The Real Time Wafermap indicates the die at location (0,0) on the preview display by
labelling it (0,0) (see figure 10-2).
3. You can specify the axis orientation in your wafermap preview (.wmap_preview) file by
adding the following lines:
POSX R [or POSX L]
POSY D [or POSY U]
These statements preset which way the axes run on the display, where X can increase
to the right or left and Y can increase up or down. Specifying axis orientation in the
preview file overrides directions specified in the set wafer statement of your test
program (see “Using the set wafer Statement” on page 10-19). You cannot specify axis
orientation in a .wafr file.
4. Name the preview file using <program_name>.wmap_preview. This file becomes the
default file and is automatically read when a connection is attempted. If this file or a
.wafr file for the test program does not exist or has an error, connection does not occur.
NOTE
Any device result received with coordinates outside the maximum and minimum
coordinates defined in the preview file is ignored.
The WRR record indicates that the wafer run has ended. This record is generated by a
tl_dlg_endwafer() statement used in the test program. Include startwafer and endwafer
statements in the following handler/prober callbacks inside the test program:
tl_handlerprober_cond_eow()
tl_handlerprober_cond_eol()
tl_handlerprober_cond_eoc()
These functions indicate end-of-wafer, end-of-lot, and end-of-cassette respectively. (For
information on the WRR, see “Wafer Results Record (WRR)” on page 24-36 and the
Standard Test Data Format Specification. See also “Using Callback Functions” on page
1-35 of the Handler/Prober Manual.)
WIR and WRR records also contain a wafer ID field used to label the wafer. To set this field,
add a tl_set_wafer_id() statement to the test program. The wafermap tool displays this
wafer ID along with the wafer start and end times for every wafer tested in the lot, up to the
maximum number of wafers (50). If a wafer ID is not set in the test program, a default ID of
Wafer <#> is used.
Your test program must include a device_bin statement. This statement controls the pass/
fail drawing of the devices. If the statement is not in the test program, the wafer will draw
incorrect results.
Starting a new lot clears all wafer data from the wafermap tool in preparation for receiving
the new lot data.
If the Real Time Wafermap is connected to a test program after it was run, all prior results
are not sent to the tool. Only the most current wafer information and then the subsequent
die results are received by the wafermap.
Figure 10-3. Main Real Time Wafermap Window Displaying Coded Software Bins
File Menu
The FILE menu contains selections that allow you to manipulate files used with the Real
Time Wafermap. Selections include the following:
FILE>LOAD This menu allows you to load files into the wafermap. Selections
include the following:
LOAD STDF FILE Brings up the Load STDF file window (figure
10-4) and allows you to load any file with a .stdf extension.
View Menu
The VIEW menu contains selections that allow you to manipulate the display and to see
which files are in use. Selections include the following:
VIEW MASK... Brings up the Wafermap View Mask window (figure 10-8) that
allows you to specify criteria to draw specific dice. A choice item
allows you to select the display variable and a mask value line
where you can enter a value to match. The button, DRAW
SELECTED DICE allows you to draw the dice that match the
variable and value specified. The button CLEAR DICE clears the
wafer display. The button REDRAW ALL redraws the entire wafer.
(See “Using View Mask to Mask the Display” on page 10-17.)
FILE INFO... Brings up the File Information window (figure 10-9) showing the
names of the preview, scramble and STDF files currently in use.
Station Menu
The STATION menu allows you to connect and disconnect the Real Time Wafer map to test
stations. It has the following selections:
CONNECT Connects the wafermap to a test station. This item has a menu
listing all 10 stations that the wafermap can connect to. The
default choice for the CONNECT menu is the station where the
application was started from or the last connected station. This
default station is shown in the title bar. Click STATION to connect
to the default station.
DISCONNECT Disconnects the wafermap from the current station.
Properties Button
The PROPS... button opens the Wafermap Properties window (figure 10-10) which contains
three wafermap default properties. They are DISPLAY VARIABLE, DISPLAY MODE, and
CONDENSED STATISTICS. The variables determine what variable and mode is displayed
when the Real Time Wafermap is started and whether the statistics are displayed in
condensed or noncondensed (normal) mode. The default variable is PASS/FAIL, the default
mode is COLOR, and the default for condensed statistics is FALSE.
These properties are stored in the .Xdefaults file in the IMAGE section under
image.wafermap.display.variable, image.wafermap.display.mode, and
image.wafermap.display.condensed_stats. These values correspond to the choice
items in the Display Variable and Display Mode controls and the NORMAL/CONDENSED
STATISTICS BUTTONS in the Real Time Wafermap display (see figure 10-3 on page 10-11).
For example, if you want the default for the display to be hardware bin data, set the DISPLAY
VARIABLE to HW BIN. The wafermap will automatically start using hardware bins as the
default.
Figure 10-11. Main Real Time Wafermap Window Displaying Condensed Statistics
the pinmap must have a site clause and you can use variables to specify the site number
and the offsets.
The [x,y] specifies the position of prober sites relative to site 0. For example (figure 10-
12), offset [2,3] means the prober needle is two die positions to the right and three die
positions up from the [0,0] site.
Offset [2,3]
x
Site 0
x
The compiler checks that you have written the site clause correctly and that the number of
sites specified is less than the maximum allowed by IMAGE. The compiler prints an error
message if these two conditions are not met.
Runtime checks are performed to assure that:
• A site 0 is specified
• No site is specified more than once.
• All site numbers are within limits (greater than or equal to zero and less than the total
number of sites declared in the pinmap minus one)
• A site specification exists for each site declared in the pinmap.
• One site with [0,0] offset is declared
• No offset is specified more than once.
A site can have no offset. That is, it can have offset [0,0]. The positions of the other prober
needles are specified as offsets relative to this site. Examples are shown below. Some of
these configurations may be imaginary and are used only as examples. In each figure, the
x’s mark the positions of the prober needles on the wafer.
site: 3 = [3,-3]
;
Site 0
Site 1 x
x
x
Site 2 x
Site 3
Site 3
Site 2 x
x
x
Site 1 x
Site 0
Site 0
Site 1
Site 2 x x
x x
Site 3
Set the wafer_id of a particular wafer using the tl_set_wafer_id() function. This is a
void type function that expects a pointer to a character string as its argument. The
wafer_id must conform to the STDF standard governing variable length strings and must
not exceed 255 bytes in length.
The code to set the wafer identification to Image_wafer_1 would look like
void tl_set_wafer_id(); /* Declare the function in the header */
char *wafer_id = "Image_wafer_1";/* Declare variable to hold wafer ID */
test program you are using. This file must have the extension .wafr and is made up of four
sections:
• ROW list
• INK list
• SKIP list
• PROBE list
The ROW list specifies die positions on the wafer including partial die, landmarks, and ugly
die. You can exclude (that is, not test) later partial die and other locations in each row by
specifying the locations in either the INK or SKIP lists. All die specified in the ROW list are
ultimately binned, either by actual testing or by being assigned an ink bin, in the case of ink
and skip die. You can set the ink bin using the tl_set_wafer_mapping_ink_bin()
function.
Ink die and skip die are ultimately treated alike—both are inked. The distinction is made only
for conceptual purposes so that you can distinguish between ugly die and landmarks on the
wafer.
An example of a wafer configuration file would be as follows:
# Probe Quadrant 1
#
ROW
X0,Y0,X-3
X0,Y-1,X-3
X1,Y-2,X-4
X1,Y-3,X-4
X0,Y-4,X-3
X0,Y-5,X-3
INK
X0,Y0,X0
X-3,Y-1,X-3
X1,Y-2,X1
X-4,Y-3,X-4
X0,Y-4,X0
X-3,Y-5,X-3
SKIP
X-3,Y0,X-3
X-1,Y-1,X-1
X-4,Y-2,X-4
X-1,Y-3,X-1
X-3,Y-4,X-3
X0,Y-5,X0
PROBE
X0,Y-1,X-2
X1,Y-3,X-3
X0,Y-5,X-2
You can use the wafer configuration file (.wafr) for a test program as your wafermap
preview file (see “Creating a Preview File” on page 10-5). The wafermap program allows a
.wafr file anywhere it would allow a .wmap_preview file. If no .wmap_preview file is located
for a program, the wafermap display looks for a .wafr file and uses that. The wafermap
display can even read a .wafr file, then generate a .wmap_preview file that you can edit.
The wafermap calculates the MIN and MAX for X and Y from the ROW entries and calculates
the preview dice from the INK, SKIP, and PROBE entries.
The wafer configuration file also allows you to specify the order in which dice are probed. In
fact, the mapping software assumes you have defined the probe pattern. If the prober is
allowed to select its own probe pattern, wafers in a particular lot may not be probed in
exactly the same way, making the maps invalid.
The wafer configuration file specifies only the location of dice on a wafer. You must specify
other wafer information, such as wafer units, die size, orientation of the positive x and y axis,
using the set wafer statement. For multisite probing, you must also include orientation of
the probe needles which is essential to wafer mapping.
Y+ Y+
X- X+ X- X+
X2 X2
X1 X1
Y+ Y+
X2 X2
X1 X1
X- X+ X- X+
Y- X1 = (2, 2) X1 = (-1, 2) Y-
Quadrant 3 X2 = (1, 4) X2 = (-2, 4) Quadrant 4
The first die need not be assigned the preset value of (0,0). If a value, say (x,y) other than
(0,0) is selected, this serves to identify that the first die is (x,y) die locations away from the
origin. In this case, each die specified is in die steps from the origin not from the first die
(since the first die is not the origin in this case). Note that the value selected for FIRST may
locate the origin off the wafer.
For Electroglas probers, you set the preset value using the menu selection called PRESET.
To assign this value to a particular die, you must physically move the die under the probe
needle and press the FIRST key. You must also select the prober quadrant.
You must express the ROW, SKIP, INK, and PROBE lists according to the coordinate system
of the prober quadrant chosen. If for some reason a wafer configuration file is written for a
particular prober quadrant and you choose another, you must change the coordinates in the
wafer configuration file to reflect the new quadrant. In Electroglas probers, the coordinate
quadrant must match the prober quadrant. If the coordinate quadrant differs, the X,Y
coordinates will be reported incorrectly, and the wafer mapping software will interpret the
coordinates as being incorrect and disable the prober.
First die
The format of the PROBE list is exactly the same as the ROW list, except now the choice of
which die is the first die or last die in a row is important since this governs the direction the
probe needle takes along the wafer. The order, sequentially from top to bottom, of the rows
in the PROBE list determines the order the rows are probed.
The following are the probe lists to probe the wafer in the serpentine pattern shown in figure
10-17:
#Probe Quadrant 1 Probe Quadrant 2
PROBE PROBE
X0,Y0,X-3 X0,Y0,X3
X-3,Y-1,X0 X3,Y-1,X0
X1,Y-2,X-4 X-1,Y-2,X4
X-4,Y-3,X1 X4,Y-3,X-1
X0,Y-4,X-3 X0,Y-4,X3
X-3,Y-5,X0 X3,Y-5,X0
#Probe Quadrant 3 Probe Quadrant 4
PROBE PROBE
X0,Y0,X3 X0,Y0,X-3
X3,Y1,X0 X-3,Y1,X0
X-1,Y2,X4 X1,Y2,X-4
X4,Y3,X-1 X-4,Y3,X1
X0,Y4,X3 X0,Y4,X-3
X3,Y5,X0 X3,Y5,X0
NOTE
For multisite testing, be careful to step the prober so that at least one die out of all the sites
is a valid, testable die. IMAGE executes the test program, tests one part, and inserts an
extra part record in the STDF file. This die is subsequently inked, but the STDF file will
contain an extra part record.
S I
I S
S I
I S
S I
The following are the INK and SKIP lists for the dice in figure 10-18:
PROBE
X26,Y15,X23
X19,Y15,X16
X12,Y15,X5
You must still include the skip or ink die in the INK and SKIP lists since these dice
(particularly the ink die) must be inked.
The wafer configuration file has been designed for Electroglas probers. Therefore, you can
transfer information in the wafer configuration directly to an Electroglas prober. Information
in the wafer configuration file may be incompatible with equipment from other vendors. To
use this file for another prober, you must be able to program the prober to follow a
consistent, predictable pattern over a wafer and to retrieve that information as part of the
setup. If this is the case, you can use the wafer configuration file to describe the pattern the
prober will take and initialize the wafer mapping software.
When using the set wafer statement with wafer mapping, this statement must appear in a
tl_init() function in the test program. In this way, IMAGE can construct its wafer map
before testing starts.
For example, if the die X dimension is 8.4 mils and the Y dimension is 12.8 mils, enter the
numbers as
set wafer:
die_height = 128 or (128.0)
die_width = 84 or (84.0)
;
When the SECS wafer map filter is invoked, it is invoked with the string 10^-1*mil to signify
that the unit of measure is in tenths of mils. The SECS wafer map filter and valid format
strings are discussed in “Generating the SECS Map” on page 10-35.
Getting a Setup
RDP protocol supports block data transfers between the tester and prober. The
handlerconf -get_setup command allows you to transfer the prober’s current setup to a
file. To retrieve the setup from a prober and store it in a file called prober_setup.prober,
the command is:
handlerconf -get_setup prober_setup.prober
The information is automatically written to the directory
/image/tester/testername
In IMAGE V5.6 and later, you can use the -local switch to write the setup file to your
current working directory (the directory from which the command is initiated). The command
is:
handlerconf -get_setup -local prober_setup.prober
You can send this file later to the prober. Once the prober receives this information, it loads
the information into its memory and uses it as the current setup. Therefore, you need only
set up a prober manually once. You can save that setup and use it to automatically set up
the prober whenever a particular product must be tested.
When testing a new product, however, you must set the Z-height and reprofile the wafer.
Electroglas probers do not send this as part of the set up information.
You can include the setup file in a .load file, and the load command will automatically send
the name of the file to IMAGE.
Downloading a Setup
You can download a setup file to the prober by:
• Listing the file in the load command processor (in which case it must contain a .prober
extension)
• Using the handlerconf command
The command handlerconf -put_setup <filename> command searches for the named
file in:
/image/tester/testername
and downloads the file to the prober. Once the prober receives this file, it uses this
information as its current setup.
In IMAGE V5.6 and later, you can use the -local switch to write the setup file to your
current working directory (the directory from which the command is initiated). The command
is:
handlerconf -put_setup -local prober_setup.prober
You can issue this command at any time, once the tester is running. A test program need
not be loaded in the particular station. Note, however, that the last setup is the one that
takes effect. Issuing the -put_setup option overrides any current setups. Likewise, if the
prober setup file is listed in the .load file, it overrides any preexisting setups.
When using -get_setup and -put_setup, the directory where the files reside must have
appropriate read/write permission set to allow IMAGE to access the files.
As mentioned earlier, you can include the setup file in a .load file (see “Using .load Files to
Load Test Programs” on page 5-11). If the setup file is found at load time, its name is sent
to IMAGE. When you enable the wafer mapping option, the file is transferred to the prober.
For the load command to recognize a file as a valid prober setup file, it must end with the
.prober extension.
You can also include the wafer configuration file in a .load file. If the file is found at load
time, its name is also sent to IMAGE. When you enable the wafer mapping option, the wafer
mapping software initializes from this information. If no setup file is named in the .load file,
the information in the wafer configuration file is sent to the prober. Before you enable the
wafer mapping option, you must clear the prober’s current ROW list. If you do not clear the
list, information contained in the wafer configuration is appended to the current ROW list.
The following is a sample .load file for a test program named wafer.tl:
wafer.tl
3122.wafr
-autocal
-handlerprober eg2001
This file includes the wafer configuration file 3122.wafr and a switch that connects IMAGE
to the EG2001 prober (-handlerprober eg2001).
If the setup file named in the .load file is successfully transferred to the prober, the
information in the wafer configuration is not transferred to the prober. It is assumed that this
information is contained in the setup file. In this case, the ROW list is used only to initialize
the wafer mapping software.
Using the wafer configuration file may not be appropriate for all makes of probers. If,
however, the prober manufacturer adheres to the RDP standard, automatic prober setup
(either using the handlerconf -put_setup command or using a .load file and the
handlerconf -wafer_map command) will work correctly. For probers made by vendors
other that Electroglas, you may be able to manually set up the prober to follow the wafer
configuration and probe pattern contained in the wafer configuration file. Once you have
done this and saved the information in a setup file, you can use the wafer mapping software
successfully.
Setting Up Datalog
The SECS wafer map is generated from an STDF file. Before the prober is enabled, you
must be sure that datalogging is enabled. You must datalog all parts. You cannot use the
sample rate and limit options for data collection, since this writes a subset of part information
to the STDF file and, consequently, produces an incomplete wafer map.
Put all setup commands into a script file and execute the script to load the test program,
enable the wafer mapping function, and enable data collection. This helps assure that things
are set up properly.
11 GPIB PROGRAMMING
This section describes IMAGE programming for the General Purpose Interface Bus (GPIB).
It includes the following topics:
• “GPIB Overview” on page 11-2
• “The gpibcap File” on page 11-7
• “High-Level GPIB Programming” on page 11-10
• “Low-Level GPIB Programming” on page 11-15
• “Cabling and Configuration Issues” on page 11-18
GPIB Overview
The GPIB consists of eight control lines and eight data lines. Instruments connected to the
GPIB share the bus. (See figure 11-1.)
HP 3458A
meter
EOI
REN
GPIB SRQ
ATN
Control IFC
Lines NDAC
NRFD
DAV
GPIB
Data / Address
Lines
8
GPIB Commands
The GPIB has a command set, listed in table 11-1. The GPIB driver gives you access to two
of these commands: Go to Local (GTL) and Selected Device Clear (SDC). The GPIB driver
manages the other commands; table 11-1 is provided for reference only.
The Go to Local (GTL) command causes the currently addressed listeners to return to local
programming mode. The GPIB driver issues this command in response to the set
gpib...option: go_to_local statement (see “Setting Up the GPIB” on page 11-10).
The Selected Device Clear (SDC) command resets all the listeners. The reset state for each
listener is instrument dependent (refer to its user’s manual).
GPIB Addresses
The GPIB driver identifies each instrument on the bus (including the controller) using its
preset GPIB address. Instruments usually acquire a GPIB address at the factory, which can
be reset using an address switch, jumpers, or a control panel. (Refer to the instrument’s
user’s manual for an explanation of how to set its GPIB address.)
An instrument’s address is actually two addresses: a talk address and a listen address. If
an instrument detects its listen address on the GPIB, it begins listening for information on
the bus. If an instrument detects a talk address on the GPIB and has something to say, it
begins talking.
The high-level GPIB language eliminates talk and listen addresses and instead refers to
instruments using a single, decimal address. Table 11-2 lists the decimal GPIB addresses
along with the corresponding, low-level talk and listen address codes. The table also
identifies the addresses allocated to Teradyne instruments.
The GPIB has 31 available addresses, but it can support a maximum of only 19 instruments.
Four addresses are assigned to Teradyne instruments, leaving 15 GPIB addresses for other
instruments.
REN Remote Enable. When true, this signal places all listeners
capable of remote operation in remote programming mode.
When false, it returns all instruments to local programming
mode.
SRQ Service Request. Instruments use this line to request the
controller’s attention. Typically, this occurs when an instrument
has data ready to transmit or when it detects an error condition.
The control lines are active low — that is, the signal is true when its voltage is low (near 0
V), and the signal is false when its voltage is high (near 5 V).
Outside of a test program (in a handlerconf command for example) IMAGE only searches
in /image/tester/<name> and $IMAGEBIN/custom. The GPIB configuration in
$IMAGEBIN/custom applies to all workstations connected to the network.
If you plan to communicate with GPIB based material handling equipment from within the
test program and also through IMAGE, be careful that only one gpibcap is being used.
Otherwise, communication may be unsuccessful. IMAGE looks in /image/tester/
<tester_computer_name>, and the test program looks in the user’s home directory. If a
gpibcap file exists in both places, the two gpibcap files can contain different entries,
addresses or specifications for devices.
rterm="<command>"
tterm="<command>" These fields are used with handlers and probers on the GPIB.
rterm specifies the terminator which marks the end of data for
data being transferred to the tester from the handler or prober.
tterm specifies the terminator to be appended to all messages
being sent to the handler or prober from the tester. See “Writing
a gpibcap File” on page 4-18 in the Handler/Prober Manual.
For example, here are some entries from a typical gpibcap file:
_______________________________________________________
#
# Master clock
master_clock|PTS 160MHz master clock:\
:addr=1:listener:reset_code="":\
:drivers=open:
#
# High Speed Sampler auxiliary clock
aux_clock|PTS 160MHz sampler clock:\
:addr=20:listener:reset_code="":\
:drivers=open:
#
# Entry for the Precision Multimeter
pmm|HP3458A meter:\
:addr=22:reset_code="PRESET NORM;OFORMAT DREAL":\
:talker:listener:drivers=tri:\
:errbitmask=32:moreinfo="ERRSTR?":
_______________________________________________________
Notes:
• At least one of the options, talker or listener, must be specified.
• The gpibcap file is reread after test system initialization. This includes when power is
cycled or the initialize command is issued.
• If an instrument has more than one GPIB address, the gpibcap file must contain
multiple entries for that instrument, one for each GPIB address.
• By default, error checking is disabled. To enable error checking, see the set gpib ...
echeck parameters in “Setting Up the GPIB” on page 11-10.
• The gpibcap file is similar to the handcap file that exists in the directory $IMAGEBIN/
custom. handcap informs the test system about the functionality of the various handlers
and probers. Using handlers and probers over the GPIB requires entries in the handcap
file. See “GPIB Handler/Prober Interface” on page 4-1 in the Handler/Prober Manual.
option: echeck_off
Turns error checking off.
option: go_to_local
Sends a Go To Local (GTL) GPIB command to the instrument.
timeout= <integer> Specifies, in seconds, how long to wait for a bus response before
generating a timeout. (The default is 7 seconds.)
Notes:
• If a test program is loaded that uses the set gpib instr=<instrument name> syntax,
IMAGE checks the gpibcap file for the entry. If the instrument has no entry in the
gpibcap file, the error message no current instrument definition appears.
IMAGE searches for the gpibcap file in the login directory, /image/tester/<tester
name>, and $IMAGEBIN/custom, in that order. IMAGE uses the first gpibcap file it finds
for all instrument definitions. The handler/prober software does not look in the user’s
directory for the gpibcap file.
• An instrument can be a talker or a listener, but not both.
• If you plan to have the controller communicate with a single instrument, you need not
designate the talker and the listener in a set gpib statement. (However, it is not an error
to do so.) In controller-to-instrument communications, the GPIB driver handles these
details for you when you initiate a transfer with a start gpib statement. The talk and
listen options are primarily for designating multiple listeners or instrument-to-
instrument communications.
• Error checking slows down bus transfers and is only recommended as a debugging tool.
• You can specify an echeck option only for an instrument listed in the gpibcap file.
serial_poll=<integer variable>
Captures the result of a serial poll in the named integer
variable. Serial poll data is one byte and is stored in the least
significant byte of the integer variable. Use this option to check
the status of an instrument.
start gpib wait: srq
This statement forces the GPIB driver to wait for a Service
Request (SRQ) from one of the instruments. Use this statement
to synchronize the communications from different instruments.
error=<integer variable>
This option returns a zero into the named integer variable if
a timeout occurs while the GPIB driver is waiting for a Service
Request (SRQ). Otherwise, it returns a nonzero event code
indicating the wait was successful.
start gpib trigger;
This statement triggers all listeners.
Notes:
• After the controller sends information to an instrument, it remains a talker and the
instrument remains a listener.
• After the controller receives information from an instrument, it remains a listener and the
instrument remains a talker.
• When a talker runs out of information to send to a listener, it sends an EOI control signal.
A listener stops receiving information when it detects the EOI control signal. However,
if you rely solely on EOI to terminate a transfer, you run the risk of runaway data
transfers—when the listener ceaselessly requests more data and the talker ceaselessly
sends it more data. Eventually, the system crashes leaving you with few clues as to why
it crashed. To avoid this problem, always specify the size parameter with start gpib
send and receive statements, even if you do not know the size of the transfer. In this
case, use the size parameter to set an upper limit for the transfer, so that the transfer
is guaranteed to terminate.
Programming Examples
The instrument in these examples is the HP3458A multimeter, which is part of the Precision
Multimeter (PMM) subsystem. (See the PMM section in the instrumentation manual for your
tester.) The commands sent to the HP3458A over the GPIB are HPML (Hewlett-Packard
Multimeter Language) commands. (These commands are described in the HP3458A
Multimeter: Operating, Programming, and Configuration Manual.) The examples assume
that you have already created an entry for the PMM in the gpibcap file (see “The gpibcap
File” on page 11-7).
• Send the PMM an nplc (Number of Power Line Cycles) command.
start gpib instr="pmm" sendstr="nplc 2";
(This statement automatically designates the controller as talker and the PMM as
listener.)
• Designate the PMM and two other instruments as listeners. Then trigger all listeners:
set gpib addr=3 option:listen;
set gpib addr=10 option:listen;
set gpib instr="pmm" option:listen;
float val;
set gpib instr="pmm" option:listen;
start gpib trigger;
start gpib instr="pmm" receive = &val size=4;
12 SIMULATOR
IMAGE includes software simulation of the tester hardware, allowing you to develop, run,
and debug test programs on a stand-alone workstation. To maintain a consistent work
environment, IMAGE does not change its behavior when running the simulator.
This section icludes the following topics:
• “Customizing Simulation” on page 12-2
• “Creating and Maintaining a Simulator DataBase File” on page 12-4
Invoking the simulator requires no special commands or procedures. When IMAGE is
invoked, it reads the contents of a file named confsim to determine the type of tester to
simulate (such as Advanced Mixed-Signal, Catalyst, or Catalyst Tiger) and its hardware
configuration. confsim files are located in the $IMAGEBIN/custom directory. For an
explanation of the confsim file, see “Configuring IMAGE” on page 4-1.
From this point on, the simulator imitates the functions of the hardware in its hypothetical
test system. You can extend the simulation using a Simulator DataBase file (see
“Customizing Simulation” on page 12-2).
IMAGE also includes a digital simulator (DSim) that detects timing violations in digital
patterns which the digital hardware cannot detect. These violations may result in a tester
rejecting good devices and passing faulty ones. (See “Digital Subsystem Simulator” on page
3-1 in the IMAGE Software Tools Manual.)
Customizing Simulation
Executing a statement such as dc_result=read_meter() on a standalone workstation
does not fail because the simulator intercepts the read_meter call and returns a default
value, usually 0.0. To make hardware simulation more realistic, you can replace default
values with your test values by specifying test values in a special file called a Simulator
DataBase file.
Any time a test function in a test program requires data from an instrument, the simulator
responds by searching the current directory for the following files in the following order:
<program>_<site>.sdb
<program>.sdb
where:
program Is the name of the test program.
site Is a test site in a multisite test program (0–7). (See “Using
Simulator Database Files in Multisite Test” on page 12-8.)
.sdb Simulator DataBase file extension.
If it finds one of these files, it searches through the list of records in the file for a record
having the same name or number as the test function. For example, if the test function is
named vilpp, the simulator looks for a record named test vilpp.
If it finds this record, it then searches the record for the name of the instrument it requires
data from. For example, if the vilpp test function is trying to take a measurement with the
dc voltmeter, the simulator would search its test vilpp record for the word dcmeter.
If it finds an entry for the instrument, it takes the value assigned to that instrument and
returns it to the test program in place of the simulator’s default value. For example, a typical
record for the vilpp test function might look like this:
test vilpp
dcmeter = 2.34volts
acmeter = 1086mvolts
acmeter = 1221mvolts
;
The first read_meter() function call in vilpp would return 2.34 for the dcmeter reading and
would return 1.086E-3 for the acmeter reading. The second read_meter() function call of
the acmeter would return 1.221E-3. Further calls to read_meter() return the last reading
in the entry list (1.221E-3). The relevant debug displays would also show the simulated test
result.
Table 12-1 lists instruments that can be included in a Simulator DataBase file.
NOTE
simdbase does not display site-specific .sdb files. See “Using Simulator Database Files in
Multisite Test” on page 12-8.
The simdbase syntax checker is automatically invoked when you try to save the edited file
by selecting FILE>SAVE. If it detects a syntax error, it aborts saving the file, displays an error
message indicating the line on which the error was detected, highlights that line, and returns
simdbase to text edit mode. To save a Simulator DataBase file with syntax errors, select
SIMDBASE>SAVE AND QUIT.
When the test program calls a function which performs more than one meter strobe, like
read_meter_n(), the simulator reads one entry from the simulator database. That value is
presumed to be the averaged reading, which is returned to the test program.
Examples
Test function:
TESTF special_bias()
{
tms_result = read_tms() ;
dc_result = read_meter() ;
}
Simulator DataBase record:
test special_bias
tms= 15.33us
dcmeter= -10.555V ;
When read_tms is called, read_tms returns 15.33us to tms_result. When read_meter is
called, read_meter returns -10.555V to dc_result.
meter = 2.0V
meter = 2.2V
meter = 2.4V ;
On the first call to vm, read_meter returns 1.2, 1.8, and 2.0. On the next call to vm,
read_meter returns 2.2, 2.4, and 2.4.
Specifying repeat in a Simulator DataBase record forces the simulator to always begin with
the first measurement value in the record when the test function is called. For example:
test vm repeat
meter = 1.2V
meter = 1.8V
meter = 2.0V
meter = 2.2V
meter = 2.4V ;
On the first call to vm, read_meter returns 1.2, 1.8, and 2.0. On the next call to vm,
read_meter returns 1.2, 1.8, and 2.0.
test vout5
dcmeter= 4.96;
The record for site 2 (in a separate file) would be:
test vout5
dcmeter= 4.99;
This feature makes .sdb files easy to use when debugging multisite test programs. Single
site test programs are not affected.
The simdbase editing window does not use site numbers. It only displays <program>.sdb
files, not <program>_<site>.sdb files. You must use a text editor (such as textedit, vi,
or emacs) to modify site-specific .sdb files.
The simulator automatically converts waveform file data to the format appropriate to the
calling statement or function.
If, instead of a waveform file, a single floating-point number is assigned to c_mem, the
simulator uses that value for every c_mem location. For instance, if the Simulator DataBase
record in the last example was entered as:
test NONE c_mem = 99;
the simulator would move 99 into every storage location in int_bh1.
If the simulator cannot find a Simulator DataBase file or an entry in a Simulator DataBase
file, it searches the current directory for a file named simwavedata.wav and substitutes data
in this file for capture memory. The simwavedata.wav file offers a second way to simulate
capture memory.
The programming language for Catalyst test systems is called the IMAGE Test Language
(ITL). ITL is a superset of the “C” programming language. ITL supports the entire C
programming language as well as a set of enhancements designed for ATE. (IMAGE
operating under Solaris 2 uses ANSI C.) Specific testing-oriented functions and statements
have been added to help create device test programs. In addition, ITL provides pin-oriented
language statements for controlling Catalyst instrumentation.
C is a general-purpose programming language that allows you to write modular well-
structured programs using a rich set of data types, operators, and high-level statements. In
addition, it allows you to easily manipulate data and bits at a low level. It is a fully compiled
language that produces efficient object code for fast execution speed.
Using ATE-specific sequencer and test functions, ITL provides a framework that makes it
easy to create, debug, and maintain device test programs. The test list, pass/fail conditions,
and binning strategy are all specified in one place—a specialized function called the
sequencer. The sequencer, in turn, calls test functions to perform each test.
ITL is a pin-oriented programming language. In a pinmap at the beginning of each program,
you assign a specific tester channel to a specific device pin and indicate the hardware
resources available to each pin on the assigned channel. This assignment can include
giving a device pin a name indicative of its function. Thereafter, you can refer to device pin
names in your program and gain access to the resources assigned to each pin, rather than
having to refer to the resources by tester channel numbers or instrument names. Each type
of hardware resource has a customized set of high-level language statements used to
program it.
This section describes the base programming language portion of ITL. Language specific
to test system instruments is described in the Catalyst Instrumentation Manual, and the
Catalyst Tiger Instrumentation Manual.
This section includes the following topics:
• “Parts of a Test Program” on page 13-2
• “IMAGE Test Language Basics” on page 13-6
• “Variables and Operators” on page 13-11
• “Flow Control Statements” on page 13-19
• “Arrays and Other Data Structures” on page 13-24
• “Updating Test Programs Written Before Solaris 2” on page 13-29
Header
#include <stdio.h> /*standard I/O header*/
#include <math.h> /*standard math functions*/
#include <image.h> /*standard IMAGE header*/
#define VMASK 0077 /*macro definition*/
#define SPECTRUM_SIZE 512
float spectrum[SPECTRUM_SIZE]; /*define a global array*/
int myflag = 0; /*define a global flag var*/
pinmap = {
/*DUT pin number pin name channel resource*/
1 "VIN" dc_matrix:1 (src:1),
2 "VOUT" dc_matrix:2,
dib "DIB" dc_matrix:3 (src:2),
24 "VCC" dutsrc:1,
};
Main Program—Beginning of executable code
main()
{ /*beginning of main*/
seq1(); /*execute the sequencer seq1 and assign bin_number*/
sort bin; /*sort the bin number result*/
} /*end of main*/
SEQUENCER Function
SEQUENCER seq1()
{ /*beginning of sequencer*/
/*
test function test test limits test binning
name # low/high label f/p */
seq contin() $1 >0 <.7v "continuity" f(0);
seq icc() $2 >20ma <25ma "supply i" f(2);
seq ac() $3 >1.55v <1.62v "amplitude" f(3) p(1);
} /*end of sequencer*/
TEST Function
TESTF icc()
{ /*beginning of testf*/
double supply_i; /*declare local variable*/
set pin=vcc dutsrc:v=5.125v; /*set up dc source*/
set meter input:pin=vcc dutsrc:i; /*set up dc meter*/
set power on: dc; /*turn power on*/
wait 10ms; /*wait for device to settle*/
supply_i=read_meter(); /*read dc voltmeter*/
test supply_i; /*test the result against limits*/
} /*end of testf*/
Header Section
A typical ITL test program begins with a header section containing file #include directives,
macro definitions, external variable declarations, and global variable definitions. Here is a
sample header section:
#include <stdio.h> /*standard I/O header (required)*/
#include <math.h> /*standard math functions (required)*/
#include <image.h> /*standard IMAGE header (required)*/
pinmap = {
/*DUT pin number pin name channel resource*/
1 "VIN" dc_matrix:1 (src:1),
2 "VOUT" dc_matrix:2,
dib "DIB" dc_matrix:3 (src:2),
24 "VCC" dutsrc:1,
};
Pinmap
The sample header above also includes a pinmap. The pinmap is a special section that
describes the mapping between tester channels and device pins, including the test system
resources available behind each pin. You specify the pinmap once based on how your
device connects to tester channels. From then on, you program using device pin names.
Pinmaps are explained in the instrument manual appropriate for your tester.
Tester resources in a test program can also be assigned using DIBView. See “DIBView” on
page 2-1 in the IMAGE Software Tools Manual.
main() Function
The main() function is the highest level function of a test program; it is where execution
begins each time the program is run. In the following main function, a sequencer function is
called which returns a bin number. This bin number is used to sort the device using a sort
bin statement.
main()
{ /*beginning of main*/
seq1(); /*execute the sequencer seq1 and assign bin number*/
sort bin; /*sort the bin number result*/
} /*end of main*/
Sequencer Function
A sequencer function is like test program table of contents. In a sequencer function you
string together sequencer statements and, by doing so, list all tests to be performed in order
of execution. For each test, all limits, datalog formatting information, and binning information
is presented in a tabular, readable form, resembling a specification sheet. A test program
usually has one or more sequencer functions such as the following:
SEQUENCER seq1()
{ /*beginning of sequencer*/
/* test function test test limits test binning
name # low/high label fail/pass*/
seq contin() $1 >0 <.7v "continuity" f(0);
seq icc() $2 >20ma <25ma "supply i" f(2);
seq ac() $3 >1.55v <1.62v "amplitude" f(3) p(1);
} /*end of sequencer*/
Test Function
The test function is where you set up test system hardware to provide forcing functions or
take measurements. A test function includes one or more test statements that it calls to
determine pass or fail on one or more test results. A test program usually has many test
functions similar to the following which correspond to the tests to be performed.
TESTF icc()
{ /*beginning of TESTF*/
double supply_i; /*declare local variable*/
set pin=vcc dutsrc:v=5.125v; /*set up dc source*/
set meter input: pin=vcc dutsrc:i; /*set up dc meter*/
set power on: dc; /*turn power on*/
wait 10ms; /*wait for device to settle*/
supply_i=read_meter(); /*read dc voltmeter*/
test supply_i; /*test the result against limits*/
} /*end of TESTF*/
Statements
In ITL, all statements are terminated by a semicolon (;). For example:
set power on: dc;
Right and left braces ({ and }) are used to group statements together into a compound
statement to be executed as a block. For example:
TESTF()
{
set power on: dc;
wait 10ms;
}
This is similar to the use of the words “begin” and “end” in other languages. When braces
are used, a semicolon is not required after the right brace (}) to terminate the statement.
Assignment statements and flow-control statements are described in “Flow Control
Statements” on page 13-19.
Comments
Comments begin with a slash and an asterisk (/*) and end with an asterisk and slash (*/),
as in
/*This is a comment*/
Comments can be placed anywhere in a source file. Nested comments are illegal and
produce a compiler error.
Functions
Functions are executable blocks of code structured in standard C format. Each function is
delimited by a left and right brace, and uniquely identified by a function name. Typically the
name of the function describes the operation that takes place when the function is executed.
Functions are executed by calling them, using the function name.
Functions can receive values through the passing of parameters and can return a value
through a return statement.
The parts of a function are:
• A declaration of the type of return value if a return statement is to be used
• The function name followed by parentheses
• A list of variable names that receive the values of the arguments or parameters being
passed to the function. This list is placed in the parentheses following the function name.
It gives the names and the order in which the function expects them.
• Declarations for each of the names in the arguments/parameters list. Declarations give
the type of values being passed.
• The body of the function (the block of executable code delimited by left and right braces)
• A return statement (when a value is to be returned)
Sample function definition is:
double vout(p, pname, supply)
int p;
char pname[];
double supply;
{
double x;
<statements - body of function>
return(x);
}
In this example, the word double in front of the function name vout is the declaration of the
type of value being returned by the return(x); statement. (double means “double
precision floating point.”) The default type for any returned value is an integer. (See “Data
Types and Constants” on page 13-11.)
The terms p, pname, and supply contained in the parentheses are the parameters being
passed to the function vout. If no arguments are passed, it is written vout(). (If using
Solaris 2, this can be written vout(void).)
Between the function name and the left brace ({) are:
int p;
char pname[];
double supply;
These are declarations of the type of values being passed to the parameters p, pname, and
supply.
The body of the function is contained within the left and right braces ({}) and can be any
group of executable ITL statements.
The return statement contains the variable x between parentheses. x is a variable that has
been given a value during execution of the body of statements in the function. This value
will be returned to the statement that called function vout.
NOTE
A return statement does not require parentheses; you can give it an arbitrary expression,
such as return 4+x; or return func1();
If you are using Solaris 2, you can use the ANSI C format to write functions. This provides
compile time checking of parameters to verify that the parameters used in the call to a
function match the parameters expected by the function. The example function would be
rewritten as follows in ANSI C:
double vout
(int p, char pname[], double supply)
{
double x;
<statements - body of function>
return(x);
}
Use of this format in Solaris 2 is optional. The standard format used in OS4.1 works in
Solaris 2.
Calling Functions
The following are examples of function calls:
vin(); A function call with no parameters. The block of code vin() is
executed.
vout(a,b,c); A function call passing parameters a, b, and c to the called
function.
x = myfunc(); A function is called and the return value assigned to x.
x = myfunc() + 4; A function call used in an expression. A function is called and its
return value is added to 4.
Macros
The directives #define and #undef, used in C to define or undefine a macro, are illegal in
ITL outside of the header of a test program.
Macros cannot be used for function definitions; structure or enum definitions and cannot
contain unbalanced braces or parentheses.
Unit Modifiers
An ITL feature not available in C is the ability to use unit modifiers for test program values.
This allows you to use expressions such as 2mA and 3dB, rather than the equivalent
scientific notation that C requires. The ITL preprocessor converts any unit modifiers into the
correct notation for you.
NOTE
Unit modifiers can be a source of confusion when using the modulus operator. The symbol
for the modulus operator (%) is the same as the symbol for the units of scaling (percent).
Therefore, be careful when using the modulus operator that you use a space before and
after the operator. Otherwise, you can get compiler errors. See “Arithmetic Operators” on
page 13-13 for an explanation.
ANSI C
If you are using Solaris 2, the C compiler supports ANSI C extensions to the C language.
For information on differences when converting to Solaris 2 and ANSI C, see “Updating Test
Programs Written Before Solaris 2” on page 13-29.
Variables
Variable names are made up of letters and digits. The first character must be a letter. The
underscore (_) is considered a letter. ITL differentiates between upper and lower case.
Therefore, ABC is not the same as abc.
Variable Names
You can use almost any name for a variable, but you cannot use any of the IMAGE reserved
words (such as set, wait, and tl_). See “Reserved Word List” on page 23-1 for a list.
Declaring Variables
All variables must be defined or declared before they are used. A definition consists of a
data type followed by a variable name. Some examples are:
int index;
double value;
char ch;
unsigned num;
Multiple variables of the same type can be defined on one line, as in:
int a, b, c;
Initializing Variables
Variables can be initialized in their definition by placing an equal sign and a constant after
the variable name:
int i = 0;
float pi = 3.14159;
char newline = '\n';
NOTE
In ITL, uninitialized global variables are initialized to 0 at load time. From then on, their
values (when changed) are retained from run to run.
In ITL, programs can be divided into separate source files. Global variables can be defined
in any file. To access a variable defined in another source file, you must declare the variable
as external using an external declaration with the keyword extern in front of the variable
type and name. For example:
extern int status;
This indicates to the compiler that the variable is defined in another source file. You must
place external declarations in the header section at the top of the file or in a function.
Arithmetic Operators
ITL has one unary (takes one operand) and five binary (takes two operands) arithmetic
operators. The unary operator “-” is used to negate a number. The five binary arithmetic
operators are: + (addition), - (subtraction), * (multiplication), / (division), and % (modulus).
The modulus operator (%) produces a remainder when two integers are divided. For
example, if:
a = 25 b = 10
then:
a % b = 5
Take care to use spaces around the modulus operator to avoid confusion with % used as a
scale factor. (See “Units” on page 13-17.) For example, consider the following expressions:
k= 2 % j
k= 2% j
The first is a legal expression. The second is equivalent to:
k= 2E-2 j
This expression is illegal and will produce a compiler error.
The order of precedence of ITL arithmetic operators is as follows:
unary - highest precedence
*, /, % equal and lower precedence
+, - equal and lowest precedence
Arithmetic operators of equal precedence execute from left to right with parentheses
overriding. For example:
c = 5 * 4 + 3; /*c is assigned the value 23*/
c = 5 * (4 + 3); /*c is assigned the value 35*/
Relational Operators
ITL relational operators for use in determining TRUE or FALSE are as follows:
> greater than
>= greater than or equal to
< less than
<= less than or equal to
== equal to
!= not equal to
== and != have lower precedence than the others. All relational operators have lower
precedence than arithmetic operators. For example:
if (x + 4 < 3 + y);
is the same as:
if ((x + 4) < (3 + y));
NOTE
Do not confuse the single = and double == equal sign operators. The == operator compares
two values, as in:
if (x==5)
The = operator is used for assigning a value to a variable.
Relational operators are most often used in flow control statements or conditional
statements, like loop conditions or if statements.
x=0; /*x is assigned the value 0 and then evaluated*/
if (x==1)...
Logical Operators
ITL logical operators for use in determining TRUE or FALSE are as follows:
&& logical AND
|| logical OR
! unary NOT
Expressions containing && or || are evaluated left to right and evaluation stops as soon as
TRUE or FALSE is known. For example:
if (i > 4 && x == y); /* if i > 4 AND x == y */
NOTE
Do not confuse the bitwise operators & and | with their logical counterparts && and || which
are used in Boolean expressions to determine TRUE or FALSE.
Shift operators are used to shift right or left some number of bits. The syntax for shift
operators is:
x = 01;
y = x << 2; /*y is now 04*/
Assignment Operators
Three operators are provided for assigning values to variables:
a = x /*assign the value of x to a*/
a += x /*add x and a and assign the result to a*/
a -= x /*subtract x from a and assign the result to a*/
Precedence of Operators
Table 13-2 summarizes operator precedence and associativity (the degree of dependence
between two operators).
Operator Associativity
Operator Associativity
Units
When programming instruments, you may wish to specify units in standard terms like
millivolts or kilohertz. ITL allows you to deal with floating point numbers in the scale and
units appropriate for each application.
To do this, ITL uses a format for floating point constants that includes a scale factor and
units string appended to a floating point constant. The scale factor (table 13-3) is a single
letter indicating which power of 10 to scale the number by. The units string is made up of
one to six alphabetic characters. The scale factor and units string are concatenated together
and placed immediately following the floating point constant with no space in between. The
scale factor and units string are each optional.
f femto -15
p pico -12
n nano -9
u1 micro -6
m milli -3
% percent -2
c centi -2
k or K kilo 3
M mega 6
G giga 9
1. A unit must follow the u scale factor. In accordance with Solaris conventions, u or U following a
constant casts that number as an unsigned int unless a unit follows the u.
The units string is a label provided for readability and has no effect on floating point
arithmetic. It is checked by the compiler in certain cases to verify that the units are
appropriate for the instruments being programmed. In the sequencer statement, the units
string in a limit specification is used as a default for the units appearing in a datalog printout.
(See “Test Parameter List” on page 14-13 and “Datalog Format” on page 6-75.)
Common unit strings include the following:
A amperes
s seconds
dB decibels
V volts
Hz hertz
ohm ohms
The following are floating point constants that use units and the actual numerical value they
represent:
2.4mV 0.0024
65uA 0.000065
32.4kV 32400.
.45MHz 450000.
Units can only be used as part of a constant. They cannot be appended to variables.
next:
Assignment Statement
The assignment statement allows you to assign a value to a variable. The statement syntax
is:
<variable> = <expression>;
where <variable> can be any variable name, and <expression> can be any legal
expression in ITL. For example:
x = 4;
y = vout/4;
result = read_meter();
If the value of the expression is not the same type as the variable, the value is converted to
that type before the assignment is made. For example:
double a;
int x;
x = 4.6 + 5.6; /*x = 10*/
a = 4.6 + 5.6; /*a = 10.2*/
In this example, x is declared as an integer. Therefore, x = 4.6 + 5.6 yields 10, since the
arithmetic is done first in floating point, giving you 10.2, and then converted to an integer
(10).
If-Else Statement
The if-else statement creates a simple conditional branch in the program. The format is:
if (<expression>) <statement1>;
else <statement2>;
This is a Boolean expression that must evaluate to TRUE (a nonzero value) or FALSE (a
zero value). If the expression evaluates to TRUE, <statement1> executes. If it evaluates
to FALSE, <statement2> executes. The else clause of the statement is optional. Here is
an example:
if (read_meter() > 2.4mv) vflag = 1;
else vflag = 0;
For Statement
Use the for statement to iterate a statement or group of statements a fixed number of times.
The syntax of a for loop is:
for (<init>; <cond>; <incr>)
{
<statements>
}
where:
<init> Sets the initial value of a variable that keeps count of the number
of times the loop is executed. (Can also call a function.)
<cond> Sets the condition by which looping continues. If the condition
evaluates to TRUE, the loop is executed. If the condition
evaluates to FALSE, the loop is not executed.
<incr> Sets the value by which the <init> variable is changed after
each pass of the loop. (Can also call a function.)
While Statement
The while statement provides a loop based on a condition remaining true. The condition is
checked before the first iteration of the loop. Therefore, the loop condition can prevent the
loop from executing. The syntax is:
while (<expression>)
{
<statements>
}
<expression> is a Boolean expression that must evaluate to TRUE or FALSE. If the
expression evaluates to TRUE, the statement executes. The expression is reevaluated
each time through the loop, and the statement is executed until the expression becomes
FALSE. If the expression is FALSE the first time it is evaluated, the statement does not
execute. For example:
while (vout < 30mv)
{
set src= 1 v= vout/4;
vout= read_meter();
}
Do-While Statement
The do-while statement is similar to the while statement except that the condition is
checked after the loop rather than before the loop. This means that the loop always
executes at least once. The syntax is:
do
{
<statements>
}
while (<expression>);
Switch Statement
The switch statement provides an easy way to perform a multipath branch based on an
expression matching one of a number of constant values. It is similar to the “case” statement
in other languages. The syntax is:
switch(<expression>)
{
case <const>: <statements>;
break;
case <const>: <statements>;
break;
·
·
default: <statements>;
break;
}
The integer value of the expression is compared with the integer constant value <const>
specified in the first case. If the expression equals the value, the statements following that
case are executed. If there is no match, the next case is checked. If none of the cases
match, the statements following the reserved keyword default are executed.
When a case matches, execution begins at that case and automatically falls through to all
the other statements. In most cases, a break statement is used at the end of each case to
prevent execution from falling through. The break statement stops execution of the switch
statement at the end of the case that has executed.
For example, if you want to read a character from the terminal and call two different
functions based on whether the character is “Y” or “N”, you could use the following:
ch = getchar(); /*get a character from the terminal*/
switch(ch)
{
case 'Y': yesfunc();
break;
case 'N': nofunc();
break;
default: printf("answer must be Y or N\n");
}
An error message is printed by the default case if the character is neither “Y” or “N.”
Break Statement
The break statement provides a way to break out of a while, for, do-while, or switch
statement. The syntax is:
break;
When a break statement executes, it immediately interrupts execution of statements in the
body of the loop or switch statement. Execution continues with the first statement outside
of and after the body of the loop or switch statement.
Continue Statement
The continue statement is related to the break statement. Rather than exiting the loop,
however, it stops the current iteration of the loop and execution continues again at the top
of the loop. The syntax is:
continue;
This statement stops execution within a loop, then continues at the beginning of the next
iteration of for, while, and do-while loops.
Goto Statement
Control can be transferred unconditionally using a goto statement and a label:
goto <label>;
.
.
.
<label>:
Labels must obey the rules for variable names but need not be declared the way variables
do. A label must be in the same function as the corresponding goto. The goto statement is
usually unnecessary and can make programs difficult to read, so avoid it when possible. A
label must be followed by a colon (:).
Arrays
An array is a series of variables of the same data type stored in a row or in the form of a
table or matrix. The elements of an array are in sequentially numbered locations and can
be referenced using a subscript that indexes to the proper point in the table.
You declare an array variable by giving the data type followed by the array name and the
size of the array in square brackets. The following are examples:
int i[10];
char ch[80];
double d[1024];
In the first example, int is the data type integer, i is the array name, and [10] is the
subscript that represents the number of storage spaces allotted for integers in the array.
You can initialize arrays at compile time by specifying the initial value of each element in the
declaration statement. For example, to initialize an array of five integers to the powers of 2,
use the following declaration:
int powers[5] = { 1, 2, 4, 8, 16 };
NOTE
You cannot initialize arrays of local variables.
To declare multidimensional arrays, specify a size for each dimension. For example, to
specify a 5x10 matrix of integers, you would write:
int multi[5][10];
Refer to array elements using a subscript that indexes to the proper element. Numbering of
array elements always starts with zero. Thus, in an array of five elements, the elements are
referred to as 0 through 4:
0 1 2 3 4
NOTE
The C language has no “bounds checking.” Make sure, therefore, that an array is large
enough to hold all the values you are writing to it. Writing past the end of an array can
overwrite other program variables.
Pointers
A pointer represents the address of a storage element. Pointers are useful for accessing
and manipulating data in a program. To use pointers, you must declare pointer variables. A
pointer variable is a variable that can hold the address of data. For the purpose of
declaration, the asterisk (*) preceding the variable name distinguishes pointer variables
from regular variables. For example, the following are declarations of pointer variables:
int *tblptr;
char *ch;
double *fptr;
The variable tblptr is a pointer to an integer and can hold the address of an integer. The
variable ch is a pointer to a character and can hold the address of a character.
To get the address of a storage element so that this address can be stored in a pointer
variable, use the operator ampersand (&). The & means “get the address of.” For example,
if you have an integer variable x that currently has the value 4 and want to assign its address
to the pointer variable ptrx, use the following assignment:
ptrx = &x;
It is also useful to get the actual data to assign it to another variable, or to use it inside an
expression. This is done using the operator asterisk (*) which means “get the contents of.”
For example, if ptrx still points to x, which has the value 4, then:
y = *ptrx + 1;
assigns y the value 4 + 1 = 5.
Pointers are often used to pass parameters to a function. If parameters are passed using a
regular variable, the value of the variable passed is used inside the function but cannot be
changed by the function. If a pointer variable is passed to a function, you can change the
value pointed to by the variable inside the function. This change will still be in effect when
the function returns because you are changing the actual data that the pointer points to
rather than a local copy of it.
Character pointers are often used to pass character strings to functions. A string constant
inside double quotes evaluates to a pointer that marks the beginning memory location of the
string. This pointer can then be passed to various string manipulation functions. For
example:
char *mystring;
mystring = "This is my string.";
len = strlen(mystring);
There is a unique relationship between a pointer and an array name. The array name is a
pointer to element 0 of an array. This allows the simple creation of functions that perform
array operation. For example:
copy(in_array,out_array,size) /*Copy data from one
double *in_array,*out_array; array to another.*/
int size;
{
int i;
for (i=0;i<size;i++) out_array[i]=in_array[i];
}
NOTE
Array names, when passed to functions, are pointers.
Structures
Structures are powerful tools for logically grouping similar pieces of data. They are useful
for creating and organizing tables of information and accessing them in a readable way.
Structures are used along with pointers and arrays to create powerful data structures that
are easy to understand.
To set up a structure, you must create a structure template, name the template (using a
“tag”), and define the fields the template contains. (ITL requires that all structures have
tags.) This is called structure declaration. An example using the tag Setup would be:
struct Setup {
char name[SETUP_NAME_SIZE+1];
double voltage;
double current;
double frequency;
int number;
};
This structure declaration provides a template for any structure that you want to define of
the type Setup. It contains information on the type of storage of the data for each field in the
structure.
To use a structure template, you must define a variable that gives you access to the fields
of the structure and allocates storage for each field as defined in the template. For the
structure Setup, such a variable would be:
struct Setup instrument_setup;
To access any of the members of this structure use the structure variable name
(instrument_setup in this example) followed by the member field name separated by a
period (.). For example:
instrument_setup.voltage = 2v;
instrument_setup.frequency = 10MHz;
strncpy(instrument_setup.name, "func_name", SETUP_NAME_SIZE);
For more information on structures, see The C Programming Language by Brian W.
Kernighan and Dennis M. Ritchie.
void newfunc
#ifdef __STDC__
(int val, char *cptr)
#else
(val, cptr)
int val;
char*cptr;
#endif
{
}
Using ANSI C
The Solaris 2 operating system uses the ANSI C standard. The following sections describe
differences you may encounter between ANSI C and the C standard used in OS 4.1.
parameters passed to a function. If the compiler cannot fit the specified parameter to its
prototype, this warning occurs.
• dubious escape: \<char>
Code example:
int i = '\q';
yields:
dubious escape: \q
This warning indicates that the character immediately following a \ is not a supported
escape character in the C language. The compiler notes this because additional letters
may be added to the escape character set in the future. Do not, therefore, specify an
escape sequence which may have a different meaning to a future compiler version.
• dubious tag declaration: <type> <tag>
Code example:
int f(x)
struct s *x;
{
}
yields:
dubious tag declaration: struct s
In this code example, the definition of struct s does not appear in the source file.
Although all pointers have the same size, the code could never use the members of this
structure since it does not have the definition. If the members were never specified, the
K&R compiler would simply accept this without comment. The ANSI C compiler notes
this as a potential problem.
• empty translation unit
Zero characters were sent to the IMAGE compiler. This would happen if you loaded a
file, then removed all text and tried to compile the file or if a source file contained only
comments using /*...*/ or #if 0...#endif.
• {}-enclosed initializer required
Code example:
int array[5] = 0;
You tried initializing a global array with out enclosing braces. ANSI C is stricter about
this sort of code. An array is a collection of values which can be initialized by an explicit
collection of values. By definition, such a collection must be enclosed with {} even if it
is only one value.
• end-of-loop code not reached
Code example:
int c;
while((c=getchar()) != EOF) {
switch(c) {
case 'a': return 1;
case 'B': return 2;
The source code redefined the value of a preprocessor macro. The K&R compiler would
accept the new definition without comment. The ANSI C compiler gives a warning. This
warning usually occurs when a macro is defined in a header file and in the source code
which includes the header file. It is a warning because it may indicate that the program
is trying to use the same macro name for two different purposes.
• old-style declaration; add "int"
Code example:
#include <stdio.h>
i;
main()
{
i++;
}
The K&R compiler allowed this type of implicit integer declaration. The ANSI C compiler
does not. All identifiers must have a storage class specification.
• prototype mismatch: <n1> arg[s] passed, <n2> expected
Code example:
#include <stdio.h>
main()
{
fflush();
}
yields:
prototype mismatch: 0 args passed, 1 expected
If a function prototype appears in the source code, it is applied to the function call
statement. If the number of parameters passed does not agree with the prototype, this
error occurs. Even without porting test programs to ANSI C, system header files declare
C functions using prototypes. This error almost always indicates a bug in the program.
• semantics of "<op>" change in ANSI C; use explicit cast
Code example:
f()
{
int i=12;
unsigned short x = 3;
i = x/i;
}
yields:
warning: semantics of "/" change in ANSI C; use explicit
cast
This is probably the most subtle difference between the K&R and ANSI C compilers. In
the expression above, the value x must be promoted to match the width of the largest
value in the expression. In this case, x (16 bits) must have the same width as the
variable i (32 bits). The K&R compiler always promotes to an unsigned value where the
ANSI C compiler promotes this to a signed value. While in most cases this will not make
a difference in the calculation, there is no way to tell at the time the program runs if the
calculation is correct. Therefore, the compiler warns of a potential problem.
The solution is to indicate to the compiler which promotion it should make. When porting
from the K&R compiler to the ANSI C compiler, the safest thing to do is be sure that the
compiler uses the K&R interpretation of the promotion rules. In the code example, the
solution is:
i=(unsigned int)x/i;
• switch expression must have integer type
Code example:
f()
{
float x=4.0;
switch(x) {
case 4: break;
}
}
The argument of a switch statement must be an integer. While of questionable validity,
the K&R compiler would accept the code example. The ANSI C compiler does not. The
reason for this is that floating point variables may have different exact representations
depending on how they are arrived at. Even though a printf statement might indicate
that two variables are the same value, they may only appear so due to rounding.
Equating a float or double variable with an integer will usually yield unexpected
results.
• syntax error: empty declaration
Code example:
int i;;
The file header contains a null statement. This looks like an empty declaration
statement. The K&R compiler permits this, but the ANSI C compiler does not.
• useless declaration
Code example:
int; /* no identifier */
enum e { e1, e2 }; /* introduces enum e */
enum e; /* no new information */
The ANSI C compiler requires that each statement have meaning. The first and third line
of the code example give no new information to the compiler. While the K&R compiler
would ignore these statements, the ANSI C compiler warns of a potential error.
Initializing Structures
K&R C and ANSI C use different algorithms for parsing structure/union initializers. For
example, the code:
struct { int a[3]; int b; } w[] = { {1}, 2 };
yields this with the K&R compiler:
sizeof(w) = 16
w[0].a = 1, 0, 0
w[0].b = 2
but yields this with the ANSI C compiler:
sizeof(w) = 32
w[0].a = 1, 0, 0
w[0].b = 0
w[1].a = 2, 0, 0
w[1].b = 0
The way to overcome this confusion is to be explicit about structure initializers. For example:
struct { int a[3]; int b; } w[] = { {{1}, 2} };
yields:
sizeof(w) = 16
w[0].a = 1, 0, 0
w[0].b = 2
In this example, the first { begins the initialization of the array w[]. The second { begins the
initialization of the structure w[0]. The third begins the initailzation of the array w[0].a.
Preprocessor Differences
Another difference between K&R C and ANSI C is in the preprocessor directives. While
most basic functions of the preprocessor are the same, certain features are different. The
IMAGE compiler running with ANSI C defines the symbol __STDC__ having the value 0 to
allow for conditional compiles of ANSI C code.
• Macro pasting. With K&R C, preprocessor symbols can be pasted together using a
comment, /* */. ANSI C uses the symbol ## to accomplish the same functionality. For
example, the following compiles and prints 1 in either ANSI C or K&R C:
#include <stdio.h>
#ifdef __STDC__
#define PASTE(A,B) A##B
#else
#define PASTE(A,B) A/*a comment*/B
#endif
main()
{
int vara=1, varb=2;
printf("%d\n", PASTE(var,a));
}
• Macro strings. K&R C allows you to write a preprocessor macro which takes the
argument and puts quotes around it. The method for doing this in ANSI C is to use the
# operator as in:
#include <stdio.h>
#ifdef __STDC__
#define STRING(X) #X
#else
Function Prototypes
Probably the most notable difference between K&R and ANSI C is the format of function
prototypes. In ANSI C you can declare variable types within the arguments list. K&R
requires you to declare them outside the arguments list. For example:
• ANSI C format:
int foo (int val1, int val2)
• K&R format:
foo (val1, val2)
int val1, val2;
The ANSI C compiler accepts either format for a function definition or declaration. However,
never mix the two for the same function.
Below are a few examples of both styles. Take special note of the variable argument
example. The two forms are completely incompatible.
• K&R style function takes no arguments:
int f() {} /* function definition */
int f(); /* function declaration */
• ANSI C style function takes no arguments:
int f(void) {} /* function definition */
int f(void); /* function declaration */
• K&R style function takes one argument:
int f(val) /* function definition */
int val;
{
}
int f(); /* function declaration */
• ANSI C style function takes one argument:
int f(int val) /* function definition */
{
}
int f(int); /* function declaration */
int f(int val); /* function declaration (variable
name is optional) */
• K&R style function takes three arguments
int f(val, fval, cptr) /* function definition */
int val;
float fval;
char *cptr;
{
}
int f(); /* function declaration */
• ANSI C style function takes three arguments:
int f(int val, float fval, char *cptr) /* function definition */
{
}
int f(int, float, char *); /* function declaration */
• K&R style function takes variable arguments:
#include <varargs.h>
int f(val, va_alist) /* function definition */
int val;
va_dcl
{
float fval;
va_arg ap;
va_start(ap);
while (val--) {
fval = va_arg(ap, float);
/* operate on fval */
}
}
int f(); /* function declaration */
• ANSI C style function takes variable arguments:
#include <stdarg.h>
int f(int val, float fval, ...) /*function definition*/
{
float fval2;
va_arg ap;
va_start(ap, fval); /* fval is the last fixed
argument in the definition */
while (val--) {
fval2 = va_arg(ap, float);
/* operate on fval2 */
}
}
int f(int, ...); /* function declaration */
A function prototype may be conditionally compiled to be a legal K&R declaration in Solaris
1 using the EXTERN_FUNCTION macro. For example:
/* Define a conditional macro for function prototypes */
#include <image.h>
EXTERN_FUNCTION (extern void
Foo,(int i, double j));
For functions with no arguments, use _VOID_. For example:
Memory Allocation
The memory de-allocation function free() (used with malloc()) is different in Solaris 1 and
Solaris 2. free() is declared int free() in Solaris 1 and returns 1 on success and 0 on
failure. It is declared void free() in Solaris 2 and does not return a value. Therefore, when
porting test programs from Solaris 1 to Solaris 2, check for dependencies on the return value
for free().
Table 13-5. Differences Between OS 4.1 and Solaris 2.x Header Files
Table 13-5. Differences Between OS 4.1 and Solaris 2.x Header Files (Continued)
Functions are the basic building block of a test program written in the IMAGE Test Language
(ITL). A function is a distinct section of code similar to a procedure or a subroutine in other
languages.
This section includes the following topics:
• “Functions in IMAGE” on page 14-2
• “Header” on page 14-4
• “main() Function” on page 14-9
• “Sequencer and Tests” on page 14-10
• “Datalog and Summary Statements” on page 14-24
• “Creating Test Program Modules Without a Pinmap” on page 14-26
Functions in IMAGE
Execution of a test program starts at the beginning of a function called main(). The main
function can, in turn, call other functions. ITL includes special types of functions, sequencer
functions and test functions, for creating test programs. An example of a function
definition is:
double vout(p, pname, supply) /*Type of value, function name, and params*/
int p;
char *pname; /*Parameter declarations*/
double supply;
{ /*Start of function body*/
double x; /*Definition of local variables*/
.
<statements> /*Executable statements*/
.
x = read_meter();
return(x); /*Return statement*/
} /*End of function body*/
A typical test program includes a header section, a main function, one or more
sequencer functions, a number of test functions, and some general-purpose functions.
The example test program in figure 14-1 shows how all the parts fit together. This section
describes each type of program section.
Header
#include <stdio.h> /*standard I/O header*/
#include <math.h> /*standard math functions*/
#include <image.h> /*standard IMAGE header*/
#define VMASK 0077 /*macro definition*/
#define SPECTRUM_SIZE 512
float spectrum[SPECTRUM_SIZE]; /*define a global array*/
int myflag = 0; /*define a global flag var*/
pinmap = {
/*DUT pin number pin name channel resource*/
1 "VIN" dc_matrix:1 (src:1),
2 "VOUT" dc_matrix:2,
dib "DIB" dc_matrix:3 (src:2),
24 "VCC" dutsrc:1,
};
Main Program—Beginning of executable code
main()
{ /*beginning of main*/
seq1(); /*execute the sequencer seq1 and assign bin_number*/
sort bin; /*sort the bin number result*/
} /*end of main*/
SEQUENCER Function
SEQUENCER seq1()
{ /*beginning of sequencer*/
/*
test function test test limits test binning
name # low/high label f/p */
seq contin() $1 >0 <.7v "continuity" f(0);
seq icc() $2 >20ma <25ma "supply i" f(2);
seq ac() $3 >1.55v <1.62v "amplitude" f(3) p(1);
} /*end of sequencer*/
TEST Function
TESTF icc()
{ /*beginning of testf*/
double supply_i; /*declare local variable*/
set pin=vcc dutsrc:v=5.125v; /*set up dc source*/
set meter input:pin=vcc dutsrc:i; /*set up dc meter*/
set power on: dc; /*turn power on*/
wait 10ms; /*wait for device to settle*/
supply_i=read_meter(); /*read dc voltmeter*/
test supply_i; /*test the result against limits*/
} /*end of testf*/
Header
All test programs begin with a header section. The header section must be at the top of the
source file before the first function. It contains file #include directives, macro definitions,
external variable declarations, the pinmap, and global variable definitions. Here is a sample
header section:
/* Standard header files */
#include <stdio.h> /*standard I/O header file*/
#include <math.h> /*standard math functions*/
#include <image.h> /*standard IMAGE header file*/
#define VMASK 0077 /*macro definition*/
#define SPECTRUM_SIZE 512
float spectrum[SPECTRUM_SIZE]; /*define a global array*/
int myflag = 0; /*define a global flag variable*/
Inclusion directives can contain either standard IMAGE header files or files you write. Such
a file, however, can only contain declarations. You cannot place executable code inside an
include file.
NOTE
You cannot place executable code in a header file. This restriction extends to variables. The
only variable declarations in an include file should be those that declare variables as
extern.
Inclusion directives for standard header files are written using angle brackets (<>), as in:
#include <stdio.h>
This header file is the standard IMAGE I/O file. You cannot modify any standard header files
in debug.
Inclusion header files you (or other users) write are written using double quotes (" "), as in:
#include "myheader.h"
This statement includes the file myheader.h from disk. You can modify header files you
create while in debug.
For example, the following macro substitutes 1024 wherever MAXSIZE appears:
#define MAXSIZE 1024
A test programming example using a #define directive is:
double stuff[MAXSIZE];
.
.
for(i=0;i<MAXSIZE;i++)
stuff[i]=1.75;
You can also specify macros with parameters. For example, the following macro calculates
the remainder when dividing two integers:
#define REM(a,b) ((a) - (a)/(b) * (b))
NOTE
Changing a macro in debug causes the entire file to recompile.
Pinmap
One of the first steps in writing a test program is assigning tester resources to device pins
by creating a pinmap. This allows you to program tester instruments by referencing pin
numbers of the device under test (DUT). The pinmap tells IMAGE which instruments and
channels are used by each pin of the DUT. (This can also be done using DIBView. See
“DIBView” on page 2-1 in the IMAGE Software Tools Manual.)
Usually, each pinmap line specifies a DUT pin. This pin specification includes:
• Pin number (or the word dib)
• Pin name
• Tester channel type and channel number
• Any tester ac instruments used for that pin
An example pinmap for a mixed-signal test system would be as follows:
pinmap = {
/*DUT pin number pin name channel resource*/
1 "VIN" analog:2A (lfsrc_hi),
2 "VOUT" analog:4A (lfdig_hi),
dib "DIB" analog:2B (lfsrc_gnd),
24 "VCC" dutsrc:1,
};
Test systems that use a configuration board in the test head (such as advanced mixed-
signal testers) use a slightly different form of pinmap. The following is an advanced linear
pinmap:
pinmap = {
3 "VEE" dib:27a1 dutsrc,
6 "MCLAMP" dib:1a2 dc_matrix (src:2),
};
A pin name is mapped to the corresponding pin number by a macro, a mechanism in C that
allows for text substitution. If a pinmap specifies 1 "ABC", the compiler creates a macro that
defines ABC as 1. From then on, the compiler replaces ABC with 1. This works well for
statements such as:
set pin = ABC dutsrc: v = 5v;
However, error messages result from something like:
MyFunction()
{
int ABC;
ABC = 7;
return ABC;
}
because the compiler changes this into:
MyFunction()
{
int 1;
1 = 7;
return 1;
}
Because of this side effect, choose unique pinnames, ones not used elsewhere in the test
program. Also, avoid using reserved words in pinnames.
The pinmap can also specify stored databits, field specifications for groups of pins or
databits, and additional tester resources not specified elsewhere.
Declare the pinmap in the header section of the test program file before the first function in
the file and before any statements referring to DUT pins. If a program uses multiple source
files, the pinmap must be included in every program file. To avoid having multiple copies of
the pinmap, put it in a .h file and use a #include directive in each file used by the test
program. See the instrumentation manual for your tester for information on pinmap
statement syntax.
You can also create test program modules without a pinmap. See “Creating Test Program
Modules Without a Pinmap” on page 14-26.
main() Function
Each test program must contain one function called main(). A program always begins
execution with main(). This function is used to globally set up and reset, query the operator
if necessary, and then call several functions to perform testing. One or more of these
functions is a sequencer function.
In the following main function, a sequencer function that determines a bin number is called
and executed. This bin number is used to sort the device with the sort bin statement. (See
“Testing and Classifying Devices” on page 15-1 on sort bin and other statements.)
main()
{
setup_all_digital(5.0v,0.4v); /*High level setup function*/
printf("Ready to begin testing...\n"); /*Message*/
seq1(); /*execute the SEQUENCER seq1 and assign bin number*/
sort bin; /*perform a sort on the bin number result*/
}
Sequencer Functions
A sequencer function is an ITL specialized function. It contains sequencer statements that
specify a set of tests to be performed, the order of their execution, the test limits, and the
binning strategy. A test program can have more than one sequencer.
A sequencer function is usually called from the program’s main() function to execute a set
of test functions and determine a bin number. It must begin with SEQUENCER in upper case
followed by the function name. The syntax is:
SEQUENCER sname()
{
.
<sequencer statements>
.
}
Figure 14-2 shows that sequencer functions contain sequencer statements which, in turn,
call test functions that contain test statements. A sequencer function returns the bin value
following its execution (see “Test Parameter List” on page 14-13). Although a sequencer
function typically contains only sequencer statements, other statements are allowed.
A sequencer function returns an undefined value. Do not use it in a sort bin statement.
Using a sequencer return value in a sort bin statement may cause devices to be
incorrectly binned. See “The sort bin Statement” on page 15-14.
main()
{
<call sequencer function>
}
Sequencer Function
SEQUENCER<name of sequencer
function>()
{
<sequencer statement>
<sequencer statement>
}
Sequencer Statement
Test Statement
• Determines pass or fail
(Limit comparison, for example)
• Datalogs result, if enabled
Sequencer Statements
You specify a sequencer statement within a sequencer function. This statement calls a
test function and takes a pass or fail action based on one or more test results determined
by the test function. An example would be:
/*test name test # test limits test label binning*/
seq icc() $2 >20ma <25ma "supply i" f(2);
A sequencer statement has the following effects:
• It calls the specified test function.
• Inside the test function, a test statement must be called to make a pass/fail decision on
each test.
• After the test function returns the test result, the sequencer statement evaluates each
result in order and executes the specified pass/fail action.
A sequencer statement includes the name of a test function to be called and a test
parameter list for each test to be performed inside the test function. Each test parameter list
can contain the following information:
• Test limits
• Test number
• Datalog label
• Datalog result format
• Pass action
• Fail action
• Test conditions
• Binning information
All fields are optional. Many fields have defaults if they are not specified.
Sequencer Syntax
A sequencer statement has two forms, simple and compound. The simple form of the
sequencer statement specifies a single test parameter list. It always begins with seq. The
syntax is:
seq <test function> <test parameter list>;
where:
<test function> A specified test function (TESTF) that performs one or more tests
and calls the appropriate test statements internally to determine
pass or fail for each test result and to perform datalogging. A test
function call includes the name of the test function and optional
parameters to the function in parenthesis, as in ileak() or
icc(pnum). See “Test Functions” on page 14-18 and “Test
Statements” on page 14-18.
<test parameter list>
A series of fields that specify test limits, identifying information
and pass or fail information. A test function can have more than
one test parameter list.
A compound sequencer statement specifies a test parameter list for each test and requires
braces ({}) around multiple test parameter lists. The syntax is:
seq <test function>
{ <test parameter list>;
<test parameter list>;
on a printout for data analysis and for user selection. Give all
tests in a program a unique test number. This test number
should not change between separate runs in the same lot. If you
are using more than one sequencer function, explicitly set the
number of the first test in each sequencer so the numbers do not
overlap.
The compiler also has an automatic numbering capacity. If you
do not specify the test number, the compiler automatically uses
the last test number incremented by one. By default, the
compiler starts numbering at 1 at the beginning of each
sequencer function. To set the starting number for a sequencer
or a group of tests, number the first test in the group and the
compiler assigns test numbers for the remaining tests in the
group. For example, to number a sequencer containing 50 tests
starting at 200, specify $200 as the test number for the first. The
compiler assigns numbers to the other tests, resulting in 50 tests
numbered 200 to 249.
repeat=> This field contains a constant between 2 and 65535. See
“Repeated Test Limits” on page 14-17.
"<datalog label>" A quoted string constant of up to 18 characters, such as "supply
i". This character string labels the result on a datalog printout. If
you do not specify a datalog label, IMAGE uses the test function
name specified in the <test function> field as a default.
"<datalog format>" A quoted string constant beginning with the character %. It
specifies the test result format in a datalog printout using
printf-style formats such as %5.2f. (See “Input and Output
Functions” on page 16-1 for an explanation of formatted I/O
functions.) You can optionally place a units string of up to five
characters after the format of the result. For example, "5.2f uA"
uses the string uA for the units. If you do not specify a datalog
format, the compiler uses the format specified in the <limit
spec> field. If you do not specify limits, the compiler uses a fixed
point format with two digits to the right of the decimal point.
When you set the format string of a test, the datalog format
specifier in the STDF file is set as specified. However, the
datalog formatters provided with IMAGE interpret the standard
ASCII formats, e, f, g, c, and s as f (fixed decimal floating point)
and formats u and i as d (decimal integer).
NOTE
The datalogger is limited to 24 bits. High and low test limits cannot exceed this limit.
NOTE
Use of pa() is discouraged. Most test programs that require this syntax can use disqualify
binning. (See “Assigning Bin Numbers Using Disqualify Binning” on page 15-8.)
f(<expression>) Specifies an action if a test fails. If the test fails, the value of the
expression is remembered as a bin number. The expression can
be a bin number or any legal expression. If in stop on fail mode
(the default) and the test fails, the device is “disabled” and no
further testing takes place on the device. If in continue on fail
mode, testing continues. The expression in f(<expression>) is
always executed.
fa(<statement>) Specifies an action if a test fails. If the test fails, the specified
statement or statements are executed. The statement in
fa(<statement>) is only called if the test fails. The statement
cannot be an instrument statement.
NOTE
Use of fa() is discouraged. Most test programs that require this syntax can use disqualify
binning. (See “Assigning Bin Numbers Using Disqualify Binning” on page 15-8.)
limit set Indicates the test limit values for a test, either the low or the high
limits or both or an exact value or no limits.
lowlim The lower test limit is the symbol > or >= followed by a floating
point constant or variable, as in >=4.5mv, >-20db, or >(low).
The test result must be greater than or equal to the specified
value for the test to pass.
highlim The high test limit is the symbol < or <= followed by a floating
point constant or variable, as in <8.4mv, <5db, or <=(high). The
test result must be less than or equal to the specified value for
the test to pass.
See “Disqualify Binning Syntax” on page 15-8 and “Test Conditions in a Sequencer” on page
15-28 for additional sequencer examples using disqualify binning and test conditions
statements.
Test Functions
A test function is a specialized function called from a sequencer statement to perform one
or more tests. Inside a test function, you can:
• Set up tester instrumentation to provide an input stimulus to a device
• Measure or capture device output
• Analyze the results to obtain one or more test results
• Call a test statement with each test result to make a pass/fail determination and to
datalog the result
• Include other ITL and C statements to modify the behavior of test statements
A test function must be called by a sequencer statement. It must begin with the word TESTF
in upper case preceding the function name in a function definition. The syntax of the test
function is:
TESTF tname()
{
<ITL language statements>
.
.
<test statement>
.
}
Test Statements
A test statement performs two main operations:
• It determines pass or fail on a test result you specify.
• It datalogs the result if datalogging is enabled.
A pass or fail determination can be made in different ways depending on the type of test
statement. For a simple analog parametric test, the test result is compared with the test
limits specified in the corresponding test parameter list in a sequencer statement.
The test statement and sequencer statement work together. The sequencer statement
stores the test limits and datalogging information for each test result. The test statement
accesses this information and uses it to make a pass or fail decision and to perform
datalogging. The test statement stores the pass or fail decision so that the sequencer
statement can use it to take a pass or fail action.
A test statement can have several forms. The basic form of a parametric test statement
allows you to specify a numerical result calculated or measured inside a test function. The
syntax is:
This example, shows the sequencer and icc test from a test program. The test sources a
voltage to the DUT and reads the result. In this test function, the test statement test
supply_i is used to test the result against the limits for the test. The value of supply_i is
obtained from the read_meter function. This value is compared against the limit in the seq
icc() line in the sequencer.
In a compound sequencer statement, the test function must call one test statement for each
test being performed. The first call to the test statement should correspond to the first test
parameter list specified in the sequencer statement. The second call to the test statement
should correspond to the second test parameter list specified, and so on.
This type of test statement uses a software limit comparison to determine pass or fail. The
datalogger is called to log the result if datalogging is enabled. The datalogger is passed the
test result, the pass or fail decision, and the test number, label, and format specified in the
test parameter list for this test. The test statement stores the pass or fail decision so that the
sequencer statement can access it later to determine whether to take a pass or fail action.
You can add the reserved words pass or fail to the end of a test statement to force pass
or force fail. If you specify a result, it is datalogged as the result of the test. If you do not
specify a result, no value is datalogged, only the fact that the test passed or failed. Examples
are:
test myresult pass; /*force pass, datalog myresult*/
test myresult fail; /*force fail, datalog myresult*/
test pass; /*force pass, no value datalogged*/
test fail; /*force fail, no value datalogged*/
NOTE
If you use this statement to override the default test function conditions inside a test
function, the changes are only valid for that test function. At the beginning of each test
function, the conditions are automatically reset to their default state.
the next test parameter list in the sequencer. The index can be a
constant or a variable and specifies which test parameter list to
use. 0 specifies the first test parameter list, 1 the second, and so
on.
The index option is useful when a test is conditionally skipped. Take, for example, the
following sequencer:
seq offset_gain()
{ $100 "ac offset" >-2.1v <2.1v f(4);
"ac offset drift" >-0.3v <0.3v f(5);
"ac gain" >3.95v <4.05v f(4);
}
In test function offset_gain you could set up the following test condition:
test ac_offset; /* "ac offset" test result */
if (read_test_condition() == HOT) /* Do "ac offset drift" only */
test calc_offset_drift(); /* if test condition is HOT */
set testf_cond: test_params: index = 2;/* Make sure last limits are */
test ac_gain; /* used for "ac gain" test */
NOTE
If any tester statements affecting a test are executed, for example tl_write_lowlim() or
tl_write_label(), the set testf_cond: test_params: index= statement must be
executed before these statements. In other words, these statements must appear between
the set testf_cond: statement and the test statement.
In this case, the device is “disabled” and no further testing is performed. If you use disqualify
binning and the program is running in stop on fail, the device is disabled when all pass
bins are closed.
Disabling the device under test means that no additional instrument programming takes
place and that no additional test or sequencer functions are called. This effectively
terminates testing on the device.
However, noninstrument statements in the test function following the failed test and
statements between sequencer statements following the failed sequencer statement
continue to execute. You can use the statement tl_site_active() to avoid executing
these statements. For example:
sequencer1()
{
seq test1() $1 >5ma <10ma f(2); /* If the device fails this test */
if (tl_site_active())
printf("About to do test2.\n"); /* Then this is not executed */
seq test2() $2 >0v <2.7v f(2);
}
You can re-enable testing on a device using the statement:
set site_enable_all;
You can use this statement to continue testing a device after it fails. Use it, for example, to
grade devices. After a device fails in one sequencer with tight limits, the set
site_enable_all statement can be used to allow a second sequencer to be called with
looser limits.
You can also declare pin names and fields by declaring them at the top of each file. This
means that each file would include declarations for the pin names used in that file.
One file cannot include both the pinmap and the declarations for pin names and fields. One
file should contain either the pinmap or the declarations.
Lists of pins are not supported but field notation is allowed. For example, you cannot use:
set pin = (DBUS1, DBUS2) ...
But you can define these pins as a field in the pinmap. For example:
set pin = (FIELD1) ...
Debug displays will work for any declared pins. If all pin names in the pinmap are not
declared in a file, however, a display cannot manipulate any undeclared pins.
test read_meter();
}
The following shows the same test program rewritten to place the pinmap in a separate file
from the sequencer and test function code and to organize the program code into multiple
files (modules):
/* Pinmap file - "pinmap.tl" - This is now a ".tl" file. */
#include <image.h>
pinmap = {
1 "VCC" dib:27a1 dutsrc,
};
TL_PINMAP;
/* Pin name file - "pinnames.h" */
extern TL_PINNAME VCC;
/* File "a.tl" */
/* This file is now generic. It does not need the pinmap or "pinname.h". */
#include <stdio.h>
#include <math.h>
#include <image.h>
main()
{
seq1();
sort bin;
}
SEQUENCER seq1()
{
seq test1() < 1ma f(2) p(1);
}
/* File "b.tl" */
#include <stdio.h>
#include <math.h>
#include <image.h>
#include "pinnames.h" /* This file needs "pinnames.h" */
TESTF test1()
{
set pin = VCC dutsrc: v = 5.0v;
set meter input: pin = VCC dutsrc: i;
test read_meter();
}
not included, the compiler gets the type from other statements in the program. When such
statements do not precede a TMS statement, an error results.
Therefore, to create modules without a pinmap that include the TMS, use the following
macros:
TL_TSTHD_MS Defines a mixed-signal test head (A540).
TL_TSTHD_AMS Defines an advanced mixed-signal test head (A580).
These macros are defined in the IMAGE header file image.h and will produce a hardware
programming statement which will identify the test head type to the compiler. Each function
using the TMS should include this macro before the TMS statement. The macro definitions
include a conditional statement so that the hardware statements are not executed at run
time. The definitions look like this:
#define TL_TSTHD_AMS \
{static int dummy=0; if (dummy)
<AMS specific statement>;}
This section describes ITL statements that allow you to set and control tester functions and
to read parameters from within a test program. These tester-specific statements relate to
programmed waits, assigning bin numbers, run-time errors, and accessing system
information.
This section includes the following topics:
• “Testing Functions” on page 15-2
• “Assigning Bin Numbers” on page 15-6
• “Assigning Bin Numbers Using Disqualify Binning” on page 15-8
• “Monitoring Maximum Consecutive Failures” on page 15-16
• “The Input Adjust Function” on page 15-20
• “Test Conditions” on page 15-27
• “Controlling Run-Time Errors” on page 15-31
Testing Functions
The following subsections describe programming statements you can use in a test program
during testing.
Wait Statement
The wait statement causes a program to wait for a specified amount of time. Syntax for the
wait statement is:
wait <expression>;
where:
<expression> Must evaluate to a floating point number that represents the
number of seconds to wait.
The test program waits for the specified amount of time, then continues at the next
statement. The minimum wait is 10µs and the resolution is 10µs.
Rdelay Function
After relays are opened or closed, a hardware settling time delay is required before starting
a measurement. Since ITL statements that open and close relays return without waiting for
this delay, you must provide the delay to be sure hardware has settled. The following
function executes the necessary delay:
rdelay();
Certain language statements, such as set power on and all read_meter() functions, do
perform an rdelay.
tl_set_wait
NAME tl_set_wait—Set a retriggerable wait time.
tl_wait_wait
NAME tl_wait_wait—Start Terabus settling delay timer
DESCRIPTION Wait for wait timer done. In case of timer hardware problems,
there is a two minute timeout on the wait. If the remaining wait
period will be legitimately longer than two minutes,
tl_set_wait() and tl_wait_wait() are not recommended.
ARGUMENTS None
RETURN VALUE None
NOTE
Use either direct binning or disqualify binning in a test program, but not both. If you mix the
two types of binning, the direct assignment of a bin always takes precedence.
Direct Binning
Direct binning uses simple sequencer statements to assign a bin number to a device, as in:
seq cal() $100 "ac offset" >-2.1v <2.1v f(4);
In a simple test program, testing proceeds sequentially through each test until a test fails.
At this point, a bin number is assigned and testing usually stops. If the device passes all
tests, the last test generally assigns the device to a pass bin (such as bin 1). IMAGE
supports binning for bins 0 to 255.
You can program more complex binning strategies using multiple sequencer functions or
fail and pass actions. For example, a program can include several sequencers with each
sequencer determining a bin number. A final bin number can then be calculated based on
the bin numbers from the individual sequencers.
Pass Actions
A pass action, written as p(<expression>) or pa(<statement>) or both, specifies an
action to be taken if the test passes. If you use p(<expression>) and the test result
passes, the value of the expression is remembered as a bin number. Any legal expression
is allowed, although typically a constant bin value is used. You can also call a function to
achieve some side effects, as in p(getbin()).
If you use pa(<statement>) and the test result passes, the specified statement or
statements are executed. In either case, testing of the device continues. This statement can
be a function call, a goto statement, or any other C language statement. It cannot be an
instrument statement such as a set, reset, start, stop, or move. At this point, a goto
statement is often used to change the flow of the sequencer.
The expression in p(<expression>) is always executed. If, for example, the expression is
a function call such as p(calc_bin_number()), this function is called to determine the pass
bin number even if the test fails. The bin number is only used if the test passes. The
statement in pa(<statement>) is only called if the test passes.
Fail Actions
A fail action, written as f(<expression> or fa(<statement>) or both, specifies an action
if the test fails. If you use f(<expression>) and the test fails, the value of the expression
is remembered as a bin number. Any legal expression is allowed, although typically a
constant bin value is used. If in stop on fail mode (the default) and the test fails, the device
is “disabled” and no further testing takes place on the device. If in continue on fail mode,
testing continues. If you use fa(<statement>) and the test result fails, the specified
statement or statements are executed and testing of the device continues. The statement
in fa(<statement>) cannot be an instrument statement such as set, reset, start, stop,
or move.
The expression in f(<expression>) is always executed. If, for example, the expression is
a function call such as f(calc_bin_number()), this function is called to determine the fail
bin number even if the test passes. The bin number is only used if the test fails. The
statement in fa(<statement>) is only called if the test fails.
NOTE
The use of fa() and pa() is discouraged. Most test programs using these constructs can
use disqualify binning instead.
{
1 "GRADE_1" pass,
2 "GRADE_2" pass,
3 "GRADE_3" pass,
4 "BAD_DEVICE" fail,
};
main()
{
setup();
test_device();
sort bin;
}
SEQUENCER test_device()
{
seq leakage() <100ua c(1 to 3);
seq distortion() >60.0dB c(1)
>55.0dB c(2)
>50.0dB c(3);
seq gain() >4.995 <5.005 c(1)
>4.950 <5.050 c(2, 3);
}
In this program, bins 1, 2, and 3 are all pass bins, but for different grades of the device. The
limits for the leakage test are the same for all grades, so all three bins are closed if this test
fails. The distortion test uses separate limits for each grade. The gain test uses one set of
limits for bin 1 and another set for bins 2 and 3. A device is binned in bin 1, 2, 3, or 4
depending on which limits it passes. If the device fails the leakage test, testing stops
immediately since all pass bins are closed. If running in the continue on fail mode, however,
testing continues until the end of the test program.
results which caused bins to be closed, but passed an alternate set of limits, are marked
with a (C). In STDF files, bit 5 in the PARM_FLG of the Parametric Test Result Record
(PTR) is set to indicate a test passed an alternate set of limits. (See “Parametric Test Record
(PTR)” on page 24-24.)
Disqualify binning allows you to specify multiple limits for a test. The datalog output will show
the limits against which the test result was compared. If a test result fails a set of limits and
is compared to more than one set of limits, the last set of limits used are shown in the
datalog report. This case is identified by (C) (since bins were closed) if it passed the last
set of limits or (F) if it failed all limits.
For example, in the example in “Disqualify Binning Syntax” on page 15-8, if the leakage test
result is 50 µA, the distortion test result is 53 dB, and the gain test result is 5.5, the following
datalog output will be generated when datalogging all tests:
1 leakage leakage 50 ua < 100 ua
2 distortion distortion 50.0 dB < 53.0 dB (C)
3 gain gain 4.950 < 5.500 (F) < 5.050
The command prints out information on whether or not the part has been binned and the
current bin numbers, both software bin and handler bin, assigned to the part. When using
disqualify binning, the current open or close status of each bin is also shown.
All binning in a test program refers to software bin numbers. Device handlers, however, are
often limited to a small set of bin numbers. You can use a device_bins declaration to
specify the handler bin number to be used for each software bin number. The device_bins
declaration also allows you to specify a bin name for each software and handler bin.
The following is the syntax for the device_bins declaration:
device_bins =
{
<bin_num> ["<bin_name>"][hbin = <hbin_num> ["<hbin_name>"]]
[pass | fail | error],
.
.
};
An example is:
device_bins =
{
1 "GRADE_1" hbin = 1 "GRADE_1" pass,
2 "GRADE_2" hbin = 2 "GRADE_2" pass,
3 "GRADE_3" hbin = 3 "GRADE_3" pass,
4 "FAIL_LEAKAGE" hbin = 9 "FAIL_BIN" fail,
5 "FAIL_DISTORTION" hbin = 9 fail,
6 "FAIL_GAIN" hbin = 9 fail,
99 "RUN_TIME_ERROR" hbin = 9 error,
};
If you do not specify a handler bin number, the handler bin number is assumed to be the
same as the software bin number. If you do not specify pass or fail, bin 1 is assumed to be
a pass bin and all other bins are fail bins.
Bin names are defined as macros and can be referenced anywhere in a test program. The
bin names are also included in summary reports and are available in STDF datalog files.
You can also specify the error bin number in a device_bins declaration. The default bin
number for binning devices that encounter a run-time error is bin 0. You can change this bin
number using the error option in the device_bins statement. The error bin is assumed to
be a fail bin.
Hardware bin assignments have the following restrictions:
• You cannot assign one bin name to any one hardware bin.
• You cannot assign any one hardware bin to more than one bin type (pass, fail, error).
For example, the following statement violates both these restrictions:
device_bins =
{
/* SW_Bin SW_Bin_Name HW_Bin HW_Bin Name P/F/E */
1 "SW_Pass_1" 1 "HW_Pass_1" pass,
2 "SW_Fail_2" 1 "HW_Fail_2" fail
}
NOTE
Do not assume that the return value of a sequencer function is a valid bin number. Using a
sequencer return value in a sort bin statement may cause devices to be incorrectly
binned.
NOTE
The set handler_bin statement is obsolete. Although IMAGE supports this syntax, you
should use the device_bins syntax. (See “The device_bins Declaration” on page 15-13.)
You can use a list of these statements to map all relevant software bin numbers to the
corresponding handler bin numbers. Any bin number not mentioned continues to map to the
same number. Only execute these statements once after loading the test program. This is
best done by including them in the tl_init function. For example:
tl_init()
{
set handler_bin bin = 99 hbin = 9;
set handler_bin bin = 0 hbin = 10;
}
In this example, the handler does not support bin numbers 99 and 0. These are mapped to
other values. If the sort bin statement gets a bin number of 99 or 0, bin number 9 or 10 is
sent to the handler. If the sort bin statement gets any other bin number, that number is
sent to the handler.
You can use the set handler_bin statement to define a real handler bin number for the
software bin value NO_BINNING as shown in this example:
set handler_bin bin = NO_BINNING hbin = 0;
After executing this statement, if a sort bin statement is executed without first having
assigned a bin number, a bin number of 0 is sent to the handler.
Initializing Sites
To initialize sites for MCFD use the function:
int tl_mcfd_init(unsigned count)
You must call this function once for each site you wish to initialize, from within a serial loop
for a multisite test program. Otherwise, all sites’ counters are set to count. This function
returns the count.
The following example shows how to use this function to select some sites out of the total
number of sites supported by a test program:
serial {
switch (tl_site) {
case 0: tl_mcfd_init(count);
case 1: tl_mcfd_init(count);
}
}
Where count has previously been initialized to some value.
MCFD monitoring is only performed for initialized sites. This allows you to perform MCFD
on all sites supported by the test program or only on some subset.
This function does not initialize if MCFD monitoring is on. MCFD must be first turned off (or
never have been turned on). You can change the sites monitored using this function if you
follow this restriction.
Controlling Sites
To disable sites use the function:
int tl_mcfd_disable_site()
This function disables a particular site if called from within a serial loop or all sites if not. If
sites are already disabled, it returns FALSE (0).
To reset the MCFD counter for a particular site or all sites use the function:
int tl_mcfd_clear_counter()
For individual sites this function must be called from within a serial loop. MCFD monitoring
need not be turned off for the counters to be reset.
User Function
The prototype user function for MCFD is:
int tl_user_mcfd_handler(int site, unsigned count)
This function is called whenever the MCFD count is reached on any site. It is called once
per site if multiple sites reach the MCFD count on any one run.
-site <site spec> Specifies the site or sites. This can be a site number or all for
all sites.
-init # Initializes the MCFD counter. If you do not specify a site number,
all sites are initialized. If used with -on, the MCFD is initialized
first. If used with -off, the MCFD is turned off first before being
initialized.
-bin Specifies whether to monitor hardware (hbin) or software (sbin)
bins. The default is hbin.
You can combine some options of this command. If one operation in the command does not
succeed, however, none of the operations will work. For example, you enter:
max_consec_fail_dev -init 5 -on -bin hbin
If initialization fails (the MCFD is already on, for example), -on and -bin are not processed.
<hi_lim> This is the upper limit of the input values. tl_input_adjust will
not try more positive input values. Must be a constant or a
variable.
<output> This expression is compared with the desired output value after
each adjustment step. The results of this comparison are used to
determine the direction of the next adjustment to the input. Can
be any expression.
<resolution> Search continues until the difference between successive tries is
less than this number.
<polarity> Direction of search. Software determines direction based on first
two tries.
<max_loop_count> Maximum number of iterations to find input.
The adjust_func() function you supply should look like this:
double adjust_func(input)
double input;
{
double result_of_device_test;
...
...
test the device based on 'input'
...
return(result_of_device_test);
}
The return value from tl_input_adjust indicates exit status as follows:
IA_INVALID_ARGUMENT= -1
Bad argument: hi_limit less than lo_limit or invalid polarity.
IA_RETURN_OK=0 A solution was found. It will be returned in input.
IA_RETURN_NO_RESOLUTION=1
Function has iterated max_loop_count and has failed to
converge on an input value to the specified resolution. input
contains zero.
IA_RETURN_INPUT_TOO_LOW=2
The input value lies below the lower limit. input contains the
lower limit lo_limit.
IA_RETURN_INPUT_TOO_HIGH=3
The input value lies above the upper limit. input contains the
upper limit hi_limit.
#include <image.h>
#define MAX_LOOPS 1000
pinmap = {
1 “VREG” dib:1a2 dc_matrix (apu,src:1),
2 “SFST” dib:1b2 dc_matrix (src:2),
3 “PSEN” dib:1c2 dc_matrix (apu,src:3),
};
main() {
seq1();
sort bin;
}
SEQUENCER
seq1()
{
seq vpsen() >-10.0v <10.0v f(2) p(1);
}
TESTF
vpsen()
{
double psen_v,adj_psen();
enum Ia_returns status;
set pin=(VREG)
apu:v=0v
force:v
gate:off
disconnect;
set pin=(SFST)
src: v=0.0v;
set pin=(SFST) disconnect:src;
rdelay();
tlevel.vil = x;
failed = (x < limit);
break;
case ADJ_VIH:
tlevel.vih = x;
failed = (x < limit);
break;
case ADJ_VOL:
tlevel.vol = x;
failed = (x > limit);
tlevel.vcp = (tlevel.vol+tlevel.voh)/2;
break;
case ADJ_VOH:
tlevel.voh = x;
failed = (x < limit);
tlevel.vcp = (tlevel.vol+tlevel.voh)/2;
break;
case ADJ_IOL:
tlevel.iol = x;
failed = ( x > 4ma);
break;
case ADJ_IOH:
tlevel.ioh = x;
failed = ( x < -4ma);
break;
}
func_setup(static_adj.vdd, &tlevel, &static_adj.pecl);
pat_power(1);
run_pat("simple.pat", NULL, RUN_FREE_SCL); /* Super Clock NO sync */
wait_until_h50_halt();
pat_power(0);
failed = read_hsd50_results(NULL) !=0 ;
#ifdef ADJ_DEBUG
printf("Adjusting %d, value %f, result %f ABS=%f\n",
static_adj.what, x, (double)failed,fabs(x));
#endif
return (double)!failed;
}
/* Datalog IOL and IOH values */
TESTF
log_pad(avdd, acmos, apecl, amin, amax, astep, adirn, awhat)
double avdd;
PIN_LEVELS *acmos, *apecl;
double amin, amax, astep;
enum Ia_adjust_polar_values adirn;
ADJ_WHAT awhat;
{ enum Ia_returns status;
double answer;
static char *stat_map[] = { "Badarg", "Ok", "MaxLoops", "Too Low", "Too High"};
/* save args to adj func */
static_adj.vdd = avdd;
static_adj.cmos = *acmos;
static_adj.pecl = *apecl;
static_adj.what = awhat;
/* Note: adj_func returns 0.0 for fail, and 1.0 for pass.
* the DESIRED value is 0.5 (not 0.0) to prevent degenerate behavior, since
* tl_input_adjust checks for actual >= desired in POSITIVE case,
* and 1.0 (and 0.0) are both >= 0.0 */
status = tl_input_adjust(adj_func, amin, amax, 0.5, astep,adirn, 100, &answer);
#ifdef ADJ_DEBUG
printf("Status %s, answer %f\n", stat_map[status+1], answer);
#endif
if (status == IA_RETURN_OK)
test answer;
else
test answer fail;
}
in real time. If during the adjustment process, the input value is adjusted higher (or lower)
three times in a row, the algorithm temporarily stops its binary search and continues linearly
until the input becomes high (or low) enough so that it must be adjusted lower (or higher)
again. Linear search means that instead of successive input values coming closer and
closer together, the algorithm keeps the difference between the inputs the same and keeps
taking steps in that direction of that same size. Once the input becomes high (or low)
enough, the algorithm reverts to its regular binary search method.
The input may, for example, be drawn higher and higher by an output which is drifting lower.
The input must be moved much higher so that it can get the output to move higher again.
The binary search keeps changing the input by smaller and smaller increments. These
smaller and smaller changes would not stop the drifting, because the input would never get
high enough. The temporary linear search gets the process back on course.
Test Conditions
IMAGE includes test program syntax that allows you to test and classify devices using test
conditions. Typically, test conditions are used to specify the conditions under which the
device is being tested, for example, the temperature, such as hot, cold, or room
temperature. Test conditions can also be used to include special tests or to specify different
test limits that are only used in some circumstances, such as testing a lot of devices to a set
of specifications for a particular customer.
Test conditions can also be used to influence the testing of a device by having the test limit
values depend on the active test condition and, if necessary, changing the flow of the test
program depending on the active test condition.
ROOM: >-1.8v <1.8v HOT: >-2.5v <2.5v COLD: >-1.7v <1.7v c(2)
ROOM: >-2.1v <2.1v HOT: >-2.7v <2.7v COLD: >-2.0v <2.0v c(3);
An example of a compound sequencer statement for grading devices at different
temperatures would be:
seq cal() {
$100 "ac ref" >9.998 <10.002 f(10);
$101 "ac offset" ROOM: >-1.2v <1.2v
HOT: >-2.0v <2.0v
COLD: >-1.1v <1.1v c(1, 2)
ROOM: >-1.8v <1.8v
HOT: >-2.5v <2.5v
COLD: >-1.7v <1.7v c(3)
ROOM: >-2.1v <2.1v
HOT: nolimits
COLD: >-2.0v <2.0v c(4);
$102 "ac gain" ROOM: >4.95v <5.05v
HOT:
COLD: >4.94v <5.06v c(1)
ROOM: >4.90v <5.10v
default:>4.85v <5.15v c(2, 3)
>4.80v <5.20v c(4);
}
if (current_test_cond == COLD)
{ ...
}
You can get the name of the currently selected test condition using:
read_test_condition_name();
This function returns a pointer to a string (char *) which contains the name. For example:
Lprintf( "Current test condition is: %s\n", read_test_condition_name() );
The test condition used to test a lot of devices is recorded in STDF datalog files. The test
condition name is stored in the TEST_COD field of the Master Information Record (MIR). (If
you are using STDF V3, test condition names can be up to three characters. STDF V4 has
no such limitation.)
When an error occurs, the error handler function is called with the number of the error as a
parameter. (Error numbers are listed in IMAGE Quick Help.) The error handler function can
look at the error number passed to it, determine what action to take, and perform that action.
For instance, assume your error handler function is called myhandler and run-time error
number 4 occurs. If your test program includes the statement:
set error handler = myhandler;
the number 4 is passed to the myhandler function. Having intercepted the error, myhandler
can now respond to error number 4. It can perform a series of actions and then exit from the
test program, it can force IMAGE to take a different action instead of its default action, or it
can let IMAGE take its default action.
Which action IMAGE takes depends on which error action code your error handler function
returns to IMAGE. The possibilities are:
ERROR_FORCE_BIN Bin the device in the error bin.
ERROR_FORCE_FAIL Force the current test to fail.
ERROR_IGNORE Ignore this error.
ERROR_PRESET Allow IMAGE to respond to this error as usual (default action).
These error action codes are defined in a header file named tlerror.h located in the
$IMAGEBIN/itlh directory. Before you can use these error action codes as return values,
you must include tlerror.h in your test program. To include it, insert the following
statement after the standard header files in your test program:
#include <itlh/tlerror.h>
Omitting this statement results in undefined error action codes.
The following is a sample error handling function:
/* Standard header files */
...
#include <itlh/tlerror.h> /* Required for ERROR action codes */
main()
{
...
set error handler = myhandler;
...
}
switch(error){
/* CLEAN UP BEFORE RESPONDING TO ERROR 16: "segmentation fault" */
case 16:
printf("\nERROR %d: Segmentation fault in test program!\n",error);
cleanup();
return(ERROR_PRESET); /* default action */
break;
/* IGNORE ERROR 1506: "No rdelay() since last relay was programmed" */
case 1506:
printf("\nERROR %d: rdelay() required!!\n",error);
printf("rdelay() has been executed for you.\n");
rdelay();
return(ERROR_IGNORE);
break;
} /* end myhandler */
cleanup()
{
printf("Clean up in progress...\n");
...
}
main() {
myerror_routine(WARNING);
myerror_routine(STRANGE_ERROR);
myerror_routine(1123);
myerror_routine(GRISLY_ERROR);
}
switch(error){
case WARNING:
printf("This is just a warning.\n");
tl_error_user("Nothing printed out", ERROR_IGNORE);
break;
case STRANGE_ERROR:
tl_error_user("What a strange error!", ERROR_FORCE_FAIL);
break;
case GRISLY_ERROR:
tl_error_user("What a grisly error!", ERROR_FORCE_BIN);
break;
default:
printf("ERROR %d not defined!\n", error);
tl_error_user("Nothing printed out.", ERROR_IGNORE);
break;
} /* end switch*/
} /* end myerror_routine */
Running this program produces the following output:
% run
This is just a warning.
ERROR #0 - What a strange error!
ERROR 1123 not defined!
ERROR #0 - What a grisly error!
Program stopped for in myerror_routine at line 29
Notice that the function tl_error_user identifies all errors as ERROR #0.
those of type ERROR_FORCE_HALT. You can, for instance, continue to run a test program
beyond a failing test to another test. The error messages for any errors continue to appear,
however, so that you know the errors are occurring.
Use this function by typing:
tmode -cont_on_error
Or you can set this mode with the mouse using the SET TERMINATION MODE item on the RUN
pull-right menu or by accessing this tmode switch from within a test program. (See “Setting
Program Termination Modes” on page 5-24.) Turn off this mode by selecting another testing
mode (either -cont_on_fail or -stop_on_fail).
ITL includes input and output functions that allow input from the terminal keyboard to a
program, output from a program to the terminal screen, and program input and output to disk
files.
This section includes the following topics:
• “Using Input and Output Functions” on page 16-2
• “Input To and Output From the Terminal” on page 16-4
• “Input To and Output From a File” on page 16-10
• “Input To and Output From Strings and Characters” on page 16-14
• “Special I/O Functions” on page 16-15
Function Description
Function Description
printf()
printf() converts characters and numerical values stored in variables in a program to an
output string and prints the string to the terminal.
NOTE
ITL test programs are run in a high priority mode under UNIX and Solaris to eliminate
interrupts and ensure measurement repeatability. This technique may delay the
appearance of printf strings. If the time when a printf statement appears on the screen
is important, use the fflush function (see “fflush()” on page 16-15) to force the printf
statement to the screen at a certain time.
printf() has two parts—a control (or format) string and a list of variables. The syntax is:
printf("control string", var, var,...);
Within the control string are two kinds of data: characters printed literally to the output
stream, and conversion specifications. The figure 16-1 shows the parts of a printf()
statement.
Control string
Conversion specification
Literal characters
Conversion Specifications
A conversion specification converts and prints the next successive variable after printf().
Each variable listed after a control string must have a conversion specification. All
conversion specifications begin with the % character and end with a conversion character.
Additional modifiers can be used to control format. The syntax is:
%[<conversion modifiers>]<conversion character>
Table 16-2 lists printf conversion characters. Table 16-3 lists printf conversion
modifiers.
Character1 Output
Modifier1 Output
- (minus sign) Converted value is printed beginning at the left of its field width (left
justified).
+ (plus sign) If positive, the reverse value is printed with a + at the beginning.
Field Width Specifies the minimum width of the field. If converted value has
fewer characters than the field width, output is padded on the left (or
right, if the left-adjustment indicator has been given) to make up the
field width. If the field width begins with a zero, zero-padding is
used; if not, blank padding is used.
. (period) Separates the field width from the next digit string. The decimal
point counts as one space in the output.
Precision Specifies maximum number of characters printed from a string or
number of digits printed to the right of the decimal point of a float
or double.
l (letter ell) Specifies that the corresponding data item is long rather than int.
Conversion A character that indicates type of conversion to be applied (see
Character table 16-2).
1. If used, modifiers must appear in the order listed in this table.
Field Width
Most conversion modifiers affect field width. To better understand how these modifiers
change field width, you must look at the parts of the conversion format. For example:
precision
% .
precision = 5
field width = 16
In no case does a nonexistent or small field width cause truncation of a field. Padding takes
place only if the specified field width exceeds the actual width.
To produce output formatted the way you want it, and to get the most out of printf(), be
sure to use a sufficiently large field width. You cannot, however, print fields of more than
128 characters.
For example, using:
printf("%9d %9d %9d\n", val1, val2, val3);
produces:
12 234 1222
4 5 23
22334 2322 10001
putchar()
The putchar() function puts a single character to the terminal. putchar() always takes an
argument. You must place the character you want printed between the parentheses. This
argument can be a single character, a variable, or a function whose value is a single
character. The syntax is
putchar('s');
putchar('\n');
putchar('345');
putchar(getchar());
NOTE
Single quotes (') are used for character constants.
getchar()
getchar() gets one character from the keyboard. It has no argument. The syntax is:
var = getchar()
Since getchar() has no argument, it simply gets the next character and gives itself the
value of that character. For example:
char ch;
ch = getchar();
putchar(ch);
scanf()
scanf() takes characters and numerical values from the keyboard (standard input),
interprets those characters and numerical values using conversion specification, and stores
the results in its variables.
Like printf(), scanf() uses a control string followed by a list of variables. However, each
variable must be a pointer, indicating where the converted input is to be stored. The syntax
is:
scanf("control string", var, var,...);
When using scanf() with numeric values, always precede the variable name with an &
character. (See “Data Types and Constants” on page 13-11.) To read in a value for a string
variable, do not use an &. For example:
scanf(input, "%d", &value);
The control string can contain:
• “White space” characters (blanks, tabs, or newlines), which are ignored.
• Ordinary characters (except %) that must match the next nonwhite space character of
the input stream.
• Conversion specifications used to direct interpretation and conversion of the input field.
As with printf(), the conversion specification begins with the % character and ends with a
conversion character and a number that specifies field width.
An input field is defined as a string of nonwhite space characters. It extends to the next white
space character, or until the field width, if specified, is exhausted. scanf() uses white space
when dividing input into separate fields. Consecutive conversion specifications are matched
with consecutive fields, leaving white space in between. The only exception to this is %c,
which reads the next character, even if it is white space.
Table 16-4 lists conversion characters used with scanf(). The conversion characters d, o,
and x can be capitalized or preceded by l (the letter ell) to indicate that a pointer to long
rather than to int is in the argument list. Similarly, the conversion characters e and f can
be capitalized or preceded by l to indicate a pointer to double rather than to float. The
conversion characters d, o, and x can be preceded by h to indicate a pointer to short rather
than to int.
Character Input
%d, %D, %hd A decimal integer is expected; the corresponding variable should
be an integer pointer.
%o, %O, %ho An octal integer is expected; the corresponding variable should be
an integer pointer.
%x, %hx A hexadecimal integer is expected; the corresponding variable
should be an integer pointer.
Character Input
scanf() functions return the number of successfully matched and assigned input items.
This can be used to decide how many input items were found. The constant EOF is returned
at end of input. Note that this is different from 0, which means that no conversion was done;
if conversion was intended, the input must contain an inappropriate character. scanf()
does not provide a way to convert a number in any arbitrary base (decimal, hex, or octal)
based on the traditional C conventions (leading 0 or 0x).
fopen()
fopen() opens a specified file, associates a stream with it, and returns a pointer to be used
to identify the stream in subsequent operations. The syntax is:
fopen(filename, type);
To use fopen(), you must assign a type designation that describes the use to be made of
the file. This type designation is a character string having one of the following values:
r Open for reading.
w Create for writing.
a Append: open for writing at end of file, or create for writing.
fopen() returns the pointer NULL if the filename cannot be accessed.
fclose()
fclose() empties any buffers for the named stream and closes the file. Buffers allocated
by the standard input/output system are freed. fclose() is normally used to close a file
being written to. The syntax is:
fclose(stream); Terminal
stream
File
An example that illustrates the use of fopen() and fclose() is as follows:
/* This function opens a file, reads the first line, prints it,
and closes the file.*/
prline()
{
char input_buffer[80]; /* buffer for storing characters read in */
char filename[256]; /* put the name of the file to open here */
FILE *fp; /* file pointer */
/* Open the file, storing the result of the "fopen()" call in the file
descriptor 'fp'. If the open fails, print a warning and return. */
strcpy(filename, "myfile");
fp = fopen(filename,"r"); /* first param is filename */
/* second param is "r" for read only mode */
if (fp == NULL) {
printf("I can't open the file %s.\n", filename);
return;
}
fprintf()
fprintf() puts output to a file. The syntax is:
fprintf(pointer, "control string", var, var,...);
This function is identical to printf() but requires an additional variable. This variable is a
pointer to a file and must be the first variable in your variable list. For example:
/* Print some values at the terminal and also print the same text
into a file. Assume the file has already been opened for
writing and the descriptor for the file is named "outfp". */
scanf()
fscanf() gets output from a file. The syntax is:
fscanf(pointer, "control string", var, var,...);
This function is identical to scanf() but requires an additional variable. This variable is a
pointer to a file and must be the first variable in your variable list. For example:
/* Read two floating point numbers and an integer from a file. The first
line of the file looks something like "0.1 10.0 44". Assume the file is
already opened for reading, and the descriptor for the file is named
"outfp". */
int loop;
char outstring[256];
strcpy(outstring, "This is a string.");
for (loop = 0; /* start the loop at 0 */
outstring[loop] != '\0';/* run until a null character */
loop++) { /* increment loop after every iteration */
fputc(outstring[loop], /* put the current character */
outfp); /* to the file using function fputc */
putc(outstring[loop], /* put the current character */
stdout); /* to the terminal using macro putc */
}
/* Send "newline" characters to get carriage-return linefeed. */
putc('\n', outfp);
fputc('\n', stdout);
getc(stream);
KEYBOARD
stream
FILE
int loop;
char instring[256];
loop = 0;
instring[loop] = getc(stdin);
while(instring[loop] != '\n' && instring[loop] != EOF)
{
if (instring[loop] == '.')/* Convert the character if necessary. */
instring[loop] = '_';
loop++; /*Increment count and get another character.*/
instring[loop] = getc(stdin);
}
instring[loop] = '\0'; /* terminate string, just to be sure */
printf("%s\n", instring); /* print the string, for good measure */
If getc() encounters the end of the file being read, or if an error occurs, such as trying to
read from a file that was not opened for reading by fopen(), getc() returns the constant
EOF.
A variation, fgetc(), works like getc(). It can be used to save object text. The syntax is:
fgetc(stream)
NOTE
A carriage return is not a legal character.
sprintf()
sprintf() places output in a specified character string. The syntax is:
sprintf(string, "control string", var, var,...);
An example using the sprintf() function is:
/* Create a string containing selected information using the function
sprintf(), then print it out with printf(). */
char operator[80];
char mystring[256];
extern int tl_lotnum;
strcpy(operator, "Fred");
sprintf(mystring, "Operator: %s Lot number: %d", operator, tl_lotnum);
printf("%s\n", mystring);
sprintf() formats variables as printf() does but places the result in string. Therefore,
be sure that string is big enough to receive the result.
If you are using Solaris 2, be aware that operation of sprintf() is different. Under Solaris
2, this function returns the number of characters transmitted. When switching between
platforms, be careful that functions written using sprintf() still work as intended.
Function Description
fflush()
When using printf(), the \n put at the end of the string flushes the stdio buffer, causing
the string to appear at the terminal and moves the cursor to the next line. The fflush()
function flushes the stdio buffer used by printf() without requiring a \n in the string.
This allows you to put a string to the terminal without a carriage return at the end, leaving
the cursor on the same line as the string. You can use this to prompt the user and accept
the user’s input on the same line as the prompt.
The syntax is:
fflush(stdout);
You might use fflush() in the following way:
printf("prompt string:"); /*Stores string in the stdout buffer.*/
fflush(stdout) /*Flushes buffer contents to terminal,
retaining cursor at end of the string.*/
scanf(); /*Receives keyboard input.*/
There is no \n inside the printf parentheses since you do not want a carriage return.
Another function of fflush is to put strings to the terminal at the exact time you want them
to appear. This is sometimes useful because IMAGE test programs run in a high priority
mode under UNIX/Solaris. This mode eliminates interrupts and may delay the appearance
of printf strings. Use fflush after a printf statement to ensure that the string appears
where you want it.
fflush, however, resets nowait if it is set. In such cases use the function
tl_fflush_nowait(). This function does not reset nowait. It is particularly useful in loops
waiting for a character strike. An example would be:
int count=0;
tl_read_enable_nowait();
while (!tl_read_char_nowait())
{
printf("count is %d\r", ++count);
tl_fflush_nowait(stdout);
wait 1;
}
tl_read_disable_nowait();
tl_read_char()
The tl_read_char() function allows you to get a single character from the keyboard
without echoing it to the screen or requiring a carriage return to be typed after the character.
It can be used for “type any number to continue” routines. The syntax is:
tl_read_char();
You might use tl_read_char() in the following way:
char ch;
printf("type a letter ==>\n");
ch = tl_read_char();
}
tl_read_disable_nowait();
NOTE
tl_read_char_nowait can cause a problem during debugging. If you are stopped in a trap
and use the step command to step into this function, you will lose IMAGE and have to
reboot.
17 MULTISITE TESTING
IMAGE supports testing of several identical devices in multiple sites on a single test head.
Multisite testing of devices increases throughput by testing two or more devices
simultaneously1. Multisite testing can be used with test head multiplexing to mask the
handler or prober indexing time on testers with more than one test head. A single test
program is loaded in a station used for multisite testing. This program then controls the
testing of all devices being tested at all sites.
This section includes the following topics:
• “Multisite Testing in IMAGE” on page 17-2
• “Multisite Test Pinmap” on page 17-3
• “Channel Assignments in a Pinmap” on page 17-5
• “Sequencer Functions and Binning” on page 17-6
• “Test Functions” on page 17-8
• “Global Variables in Multisite Test Programs” on page 17-17
• “Site Selection” on page 17-19
• “Loading a Multisite Test Program” on page 17-20
• “Manipulating Sites in a Test Program” on page 17-21
• “Assigning and Accessing Bin Numbers” on page 17-27
• “System Variables” on page 17-28
• “Digital Signal Processing” on page 17-29
1. See also “Parallel Test on A500 Family Test Systems” on page G7-1.
Each site has separate dc_matrix pins, as shown by pin 131 "SCO_A". Each site has
separate PLFDIG pins, as shown by pin 231 "PLFD_1". Analog instruments are typically
assigned on a per site basis. However, if a singular instrument must be shared between
both sites, such as the HFDIG in the above examples, then only declare one instrument in
your pinmap, as in pin 405 "HFDGHI".
Each site must have its own power supply (device pin 5).
You can declare thadsmux resources in a multisite pinmap and can place various resources
behind those pins (device pins 44 and 344).
NOTE
This section does not apply to Catalyst test systems.
Analog channels can be assigned to device pins and sites in a pinmap without restrictions.
Assign digital channels into which patterns are loaded according to the following set of rules:
• Group digital tester channels in groups of eight, as in: 1-8, 9-16, and 17-24.
• Assign all channels in a group to one site. For example, do not assign channel 1 to site
0 and channel 8 to site 1.
• After assigning a group of eight tester channels to eight device pins on site 0, assign
other groups of eight channels each to each of the other sites in the same order. For
example, if on site 0 channels 1 to 8 are assigned to device pins 1 to 8 in that order, site
1 may have channels 9 to 16 assigned to device pins 1 to 8 in that order. But do not
assign channel 9 to pin 1 and then channel 16 to pin 2. Use the same ordering on each
site.
In the A580 pinmap example in “Multisite Test Pinmap” on page 17-3, digital channel
assignments follow these rules. These rules need not be followed for digital channels into
which patterns will not be loaded (for example, channels connected to a digital signal
capture memory). This is the so-called “Mod-8” rule, and the compiler checks the digital
channel assignments and issues an error if the rules are not followed.
Do not use the goto statement in a multisite test program, especially not as a fail or pass
action. This is because after one device fails execution should not be altered for the still
active devices.
Test Functions
Test functions are called from sequencer functions by sequencer statements. A test function
contains the statements necessary to set up the tester hardware or to take measurements.
In a multisite test program, a test function is called only once to test all the active sites.
A test function includes one or more test statements to determine pass or fail. A separate
pass or fail must be determined for each device. A serial block is used to specify a separate
result for each device.
In this example the supplies are programmed in parallel, but the meter is sequentially
connected to each device and read. The test statement must be used inside a serial block.
The test statement accepts the test result which in this example is the result returned by the
read_meter statement.
If two devices are being tested in the above example, the first statement sets the voltage on
each supply to 5.2V. Then the meter is connected to the supply for the first device, read,
and the result compared to the limits specified in the sequencer function. Then the meter is
connected to the supply for the second device, read again, and the result for the second
device is compared to the same limits in the sequencer function.
Serial blocks are generally used in test functions or in lower level functions called from test
functions. They are usually not used in sequencer functions.
The code in a serial block is executed once for each active site. If running in stop on fail
mode (the default) the code is not executed for any sites that have failed.
In some cases, devices at all sites can be driven from a single signal source. For example,
it may be necessary to drive all devices from a single ac source. Isolating buffers are
generally required on the DIB to avoid device interference. You can specify a shared
resource of this type in the pinmap. The instrument statements used to program the device
pin to which this ac source is connected then know that only one tester channel is used for
all devices instead of a separate channel per device.
The following additional serial blocks are available:
serial_sleep { ... }
serial_disabled { ... }
serial_all { ... }
serial_failed_sequencer { ... }
serial_max_sites { ... }
For information on these serial blocks, see “Serial Blocks Used in Site Manipulation” on
page 17-24.
by the compiler at the load hsd pattern statement if the load hsd pattern statement
does not specify no_parallel.
The compiler can only check the Mod 8 rules if a pinmap is used. That is, you can get around
this restriction by putting the load statement in a file that does not include the pinmap.
Having a parallel pattern that does not follow the Mod 8 rule can cause problems that are
difficult to find. To ensure that these problems do not occur, another Mod 8 rule check is
performed at run time for patterns that do not specify no_parallel.
PATTERN2
CLOCK DATA3
0 H
SVM & LVM Memory
1 L
. .
As explained in the previous section, parallel patterns are written for site 0, and IMAGE
automatically duplicates them across the multiple sites. Patterns defined as no_parallel
are not duplicated by IMAGE. Then how are the match mode patterns executed on the other
sites? Multisite test patterns without no_parallel set must be written in a certain way. You
must duplicate the site 0 match mode pattern for each site. You must also create new
patterns to keep the initialized devices in the desired state while the next site is being
initialized.
When duplicating a pattern use the following procedure:
1. Create one pattern that is the site 0 pattern size times the number of sites.
2. Start the site 0 pattern at virtual address 0 and continue for site 0 pattern size.
3. Set sites 1-n channels to x. At this time, site 0 has been initialized.
4. Write vectors to keep site 0 in the initialized state and to pad the remaining vectors in
this pattern. At this time, site 1 pattern starts at site 0 pattern size plus 1 and continues
for site 0 pattern size.
5. Set sites 2-n channels to x. Now site 2 is initialized.
6. Write vectors to keep site initialized. Note that these may or may not be the same as site
0 vectors. This varies from device type to device type.
7. Keep repeating the above steps until all sites are initialized.
The pattern resulting from this process includes n copies of the site 0 initialization pattern
with each pattern residing in unique pattern address space. This allows each vector to
sequence freely. You must keep a site that was previously initialized in the initialized state
while initializing the other sites. You must also keep all sites in the initialized state when
moving from the match mode pattern to the parallel pattern.
In some cases, however, this delay is prohibitive. In these cases, you can jump from the
match mode pattern to the parallel pattern. The limitation is that the simulator and the history
RAM cannot deal with patterns in the same burst that have different pin lists.
Another variation on this technique is to use only no_parallel patterns throughout your
test program. In this case, you are responsible for duplicating the channel data across all
sites. IMAGE, however, still interprets the results at runtime. Even though a pattern may be
loaded using no_parallel, the test statement still tests the results on a per site basis. This
allows you to develop the patterns as desired without losing the benefits of having a multisite
test program.
The last vector in a no_parallel pattern should verify that the device is still in the desired
state (see VERIFY in figure 17-2). Any site failing this vector implies that the device did not
hold its initialized state. This failure mechanism is useful for binning, but even more useful
for developing these vectors and debugging them. Figure 17-2 shows a no_parallel
pattern.
pinmap (3 sites) =
{ Site 0 Site 1 Site 2
SEQ
1 clock drv:(1, 9, 17), 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
CLOCK DATA3
0 H
1 L
. .
Any digital pin using a dig_src or dig_cap instrument must define a list of channels needed
for multisite testing in the pinmap. It must also specify the list of dig_src and dig_cap
instruments needed for each channel. This information is used by the compiler to create pin
lists for the hardware setup routines of instruments and digital channels and by the loader
to see if microcode needs to be duplicated.
from the current site. This consideration implies that any pattern used in this fashion should
be self initializing. That is, the pattern should not make any assumption about the state of
the device at pattern start. Also no other pattern should depend on the state of the device
at the end of this pattern since that can not be guaranteed either.
Testing Restrictions
Observe the following restrictions when doing multisite testing on an Catalyst tester:
• Conditional branching on a per site basis is not allowed in a parallel pattern. That is,
“match mode” vectors usually apply to a specific condition on a site. Thus, the condition
coming true on any site alters the execution on all sites.
• Digital pattern load statements appearing inside a serial loop cause the pattern to be
loaded on the first pass through the loop. All subsequent passes do nothing.
• Jumps between no_parallel patterns and parallel patterns are not recommended.
• All channels in a single DMF cage that use dig_srcs are restricted to using the
dig_srcs in the same cage.
• Channels from different DMF cages that use dig_cap cannot be connected to the same
slice.
• You can load patterns into either site 0 or all sites. You cannot select any other sites for
pattern loads.
• Parallel test patterns must be run with ignore-halt-on-fail set. Without this flag set,
a failure on one site can cause the pattern to halt prematurely, possibly passing bad
devices on other sites which could have failed had the pattern continued.
serial {
...
offset = read_meter(); /* Determine offset for one device */
save ddata = offset; /* Save the offset */
}
...
serial {
...
retrieve ddata = offset; /* Retrieve the offset for one site */
test read_meter() - offset; /* Use the offset in a calculation */
}
Retrieve Functions
Two functions are available for retrieving an integer or double value directly without first
writing it into the variable:
tl_retrieve_i("<integer_variable_name>");
tl_retrieve_d("<double_variable_name>");
The last serial block in the example above can alternatively be written as:
serial {
...
test read_meter() - tl_retrieve_d("offset");
}
NOTE
In save and retrieve statements the variable names do not use quotes. The tl_retrieve
functions in the preceding example, however, require quotes around the variable name.
These functions are useful for getting a value in a calculation. They can be used outside a
serial block as part of a set statement as shown in this example:
set acsrc: audio1
freq= 4khz
amp= tl_retrieve_d("gain") * 0.5
set acsrc: output1
offset= tl_retrieve_d("dc_offset");
A different value of gain and dc_offset will be used in calculating the amplitude and DC
base for each low frequency source.
Site Selection
Executing the run command by default causes testing on all the sites supported by the test
program. You can change this default using the sites command which has the following
syntax:
sites [# # ... | -all] [-debug #] [-station #] [-auto on | off]
where:
sites # Enable a site or sites for test program execution. Enter the
command with one or more numbers (0–3) to enable specific
sites. Default is site 0. For example, the following command
enables sites 0, 2, and 3:
sites 0 2 3
run commands will now test devices on these sites only.
Table 17-1. Moving Sites Between Enabled, Sleeping, and Disabled (Continued)
Action set
sleep_mode:
Test Bin
Test Result Bin Result
Mode Specifier
off;
on;
(default)
Note that with sleep_mode on, a failing test causes a site to be put to sleep independent of
the test mode. Note also that even if no fail bin number is specified on the sequencer for a
test, if the test fails and sleep_mode is on, the site is put to sleep. This behavior differs from
the default behavior where a device is not disabled if neither a fail bin number nor close
binning is specified.
serial_sleep { ... }
Do for each sleeping site. For information regarding the sleep
state, see “Using the Sleep State” on page 17-21.
serial_disabled { ... }
Do for each disabled site.
serial_all { ... } Do for each site, regardless of the state.
serial_failed_sequencer { ... }
Do for each site that failed the last sequencer. This provides a
convenient way of determining which sites failed a sequencer.
This can be used after returning from a sequencer to perform an
operation on each site that failed the sequencer. The code in the
serial block is executed once for each failed site. If used inside a
sequencer, the code in the serial block is executed once for each
site that has failed that sequencer so far.
serial_max_sites { ... }
Do for each site supported by the test program. Normally, you
use serial_all instead of serial_max_sites. Both types of
serial blocks behave identically if all sites supported by a test
program are used. They behave differently if a program is run
using only a subset of the sites specified in the pinmap. This is
the case if the -sites option is specified when the program is
loaded, if the -sitemask option is used when the program is run,
or if the start command issued from a handler or prober
specifies not running all sites. In these cases, serial_all goes
through only the sites used for that run, but serial_max_sites
goes through all the sites supported by the test program as
specified in the pinmap.
When you use serial_max_sites you cannot datalog to the
sites that were not enabled at the start of the test program run.
Only use serial_max_sites in special circumstances, such as
performing spot calibration on all sites during the execution of a
test program.
Inside each serial block, read_current_site() can be used to determine which site is
being tested during a pass through the serial block. For more information on serial blocks,
see “Shared Tester Resources in Serial Blocks” on page 17-8.
For example, you have a four site program. In this program sites 1 and 2 are enabled and
sites 0 and 3 are disabled. The site mask of all the enabled sites would contain 0...0110
in binary or 0x6 in hexadecimal.
The following functions allow you to obtain site masks for all the sites in the enabled,
disabled, or sleep state:
read_sitemask_enabled();
Returns a site mask for all enabled sites.
read_sitemask_disabled();
Returns a site mask for all disabled sites.
read_sitemask_sleep();
Returns a site mask for all sleeping sites.
read_sitemask_all();
Returns a site mask for all sites being tested. This is the
equivalent of ORing the 3 first site masks.
In addition, the following function obtains a site mask for all sites that failed the last
sequencer:
read_sitemask_failed_sequencer();
Returns a site mask of all sites failing a sequencer. If called from
within a sequencer, the site mask returned identifies the sites
that failed that sequencer so far.
NOTE
A sort bin statement (without the equal sign) is usually not used in a serial block, although
it is legal to do so. It is usually used to bin all devices at once.
System Variables
The function read_current_site() is available inside a serial block to determine which
site is being tested during a pass through the serial block. You usually do not need to know
this. This function may be called, however, if you must take different actions based on the
site or index an array based on the site number. The function returns the site being tested
on this pass through the serial block. For example:
serial {
switch (read_current_site()) {
case 0: /* Do this for site 0 */ break;
case 1: /* Do this for site 1 */ break;
default:/* Do this for other sites */ break;
}
}
Calling this function outside of a serial block has no meaning, and it will return a negative
number.
Alternatively, for backwards compatibility, you can access the system variable tl_site
directly. This variable is normally set to the site being tested on a pass through the serial
block. However, in some cases, such as after a failing test statement, it is set to a negative
value. Use read_current_site() instead of accessing tl_site directly.
You can call tl_site_active() to determine if a site or any sites are still active. The
function returns TRUE if the site is active or FALSE if it is not. Inside a serial block it returns
TRUE if the site tested on this pass through the serial block is still active. It returns FALSE if
the device has been disabled (failed). Outside a serial block the function returns TRUE if any
devices are still active. It returns FALSE if all devices have failed.
Example (in a sequencer function):
seq test1() > 10.0ma < 15.0ma f(2);
if (tl_site_active()) printf("About to call test2\n");
seq test2() > 4.8v < 5.2v f(3);
The message About to call test2 is printed only if at least one device is still being
tested.
In this example, data is captured in parallel on all devices. This is the time consuming part
of the test. Then the data is analyzed separately for each device by moving the data for one
device into the array processor. The function analyze_spec performs the actual analysis in
the array processor and returns a value. analyze_spec is written to process the data from
only one device. The value returned from the function is passed to the test statement for
comparison against the test limits in the calling sequencer statement.
Digital Signal Processing (DSP) for mixed-signal device testing is a key capability of the
Tiger, Catalyst, and A5xx PowerPort test systems.
DSP-based test methods use waveform synthesizers and digitizers, instead of analog
source and measurement instruments, to stimulate and measure devices. With DSP-based
testing, analog hardware instrument functions are replaced by algorithms executing on
computers. One major advantage is reduced test time. A significant cost has been the time
and expertise needed to develop DSP-based test programs.
DSP-capable systems have an architecture that supports high throughput DSP-based
testing. Test language features, in particular a feature set named FlexDSP, are designed to
simplify test program development and reduce the programming effort and expertise
needed.
This section includes the following topics:
• “Basic Features and Specifications” on page 18-2
• “Background: DSP-based Testing” on page 18-3
• “DSP-enhanced Tester Architecture” on page 18-6
• “Overview of FlexDSP” on page 18-7
• “Output Parameter for Capture Instruments” on page 18-10
• “Data Arrays” on page 18-12
• “Compute Blocks” on page 18-16
• “Signal Processing Operations on Data Arrays” on page 18-21
• “Other Operations on Data Arrays” on page 18-22
• “Programming With FlexDSP” on page 18-23
• “Running and Debugging FlexDSP Programs” on page 18-30
• “FlexDSP Operation” on page 18-31
• “Creating Custom Block Algorithms” on page 18-32
S Measurement
S e
t t M T
Instrument a t Device response/ o e
r l v Compute s
setup data capture
••• t e e t •••
In the simplest case, each of the measurement tasks are executed serially, that is, in
sequence, one after another. The whole sequence is repeated for each test. Since the test
computer is idle during data capture and the DUT is idle during computations, this simple
approach is inefficient, especially in a program with many tests.
Pipelining
During a series of measurements, data captures can be programmed to overlap with
computations. This technique is known as “pipelining.” Pipelining speeds up execution by
reducing the time the test computer and the DUT are idle.
The term pipeline is used to describe a program structure that allows two or more
sequences of tasks to be overlapped and synchronized with each other. An overlapped
sequence is a “pipeline.” See figure 18-2.
Programs that incorporate pipelines are complex. Expertise is required to write and debug
programs using pipelines.
Multisite Testing
A test “site” is a location on the device interface (test fixture) for one device under test.
Multisite testing occurs when the separate devices at multiple sites are stimulated
simultaneously so they can all respond at the same time, in parallel. See figure 18-3.
Source Site 1
Capture
Site 2
Capture
Source Site 3
Capture Site 4
Capture
Device Interface
Tester Instruments (Fixture)
Capability for parallel measurement depends on the test system architecture, the instrument
resources and test programming features available.
For more information, see “Multisite Testing” on page 17-1.
High-Speed
Digital
DSP-Capable Test Computer
Subsystem
Bus I/F
Control
CPU 1 Source
Data1
Data2 Capture
CPU 2*
Data3 Device
Precision Source Under
Data4
AC Test
Data Subsystem Capture
Busses
Source
Capture
²
²
²
* Note: CPU 2 is optional
Overview of FlexDSP
ITL for Tiger, Catalyst, and A5xx with PowerPort has a set of programming features called
FlexDSP, designed to simplify writing DSP-based test programs and allow you to take
advantage of the DSP-enhanced architecture.
At a high level, to develop a high throughput DSP-based test program, you must:
1. Write and debug code to perform the computations on the captured data that are
required by your test method.
2. Create threads and control their execution on one or, optionally two, test computer
processors.
3. Manage testing and test result processing of multiple device sites.
FlexDSP provides features to support these tasks:
• Three C language extensions as part of ITL:
– Compute block - A statement that identifies code that can be autopipelined:
automatically pipelined and executed in parallel, for all measurements and device
sites. Compute blocks are the programming interface for autopipelining. Test result
processing is managed for all test sites.
– DARRAY - A variable type referring to an internal structure, called a data array, that
manages the data used by code that is automatically pipelined and executed in
parallel, inside a compute block.
– Capture instrument output parameter - A parameter in the set statement for
capture instruments that allows automatic background movement of the captured
data into a data array for processing inside a compute block.
• A library of measurement routines - These functions, called block algorithms, return
values for common device measurements. The routines are called block algorithms
because each one replaces a sequence of basic, lower level vector processor
operations. In the C language, “block” is another term for compound statement. Block
algorithms are the “compound statements” of DSP.
• A library of “thread-safe” basic DSP algorithms, similar to A5 algorithms. These basic
routines can be used for data analysis requirements not met by the library of block
algorithms.
The DSP architecture does not include special digital signal processor hardware. Because
of this, there are no special syntax or data buffers corresponding to the signal processor
instrument. DSP computations are programmed using function calls on variables you
declare as a special type (DARRAY), described below.
The captured data flow through the FlexDSP feature set is shown in figure 18-5.
Figure 18-5. Captured Data Flow Through the FlexDSP Feature Set
When used in a multisite program, multiple capture instruments can capture multiple
responses of a single device, or multiple device responses, and the sample data for each
response is analyzed separately. IMAGE manages the separate processing of test results
for all devices.
FlexDSP does not support programming threads explicitly using low level calls to the
operating system. All thread programming is done at a high level using compute blocks.
An ITL programming example using FlexDSP features is in figure 18-6.
TESTF example()
{ • DARRAY - Data will be
DARRAY cap_samples=DA_NULL;
managed by IMAGE
set pin= AOUT plfdig: output= &cap_samples
enable_capture;
da_set_Fs(cap_samples, 64.0e3);
start pin= AOUT plfdig; • output parameter - data
will be automatically
compute(cap_samples)
moved in the background
DARRAY cap_samples;
{
DARRAY real_samples= DA_NULL;
DARRAY fft_freq= DA_NULL; • Compute block - Data
DARRAY power_spec= DA_NULL; moves and computations
double fund, harm3, power_ratio; will be automatically
pipelined, in parallel
real_samples=da_frac_to_real(cap_samples);
fft_freq=da_fftb(real_samples);
power_spec=da_power_spectrum(fft_freq, DA_REAL);
fund= da_amplitude(power_spec, 1.0k);
harm3= da_amplitude(power_spec, 3.0k);
power_ratio= da_dB(harm3/fund);
• Block algorithms -
test fund;
test oriented
test harm3;
test power_ratio; analysis functions
}
}
NOTE
You must specify the value of the data array address for the output parameter using the
operator &.
Descriptions of other capture instrument syntax related to data movement, such as vector
size and data type, and procedures for use, are contained in the individual capture
instrument sections. See “Supported Capture Instruments” on page 18-11.
If you use the output parameter to assign a destination data array and do not operate on
the data array inside a compute block, the parameter and the data array are ignored during
execution.
For more information on using the output parameter, see “Programming an Automatic
Background Move” on page 18-23.
Data Arrays
A data array is an IMAGE structure that holds sample data from a capture instrument for up
to eight test sites, plus other site-independent data. In addition you can use as many data
arrays as you need for data processing. The data array allows IMAGE to manage the
sample data during parallel execution of autopipelined data moves and computations inside
compute blocks.
Type DARRAY
To refer to the data in a data array, you must declare and use a variable of type DARRAY.
The DARRAY type is a C extension within ITL.
The syntax for the DARRAY declaration is:
DARRAY <data_array_name> = DA_NULL;
where:
<data_array_name> Is the variable name you choose to declare for the data array.
that contains the data and the DARRAY is the type of the variable used to refer to the data
array.
In addition, the term handle is sometimes used to refer to variables of type DARRAY.
In summary, functions that operate on data arrays may specify inputs as one of:
• The data array name
• The data array handle
• The DARRAY name
• The DARRAY handle
Sample Data
Sample data from a capture instrument is the primary content of a data array. The data array
structure allows IMAGE to multiplex and demultiplex the sample data for individual sites,
maintaining a separate sample data set for each site.
Attribute Data
In addition to sample data, the data array also contains information about (attributes of) the
sample data. The values of the attributes are common to all test sites.
Information about sample data (attribute data), includes:
• “Data Type” - numeric type of all samples, for all sites
• “Size of Sampled Data” - length of sample data vectors, for all sites
• “Sample Frequency” - sample frequency of data samples, for all sites
• “Test Frequency” - fundamental frequency of data samples, for all sites
• “Lifetime” - time of persistence of a data array and its data in memory
You can read, write and print the attribute data in data arrays. See “Other Operations on
Data Arrays” on page 18-22.
Data Type
FlexDSP supports the following data types:
DA_REAL Single precision floating point
DA_DREAL Double precision floating point
DA_INT 32-bit signed integer
Type Conversion
Block algorithms support automatic data type conversion, or promotion. The conversions
are ordered as shown in figure 18-7. When an operation is performed on data with different
types, all data is converted to the type next higher in the diagram.
For example, if an operation is performed with DA_INT and DA_FRACT2 data, the operands
are converted to DA_REAL.
DA_DCMPLX
DA_CMPLX DA_DREAL
DA_REAL
DA_INT DA_FRACT2
Sample Frequency
The sample frequency is the sampling rate associated with a sample set. If an analysis
function requires it, you must specify the sample frequency since it is not passed from the
capture instrument.
Test Frequency
The test frequency is a frequency specification used by some block algorithms. If the
function requires it, you must specify the sample frequency.
Lifetime
The lifetime of a data array is how long the structure and its data persists in memory. A data
array is a structure with allocated memory.
To conserve allocated memory, IMAGE sets the default lifetime of a data array to be until
the end of the TESTF in which it is declared or defined. You can set the lifetime to be until
the run is completed, or until the test program is unloaded.
Compute Blocks
A compute block is a program construct that identifies code that can be autopipelined
(automatically pipelined and executed in parallel). A compute block is implemented as the
compute statement, a C extension within ITL.
Autopipelined program tasks include data movement, computations on data, and test result
processing for all test sites.
Compute blocks provide a high level mechanism and simple syntax for creating and
controlling parallel threads of execution on one or more test computers. IMAGE does not
support programming threads explicitly using low level calls to the operating system.
Threads are programmed only by using compute blocks.
Syntax for the compute statement is:
compute( <parameter(s)> )
<parameter declaration>;
{
<ITL statement(s)>
}
where:
parameter A sequence of simple expressions used to transfer data into
computations spawned by compute block. The list of
expressions accepted is restricted. See “Syntax Rules” on page
18-17.
parameter declaration
Declarations for the names used in the compute block. Each
parameter must be declared separately. See “Syntax Rules” on
page 18-17.
ITL statement(s) Any sequence of allowable ITL statements. See “Restrictions on
ITL Statements” on page 18-19.
• Guidelines for structuring programs using compute blocks. When you use compute
blocks, you must structure your test program in specific ways to ensure autopipelining
operates correctly and your program structure does not negate the advantages of using
compute blocks. See “IMAGE Program Structure and Compute Blocks” on page 18-26.
• Test result processing and data logging.
• Compute blocks and multisite test. Compute blocks extend IMAGE multi-site (also
referred to as parallel test) capabilities to allow pipelining and parallel processing of data
analysis computations.
Syntax Rules
The following syntax rules apply to the compute statement:
• Expressions that may be passed into a compute block include
– variables of form name
– pointers of form *name
– addresses of form &name
Other expression forms result in compile errors.
• Parameter declarations must be done individually, each as a separate statement.
Examples:
Correct - This will compile:
compute (input1, input2)
int input1; /*CORRECT: Each variable */
int input2; /* declared in separate */
{ /* statement. */
<statements>
}
Scope Rules
An important difference between a compute block and a C function is the scope of variables.
The scope of a variable determines where a variable is available to be used. A compute
block appears to be the same as a function, but the implementation of the compute block
makes it behave differently from a function. For implementation details, see “How the ITL
Compiler Processes a Compute Block” on page 18-31.
For a variable to be available for use in a compute block, it must be one of the following:
• Global to the function (often a TESTF) that includes the compute block
• Local within the compute block
A compute block cannot reference a variable in the surrounding TESTF (or other function
which contains it). Surrounding variables must be passed in as parameters.
See examples in figure 18-8.
Incorrect: Correct:
Variable from surrounding scope Variable from surrounding scope
used in compute block. passed into compute block before use.
compute() compute(var_in_scope_t2)
{ int var_in_scope_t2;
int result = var_in_t1_scope {
} int result = var_in_t2_scope;
} /* end of t1 */ }
} /* end of t2 */
Compile error:
undefined symbol: var_in_tl_scope
The following statement category is allowed, because it will not create a compiler or runtime
error, but is not recommended:
• Statements that write to shared data between compute blocks
Threads are independent and contend for execution: it is impossible to control or predict
the order of execution. If multiple threads are executing and writing to shared data, it is
very likely the data will be corrupted.
Although you can read shared data in compute blocks, do so only if you know the data
is not going to change value while the compute block is executing.
You cannot move compute blocks containing shared resources (see “Shared Resources
in Parallel Patterns” on page 17-15).
Data arrays are “thread safe.” That is, captured data is completely managed for
automatic background moves, computations using da_ DSP routines, and test result
processing in SEQUENCER statements.
Block Algorithms
Block algorithms are used to analyze sample data. They are high-level, test and
measurement functions that replace sequences of basic algorithms. For detailed
information on writing custom block algorithms, see “Creating Custom Block Algorithms” on
page 18-32.
For example, da_snr computes the signal-to-noise ratio of a sample data set.
Utility Functions
Utility functions provide simple operations on samples and block algorithm results.
For example, da_amplitude returns the amplitude (magnitude) of a frequency in a
spectrum.
Basic Algorithms
Basic vector operations are also used to analyze sample data. The operations are similar
to the A5 DSP algorithms, but usable (thread-safe) in the FlexDSP environment.
Reading Data
• Get the location of the sample data
• Get the type of the sample data
• Get the size allocated for sample data
• Get the sample frequency
• Get the test frequency
Writing Data
• Set the sample frequency
• Set the test frequency
• Set the lifetime of the data array
Printing Data
For debugging purposes, you may want to print out the contents of a data array:
• Print the contents of the data array
• An array
• A DARRAY
When a DARRAY is the destination and the DARRAY handle is invalid, the move statement
automatically creates a new DARRAY. For example:
DARRAY DA_filedata = DA_NULL;
move
file = "datafile"
size = 1024
to:
data_array = DA_filedata;
This creates a handle DA_filedata to a DARRAY which contains 1024 elements from
datafile.
When a DARRAY is the destination and the DARRAY handle refers to a valid DARRAY, the data
is converted from the source data type to the DARRAY’s data type as necessary. For
example, assume that the file fract2.data contains 1024 elements of type DA_FRACT2.
The following move statement will convert the data from DA_FRACT2 to DA_REAL and store it
in DA_realdata:
DARRAY DA_realdata = da_define(DA_NULL, DA_REAL, 1024);
move
file = "frac2.data"
size = 1024
to:
DA_realdata;
Table 18-1 shows legal data movement as a function of data type when moving data from a
DARRAY.
Fract2 m c m c c
Integer m c m m c
Real c m c m c m c
Double c m m c m
Complex m c m m c
Double c m m c m
Complex
Table 18-2 shows legal data movement as a function of data type when moving to a DARRAY
from any source, provided that the source supports the given data type. For example, a CPU
source cannot be type Fract2.
To DARRAY
Data Type
F I R D C DC
Fract2 m c c
Integer m c
Real c c m c
Double c c m
Complex m c
Double Complex c m
Column labels are: F= fract2, I= integer, R= real, D= double, C= complex, DC= double
complex.
m indicates a data move only (no conversion is performed).
• A company may have a standard for modular programming that specifies how many
sequencer statements are in a SEQUENCER function.
• A test developer may program pipelines for reduced test time.
There are many other reasons for particular program structures.
Compute blocks and the operation of threaded programs restrict the ways that programs
can be structured. These restrictions interact with the program structures listed above, and
many others not listed.
For ITL programs using compute blocks to operate efficiently, programs need to be
structured in the recommended way. Some programming styles and techniques are
incompatible with compute block operations and should be avoided.
Use this function with caution. If the main thread of execution could have continued,
synchronization defeats parallel execution.
Generally, programs with the recommended structure do not need additional calls to the
synchronization function.
A diagram of the recommended ITL program structure for programs using compute blocks
is in figure 18-9.
main()
{
<call sequencer function> Use minimum number of
} sequencers (1 is ideal) for all
test functions with compute
blocks
Sequencer Function
SEQUENCER<name of sequencer function>()
{
<sequencer statement> Synchronization Points -
<sequencer statement> Implicit tl_compute_sync
}
Sequencer Statement
• Defines: Test Limits
Datalog Number
Datalog Label
Datalog Format
• Calls test function
• Receives pass or fail result
• Takes pass or fail action
FlexDSP FEATURES
Figure 18-9. Recommended Structure for Test Programs with Compute Blocks
FlexDSP Operation
Creating a DARRAY
New DARRAYs can be created using the function da_define. An example using da_define
is as follows:
DARRAY new_darray;
new_darray = da_define(DA_NULL, DA_REAL, 128);
In this example, new_darray is assigned to a DARRAY handle, which describes the location
of the internals of the new DARRAY. The da_define parameters specify information about
the new DARRAY.
DA_NULL tells IMAGE to allocate a new handle for the new DARRAY. If an existing DARRAY
handle is used in place of DA_NULL, IMAGE reuses the handle for the new DARRAY. In most
cases, DA_NULL is sufficient.
DA_REAL is the datatype of the new DARRAY. It means that new_darray expects to be filled
with values of C type float. Other options for this parameter include the following:
DA_DREAL C type double
DA_INT C type int
DA_CMPLX C type COMPLEX
DA_DCMPLX C type D_COMPLEX
The complex types contain special structures as their elements. See “Use of Complex
Types” for details on handling this data type.
The 128 passed to da_define in the above example tells IMAGE to create a vector big
enough for 128 data points. One vector is created for each site in the test program.
Therefore, an eight site test program with a DARRAY size of 128 has eight vectors, each with
room for 128 data points.
data_size = da_get_size(handle);
data_vector = (double*)da_get_vector(handle);
The task of translation is not completed by accessing the correct information. The final piece
is to package the information in a manner convenient to the computation layer. Most
typically this involves just passing the information as C parameters, as in the following call:
volts_per_second_computation(data_vector, data_size, Fs);
Sometimes, it makes sense to do some preliminary work on the information to make it more
palatable to the computation layer. While this is a stylistic point, it can make a big difference
in the simplicity and reusability of the computation layer. The key question to ask is, from
the computation standpoint, what information is fundamental to finding the right answer? In
this case, it may be natural to ask for the duration in time of the vector, as well as the vector
itself, and the size of the vector, in elements. In that case, the error layer may perform the
following:
double data_duration;
data_duration = data_size / Fs;
volts_per_second_computation(data_vector, data_size, data_duration);
The task of translation is to provide convenience to both the user of the algorithm and the
programmer. By examining key information from both perspectives, the error layer can
provide a simple and convenient interface between those two entities.
One other important task remains for the error layer, finding errors. User data is not always
correct and it is easier to handle errors when they are found up front.
You first need to understand the assumptions being made by the computation layer. Then
you must consider how user data could possibly break those assumptions.
For example, the computation layer may assume that the data_duration will be positive.
A user may break that assumption by passing a zero or a negative value for Fs. A simple
check in the error layer can rule out this possibility, as in:
if (Fs <= 0.0) { /* error code here */ };
Similar checks can be made for other failure conditions on user data. Calls to
da_get_vector(), for instance, will return NULL pointers if they encounter an error
condition. Checking for this NULL condition can save the trouble of debugging a
segmentation violation later on in the development cycle. The documentation on individual
da_get_*() functions (see “FlexDSP Programmer’s Reference” on page 27-1) explains the
error conditions and how they may occur.
Note that graceful error handling can be difficult in a language like ITL or C. Once an error
is detected, you must decide what to do, usually on an individual basis. You can, for
example, print an error to the screen, return a reserved error value, flag a global error
variable, or perform some combination of these. The action taken should allow easy
detection and correction of errors. Any such scheme would be satisfactory.
Computation Layer
The purpose of the computation layer is to produce an answer from the relevant information.
A well-designed computation layer should be able to stand on its own as a logical tool for
doing a given calculation. IMAGE computation layer functions are designed to have minimal
overhead while computing their result. The error handling layer should buffer these
functions from user errors and other conditions that would complicate their implementation.
In other words, the computation layer should get right to the point.
Here is the example computation layer for the voltage average calculation:
double volts_per_second_computation(data_vector,data_size, data_duration)
double *data_vector;
int data_size;
double data_duration;
{ double result;
double total_voltage = 0;
int i;
for (i=0;i<data_size;i++)
total_voltage += data_vector[i];
result = total_voltage / data_duration;
return result; }
Notice how this routine contains nothing not directly related to calculating the final answer.
The error handling layer takes care of the context, while this layer does only the “real” work.
Multithreading Concerns
Typically, a block algorithm is called from inside a compute block in a multithreaded
program. This means that the program must account for the possibility that it will be run
concurrently or in parallel with other algorithms, possibly all accessing the same data. This
section looks at issues arising from multithreading.
The most common error in a multithreaded program is known as a data race condition and
occurs when two or more threads try to access the same piece of data at the same time.
Consider the case of a bank’s computer updating the balance in your savings account. One
thread may be adding 1% interest to your account, while another may be processing a
deposit of $100 you make at an ATM machine at the same time.
Thread 1:
temp = balance;
temp = temp * (1.01);
balance = temp;
Thread 2:
balance = balance + 100;
Assuming an initial balance of $100, you might expect the final balance to be either $201 or
$202, depending on whether the deposit is processed before the interest. However, if the
deposit is processed in the middle of thread 1, it is possible to find a final balance of $101.
Assume thread 1 assigns the variable temp and then multiplies by 1.01 to compute $101.
At the same time, thread 2 updates balance to $200. But, the value of temp is $101, and
then thread 1 finishes by clobbering the changes thread 2 made and writing $101 in the
balance. Your deposit is lost.
You can avoid such a problem by identifying data shared among the different threads
running the algorithm. This global data can take many forms, and it is often hard to identify.
Most generally, whenever two or more threads have a pointer to the same address, the data
at that address is global. Fields of the DARRAY structure are global data, with the exception
of the data vector returned by da_get_vector(), which is site-specific. Any values that the
algorithm accepts by pointer are global data, unless the addresses passed through that
pointer are different for the different sites. Static variables declared in the algorithm are
global data. Global program variables are, of course, global data. Finding all the global data
in such an algorithm is difficult, but those are the most common instances.
Once global data is identified, it must be treated with care. The rules for handling global data
can be boiled down into two cases. If no thread will be modifying the data, no race condition
exists. If any thread will be modifying the data, synchronization techniques must be used.
These techniques are beyond the scope of this section. If possible, try to avoid writing to
global data in any algorithm that will be called from a compute block. If writing to this data
is unavoidable, refer to any multithreading reference for information on synchronization.
Sometimes, it may be your responsibility to manage multithreading concerns. For instance,
an algorithm that returns two values must write to pointers you supply. It would be wrong to
give the same addresses to different sites to supply their return values. It is also possible
that your program may try to manipulate a global variable at the same time as the algorithm.
In such cases, it’s up to you to eliminate any race conditions. You must supply different
output pointers to different sites and wait until the algorithm is finished manipulating global
variables to access that data. Of course, explicitly documenting such pitfalls is the
responsibility of the writer of the algorithm.
The key point to remember about multithreaded programming is to be careful about how you
treat global data. Avoiding race conditions by treating this data with care is a major step in
writing correct multithreaded programs.
19 CHECKERS
IMAGE includes a set of checker software programs designed to verify that the tester
hardware is functioning correctly. The two basic types of checker programs are:
• Self-test
• Maintenance and installation
Self-test checkers are designed to run on the test system without requiring you to remove
your device testing setup. They are the focus of this section.
This section covers the fundamentals of using the IMAGE checker programs, including the
following:
• “Understanding IMAGE Checkers” on page 19-2
• “Overview: Loading and Running IMAGE Checkers” on page 19-5
• “Loading Checkers” on page 19-6
• “Running Checkers” on page 19-12
• “Running Checkers Automatically” on page 19-22
• “Creating Custom Checker Runs” on page 19-34
• “Creating a Static Configuration” on page 19-43
For information on specific IMAGE checkers, see the Checker Description Manual that
corresponds to your tester.
For information on running Device Focussed Checkers, see “Device Focussed Checkers”
on page 20-1.
NOTE
The A500F, A510F, A520F, A530F, A535, A540F, A545, A550F, A555, A560, A565, A570,
and A580 test systems are not supported in IMAGE V8.0. That means V8.0 is not tested on
those systems. While the software may operate properly, Teradyne will not fix bugs in V8.0
that involve those testers only.
Checker Structure
A checker program can include the following functions:
• Initialization—this section (not included in all checkers) allows you to provide
information to set up the checker.
• Brief check—this section of a checker program includes functions to verify as quickly as
possible that the instrument is present and working.
• Full check—this section of a checker program includes additional functions, including
performance and verification tests such as memory checks and high and low speed
tests, to determine the full functionality of the instrument.
The results of each checker run are returned to IMAGE by the values CK_PASS, CK_FAIL, or
CK_INVALID.
Checker Types
Although IMAGE checkers are used to test a wide variety of test system functions, they are
grouped in two broad categories.
Self-test checkers are standalone checker programs that can be run at any time without
additional equipment or test system preparation.
Maintenance and installation checkers include a variety of programs used to test
functionality, for calibration, and other purposes. Some of these programs require external
hardware, such as a device interface board (DIB) or cable. Some maintenance and
installation checkers include an _mi suffix.
Checker Groups
To allow you to load the correct checkers on your tester, checker programs are organized
in groups. Checkers are grouped first by test-head type (advanced mixed signal, and
Catalyst Tiger), and then divided into mainframe and test-head groups. Common tester
hardware is included in a separate group. IMAGE checker groups include the following:
• Common Frame
• Advanced Mixed Frame
• Advanced Mixed Head
•
• Tiger Digital
• Tiger Analog
Grouping IMAGE checkers minimizes memory use by loading only relevant checkers into a
tester. This method also avoids using incompatible syntax in a checker in the wrong test
head.
Location of Checkers
Checker releases occur at the same time as IMAGE releases, and you may have more than
one version of checkers installed. IMAGE loads the version of checkers specified by the
/image/checkers link. To see which version of checkers is loaded, type the following in a
station window:
ls -l /image/checkers
You should see a listing such as:
checkers -> ckr_bin.6.3
In this example, the link is to checkers 6.3, so IMAGE reads the menu files in ckr_bin.6.3
and loads V6.3 checkers.
IMAGE reads the checker menu files from the path specified in the CKRBIN environment
variable. If the environment variable in CKRBIN is not set, IMAGE looks in /image/checkers
for the link and reads that menu file. You can set the CKRBIN environment variable to a
checker version by typing the following command in a station window before clicking on the
CHECKERS button:
NOTE
IMAGE V4.3 and later does not work with older versions of checkers. Newer IMAGE
versions use calibration information that is in the corresponding version of checkers.
Loading Checkers
The first task in running IMAGE checkers is loading the checker programs into a station
window. You can use any station, although tester-specific stations only allow you to load the
checkers and checker groups appropriate for the test head at that station. Auxiliary stations,
on the other hand, allow additional options, including loading System Checkers.
Auxiliary stations are:
• 3 to 10 on advanced mixed-signal testers
• 2 to 10 on A565/PATH II testers
• 3 to 10 on Catalyst testers
• 2 to 10 on Catalyst Tiger testers
You can load checkers using the CHECKERS button menu in the station window (figure 19-
1). All load selections in the CHECKERS button menu have command line equivalents that use
the load command. For more information on the load command, see “Loading Using the
load Command” on page 5-4.
The following sections describe the IMAGE options for loading checkers. They include:
• Checker groups. Loads selected checker programs in groups. Also includes the option
to automatically bring up the IMAGE debugger. See “Loading Checker Groups” on page
19-10.
• Fast-load checkers. Loads groups of checker programs faster than all other options.
See “Loading Checker Groups” on page 19-10.
• Individual checkers. Loads an individual checker program. Also includes the option to
automatically bring up the IMAGE debugger. See “Loading Individual Checkers” on
page 19-11.
• System checker. The system checker loads all available checker programs and
automatically checks all test heads in the tester. This selection appears only in an
auxiliary station. See “Loading the System Checker” on page 19-7.
• Custom checkers. Loads any custom checker groups you have saved. See “Creating
Custom Checker Runs” on page 19-34.
• Static Configure. Allows you to create and view checker groups for specific hardware
configurations. This selection appears only in an auxiliary station. See “Creating a Static
Configuration” on page 19-43.
In full mode the hardware is functionally tested in all known possible conditions. In this
mode, coverage is emphasized over execution time.
-trap_on_fail Loads and runs test system checkers in debug mode. When the
checkers are loaded, a settrap -failedtest command is
issued before running the checkers. Use this option to debug a
failing test.
-trap_on_alarm Loads and runs test system checkers in debug mode. When the
checkers are loaded, a settrap -alarm command is issued
before running the checkers. Use this option to debug a failing
test.
-custom Displays a menu in the station window that allows you to change
the number of times the checker is run or to change checker data
collection and termination mode. You can also store modes to a
file or restore saved modes from a file. See “Creating Custom
Checker Runs” on page 19-34.
-saved <file> Starts the auto checkers using a custom setup obtained from
<file>.
If you do not specify any parameters, the checkers test all the hardware present once.
Hardware switches can be combined, as in:
/image/checkers/sys_check -custom -loop
If the test system checkers are run using the -loop switch, you must stop them using
Control-C or the ABORT button.
NOTE
When loading a test program into an auxiliary station, use the following switches to specify
the test head type associated with that station:
load <program> -head adv_mixsig
-head catalyst
-head tiger
If you try to load a program into a station with a mismatched test head, the program is not
loaded and an error message appears.
Fast-Load Groups
Fast-load checkers are prelinked, binary checker groups that perform identically to checkers
loaded without this option. When you fast-load checkers, you cannot use the IMAGE
debugger. You cannot fast-load maintenance and installation programs.
When each version of checkers is released, you must run the system checker once to create
fast-load groups. The procedure is as follows:
1. At the root prompt, log in as checkers and start IMAGE.
# login checkers
password: xxxxxxx
% image
2. Select NEW STATION from the IMAGE Workspace menu or click on the STATIONS button
in the IMAGE Control window to open an auxiliary station window.
3. Using the CHECKERS button on the station window select SYSTEM CHECK to run the
system checker. You can also run the system checker using the command:
/image/checkers/sys_check
This procedure takes about 15 minutes. When done, a fast version of checkers is created,
allowing checkers to load in seconds instead of minutes.
Before starting to test or build the fast-load file, IMAGE looks for a file called
disable_fastload in the CKR_BIN directory. If this file is present, no testing is done, and
the group is loaded in the standard mode. If you place this file in the CKR_BIN directory, you
can use the same CKR_BIN for multiple systems with different configurations.
Running Checkers
Once a checker program is loaded, you can run it using the RUN button or the run command.
If the checker option permits, you can access the debugger using the DEBUG button or the
debug command. To datalog checker results, use the DATA SETUP button or any of the data
collection commands (see “Datalog Reports” on page 6-13).
The default for all self-test checkers is tmode -cont_on_error. To reset the program
termination mode, use the tmode command (see “Setting Program Termination Modes” on
page 5-24).
All errors are logged to a trace file. The trace file is named:
<system-checker-date>.data
This file is stored in the directory from which the checker was started.
NOTE
If you use the xlock command to lock the screen, you must use an argument, such as
-allowaccess. The xlock command by itself locks the screen but it also shuts down the X
server, causing the checkers to hang up the first time sys_check deletes a checker group.
Another way to lock the screen is to use the LOCK SCREEN selection in the IMAGE
Workspace Utilities menu. This selection does not shut down the X server.
Selection >>
where:
Display Configuration
Displays the current hardware configuration. This option is no
longer supported.
where:
Specify Execution count
Specifies the number of times each individual checker is to be
executed. (The default is once.) This selection prompts you to
enter a checker name. To turn off (not execute) an individual
checker, specify an execution count of 0 for it.
Specify Execution mode
Specifies the execution mode (full or brief) for each checker.
(The default is once.) This selection prompts you to enter a
checker name.
Clear All Execution counts
Set execution counts for all checkers in the group to 0.
Set All Execution counts to 1
Set execution counts for all checkers in the group to 1.
Set All Execution modes to 'Brief'
Set execution mode for all checkers in the group to brief.
Set All Execution modes to 'Full'
Set execution mode for all checkers in the group to full.
Save Execution & Output Setup
Save (on disk) the current setup for the configuration, execution
counts and mode, and I/O selections. The setup is always saved
to the file ck_setup.<suffix>. You are prompted for the
suffix extension.
Initializing Checkers
Selecting Initialize Checkers generates the following menu that allows you set,
change, or restore initialization:
INITIALIZATION MENU
---------------------
1 - Step through initialization questions
2 - Initialize checker to default values
3 - Save checker initialization values
4 - Restore saved initialization values
5 - Exit this menu level
where:
Step through initialization questions
Allows you to select a checker and to examine and change all
possible setting for the checker.
Initialize checker to default values
Changes all checker values to default.
Save checker initialization values
DC SOURCE MENU
--------------
1 - Check V Forcing Accuracy
2 - Check I Forcing Accuracy
3 - Check V & I Forcing Accuracy
4 - Exit this menu level
Selection >> 1
• More than four hours has elapsed since the last calibration
Autocalibration always calibrates the DC Subsystem at the start of the test program and
after every four hours and whenever the test system is powered up.
TMS calibration and TMS deskew occur at the beginning of the test program and after every
four hours only if TMS statements occur in the test program.
Autocalibration deskews the advanced mixed-signal High Speed Digital Subsystem.
IMAGE repeats the calibration whenever the temperature changes more than three degrees
Centigrade or whenever test-head power supply levels change more than the specified limit.
Autocalibration calibrates only the test head in use during TMS and HSD calibration. For
example, a test program loaded into station 2 with the -autocal switch calibrates the TMS
for test head 2 only and deskews the TMS and HSD for test head 2 only.
Calibration results are sent to a trace file in the same directory as the test program. The
calibration output is directed to the checker output stream when checkers are run with the
-autocal switch. See “Changing the Output Setup” on page 19-15 for more information on
directing the output of checker programs (and thereby the autocal messages that occur
while checkers are run with -autocal turned on).
If calibration fails during a checker run, the test system checkers ignore calibration errors.
The test system checkers program the instrument with nominal values and run to the end
of the checker by default.
135.123.254.1 neutron
135.123.254.2 proton_s
135.123.254.3 proton_t
135.123.254.4 alpha
135.123.254.5 beta
135.123.254.6 gamma
The .rauto file for this test system might look like the following:
proton_s
alpha
In this example, proton_s and alpha could configure, schedule, and start checker runs on
the test system.
The system administrator can enter the + character in the .rauto file to allow any tester,
workstation, or terminal to configure, schedule, or start the auto run. In the above example,
the /image/tester/<hostname>/.rauto file would contain only the + character; no other
entries would be required.
NOTE
Auto checkers will not run if the Common Desktop Environment (CDE) has been installed
and the graphical login screen is enabled. The graphical login screen starts before anyone
logs in to the test system. This prevents auto checkers from running. See “Installing IMAGE
on a Test System Using CD ROM” on page 3-3 of the IMAGE V7.x/8.x Software Installation
Guide for Testers.
Checker Versions
The CHECKER VERSION item of the Checker Setup display shows the major release number
of the checkers installed on the test system and the release revision (as a date).
Start Time
The START TIME item on the Checker Setup display is the time that the auto run starts. Enter
a start time value and press Return to validate the entry. The start time must be in 24 hour
format. No AM or PM notation is permitted. The Checker Setup display attempts to interpret
any abbreviations entered in the Start Time field. For example, if you enter 12, the Checker
Setup display shows 12:00 after you press Return.
Only one time entry is permitted. If the auto run is scheduled to run more than one night, it
does so at the same time each night. If you enter an invalid START TIME entry, an error
message appears at the bottom of the display. The default start time is 23:00 hours (11:00
PM).
Datalog Mode
The DATALOG MODE item on the Checker Setup display selects the test results to be
recorded. Select FAILED TESTS or ALL TESTS by clicking SELECT on the corresponding
boxes. Results are stored in export /home/<hostname>/auto. Take care when selecting
ALL TESTS since overnight runs can generate enough data to fill the hard disk partition. The
default is FAILED TESTS.
Set Modes
The SET MODES item on the Checker Setup display brings up a pop-up window with all the
individual checker attributes. Display this Checker Attributes window by clicking SELECT
on the SET MODES button. The pop-up window (figure 19-5) displays all the checkers in the
present group of checkers selected, the execution mode, and the loop count for each
checker. As the default, all checkers run one pass in full mode and only failed tests are
datalogged to a trace file in /home/<hostname>/auto and to the console window.
Checker Groups
You can view and select checker groups by pressing MENU on the GROUPS button and
selecting from this menu (figure 19-6). The checkers in each group are the same as the
ones shown when you press MENU on the CHECKERS button in a test station control panel.
See “Loading Individual Checkers” on page 19-11 for a list of the checkers in each group.
Execution Mode
You can change the execution mode from FULL to BRIEF by clicking SELECT on the
abbreviated menu button next to EXECUTION MODE for each checker (figure 19-7).
The buttons at the top of the Checker Groups display, ALL MODES FULL and ALL MODES
BRIEF, allow you to set the execution mode of all checkers in the Checker Group displayed
to FULL MODE or BRIEF MODE by clicking one button. You can see the choices for execution
mode by pressing MENU on the abbreviated menu button next to each EXECUTION MODE.
A menu appears with the choices BRIEF and FULL.
Loop Count
The LOOP COUNT is the number of times the checker will be executed. You can change the
LOOP COUNT for each checker by pressing MENU on the abbreviated menu button next to
LOOP COUNT for each checker (figure 19-7). The menu shows the loop count choices. Select
1, 2, 4, 8, 16, or 100.
Output Mode
You can select the checker results to be saved by pressing MENU on the box next to
OUTPUT MODE. The choices are FAILED TESTS, ALL TESTS, and NO TESTS (figure 19-8).
You can send the checker results to a trace file or to the screen by clicking SELECT on the
boxes for TRACE FILE or CONSOLE. A trace file is a file in /home/<hostname>/auto
containing all auto run test results and messages. If you select CONSOLE, the test results
and messages are sent to the station 5 tester window. The default settings are FAILED TESTS
to a TRACE FILE and CONSOLE (figure 19-8).
Reboot_Always
The IMAGE Properties window includes an option, REBOOT ALWAYS, that allows you to
reboot the remote tester before the start of the auto run. Rebooting is useful if the remote
tester is not running IMAGE (for example, OpenWindows) or if station 5 is in use on the
tester. (For more information on IMAGE Properties, see “Setting IMAGE Properties” on
page 3-34.)
To enable this option:
1. Log in to the test system as root.
2. su to auto.
3. Bring up IMAGE.
4. Select PROPERTIES>IMAGE PROPERTIES from the IMAGE Workspace menu.
5. Select the AUTO CHECKER RUN OPTIONS menu.
6. Press MENU on the abbreviated menu button for REBOOT ALWAYS and select TRUE.
7. Save this change by clicking SELECT on the APPLY button (figure 19-10).
8. Quit the IMAGE Properties window.
NOTE
Changes made to the IMAGE Properties window are recognized by auto run only if the
changes are saved and the ENABLE/DISABLE AUTO RUN button is toggled. To toggle this
button, click on the DISABLE AUTO START button in the Checker Setup Display (the button
changes to ENABLE AUTO START) and then click on the ENABLE AUTO START button (the
button changes back to DISABLE AUTO START).
A message appears on the tester console window that auto run is enabled. If the start time
is within 12 hours, countdown messages appear in the tester console window announcing
the auto run. Countdown messages appear in the windows of any terminals logged into the
tester.
Four hours before start time, the warning messages become more frequent, and the ABORT
AUTO icon appears on the tester screen if the tester is running IMAGE. To stop the auto run,
click on the ABORT AUTO icon at any time before the auto run starts.
Once the auto run starts, the tester reboots itself if you set REBOOT_ALWAYS to TRUE in the
Auto checker runs menu, and then the tester starts the checker run in station 5. After the
checker run starts, you can stop it by clicking on the ABORT button or by typing CONTROL-C
in station 5. When the checker run is stopped, user “auto” remains logged in until IMAGE is
manually exited and user “auto” is manually logged out.
If REBOOT_ALWAYS was not enabled, the tester must be running IMAGE and station 5 must
not be in use. When running in the no-reboot mode, auto run starts in station 5 at the
specified time if no devices are being tested, or as soon as the device being tested is
binned.
For the ABORT icon to appear on the user computer in the four hours before the start of an
auto-checker run, any user on the console must allow outside connections to the X server.
Do this using the command:
xhost +
in the user’s .login file.
Terminal Interface
The Terminal Interface allows you to schedule and start auto run from a remote VT100 style
terminal over a modem or from a Shelltool through the Ethernet. The workstation must be
in the tester’s /image/tester/<hostname>/.rauto file as described in “Installing the Auto
Checker Utility” on page 19-22. The same warnings and ability to stop the auto run occur on
the remote tester. The Terminal Interface cannot change the checker attributes or the
REBOOT_ALWAYS selection in the IMAGE Properties window. To change the checker
attributes and the REBOOT_ALWAYS selection, you must be logged in to the tester itself as
described in “Installing the Auto Checker Utility” on page 19-22.
To schedule or start the auto run from a VT100 type terminal or shell tool:
1. Log onto the VT100 style terminal or shell tool.
2. Type either of the following:
checkerdisp -nographics<cr>
ckrsetup<cr>
The VT100 or Shelltool prompts you for the name of the test system on which you want
to schedule auto run.
3. Press RETURN to enter the name of the test system that you remotely logged in to, or
type in the name of the test system for the auto run and press RETURN.
4. The Checker Setup for the selected test system appears on the VT100 screen or shell
tool. If no changes have been made, the default settings are:
– Auto Run enabled for current day of the week
– Datalog mode is FAILED TESTS
– Scheduled start time is 23:00 (24 hour format)
– Auto Run Feature is DISABLED
5. The Configuration Menu appears on the VT100 screen shell tool with the following
selections:
1 Edit Start Time
2 Edit Day of Week
3 Edit Datalog Mode
4 Toggle enable/disable Auto Run
5 Save Changes
6 Exit this menu level
6. To change the start time, type 1 and enter the start time in 24 hour format.
7. To change the day or days of the week for auto run, type 2 and type y or n after the days
of the week.
8. To change the datalog mode, type 3 followed by A for All Tests or F for Failed Tests.
9. To save changes, type 5. You must save any changes before you can enable or disable
the auto run in the next step.
10. To start the auto run, type 4. The Checker Setup indicates AUTO RUN FEATURE IS
ENABLED.
11. To exit the menu, type 6.
The auto run countdown now begins with the same warning messages to users logged on
to the tester. You can stop the auto run from the VT100 style terminal or Shelltool only if
auto run has not started. To stop auto run, type 4. Checker Setup indicates AUTO RUN
FEATURE IS DISABLED. Once the auto run begins, you can stop auto run only by aborting
the auto run on the tester itself.
NOTE
If the checker group has changed, IMAGE gives a warning about a “stale” saved file. The
checker run is then aborted.
NOTE
If you statically configure a test system, you must recreate any saved custom checker files.
See “Creating a Static Configuration” on page 19-44.
You can also move stored custom setups forward when a new version of checkers is
installed on a tester (provided the checkers in the group have not changed). IMAGE
includes a search path for the custom files. When looking for a set of saved files, IMAGE
looks in the following directories in this order:
$HOME/.checker_setups
/image/tester/<nodename>/.checker_setups
This allows a two-tier approach which provides for a tester-specific set of customizations
and a user-specific set of customizations.
You can also use the ckr_setup_menu command. The syntax is as follows:
/image/checkers/ckr_setup_menu [-init] | [-file <restore file>]
where:
-init Initializes all exo tables to their default values without interactive
operation. The default values are:
io = fail messages to station window and trace file
checker execution mode is FULL
checker execution count is 1
-file File name of setup file to restore.
Selection =>
Selection 0 allows you to start the current system checker. Selections 1 through 10 allow
you to customize each checker group. Selection 11 includes global commands that affect
all groups in the system checker.
uwst full 1 19
modsrcst full 1 20
bbacst full 1 21
Precede the list input by + or - to mark the channels listed for set or reset. If neither is
specified, the resources listed are toggled from the present state.
Since a resource can mean different things to different checkers, checkers include a help
file to describe the resource nomenclature. You can view the help files using the resource
menus in the custom checker utility.
Selection 3 in the group menu displays the resource settings for the group and a menu that
allows you to set and view resources. The following is an example:
Tiger_analog_ck
Checker ID Type Resource Data (1 to 160)
-------------------------------------------------------------------------
pacsII_ams_st 1 1 all resources selected
headst 2 1 all resources selected
vhfcwst 3 1 all resources selected
vhfst 4 1 all resources selected
vhf_ams_st 5 1 all resources selected
gigadigst 6 1 all resources selected
uhfcwst 7 1 all resources selected
lfacst 8 1 all resources selected
lfac_ams_st 9 1 all resources selected
rdc24st 10 1 all resources selected
vregst 11 1 all resources selected
ovidccst 12 1 all resources selected
lcast 13 1 all resources selected
trgst 14 1 all resources selected
tjast 15 1 all resources selected
qvsdccst 16 1 all resources selected
qvsst 17 1 all resources selected
ubasyst 18 1 all resources selected
uwst 19 1 all resources selected
modsrcst 20 1 all resources selected
bbacst 21 1 all resources selected
NOTE
The resource help file is displayed using the file editor program set by the EDITOR
environment variable. Thus, to have the file displayed using the OpenWindows textedit
program, enter the following in the station window: setenv EDITOR textedit
Selection 6 in the group menu controls how resource customization summaries are
displayed. This selection provides a summary such as the following:
Display resource data in [H]ex or [D]ecimal >> d
Display mode will be DECIMAL
Enter first resource number to display [1 to 1024: 1] >> 1
First resource displayed will be 1
Enter last resource number to display [1 to 1024: 22] >> 22
Last resource displayed will be 22
Enter maximum resource type to display [1 to 4: 1] >> 4
Highest resource type displayed will be 4
For example, the dmf_ams_st example above changed to display in decimal would look as
follows:
Advmixsig_frame_ck
Checker ID Type Resource Data (1 to 160)
-------------------------------------------------------------------------
scmclk_ams_st 1 1 all resources selected
dmf_ams_st 2 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0
mfs_ams_st 3 1 all resources selected
pacs_ams_st 4 1 all resources selected
smem_ams_st 5 1 all resources selected
cmem_ams_st 6 1 all resources selected
apxfer_ams_st 7 1 all resources selected
vbms_ams_st 8 1 all resources selected
Selection =>
Selection 0 returns you to the main menu.
Selection 1 saves the custom setup to a file. When selected, you are asked to enter a prefix.
This is a name you want to give to the custom setup. The names daily, weekly, and
monthly have special meanings. See the “Loading the System Checker” on page 19-7.
Once you enter the prefix, you are asked to enter whether the saved setup should be stored
as [P]rivate or [S]ite. (You can also answer with ? to get help.) Private allows you to
save the setup in your home directory under a directory .checker_setups. Add the
following to your .usermenu file for faster execution of private custom checker setups:
"Custom Checker Menu" MENU ${HOME}/.checker_setups/.custom_menu
If you save the custom setup as Site, the file is saved in
/image/tester/<name>/.tester_setups and appears in the CHECKERS>CUSTOM
CHECKER RUNS button menu.
Selection 2 reloads a saved custom setup. You can do this, as explained above, either from
your customized .usermenu (if private) or from the station window CHECKERS>CUSTOM
CHECKER RUN menu.
Selection 3 calls for datalogging of only failed tests to a file, and selection 4 calls for
datalogging of all tests to a file.
NOTE
If a new hardware option is added to the test system, or an existing option is removed,
perform an Unconfigure operation then perform another Static Configure operation. This
updates the checker groups and menus.
When you select STATIC CONFIGURE from the CHECKERS menu, the config file for each
checker is compared to the file:
/image/tester/<tester>/system_config
This file is created by sys_check.
If the required hardware is present, the checker is included in the checker group. If any
hardware specified in the checker config file is missing from the system_config file, the
checker is not included in any checker group.
If any checker does not have a config file ($CKRBIN/conf/<name>.cf), the checker is
included in the checker group by default.
If you change the hardware configuration on a tester that has been configured, you must
rerun static configure. The static configure option takes about 10 to 15 minutes to configure
a tester.
If the tester configuration does change, you are warned; sys_check compares a stored
system configuration file to the present system configuration.
The Checker Groups are rebuilt based on the hardware configuration in the test system at
the time of execution. It takes about 10 to 15 minutes.
If a new hardware option is added to the test system, or an existing option is removed,
update the static configuration as follows:
1. Open an auxiliary station window.
2. Select CHECKERS>CONFIGURE>UNCONFIGURE or enter the command
/image/checkers/unconfigure. The unconfigure operation takes about 10 to 15
minutes.
NOTE
Once you statically configure a test system, you must recreate any saved custom checker
files. These files are stored in your directory
$HOME/.checker_setups
/image/tester/<tname>/.checker_setups
This restores the checker groups and checker menus to their original state, where all
checkers are viewed under the appropriate menus. It takes about 10 to 15 minutes. The
definition of an INVALID checker is restored, where in the System Check summary it
appears as if the checker were not executed.
This selection displays in a textedit window the list of checkers currently part of each
checker group. For example, if a test system has not had Static Configure performed, all
default checkers are listed in the default checker groups. If the test system has had Static
Configure performed, the reduced list of checkers is displayed in the checker groups.
preventing the static configure option, namely that checker binaries are shared by more
than one tester. (See “Fast-Load Groups” on page 19-10.)
The Device Focussed Checkers (DFC) feature more tightly integrates test system checkers
into the production environment. It allows you to describe how the tester is being used to
test devices and to include this information in a test program. This information is then used
to test the specified instruments at the operating points being used in the test program
during a production run.
This section includes the following topics:
• “Using Device Focussed Checkers in IMAGE” on page 20-2
• “DFC User Callable Functions and Definitions” on page 20-4
• “DFC User Callable Functions and Definitions” on page 20-4
• “DFC Execution Points” on page 20-5
• “DFC Compiler” on page 20-6
• “PLFSRC Module” on page 20-8
• “PLFDIG Module” on page 20-9
• “HSD50 Module” on page 20-10
• “DC Module” on page 20-12
Limitations
The DFC provides no diagnostic output and is designed only to signal the test program if an
instrument used by the test program fails or drifts out of specification (as best as can be
determined by the tester).
If DFC signals the test program to stop testing on a lot of devices, have a technician or field
service person run test system checkers to determine the cause of the fault.
You can determine which instrument failed using the DFC. This requires that you modify
your test program to add calls to the DFC library.
You must also modify the test program to check the return status of DFC and take action on
a failure. The most integrated approach is to write a callback function supported by the DFC
control, which lives in the test program and is called by DFC if any instruments fails a test.
The name of the supported call-back is tl_dfc_fail_action(), and the recommended
action would be to stop testing the lot of devices.
To output additional information, such as which instrument failed, you must include the
header file dfc_instrs.h in the test program. This header defines an enumerated type
called TL_DFC_INST which contains a value for each supported instrument. These values
can be passed sequentially to the function tl_dfc_inst_status() to determine which
instrument failed.
DFC Compiler
The DFC compiler parses and compiles the instrument description file. The output is a .o
module which is loaded with the test program. The input is a DFC file in a LISP-like syntax
which specifies which instruments are used in the test program and how they are
programmed.
Loading the test program with the DFC module causes the DFC test library to be linked with
the test program. This library (libdfc.a) is where the checker functions for each instrument
exist. When the test program is run, the DFC executive calls, at the appropriate time,
Usage
The DFC compiler is called dfccomp. Unlike other IMAGE tools, it cannot be started by
imagepath in /image/common. This means that to use the tool, you must either add
$IMAGEBIN to your path, or start the compiler with the full path as in:
$IMAGEBIN/dfccomp <foo.dfc>
The usage of the tool is:
dfccomp [-save] <filename>
The -save flag saves a copy of the intermediate .tl file for inspection or debugging
purposes. This intermediate file is compiled using the IMAGE itlc compiler to create the
final DFC module.
Compiling foo.dfc creates the object file foo.o in the same directory.
Compiling foo.dfc with the -save switch creates the intermediate file foo.tl and the
object file foo.o in the same directory.
(lpfilt 20KHz)
)
You can define multiple setups for an instrument and multiple instruments. You cannot set
the same parameter more than once for an instrument. This requires multiple setups.
Instrument names (such as plfsrc used in the example) are checked against a valid list of
supported instruments at compile time. Parameters and values are not checked by the
compiler. This checking is done in the individual instrument checkers at runtime. For
information about which parameters and values are supported by each instrument checker,
see the documentation for that DFC instrument.
During the development of a DFC input file, closely monitor the output in the station window
at runtime for errors generated from the DFC checkers related to parameters. Any error
causes the test program to terminate execution, and this is the only time the DFC prints any
output to the station window.
Once the DFC input file is debugged, no output should be generated by the DFC.
PLFSRC Module
The test program plfsrc_dfc() checks the functionality of a Precision Low Frequency
Source. The inputs to the program are values to specify what operating characteristics to
verify the source at and the pin number of the source to be tested. A pin number is also
required to specify some PLFDIG for use in testing the source’s AC capabilities. This other
PLFDIG should be one that is also being tested with a DFC module. Another constraint on
the input for the pin numbers of the instruments is that the pin number must be for the HI
side of the instrument.
The output for the program is a FAIL if the instrument fails to preform correctly or a PASS if
it succeeds. The program takes no more than a minute to test a single source instrument.
Parameters/Syntax
The program is called using the syntax:
plfsrc_dfc(<parameter list>);
where:
src_pin Specific PLFSRC to be tested. It must be a valid pin number.
dig_pin Specific PLFDIG. It must be a valid pin number.
src_lpfilt 2khz | 20khz | 100khz | 500khz (Default is 2khz.)
Test Strategy
The program tests the PLFSRC at dc and ac. At DC the inputted values for amp and the
dcbase line are tested by connecting the source to the DC Matrix in the test system. This
allows checking of connection ability and the performance in the ranges you specify. The
AC section involves connecting the source and specified digitizer together across the
THADS bus and sourcing sine waves at, and within, the frequency range specified and with
the appropriate filter and amplitude. The sine waves are checked for noise, amplitude
accuracy, THD, and spurs. These characteristics signify if the source is performing
correctly. At any time that the source is not performing within the expected values, the
program fails and produces an error message.
PLFDIG Module
The plfdig_dfc() test program checks the functionality of a Precision Low Frequency
Digitizer instrument. The inputs to the program are the values to specify the operating
characteristics to verify the digitizer at and the pin number of the digitizer to be tested. A pin
number is also required to specify a PLFSRC for use in testing the digitizer’s AC capabilities.
This PLFSRC should be one that is also being tested with a DFC module. Another constraint
on the input for the pin numbers of the instruments is that the pin number must be for the HI
side of the instrument.
The output for the program is a FAIL if the instrument fails to preform correctly or a PASS if
it succeeds. The program takes no more than a minute to test a single digitizer instrument.
Parameters/Syntax
The program is called by using the syntax:
plfdig_dfc(<parameter list>);
where:
dig_pin Specific PLFDIG, must be valid pin number.
src_pin Specific PLFSRC, must be valid pin number.
vrange 0.113 -> 11.0 vpk. (Default is 11.0vpk.)
dig_lpfilt 2khz -> 500khz. (Default is 2khz.)
dig_dcbase -11.0 -> 11.0vpk. (Default is 0.0v.)
dig_feq Frequency of waveforms typically captured by dig. (Default is
1khz.)
The parameters must be input in the order above. If you are not testing a specific parameter,
it is assigned a default value. Src and dig pin numbers require valid pin number which must
be supplied. Otherwise, the program fails immediately.
Test Strategy
Test the PLFDIG at dc and then ac. DC tests involve testing connections to the DC Matrix
and the THADS bus, using the ability of the digitizer to capture simple dc levels at specific
ranges. This verifies the basic capture and move ability of the digitizer. AC tests involve
connecting the digitizer and source together across the THADS bus and then using the
digitizer to capture waveforms from the source. This verifies the ability of the source to
capture AC waveforms within its operating specifications and verify its performance in that
range by specifically testing to the frequency inputted with the amplitude and filter
requested. Any time the digitizer is not preforming correctly, the program fails the instrument
and stops testing.
HSD50 Module
The hsd50_dfc module tests the basic functionality of HSD50 channels. If present, the
DSIO subsystem is also tested. Test coverage is designed to exercise the digital channels
at the operating points specified by the device program. Only the channels in the channel
list specified in the .dfc file are tested. To minimize run time, only specify the channel range
used by the device program.
Some testing is performed by looping back each channel’s digital driver to the digital
receiver and bursting a pattern. The loopback connection is made at the test head. Other
testing is performed using the TMS.
Parameters/Syntax
The hsd50_dfc program is called using the syntax:
tl_dfc_hsd50(<parameter list>);
where:
chanlist The range of digital channels to test, from 1 to 192. The format
must be x..y with x as the first and y as the last channel in the
range. This parameter is required.
mclk Master clock frequency from 160 MHz to 200 MHz. (Default is
200 MHz.)
t0_div t0 clock divider from 4 to 32771. (Default is 4.)
vrange Channel driver voltage range: low, middle, or high. (Default is
high.)
calset A valid digital calibration set name. The calset must already have
been defined and started in tl_init() for testing to function
correctly. This parameter is required.
An example is as follows:
tl_dfc_hsd50 (
mclk, 200MHz
t0_div, 4
vrange, high
calset, "valid_calset_name");
calibrated before a call to the hsd50_dfc program, the program fails. Also, variables defined
in the .dfc file must match the settings defined in the cal_set defined in the .dfc file. For
example, if the .dfc file looks like:
(hsd
(mclk 200MHz)
(t0_div 4)
(vrange high)
(calset "cal_200_normal")
)
then the cal_set cal_200_normal should include:
set hsd50 cal-set = "cal_200_normal"
m_clk = 200MHz
vrange: high
dchan = (1 to 8);
Variables defined in the .dfc file that do not match the variables in the cal_set can cause
hsd50_dfc to fail. The only operating point that should be considered optional is the t0 clock
divider. All others must be included in the .dfc to ensure correct test execution.
The TMS and DC subsystems are used and, therefore, must also be calibrated.
dfc_hsd50 tests, as with all checker tests, must be run with the DUT relay open to isolate
the tester from the DIB while the self-tests are run. The cal_set passed to dfc_hsd50
through the .dfc file may be defined to calibrate HSD50 with the DUT relay either open or
closed. Therefore, the timing used in the dfc_hsd50 tests is set up to allow for potential
differences between calibration with open or closed DUT relays. Calibration sets run with
the DUT relay closed on long path lengths may result in failure of the dfc_hsd50 tests.
Tests included in dfc_hsd50 are briefly described below:
Rev. prom check Checks HSD ID PROMs.
Calibration Constants Check
Checks that the calibration set is valid.
Format and timing checks
Various patterns are burst, with each channel driver looped back
at the test head and checked by the channel receiver. SCM
microcode, digital modes, formats, patterns, and timing are all
exercised. Failures are determined by reading the accumulated
fail register and SCM flags and comparing to expected values.
Digital channel driver operation is also monitored using the TMS.
Digital Signal Tests (if option exists in system)
A digital signal is burst from SMEM to the CMEM through each
digital channel and looped back at the test head. The results
captured into CMEM are compared to expected values.
DC Module
The test program dc_dfc checks the standard dc sources and the dc system meter. For the
dc sources, you must specify the source number, voltage, and current ranges that the
sources are set to during their test points of interest. For the meter you can specify which
input to test. The program takes no more than 5 seconds per source and 16 seconds for the
system meter to execute a single setup.
Parameters/Syntax
The parameters input by a foo.dfc file are as follows:
DC SOURCES (dc
(src #)
(vrng xxx)
(irng xxx)
)
where:
src # Specified source to test (1-9).
vrng xxx Voltage range of source: 0.5v | 1v | 2v | 5v | 10v |
20v | 50v | 100v | 200v
DC METER (dc
(meter xxx)
)
where:
meter xxx Specified input to test: vm1, vm2, vmdiff, all
all tests vm1, vm2, vmdiff, and all in the same test call.
Test Strategy
Using matrix crosspoints 1-3 and the test system reference, the voltage forcing/metering
and the current forcing/metering for the dc sources are verified for the voltage and current
ranges you specify. Some miscellaneous checks are also performed, such as verification of
the delta bus input to the dc source and the maximum compliance tests.
The DC meter tests are done using dc source 1, crosspoints 1-3, and the test system
reference. The metering accuracy is verified per user input (for example, vm1, vm2...) on all
meter ranges. Coverage for sample and difference gain and meter filtering are also
performed. These tests are the same as those found in the DCST self-test checker.
21 CALIBRATION
No
tl_user_pre_autocal()
Autocalibration
tl_user_post_autocal()
tl_init() End
tl_init() is a null function that you typically overwrite when you define this function in your
program.
No
tl_user_pre_autocal()
Autocalibration
tl_user_post_autocal()
main() End
Autocal checks the calibration status of each instrument linked to the test program. If
calibration is necessary, the instrument is calibrated. Calibration is unnecessary if the
instrument is already calibrated and nothing has happened to invalidate this calibration.
(See “Determining When Calibration is Performed” on page 21-6.)
Calibration results are sent to a trace file in the same directory as the test program.
NOTE
Exceptions to this statement are the Analog Pin Unit (APU) and Advanced Analog Pin Unit
(AAPU). These instruments maintain their calibration during initialization and so do not
require calibration afterwards.
• Instrument lists the instrument and its IMAGE syntax abbreviation used in calibration
commands
• Autocal lists whether the instrument is calibrated by autocalibration
• Pinmap Only lists whether the instrument can use the pinmap_only feature. (See
“Pinmap Only Mode” on page 21-29.)
• Calfile lists whether the instrument uses a calibration file to store calibration values
• Force lists whether the instrument can be forced to use its calibration file even if the file
may not be valid
• Default Criteria lists the default time interval used for checking calibration
• Dependencies lists which other instruments must be calibrated for calibration to
succeed for this instrument.
Pinmap Default
Instrument Autocal? Calfile? Force? Dependencies
Only? Criteria
Pinmap Default
Instrument Autocal? Calfile? Force? Dependencies
Only? Criteria
Table 21-2 shows the required calibration resources for the A500 family instruments. The
table has the following headings:
• Instrument lists the instrument and its IMAGE syntax abbreviation used in calibration
commands
• Resource lists the name of the resource
• Use lists whether the instrument uses the resource.
VHFAWG
In IMAGE V6.3 and later, the Very High Frequency Arbitrary Waveform Generator
(VHFAWG) has temperature-based calibration. Temperature checks are performed every
20 minutes, and recalibration will not occur unless a significant drift is detected.
The VHFAWG1200/2500/4800 uses a temperature sensor on its channel card to determine
the amount of temperature drift. A 1.75 degree C change will trigger recalibration.
The VHFAWG200 and 400 check for drift using the peak detector and Absolute Level
Reference Oscillator (ALRO) on their channel cards. The ALRO provides a temperature-
stable reference signal. To perform a drift check, this signal is connected to and measured
by the detector. When the voltage measured by the detector changes by 5 mV or more since
the last calibration, recalibration is triggered.
The RF Instrument Setup display shows the time of the last actual calibration. The
command calibrate -report shows the time remaining until the next temperature check.
Controlling Calibration
Normally, using autocal simply involves loading a test program under autocal and running
it. In this case, IMAGE does all the work of making sure instruments stay in calibration.
In some situations, such as debug, you may want some flexibility. For example, you may
want to handle calibration of one or more instruments yourself. Autocal includes a number
of functions and parameters that allow you to customize the way autocal operates.
NOTE
When debugging a test program, do not use the Immediate window to alter calibration
between test program runs.
IMAGE also supports “manual” calibration. This is calibration you invoke using the
calibrate command or test program calibration statements. See “Manual Calibration
Using the calibrate Command” on page 21-33 for more information.
NOTE
This parameter allows you to run the test system uncalibrated. This may result in incorrect
testing of some devices. Production testing is disabled in this mode.
-cal_after Calibrate after the test program run. The default is to run
calibration before the test program run.
-nocalfile Do not use the calibration data files for instruments which
support them. (See table 21-1 on page 21-7.)
-pinmap_only Calibrate only those copies used in the current pinmap. This
mode is available only for instruments which support calibration
by instance. See “Pinmap Only Mode” on page 21-29 and table
21-1 on page 21-7.
-frc_calfile Force use of calibration data files even if the calibration file may
not be valid.
NOTE
This parameter allows you to run the test system uncalibrated. This may result in incorrect
testing of some devices. Production testing is disabled in this mode.
NOTE
The HF Digitizer does not require calibration. The VHF Digitizer, which is programmed using
hfdig syntax, does require calibration.
When autocal is not enabled, you must handle calibration for that
instrument.
-<inst> [cal_type] ignore_cal
Ignore calibration for instrument inst or calibration type
cal_type. Allows you to load a test program without calibrating
a specified instrument.
NOTE
This parameter allows you to run the test system uncalibrated. This may result in incorrect
testing of some devices. Production testing is disabled in this mode.
NOTE
This parameter allows you to run the test system uncalibrated. This may result in incorrect
testing of some devices. Production testing is disabled in this mode.
NOTE
The pinmap_only mode is available only for instruments which support calibration by
instance (see table 21-1 on page 21-7).
TL_AUTOCAL_CALFILE/TL_AUTOCAL_NO_CALFILE
Use or ignore all existing calibration data files. The default is to
use all cal files.
NOTE
The cal file mode is available only for instruments which support calibration files (see table
21-1 on page 21-7).
TL_AUTOCAL_FRC_CALFILE/TL_AUTOCAL_NO_FRC_CALFILE
Force or do not force use of calibration data files even if they are
not valid under current conditions. The default is to not force use
of cal files.
NOTE
This mode is available only for instruments which support forcing calibration files (see table
21-1 on page 21-7).
NOTE
Test system instrument specifications are not guaranteed when operating with calibration
files forced for any instrument.
NOTE
When the autocal utility is set to force calibration files, a warning message is printed to the
station window and to the datalog stream for every program execution. Production testing
is disabled.
TL_AUTOCAL_IGNORED/TL_AUTOCAL_NOT_IGNORED
Ignore calibration for any instruments using autocal, but allow all
instruments to be used as if they were calibrated. (That is, do not
stop the program with run time errors reporting that instruments
are not calibrated.) This is intended for use in engineering
situations and is not appropriate for production testing. The
default is to not ignore autocal.
NOTE
Test system instrument specifications are not guaranteed when operating with calibration
ignored for any instrument.
NOTE
When the autocal utility or any instrument is set to ignore calibration, a warning message is
printed to the station window and to the datalog stream after each program execution.
Production testing is disabled.
TL_AUTOCAL_NOT_IGNORED
Error messages will not be ignored.
TL_AUTOCAL_CAL_BEFORE
Perform autocal before running test program.
TL_AUTOCAL_CAL_AFTER
Perform autocal after running test program.
TL_AUTOCAL_CALFILE Use the calfile.
TL_AUTOCAL_NO_CALFILE
Do not use the calfile.
TL_AUTOCAL_ALL_COPIES
Calibrate every copy of the instrument.
TL_AUTOCAL_PINMAP_ONLY
Calibrate only copies of the instrument defined in pinmap.
See “tl_cal_get_autocal_mode” on page 26-158 for more information.
TL_AUTOCAL_FRC_CALFILE/TL_AUTOCAL_NO_FRC_CALFILE
Force or do not force use of calibration data files for this
instrument even if they are not valid under current conditions.
The default is to not force use of cal files.
NOTE
This mode is available only for instruments which support forcing calibration files (see table
21-1 on page 21-7).
NOTE
Test system instrument specifications are not guaranteed when operating with calibration
files forced for any instrument.
NOTE
When any instrument is set to force calibration files, a warning message is printed to the
station window and to the datalog stream for every program execution. Production testing
is disabled.
TL_AUTOCAL_IGNORED/TL_AUTOCAL_NOT_IGNORED
Ignore calibration for this instrument using autocal, but allow the
instrument to be used as if it were calibrated. (That is, do not stop
the program with run time errors reporting that the instrument is
not calibrated.) This is intended for use in engineering situations
only and is not appropriate for production testing. The default is
to not ignore autocal.
NOTE
Test system instrument specifications are not guaranteed when operating with calibration
ignored for any instrument.
NOTE
When the autocal utility or any individual instrument is set to ignore calibration, a warning
message is printed to the station window and to the datalog stream for every program
execution. Production testing is disabled.
View choices for inst by typing calibrate -usage in the station window.
In all functions, cal_type is the specific type of calibration for a particular instrument.
Currently, only the Precision Multimeter supports multiple types of calibration. (See
“Precision Multimeter” on page 21-44.) If an instrument has only one type of calibration, use
empty quotes ("") for its cal_type. For example:
tl_cal_set_inst_mode("hsd50", "", TL_AUTOCAL_FRC_CALFILE);
See “tl_cal_set_inst_mode” on page 26-166 for more information.
TL_AUTOCAL_NOT_IGNORED
Error messages will not be ignored.
TL_AUTOCAL_CALFILE Use calfile.
TL_AUTOCAL_NO_CALFILE
Do not use calfile.
In all functions, cal_type is the specific type of calibration for a particular instrument.
Currently, only the Precision Multimeter supports multiple types of calibration. (See
“Precision Multimeter” on page 21-44.) If an instrument has only one type of calibration, use
empty quotes ("") for its cal_type. For example:
tl_cal_get_inst_mode("hsd50", "");
See “tl_cal_get_inst_mode” on page 26-160 for more information.
Both these functions return the following flags indicating calibration state:
TL_AUTOCAL_CALIBRATED/TL_AUTOCAL_UNCALIBRATED
If calibration has failed or has never been run, the state is
uncalibrated.
TL_AUTOCAL_INVALID If autocal was attempted but the required hardware is not
present, the state of calibration for that instrument is both
uncalibrated and invalid.
NOTE
Global autocal state (that is, autocalibration for all instruments) cannot be invalid.
TL_AUTOCAL_THIS_RUN
For “pre-run” autocalibration (autocal mode is set to
TL_AUTOCAL_CAL_BEFORE), it indicates that calibration occurred
at the beginning of the run.
For “post-run” autocalibration (autocal mode is set to
TL_AUTOCAL_CAL_AFTER), it indicates that calibration occurred
at the end of the last run.
NOTE
For the special case of the first run after a load, TL_AUTOCAL_THIS_RUN is flagged in “post-
run” autocalibration and is not flagged in “pre-run” autocalibration.
NOTE
Modifying the default calibration criteria for any test system instrument invalidates the
specifications of that instrument.
View choices for inst by typing calibrate -usage in the station window.
For example, to change the time interval for DC calibration you could use:
tl_cal_set_inst_crit("dc", "", 6*60*60.0, TL_AUTOCAL_TIME)
This function would reset the dc calibration time interval to six hours. TL_AUTOCAL_TIME and
TL_AUTOCAL_TEMP define the type of calibration criteria (time or temperature).
In all functions, cal_type is the specific type of calibration for a particular instrument.
Currently, only the Precision Multimeter supports multiple types of calibration. (See
“Precision Multimeter” on page 21-44.) If an instrument has only one type of calibration, use
empty quotes ("") for its cal_type.
See “tl_cal_set_inst_crit” on page 26-166, “tl_cal_get_inst_crit” on page 26-160, and
“tl_cal_get_remaining” on page 26-163 for more information.
To use pinmap_only mode effectively, include all instruments used in your test program in
your pinmap, even resources (such as TMS) that may not normally be listed. You can use
dummy pins or the uses pinmap statement to do this.
Note that the PLFDIG requires the PLFSRC to be calibrated. (See the calibration
dependencies in table 21-1 on page 21-7.) Furthermore, if the PLFDIG is used in the pinmap
and the PLFSRC is not, the PLFDIG will not calibrate properly when using pinmap_only
mode. The PLFSRC must be mentioned in the pinmap (even if it is not being used).
NOTE
Calibration interval defaults are set to the maximum recommended time for each
instrument. Increasing this time may violate calibration.
NOTE
Use of cron with calibration commands is not recommended.
NOTE
The HF Digitizer does not require calibration. The VHF Digitizer, which is programmed using
hfdig syntax, does require calibration.
where:
inst Specifies an instrument. Not all instruments are available on all
test systems.
cal_type Specifies the type of calibration for an instrument. Currently, only
the Precision Multimeter supports multiple types of calibration.
The PMM allows the following cal types:
acv dcv ohms
See “Precision Multimeter” on page 21-44.
-noautocal | -autocal
Turn autocal off or on. When autocal is not enabled, you must
handle calibration. The default is off.
-ignore_cal | -noignore_cal
Ignore calibration for this instrument using autocal, but allow the
instrument to be used as if it were calibrated (that is, do not stop
the program with run time errors reporting that the instrument is
not calibrated). This is intended for use in engineering situations
only and is not appropriate for production testing. The default is
to not ignore autocal.
NOTE
Test system instrument specifications are not guaranteed when operating with calibration
ignored for any instrument.
NOTE
When the autocal utility or any individual instrument is set to ignore calibration, a warning
message is printed to the station window and to the datalog stream for every program
execution. Production testing is disabled.
-cal_after | -cal_before
Invoke autocal before or after the test program executes. In
either case, autocal always occurs immediately after the test
program load completes. Calibrating after execution may be
useful when using device handlers or probers with
environmental controls and temperatures can be held only for a
limited time. The default is before.
-nocalfile | -calfile
Use or ignore all existing calibration data files. The default is to
ignore all cal files. (See table 21-1 on page 21-7.)
-frc_calfile | -nofrc_calfile
Force or do not force use of calibration data files even if the
calibration file may not be valid. The default is to not force use of
cal files.
NOTE
This parameter allows you to run the test system uncalibrated. This may result in incorrect
testing of some devices. Production testing is disabled in this mode.
-all_copies | -pinmap_only
Calibrate all copies of instruments for each instrument driver
linked into the current test program, or calibrate only those
copies used in the current pinmap. The default is to calibrate all
copies.
NOTE
The pinmap_only mode is available only for instruments which support calibration by
instance (see table 21-1 on page 21-7).
NOTE
If your test program includes any calibration statements, and you load the program under
autocal, IMAGE calibrates the test system or instrument twice.
calibrate -hsd
Typing this command immediately forces calibration of all defined cal_sets. If no cal_sets
are defined, calibration exits without doing anything.
Calibration can be controlled completely by the test program. You can turn off autocal and
use your own set of conditions to determine when to run calibration. These conditions can
include:
• First run of the test program
• Any specified mainframe or test head temperature change
• Any specified power supply change
• Any specified time interval
• Any other condition appropriate for the test program and device under test
When the specified conditions are met, the test program executes a statement which
invalidates the calibration. Like autocal, this does not cause calibration to run. Calibration
begins when the start hsd calibration statement in the test program executes.
See “Calibrating the Digital Subsystem” on page 32-36 in the Catalyst Instrumentation
Manual for more information.
DC Subsystem
Calibrate the DC Subsystem, including all present sources, voltmeter, and DUT sources,
manually using the command:
calibrate [-station #] -dc [file | verbose]
where:
-station # Specifies the test station for calibration.
-dc Switch for DC calibration.
file Sends a detailed summary of the calibration to a log file, date
and time stamped, in the following directory:
/image/tester/<hostname of tester computer>
/dccal_log_<DATE:HR:MN>
verbose Sends a detailed summary of the calibration to the station
window.
This command also calibrates any HCUs in the test system.
As calibration proceeds, messages are displayed on the status of calibration, including:
• Source currently being calibrated
• Reference card serial number
• Date of last calibration of the DC reference
• Result of calibration (passed, failed, or aborted)
Messages are shown in the current station window or in the station window specified using
the -station # option. An example of calibration output is:
% calibrate -dc
Starting calibration of the DC sources
Data Retention Verified
Reference serial number 851721
Last reference calibration on Sept. 12, 1989
Calibrating Voltmeter
Calibrating Source 1
Calibrating Source 2
Calibrating Source 3
Calibrating Source 4
Calibrating Source 5
Calibrating Dut Source 1
Calibrating Dut Source 2
Calibrating Dut Source 3
Calibrating Dut Source 4
Calibration complete
DC source calibration complete
Calibration Functions
IMAGE includes several functions related to DC Subsystem calibration. One of these,
tl_dccal_subr(0), allows you to initiate calibration from a test program. Additional
functions are as follows:
tl_dc_cal_set_interval()
Sets the autocalibration interval (see “Calibration Theory of
Operation” on page 21-3).
tl_dccal_status(inst)
Returns the calibration status of each DC Subsystem instrument
(see page 26-179).
tl_dccal_time() Reads the time since the last calibration and the calibration
status (see page 26-180).
For additional information on DC Subsystem calibration see the DC Subsystem section of
the instrumentation manual appropriate for your tester.
GigaDig
To calibrate the GigaDig from the command line, use the following command:
NOTE
You must calibrate the Time Measurement Subsystem and the DC Subsystem before
calibrating the High Speed Sampler.
You can also initiate ramp calibration using the function call:
tl_hfsc_ramp_cal();
It takes tl_hfsc_ramp_cal() about seven seconds to finish. To maintain accuracy,
recalibrate the sampler every four hours.
Microwave Port
To calibrate the Microwave Port (UWPORT) in the test system manually, use the command:
calibrate [-station #] -uwport
where:
-station # Specifies the test station for calibration.
-uwport Trigger switch for UWPORT calibration.
Microwave Receiver
To calibrate the Microwave Receiver in the test system manually, use the command:
calibrate [-station #] -uwrecv
-station # Specifies the test station for calibration.
-uwrecv Switch for UWRECVV calibration.
You can also calibrate a UWRECV from within a test program. To to calibrate all UWRECVs
in the test system regardless of the last calibration, execute the following ITL statement:
start uwrecv: cal;
To calibrate a specific UWRECV, use:
start pin=<pin_spec> uwrecv: cal;
Microwave Source
To calibrate all Microwave Sources (UWSRCs) in the test system manually, use the
command:
calibrate [-station #] -uwsrc
where:
-station # Specifies the test station for calibration.
-uwsrc Trigger switch for UWSRC calibration.
You can have your test program calibrate the UWSRC using the following statements.
These statements calibrate the UWSRC every time the test program runs.
To calibrate the UWSRC assigned to the pin in <pin ID>, use:
start pin=<pin ID> uwsrc: cal;
The default UWSRC for a pin is the UWSRC assigned to the pin as a channel in the pinmap.
The statement shown above calibrates the specified UWSRC regardless of the last
calibration. To calibrate all UWSRCs in the test system regardless of the last calibration, use
the following statement:
start uwsrc: cal;
Octal VI Source
Use the following syntax to calibrate the OVI Source.
To calibrate every OVI source in the test system, use either of the following:
start ovi cal;
To calibrate each OVI source in OVI_LIST, use:
start ovi=<OVI_LIST>cal;
To calibrate the OVI source behind each pin in PIN_LIST, use:
start pin=<PIN_LIST>ovi:cal;
To calibrate OVI sources from the command line, use:
calibrate -ovi
Precision Multimeter
To ensure that the Precision Multimeter (PMM) meets its rated accuracy specifications, it
must be calibrated regularly. (See the PMM section of the instrumentation manual
appropriate for your tester.) Calibrate the PMM using:
calibrate [-station #] -pmm dcv acv ohms
where:
-station # Specifies the test station for calibration.
-pmm Perform calibration of all the PMM modes. This calibration takes
12 minutes.
dcv Perform calibration on the DC voltage modes of the PMM. This
calibration takes 2.2 minutes.
acv Perform calibration on the AC voltage modes of the PMM. This
calibration takes 1.1 minutes.
ohms Perform calibration on the resistance modes of the PMM. This
calibration takes 11 minutes.
You can specify more than one flag on the command line.
NOTE
Do not interrupt calibration using Control-C. Interrupting calibration returns control to you,
but the PMM will not be calibrated.
You can also calibrate the PMM from within your test program. Use the set pmm cal_mode
statement to tell the PMM which self-calibration routine or routines to run:
set pmm cal_mode: dc; /* run the DCV routine */
set pmm cal_mode: ac; /* run the ACV routine */
set pmm cal_mode: ohms; /* run the OHMS routine */
set pmm cal_mode: (dc ac); /* run DCV and ACV */
set pmm cal_mode: all; /* run all the routines */
You can specify a combination of routines by enclosing them within parentheses separated
by spaces, as in:
set pmm cal_mode: (dc ac); /* run DCV and ACV */
Then use the set pmm cal statement to tell PMM when to run the self-calibration routines
you selected. The choices are:
set pmm cal:off; Do not run PMM self-calibration routines.
set pmm cal:once; Run PMM self-calibration routines each time a set pmm
statement is executed.
set pmm cal:on; Automatically check at the start of each test program run to see
if PMM self-calibration routines are required. (Not currently
supported.)
Normally, PMM self-calibration information is bundled into a single set pmm statement, such
as:
set pmm
cal_mode: all
cal: once;
Calibrate the meter when absolute accuracy is necessary. Calibrate all PMM modes once
every 24 hours. Use the function tl_pmm_dump_cal_times to determine the time of the last
calibration was run for dc, ac, and ohms.
Pulse Driver
To calibrate all Pulse Driver channel cards manually, use the command:
calibrate [-station #] -pulse [file | verbose]
where:
-station # Specifies the test station for calibration.
-pulse Trigger switch for Pulse Driver calibration.
file Sends a detailed summary of the calibration to a log file, date
and time stamped, in the directory:
/image/tester/<hostname of tester computer>
/pulse_log_<DATE:HR:MN>
verbose Sends a detailed summary of the calibration to the station
window.
Pulse Driver calibration occurs immediately after you enter this command.
You can also calibrate the Pulse Driver from within a test program. The statement for
calibrating a specific Pulse Driver channel card is:
start pin=<pin ID> pulse: cal;
The statement for calibrating all Pulse Driver channel cards is:
start pulse: cal;
To calibrate the QVS behind each pin in PIN_LIST, use the statement:
start pin=(PIN_LIST) dps:cal;
NOTE
By default, event line channel calibration is used even when the event line channel is used
for sandcastle output unless you specify sandcastle in the calibration statement.
Time-Jitter Digitizer
The Time-Jitter Digitizer (TJD) is calibrated for:
• Offset between time stamper A and time stamper B
• Interpolator linearity
Calibration Priority
The mainframe portion of ATMS calibration (interpolators and local clock) uses a set of
priorities to decide when to perform calibration. The mixed-signal test head version of the
ATMS mainframe calibration has highest priority, the advanced linear head version has
second priority, and the linear version has lowest priority.
For example, assume a tester is configured such that station 1 is a linear station, station 2
is an advanced linear station, and station 3 is a mixed-signal station. You load a test
program in each station using the -autocal option. You run the program on station 1,
causing TMS mainframe calibration to run completely. You then run the program on stations
2 and 3, and mainframe calibration is executed in each case.
Assume now that the allotted time between calibrations expires. If you run a program, TMS
mainframe calibration is run. Say that program was for the advanced linear head. If you then
run a program on the mixed-signal head, mainframe calibration runs again because the
mixed-signal head has the highest priority. If you run a linear program after the mixed-signal
program, however, and the time interval for autocalibration has not expired, mainframe
calibration will not run. This is because the mixed-signal mainframe calibration just ran, and
it has higher priority.
IMAGE V5.4 and later includes the flag tl_tms_cal_has_run(). This function returns a
value of 1 the first time this flag is read after ATMS calibration. Otherwise, the flag is
assigned a value of 0. You can use this flag to conditionally reprogram your timing only
when necessary.
In IMAGE V5.5 and later, this problem is fixed and the tsets are restored.
where:
-station # Specifies the test station for calibration.
-vhfawg Trigger switch for VHFAWG calibration.
Use the following statement in your test program to calibrate all VHFAWGs in the test
system:
start vhfawg: cal;
Use the following statement in your test program to calibrate a specified VHFAWG in the
test system. pin_spec is the pin connected to the VHFAWG you want to calibrate. The
default VHFAWG for a pin is the VHFAWG assigned to the pin as a channel in the pinmap.
start pin=<pin_spec> vhfawg: cal;
Autocal Examples
The following are two autocal examples.
tl_init()
{
printf("in tl_init(): setting DC cal criteria to 10 seconds for demo\n");
tl_cal_set_inst_crit("dc", "", 10.0, TL_AUTOCAL_TIME);
}
tl_user_preautocal()
{
printf("in tl_user_preautocal()\n");
if (do_cal == 0) {
printf("TEST: setting global ignore cal\n");
tl_cal_set_autocal_mode(TL_AUTOCAL_IGNORED);
printf("TEST: setting do_cal flag to 1\n");
do_cal = 1;
}
}
tl_user_postautocal()
{
printf("in tl_user_postautocal()\n");
if (do_cal == 1) {
printf("TEST: unsetting global ignore cal\n");
tl_cal_set_autocal_mode(TL_AUTOCAL_NOT_IGNORED);
}
}
main()
{
printf("entering main()\n");
if (tl_cal_get_autocal_state() & TL_AUTOCAL_UNCALIBRATED) {
printf("TEST: calibration invalid, skipping tests\n");
}
else if (do_cal == 1) {
printf("TEST: calibration ONLY, skipping tests\n");
printf("TEST: setting do_cal to 0\n");
do_cal = 0;
}
else {
printf("TEST: calibration valid, executing tests\n");
seq1();
sort bin;
}
printf("leaving main()\n");
}
SEQUENCER seq1()
{
/*
test function test test limits test binning
name # low high label fail pass
_____________ ____ ___________ ___________________ _________*/
seq test_dc() $1 >2.9v <3.1v "test dc meter" f(0) p(1);
}
TESTF test_dc()
{
double reading;
Calibrating Source 2
Calibrating Source 3
Calibrating Source 4
Calibrating Source 5
Calibrating DUT Source 1
Calibrating DUT Source 2
Calibrating DUT Source 3
Calibrating DUT Source 4
Calibration Complete
in tl_user_postautocal()
TEST: unsetting global ignore cal
entering main()
TEST: calibration ONLY, skipping tests
TEST: setting do_cal to 0
leaving main()
Device #0 No binning Test time = 0.058 sec
Test program size = 3128K. (text=1096K data=624K malloc data=1408K)
% entering main()
TEST: calibration valid, executing tests
leaving main()
Device #1 Bin #0 Test time = 0.270 sec
Test program size = 3128K. (text=1096K data=624K malloc data=1408K)
entering main()
TEST: calibration valid, executing tests
leaving main()
:
:
:
TESTF test_dc()
{
double reading;
set src=1 vrng=5v v=3.0v force:v;
set meter input: src=1:v vrng=5v;
set power on:dc;
wait 5ms;
reading=read_meter();
set power off:dc;
test reading;
}
Running this program would display the following in your station window (note the bin
numbers):
% load cal_custom_error.tl
...Load in progress
...Reading binary file /u/dcp/progs/cal_custom_error.bin
...Wait (Searching libraries)
...Wait (Loading)
...Load completed.
% loop -on
Test program looping is ON
%
recalibrating DC from my_error_function()
Data Retention Verified.
Reference serial number 0xc5c55
Last reference calibration on Mar. 17, 1994
Calibrating Voltmeter
Calibrating Source 1
Calibrating Source 2
Calibrating DUT Source 1
Calibration Complete
Device #1 Bin #0 Test time = 16.301 sec
Test program size = 1384K. (text=792K data=544K malloc data=48K)
Device #2 Bin #1 Test time = 0.042 sec
Test program size = 1384K. (text=792K data=544K malloc data=48K)
:
:
:
Device #17 Bin #1 Test time = 0.042 sec
Test program size = 1384K. (text=792K data=544K malloc data=48K)
Device #18 Bin #1 Test time = 0.042 sec
Test program size = 1384K. (text=792K data=544K malloc data=48K)
recalibrating DC from my_error_function()
Data Retention Verified.
Reference serial number 0xc5c55
Last reference calibration on Mar. 17, 1994
Calibrating Voltmeter
Calibrating Source 1
Calibrating Source 2
Calibrating DUT Source 1
Calibration Complete
Device #19 Bin #0 Test time = 15.952 sec
Test program size = 1384K. (text=792K data=544K malloc data=48K)
Device #20 Bin #1 Test time = 0.042 sec
Test program size = 1384K. (text=792K data=544K malloc data=48K)
:
:
:
% loop -off
Test program looping is OFF
Syntax Summary
The following is the syntax summary of calibration parameters for the load command:
load [-autocal] [-ignore_cal] [-cal_after] [-nocalfile] [-pinmap_only]
[-frc_calfile]
[-<inst> [cal_type] noautocal ignore_cal nocalfile frc_calfile]
where <inst> can be one or more of:
dc plfsrc plfdig ...
The following is the syntax summary for the calibrate command:
calibrate [-station #] [-autocal | -noautocal] [-ignore_cal | -noignore_cal]
[-cal_after | -cal_before ] [-calfile | -nocalfile ]
[-frc_calfile | -nofrc_calfile ] [-all_copies | -pinmap_only ]
[-report]
calibrate [-station #] -<inst> [cal_type] [autocal | noautocal]
[-station #] -<inst> [cal_type] [ignore_cal | noignore_cal]
[-station #] -<inst> [cal_type] [calfile | nocalfile]
[-station #] -<inst> [cal_type] [frc_calfile | nofrc_calfile]
calibrate [-station #] -dc [file | verbose]
calibrate [-station #] -plfsrc
calibrate [-station #] -plfdig
:
:
:
The instrument list is configuration specific and generated at run-time.
In Catalyst and Catalyst Tiger test systems, some hardware alarms are common to all test
systems while other alarms are dependent on the test system configuration. This section
contains general information for all alarms. For details on alarms for individual instruments,
see the appropriate instrument section in the instrumentation manual for your test system.
An alarm indicates a hardware condition that may invalidate a measurement. These
conditions may be caused by a bad device, an incorrectly programmed instrument, or a test
system hardware malfunction. The action taken when a measurement alarm occurs is under
the control of the test program. Unless otherwise specified, alarms are always enabled.
This section includes the following topics:
• “How Alarms Work” on page 22-2
• “Alarm Checking” on page 22-4
• “Reporting Alarms” on page 22-5
• “Hardware Conditions That Cause Alarms” on page 22-7
• “Alarm Masking” on page 22-17
• “Alarm Programming Examples” on page 22-20
• “Debugging Alarms” on page 22-21
Enabling Alarms
Before you take a measurement, enable alarms and wait for relays to settle. Alarms are
enabled and then immediately cleared during the rdelay() function if any set statement
was executed since the last rdelay. If two rdelay functions are executed in a row, only the
first will enable and clear alarms.
rdelay() calls can be written into the program explicitly, but this is usually not necessary
because the function is automatically embedded in other IMAGE statements.
Disabling Alarms
The set statements disable alarms, causing any alarms generated during the changing
states of the instruments to be ignored. At the simplest level, alarms are disabled by the
function tl_tba_settle(). This function sets the settling timer in the tester in increments
of 100 µs. tl_tba_settle() takes a single integer parameter to indicate the time, where 1
= 100 µs. This function is used by various drivers in the tester when a setup change is made.
The rdelay function calls the corresponding tl_tba_settle_wait function to wait for the
settling timer to expire.
You can insert tl_tba_settle(1); calls in your program directly to disable alarms. This
also ensures that the next rdelay clears alarms. However, we recommend that you use the
set all alarm statement.
Sequencer: main_seq
10 alpha 64 volts (A) 20 beta -4.7 uf
30 gamma 29 kHz 35 binom 3.00
4000 res -63.00 40 delta -63.00
50 epsilon 0.00 mv (A) 60 theta 0.00 ma (A)
Alarm Checking
Catalyst and Tiger test systems are designed to continually check for alarms. However,
since an instrument may trigger an alarm during a setup operation (as in a DC source), a
mechanism is provided to disable alarm checking during this time and to re-enable alarm
checking once an instrument has settled.
Alarms are checked when measurements are taken. In most cases, alarms are checked
throughout the tester. Some examples of statements at which checking occurs are as
follows:
read_meter()
read_tms();
test ac_functional... ;
read_pmm();
Reading the capture memory is a special case because reading capture memory only
checks for capture memory alarms. An alarm in capture memory data indicates that its
associated digitizer detected an alarm or that a parity error exists. Since this information is
retained in memory until it is read, you may not get an indication of an alarm until the
memory is read. The digitizer channel card may alarm, however, in which case it is reported
at the next full alarm check. This feature ensures the integrity of each individual captured
sample.
NOTE
Capture memory may also be noted as dig_cap, lfdig, hfdig, and plfdig.
Reporting Alarms
By convention, IMAGE displays alarm messages to the terminal or console window from
which you started IMAGE. This is not always possible, however, when running under CDE.
The Alarm Manager collects messages that would normally go to the console window and
displays them in a common window.
This feature allows you to direct these messages to any of the following outputs:
• The window from which you started IMAGE (if possible)
• The Alarm Manager window
• The IMAGE_alarm_manager.log file
You control the output of console messages by including lines in the .Xdefaults file in your
home directory. The lines are in the format:
property: setting
You can set the following properties to control Alarm Manager’s behavior:
image.alarm_manager.use_alarm_manager
use_alarm_manager redirects IMAGE and system messages to
the Alarm Manager.
do_not_use_alarm_manager makes no change to where
messages are sent. (IMAGE error messages go to the window
from which you started IMAGE, if possible, and system
messages go to the console window, if possible.) This is the
default setting.
image.alarm_manager.screen_output
Terminal sends messages to the window from which you
started IMAGE. This is the default setting.
GUI sends messages to the Alarm Manager GUI window.
image.console.tester_output_action
Open causes the Alarm Manager GUI window to open to display
each new message. This is the default setting.
Beep sounds a beep for each new message.
image.production.error_alarm_handling
screen_display sends messages to the screen (as specified in
other Alarm Manager properties). This is the default setting.
record_in_log writes the messages to the log file but does not
display them on the screen. The property
image.alarm_manager.screen_output has no effect if you
specify this setting.
screen_and_log displays messages on the screen and writes
the messages to a log file.
If you omit any of these properties from your .Xdefaults file, IMAGE uses the default value
for the property you omitted.
To select a message in the display, click anywhere on the message line.
Alarm Manager provides two buttons you can use to manage the list of messages:
• To acknowledge the selected message, click the ACK button.
• To remove the selected message from the list, click the DEL button.
You can change Alarm Manager’s display in a number of ways.
To select which of the detail columns (STATE, DATE, TIME) Alarm Manager should display,
select OPTIONS, then select the appropriate column title. This is a toggle; Alarm Manager
displays those columns with a check beside their names in this list.
Alarm Manager can insert new messages at the top or bottom of the list. To modify this
behavior, select OPTIONS, then choose INSERT NEW ALARMS AT TOP or INSERT NEW ALARMS
AT BOTTOM.
AC Instrumentation
1 GHz Very High Frequency Digitizer 4 4
Broadband AC Digitizer
Broadband AC Source
Floating point exceptions
GigaDig 4 4
DC Instrumentation
Advanced Analog Pin Unit 4 4
DC measurement system 4
DC sources 4
Digital Instrumentation
Capture memory
Large vector memory 4 4
Source memory
Measurement Instrumentation
Low Current Ammeter 4
Time-Jitter Digitizer 4
Time-Jitter Analyzer 4
Other Instrumentation
Serial Bus Channel Card
Stored data bits (SDB)
Tester support circuitry 4 4
AC Instruments
GigaDig
The GigaDig can generate the following alarm:
data The data sent from the digitizer’s capture memory have an
associated over-range alarm condition.
DC Instruments
DC Measurement System
The DC Measurement System refers to the voltmeter and its various inputs and modes of
operation. As with source alarms, the specific alarm types are unlatched. A general report
indicates a past unlatched condition that no longer exists. A specific report indicates that the
unlatched condition continues to be generated. Four alarms are possible:
vm1 guard Voltmeter 1 (vm1) guard current exceeds ±1mA.
vm2 guard Voltmeter 2 (vm2) guard current exceeds ±1mA.
dgs Deviation ≥0.25V from chassis ground.
adcomp A/D converter over-range.
DC Sources
Most test systems can be configured with up to nine sources: four DUT sources and five
matrixed sources. Associated with each source are three unlatched alarms and a latched
alarm data bit. Whenever an unlatched condition occurs (as described below), the latched
data bit is set. Therefore, a source alarm can occur without a specific type description of
what caused it. This feature reports transient conditions that may occur during a
measurement. If a type is reported, the unlatched condition it represents is still occurring.
DC source alarms include
output The source has encountered an illegal range, an overheat
condition exists (>90°C), or an open loop condition exists.
guard A current ≥ ±1mA on the guard exists.
Delta Bus
A Delta Bus alarm indicates that the output deviates more than ±0.6V from the nominal
value of the D/A output.
OVI Open Loop Alarm An open loop alarm indicates one or more of the following. The
control loop cannot be satisfied when slewing, or the
programmed state cannot be satisfied with a given load. The OVI
source can be programmed to operate outside the specified
power limits. See section 7.0 in the “Octal V/I Source”
specifications. While modulating the OVI output, the sum of the
programmed dc value and adjusted wave bus signal may have
exceeded the maximum allowable amplitude as defined in the
OVI specifications. The current clamp can be programmed to a
value less than the offset current into an open load. See section
4.3 in the “Octal V/I Source” specifications for offset current
values for OVI current ranges.
Local Meter Overrange Alarm
An overrange alarm indicates that the voltage or current being
measured is greater than the programmed voltage or current
metering range. See vrng, irng, and amm_gain programming
instructions.
open loop The programmed voltage and current conditions can not be
satisfied by the loop control.
Digital Instruments
Capture Memory
Capture memory alarms can occur during movement of data from a digital capture memory
to another part of the test system. Only at this time are any capture memory alarms
reported, and they are only for the capture memory being read. The alarms are:
data The data from the digitizer has an alarm condition associated
with it.
parity A parity error exists in the section of capture memory just read.
This may reflect a real test system hardware problem or may be
DCB (dig_src)
The only error that can occur on the digital source is a parity error in the data transferred
from the s_mem:
parity Indicates either a bad data path between the s_mem and DCB
or a fault on either one. This error cannot be masked.
Source Memory
The only error that can occur in source memory results from faulty test system hardware:
parity The microcode memory in the s_mem has a parity error. This
can only be caused by a faulty s_mem. This error cannot be
masked.
Measurement Instruments
Precision Multimeter
The PMM supports five types of alarms. Four are related to the channel card (these alarms
are not supported on test systems without test heads), and the fifth is an overrange alarm.
The a and b designators specify which PMM channel pair is involved.
iout_a | iout_b Indicates overcurrent conditions on the guard driver outputs for
PMM channel A or B. If this alarm occurs, the guard drivers are
disabled.
vin_a | vin_b Indicates overvoltage conditions on the guard driver inputs from
PMM channel A or B. If this alarm occurs, the guard drivers are
disabled.
range Indicates an overrange condition. If this alarm occurs, the
number 1E+38 is returned.
Time-Jitter Digitizer
The Time-Jitter Digitizer (TJD) will time out and produce an alarm if all the expected
samples are not captured within a specified period of time. There is an alarm type for each
way that a data capture timeout can occur:
tjd_a_start_timeout A stamper did not start stamping events.
tjd_a_stop_timeout B stamper did not finish stamping events.
tjd_b_start_timeout A stamper did not start stamping events.
tjd_b_stop_timeout B stamper did not finish stamping events.
tjd_ab_start_timeout A and B stamper did not start stamping events.
tjd_ab_stop_timeout A and B stamper did not finish stamping events.
tjd_a_start_b_stop_timeout
A stamper did not start and B stamper did not finish.
tjd_b_start_a_stop_timeout
B stamper did not start and A stamper did not finish.
Time-Jitter Analyzer
The Time-Jitter Analyzer (TJA) will time out and produce an alarm if all the expected
samples are not captured within a specified period of time. There is an alarm type for each
way that a data capture timeout can occur:
tja_a_start_timeout A stamper did not start stamping events.
tja_a_stop_timeout B stamper did not finish stamping events.
Other Instruments
Stored Databits
A stored databit alarm indicates that an overload (>200mA) has been detected.
Alarm Masking
Test program syntax is available to mask alarms. Masking an alarm causes the test system
to ignore that alarm. At the beginning of a program all alarms are enabled (except where
noted for a particular instrument). To make the tester ignore an alarm, you must disable it
in the test program. You can also enable a previously masked alarm.
Note that masking an alarm results in longer test times. Ignoring a masked alarm is more
time-consuming for the software than checking for that alarm. Therefore, masking alarms,
especially masking all alarms, is not advisable in most circumstances.
The syntax for alarm masking and enabling is:
where:
ignore Ignores an alarm if one occurs.
force_fail Forces the test to fail if an alarm occurs.
force_bin Forces the test to bin if an alarm occurs.
default Sets the alarm to the default condition.
<instr> Is one of the test system instruments listed in table 22-2.
<alarm_type> Is one of the alarm types for the instrument listed in table 22-2.
Instrument
Instrument Alarm Types
Syntax
Instrument
Instrument Alarm Types
Syntax
Instrument
Instrument Alarm Types
Syntax
Debugging Alarms
The following statements always clear (and enable) alarms:
tl_tba_settle(1);
rdelay();
You can poll for alarms by calling the following function:
tl_alarmcheck(0);
This can be called only when alarms are enabled. If you call this function when alarms are
disabled, you get the following error message:
ERROR #1506—Alarmdriver: no rdelay() since last relay was programmed
A lower level function is available to debug the alarm driver itself. It provides more detail on
alarms but is also partly obsolete. The function call is
tl_alarminfo();
This causes the following information to be printed in the station window after you have
executed set statements, but not rdelay:
gate word 0x0000
user alarms are enabled
Warning: hardware and software masks differ!
tl_alarm_cleared is FALSE (setup alarms still outstanding!)
status hi tbus 0x0000
status low tbus 0x0002
vector bus 0x0000
conv cage 0x0000
test head 1 0x0000
System is Safe
Ignore the following warning:
Warning: hardware and software masks differ!
This message is obsolete. No alarm is present in this example. Another example is:
gate word 0x8107 alarms enabled
user alarms are enabled
tl_alarm_cleared is TRUE (setup alarms cleared)
status hi tbus 0x0000
status low tbus 0x0003 alarming
vector bus 0x0000
conv cage 0x0000
test head 1 0x0001 alarming
System is Safe
The rdelay function was executed (alarms were cleared), but an alarm is present in test
head 1 and on the low speed terabus. The test head data bus is on the low speed terabus,
so the alarm is reflected there also. tl_alarmcheck(0); can now be called to identify the
alarm.
Chan_num
char
CLK_DLY_MODE
CLOCK_AC_CAGE
CLOSE
CMPHI_START
CMPHI_STOP
CMPLO_START
CMPLO_STOP
CMPL_SURND
CMP_STOP
cmu
COMPLEX
compute
connect
const
continue
conv
convert_offset_binary_to_r
create_list
cvadd
cvcomb
cvconj
cvexp
cvmags
cvmagsd
cvmov
cvmul
cvneg
cvrcip
cvsub
c_mem
c_mem_alt
C_MEM_READ_ALARM
C_MEM_READ_NOCLOCK
C_MEM_READ_NOTRIG
C_MEM_READ_PARITY
C_MEM_READ_SUCCESS
d0
d0b
d1
d2
d3
d3b
databits
datalog
dchan
decimal_mode
decimal_record
decimal_string
default
delta
deskew
device_bins
dibname
dig_cap
dig_cap_alt
dig_instrument
dig_src
dig_src_alt
disconnect
diu
do
dotpr
double
download
dpin
dps
dpu
DRV_START
DRV_STOP
dsf
dsio_instrument
dsp
DSPBUFFER
DSPMC
DSPSOFT
DSPZIP
dsys
duthcu
dutsrc
dutsrc100
dutsrc200
dut_trig_in
D_COMPLEX
ecms
edgefind
else
emt
emt_region
emt_subregion
enlfsrc
enlfsrc_alt
enum
error
expert_inst
extended
extern
ext_trig
FAILED
FALSE
fftwts
fftwtsd
FIELD
FILE
float
FMT_CAGES
FMT_CMPHI
FMT_CMPLGC
FMT_CMPLO
FMT_CMPMID
FMT_CMPPAT
FMT_COND_DISABLE
FMT_COND_FAIL
FMT_COND_LOGIC
FMT_ENABLE
FMT_FAIL
FMT_FAIL_DISABLE
FMT_FAIL_ENABLE
FMT_FHI
FMT_FLO
FMT_HIZ
FMT_LOGIC
FMT_NONE
FMT_NRZ
FMT_RZ
for
fpos_t
fp_exception_field_type
fvs
ghsd
goto
gpib
hamm
hammd
handler
hannd
hann
hbin
hccs
hclk
hcu
hcvs
hfdig
hfsrc
hfsrc_alt
hf_sampler_control
HIGHEST_CHAN_NUMBER
hist
histd
HIZ_START
HIZ_STOP
hpvi
hp_xpt
hsd
hsd50
hsd50_alt
hsds
HSD_FMT_BASE
HSD_NOHALTCODE
HSD_NOREADCODE
HSD_PATRUNNING
HSD_TVAL_CMP_START
HSD_TVAL_CMP_STOP
HSD_TVAL_DRVCMP_START
HSD_TVAL_DRVCMP_STOP
HSD_TVAL_DRV_START
HSD_TVAL_DRV_STOP
HSD_TVAL_HIZ_START
HSD_TVAL_HIZ_STOP
hva
hvs
idfb
if
inst_usage
int
kernel
laser
LA_LEVEL_HIGH
LA_LEVEL_LOW
LA_LEVEL_MID
LA_LEVEL_UNKNOWN
LA_PLOT_DATA
lca
lfacdig
lfacsrc
lfdig
lfdig_alt
lfsrc
lfsrc_alt
load
long
lveq
lvge
lvgt
lvne
lvnot
margin
MAXBIN
maxmgv
maxv
maxvi
MAX_A500_HEADS
MAX_AL_HEADS
MAX_DUTPINS
MAX_H50_CHANLIST
MAX_HEADS
MAX_HSD_CHAN
meamgv
meanv
measqv
measure
meter
minmgv
minv
minvi
mmul
modify
move
mtrans
M_CLK
M_CLK_ALT
M_CLK_AUX1
M_CLK_AUX2
ndutsrc
NO
NORESULT
NO_BINNING
nsrc
of
OFF
ON
opamp
OPEN
ost
ovi
pad
PASSED
pclock
pgu
pin
PINLIST
PINLIST_ENTRY
PINMAP
PINMAP_ENTRY
PINMAP_WORDS
plfdig
plfsrc
plfsrc_alt
pmm
polar
power
proto
pulse
pvmeter
pvsrc
pwrsrc
quadruple
r1
r2
read_laser
rect
refsrc
register
reset
resume
retrieve
return
rfft
rfft2d
rfftb
rfftd
rfftm
rfftsc
rfftscd
rfu
rmmul
rmsqv
rmtran
rt_histo
RT_HISTO_CAPTURE_DONE
RT_HISTO_CAPTURING
RT_HISTO_HISTO_OVERFLOW
RT_HISTO_NO_CAPTURE
RT_HISTO_NO_TRIG
RT_HISTO_PAGE_ERROR
RT_HISTO_WHISTO_OVERFLOW
RT_HISTO_W_CTR_OVERFLOW
save
schan
scm
sdig
SEGMENT
seq
SEQUENCER
SEQ_DATA
SEQ_DATA_STR
serial
serial_all
serial_disabled
serial_failed_sequencer
serial_max_sites
serial_sleep
set
setup
shmoo
short
sigfpe_code_type
sigfpe_handler_type
signed
single
sizeof
size_t
sleep_mode
slot
sort
specs
SPOT_PULSE
sps
sps_tgen
src
start
START_CLK
static
STDF_CUSTOM_BASELINE
stop
STOP_CLK
struct
subbus
supclk
sve
sved
svemg
svesq
svessq
svs
SWEEP_OFF
SWEEP_ON
switch
S_FMT
S_JOBNAME
S_LOTNAME
s_mem
s_mem_alt
S_MEM_STATUS_BUSY
S_MEM_STATUS_IDLE
S_MEM_STATUS_PRC
S_MEM_STATUS_SRC
S_OPNAME
S_STDF_STRING
S_TNAME
t_delay
t_mem
T0_CLK
T0_CLK_DIV
TB_REG
test
TESTF
testf_cond
test_conditions
tgen
TIMSPEC
tja
tjd
TJD_STATUS_AB_MEAS_NOT_COM
TJD_STATUS_AB_MEAS_NOT_STA
TJD_STATUS_A_MEAS_NOT_COMP
TJD_STATUS_A_MEAS_NOT_STAR
TJD_STATUS_B_MEAS_NOT_COMP
TJD_STATUS_B_MEAS_NOT_STAR
TJD_STATUS_MEAS_A_NOT_STAR
TJD_STATUS_MEAS_B_NOT_STAR
TJD_STATUS_MEAS_COMPLETE
TJD_STATUS_SET_SINCE_LAST_
tms
tmschan
to
trigger
TRUE
TSET_RTR
typedef
t_delay
t_mem
uhfmm
uhfsrc
UNDEFINED
union
unload
unsigned
uwport
uwrecv
vabs
vadd
vaddd
vaint
valog
vam
vandi
vatan
vatan2
vclip
vclr
vclrd
vcos
vcosd
vdiv
vdivd
vdpsp
veqvi
vexp
vexp10
vfill
vfix
vfix32
vfix32d
vfixd
vfloat
vfloatd
vflt32
vflt32d
vhfawg
vhfcw
vhfmm
vimag
vlim
vln
vlog
vlog10
vma
vmax
vmaxmg
vmcu
vmin
vminmg
vmov
vmovd
vmsa
vmsb
vmul
vmuld
vneg
vnegd
void
volatile
vori
vpoly
vramp
vrampd
vreal
vrvrs
vsadd
vsaddd
vsbm
vsdiv
vsdivd
vsin
vsind
vsma
vsmsa
vsmsb
vsmul
vsmuld
vspdp
vsq
vsqrt
vsqrtd
vssq
vsub
vsubd
vsum
wafer
wait
wdig
wfcap
wfsrc
wgen
while
xpt
YES
_h_val
_dsp_types_
__va_list
In addition, all words beginning with tl_, tt_, TL_, or TT_, are reserved everywhere.
The following words are reserved in a dpin or deskew statement (A500 and A540):
close
cmp
drv
drvcmp
format
hiz
hotclose
hotopen
ioh
iol
isdn
muxmode
open
rcv
time_src
tset
vcp
vih
vil
voh
vol
IMAGE Pattern Language (IPL) has a separate set of reserved words that is different from
IMAGE Test Language (ITL). One key difference between IPL reserved words and ITL
reserved words is that IPL is not case-sensitive. So if VHFAWG is reserved, vhfawg, Vhfawg,
VhFaWg, and every other capitalization of VHFAWG is also reserved.
ALL
ANALOG
AND
CALL
CHAN
CLR_CODE
CLR_COND
CLR_FAIL
CLR_FLAG
CPU
DECR
DIB
DIG_CAP
DIG_CAP_ALT
DIG_SRC
DIG_SRC_ALT
D_IN
D_INOUT
D_OUT
DRV
DRV_RCV
ENABLE
END_ARG
END_LOOP
END_LOOP1
END_LOOP2
EXE_ARG
EXE_GLO
EXIT_LOOP
EXT
EXTERN_LABEL
EXTERN_PRAM_LABEL
EXTERN_SCAN_HEADER
EXTERN_SCAN_TRAILER
EXTERN_SCAN_SUBR
FAIL
FIELD
FILETYPE
FLAG
FMT
GLOBAL
HALT
HALTCODE
HEADER
HFDIG
ICYC
IF
INST
JMP_GLO
JMP_PRAM
JMP_SAM
JUMP
KEEP_ALIVE
LD_NOP
LOOP
LOOP1
LOOP2
MASK
MATCH
NEXT
NEXT1
NO_HALT
NONE
OR
OUTPUT_FILENAME
PASS
PINMAP
PINMAP_FILENAME
PLFDIG
PLFSRC
POP
POP_LOOP
PUSH
Q2
QUAL
RCV
READCODE
REALIGN
REPEAT
RESYNC
RETURN
RT_HISTO
SAM_ADDR0
SAM_ADDR1
SCAN
SCAN_CHAIN
SCAN_DEFAULT
SCAN_HDR
SCAN_HDR_VAR
SCAN_IN_PIN
SCAN_OUT_PIN
SCAN_PINS
SCAN_SETUP
SCAN_SUBR
SCAN_TEMPLATE
SCAN_TLR
SCAN_TLR_VAR
SCAN_TYPE
SCF
SEND
SEND10
SET_GLO
SET_LOOP
SET_LOOP1
SET_LOOP2
SET_SCF
SHIFT
SLOT
START
START1
STARTE
STARTE1
STOP
STOPE
STORE
TO
TRAILER
TRIG
TSET
TST1
TST2
VBC
VBC_STR
VBMS_INC
VECTOR
VHFAWG
WAVEFORMS
The following words are reserved in some or all places in a Catalyst high speed digital
pattern source file. Do not use them as pin names in a pattern file or for pattern label names.
An asterisk (*) denotes reserved words in Catalyst that do not exist in the advanced mixed-
signal IPL reserved word list. You must be aware of them when porting advanced mixed-
signal patterns to Catalyst.
A0_DEC
A0_INC
*ADD
*ADSS
*AI
ALL
*ALROT
AND
CALL
CHAN
CI
CLR_CODE
CLR_COND
CLR_FAIL
CLR_FLAG
*COND_ON
CPU
*DATA
DECR
DIB
DIG_CAP
DIG_CAP_ALT
DIG_SRC
DIG_SRC_ALT
*EMT
ENABLE
END_ARG
END_LOOP
END_LOOP1
END_LOOP2
*END_MODULE
*ETRAP
EXE_ARG
EXE_GLO
EXIT_LOOP
EXT
EXTERN_LABEL
EXTERN_PRAM_LABEL
EXTERN_SCAN_HEADER
EXTERN_SCAN_SUBR
EXTERN_SCAN_TRAILER
FAIL
FIELD
FILETYPE
FLAG
FMT
GIGADIG
GLOBAL
*GLOBAL_START
HALT
HALTCODE
HEADER
HFDIG
*HRAM_EN
*ICC
ICYC
IF
*IFC
INST
*INVC
JMP_GLO
JMP_PRAM
JMP_SAM
*JTRAP
JUMP
KEEP_ALIVE
*LDNEXT
LD_NOP
*LFACDIG
*LFACSRC
LOOP
LOOP1
LOOP2
MASK
MATCH
*MAX_T0
NEXT
NEXT1
NONE
*NOP
NO_HALT
*OP
OR
OUTPUT_FILENAME
PASS
*PASSA
*PASSB
PINMAP
PINMAP_FILENAME
PLFDIG
PLFSRC
POP
POP_LOOP
PUSH
Q2
QUAL
READCODE
REALIGN
REPEAT
*RESET
RESYNC
RETURN
*RF
*ROT
RT_HISTO
SAM_ADDR0
SAM_ADDR1
SCAN
SCAN_CHAIN
SCAN_HDR
SCAN_HDR_VAR
SCAN_IN_PIN
SCAN_OUT_PIN
SCAN_PINS
SCAN_SETUP
SCAN_SUBR
SCAN_TEMPLATE
SCAN_TLR
SCAN_TLR_VAR
SCAN_TYPE
SCF
SEND
SEND10
*SETMOV
*SETROTL
*SETROTR
SET_GLO
SET_LOOP
SET_LOOP1
SET_LOOP2
SET_SCF
*SET_TRAP
*SHFTL
*SHFTR
SHIFT
*SKIP1
*SKIP3
SLOT
*SLOW_PIN
START
START1
STARTE
STARTE1
STOP
STOPE
STORE
*SV0C
*SVC
*SVOUT
*SVOUTH
*SVOUTL
*SVRLT
*SYNC
TO
TRAILER
TRIG
TSET
TST1
TST2
*USEC
VBC
VBC_STR
VBMS_INC
VECTOR
VHFAWG
WAVEFORMS
*WRF
*WRINP
*WRRLT
*XEXT
*XFAIL
*XOR
Communication is easiest when all participants speak the same language. Following this
precept, Teradyne developed a standard data format that any tester can use to store test
results. Called the Standard Test Data Format (STDF), this standard establishes the basis
for flexible communications between A5xx and Catalyst test systems and other test
systems, database management systems, and data analysis software. IMAGE V6.4 and
later conforms to STDF V4.
A file structured according to the Standard Test Data Format is called an STDF file. IMAGE
uses an STDF file to store test data associated with a particular lot or group of devices.
IMAGE constructs this file from a set of software data structures called STDF records. In the
fields of these STDF records, IMAGE stores its test data.
This section covers the following STDF topics:
• “Generating STDF Files” on page 24-2
• “Sources for STDF File Data” on page 24-4
• “STDF Records” on page 24-6 explains how IMAGE uses STDF records to build STDF
files.
• “IMAGE STDF Record Set” on page 24-11 describes the data fields for each STDF
record supported by IMAGE V7.0.
• “Reading, Writing, and Processing an STDF File” on page 24-39
This appendix focuses on STDF information specific to A5xx and Catalyst test systems. It
provides additional information on the way the test system collects and formats test data.
For a general discussion of IMAGE data collection, see “Data Collection” on page 6-1.
For general information on the Standard Test Data Format, see “Introduction to STDF” on
page 1-1 in the STDF Specification Manual. For a comprehensive understanding of the
Standard Test Data Format, read both this appendix and the STDF Specification Manual.
If you turn on both datalogging and histogramming, IMAGE generates a single datalog
STDF file and a single histogram STDF file.
IMAGE constructs datalog and histogram files in the same way using the same set of STDF
records. Therefore, if you turn on both datalogging and histogramming with identical
options:
datalog -on -stdf -test all
histoset -on -test all
you generate two identical STDF files.
NOTE
Since IMAGE constructs datalog and histogram STDF files in the same way, it cannot
differentiate between them. Therefore, you can generate a histogram from either a
histogram or datalog STDF file.
Table 24-1. Correspondence Between Sequencer Statement Values and STDF Record Fields
Some test data originates from test program utility functions. For example, the function
tl_set_lot_id() provides IMAGE with a value for STDF record field LOT_ID.
tl_write_highlim() provides IMAGE with the upper limit for the current test, which it
stores in STDF record field HI_LIMIT. See “Base IMAGE Functions” on page 26-1 for a list
and description of program utility functions that provide IMAGE with test data values for
STDF record fields.
Some test data originates from IMAGE commands. For example:
• The lot command provides values for STDF record fields LOT_ID, SBLOT_ID, and
STAT_NUM
• The operator command provides an operator name for STDF record field OPER_NAM
• The testcond command provides a test code value for STDF record field TEST_COD
For information on how a particular STDF record field is set in an STDF file, contact
Teradyne Applications Engineering.
STDF Records
An STDF file is organized as a collection of STDF records appended one to another.
Serving as building blocks for STDF files, STDF records vary in type and size. For general
information on the characteristics of each STDF record in the complete STDF record set,
refer to the “STDF Record Types” chapter in the STDF Specification Manual. For specific
information on how IMAGE 7.0 supports and implements STDF records, see “IMAGE STDF
Record Set” on page 24-11.
1. For Catalyst 400 systems, the FTR may be two records, an FTR and an FTR-PLUS. For more information,
see section on page 24-16.
STDF File
FAR One per STDF file
MIR
SDR
PIR For first part tested
BPS
One pair for each PTR, FTR, or One per test; record type
sequencer function MPR corresponding to test type
EPS
One pair for PRR
For nth part
each device tested PIR
BPS
PTR, FTR, or One per test; record type One pair for
MPR corresponding to test type each device
EPS lot
PRR
SBR Summary Report Records
HBR
TSR
PCR
MRR
• Before IMAGE closes an STDF file following an end of lot, it writes a set of summary
records:
– Software Bin Records (SBR) for each software bin
– Hardware Bin Records (HBR) for each hardware bin
– Test Synopsis Records (TSR) summarizing results for each sequencer line
executed
• Once the summary records are written, IMAGE writes a Part Count Record (PCR) and
a Master Results Record (MRR) for the lot to the STDF file and closes it.
In STDF V4, the first PTR or FTR confirms static or global data for a particular test.
Examples are: limits, limit format, and result scaling factor. If this data should change,
subsequent PTRs and FTRs will contain the modified data. Figure 24-2 shows how records
are arranged in an STDF file.
STDF File
FAR User opens an STDF file
MIR User turns on datalogging or opens new device lot with startlot command
SDR
PIR IMAGE begins executing test program, begins testing first device.
BPS IMAGE encounters SEQUENCER all_tests() function in user test program
PTR IMAGE writes result of leak_vcc() test. IMAGE generates one PTR.
PTR IMAGE writes result of lcap_vcc(). IMAGE generates one PTR.
FTR IMAGE writes result of functional_test(). IMAGE generates one FTR.
FTR IMAGE writes results of dig_leak().
MPR IMAGE writes results of dig_leak() if leakage datalog is enabled (AMS HSD50 only).
DTR IMAGE encounters lprintf() statement.
PTR IMAGE writes result of ac_rip() test. IMAGE generates one PTR
EPS IMAGE encounters end of SEQUENCER all_tests() function
PIR IMAGE re-executes test program, begins testing next device
PRR main() function of test program exits
SBR IMAGE receives endlot signal from handler or user issues summary -final command
SBR
main()
SBR {
- all_tests();
Test Program
HBR sort bin;
HBR }
HBR SEQUENCER all_tests()
- {
TSR seq leak_vcc() $1 >10v <50v "leakage" f(0);
TSR seq lcap_vcc() $2 >0uf <2e-05uf "lcap" f(2);
seq dig_leak() $3 <100ua f(4);
TSR
seq functional_test();
- lprintf("AC test is next");
PCR
MRR seq ac_rip() $(tnum) >20khz <30khz "ac rip" f(3)p(1);}
Header fields
REC_LEN Bytes of data following header
REC_TYP Record type (15)
At the top of each STDF record are header fields that serve as the record’s identification.
Collectively known as an STDF record header, these header fields are named REC_LEN,
REC_TYP, and REC_SUB.
Header Fields
• REC_LEN specifies the number of bytes of data in a record following the record header.
Stated mathematically:
Record_size = size of STDF record, expressed as number of bytes
Header_size = size of STDF record header = 4 bytes
REC_LEN = Record_size – Header_size = Record_size – 4
• REC_TYP contains an integer value identifying record type. For example, IMAGE collects
test data for Parametric Test Result Records (PTRs) and Functional Test Result
Records (FTRs) after each test execution. No other STDF records have this
characteristic. To indicate that PTR and FTR are the only records of this type, IMAGE
sets their REC_TYP field to integer value 15 (using STDF conventions) and sets the
REC_TYP field for all other STDF records to values other than 15. Each REC_TYP setting
conforms to STDF specifications, as stated in “Record Types and Subtypes” on page
2-3 of the STDF Specification Manual.
• REC_SUB contains an integer value identifying a specific STDF record of a given type
(REC_TYP). For example, both STDF records PTR and FTR are of the same type
(REC_TYP=15). IMAGE distinguishes PTRs from FTRs by setting the REC_SUB field for
all PTRs to integer value 10 and the REC_SUB field for all FTRs to integer value 20. As
with REC_TYP fields, each REC_SUB setting conforms to STDF specifications, as stated
in “Record Types and Subtypes” on page 2-3 of the STDF Specification Manual.
Each STDF record in the STDF record set can be uniquely identified by the integer value in
its REC_TYP and REC_SUB field. Consequently, Parametric Test Result Records can be
identified by name (Parametric Test Result Record), by acronym (PTR), or by their record
identifier fields (REC_TYP=15, REC_SUB=10).
STDF name assigned Short description of data yes = IMAGE V7.0 supports the field.
to field assigned to field
no = IMAGE V7.0 does not support the field.
Supported by Data
Field Name Field Description IMAGE V7.0? Type
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
For more information, see “Begin Program Section Record (BPS)” on page 3-55 in the
STDF Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
For more information, see “Datalog Text Record (DTR)” on page 3-60 in the STDF
Specification Manual.
beginning and an EPS marks its end. IMAGE writes an EPS to all open STDF files
immediately before returning from a sequencer function call.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
In versions of IMAGE before V5.6, if a test failed or a run-time error occurred, an End
Program Section record (EPS) was not generated for the failing sequencer. In V5.6 and
later, you can optionally modify this behavior and have an EPS record written to the datalog
stream.
To datalog an EPS record, call the function tl_datalog_endseq_on_fail() and pass it a
nonzero value. To turn this feature off, call the same function with an argument whose value
is zero.
By default IMAGE will not datalog an EPS record when a test fails or encounters a run-time
error.
For more information, see “End Program Section Record (EPS)” on page 3-56 in the STDF
Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
CPU_TYP
Indicates which type of CPU wrote this STDF file. IMAGE sets CPU_TYP to 1. According to
STDF specification, CPU_TYP=1 implies that Sun 1, Sun 2, Sun 3, or Sun 4 computer wrote
this STDF file.
STDF_VER
Identifies which version of the STDF specification IMAGE used when generating STDF files.
Allows data analysis programs to handle STDF specification enhancements.
For more information, see “File Attributes Record (FAR)” on page 3-5 in the STDF
Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
FAIL_PIN
Encoded with PMR index 0 in bit 0 of the field, PMR index 1 in the first position, and so on.
Bits representing PMR indexes of failing pins are set to 1.
For more information, see “Functional Test Record (FTR)” on page 3-49 in the STDF
Specification Manual.
The definition of the IMAGE FTR-PLUS Record can be found in the header file
image_data_recs.h, located in the directory $IMAGEBIN/itlh. It is defined as follows:
a. typedef struct
{
unsigned short rec_len; /* Bytes of data to follow */
unsigned char rec_typ; /* Record Type */
unsigned char rec_sub; /* Record sub-type */
unsigned int test_num; /* Test number */
unsigned char head_num; /* Test head number */
unsigned char site_num; /* Test site number */
unsigned short pgm_icnt; /* Count of programmed state indexes */
unsigned short *pgm_indx; /* Array of programmed state indexes */
char *pgm_stat; /* Array of programmed states */
} IMAGE_FTR_PLUS;
The datalog formatters (including custom datalog formatters) treat a pair of FTR-PLUS and
FTR Records as one FTR. Since the internal memory representation of the existing FTR
uses a full 8 bits to store the 4 bits of data, existing formatters need only be relinked to the
new datalog formatter base code to work with the new records.
NOTE
If your code explicitly masks the pgm_stat 8-bit code with 0xF to force it to 4 bits, or if it
makes any other hard-coded assumptions that the data is no greater than 0xF, then this
code must be modified to work with the new records.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
HEAD_NUM
If this HBR contains a summary of the hardware bin counts for all test sites, this field must
be set to 255.
HBIN_NUM
Legal values range from 0 to 32767.
HBIN_PF
This field indicates whether a hardware bin was a passing or failing bin. Valid values are:
P = Passing bin
F = Failing bin
space = unknown
For more information, see “Hardware Bin Record (HBR)” on page 3-13 in the STDF
Specification Manual.
the File Attributes Record (FAR). IMAGE writes an MIR to all open STDF files in response
to either of two events:
• Selecting the STDF file as the destination for the datalog. (DATALOG TO STDF FILE: ON)
• Opening a new device lot with the startlot command.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
SETUP_T
Specifies when datalogging began. IMAGE represents data and time as the number of
seconds since midnight, January 1, 1970, adjusted for local time.
START_T
Specifies when first device was tested. IMAGE represents data and time as the number of
seconds since midnight, January 1, 1970, adjusted for local time.
PROT_COD
User-defined field indicating the protection desired for the test data being stored. Valid
values are the ASCII characters 0–9 and A–Z. A space in this field indicates a missing value
(default protection).
CMOD_COD
Indicates the tester command mode during testing. You or IMAGE define command mode
values. Valid values are the ASCII characters 0–9 and A–Z. A space indicates a missing
value.
TSTR_TYP
Identifies the type of tester performing the tests, such as A500 or A510.
TEST_COD
Specifies the phase of device testing or test conditions, such as WFR for wafer test or HOT for
hot test.
The testcond command sets the TEST_COD field. For example:
testcond HOT
sets TEST_COD to HOT. Valid characters for TEST_COD are ASCII characters 0–9 and A–Z.
For a test code of less than three characters, IMAGE inserts the test code into a TEST_COD
field left justified and padded with spaces.
TST_TEMP
The test temperature is an ASCII string. Therefore, it can be stored as degrees Celsius,
Fahrenheit, Kelvin, or any other scale. It can also be expressed in terms like HOT, ROOM, and
COLD.
For more information, see “Master Information Record (MIR)” on page 3-7 in the STDF
Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
RTN_INDX
The values used are:
5 = Failed low
6 = Failed high
2 = midband == PASSED
The RTN_INDX values are the same values that you would expect to find for the FTR
record, that is, channel number indexes not pin map record indexes.
For more information, see “Multiple-Result Parametric Record (MPR)” on page 3-43 in the
STDF Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
For more information, see “Master Results Record (MRR)” on page 3-10 in the STDF
Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
C_RESFMT
Is an ANSI C format string for use in formatting the test result.
C_LLMFMT
Is an ANSI C format string for use in formatting the low test and spec limits.
C_HLMFMT
Is an ANSI C format string for use in formatting the high test and spec limits.
IMAGE uses the following fields to format the low limit for a test result:
• LLM_SCAL contains the value for the low limit’s exponent
• C_LLMFMT contains the result format string
• UNITS contains the symbols for the low limit’s units
IMAGE uses the following fields to format the high limit for a test result:
• HLM_SCAL contains the value for the high limit’s exponent
• C_HLMFMT contains the result format string
• UNITS contains the symbols for the high limit’s units
For more information, see “Parametric Test Record (PTR)” on page 3-37 in the STDF
Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
HEAD_NUM
This field must be set to 255.
GOOD_CNT
A part is considered good when it is binned into one of the “passing” hardware bins.
For more information, see “Part Count Record (PCR)” on page 3-11 in the STDF
Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
For more information, see “Part Information Record (PIR)” on page 3-31 in the STDF
Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
PART_FIX
This is an application-specific field for storing device repair information. It may be used for
bit-encoded, integer, floating point, or character information. Regardless of the information
stored, the first byte must contain the number of bytes to follow. This field can be decoded
only by an application-specific analysis program.
For more information, see “Part Results Record (PRR)” on page 3-32 in the STDF
Specification Manual.
Plr.pgm_char: Plr.pgm_chal:
0: 0X-1LMVH 0: <NULL> (1-character code)
1: 00001111 1: LXVHLXVH
2: 01010101 2: 00110011
If the FTR has a pgm_indx=1 and pgm_stat=4, the 2-character data code is 1L, because
pgm_char[pgm_indx=1][pgm_stat=4] is 1 and pgm_chal[pgm_indx=1][pgm_stat=4] is
L. If the FTR had a pgm_indx=0 and pgm_stat=1, then the 1-letter data code is X, because
pgm_char[pgm_indx=0][pgm_stat=1] is X, and pgm_chal[pgm_indx=0] is NULL.
Several modes on Catalyst 400 testers require 4-character data codes. In the existing STDF
PLR, the first character of both 1-character and 2-character codes is stored in the PLR
pgm_char field, and the second character of 2-character codes is stored in the PLR
pgm_chal field. To handle 4-character codes, and to make them obviously different from 1-
and 2-character codes, the pgm_char field is left blank for 4-character codes, and the entire
4-character code is placed in the pgm_chal field, with space separators. Thus, to store the
code 0000, 0001, 0010, 0011, 0100, etc., you see:
Plr.pgm_char: Plr.pgm_chal:
0: <NULL> 0: 0000 0001 0010 0011 0100 ...
In this case, if the FTR had a pgm_indx=0 and pgm_stat=1, then the 4-character data code
is 0001 because pgm_char[pgm_indx=0] is NULL and the 4 characters starting at
pgm_chal[pgm_indx=0][pgm_stat=1 * 5) +1] are 0001.
For more information, see “Pin List Record (PLR)” on page 3-20 in the STDF Specification
Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
PMR_INDX
This field is used for the pin number.
CHAN_NAM
This field is used for the channel number.
LOG_NAM
This field is used for the pin name.
For more information, see “Pin Map Record (PMR)” on page 3-17 in the STDF Specification
Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
For more information, see “Site Description Record (SDR)” on page 3-24 in the STDF
Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
For more information, see “Software Bin Record (SBR)” on page 3-15 in the STDF
Specification Manual.
2. HBRs
3. TSRs
followed by one Part Count Record (PCR) and Master Results Record (MRR).
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
HEAD_NUM
This field must be set to 255.
TEST_TYP
Indicates what type of test the summary data is for. Either F (for functional) or P (for
parametric) is automatically set for any test that ran during the lot.
SEQ_NAME
STDF convention dictates that SEQ_NAME receive the name of a program section (or
sequencer). IMAGE deviates from this convention by assigning to SEQ_NAME the datalog
label for a particular test. For example, given the sequencer statement:
seq in_leak() $1 >-10ua <10ua "input leak pin 14" f(0);
IMAGE copies the datalog label input leak pin 14 to SEQ_NAME. If you omit the datalog
label from the sequencer statement, as in:
seq in_leak() $1 >-10ua <10ua f(0);
IMAGE responds by creating a datalog label from the test function name and copies it to
SEQ_NAME. In this case, IMAGE copies in_leak to SEQ_NAME.
For more information, see “Test Synopsis Record (TSR)” on page 3-35 in the STDF
Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
WF_UNITS
Has these valid values:
0 = Unknown units
1 = Units are in inches
2 = Units are in centimeters
3 = Units are in millimeters
4 = Units are in mils
WF_FLAT
Has these valid values:
Space = Unknown
U = Up
D = Down
L = Left
R = Right
CENTER_X
Use the value -32768 to indicate that the field is invalid.
POS_X
Has these valid values:
Space = Unknown
L = Left
R = Right
POS_Y
Has these valid values:
Space = Unknown
U = Up
D = Down
For more information, see “Wafer Configuration Record (WCR)” on page 3-29 in the STDF
Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
WAFER_ID
This field is optional but is strongly recommended to make the resulting data files as useful
as possible.
For more information, see “Wafer Information Record (WIR)” on page 3-26 in the STDF
Specification Manual.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
WAFER_ID
This field is optional but is strongly recommended to make the resulting data files as useful
as possible. A Wafer ID in the WRR supersedes any Wafer ID found in the WIR.
For more information, see “Wafer Results Record (WRR)” on page 3-27 in the STDF
Specification Manual.
<subtype> Is the record subtype, which can be any whole number of type
unsigned char. The number goes into the REC_SUB field.
<byte count> Is the number of bytes in the data you plan to move into your
custom record. The function expects the byte count to be of type
unsigned short. The byte count goes into the REC_LEN field.
<pointer to data> Is a pointer to the data. The data can reside in a structure, an
array, or any other data type. Given this pointer, the function
locates the data and appends it to the record’s header (REC_LEN,
REC_TYP, REC_SUB).
When this function is executed, it creates a custom STDF record (table 24-22) and writes it
to the datalog stream, where it flows into an STDF file with the other STDF records.
Supported by Data
Field Name Field Description
IMAGE V8.0? Type
NOTE
The tl_log_custom_record function is not designed for writing standard STDF records to
the datalog stream.
For more information, see “Begin Program Section Record (BPS)” on page 3-55 in the
STDF Specification Manual.
NOTE
To have IMAGE generate an ASCII file for test data, select the DATALOG TO TEXT FILE:ON
option on the Data Collection Setup display or issue a datalog -file command.
To find out how to process STDF files and what software systems are available for
processing STDF files, contact your Teradyne representative.
NOTE
All utilities in this section can read either Version 3 or Version 4 files, except for
read_stdf_v3 (which reads only V3 files) and stdf_print_yield (which reads only V4
files).
read_stdftool
read_stdftool is a window-based tool for selecting an STDF file and displaying its
contents one record type at a time.
Invoking
Type the following command from a Shell Tool or Command Tool window in OpenWindows:
% read_stdftool &
The ampersand (&) causes the tool to run in background mode.
NOTE
You can invoke read_stdftool as many times as your system permits. This allows you to
have multiple windows on a single STDF file.
When you first invoke read_stdftool, its control area looks as shown in figure 25-1.
Read_stdftool
FIle View Display Records Clear
Mouse Buttons
When using read_stdftool, you use two mouse buttons, referred to as SELECT (left) and
MENU (right). This assumes that you are using a three-button mouse, and that you have
not redefined the buttons. If either of these assumptions is false, use your system’s
definitions for SELECT and MENU.
Loading a File
To load an STDF file, select FILE>LOAD. The Read_stdftool: Load window appears (figure
25-2).
Read_stdftool: Load
1. Specify a directory. Directory: /opt/firms/stdf
2. Enter a filename Match: .std*
“match” template. File:
1. Specify the directory. The default is the current directory. To specify another directory,
enter an absolute path name or a path name relative to the directory where you invoked
read_stdftool. You can use the shell meta character tilde (~) to begin the path name.
2. Use a MATCH: template to specify what files you want read_stdftool to list. The
template can use these wildcard characters:
* (asterisk) Match a string of zero or more characters.
? (question mark) Match a single character.
[xy] (square brackets) Match one of the characters in the brackets.
The default template, *.std*, matches any filename whose extension begins with
“.std” (that is, any valid STDF filename).
3. Once you have specified a MATCH: template, click the LIST: button. read_stdftool lists
all the files in the directory that match the template.
NOTE
If you see an error message stating that an argument is too long, enter a new MATCH:
template that matches fewer files.
4. You can then click the filename you want. (If necessary, scroll through the files listed in
the window.)
The filename you select appears to the right of the FILE: label and is highlighted in the
Read_stdftool: Load window (see figure 25-3).
Read_stdftool: Load
Directory: /home/wilde/data
Match: *.std*2?may94*
File: mch_ado_zero.std_benedick_23may94_152543
List: mch_ado_zero.std_beatrice_23may94_151630
mch_ado_zero.std_beatrice_26may94_124727
mch_ado_zero.std_beatrice_26may94_1623170
mch_ado_zero.std_benedick_23may94_152543
mch_ado_zero.std_benedick_26may94_143207
FTR 0
Display Records
Each STDF record type is represented by its three-letter abbreviation. The number to the
right of each record type indicates how many records of that type are in the file. An entry
>100K means that the file contains more than 99,999 records of this type.
The Report Setup window lists all Version 3 and Version 4 record types, even though the
STDF file will contain only V3 or V4 types.
To display a record type, click the box for the record type, then click the DISPLAY RECORDS
button. (This button appears both on the Report Setup window and in the control area. You
can use either button.)
The window in which the records appear is editable. Click MENU in the display area to see
the editing options. Editing the display has no effect on the STDF file itself.
To clear the display, click the CLEAR button on the base window.
Hardcopy Output
You can get hardcopy output of the currently displayed record type, by writing it to a file or
sending it to a printer. To display the Hardcopy window, select FILE>HARDCOPY. The
Hardcopy window appears.
The Hardcopy window prints the currently displayed record type. It does not redisplay a new
record type, even if you have changed Report Setup parameters since the previous
execution.
Set the fields of the Hardcopy window as shown in table 25-1.
Field Setting
PROCESS CMD: Specify commands for processing the file, for example, to make it
suitable for a particular printer.
OUTPUT TO: Click in one or both boxes to indicate what kind of output you want:
FILE or PRINTER.
PRINTER: ∇ If OUTPUT TO: specifies Printer, this field is enabled. Either type in a
printer name or click MENU on this button to display a list of printers,
then SELECT to choose one.
The printer list is from your /etc/printcap file. For each
printcap entry, read_stdftool displays the second name
assigned to this printer. (If there is only one name, it is used.) For
example, from this printcap entry
varian|va|Benson Varian:
the second name, “va”, is displayed.
The default printer always appears on the printer list. To change the
default, use the Properties window (see “Setting Properties” on page
25-7).
FILE SPEC: ∇ If OUTPUT TO: specifies FILE, this field is enabled. Type in the filename
you want, either an absolute pathname or relative to the directory
where you invoked read_stdftool.
read_stdftool maintains a File Spec List of files you have specified
during this session. A file is added to this list when you press RETURN
or click FILE SPEC or PRINT. To use the list, click MENU on FILE SPEC,
then SELECT on a file. This lets you reuse (or edit) a filename.
PRINT After setting up the Hardcopy window, click PRINT to send the text to
the printer or write it to a file.
Setting Properties
To set defaults for read_stdftool, select VIEW>PROPERTIES. The Properties window
appears. Note these points:
• When you have changed values in a Properties window, click APPLY to use the new
values. The new values will be used the next time you invoke read_stdftool. They are
not used immediately within the current session.
• If you have changed values, but have not yet clicked APPLY, you can return to the
previous values by clicking RESET, which restores the values that were set previously.
• If you have changed the default values, you can click DEFAULT to restore the initial
default values. Clicking DEFAULT redisplays the initial defaults; to use these values, click
APPLY.
• Properties are set on a per-user basis. A user can change properties without affecting
other users.
• This window is pinnable. If you do not pin it, clicking APPLY dismisses it.
Fill in the fields of the Properties window as shown in table 25-2.
Field Setting
DIRECTORY: Default location for STDF files. The initial default is your current
directory.
MATCH: Default template for matching STDF filenames. The initial default is
*.std*, which matches any legal STDF filename.
read_stdf
read_stdf reads an STDF file and displays each record’s contents on the screen. The
syntax is:
% read_stdf [-f] [filename]
The -f switch causes read_stdf to display only one or two lines of the most important
information in each record. In addition, the line indentation indicates the record groupings.
For example, a paired PIR and PRR are similarly indented, while PTRs or FTRs within the
PIR/PRR pair are indented further. If you omit -f, read_stdf displays every field of every
record in the file.
read_stdf can accept input from a filename on the command line. If the filename is omitted,
input is from standard input (stdin).
read_stdf can read any V3 or V4 STDF file. It is useful for debugging STDF files you write.
You can also use read_stdf to check whether a file transfer has run to completion. (If a
transferred STDF file does not end with an MRR (Master Results Record), then the transfer
did not run to completion.)
STDF V3 and V4
read_stdf can read either an STDF Version 3 or Version 4 file. When displaying the
contents of an STDF V3 file, it uses the comparable Version 4 structures. For a more
complete explanation, see “Note on STDF V3 and V4” on page 25-3.
analyze_stdf
The analyze_stdf utility displays a brief summary of the content and size of an STDF file,
categorized by STDF record type. Use this command line to invoke the utility:
analyze_stdf stdf-file
analyze_stdf can accept input from a filename on the command line. If the filename is
omitted, input is from standard input (stdin).
The STDF file can be in either Version 3 or Version 4 format. If you specify the filename on
the command line, you can compress the file; analyze_stdf cannot accept a compressed
file from stdin.
The utility displays statistics as shown in figure 25-5 (lines have been omitted).
Filename: /home/wilde/data/h420.stdf
CPU Type: SUN
Version: 4
Size: 306344
TYPE COUNT MIN LEN AVG LEN MAX LEN TOT LEN
=========================================================
far 1 6 6 6 6
mir 1 178 178 178 178
rdr 1 12 12 12 12
...
wir 1 19 19 19 19
pir 2555 6 6 6 15330
ptr 66304 32 32 34 2126838
prr 2555 23 25 26 65323
...
pcr 1 18 18 18 18
mrr 1 8 8 8 8
---------------------------------------------------------
71523 2210091
analyze_stdf provides the following exit status so that the disposition of the STDF file can
be determined programmatically:
0 Complete STDF file, no errors.
1 Error in reading the STDF file, or file not recognized as an STDF
file (missing FAR or MIR).
2 Incomplete STDF file.
An exit status of 1 may occur when analyze_stdf cannot open the specified STDF file or
when a compressed STDF file is being read from stdin.
stdf_print_field
The stdf_print_field utility returns a string containing the values from one or more fields
of the File Attributes Record (FAR) or Master Information Record (MIR) of a specified STDF
file. It prints this string on stdout. The STDF file can be Version 3 or 4 format.
One use of this utility is to rename an STDF file based on the kind of data it contains:
stdf_print_field can return a string that includes the file’s lot ID, part type, testing mode,
or any other FAR or MIR field, and the string can be used as the file’s new name.
Use the following command line to invoke the utility:
stdf_print_field [-w] [-s] file "format" field(s)...
where:
-w Removes all spaces, tabs, carriage returns, new lines, vertical
tabs, and form feeds from the output.
-s Removes all characters from the output that are not letters or
digits.
file Is the STDF file specification. The file can be in V3 or V4 format.
"format" Is an enquoted string that specifies the output format. Use the
codes shown in the table 25-3 on page 25-12. The format string
can also specify white space, punctuation, and any other
printable characters. The -w and -s options affect the format
string. For example, if the format string contains spaces, the -w
switch will remove them from the output.
field(s) Are the keywords specifying the MIR fields to display. The nth
field-name keyword corresponds to the nth format specifier in the
format string. The keywords are shown in table 25-3 on page
25-12, along with the correct format specifier for each. Each
keyword shown is the minimum acceptable string for the MIR
field. You can include more characters to improve readability: for
example, sub is the keyword for SBLOT_ID, but you could include
the complete string Sub-Lot. The case of the keywords is
unimportant.
Note that MIR fields differ between STDF V3 and V4. If you request a field that is not
supported by the version of the STDF file, stdf_print_field returns a null string (if the
field format specified is %s) or the value 65,535 (for BURN_TIM, the only numeric field not
supported by both versions).
This is an example of an stdf_print_field command line:
stdf_print_field tfile.std "LOT %s_%s" lot par
It will return a string like this:
LOT 61772_D07X1
The value 61772 is the lot identifier, and D07X1 is the part type. The format string
concatenates the two values with an underscore.
Table 25-3 shows the FAR and MIR fields, the stdf_print_field keyword, and minimum
acceptable format specifier for each. It also shows which fields are supported only by STDF
Version 3 or Version 4.
stdf_print_yield
The stdf_print_yield utility determines the yield of good parts from an STDF file and
prints it on stdout. The yield appears as a percentage (without the percent sign). The STDF
file must be in Version 4 format.
Use this command line to invoke the utility:
stdf_print_yield file [ -s ] [ good-bins ]
where:
file Is the input file. The file must be in Version 4 format.
-s Specifies that the utility is to use counts from SBRs (Software Bin
Records). The default is to use the HBRs (Hardware Bin
Records).
good-bins Is a list of “good” bin numbers separated by commas. White
space is not permitted in the string of bin numbers. The meaning
of “good” is user-defined. The list specifies the bins
stdf_print_yield uses in calculating the yield. If the bin list is
not included, the utility uses its own definition of “good” parts, as
described below.
Yield is defined as: good-parts / total-parts
The “good-parts” numerator and “total-parts” denominator are defined in the following
sections.
STDF-ATDF Conversions
The Data Pipeline package contains utilities for converting between Standard Test Data
Format (STDF) and ASCII Test Data Format (ATDF). The conversion utilities are:
stdf_to_atdf Converts an STDF Version 4 file into ATDF V2 format.
atdf_to_stdf Converts an ATDF Version 2 file into STDF V4 format.
To invoke one of these utilities, use this format:
utility-name input-file output-file
If you specify one file, it is assumed to be the input file and the utility writes output to stdout.
If you do not specify a file, the utility reads input from stdin and writes output to stdout.
For stdf_to_atdf, the input STDF file must be in Version 4 format.
For more information on the file formats, see:
• Standard Test Data Format (STDF) Specification — Version 4
• ASCII Test Data Format (ATDF) Specification — Version 2
Conversion between STDF and ATDF occurs with no loss of data, because the records and
fields of each are identical.
PRB_CARD. CPU_TYP and STDF_VER are now in the FAR (required as the first record in a
V4 file). If the MIR has a HAND_ID or PRB_CARD value, the utility creates an SDR (Site
Description Record, new in V4) for these values.
• MRR (Master Results Record)
These fields have moved from the MRR to the PCR (Part Count Record, new with V4):
PART_CNT, RTST_CNT, ABRT_CNT, and GOOD_CNT. When the utility reads a V3 MRR, it
writes a PCR with these values and with the HEAD_NUM and SITE_NUM values set to 255.
• WIR (Wafer Information Record)
When the utility writes a V4 WIR, it assigns the value 255 to the SITE_GRP field.
• WRR (Wafer Results Record)
When the utility writes a V4 WRR, it assigns the value 255 to the SITE_GRP field. The
utility does not store the V3 HAND_ID and PRB_CARD values.
• PMR (Pin Map Record)
The PMR has been redefined. The utility writes the V4 PMR as follows:
CHAN_NAM = PMR V3 CHAN_NUM
CHAN_TYP = 0
LOG_NAM = ""
HEAD_NUM = 1
SITE_NUM = 1
PMR_INDX = PMR V3 CHAN_NUM
PHY_NAM = PMR V3 PIN_NAME
In STDF V3, CHAN_NUM and PIN_NAME can be arrays. When the utility reads a V3 PMR,
it reads only the first CHAN_NUM into CHAN_NAM and PMR_INDX, and it reads only the first
PIN_NAME into PHY_NAM. The V3 CHAN_CNT and NAME_CNT are no longer necessary.
• PIR/PRR (Part Information Record/Part Results Record)
The X_COORD, Y_COORD, and PART_ID fields are no longer part of the PIR; instead, they
are found only in the PRR. When the utility reads a V3 PIR, it writes these values to the
PRR with the same site and head number, if it does not have them.
• PDR (Parametric Test Description Record)
The PDR has been dropped from V4, so the utility writes the fields from a PDR to a PTR.
The utility takes the following V4 fields from the V3 fields with the same name:
TEST_NUM, OPT_FLAG (although some bits are different), RES_SCAL, LO_LIMIT,
HI_LIMIT, LLM_SCAL, HLM_SCAL, and UNITS.
The utility sets the following fields to 0 (zero): HEAD_NUM, SITE_NUM, TEST_FLG (indicates
that test was not executed and that the FTR contains only default information),
PARM_FLG, RESULT, TEST_TXT, and ALARM_ID.
The utility fills in the format fields as follows:
C_RESFMT = Determined from PDR V3 RES_RDIG and RES_LDIG
C_LLMFMT = Determined from PDR V3 LLM_LDIG and LLM_RDIG
C_HLMFMT = Determined from PDR V3 HLM_LDIG and HLM_RDIG
The utility writes the V4 TEST_NAM and SEQ_NAME values to the TSR for this test, if it does
not already have them; if no corresponding TSR exists, the utility creates one for them.
The V3 DESC_FLG value is no longer necessary.
The utility does not try to merge the Master Information Records (MIRs) from each of the
STDF files. It uses the MIR from the first input file. The utility assumes the two STDF files
represent two halves of a lot and, as such, it uses the MIR from the first half.
When it is merging two STDF files, the utility renumbers devices from the second file to
follow the first sequentially. To turn off this renumbering, specify the -no_renum option.
If any limits or statistics (for example, mean or standard deviation) change for a given test
from one STDF file to the other, the utility marks the information as invalid in the merged
STDF file.
STDF Filters
DataPump software (see “Datapump Automation Software” on page 15-1) provides a set of
filters for use with STDF files. Each filter performs one function: for example, to exclude
certain bins, or to replace datalog readings with the retested readings, as identified by the
X/Y coordinates. You can call the filters from the command line and pipe them to each other.
This section covers the following topics:
• General points that apply to all filters
• Detailed descriptions of all filters
Note that “Changing and Repairing STDF Files” on page 25-16 describes these utilities for
changing or repairing STDF files:
• stdf_repair (page 25-16)
• stdf_to_atdf and atdf_to_stdf (page 25-18)
• stdf3_to_4 (page 25-18)
• stdf4_to_3 (page 25-21)
• stdf_merge (page 25-23)
If you omit input-file or output-file, the filter uses stdin and stdout, thus allowing
you to pipe filters together. The general form would be:
filter1 -e items input-file | filter2 -i items | \
filter3 -e items |....| filtern -i items > output-file
Additional Notes
The following sections describe the action of each filter. Note these points:
• In addition to the effects of the filters described here, each filter also adds an ATR (Audit
Trail Record) to the STDF file, containing the command line for the filter.
• Some filters exclude PTRs (Parametric Test Records). Some PTRs, however, contain
semistatic default data that describes the units and scaling information needed by other
records. For this reason, these filters write any PTRs with semistatic default data before
they write any of the PIR/PRR pairs, so that, even if datalog records are excluded, this
information is preserved.
Filter Types
The filters fall into these categories:
• Filter by some criterion
• Replace First-Pass Data With Retest Data
• Other
See tables 25-4, 25-5, and 25-6 for details about these filters.
Note that this filter can create an illegal STDF file, that is, a file that does not have an FAR,
MIR, and MRR. It is your responsibility to create a legal file or to be aware of the
consequences of generating an illegal one.
NOTE
This filter results in a format that is consistent with STDF V3 files converted into V4. In V3,
the default data was put in Parametric Test Description Records (PDRs). A V4 PTR
containing default data but no test result value is comparable to a V3 PDR.
c CYCL_CNT 0
v REL_VADR 1
r REPT_CNT 2
n NUM_FAIL 3
x XFAIL_AD 4
y YFAIL_AD 5
f VECT_OFF 6
b FAIL_PIN 7
o OP_CODE 8
If you do not include any switches, all nine fields are considered to be specified.
If there are FTRs that you do not want to convert, first use filter_test to remove them
from the file before calling filter_ftr.
NOTE
If you use stdf_repair, it must be the first filter in the pipe.
Null Filter
In addition to the other filters, the Datapump provides the C code and make file for a null
filter. The null filter program reads an STDF file, and writes out a nearly identical STDF file.
The only difference is that it adds an ATR to indicate the filter that it applied.
Like all other valid record types, user-defined record types (REC_TYP >= 200) and executive-
reserved record types (REC_TYP = 180 or 181) are copied unchanged from the input file to
the output file. The null filter does not do any byte conversion on the data in these records.
It assumes that it is running on the same kind of CPU as the system that created the file.
The null filter does write the correct record length to the REC_LEN field of the header.
The null filter takes two arguments: the input and output files. If you omit the output file, the
filter writes the file to stdout; if you omit both files, the filter reads the input from stdin and
writes to stdout.
You can use this program as a template for writing your own filters. The C code is fully
commented for easy modification.
You can find the null filter program and its make file in:
$IMAGEBIN/custom/stdf.filters
As installed, the null filter program is not compiled. To compile it, use the make file in the
same directory. Use this command line:
% make -f make_null
This section describes functions you can call from test programs. Functions are listed in
table 26-1, and function definitions begin on page 26-39. Table 26-11 describes obsolete
functions for your reference.
Additional functions specific to tester types are listed in other manuals as follows:
• “Catalyst Functions” in the Catalyst Instrumentation Manual
• “Catalyst Tiger Functions” in the Catalyst Tiger Instrumentation Manual
• “FlexDSP Programmer’s Reference” on page 27-1 lists all functions for FlexDSP data
arrays
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
tl_get_dib_id Get the DIB board type of the parts being tested
tl_get_dib_typ Get the DIB board type of the parts being tested
tl_get_dsgn_rev Get the device design revision of the parts being
tested
tl_get_eng_id Get the engineering lot ID of the parts being tested
tl_get_extr_id Read the extra equipment id of the parts being tested
tl_get_extr_typ Get the extra equipment type of the parts being tested
tl_get_facil_id Get the test facility ID of the parts being tested
tl_get_famly_id Get the device family ID of the parts being tested
tl_get_floor_id Get the test floor ID of the parts being tested
tl_get_flow_id Get the test_flow ID of the parts being tested
tl_get_hbin_device_count Return the device count for the desired hardware bin
tl_get_hp_name Get the name of the handler or prober
tl_get_hp_type Get the name of the handler or prober
tl_get_hsd_type Get type of digital subsystem
tl_get_inker Get the inker number to fire when bin result received
tl_get_lasr_id Get the laser ID of parts being tested
tl_get_lasr_typ Get the laser_type of parts being tested
tl_get_last_seq_bin Get bin number for last sequencer
tl_get_load_id Get the load board ID of parts being tested
tl_get_load_path Convert a file name into a full path name
tl_get_load_typ Get the load board type of the parts being tested
tl_get_number_of_testheads Get the number of test heads
tl_get_oper_frq Get the test operation frequency of parts being tested
tl_get_part_datalogged Return if current set of parts will be datalogged
tl_get_pkg_typ Get the package type of parts being tested
tl_get_prb_card Get the probe card ID of the parts being tested
tl_get_prb_typ Get the probe card type of the parts being tested
Function Action
tl_get_prog_nam_fullpath Get the fully rooted path name of the test program
tl_get_radians_d Convert a double value from degrees to radians
tl_get_radians_f Convert a float value from degrees to radians
tl_get_sbin_device_count Return the device count for the desired software bin
tl_get_seq_bin Get the sequencer bin number for a site
tl_get_setup_id Get the test setup ID of parts being tested
tl_get_slot_from_pin Return test head slot number from pin
tl_get_sort_bin Get bin number assigned in sort bin statement
tl_get_sort_hbin Get handler bin assigned in sort bin statement
tl_get_spec_nam Get the test spec. name of parts being tested
tl_get_spec_ver Get the test spec. version of parts being tested
tl_getstdftimeofday Return the value of the GMT time of day (in STDF
format)
tl_get_stream_criteria Get test criteria for the given stream
tl_get_stream_filename Return the name of the file the datalog stream is
writing
tl_get_stream_sample_info Return streams sampling rate
tl_get_tester_number Read current tester number
tl_get_tst_temp Get the testing temperature of parts being tested
tl_get_user_power Get the state of the user power relay
tl_get_wavefile_sample_size Get the sample size from a waveform file
tl_gigadig_report_ac_corr_spectrum return error correction spectrum
tl_gigadig_report_chan_mismatch_data report mismatch data between channels
tl_gigadig_report_err report error at a single freq.
tl_gigadig_skew_clock skew GigaDig capture clock
tl_gpib_dump_bus_info Dump information about the GPIB
tl_gpib_dump_gpibcap_info Dump the driver’s copy of gpibcap
tl_gpib_get_ifc_at_reset Read whether IFC is asserted during reset
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
tl_set_tsr_test_tim Set the Average Test Time field in the Test Synopsis
Record
tl_set_tst_temp Set the testing temperature for the current lot
tl_set_user_power Set the state of user power
tl_set_usr_desc Set user-defined lot information string
tl_set_wafer Set wafer coordinates for current devices
tl_set_wafer_id Set wafer ID for the current wafer
tl_set_wafer_mapping_ink_bin Designate bin number for the ink bin
tl_set_wait Set a retriggerable wait time
tl_set_wait_timeout Set user retriggerable wait timeout
tl_simwave_name Set file name for AC wave source simulator
tl_sinxx_amp Calculate sin x/x corrected amplitude
tl_site Global variable indicating current site number
tl_site_active Determine if sites are still qualified
tl_site_shutdown Call user function when site fails
tl_smem_read_wave_sample_max Return the wave sample size maximum
tl_smem_set_wave_sample_max Set the wave sample size maximum
tl_sps_ammeter_connect Set the HVA connect bit
tl_sps_ammeter_disable_alarm Disable the selected alarm
tl_sps_ammeter_enable_alarm Enable the selected alarm
tl_sps_ammeter_reset Reset the High Voltage Ammeter
tl_sps_discon_meter_input Disconnect SPS from meter input
tl_sps_gateoff Set the SPS gate enable bit off
tl_sps_gateon Set the SPS gate enable bit
tl_sps_get_amm_cal_stat Return HVA calibration status
tl_sps_get_amm_cal_time Return HVA calibration time
tl_sps_get_fvs_status Get FVS alarm status
tl_sps_get_hccs_status Get HCCS alarm status
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
Function Action
ftoi
Convert double to int with rounding.
SYNOPSIS int ftoi(doubleval)
double doubleval;
handlerprober_bin
Send bin command to handler (obsolete)
SYNOPSIS handlerprober_bin()
handlerprober_init
Initialize handler software interface.
SYNOPSIS handlerprober_init(name)
char *name;
DESCRIPTION Initializes the handler or prober software interface for the current
test head. This function only needs to be called once; it is
unnecessary to call it for each run of a test program. You must
call this function if your test program uses any of the tl_hp_...
handler library functions.
You can use this function in one of two modes. In the first (and
most useful) mode, the function initializes the interface based on
the handler type previously selected using the handlerconf
command. This mode is most often used when the test program
must perform some form of handler control in addition to the
basic operations supported by IMAGE, although it can also be
used when the test program is doing all of the handler control
(“independent” mode).
In the second mode, this function initializes the interface based
on the name of the peripheral passed as a parameter. This mode
was designed primarily for programs written before IMAGE V2.0,
which required that all handler control be done from the test
program.
ARGUMENTS name—String with name of handler to select, or 0 to use handler
selected by handlerconf -connect
RETURN VALUE 1—interface initialized successfully (starts enabled)
0—interface initialized successfully (starts disabled)
-1—initialization failed
SIDE EFFECTS May print error messages to the station window
handlerprober_reset
Reset handler software interface.
SYNOPSIS handlerprober_reset()
DESCRIPTION This function resets the handler software interface within a test
program, effectively disabling all handler library calls. To re-
enable the handler interface software, make another call to
handlerprober_init().
ARGUMENTS None
RETURN VALUE -1 for failure, 1 for success
handlerprober_start
Wait for handler start (obsolete)
SYNOPSIS handlerprober_start()
Hprintf
Print a heading string to the datalog.
SYNOPSIS void Hprintf(char * header_fmt, ...);
DESCRIPTION This function prints into the datalog the first 255 characters of the
string resulting from the formatting of the header_fmt argument,
and any variable arguments. It does this once for every datalog
stream that is enabled. The calling convention for this function is
identical to the printf() family of functions. Embedded newline
characters are accepted as part of the string.
ARGUMENTS Calling conventions is the same as the printf function family.
header_fmt—The format string for the string to be placed into
the datalog.
...—Variable arguments for any format specifiers in the format
string.
RETURN VALUE None
SIDE EFFECTS Multiple calls to this function are ignored.
Lprintf
Print a formatted string to the datalog report.
SYNOPSIS Lprintf(fmt, arg, arg, ...)
char *fmt;
...
lprintf
Print a formatted string to the datalog report.
SYNOPSIS lprintf(fmt, arg, arg, ...)
char *fmt;
...
Mprintf
Print a formatted string to the datalog report regardless of datalog mode or binning status.
SYNOPSIS Mprintf(fmt, arg, arg, ...)
char *fmt; ...
next_device_is_retest
Force the next device to be a retest
DESCRIPTION This function tells IMAGE to treat the next device tested as a
retest. Testing on the current device is not affected in any way.
ARGUMENTS None
RETURN VALUE None
rdelay
Function to wait for relay delay.
SYNOPSIS int rdelay()
DESCRIPTION Waits for both the DC Subsystem hardware busy bit and the
Terabus settling timer.
ARGUMENTS None
RETURN VALUE Always 0
SIDE EFFECTS tl_tba_settle_wait is always called, so all alarms are cleared
and a new latched alarm window begins.
rdelay_time
Wait for relay delay then return time waited.
SYNOPSIS double rdelay_time()
DESCRIPTION Waits for both the DC Subsystem hardware busy bit and the
Terabus settling timer.
ARGUMENTS None
RETURN VALUE Returns the number of seconds which elapsed during rdelay().
This is intended as an aid in optimizing test programs. Returns
the time waited in seconds as a double.
SIDE EFFECTS tl_tba_settle_wait is always called so all alarms are cleared
and a new latched alarm window begins.
read_ac_clock
Read back An clock frequency setting.
SYNOPSIS double read_ac_clock(clock)
int clock;
DESCRIPTION Function to read back the frequency of one of the analog clocks.
Note that for mixed-signal instrumentation, the A0 clock has a
special feature. Using the set clock: a0_mode:c0 statement,
A0 can be put into a mode where the C0 clock is actually
read_ac_freq_pin
Return the frequency of the ac clock attached to the instrument described by the pin
number.
SYNOPSIS double read_ac_freq_pin(pin)
int pin;
read_ac_vrng
Read back the voltage range of an ac instrument.
SYNOPSIS double read_ac_vrng(pin)
int pin;
DESCRIPTION This function reads back the voltage range (or max amplitude
setting) for one of the ac instruments. Called with a device pin
number, it returns the vrange of the instrument behind that pin.
It is an error to have more that one ac instrument behind a pin.
Consider using read_lfdig_vrng or read_hfdig_vrng to
make it unambiguous.
ARGUMENTS pin—Instrument pin number.
read_ac_vrng_chan
Read back the voltage range of an ac instrument.
SYNOPSIS double read_ac_vrng_chan(chan)
char *chan;
DESCRIPTION This function reads back the voltage range (or maximum
amplitude setting) for an ac instrument. Called with a tester
channel number string, it returns the vrange of the instrument
behind that channel.
ARGUMENTS chan—Instrument channel number.
read_ac_vrng_slot
Read back the voltage range of an ac instrument.
SYNOPSIS double read_ac_vrng_slot(slot)
int slot;
DESCRIPTION This function reads back the voltage range (or maximum
amplitude setting) for an HFDIG instrument. Called with a tester
slot number, it returns the vrange of the instrument behind that
slot.
ARGUMENTS slot—The slot number of the instrument.
read_apu
Read results of simulated APU local meter measurement.
SYNOPSIS double read_apu(apu_number_array, result_array)
short *apu_number_array;
double *result_array;
read_apu_pin
read results APU local meter measurement
SYNOPSIS double read_apu_pin(pin_number_array, result_array)
short *pin_number_array;
double *result_array;
DESCRIPTION Note: This function does not work properly on multisite programs
and exists only for legacy purposes. It is replaced by
read_apu_pin_multisite.
Reads the results of an APU local meter measurement for a
single pin or list of pins and returns the result(s) in result_array.
The first parameter can either be a single pin number or a pointer
to a 0-terminated list of pin numbers. The second parameter is a
two-dimensional array of doubles of the form
result_array[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
If the first parameter is a single pin then the measurement result
will also be returned as the function return value. If there is not
exactly one active test site then 0 will be returned. If the first
parameter specifies a list of pins then the function return value is
undefined.
If the test program uses parallel test result_array must be large
enough to store values from all test sites. The function does not
fill in results for sites that are not active.
double results[TL_SYS_MAX_SITES][NUMBER_OF_PINS];
int i;
serial {
read_apu_pin(APU_PINS, results);
for (i = 0; i < NUMBER_OF_PINS; i++)
test results[tl_site][i];
}
For the UB APU this function reads the results of an APU local
meter measurement which was simulated via the measure driver
and measure bus.
ARGUMENTS short *pin_number_array—pointer to list of APU pin numbers
double *result_array —pointer to list of apu results
read_apu_pin_multisite
Read results APU local meter measurement.
SYNOPSIS double read_apu_pin_multisite(pin_number_array,
result_array)
short *pin_number_array;
double *result_array;
For the UB APU this function reads the results of an APU local
meter measurement which was simulated via the measure driver
and measure bus.
ARGUMENTS short *pin_number_array—Pointer to list of APU pin numbers
double *result_array—Pointer to list of apu results
read_apu_pin_status
Read status of APU pin number.
SYNOPSIS read_apu_pin_status(pin_number)
short pin_number;
RETURN VALUE 0—APU pin number is invalid or specified APU pin not found in
pinmap or APU hardware behind the pin is not present or called
outside serial loop and more than one active test site
2—Corresponding APU hardware is present and no alarm is
latched
3—APU hardware is present and guard or overload alarm is
latched
SIDE EFFECTS Produces a run-time error for error conditions.
SEE ALSO “tl_apu_read_pin_status”, “read_apu_status”
read_apu_status
Read status of APU number.
SYNOPSIS read_apu_status(apu_number)
short apu_number;
read_bin_is_open
Is a bin open or closed?
SYNOPSIS int read_bin_is_open(bin)
int bin;
read_bin_is_pass
Is a bin is a pass bin or a fail bin?
SYNOPSIS int read_bin_is_pass(bin)
int bin;
read_cdig_all_fail_vectors
Get information for all Serial Bus Channel Card failing vectors.
DESCRIPTION Reads the hardware receive memory to find all failing vectors in
the receive memory for pattern patname. The search will
terminate when the end of the pattern is reached. This function
also clears the pattern fail register, so that read_cdig_failed()
will return FALSE after this function is called.
Note: arrays fail_chans and fail_vectors must be declared
as the appropriate type arrays of at least size 65536. Otherwise,
the function may violate segmentation without warning if the
number of failures exceeds the size of the array. This is because
the program cannot determine the size of arrays passed as
function arguments at runtime.
ARGUMENTS slot—Slot number of SBCC
patname—Name of the pattern
fail_chans—Array of unsigned char of at least size 65537 in
which
failed channel information is returned.
fail_vectors—Array of unsigned short of at least size 65537
in which
failed vector information is returned
RETURN VALUE TRUE if any failures were found
FALSE if no failures were found
fail_chans[i] = 1 if channel 1 failed
= 2 if channel 2 failed
= 3 if both channel 1 and 2 failed
= 0 if there are no more failing pins.
fail_vectors[i]
If pattern name is not NULL, will have the vector number
in pattern patname where the failure in fail_chans[i]
was found. If pattern name is NULL, will have the
hardware address where the failed vector was found.
SIDE EFFECTS Clears AFR bit, even though it was not used.
read_cdig_all_fail_vectors_pin
Get information for all Serial Bus Channel Card failing vectors.
SYNOPSIS int read_cdig_all_fail_vectors_pin(pin, patname,
fail_chans, fail_vectors)
int pin;
char * patname;
unsigned char fail_chans[n];
unsigned short fail_vectors[n];
DESCRIPTION Reads the hardware receive memory to find all failing vectors in
the receive memory for pattern patname. The search will
terminate when the end of the pattern is reached.
This function also clears the pattern fail register, so that
read_cdig_failed() will return FALSE after this function is
called.
Note: arrays fail_chans and fail_vectors must be declared
as the appropriate type arrays of at least size 65536. Otherwise,
the function may violate segmentation without warning if the
number of failures exceeds the size of the array. This is because
the program cannot determine the size of arrays passed as
function arguments at runtime.
ARGUMENTS pin—A pin number in front of the cdig slot
patname—Name of the pattern
fail_chans—Array of unsigned char of at least size 65537 in
which failed channel information is returned.
fail_vectors—Array of unsigned short of at least size 65537
in which failed vector information is returned
RETURN VALUE TRUE if any failures were found
FALSE if no failures were found
fail_chans[i] = 1 if channel 1 failed
= 2 if channel 2 failed
= 3 if both channel 1 and 2 failed
= 0 if there are no more failing pins.
fail_vectors[i]
If pattern name is not NULL, will have the vector number
in pattern patname where the failure in fail_chans[i]
was found. If pattern name is NULL, will have the
hardware address where the failed vector was found.
SIDE EFFECTS Clears AFR bit, even though it was not used.
read_cdig_failed
Check for Serial Bus channel card pattern failures.
SYNOPSIS read_cdig_failed(pin)
int pin;
read_cdig_failed_segment
Check if Serial Bus channel card pattern failed in segment.
SYNOPSIS read_cdig_failed_segment(slot, patternname,
segmentname, segment_instance);
int slot;
char * patternname, segmentname;
int segment_instance;
SIDE EFFECTS Clears AFR bit, even though it was not used in the determination.
read_cdig_failed_slot
Check for Serial Bus channel card pattern failures.
SYNOPSIS read_cdig_failed_slot(pin)
int slot;
DESCRIPTION Returns TRUE a pattern on the board indicated by slot has failed
since the last time pattern failures were read. Returns FALSE
otherwise.
Clears the hardware fail bit (AFR). Call the
wait_until_cdig_halt function before calling
read_cdig_failed_slot. This function does not check if the
hardware has stopped.
Note: Failures are cleared whenever the hardware is reset.
ARGUMENTS slot—Slot number of channel on Serial Bus Channel Card to be
checked
RETURN VALUE TRUE—Pattern failure occurred
FALSE—No pattern failure
read_cdig_n_fail_vectors
Get information for first n Serial Bus channel card failing vectors.
SYNOPSIS int read_cdig_n_fail_vectors(slot, patname, n,
fail_chans, fail_vectors)
int slot;
char * patname;
int n;
unsigned char fail_chans[n];
unsigned short fail_vectors[n];
SIDE EFFECTS Clears AFR bit, even though it was not used.
read_cdig_n_fail_vectors_pin
Get information for first n Serial Bus channel card failing vectors.
SYNOPSIS int read_cdig_n_fail_vectors_pin(pin, patname, n,
fail_chans, fail_vectors)
int pin
char * patname;
int n;
unsigned char fail_chans[n];
unsigned short fail_vectors[n];
SIDE EFFECTS Clears AFR bit, even though it was not used.
read_cdig_timing_range
Read currently set timing range for Serial Bus channel card.
SYNOPSIS int read_cdig_timing_range(slot)
int slot;
DESCRIPTION Reads the hardware and returns current setting of timing range.
ARGUMENTS slot—Slot number of the card to check
read_cdig_timing_range_pin
Read currently set timing range for Serial Bus channel card.
SYNOPSIS int read_cdig_timing_range(pin)
int pin;
DESCRIPTION Reads the hardware and returns current setting of timing range.
ARGUMENTS pin—Pin number in front of the card to check
read_configuration_status
Read status of last configuration check.
DESCRIPTION The return value from this function indicates whether or not the
last configuration check passed or failed. It is useful for
preventing the execution of a test program on a test system not
containing all the instrumentation required to run the test
program.
ARGUMENTS None
RETURN VALUE TRUE (1) if the configuration check passed
FALSE (0) if the configuration check failed
read_current_site
Get current site number.
SYNOPSIS int read_current_site();
DESCRIPTION This function is only useful in a multisite test program and only
inside a serial block. The function returns the current site
number. This is normally the same as the value of tl_site.
However, after a site is disabled, for example by failing, tl_site
takes on a negative value, but read_current_site() returns
the site number.
ARGUMENTS None
RETURN VALUE The number of the current site. In a single site test program the
return value will always be 0. In a multisite test program, inside
a serial block, the site number is returned. Outside a serial block,
a negative value is returned.
SEE ALSO “tl_site”
read_databits
User level read databits function.
SYNOPSIS int read_databits(param)
int param;
DESCRIPTION This is the user level read databits function. In a multisite test
program, you must use read_databits inside a serial block if
you are trying to read the value of a bit name which maps to
different bits for each site. If you try to do this outside of a serial
block, it results in a run-time error.
ARGUMENTS You can pass either a single bit name from the pinmap or a bit
number between 1 and 48 as the parameter to read a single bit.
The value of the single bit (0 or 1) is returned.
read_databits_true
User level read databits (true readback) function.
SYNOPSIS int read_databits_true(param)
int param;
read_dps_amm_pin_status
Read status of DPS ammeter
SYNOPSIS int read_dps_amm_pin_status(pin, statusp)
unsigned short *pin;
int *statusp;
DESCRIPTION This function returns the alarm and error status of the specified
DPS ammeter. The alarms and errors of interest are those that
were present at the time the local ammeter was strobed. The first
parameter can either be a single pin number or a pointer to a 0-
terminated list of pin numbers. The second parameter is a two-
dimensional array of integers of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS] where
NUMBER_OF_PINS is the number of pins specified in the first
parameter.
ARGUMENTS pin—A single DPS pin number or a 0-terminated list of pins
statusp—Pointer to array where the status of each DPS will be
stored
RETURN VALUE A general status is returned.
1 = errors or alarms were found.
0 = no alarms or errors found on any channels.
For each pin specified, function inserts an encoded status of
alarms and errors in the integer pointed to by statusp. The value
entered is encoded as follows:
Alarms and errors at time of current ADC strobe:
QVS_AMM_INVALID_DATA—Valid data from a recent QVS
conversion has not yet been read.
QVS_AMM_OVERWRITE_DATA—Previously unread, valid data has
been overwritten by another QVS conversion.
QVS_AMM_MISSED_TRIGGER—A QVS conversion strobe was
received while another conversion was in progress.
QVS_AMM_OPEN_KELVIN—QVS open kelvin alarm at time of
strobe.
QVS_AMM_SENSE_CURR—QVS sense current alarm at time of
strobe
QVS_AMM_CLAMP—QVS clamp alarm at time of strobe
QVS_AMM_OVERRANGE—QVS voltmeter overrange alarm
QVS_AMM_OPEN_LOOP—QVS open loop alarm at time of strobe
read_dps_dib_ctrl_data
Reads DIB control data
SYNOPSIS void read_dps_dib_ctrl_data(pin, resultp)
unsigned short *pin;
int *resultp;
DESCRIPTION Reads the current dib control data for the given pin/pin field.
ARGUMENTS unsigned short *pin—a single DPS pin number or a pin field
read_dps_low_i_n
Read low current from QVS Local Meter and average
SYNOPSIS int read_dps_low_i_n(pin_names, n, max_expected_i,
wmd, &data)
DESCRIPTION This function basically measures a lower current value than what
the DPS normally encounters. It takes the specified number of
current readings per pin and returns averaged values as results.
This function first prepares to take a low current measurement
from the pin(s) passed into it. After error checking for incorrect
values (see below), it makes a copy of the values of ammeter
range, current limiter (ilim), the DIB control parameter (dib_ctrl),
the DCC capacitance parameter (dcc_cap), and the comp value.
Once these values are copied, the function turns off the dib_ctrl
and the DCC capacitance, bypasses the sense boost, and then
sets the amm_rng and the gain to the user specified values.
The function then takes the current measurements, and stores
them into a two-dimensional array of doubles of the form
data[TL_SYS_MAX_SITES][NUMBER_OF_PINS] where
NUMBER_OF_PINS is the number of pins specified in the first
parameter. It then resets the QVS back to the way that it was,
retrieving the older values.
ARGUMENTS pin_names—A single DPS pin number or a 0-terminated list of
pins
int n—# of readings to average
max_expected_i—User input expected current, in the range
0-.000200A inclusive. If that value is not .000020 or
.000200(A), the program will round up to whichever of
those values is nearer.
wmd—Wait measure delay - user defined time for device to
stabilize so that accurate measurement can be made (in
seconds) this value must between 0 < 3.000 (s)
data—Returned current measurements may be one
measurement or array of many measurements - this will
depend on how many pins are being measured
read_dps_low_i_time
Read low current from QVS Local Meter and average over time.
SYNOPSIS int read_dps_low_i_time(pin_names, t,
max_expected_i, wmd, &data)
DESCRIPTION This function basically measures a lower current value than what
the DPS normally encounters. It takes as many current readings
as possible during the specified time period and then returns
averaged values as results.
This function first prepares to take a low current measurement
from the pin(s) passed into it. After error checking for incorrect
values (see below), it makes a copy of the values of ammeter
range, current limiter (ilim), the DIB control parameter
(dib_ctrl), the DCC capacitance parameter (dcc_cap), and the
comp value.
Once these values are copied, the function turns off the
dib_ctrl and the DCC capacitance, bypasses the sense boost,
and then sets the amm_rng and the gain to the user specified
values.
The function then takes the current measurements, and stores
them into a two-dimensional array of doubles of the form
data[TL_SYS_MAX_SITES][NUMBER_OF_PINS] where
NUMBER_OF_PINS is the number of pins specified in the first
parameter. It then resets the QVS back to the way that it was,
retrieving the older values.
ARGUMENTS pin_names—A single DPS pin number or a 0-terminated list of
pins
double t—Time period (in seconds) over which measurements
are to be averaged
max_expected_i—User input expected current, in the range
0-.000200A inclusive. If that value is not .000020 or
.000200(A), the program will round up to whichever of
those values is nearer.
wmd—Wait measure delay - user defined time for device to
stabilize so that accurate measurement can be made (in
seconds) this value must between 0 < 3.000 (s)
data—Returned current measurements may be one
measurement or array of many measurements - this will
depend on how many pins are being measured
read_dps_meter_pin_status
Read status of DPS ammeter.
SYNOPSIS int read_dps_meter_pin_status(pin, statusp)
unsigned short *pin;
int *statusp;
DESCRIPTION This function returns the alarm and error status of the specified
DPS ammeter. The alarms and errors of interest are those that
were present at the time the local ammeter were strobed. The
first parameter can either be a single pin number or a pointer to
a 0-terminated list of pin numbers. The second parameter is a
two-dimensional array of integers of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS] where
NUMBER_OF_PINS is the number of pins specified in the first
parameter.
ARGUMENTS pin—a single DPS pin number or a 0-terminated list of pins
statusp—pointer to array where the status of each DPS will be
stored
RETURN VALUE A general status is returned. 1 = errors or alarms were found.
0 = no alarms or errors found on any channels.
For each pin specified, function inserts an encoded status of
alarms and errors in the integer pointed to by statusp. The value
entered is encoded as follows:
Alarms and errors at time of current ADC strobe:
QVS_AMM_INVALID_DATA—Valid data from a recent QVS
conversion has not yet been read.
QVS_AMM_OVERWRITE_DATA—Previously unread, valid data has
been overwritten by another QVS conversion.
QVS_AMM_MISSED_TRIGGER—A QVS conversion strobe was
received while another conversion was in progress.
QVS_AMM_OPEN_KELVIN—QVS open kelvin alarm at time of
strobe.
QVS_AMM_SENSE_CURR—QVS sense current alarm at time of
strobe
QVS_AMM_CLAMP—QVS clamp alarm at time of strobe
QVS_AMM_OVERRANGE—QVS voltmeter overrange alarm
QVS_AMM_OPEN_LOOP—QVS open loop alarm at time of strobe
read_dps_pin
Read current from DPS Local Meter.
SYNOPSIS void read_dps_pin(pin, resultp)
unsigned short *pin;
double *resultp;
DESCRIPTION Strobe the DPS Local ammeter, wait for the A/D conversion, and
put the measured value in the specified location. The first
parameter can either be a single pin number or a pointer to a 0-
terminated list of pin numbers. The second parameter is a two-
dimensional array of doubles of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS] where
NUMBER_OF_PINS is the number of pins specified in the first
parameter.
ARGUMENTS unsigned short *pin—A single DPS pin number or a 0-
terminated list of pins (must be at least one pin!)
double *resultp—Pointer to location where result is to be
stored
RETURN VALUE None
SIDE EFFECTS Changes tl_qvs_selected
read_dps_pin_n
Read current from DPS Local Meter and average.
SYNOPSIS void read_dps_pin_n(pin, n, resultp)
unsigned short *pin;
int n;
double *resultp;
DESCRIPTION Strobe the DPS Local ammeter and take a current reading the
specified number of times and put averaged result into the result
location. The second parameter is a two-dimensional array of
doubles of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS] where
NUMBER_OF_PINS is the number of pins specified in the first
parameter.
ARGUMENTS unsigned short *pin—A single DPS pin number or a
0-terminated list of pins (must be at least one pin)
int n—# of readings to average
double *resultp—Pointer to location where result is to be
stored
RETURN VALUE None
SIDE EFFECTS Changes tl_qvs_selected.
read_dps_pin_nostrobe
Read current from DPS Local Meter
SYNOPSIS void read_dps_pin_nostrobe(pin, resultp)
unsigned short *pin;
double *resultp;
DESCRIPTION Read the DPS Local ammeter for the specified pin and put the
measured value in the specified location. The first parameter can
either be a single pin number or a pointer to a 0-terminated list of
pin numbers. The second parameter is a two-dimensional array
of doubles of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS] where
NUMBER_OF_PINS is the number of pins specified in the first
parameter.
ARGUMENTS unsigned short *pin—A single DPS pin number or a
0-terminated list of pins
double *resultp—Pointer to location where result is to be
stored
RETURN VALUE None
SIDE EFFECTS Changes tl_qvs_selected.
read_dps_pin_status
Returns the status of the last CPU strobe performed.
SYNOPSIS void read_dps_pin_status(pin, statusp)
unsigned short *pin;
double *statusp;
6: DPS_CPU_STB_CONFLICT DPS_CPU_STB_CONFLICT_MASK
a CPU strobe conversion was received while another CPU strobe conversion was in
progress
7: DPS_ARBITOR_CONFLICT DPS_ARBITOR_CONFLICT_MASK
a measurement was requested by a command controller when a request by one of the
other 3 controllers was being handled by the arbiter
-------------------------------
8,9,10:DPS_INPUT_MODE DPS_INPUT_MODE_MASK
Input mode at the time of the strobe
-------------------------------
ARGUMENTS unsigned short *pin—a single DPS pin number or a pin field
read_dps_pin_time
Read current from DPS Local Meter and average over time
SYNOPSIS int read_dps_pin_time(pin, t, resultp)
unsigned short *pin;
double t;
double *resultp;
DESCRIPTION Strobe the DPS Local ammeter and take as many current
readings as possible in the specified time period and put
averaged result into the result location. The first parameter can
either be a single pin number or a pointer to a 0-terminated list of
pin numbers. The second parameter is a two-dimensional array
of doubles of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS] where
NUMBER_OF_PINS is the number of pins specified in the first
parameter.
ARGUMENTS unsigned short *pin—A single DPS pin number or a
0-terminated list of pin (must be at least one pin!)
double t—Time period (in seconds) over which measurements
are to be averaged
double *resultp—Pointer to location where result is to be
stored
read_fail_vectors
Return vector number of failed vector
SYNOPSIS int read_fail_vectors(fail_number, patnamep)
int fail_number;
char *patnamep;
DESCRIPTION Return the vector number and pattern name of any failed vector
captured in History RAM.
This function only works for failures where both the failing cycle
itself AND the cycle where the SCM fail flag gets set (34 cycles
later) are captured in HRAM.
This usually requires that:
—HRAM1 is in “unqualified” mode (capture all cycles).
—Repeat compress is off.
The default system HRAM setup meets these requirements.
This function may not return the correct (or any) pattern name if
a pattern was unloaded after the last pattern run.
Reading and reconstructing HRAM is a lengthy process and
calling any of the HRAM read functions has about a 25ms
overhead for the first call after a new pattern run.
This function will give a runtime error if a pattern is running and
not in keepalive.
ARGUMENTS fail_number—Which failure to get (1 = first failure)
patnamep—Name of a character array in which to write the
pattern name of the failing vector. Must be large enough to
hold the longest pattern name used in the test program.
May be zero; in this case, the pattern name is not returned.
RETURN VALUE Vector number of failing vector, or -1 if there were less than
fail_number fails captured.
read_funct_halt
Read HSD pattern haltcode.
SYNOPSIS int read_funct_halt()
read_h50_code
Read SCM READCODE register.
SYNOPSIS int read_h50_code()
DESCRIPTION Retrieves the read code written by the pattern to the READCODE
register on the 1st SCM. Does an rdelay() and checks alarms.
On the simulator, this function may cause the pattern to execute.
ARGUMENTS None
RETURN VALUE Value from 0 - 2047, the READCODE specified in the pattern.
TL_H50_NOREADCODE if the pattern didn’t specify a READCODE.
SEE ALSO Note for driver writers: Call this version only during test program
execution and never during anything like a debug display fetch
function, or it may cause pattern debugger deadlock.
read_h50_code_nac
Read SCM READCODE, no alarm check.
SYNOPSIS int read_h50_code_nac(which_scm) int which_scm;
DESCRIPTION Retrieves the read code written by the pattern to the READCODE
register on the specified SCM. This function does not do an
rdelay nor does it check alarms. On the simulator, this function
may cause the pattern to execute.
ARGUMENTS which_scm—0 for 1st SCM, 1 for 2nd SCM
RETURN VALUE Value from 0 - 2047, the READCODE specified in the pattern.
TL_H50_NOREADCODE if the pattern didn’t specify a READCODE.
read_hfdig_vrng
Read back the voltage range of a High Frequency Digitizer.
DESCRIPTION This function reads back the voltage range (or maximum
amplitude setting) for an HFDIG instrument. Called with a device
pin number, it returns the vrange of the HFDIG behind that pin.
ARGUMENTS pin—Pin number of the instrument.
RETURN VALUE Returns the vrange of the HFDIG behind that pin.
SEE ALSO “read_ac_vrng_chan” for using channel numbers instead of
device pins.
read_hram_loc
Search History RAM for a cycle.
SYNOPSIS int read_hram_loc(how, which, n)
int how
int which;
int n;
DESCRIPTION Searches History RAM for a specified cycle. Returns the location
of the cycle, used for accessing the information.
Type of search is specified by the how argument:
TL_HRAM_BY_CYCLE—find n’th cycle whose cycle number
matches which
TL_HRAM_BY_VECTOR—find n’th cycle whose vector number
matches which
TL_HRAM_BY_FAIL—find n’th failing cycle
TL_HRAM_BY_TSET—find n’th cycle whose tset number matches
which
read_hram_scm
Read SCM information for a History RAM location.
SYNOPSIS int read_hram_scm(loc, what)
int loc;
int what;
read_hsd50_results
Get Catalyst failed pin list.
SYNOPSIS int read_hsd50_results(faillist)
unsigned short *faillist;
int read_hsd50_results_scm(faillist, which_scm)
unsigned short *faillist;
int which_scm;
DESCRIPTION Get the list of DUT pin numbers listed as failing by the
Accumulated Fail Register. Writes null-terminated list of failing
channel numbers into the user-supplied array faillist.
Returns the number of failed pins. The pattern may be running.
read_lfdig_vrng
Read back the voltage range of a Low Frequency Digitizer.
SYNOPSIS double read_lfdig_vrng(pin)
int pin;
DESCRIPTION This function reads back the voltage range (or maximum
amplitude setting) for an LFDIG instrument. Called with a device
pin number, it returns the vrange of the LFDIG behind that pin.
ARGUMENTS pin—Pin number of the instrument.
RETURN VALUE Returns the vrange of the LFDIG behind that pin.
SEE ALSO “read_ac_vrng_chan” for using channel numbers instead of
device pins.
read_lowest_bin_at_fail
Read the best bin number at point of failure.
SYNOPSIS int read_lowest_bin_at_fail();
DESCRIPTION Only use this function in a test program using close binning. It
returns the bin number into which the device would be binned
had it been binned at the point all pass bins were closed (unless
an explicit pass or fail bin assignment has been made).
When running in stop_on_fail mode (the default), testing stops
at the point when all pass bins are closed. When running in
continue_on_fail mode, however, binning may change after
this point. Use this function to put the device where it would have
been binned in stop_on_fail mode.
In a multisite test program this must be called from inside a serial
block.
ARGUMENTS None
RETURN VALUE Lowest open bin number [1-32] at point of failure or NO_BINNING
if all bins closed.
read_lowest_open_bin
Read bin number of best currently open bin.
SYNOPSIS int read_lowest_open_bin()
DESCRIPTION This function determines the lowest currently open bin number.
This is the bin into which the device would be binned if a sort
bin statement was executed at this point in the test program
(unless an explicit pass or fail bin assignment has been made).
In a multisite test program this must be called from inside a serial
block.
ARGUMENTS None
RETURN VALUE Lowest open bin number [1–32] or NO_BINNING if all bins closed.
read_measurement
Take and return a DC measurement.
SYNOPSIS double read_measurement();
read_measurement_n
Return the average of N measurements.
SYNOPSIS double read_measurement_n(n_times);
int n_times;
read_measurement_nostrobe
Read a previously-taken measurement.
SYNOPSIS double read_measurement_nostrobe();
read_measurement_time
Read average of measurements over time.
read_measurement_time_and_n
Average and number of measurements over time.
SYNOPSIS double read_measurement_time(t, n);
double t;
int *n;
read_meter
Take a measurement with the test system DC meter.
SYNOPSIS double read_meter();
DESCRIPTION The system meter takes a measurement of its input and returns
a calibrated reading. The unit of the reading, such as volts,
amps, or some other unit, depending on the instrument being
measured.
ARGUMENTS None
RETURN VALUE Reading
read_meter_n
Return average of N readings.
SYNOPSIS double read_meter_n(n_times);
int n_times;
read_meter_nostrobe
Return reading without taking a new one.
SYNOPSIS double read_meter_nostrobe();
DESCRIPTION Like read_meter(), but does not strobe the meter with the CPU.
It is assumed that the meter was strobed by another means,
such as a trigger line or an external input to A/D Strobe.
ARGUMENTS None
RETURN VALUE Reading
read_meter_time
Return average of readings over time.
SYNOPSIS double read_meter_time(time);
double time;
DESCRIPTION Read meter averaged over time. Averages the meter over the
specified duration. Time is specified in seconds. A negative
duration generates an error and zero is returned. It is guaranteed
that the meter is read at least once.
ARGUMENTS time—in seconds.
read_meter_time_and_n
Return average and number of readings over time.
SYNOPSIS double read_meter_time_and_n(time, n);
double time;
int *n;
DESCRIPTION Read meter averaged over time. Averages the meter over the
specified duration. Time is specified in seconds. A negative
read_opamp_loop_alarm
Read status of Quad Opamp channel card open loop alarm.
SYNOPSIS int read_opamp_loop_alarm (pinnum)
int pinnum;
DESCRIPTION This function accepts a pin number, as specified in the pin map.
The alarm register is read on the opamp channel specified and,
if the alarm bit is set, a 1 is returned. If the bit is not set or the site
is inactive, a 0 is returned. The function supports multisite test. If
the program is a multisite program, the function must be
enclosed in a serial block.
ARGUMENTS int pinnum—The pin number from the pin map
RETURN VALUE 0 if ok
1 if alarm
read_opamp_osc_alarm
Read status of Quad Opamp channel card osc alarm.
SYNOPSIS int read_opamp_osc_alarm (pinnum)
int pinnum;
DESCRIPTION This function accepts a pin number, as specified in the pin map.
The alarm register is read on the opamp channel specified and if
the alarm bit is set a 1 is returned. If the bit is not set or the site
is inactive, a 0 is returned. The function supports multisite test. If
the program is a multisite program, the function must be
enclosed in a serial block.
ARGUMENTS int pinnum—The pin number from the pin map
RETURN VALUE 0 if ok
1 if alarm
read_ovi_amm_pin_status
Read status of OVI ammeter.
DESCRIPTION This function returns the alarm and error status of the specified
OVI ammeter. The alarms and errors of interest are those that
were present at the time the local ammeter was strobed. The first
parameter can either be a single pin number or a pointer to a 0-
terminated list of pin numbers. The second parameter is a two-
dimensional array of integers of the form:
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
ARGUMENTS pin—A single OVI pin number or a 0-terminated list of pins
statusp—Pointer to array where the status of each OVI will be
stored
RETURN VALUE A general status is returned.
1 = errors or alarms were found.
0 = no alarms or errors found on any channels.
For each pin specified, function inserts an encoded status of
alarms and errors in the integer pointed to by statusp. The
value entered is encoded as follows:
Alarms and errors at time of current ADC strobe
OVI_AMM_INVALID_DATA—Valid data from a recent conversion
has not yet been read
OVI_AMM_OVERWRITE_DATA—Previously unread, valid data has
been overwritten by another conversion
OVI_AMM_MISSED_TRIGGER—A conversion strobe was received
while another conversion was in progress
OVI_AMM_OPEN_KELVIN—Open Kelvin alarm at time of strobe
OVI_AMM_SENSE_CURR—Sense current alarm at time of strobe
OVI_AMM_MODE—Mode alarm at time of strobe
OVI_AMM_OVERRANGE—Voltmeter overrange alarm
OVI_AMM_OPEN_LOOP—Open loop alarm at time of strobe
read_ovi_amm_status
Read status of OVI ammeter
SYNOPSIS int read_ovi_amm_status(channel, statusp)
unsigned short *channel;
int *statusp;
DESCRIPTION This function returns the alarm and error status of the specified
OVI ammeter. The alarms and errors of interest are those that
were present at the time the local ammeter was strobed.
ARGUMENTS channel—A single OVI channel number or a 0-terminated list of
channels (1 based)
statusp—Pointer to array where the status of each OVI will be
stored
RETURN VALUE A general status is returned.
1 = errors or alarms were found.
0 = no alarms or errors found on any channels.
For each channel specified, function inserts an encoded status
of alarms and errors in the integer pointed to by statusp. The
value entered is encoded as follows:
Alarms and errors at time of current ADC strobe
OVI_AMM_INVALID_DATA—valid data from a recent conversion
has not yet been read
OVI_AMM_OVERWRITE_DATA—previously unread, valid data has
been overwritten by another conversion
OVI_AMM_MISSED_TRIGGER—a conversion strobe was received
while another conversion was in progress
OVI_AMM_OPEN_KELVIN—Open Kelvin alarm at time of strobe
OVI_AMM_SENSE_CURR—Sense current alarm at time of strobe
OVI_AMM_MODE—Mode alarm at time of strobe
OVI_AMM_OVERRANGE—Voltmeter overrange alarm
OVI_AMM_OPEN_LOOP—Open loop alarm at time of strobe
read_ovi_i
Read current from OVI local meter.
SYNOPSIS void read_ovi_i(channel,resultp)
unsigned short *channel;
double *resultp;
DESCRIPTION Strobe the OVI local ammeter, wait for the A/D conversion, and
put the measured value in the specified location.
ARGUMENTS channel—a single OVI channel number or a 0-terminated list of
channels (1 based)
resultp—pointer to location where result is to be stored
read_ovi_i_n
Read current from OVI local meter and average
SYNOPSIS void read_ovi_i_n(channel, n, resultp)
unsigned short *channel;
int n;
double *resultp;
DESCRIPTION Strobe the OVI local meter and take a current reading the
specified number of times and put averaged result into the result
location.
ARGUMENTS channel—a single OVI channel number or a 0-terminated list of
channels (1 based)
n—number of measurements to be averaged
resultp—pointer to location where result is to be stored
read_ovi_i_nostrobe
Read voltage from OVI local meter without strobing.
SYNOPSIS void read_ovi_i_nostrobe (channel, resultp)
unsigned short *channel;
double *resultp;
DESCRIPTION Read the OVI local meter and put the measured value in the
specified location.
ARGUMENTS channel—A single OVI channel number or a 0-terminated list of
channels (1 based)
resultp—Pointer to location where result is to be stored
read_ovi_i_pin
Read current from OVI local meter.
SYNOPSIS void read_ovi_i_pin(pin,resultp)
unsigned short *pin;
double *resultp;
DESCRIPTION Strobe the OVI local meter, wait for the A/D conversion, and put
the measured value in the specified location. The first parameter
can either be a single pin number or a pointer to a 0-terminated
read_ovi_i_pin_n
Read current from OVI local meter and average.
SYNOPSIS void read_ovi_i_pin_n(pin,n,resultp)
unsigned short *pin;
int n;
double *resultp;
DESCRIPTION Strobe the OVI local meter and take a current reading the
specified number of times and put averaged result into the result
location. The second parameter is a two-dimensional array of
doubles of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
ARGUMENTS pin—A single OVI pin number or a 0-terminated list of pins
n—Number of readings to average
resultp—Pointer to location where result is to be stored
read_ovi_i_pin_nostrobe
Read current from OVI local meter.
SYNOPSIS void read_ovi_i_pin_nostrobe(pin, resultp)
unsigned short *pin;
double *resultp;
DESCRIPTION Read the OVI local meter for the specified pin and put the
measured value in the specified location. The first parameter can
either be a single pin number or a pointer to a 0-terminated list of
pin numbers. The second parameter is a two-dimensional array
of doubles of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
ARGUMENTS pin—A single OVI pin number or a 0-terminated list of pins
resultp—Pointer to location where result is to be stored
read_ovi_i_pin_time
Read current from OVI local meter and average over time.
SYNOPSIS void read_ovi_i_pin_time(pin,t,resultp)
unsigned short *pin;
double t;
double *resultp;
DESCRIPTION Strobe the OVI local meter and take as many current readings as
possible in the specified time period and put averaged result into
the result location. The first parameter can either be a single pin
number or a pointer to a 0-terminated list of pin numbers. The
second parameter is a two-dimensional array of doubles of the
form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
ARGUMENTS pin—A single OVI pin number or a 0-terminated list of pins
t—Time period (in seconds) over which measurements are to be
averaged
resultp—Pointer to location where result is to be stored
read_ovi_i_time
Read current from OVI local meter and average over time.
SYNOPSIS int read_ovi_i_time(channel, t, resultp)
unsigned short *channel;
double t;
double *resultp;
DESCRIPTION Strobe the OVI local meter and take as many current readings as
possible in the specified time period and put averaged result into
the result location.
ARGUMENTS channel—A single OVI channel number or a 0-terminated list of
channels (1 based)
t—Time period (in seconds) over which measurements are to be
averaged
resultp—Pointer to location where result is to be stored
read_ovi_meter_pin_status
Read status of OVI voltmeter and ammeter.
SYNOPSIS int read_ovi_meter_pin_status(pin, statusp)
unsigned short *pin;
int *statusp;
DESCRIPTION This function returns the alarm and error status of the specified
OVI voltmeter and ammeter. The alarms and errors of interest
are those present at the time the local voltmeter and ammeter
were strobed. The first parameter can either be a single pin
number or a pointer to a 0-terminated list of pin numbers. The
second parameter is a two-dimensional array of integers of the
form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
ARGUMENTS pin—A single OVI pin number or a 0-terminated list of pins
statusp—Pointer to array where the status of each OVI will be
stored
RETURN VALUE A general status is returned.
1 = errors or alarms were found.
0 = no alarms or errors found on any channels.
For each pin specified, function inserts an encoded status of
alarms and errors in the integer pointed to by statusp. The
value entered is encoded as follows:
Alarms and errors at time of voltage ADC strobe.
OVI_VM_INVALID_DATA—valid data from a recent conversion
has not yet been read
OVI_VM_OVERWRITE_DATA—previously unread, valid data has
read_ovi_meter_status
Read status of OVI voltmeter and ammeter.
SYNOPSIS int read_ovi_meter_status(channel, statusp)
unsigned short *channel;
int *statusp;
DESCRIPTION This function returns the alarm and error status of the specified
OVI voltmeter and ammeter. The alarms and errors of interest
are those that were present at the time the local voltmeter and
ammeter were strobed.
ARGUMENTS channel—A single OVI channel number or a 0-terminated list of
channels (1 based)
statusp—Pointer to array where the status of each OVI will be
stored
RETURN VALUE A general status is returned.
1 = errors or alarms were found.
0 = no alarms or errors found on any channels.
For each channel specified, function inserts an encoded status
of alarms and errors in the integer pointed to by statusp. The
value entered is encoded as follows:
Alarms and errors at time of voltage ADC strobe
read_ovi_r
Calculate for a channel.
SYNOPSIS void read_ovi_r(channel, resultp)
read_ovi_r_pin
Calculate resistance for a pin.
SYNOPSIS void read_ovi_r_pin(pin, resultp)
read_ovi_v
Read voltage from OVI local meter.
SYNOPSIS void read_ovi_v(channel,resultp)
unsigned short *channel;
double *resultp;
DESCRIPTION Strobe the OVI local voltmeter, wait for the A/D conversion, and
put the measured value in the specified location.
ARGUMENTS channel—A single OVI channel number or a 0-terminated list of
channels (1 based)
resultp—Pointer to location where result is to be stored
read_ovi_v_i
Read voltage and current from OVI local meter.
SYNOPSIS void read_ovi_v_i(v_channel, i_channel, v_resultp,
i_resultp)
unsigned short *v_channel;
unsigned short *i_channel;
double *v_resultp;
double *i_resultp;
DESCRIPTION Strobe the OVI local voltmeter and ammeter, wait for the A/D
conversions, and put the measured values in the specified
location.
ARGUMENTS v_channel—Voltmeters to be read. A single OVI channel
number or a 0-terminated list of channels (1 based).
i_channel—Ammeters to be read. A single OVI channel
number or a 0-terminated list of channels (1 based).
v_resultp—Pointer to location where voltage readings are to
be stored
i_resultp—Pointer to location where current readings are to be
stored
RETURN VALUE None
SIDE EFFECTS Changes tl_ovi_selected.
read_ovi_v_i_n
Read voltage and current from OVI local meters and average.
SYNOPSIS void read_ovi_v_i_n(v_channel, i_channel, n,
v_resultp, i_resultp)
unsigned short *v_channel;
unsigned short *i_channel;
int n;
double *v_resultp;
double *i_resultp;
DESCRIPTION Strobe the OVI Local voltmeter and ammeter at the same time,
take both a voltage reading and a current reading the specified
number of times, and put averaged results into the result
location.
ARGUMENTS v_channel—Voltmeters to be read. A single OVI channel
number or a 0-terminated list of channels (1 based).
i_channel—Ammeters to be read. A single OVI channel
number or a 0-terminated list of channels (1 based).
n—number of measurements to be averaged
v_resultp—Pointer to location where voltage readings are to
be stored
i_resultp—Pointer to location where current readings are to be
stored
RETURN VALUE None
SIDE EFFECTS Changes tl_ovi_selected.
read_ovi_v_i_nostrobe
Read voltage and current from OVI local meter without strobing.
SYNOPSIS void read_ovi_v_i_nostrobe(v_channel, i_channel,
v_resultp, i_resultp)
unsigned short *v_channel;
unsigned short *i_channel;
double *v_resultp;
double *i_resultp;
DESCRIPTION Read the OVI local voltmeter and ammeter and put the
measured values in the specified location.
ARGUMENTS v_channel—Voltmeters to be read. A single OVI channel
number or a 0-terminated list of channels (1 based).
i_channel—Ammeters to be read. A single OVI channel
number or a 0-terminated list of channels (1 based).
v_resultp—Pointer to location where voltage readings are to
be stored
read_ovi_v_i_pin
Read voltage and current from OVI local meter.
SYNOPSIS void read_ovi_v_i_pin(v_pin, i_pin, v_resultp,
i_resultp)
unsigned short *v_pin;
unsigned short *i_pin;
double *v_resultp;
double *i_resultp;
DESCRIPTION Strobe the OVI Local voltmeter and ammeter, wait for the A/D
conversions, and put the measured values in the specified
location. The first two parameters can either be a single pin
number or a pointer to a 0-terminated list of pin numbers. The
third and fourth parameters are two-dimensional arrays of
doubles of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
ARGUMENTS v_pin—Voltmeters to be read. A single OVI pin number or a 0-
terminated list of pins.
i_pin—Ammeters to be read. A single OVI pin number or a 0-
terminated list of pins.
v_resultp—Pointer to location where voltage readings are to
be stored
i_resultp—Pointer to location where current readings are to be
stored
RETURN VALUE None
SIDE EFFECTS Changes tl_ovi_selected.
read_ovi_v_i_pin_n
Read voltage and current from OVI local meters and average.
SYNOPSIS void read_ovi_v_i_pin_n(v_pin, i_pin, n, v_resultp,
i_resultp)
unsigned short *v_pin;
unsigned short *i_pin;
int n;
double *v_resultp;
double *i_resultp;
DESCRIPTION Strobe the OVI Local voltmeter and ammeter at the same time,
take both a voltage reading and a current reading the specified
number of times, and put averaged results into the result
location. The first two parameters can either be a single pin
number or a pointer to a 0-terminated list of pin numbers. The
fourth and fifth parameters are two-dimensional array of doubles
of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
ARGUMENTS v_pin—Voltmeters to be read. A single OVI pin number or a
0-terminated list of pins.
i_pin—Ammeters to be read. A single OVI pin number or a 0-
terminated list of pins.
n—number of readings to average
v_resultp—Pointer to location where voltage readings are to
be stored
i_resultp—Pointer to location where current readings are to be
stored
RETURN VALUE None
SIDE EFFECTS Changes tl_ovi_selected.
read_ovi_v_i_pin_nostrobe
Read voltage and current from OVI local meters without strobing.
SYNOPSIS void read_ovi_v_i_pin_nostrobe(v_pin, i_pin,
v_resultp, i_resultp)
unsigned short *v_pin;
unsigned short *i_pin;
double *v_resultp;
double *i_resultp;
DESCRIPTION Read the OVI local voltmeter and ammeter behind the specified
pins and put the measured values in the specified location. The
first and second parameters can either be a single pin number or
a pointer to a 0-terminated list of pin numbers. The third and
fourth parameters are two-dimensional arrays of doubles of the
form:
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
read_ovi_v_i_pin_time
Read voltage and current from OVI local meters and average over time.
SYNOPSIS void read_ovi_v_i_pin_time(v_pin, i_pin, t,
v_resultp, i_resultp)
unsigned short *v_pin;
unsigned short *i_pin;
double t;
double *v_resultp;
double *i_resultp;
DESCRIPTION Strobe the OVI Local voltmeter and ammeter at the same time,
take as many voltage readings and current readings as possible
in the specified time period and put the averaged results into the
result location. The first two parameters can either be a single pin
number or a pointer to a 0-terminated list of pin numbers. The
last two parameters are two-dimensional arrays of doubles of the
form:
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
ARGUMENTS v_pin—Voltmeters to be read. A single OVI pin number or a
0-terminated list of pins.
i_pin—Ammeters to be read. A single OVI pin number or a
0-terminated list of pins.
t—Time period (in seconds) over which measurements are to be
averaged
v_resultp—Pointer to location where voltage readings are to
be stored
i_resultp—Pointer to location where current readings are to be
stored
RETURN VALUE Returns number of measurements taken in the specified time
period
read_ovi_v_i_time
Read voltage and current from OVI local meters and average over time.
SYNOPSIS int read_ovi_v_i_time(v_channel, i_channel, t,
v_resultp, i_resultp)
unsigned short *v_channel;
unsigned short *i_channel;
double t;
double *v_resultp;
double *i_resultp;
DESCRIPTION Strobe the OVI local voltmeter and ammeter at the same time,
take as many voltage readings and current readings as possible
in the specified time period and put the averaged results into the
result location.
ARGUMENTS v_channel—Voltmeters to be read. A single OVI channel
number or a 0-terminated list of channels (1 based).
i_channel—Ammeters to be read. A single OVI channel
number or a 0-terminated list of channels (1 based).
t—Time period (in seconds) over which measurements are to be
averaged
v_resultp—Pointer to location where voltage readings are to
be stored
i_resultp—Pointer to location where current readings are to be
stored
RETURN VALUE Returns number of measurements taken in the specified time
period
SIDE EFFECTS Changes tl_ovi_selected.
read_ovi_vm_pin_status
Read status of OVI voltmeter.
SYNOPSIS int read_ovi_vm_pin_status(pin, statusp)
unsigned short *pin;
int *statusp;
DESCRIPTION This function returns the alarm and error status of the specified
OVI voltmeter. The alarms and errors of interest are those that
were present at the time the local voltmeter was strobed. The
first parameter can either be a single pin number or a pointer to
a 0-terminated list of pin numbers. The second parameter is a
two-dimensional array of integers of the form:
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
read_ovi_vm_status
Read status of OVI voltmeter.
SYNOPSIS int read_ovi_vm_status(channel, statusp)
unsigned short *channel;
int *statusp;
DESCRIPTION This function returns the alarm and error status of the specified
OVI voltmeter. The alarms and errors of interest are those that
were present at the time the local voltmeter were strobed.
ARGUMENTS channel—a single OVI channel number or a 0-terminated list of
channels (1 based)
statusp—pointer to array where the status of each OVI will be
stored
RETURN VALUE A general status is returned.
1—errors or alarms were found.
0—no alarms or errors found on any channels.
read_ovi_v_n
Read voltage from OVI local meter and average.
SYNOPSIS void read_ovi_v_n(channel, n, resultp)
unsigned short *channel;
int n;
double *resultp;
DESCRIPTION Strobe the OVI local voltmeter and take a voltage reading the
specified number of times and put averaged result into the result
location.
ARGUMENTS channel—a single OVI channel number or a 0-terminated list of
channels (1-based)
n—number of measurements to be averaged
resultp—pointer to location where result is to be stored
read_ovi_v_nostrobe
Read voltage from OVI local meter without strobing.
SYNOPSIS void read_ovi_v_nostrobe(channel, resultp)
unsigned short *channel;
double *resultp;
DESCRIPTION Read the OVI local voltmeter and put the measured value in the
specified location.
read_ovi_v_pin
Read voltage from OVI local meter.
SYNOPSIS void read_ovi_v_pin(pin,resultp)
unsigned short *pin;
double *resultp;
DESCRIPTION Strobe the OVI local voltmeter, wait for the A/D conversion, and
put the measured value in the specified location. The first
parameter can either be a single pin number or a pointer to a
0-terminated list of pin numbers. The second parameter is a two-
dimensional array of doubles of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
ARGUMENTS pin—A single OVI pin number or a 0-terminated list of pins
resultp—Pointer to location where result is to be stored
read_ovi_v_pin_n
Read voltage from OVI local meter and average.
SYNOPSIS void read_ovi_v_pin_n(pin,n,resultp)
unsigned short *pin;
int n;
double *resultp;
DESCRIPTION Strobe the OVI Local voltmeter and take a voltage reading the
specified number of times and put averaged result into the result
location. The second parameter is a two-dimensional array of
doubles of the form
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
read_ovi_v_pin_nostrobe
Read voltage from OVI local meter.
SYNOPSIS void read_ovi_v_pin_nostrobe(pin, resultp)
unsigned short *pin;
double *resultp;
DESCRIPTION Read the OVI local voltmeter for the specified pin and put the
measured value in the specified location. The first parameter can
either be a single pin number or a pointer to a 0-terminated list of
pin numbers. The second parameter is a two-dimensional array
of doubles of the form:
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
ARGUMENTS pin—A single OVI pin number or a 0-terminated list of pins
resultp—Pointer to location where result is to be stored
read_ovi_v_pin_time
Read voltage from OVI local meter and average over time.
SYNOPSIS void read_ovi_v_pin_time(pin,t,resultp)
unsigned short *pin;
double t;
double *resultp;
DESCRIPTION Strobe the OVI local voltmeter and take as many voltage
readings as possible in the specified time period and put
averaged result into the result location. The first parameter can
either be a single pin number or a pointer to a 0-terminated list of
pin numbers. The second parameter is a two-dimensional array
of doubles of the form:
resultp[TL_SYS_MAX_SITES][NUMBER_OF_PINS]
where NUMBER_OF_PINS is the number of pins specified in the
first parameter.
read_ovi_v_time
Read voltage from OVI local meter and average over time.
SYNOPSIS int read_ovi_v_time(channel, t, resultp)
unsigned short *channel;
double t;
double *resultp;
DESCRIPTION Strobe the OVI local voltmeter and take as many voltage
readings as possible in the specified time period and put
averaged result into the result location.
ARGUMENTS channel—a single OVI channel number or a 0-terminated list of
channels (1-based) double
t—time period (in seconds) over which measurements are to be
averaged
resultp—pointer to location where result is to be stored
read_pacs_clock
Read A(n) clock frequency for PACS.
SYNOPSIS double read_pacs_clock(clk, cage)
int clk;
int cage;
DESCRIPTION This function reads the current frequency of an A(n) clock for the
Precision AC Subsystem.
ARGUMENTS clk—Which clock to read (0, 1, 2, 3)
cage—Cage to read, 1 to PACS_MAX_CAGES.
read_plfdig_vrng
Read back the voltage range of a Precision Low Frequency Digitizer.
SYNOPSIS double read_plfdig_vrng(pin)
int pin;
DESCRIPTION This function reads back the voltage range (or maximum
amplitude setting) for a PLFDIG instrument. Called with a device
pin number, it returns the vrange of the PLFDIG behind that pin.
ARGUMENTS pin—Pin number of the instrument.
read_plfs_integrator
Read the input bits of the selected PLFSRC.
SYNOPSIS int read_plfs_integrator();
DESCRIPTION Reads the input bits of the selected Precision Low Frequency
Source.
ARGUMENTS None
RETURN VALUE The input bits of the selected PLFSRC.
read_proto_slot_reg
Read the value of the specified prototype board register.
SYNOPSIS int read_proto_slot_reg(slot, reg, echo)
int slot;
int reg;
int echo;
DESCRIPTION Use tl_xath to read back from the specified register of the given
slot directly from the hardware.
ARGUMENTS slot—Test head slot number
reg—Prototype board register (0-63)
echo—0: read direct
non-0: read echo RAM
RETURN VALUE None
read_qvs_low_i
Intermediate function to call read_qvs_low_i2().
read_sitemask_all
Return site mask for all sites.
SYNOPSIS unsigned int read_sitemask_all()
read_sitemask_disabled
Return site mask for all disabled sites.
SYNOPSIS unsigned int read_sitemask_disabled()
read_sitemask_enabled
Return site mask for all enabled sites.
SYNOPSIS unsigned int read_sitemask_enabled()
NOTE
Use this function only if complicated site manipulation is required. In most instances, use of
the serial block is preferable and simpler.
ARGUMENTS None
RETURN VALUE A site mask with a bit set for each site current enabled
SEE ALSO “tl_site_active”
read_sitemask_failed_sequencer
Return site mask for failed sites.
SYNOPSIS unsigned int read_sitemask_failed_sequencer()
DESCRIPTION This function determines all sites that failed the last sequencer in
a multisite test program. If called from within a sequencer, the
site mask returned identifies the sites that failed that sequencer.
ARGUMENTS None
RETURN VALUE A site mask with a bit set for each site that failed the last
sequencer
SEE ALSO “read_sitemask_enabled”, “tl_get_seq_bin”
read_sitemask_sleep
Return site mask for all sleeping sites.
SYNOPSIS unsigned int read_sitemask_sleep()
read_spec
Read back the current value of a spec.
SYNOPSIS double read_spec(const char *sname)
DESCRIPTION This function gets the current value for the named spec and
returns it. The current value is that specified in a set spec
statement if any apply to that spec. Otherwise, it is the value
relative to the currently active specset for the speclist that spec
is a member of. The active specset is set whenever a set hsd50
create_setup or load hsd50 setup statement occurs.
RETURN VALUE The value of the spec; NaN: one of the following has occurred:
—Spec does not exist and the test program ignores the
subsequent error.
—Spec has no defined value for the currently active specset.
—No currently active specset.
read_spec_max
Read back the maximum value of a spec.
SYNOPSIS double read_spec_max(const char *sname)
DESCRIPTION This function gets the maximum value for the named spec and
returns it. This is the maximum value specified for the spec in the
currently active specset. The active specset is set whenever a
set hsd50 create_setup or load hsd50 setup statement
occurs.
ARGUMENTS const char *sname—the string name of the spec
RETURN VALUE The maximum value of the spec; NaN: one of the following has
occurred:
1. the spec does not exist and the test program ignores the
subsequent error.
2. the spec has no defined value for the currently active specset.
3. there is no currently active specset.
SIDE EFFECTS None.
SEE ALSO None.
read_spec_min
Read back the minimum value of a spec.
SYNOPSIS double read_spec_min(const char *sname)
DESCRIPTION This function gets the minimum value for the named spec and
returns it. This is the minimum value specified for the spec in the
currently active specset. The active specset is set whenever a
RETURN VALUE The minimum value of the spec; NaN: one of the following has
occurred:
1. the spec does not exist and the test program ignores the
subsequent error.
2. the spec has no defined value for the currently active specset.
3. there is no currently active specset.
SIDE EFFECTS None.
SEE ALSO None.
read_test_condition
Return currently selected test condition.
SYNOPSIS int read_test_condition()
DESCRIPTION This function returns the value of the currently selected test
condition. Test conditions are defined in the test_conditions
declaration. The current test condition is selected at test program
load time or using the testcond keyboard command. (See “Test
Conditions” on page 15-27 and “Setting Test Conditions Using
the testcond Command” on page 6-10.)
ARGUMENTS None
RETURN VALUE The value of the currently selected test condition or zero if no test
condition selected.
read_test_condition_name
Get name of selected test condition.
SYNOPSIS char * read_test_condition_name()
DESCRIPTION This function returns the name of the currently selected test
condition. Test conditions are defined in the test_conditions
declaration. The current test condition is selected at test program
load time or using the testcond keyboard command. (See “Test
Conditions” on page 15-27 and “Setting Test Conditions Using
the testcond Command” on page 6-10.)
ARGUMENTS None
RETURN VALUE A pointer to the name of the currently selected test condition or
NULL if no test condition selected. This pointer is valid until the
next call to this function.
read_test_status
Read status of last test executed.
SYNOPSIS int read_test_status()
ARGUMENTS None
RETURN VALUE -1, if called before first test statement was executed.
PASSED if last test passed.
FAILED if last test failed.
Both (PASSED | FAILED) if close (passed alternate limits).
read_test_status_alarm
Check if last test executed had an alarm.
SYNOPSIS int read_test_status_alarm()
read_tjd_sample_count
Read the count of the captured samples in TJD stamp_a and stamp_b.
SYNOPSIS void read_tjd_sample_count(stamp_a, stamp_b)
int *stamp_a;
int *stamp_b;
read_tjd_status
Return the status of the last Time-Jitter Digitizer capture.
SYNOPSIS int read_tjd_status()
DESCRIPTION Returns the status of the last Time-Jitter Digitizer (TJD) capture.
On a simulated system this function always returns that the
capture completed.
ARGUMENTS None
RETURN VALUE ERR_TJD_MEAS_COMPLETE—capture completed
ERR_TJD_A_MEAS_NOT_STARTED—A did not start
ERR_TJD_A_MEAS_NOT_COMPLETED—A did not finish
ERR_TJD_B_MEAS_NOT_STARTED—B did not start
ERR_TJD_B_MEAS_NOT_COMPLETED—B did not finish
ERR_TJD_AB_MEAS_NOT_STARTED—A and B did not start
ERR_TJD_AB_MEAS_NOT_COMPLETED—A and B did not finish
ERR_TJD_MEAS_A_NOT_STARTED_B_NOT_COMPLETED—A did not
start, B did not finish
ERR_TJD_MEAS_B_NOT_STARTED_A_NOT_COMPLETED—B did not
start, A did not finish
ERR_TJD_SET_SINCE_LAST_ARM—cannot move data from TJD
until after arming TJD
read_tset_num
Read back tset number of the given tset name.
SYNOPSIS int read_tset_num(tsetname, scm)
char *tsetname;
int scm;
DESCRIPTION This function takes a tset name and SCM and returns the tset
number for that tset name, or 0 if no number has yet been
assigned for that tset name on that SCM. A runtime error will
occur if the SCM number is illegal.
ARGUMENTS tsetname—ptr to tset name
scm—TL_FIRST_SCM or TL_SECOND_SCM
RETURN VALUE Tset number from 1 to 1023, or 0 if no number has been assigned
to that name.
read_uwport_one_port
Read calibrated UWPORT s-parameter.
SYNOPSIS void read_uwport_one_port(port, s_param, mag, arg)
int port;
D_COMPLEX *s_param;
double *mag, *arg;
read_uwport_one_port_cal_std
S-parameter calibration.
SYNOPSIS int read_uwport_one_port_cal_std(pin, cal_std,
filename)
int pin;
TL_UWPORT_CAL_STD cal_std;
char *filename;
RETURN VALUE 0 if OK
-1 if error
read_uwport_one_port_cal_std_slot
S-parameter calibration.
SYNOPSIS int read_uwport_one_port_cal_std_slot(slot, schan,
cal_std, filename)
int slot, schan;
TL_UWPORT_CAL_STD cal_std;
char *filename;
DESCRIPTION This function is used for s-parameter calibration with external cal
standards. For a complete description, see
“read_uwport_one_port_cal_std”. The difference between these
functions is that slot and schan should be substituted for pin.
DIB switching is not supported for slot programming.
ARGUMENTS slot—UWPORT slot
schan—UWPORT schan
cal_std—one of TL_UWPORT_CAL_OPEN,
TL_UWPORT_CAL_SHORT, or TL_UWPORT_CAL_LOAD
filename—name of .s1p file which characterizes the standard
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_one_port_slot”, “read_uwport_one_port_cal_std”,
“read_uwport_two_port_cal_std_forward”,
“read_uwport_two_port_cal_std_reverse”, “tl_uwport_dump”,
“tl_uwport_dump_1port”
read_uwport_one_port_slot
Read calibrated s-parameter.
SYNOPSIS void read_uwport_one_port_slot (slot, schan,
s_param,
mag, arg)
int slot, schan;
D_COMPLEX *s_param;
double *mag, *arg;
read_uwport_raw_one_port
Read uncalibrated s-parameter.
SYNOPSIS void read_uwport_raw_one_port(port, s_param, mag,
arg)
int port;
D_COMPLEX *s_param;
double *mag, *arg;
read_uwport_raw_one_port_slot
Read uncalibrated s-parameter.
SYNOPSIS void read_uwport_raw_one_port_slot(slot, schan,
s_param, mag, arg)
int slot, schan;
D_COMPLEX *s_param;
double *mag, *arg;
s_param, mag, and arg can be set to NULL for any value that is
not desired.
ARGUMENTS slot, schan—UWPORT slot and schan
s_param—s11 in (real, imaginary) format
mag—magnitude of s11
arg—angle of s11 in degrees
read_uwport_raw_two_port_s11
Raw s11 readback function (2-port).
SYNOPSIS int read_uwport_raw_two_port_s11(pin1, pin2,
s_param, mag, arg)
int pin1, pin2;
D_COMPLEX *s_param;
double *mag, *arg;
DESCRIPTION This function reads back the uncalibrated value of s11. It can
only be called after a start uwport: ports= (A, B)
s_params:forward; statement. s11 is the coefficient of
reflection of pin A.
NOTE
Binning on this value is not likely to be useful since it is a very strong function of the test
head hardware and the DIB, dutcard, and socket or probe you are using. Use the calibrated
readback functions instead.
Any of s_param, mag, and arg can be NULL pointers if you do not
need to have their value returned.
ARGUMENTS pin1—A from the example in the description
pin2—B from the example in the description
s_param—s-parameter in (real, imaginary) format
mag—magnitude of s_param
arg—angle (argument) of s_param
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_two_port_s11”
read_uwport_raw_two_port_s11_slot
Uncalibrated s11 readback.
SYNOPSIS int read_uwport_raw_two_port_s11_slot(slot1, schan1,
slot2, schan2, s_param, mag, arg)
int slot1, schan1, slot2, schan2; D_COMPLEX *s_param;
double *mag, *arg;
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_raw_two_port_s11”,
“read_uwport_two_port_cal_std_forward_slot”
read_uwport_raw_two_port_s12
Raw s12 readback function (2-port).
SYNOPSIS int read_uwport_raw_two_port_s12(pin1, pin2,
s_param, mag, arg)
int pin1, pin2;
D_COMPLEX *s_param;
double *mag, *arg;
DESCRIPTION This function reads back the uncalibrated value of s12. It can
only be called after a start uwport: ports= (A, B)
s_params:reverse; statement. s12 is the reverse isolation or
gain from B to A.
NOTE
Binning on this value is not likely to be useful since it is a very strong function of the test
head hardware and the DIB, dutcard, and socket or probe you are using. Use the calibrated
readback functions instead.
Any of s_param, mag, and arg can be NULL pointers if you do not
need to have their value returned.
ARGUMENTS pin1—A from the example in the description
pin2—B from the example in the description
s_param—s-parameter in (real, imaginary) format
mag—magnitude of s_param
arg—angle (argument) of s_param
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_two_port_s12”
read_uwport_raw_two_port_s12_slot
Uncalibrated s12 readback.
SYNOPSIS int read_uwport_raw_two_port_s12_slot(slot1, schan1,
slot2, schan2, s_param, mag, arg)
int slot1, schan1, slot2, schan2; D_COMPLEX *s_param;
double *mag, *arg;
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_raw_two_port_s12”,
“read_uwport_two_port_cal_std_forward_slot”
read_uwport_raw_two_port_s21
Raw s21 readback function (2-port).
SYNOPSIS int read_uwport_raw_two_port_s21(pin1, pin2,
s_param, mag, arg)
DESCRIPTION This function reads back the uncalibrated value of s21. It can
only be called after a start uwport: ports= (A, B)
s_params:forward; statement. s21 is the gain of the device
from A to B.
NOTE
Binning on this value is not likely to be useful since it is a very strong function of the test
head hardware and the DIB, dutcard, and socket or probe you are using. Use the calibrated
readback functions instead.
Any of s_param, mag, and arg can be NULL pointers if you do not
need to have their value returned.
ARGUMENTS pin1—A from the example in the description
pin2—B from the example in the description
s_param—s-parameter in (real, imaginary) format
mag—magnitude of s_param
arg—angle (argument) of s_param
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_two_port_s11”
read_uwport_raw_two_port_s21_slot
Uncalibrated s21 readback.
SYNOPSIS int read_uwport_raw_two_port_s21_slot(slot1, schan1,
slot2, schan2, s_param, mag, arg)
int slot1, schan1, slot2, schan2; D_COMPLEX *s_param;
double *mag, *arg;
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_raw_two_port_s21”,
“read_uwport_two_port_cal_std_forward_slot”
read_uwport_raw_two_port_s22
Raw s22 readback function (2-port).
SYNOPSIS int read_uwport_raw_two_port_s22(pin1, pin2,
s_param, mag, arg)
int pin1, pin2;
D_COMPLEX *s_param;
double *mag, *arg;
DESCRIPTION This function reads back the uncalibrated value of s22. It can
only be called after a start uwport: ports= (A, B)
s_params:forward; statement. s22 is the coefficient of
reflection of pin B.
NOTE
Binning on this value is not likely to be useful since it is a strong function of the test head
hardware and the DIB, dutcard, and socket or probe you are using. Use the calibrated
readback functions instead.
Any of s_param, mag, and arg can be NULL pointers if you do not
need to have their value returned.
ARGUMENTS pin1—A from the example in the description
pin2—B from the example in the description
s_param—s-parameter in (real, imaginary) format
mag—Magnitude of s_param
arg—Angle (argument) of s_param
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_two_port_s11”
read_uwport_raw_two_port_s22_slot
Uncalibrated s22 readback.
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_raw_two_port_s11”,
“read_uwport_two_port_cal_std_forward_slot”
read_uwport_two_port_cal_std_forward
S-parameter calibration.
SYNOPSIS int read_uwport_two_port_cal_std_forward(pin1, pin2,
cal_std, filename)
int pin1, pin2;
TL_UWPORT_CAL_STD cal_std;
char *filename;
If you do not specify a file for the thru standard, it is assumed you
are connecting the ends of the cables directly together.
TL_UWPORT_CAL_ISOLATE
TL_UWPORT_CAL_ISOLATE_ONLY
The isolation measurement is optional. Isolation within the
UWPORT is at the noise floor when the add path is off and may
still be insignificant when the add path is on. However,
characteristics of sockets and probe needles may make isolation
measurements essential.
If you do not do isolation cal, isolation is assumed to be perfect.
If you are calibrating for isolation, the isolate standard is
assumed to be a pair of loads. To avoid redundant
measurements, measurement of the cal standard on pin1 is also
be applied to the 1-port load standard measurement for pin1.
Specify the .s1p file corresponding to the load on pin1 for
filename. Load on pin2 is handled by:
read_uwport_two_port_cal_std_reverse().
If you are measuring isolation but do not want to use the same
load standards you use for 1-port s-parameter calibration, you
can use TL_UWPORT_CAL_ISOLATE_ONLY, which does not
assume the device is any particular standard and only makes an
read_uwport_two_port_cal_std_forward_slot
S-parameter calibration.
SYNOPSIS int
read_uwport_two_port_cal_std_forward_slot(slot1,
schan1, slot2, schan2, cal_std, filename)
int slot1, schan1, slot2, schan2; TL_UWPORT_CAL_STD
cal_std;
char *filename;
not too bad when the add path is on. However, characteristics of
sockets and probe needles may make isolation measurements
essential. If you do not do isolation cal, isolation is assumed to
be perfect.
If you are calibrating for isolation with TL_UWPORT_CAL_ISOLATE,
the isolate standard is assumed to be a pair of loads. For
convenience, the measurement of the cal standard on slot1,
schan1 is also applied to the 1-port load standard measurement.
Specify the .s1p file corresponding to the load on slot1, schan1.
(Load on slot2, schan2 is handled by
read_uwport_two_port_cal_std_reverse_slot().)
If you are measuring isolation but do not want to use the same
load standards you use for 1-port s-parameter calibration, you
can use TL_UWPORT_CAL_ISOLATE_ONLY, which does not
assume the device is any particular standard and only makes an
isolation measurement. It does not matter what file you specify;
"" is fine. If you use 1-port standards, you can also call:
read_uwport_one_port_cal_std_slot(slot1, schan1, <std>, <std file>)
in addition to this 2-port function to avoid measuring the same
standard twice.
Two port calibration is not complete until 1-port calibration is
done on both pins as well.
For quicker calibrations, measure the THRU standard before
measuring the 1-port standards or isolation. This prevents a
redundant calibration of the internal 1-port standards. Making a
2-port measurement (using std_cal:automatic | immediate)
causes the internal THRU and 1-port standards to be measured,
even if the 1-port standards have been measured already.
To calibrate the UWPORT in the forward direction:
1. Connect the calibration standard(s) at the appropriate slots and schans (source
connected to slot1, schan1 and measure connected to slot2, schan2).
2. Set up source and measure instruments (freq, amp, connect).
3. Include the following lines in your test program (or issue them in the immediate mode
window):
start uwport:
port_slots=(slot1,slot2)
port_port_schans=(schan1,schan2)
s_params: forward;
4. Read the results by including the following line in your test program (or issuing it in the
immediate mode window):
read_uwport_two_port_cal_std_forward_slot()
To calibrate the UWPORT in both directions, continue with the following (see
“read_uwport_two_port_cal_std_reverse_slot”):
5. Change the connection (source connected to slot2, schan2; measure connected to
slot1, schan1).
6. Include the following lines in your test program (or issue them in the immediate mode
window):
start uwport:
port_slots=(slot1,slot2)
port_port_schans=(schan1,schan2)
s_params: reverse;
7. Read the results by including the following line in your test program (or issuing it in the
immediate mode window):
read_uwport_two_port_cal_std_reverse_slot()
ARGUMENTS slot1—first slot in port_slots=(slot1,slot2)
schan1—first schan in port_schans=(schan1, schan2)
slot2—second slot in port_slots=(slot1, slot2)
schan2—second schan in port_schans=(schan1, schan2)
cal_std—TL_UWPORT_CAL_THRU, TL_UWPORT_CAL_ISOLATE,
TL_UWPORT_CAL_ISOLATE_ONLY
filename—name of a .s2p file for the thru, .s1p for isolate,
ignored ("") for isolate only
RETURN VALUE 0—OK
-1—Error
SEE ALSO “read_uwport_one_port_cal_std_slot”,
“read_uwport_two_port_cal_std_forward”,
“read_uwport_two_port_s11_slot”
read_uwport_two_port_cal_std_reverse
S-parameter calibration.
SYNOPSIS int read_uwport_two_port_cal_std_reverse(pin1, pin2,
cal_std, filename)
int pin1, pin2;
TL_UWPORT_CAL_STD cal_std;
char *filename;
read_uwport_two_port_cal_std_reverse_slot
S-parameter calibration.
SYNOPSIS int
read_uwport_two_port_cal_std_reverse_slot(slot1,
schan1, slot2, schan2, cal_std, filename)
int slot1, schan1, slot2, schan2; TL_UWPORT_CAL_STD
cal_std;
char *filename;
port_port_schans=(schan1,schan2)
s_params: forward;
7. Read the results by including the following line in your test program (or issuing it in the
immediate mode window):
read_uwport_two_port_cal_std_forward_slot()
ARGUMENTS slot1—first slot in port_slots=(slot1,slot2)
schan1—first schan in port_schans=(schan1, schan2)
slot2—second slot in port_slots=(slot1, slot2)
schan2—second schan in port_schans=(schan1, schan2)
cal_std—TL_UWPORT_CAL_THRU, TL_UWPORT_CAL_ISOLATE,
TL_UWPORT_CAL_ISOLATE_ONLY
filename—name of a .s2p file for the thru, .s1p for isolate,
ignored ("") for isolate only
RETURN VALUE 0—OK
-1—Error
SEE ALSO “read_uwport_one_port_cal_std_slot”,
“read_uwport_two_port_cal_std_reverse”, “tl_uwport_dump”,
“tl_uwport_dump_1port”
read_uwport_two_port_s11
Calibrated s11 readback.
SYNOPSIS int read_uwport_two_port_s11(pin1, pin2, s_param,
mag, arg)
int pin1, pin2;
D_COMPLEX *s_param;
double *mag, *arg;
DESCRIPTION This function returns the calibrated value of s11. s11 is the
coefficient of reflection for pin A when measured during a start
statement like this:
start uwport:
ports = (A, B)
s_params: forward;
Terminations of both ports are taken into account, so both the
forward and reverse measurements must be made before this
function is called.
Any of s_param, mag, and arg can be NULL pointers if you do not
need to have their value returned.
ARGUMENTS pin1—A in the example
pin2—B in the example
s_param—s11 in D_COMPLEX (real, imaginary) format
mag—magnitude of s_param
arg—angle (argument) of s_param
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_two_port_s21”,
“read_uwport_two_port_cal_std_forward”,
“read_uwport_raw_two_port_s11”, “read_uwport_one_port”,
“tl_uwport_dump_port”, “tl_uwport_dump_1port”
read_uwport_two_port_s11_slot
Calibrated s11 readback.
SYNOPSIS int read_uwport_two_port_s11_slot(slot1, schan1,
slot2, schan2, s_param, mag, arg)
int slot1, schan1, slot2, schan2; D_COMPLEX *s_param;
double *mag, *arg;
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_two_port_cal_std_forward_slot”,
“tl_uwport_dump_port”, “tl_uwport_dump_1port”
read_uwport_two_port_s12
Calibrated s12 readback.
SYNOPSIS int read_uwport_two_port_s12(pin1, pin2, s_param,
mag, arg)
int pin1, pin2;
D_COMPLEX *s_param;
double *mag, *arg;
DESCRIPTION This function returns the calibrated value of s12. s12 is the
reverse isolation of the device (gain from B to A) when measured
during a start statement like this:
start uwport:
ports = (A, B)
s_params: reverse;
Terminations of both ports are taken into account so both the
forward and reverse measurements must be made before this
function is called.
Any of s_param, mag, and arg can be NULL pointers if you do not
need to have their value returned.
ARGUMENTS pin1—A in the example
pin2—B in the example
s_param—s-parameter in D_COMPLEX (real, imaginary) format
mag—magnitude of s_param
arg—angle (argument) of s_param
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_two_port_s11”,
“read_uwport_two_port_cal_std_forward”,
“read_uwport_two_port_s12”, “read_uwport_one_port”
read_uwport_two_port_s12_slot
Calibrated s12 readback.
SYNOPSIS int read_uwport_two_port_s12_slot(slot1, schan1,
slot2, schan2, s_param, mag, arg)
int slot1, schan1, slot2, schan2; D_COMPLEX *s_param;
double *mag, *arg;
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_two_port_s12”,
“read_uwport_two_port_cal_std_reverse_slot”,
“tl_uwport_dump”, “tl_uwport_dump_1port”
read_uwport_two_port_s21
Calibrated s21 readback.
SYNOPSIS int read_uwport_two_port_s21(pin1, pin2, s_param,
mag, arg)
int pin1, pin2;
D_COMPLEX *s_param;
double *mag, *arg;
DESCRIPTION This function returns the calibrated value of s21. s21 is the
reverse isolation of the device (gain from B to A) when measured
during a start statement like this:
start uwport:
ports = (A, B)
s_params: forward;
Terminations of both ports are taken into account so both the
forward and reverse measurements must be made before this
function is called.
Any of s_param, mag, and arg can be NULL pointers if you do not
need to have their value returned.
ARGUMENTS pin1—A in the example
pin2—B in the example
s_param—s-parameter in D_COMPLEX(real, imaginary)
format
mag—magnitude of s_param
arg—angle (argument) of s_param
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_two_port_s11”,
“read_uwport_two_port_cal_std_forward”,
“read_uwport_raw_two_port_s21”, “read_uwport_one_port”,
“tl_uwport_dump_port”, “tl_uwport_dump_1port”
read_uwport_two_port_s21_slot
Calibrated s21 readback.
SYNOPSIS int read_uwport_two_port_s21_slot(slot1, schan1,
slot2, schan2, s_param, mag, arg)
int slot1, schan1, slot2, schan2; D_COMPLEX *s_param;
double *mag, *arg;
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_two_port_s21”,
“read_uwport_two_port_cal_std_forward_slot”,
“tl_uwport_dump_port”, “tl_uwport_dump_1port”
read_uwport_two_port_s22
Calibrated s22 readback.
SYNOPSIS int read_uwport_two_port_s22(pin1, pin2, s_param,
mag, arg)
int pin1, pin2;
D_COMPLEX *s_param;
double *mag, *arg;
DESCRIPTION This function returns the calibrated value of s22. s22 is the
coefficient of reflection for pin B measured during a start
statement like this:
start uwport:
ports = (A, B)
s_params: reverse;
Terminations of both ports are taken into account so both the
forward and reverse measurements must be made before this
function is called.
Any of s_param, mag, and arg can be NULL pointers if you do not
need to have their value returned.
ARGUMENTS pin1—A in the example
pin2—B in the example
s_param—s-parameter in D_COMPLEX(real, imaginary)
format
mag—magnitude of s_param
arg—angle (argument) of s_param
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_two_port_s11”,
“read_uwport_two_port_cal_std_forward”,
“read_uwport_raw_two_port_s12”, “read_uwport_one_port”,
“tl_uwport_dump_port”, “tl_uwport_dump_1port”
read_uwport_two_port_s22_slot
Calibrated s22 readback.
SYNOPSIS int read_uwport_two_port_s22_slot(slot1, schan1,
slot2, schan2, s_param, mag, arg)
int slot1, schan1, slot2, schan2; D_COMPLEX *s_param;
double *mag, *arg;
format
mag—magnitude of s_param
arg—angle (argument) of s_param
RETURN VALUE 0 if OK
-1 if error
SEE ALSO “read_uwport_raw_two_port_s22”,
“read_uwport_two_port_cal_std_reverse_slot”,
“tl_uwport_dump_port”, “tl_uwport_dump_1port”
read_uwrecv_amp
Calibrated UWRECV amplitude readback.
SYNOPSIS double read_uwrecv_amp(pin, f_rf)
int pin;
double f_rf;
read_uwrecv_amp_array
Read back calibrated power measurements.
read_uwrecv_amp_array_slot
Read back calibrated power measurements.
SYNOPSIS int read_uwrecv_amp_array_slot(slot, schan,
num_freqs, rf_freqs, results)
int slot;
int schan;
int num_freqs;
double rf_freqs[];
double results[];
read_uwrecv_amp_byif
Read amplitude for IF freq.
SYNOPSIS double read_uwrecv_amp_byif (pin, f_if)
int pin;
double f_if;
DESCRIPTION Reads back a calibrated amplitude from the UWRECV for the
specified IF. The UWRECV must be started before this function
is called to load the capture into digital capture. If the UWRECV
has not been used for a calibrated readback with this setup
before (freq, if_freq, amp, dut connection, and so on) or if
level:immediate, the UWRECV calibrates itself, clobbering
digital capture in the process. This means you cannot use
multiple calibrated read statements one after the other unless
you know that the cal constants have already been obtained. (To
avoid this problem, call read_uwrecv_cal_const() for each
frequency of interest before doing the start and set
level:automatic.) Also, because calibration happens here but
the capture happened in the start statement, the UWRECV
hardware state must not be changed between the start and
read_uwrecv_XXX() statements.
If the f_if you specify when calling this function is not the same
as the if_freq the UWRECV was set to in the last set
statement, you must know whether the IF spectrum is reversed
(high side LO) to determine what frequency a given RF signal will
be digitized at. If the IF spectrum is reversed, the formula is:
f_if = LO - f_rf
LO = freq + if_freq
where:
f_rf = frequency of interest from DUT (into UWMM)
f_if = downconverted f_rf (into digitizer)
freq = UWRECV freq parameter (programmed by user)
if_freq = UWRECV if_freq parameter (calibrated @ 1MHz)
freq if_freq RF IF
read_uwrecv_amp_slot
Slot version of read_uwrecv_amp().
SYNOPSIS double read_uwrecv_amp_slot(slot, schan, f_rf)
int slot;
int schan;
double f_rf;
read_uwrecv_amp_slot_byif
Read calibrated amplitude.
SYNOPSIS double read_uwrecv_amp_slot_byif(slot, schan, f_if)
int slot;
int schan;
double f_if;
read_uwrecv_cal_const
Return calibration constant used by Microwave Receiver.
SYNOPSIS double read_uwrecv_cal_const(uwrecv_pin, freq)
int uwrecv_pin;
double freq;
RETURN VALUE Double specifying calibration constant for last measurement with
specified UWRECV
SEE ALSO “read_uwrecv_cal_const_slot”
read_uwrecv_cal_const_array
Read back the Microwave Receiver calibration constants.
SYNOPSIS int read_uwrecv_cal_const_array(pin, num_freqs,
rf_freqs, cal_factors)
int pin;
int num_freqs;
double rf_freqs[];
double cal_factors[];
read_uwrecv_cal_const_array_slot
Read back the power cal constants.
SYNOPSIS int read_uwrecv_cal_const_array_slot(slot, schan,
num_freqs, rf_freqs, cal_factors)
int slot;
int schan;
int num_freqs;
double rf_freqs[];
double cal_factors[];
read_uwrecv_cal_const_slot
Return calibration constant used by Microwave Receiver.
SYNOPSIS double read_uwrecv_cal_const_slot(slot, schan,
freq);
int slot;
int schan;
double freq;
RETURN VALUE Double specifying calibration constant for last measurement with
the specified UWRECV
SEE ALSO “read_uwrecv_cal_const”
read_uwrecv_fs
Read back the fs a Microwave Receiver is using.
SYNOPSIS double read_uwrecv_fs(pin)
int pin;
read_uwrecv_fs_slot
Read back the fs a Microwave Receiver is using.
SYNOPSIS double read_uwrecv_fs_slot (slot, schan)
int slot;
int schan;
read_uwrecv_if
Read back the if that a UWRECV is using.
SYNOPSIS double read_uwrecv_if(pin)
int pin;
read_uwrecv_if_slot
Read back the if that a UWRECV is using.
SYNOPSIS double read_uwrecv_if_slot(slot, schan)
int slot;
int schan;
read_uwrecv_phase_noise_PSD
Reads back the calibrated phase noise spectral density estimate.
SYNOPSIS double read_uwrecv_phase_noise_PSD(pin, offset_f,
num_avg)
int pin;
double offset_f;
int num_avg;
read_uwrecv_phase_noise_PSD_array
Reads back the calibrated phase noise PSD estimates.
SYNOPSIS int read_uwrecv_phase_noise_PSD_array(pin,
num_freqs, offset_freqs, results, num_avg)
int pin;
int num_freqs;
double offset_freqs[];
double results[];
int num_avg;
read_uwrecv_phase_noise_PSD_array_slot
Reads back the calibrated phase noise PSD estimates.
SYNOPSIS int read_uwrecv_phase_noise_PSD_array_slot(slot,
schan, num_freqs, offset_freqs,results,
num_avg)
int slot;
int schan;
int num_freqs;
double offset_freqs[];
double results[];
double num_avg;
read_uwrecv_phase_noise_PSD_slot
Reads back the calibrated phase noise spectral density estimate.
SYNOPSIS double read_uwrecv_phase_noise_PSD_slot(slot, schan,
offset_f, num_avg)
int slot, schan;
double offset_f;
int num_avg;
read_uwrecv_PSD
Reads back the calibrated power spectral density estimate.
SYNOPSIS double read_uwrecv_PSD(pin, f_rf, num_avg)
int pin;
double f_rf;
int num_avg;
read_uwrecv_PSD_array
Read back the calibrated power spectral density estimates.
SYNOPSIS int read_uwrecv_PSD_array(pin,num_freqs, rf_freqs,
results, num_avg)
int pin;
int num_freqs;
double rf_freqs[];
double results[];
int num_avg;
read_uwrecv_PSD_array_slot
Read back the calibrated power spectral density.
read_uwrecv_PSD_slot
Read the calibrated Power Spectral Density estimate.
SYNOPSIS double read_uwrecv_PSD_slot(slot, schan, f_rf,
num_avg)
int slot;
int schan;
double f_rf;
int num_avg;
read_uwrecv_sample_size
Read back the number of samples a Microwave Receiver is programmed to take.
read_uwrecv_sample_size_slot
Read back the number of samples the UWRECV is programmed to take.
SYNOPSIS double read_uwrecv_sample_size_slot (slot, schan)
int slot;
int schan;
read_uwrecv_uncal_amp
Read the uncalibrated RF amplitude.
SYNOPSIS double read_uwrecv_uncal_amp(pin, f_rf)
int pin;
double f_rf;
read_uwrecv_uncal_amp_array
Read back uncalibrated pwr.
read_uwrecv_uncal_amp_array_slot
Read back uncalibrated power.
SYNOPSIS int read_uwrecv_uncal_array_slot(slot, schan,
num_freqs, rf_freqs, results)
int slot;
int schan;
int num_freqs;
double rf_freqs[];
double results[];
read_uwrecv_uncal_amp_byif
Read the uncalibrated amplitude at frequency.
SYNOPSIS double read_uwrecv_uncal_amp_byif(pin, f_if)
int pin;
double f_if;
read_uwrecv_uncal_amp_slot
Read the uncalibrated amplitude.
SYNOPSIS double read_uwrecv_uncal_amp_slot(slot, schan, f_rf)
int slot;
int schan;
double f_rf;
read_uwrecv_uncal_amp_slot_byif
Read the uncalibrated amplitude at frequency.
SYNOPSIS double read_uwrecv_uncal_amp_slot_byif(slot, schan,
f_if)
int slot, schan;
double f_if;
read_uwrecv_uncal_PSD
Read uncalibrated Power Spectral Density estimate.
SYNOPSIS double read_uwrecv_uncal_PSD(pin, f_rf, num_avg)
int pin;
double f_rf;
int num_avg;
read_uwrecv_uncal_PSD_array
Read uncalibrated Power Spectral Density estimates.
SYNOPSIS int read_uwrecv_uncal_PSD_array(pin, num_freqs,
rf_freqs, results, num_avg)
int pin;
int num_freqs;
double rf_freqs[];
double results[];
int num_avg;
DESCRIPTION Reads back the power spectral density estimate at each of the
RF frequencies in the array, rf_freqs[]. Specify the number of
frequency points of interest in num_freqs.
ARGUMENTS pin—UWRECV (UWMM) or UWPORT pin
num_freqs—Number of valid RF freqs in the array, rf_freqs[]
rf_freqs—Array of RF freqs
results—Array to return the results in
num_avg—Number of avg
read_uwrecv_uncal_PSD_array_slot
Read back uncalibrated Power Spectral Density.
SYNOPSIS int read_uwrecv_uncal_PSD_array_slot(uwrecv_slot,
uwrecv_schan, num_freqs, rf_freqs, results)
int uwrecv_slot;
int uwrecv_schan;
int num_freqs;
double rf_freqs[];
double results[];
int num_avg;
read_uwrecv_uncal_PSD_slot
Read uncalibrated Power Spectral Density estimate.
SYNOPSIS double read_uwrecv_uncal_PSD_slot(slot, schan, f_rf,
num_avg)
int slot;
int schan;
double f_rf;
int num_avg;
read_vmcu
Driver function to read VMCU values.
SYNOPSIS double read_vmcu(vmcu_num, type, location, bplane)
int vmcu_num
enum Vmcu_data_type type;
int *location, bplane;
DESCRIPTION This function reads Video Memory and Control Unit (VMCU)
data from memory or other registers.
ARGUMENTS int vmcu_num—VMCU number
type:
TL_VMCU_PIXEL (read pixel)
TL_VMCU_MIN (read minimum value after minmax process)
TL_VMCU_MAX (read maximum value after minmax
process)
TL_VMCU_MEAN (read mean value after accumulate
process)
TL_VMCU_ACC (read accumulator value after accumulate
process)
TL_VMCU_COUNT (read counter after count process)
location—x-y coordinate array for pixel read.
bplane—bitplane for pixel read.
smprintf
Print a formatted string to the summary report.
SYNOPSIS smprintf(fmt, arg, arg, ...)
char *fmt;
...
tl_add_datalog_output
Add an output stream to datalog.
SYNOPSIS int tl_add_datalog_output(unsigned int key...);
tl_add_datastream
Enable a new data stream.
SYNOPSIS int tl_add_datastream(unsigned int key...);
DESCRIPTION This function is used to start new Datastream from the test
program; and should be used rather than calling the datastream
command processor with -on option from the test program using
the tl_system function.
If the data server is busy, that is processing data from the
previous test program run, this function will wait until the data
server is free.
Use of this function is similar to using the datastream command
processor with -on option; you must minimally specify the
stream_id the datastream criteria (passing, failing, all, and so
on). This function takes a variable number of arguments. The
arguments are of two types:
flags: Indicate what function the user is attempting to perform.
These are represented by macros. They are analagous to '-test',
'-samprate', '-file'. Some flags accept a value. Others may be
used by themselves.
values: These arguments are values to a particular flag and must
immediately follow the particular flag they are used with. The
values are of four types:
1. Unsigned integer array which is terminated by 0 (zero), that is
the last element is zero.
2. Unsigned integer bit vector.
3. NULL terminated character string.
4. Unsigned integer.
Note that none of the values can be equal to zero. Specifying
sample rate and sample limits of 0 effectively turns writing
datalog data to the output, but leaves all of the overhead. Test
lists and ranges cannot be zero.
Table 26-3 describes the macros used for flags and their values.
In the case of flags that accept bit vectors for arguments the
macros used are listed. In general, value macros cannot be used
as flags. Flags that have no corresponding entry in the Value
column may be used without arguments.
Flag Value
TL_DSTRM_LKG_PINS TL_DSTRM_LKG_ALL_PINS
TL_DSTRM_LKG_FAIL_PINS
Flag Value
TL_DSTRM_LKG_STATE TL_DSTRM_LKG_OFF
TL_DSTRM_LKG_ALL
TL_DSTRM_LKG_FAIL
TL_DSTRM_OPEN_SHORT_PINS TL_DSTRM_OPEN_SHORT_ALL_PINS
TL_DSTRM_OPEN_SHORT_FAIL_PINS
TL_DSTRM_OPEN_SHORT_STATE TL_DSTRM_OPEN_SHORT_OFF
TL_DSTRM_OPEN_SHORT_ALL
TL_DSTRM_OPEN_SHORT_FAIL
TL_DSTRM_STDF_MODE TL_DSTRM_S_MODE_LIGHT
TL_DSTRM_S_MODE_HEAVY
TL_DSTRM_S_MODE_XLIGHT
TL_DSTRM_TEST TL_DSTRM_ALL_TEST
TL_DSTRM_PASS_TEST
TL_DSTRM_FAIL_TEST
TL_DSTRM_ANALOG_TEST
TL_DSTRM_DIGITAL_TEST
TL_DSTRM_TEST_RNG unsigned int array, where pairs of elements specify the start
and end of a range
TL_DSTRM_WAFER_MAP No value. Get X/Y data for all devices in sample datalog.
RETURN VALUE 0 (zero) - There was an error either connecting to the data server,
or the arguments were incorrectly specified, or testing has
already begun on this lot.
1 - Success: the command line was correct and the command
successfully processed by the data server.
SIDE EFFECTS None
SEE ALSO “Data Collection” on page 6-1, tl_change_datatastream,
tl_remove_datastream, tl_change_datastream_mode.
tl_addr_r
Read from address in Terabus space.
SYNOPSIS unsigned short tl_addr_r(addr)
int addr;
DESCRIPTION This function reads back the data at the specified Terabus
address.
ARGUMENTS addr—address (offset) in Terabus space
tl_addr_w
Write to pointer into Terabus space.
SYNOPSIS void tl_addr_w(addr, data)
int addr;
unsigned short data;
DESCRIPTION This function writes the data into the specified Terabus address.
ARGUMENTS addr—address (offset) in Terabus space
data—data value to be written
tl_alarmcheck
Check test system for alarms and take action.
SYNOPSIS int tl_alarmcheck(no_strobe)
DESCRIPTION This function checks the test system for alarm conditions and
initiates action (binning, halting the program, and so on). based
on any alarm conditions detected. Note that rdelay() must
have been called before calling tl_alarmcheck().
ARGUMENTS int no_strobe
1–do not strobe test system for alarms
0–strobe test system for alarms
tl_apu_cal_set_interval
Set calibration time interval.
SYNOPSIS void tl_apu_cal_set_interval(interval)
time_t interval;
DESCRIPTION Sets the amount of time the apu calibration is considered valid.
This is used in the above tl_apu_cal_time_check function.
ARGUMENTS time_t interval—Number of seconds. Normally set to 4 * 60
* 60 (four hours).
RETURN VALUE None.
tl_apucal_time
Query time since last UB APU calibration.
SYNOPSIS tl_apucal_time()
tl_apu_read_pin_status
Read status of APU pin number.
SYNOPSIS tl_apu_read_pin_status(pin_number, results_array)
int pin_number;
int *results_array;
DESCRIPTION Reads the status of an APU pin and returns the results in the
parameter results_array. It checks if an APU channel behind
the specified pin number is actually installed and determines
whether an APU alarm has been latched.
The parameter result_array must be large enough to store
values from all test sites. The function does not fill in results for
sites that are not active. The function can be used outside or
inside a serial loop:
int pin_number;
int results_array[TL_SYS_MAX_SITES];
int status;
tl_apu_read_pin_status(pin_number, results_array);
serial {
status = tl_apu_read_pin_status(pin_number,
results_array);
}
If the function is used outside a serial loop and there is more than
one active test site, the return value will be 0.
ARGUMENTS pin_number—APU pin number from pinmap
results_array—Array to store results
tl_asu_present
Check if ASU is present.
SYNOPSIS tl_asu_present(asu_num)
int asu_num;
tl_asu_read_ad
Read ASU A/D value with correction value.
SYNOPSIS tl_asu_read_ad(channel)
int channel;
DESCRIPTION Reads data of Analog Sampling Unit (ASU) A/D strobe value.
ARGUMENTS channel—ASU channel
tl_asu_read_code
Read A/D code.
SYNOPSIS unsigned int tl_asu_read_code(channel)
int channel;
tl_asu_read_lsb
Read LSB value.
SYNOPSIS tl_asu_read_lsb(ch)
int channel;
tl_asy_conn_pmm_vmdiff
Connect the Precision Multimeter (PMM) to matrix lines 7 and 8.
SYNOPSIS void tl_asy_conn_pmm_vmdiff();
DESCRIPTION Connects the PMM 2-wire inputs to matrix lines 7 and 8 in the
AD650 ASY.
ARGUMENTS None
RETURN VALUE None
SIDE EFFECTS Disconnects PMM from measure and accessory busses. Closes
external L7 and L8 connections to meter.
SEE ALSO “tl_asy_disc_pmm”
tl_asy_disc_pmm
Disconnect the Precision Multimeter (PMM) from ASY.
SYNOPSIS void tl_asy_disc_pmm();
tl_ath_area_size
Return area size.
SYNOPSIS int tl_ath_area_size()
DESCRIPTION This function returns the number of data line per area.
ARGUMENTS None
RETURN VALUE Number of data line per area
tl_ath_measure_data_pin_freq
Measure DATA pin frequency on Array Test Head (ATH).
SYNOPSIS int tl_ath_measure_data_pin_freq(pin, cycle)
int pin;
int cycle;
DESCRIPTION Measures the specified data pin frequency to check if the pin is
connected to the probe pin. If this function returns 1, you can
determine the measured frequency or capacitance converted
from frequency using the following functions:
tl_ath_read_counter()—get frequency count
tl_ath_read_frequency()—get frequency
tl_ath_read_capacitance()—get capacitance
The following example checks the line frequency for pin number
1 using the rate 1/16:
func1()
{
extern int tl_ath_measure_data_pin_freq();
extern double tl_ath_read_frequency();
double freq;
if (tl_ath_measure_data_pin_freq(1, 5) == 1)
freq = tl_ath_read_frequency();
}
ARGUMENTS pin—gate pin number
cycle—number of cycle to be counted It must be between 0 and
15.
RETURN VALUE 1—success
0—parameter error, invalid parameter
-1—overflow, counter over flow
-2—timeout, 5 sec passed
SEE ALSO “tl_ath_read_counter”, “tl_ath_read_frequency”,
“tl_ath_read_capacitance”
tl_ath_measure_gate_pin_freq
Measure GATE pin frequency.
SYNOPSIS int tl_ath_measure_gate_pin_freq(pin, cycle, freq)
int pin;
int cycle;
double freq;
DESCRIPTION Measures the specified gate pin frequency to check if the pin is
connected to probe pin. If this function returns 1, you can
determine measured frequency or capacitance converted from
frequency using the following functions:
tl_ath_read_counter()—get frequency count
tl_ath_read_frequency()—get frequency
tl_ath_read_capacitance()—get capacitance
The following example checks the line frequency for pin number
1 using the rate 1/16:
func1()
{
extern int tl_ath_measure_gate_pin_freq();
extern double tl_ath_read_frequency();
double freq;
if (tl_ath_measure_gate_pin_freq(1, 5, 5000000.0) == 1)
freq = tl_ath_read_frequency();
}
tl_ath_read_capacitance
Get capacitance value.
SYNOPSIS double tl_ath_read_capacitance()
tl_ath_read_counter
Get frequency counter value.
SYNOPSIS int tl_ath_read_counter()
ARGUMENTS None
RETURN VALUE Current pin contact counter value
SEE ALSO “tl_ath_measure_gate_pin_freq”,
“tl_ath_measure_data_pin_freq”
tl_ath_read_frequency
Get frequency value.
SYNOPSIS double tl_ath_read_frequency()
ARGUMENTS None
RETURN VALUE Converted frequency
SEE ALSO “tl_ath_measure_gate_pin_freq”,
“tl_ath_measure_data_pin_freq”
tl_awg4800_max_fs_to_6400
Changes fsmax to 6400 MHz from 4800 MHz.
SYNOPSIS void tl_awg4800_max_fs_to_6400(int on)
DESCRIPTION Changes fsmax to 6400 MHz from 4800 MHz or back to 4800
MHz.
ARGUMENTS 1: fsmax = 6400 MHz.
0: fsmax = 4800 MHz.
RETURN VALUE None
tl_awg4800_vca_map_debug
Set VCA mapping debug flags.
SYNOPSIS void tl_awg4800_vca_map_debug( on )
int on;
tl_bbac_disable_clock_error_messages
Disable clock error messages when BBAC forces a clock.
SYNOPSIS void tl_bbac_disable_clock_error_messages()
tl_bbac_disable_dut_connects
Disable connections to the DUT.
SYNOPSIS void tl_bbac_disable_dut_connects()
ccgnd _\__
Relays closed by
| tl_bbac_disable_dut_connects
DC matrix _\__|
|
THADS Bus _\__|
|
Instrument HI _________\__|_____\____ HI pin to DUT
tl_bbac_disable_linearity_corrections
Disable linearity corrections.
SYNOPSIS void tl_bbac_disable_linearity_corrections(pin)
int pin;
DESCRIPTION Disables the BBAC linearity corrections for the specified pin.
ARGUMENTS pin —Pinmap identifier
tl_bbac_enable_clock_error_messages
Enable clock error messages when BBAC forces a clock.
tl_bbac_enable_dut_connects
Enable connections to the DUT.
SYNOPSIS void tl_bbac_enable_dut_connects()
tl_bbac_enable_linearity_corrections
Enable linearity corrections.
SYNOPSIS void tl_bbac_enable_linearity_corrections(pin)
int pin;
DESCRIPTION Enables the BBAC linearity corrections for the specified pin.
ARGUMENTS pin—Pinmap identifier
tl_begin_lot
Begin testing a new lot of devices.
SYNOPSIS tl_begin_lot(dumpflag)
int dumpflag;
DESCRIPTION Calling this function tells IMAGE that the current lot of devices is
complete and that a new lot should be started. When a new
device lot is started, the “parts tested” counters are reset and the
datalog streams are restarted if datalogging is enabled.
This function works by building a Master Information Record
(MIR), an STDF datalog record, and writing it to the datalog
buffer. If the parameter dumpflag is set (that is, nonzero), the
datalog buffer is dumped, causing the new lot to begin
immediately. If dumpflag is not set, the record is not sent
immediately but waits until the next time the datalog buffer is
dumped (presumably the end of the test program run).
For information on STDF records and their use in IMAGE, see
“Standard Test Data Format” on page 24-1 and the Standard Test
Data Format (STDF) Specification, Version 4.
ARGUMENTS dumpflag—controls whether MIR record is sent immediately
tl_begin_new_lot
Begin testing a new lot of devices.
SYNOPSIS void tl_begin_new_lot();
DESCRIPTION Calling this function tells IMAGE that the current lot of devices is
complete, the previous (or current) lot should be closed, and a
new lot should be started. When a new device lot is started, the
“parts tested” counters are reset and the datalog streams are
restarted if datalogging is enabled.
This function first closes the previous lot, by performing an auto
endlot and then initializes the next lot by calling
tl_begin_lot(). tl_begin_lot is called in such a way that it
does not dump the datalog buffer for the new lot. Once
tl_begin_new_lot() is called, the test program can be exited
by calling exit() since this function does not perform the normal
housekeeping done for a test program run. When this function is
called, all housekeeping is done for the previous lot only.
If you call tl_begin_new_lot(), the tl_use_endlot() function
is called during endlot processing. Sometimes flags are reset
and are recognized by begin lot processing on the next iteration
of the test program. If the begin lot processing is before the call
to tl_begin_new_lot(), it is performed on the second iteration
of the test program following the new lot. The following code
example illustrates this:
if (first_run_of_lot) {
Begin lot processing
}
if (Time_for_endlot)
tl_begin_new_lot();
When tl_begin_new_lot() is called, the previous lot is closed
and a new lot is begun from the point where it is called. However,
because of the placement of the first if clause, the
first_run_of_lot code is executed during the second run of
the lot.
Be careful in structuring code when using this function.
ARGUMENTS None
RETURN VALUE None
SIDE EFFECTS Closes the previous lot and performs an auto summary.
Resets all per-run device binning information.
Calls tl_read_prb_card().
SEE ALSO “tl_begin_lot”
tl_bin_fail
Set the device bin to the fail bin.
SYNOPSIS void tl_bin_fail(failbin)
int failbin;
tl_bin_pass
Set the device bin to the pass bin.
SYNOPSIS void tl_bin_pass(passbin)
int passbin;
tl_cal_get_autocal_mode
Return autocal mode.
SYNOPSIS int tl_cal_get_autocal_mode()
DESCRIPTION This function returns the mode of autocal. Autocal can either be
on or off. In addition, calibration state (whether instruments’
calibration data is valid) can be ignored. When calibration state
is ignored, not only does autocal not calibrate instruments, but
the instruments continue to function even if calibration data
expires. When calibration is ignored, the calibration state of the
instrument remains whatever it was at the time the mode was set
to ignored.
NOTE
Operating a test system in IGNORED mode is not recommended. Instrument specs are not
guaranteed when operating in this mode.
NOTE
Operating a test system in FRC_CALFILE mode is not recommended. Instrument specs are
not guaranteed when operating in this mode.
program
TL_AUTOCAL_CAL_AFTER—do an autocal after running test
program
TL_AUTOCAL_CALFILE—use calfile
TL_AUTOCAL_NO_CALFILE—don’t use calfile
TL_AUTOCAL_FRC_CALFILE—force calfile to be read even if
invalid
TL_AUTOCAL_NO_FRC_CALFILE—do not force calfile to be read
TL_AUTOCAL_ALL_COPIES—calibrate every copy of the
instrument
TL_AUTOCAL_PINMAP_ONLY—calibrate only the ones defined in
pinmap
TL_AUTOCAL_CAL_REUSE—Allow the calibration wizard to re-use
data from the previous calibration as it sees fit.
TL_AUTOCAL_CAL_NOREUSE—Don’t use old data when
calibrating
TL_AUTOCAL_CAL_FLUSH—Flush the wizard’s data structures
tl_cal_get_autocal_state
Flag indicating calibration state.
SYNOPSIS int tl_cal_get_autocal_state()
DESCRIPTION This flag indicates the global calibration state of the instruments
used in the current test program.
The flag has the following bitmasked values:
TL_AUTOCAL_UNCALIBRATED—All instruments in calibration
TL_AUTOCAL_CALIBRATED—One or more instruments not in
calibration
TL_AUTOCAL_THIS_RUN—One or more instruments calibrated
SIDE EFFECTS Autocal state does not mean anything when autocal is not turned
on.
tl_cal_get_inst_crit
Get autocal criteria for an instrument.
SYNOPSIS void tl_cal_get_inst_crit(inst, cal_type,
crit_struct)
DESCRIPTION This function gets the calibration criteria for a specific instrument.
ARGUMENTS char *inst—The instrument name (from calibrate -usage)
char *cal_type—Calibration type (from calibrate -usage)
struct tl_cal_criteria *crit_struct—Returns calibration
criteria
double crit—Calibration criteria
int units—Macro from cal_resource.h for type of
calibration criteria (TL_AUTOCAL_TIME or
TL_AUTOCAL_TEMP)
tl_cal_get_inst_mode
Return autocal mode for an instrument.
SYNOPSIS int tl_cal_get_inst_mode(inst, cal_type)
NOTE
Operating a test system in IGNORED mode is not recommended. Instrument specs are not
guaranteed when operating in this mode.
NOTE
Operating a test system in FRC_CALFILE mode is not recommended. Instrument specs are
not guaranteed when operating in this mode.
tl_cal_get_inst_state
Flag indicating instrument calibration state.
SYNOPSIS int tl_cal_get_inst_state(inst, cal_type)
DESCRIPTION This flag indicates the global calibration state of the specified
calibration.
The value of the flag is a logical OR of one or more of the
following values:
TL_AUTOCAL_CALIBRATED—calibration valid
TL_AUTOCAL_UNCALIBRATED—calibration not valid
TL_AUTOCAL_THIS_RUN—calibrated this run
TL_AUTOCAL_INVALID—instrument does not exist
SIDE EFFECTS The state of the instrument does not mean anything when
autocal is not turned on.
tl_cal_get_remaining
Get remaining time or temperature until calibration is required.
SYNOPSIS double tl_cal_get_remaining(inst, cal_type)
DESCRIPTION This function gets the remaining time or temperature from the
calibration criteria before calibration will be required for a specific
instrument. You must declare this fu nction as extern in your test
program.
ARGUMENTS char *inst—The instrument name (from calibrate -usage)
char *cal_type—Calibration type (from calibrate -usage)
tl_cal_inst
Calibrate this instrument.
SYNOPSIS int tl_cal_inst(inst, cal_type)
SIDE EFFECTS A reset all is executed before and after completion of calibration.
This is done to ensure that all instruments which may be used
during calibration are returned to a known state. This may
destroy existing test setups.
tl_cal_report
Print a report of autocal for all instruments.
SYNOPSIS void tl_cal_report()
DESCRIPTION This function prints a status report of the state of autocal for all
instruments in the station window.
ARGUMENTS None
tl_cal_set_autocal_mode
Change autocal mode (on/off/ignore).
SYNOPSIS void tl_cal_set_autocal_mode(mode)
DESCRIPTION This function changes the mode of autocal. Autocal can either be
ON or OFF. In addition, calibration state (whether an
instruments’ calibration data is valid) can be IGNORED. When
calibration state is IGNORED, not only does autocal not calibrate
instruments, but the instruments continue to function even if
calibration data expires. When calibration is IGNORED, the
calibration state of the instrument remains whatever it was at the
time the mode was set to IGNORED.
NOTE
Operating a test system in IGNORED mode is not recommended. Instrument specs are not
guaranteed when operating in this mode.
NOTE
Operating a test system in FRC_CALFILE mode is not recommended. Instrument specs are
not guaranteed when operating in this mode.
tl_cal_set_inst_crit
Change autocal criteria for an instrument.
SYNOPSIS void tl_cal_set_inst_crit(inst, cal_type, crit,
units)
NOTE
Be sure that the criteria you are passing is of type double. Otherwise, the arguments will not
be interpreted correctly, and you may get run-time error such as:
ERROR #11581 - autocal: Illegal unit type for this instrument: 0
tl_cal_set_inst_mode
Change autocal mode for instrument (on/off/ign).
SYNOPSIS void tl_cal_set_inst_mode(inst, cal_type, mode)
NOTE
Operating a test system in IGNORED mode is not recommended. Instrument specs are not
guaranteed when operating in this mode.
NOTE
Operating a test system in FRC_CALFILE mode is not recommended. Instrument specs are
not guaranteed when operating in this mode.
The autocal mode can be set using the following bit masked
flags:
TL_AUTOCAL_ON—autocal is turned on
TL_AUTOCAL_OFF—autocal is turned off
TL_AUTOCAL_IGNORED—error messages will be ignored
TL_AUTOCAL_NOT_IGNORED—error messages will not be ignored
TL_AUTOCAL_CALFILE—use calfile
TL_AUTOCAL_NO_CALFILE—don’t use calfile
TL_AUTOCAL_FRC_CALFILE—force calfile to be read even if
invalid
TL_AUTOCAL_NO_FRC_CALFILE—do not force calfile to be read
TL_AUTOCAL_CAL_REUSE—Allow the calibration wizard to re-use
data from the previous calibration as it sees fit.
TL_AUTOCAL_CAL_NOREUSE—Don’t use old data when
calibrating
By default, for all instruments, autocal mode is:
TL_AUTOCAL_ON | TL_AUTOCAL_CALFILE |
TL_AUTOCAL_NOT_IGNORED | TL_AUTOCAL_NO_FRC_CALFILE |
TL_AUTOCAL_CAL_REUSE
ARGUMENTS char *inst—the instrument name (from calibrate -usage)
char *cal_type—calibration type (from calibrate -usage)
int mode [TL_AUTOCAL_ON | TL_AUTOCAL_OFF]
[TL_AUTOCAL_IGNORED | TL_AUTOCAL_NOT_IGNORED]
[TL_AUTOCAL_CALFILE | TL_AUTOCAL_NO_CALFILE]
[TL_AUTOCAL_FRC_CALFILE | TL_AUTOCAL_NO_FRC_CALFILE]
[TL_AUTOCAL_CAL_REUSE | TL_AUTOCAL_CAL_NOREUSE]
tl_cal_set_uncal
Force instrument to be uncalibrated.
SYNOPSIS void tl_cal_set_uncal(inst, cal_type, onoff)
tl_cdig_set_cal_interval
Set the Serial Bus channel card calibration interval.
SYNOPSIS void tl_cdig_set_cal_interval(interval)
time_t interval;
DESCRIPTION Sets autocal timeout value for the Serial Bus channel card to the
number of seconds specified in interval.
ARGUMENTS interval—number of seconds before boards need
recalibration
RETURN VALUE None
SIDE EFFECTS Sets driver variable to new value.
tl_change_auto
Change the auto debug mode.
SYNOPSIS int tl_change_auto(auto_in)
int auto_in;
DESCRIPTION This function changes the flag for the auto mode of debug.
ARGUMENTS auto_in 1 turns auto on
0 turns auto off
any other returns
RETURN VALUE 1 if auto debug mode is on
0 if auto debug mode is off
tl_change_datalog
Change the setup of the active datalogs.
SYNOPSIS int tl_change_datalog(unsigned int key...);
This function can be called after the first device is tested, but use
caution when doing so.
ARGUMENTS Variable number of arguments, generally in pairs <flag,
argument>. Arguments can be unsigned integer bit vectors,
unsigned integer arrays, or character strings. The entire
argument list must be terminated by NULL. For example:
err_code = tl_change_datalog(TL_DLG_TEST,
TL_DLG_ALL_TEST, TL_DLG_SAMP_RATE, 10, NULL);
See tl_set_datalog() for a complete list of arguments. Only
the following arguments are valid for tl_change_datalog():
TL_DLG_TEST
TL_DLG_TEST_LIST
TL_DLG_TEST_RNG
TL_DLG_TEST_FILE
TL_DLG_TEST_NAME
TL_DLG_SEQ_NAME
TL_DLG_SAMP_RATE
TL_DLG_SAMP_LIMIT
TL_DLG_WAFER_MAP
RETURN VALUE 0—An error occurred, either connecting to the data server or the
arguments were incorrectly specified or testing has already
begun on this lot.
1—Success, the command line was correct and the command
successfully processed.
SIDE EFFECTS Affects the state of datalog.
SEE ALSO “tl_set_datalog”, “tl_get_datalog”, “tl_add_datalog_output”,
“tl_remove_datalog_output”, handle_tl_datalog_commands()
tl_change_datatastream
Change the setup of the specified datastream
err_code = tl_change_datastream(TL_DSTRM_ID,
"streamName" TL_DSTRM_TEST, TL_DSTRM_ALL_TEST,
TL_DSTRM_SAMP_RATE, 10, NULL);
RETURN VALUE 0 - There was an error either connecting to the data server, or the
arguments were incorrectly specified, or testing has already
begun on this lot.
1 - Success, the command line was correct and the command
successfully processed by the data server.
tl_change_site
Change the default debug display site number.
SYNOPSIS tl_change_site()
DESCRIPTION This function changes the number of the default debug display
site.
ARGUMENTS site_num—the default debug display site number
tl_close_mux
Close the mux.
SYNOPSIS void tl_close_mux();
tl_cmu_get_roi_height
Get height of ROI in CMU.
SYNOPSIS int tl_cmu_get_roi_height()
tl_cmu_get_roi_width
Get width of ROI in CMU.
SYNOPSIS int tl_cmu_get_roi_width()
tl_cmu_get_roi_x_pos
Get X position of first pixel in CMU.
SYNOPSIS int tl_cmu_get_roi_x_pos()
ARGUMENTS None
RETURN VALUE X position
tl_cmu_get_roi_y_pos
Get Y position of first pixel in CMU.
SYNOPSIS int tl_cmu_get_roi_y_pos()
tl_create_tsr_for_ival
In the STDF output stream, create TSR records for intermediate values.
SYNOPSIS void tl_create_tsr_for_ival(int flag);
tl_d_dump_all_patterns
Dump all digital patterns.
SYNOPSIS void tl_d_dump_all_patterns()
tl_d_no_timing_reset
Flag to disable timing resets.
SYNOPSIS extern int tl_d_no_timing_reset;
DESCRIPTION Normally, the test system reset function called before each test
program run resets T0 and C0 dividers to defaults. In addition, a
software flag marks the channel edge values as “not
programmed” so they do not show up on the display.
If this flag is set to 1, the test system reset leaves all edge values
and T0 and C0 dividers intact between test program runs and
treats edge values as already programmed. This increases the
speed of the test program by not having to program timing every
run.
Note that this means a different station may reprogram the
timing, causing the program to execute incorrectly. Be sure to
only use this flag in a single-station environment.
Master clock frequency and An clock dividers are still reset and
must be reprogrammed every run.
ARGUMENTS None
RETURN VALUE None
tl_d_share_enable
Enable pattern sharing for digital subsystem.
SYNOPSIS void tl_d_share_enable(on_off)
int on_off;
DESCRIPTION Normally when patterns are loaded on two stations, they are
loaded twice and use double the pattern memory. If the same
patterns are loaded on both stations, the patterns can be shared
to reduce memory usage.
tl_databits_address_set_board
Set board address.
SYNOPSIS tl_databits_address_set_board(primary, secondary,
bd)
int primary;
int secondary;
int bd;
DESCRIPTION This function sets the board address of expansion databits in the
RTP slot. Default board addresses are:
databits 49 - 84: 0305 W1-W3
databits 85 - 120: 0305 W4-W6
databits 121 - 156: 0304 W1-W3
databits 157 - 192: 0304 W4-W6
ARGUMENTS primary—primary address
secondary—secondary address(1 or 4)
bd—0 - databits 49 - 84
1 - databits 85 - 120
2 - databits 121 - 156
3 - databits 157 - 192
RETURN VALUE None
tl_databits_unlock_code_set
Set unlock code of databits.
SYNOPSIS tl_databits_unlock_code_set(code)
int code;
DESCRIPTION This function sets unlock code of expansion databits in RTP slot.
ARGUMENTS code—!=0 unlock code
==0 disable
RETURN VALUE None
tl_databits_unlock_code_set_board
Set unlock code of databits.
DESCRIPTION This function is used to set the unlock code of expansion databits
in the RTP slot.
Note that IMAGE probes using the following unlock code for
expansion SDB:
databits 49 - 84: 0105
databits 85 - 120: 0106
databits 121 - 156: 0107
databits 157 - 192: 0110
If another value is used, the confsim file for databits may not be
created correctly.
ARGUMENTS code—unlock code
bd— 0 - databits 49 - 84
1 - databits 85 - 120
2 - databits 121 - 156
3 - databits 157 - 192
RETURN VALUE None
tl_datalog_endseq_on_fail
Have IMAGE datalog (or not datalog) the EPS record for a sequencer with a failing test.
SYNOPSIS int tl_datalog_endseq_on_fail(int yesNo);
tl_datalog_ival
Datalog intermediate values.
tl_datalog_start_new_device
Begin datalog for new device.
SYNOPSIS int tl_datalog_start_new_device()
DESCRIPTION Use this function for programs which test multiple devices within
a single run of the main() function, or those which generate
multiple devices worth of datalog data with a single run.
Call this function after a given testing sequence is complete, in
other words, after the execution of one or more sequencers and
a sort bin statement. When called, it re-enables testing (that is,
clears the current bin assignment and re-enables all sites),
dumps the datalog buffer for the completed device, and restarts
datalog for a new device. The following example generates 10
devices’ worth of data using a single execution of main():
main() {
int i;
for (i = 0; i < 10; i++) {
if (i != 0) tl_datalog_start_new_device();
first_sequencer();
second_sequencer();
sort bin;
}
}
Note that none of the code in this example will index a handler or
prober. Indexing takes place after main() is complete.
This function assumes that a sort bin statement has been
performed for the current test sequence. If a sort bin has not
been performed, it does not perform datalog reinitialization and
instead returns the value FALSE (0). If the operation succeeds,
it returns TRUE (1).
ARGUMENTS None
RETURN VALUE TRUE (1) reinitialization performed
FALSE (0) no operation performed due to no previous
sort bin
SIDE EFFECTS Flushes the datalog buffer, clears any bin assignments
tl_dccal_dump_constants
Dump DC calibration constants to a file.
SYNOPSIS void tl_dccal_dump_constants()
tl_dccal_meter
Calibrate voltmeter.
SYNOPSIS int tl_dccal_meter(pany_failed)
int arg;
int *pany_failed;
tl_dc_cal_set_interval
Set the DC Subsystem calibration time interval.
SYNOPSIS void tl_dc_cal_set_interval(interval)
time_t interval;
tl_dccal_src
Calibrate a single source in the DC Subsystem.
SYNOPSIS int tl_dccal_src(arg, src)
int arg, src;
AD212 missing or
AD330 missing or
AD330 data retention failed
SIDE EFFECTS Function does a reset all.
tl_dccal_status
Return the calibration status of each dc instrument.
SYNOPSIS int tl_dccal_status(inst)
int inst;
tl_dccal_subr
Calibrate DC Subsystem.
SYNOPSIS int tl_dccal_subr(arg)
int arg;
tl_dccal_time
Read time and result of last DC Subsystem calibration.
SYNOPSIS int tl_dccal_time()
tl_dc_meter_tsy_digitize
Digitize with DC meter and trigger switchyard.
SYNOPSIS int tl_dc_meter_tsy_digitize(sample_rate,
sample_size, data, trigger, timeout)
int sample_rate;
int sample_size;
int data[];
int trigger;
double timeout;
DESCRIPTION Runs a loop taking measurement with the DC Meter, and stores
them in the user’s array. Uses the Trigger Switchyard and
Programmable Clock to generate a stable sample rate, which
strobes the meter. A highly optimized inner loop can sustain
5000 samples/s; higher values may cause errors. The most
common error is a “premature” trigger. That is, the CPU was
delayed in reading a value out of the meter, and the next strobe
occurred while reading the previous values. Tests for this
condition, and for timeouts waiting for trigger edges, are
performed and an indication returned.
NOTE
All samples are uncalibrated, raw integers.
tl_dcvm_cal_status
Return cal status of dc voltmeter.
SYNOPSIS int tl_dcvm_cal_status()
tl_debug_site
Get the number of the debug display site.
SYNOPSIS int tl_debug_site()
DESCRIPTION Returns the number of the current debug display site. It replaces
the global variable tl_display_site.
ARGUMENTS None
RETURN VALUE An integer holding the debug display number
tl_declare_event
Send a FIRMS event message to event manager.
SYNOPSIS int tl_declare_event(event, args)
char *event, *argstr;
tl_delay
Execute a delay.
SYNOPSIS void tl_delay(wtime)
register int wtime;
tl_dfc_disable
Disable Device Focused Checker execution.
SYNOPSIS void tl_dfc_disable();
tl_dfc_enable
Enable Device Focused Checkers.
SYNOPSIS void tl_dfc_enable();
DESCRIPTION This function tells IMAGE to enable the Device Focused Checker
utility.
ARGUMENTS None
RETURN VALUE None
SIDE EFFECTS Enables DFC utility.
SEE ALSO “tl_dfc_disable”
tl_dfc_fail_run
Return true if DFC failed at last execution.
SYNOPSIS int tl_dfc_fail_run();
DESCRIPTION This function returns the value of the fail_last flag. This flag is
set to true if any instrument failed during the last DFC execution.
It is cleared at the start of the DFC run.
ARGUMENTS None
RETURN VALUE True if any DFC instrument failed during the last execution.
tl_dfc_inst_status
Return instrument status.
SYNOPSIS TL_DFC_STATUS tl_dfc_inst_status (inst_key)
TL_DFC_INST inst_key;
DESCRIPTION This function returns the status (Pass, Fail, NotRun, or Error)
for the given instrument.
ARGUMENTS inst_key—instrument to check
tl_dfc_request
Request Device Focused Checker execution.
SYNOPSIS void tl_dfc_request()
DESCRIPTION This function tells IMAGE to execute the DFC utility at the next
run. If the DFC utility is disabled, it does nothing.
ARGUMENTS None
RETURN VALUE None
SIDE EFFECTS If DFC is enabled, it executes on the next run.
tl_disable_hp_after_rte_off
Turn off autodisable of handler or prober on a run time error (RTE).
SYNOPSIS int tl_disable_hp_after_rte_off(void);
tl_disable_hp_after_rte_on
Turns on autodisable of handler or prober on a run time error (RTE).
SYNOPSIS int tl_disable_hp_after_rte_on(void);
DESCRIPTION If a run time error (any run time error not being ignored) is
encountered during the run of a test program the handler or
prober is automatically disabled. To re-enable the handler or
prober, you must issue a handlerconf -enable ... command
for that station.
ARGUMENTS None
RETURN VALUE 1—Handler/prober will be disabled if a run time error is
encountered
0—Handler/prober will not be disabled if a run time error is
encountered
SIDE EFFECTS Enables the feature which automatically disables a handler or
prober if a run time error is encountered.
tl_disable_hp_after_rte_state
Return the state of autodisable of handler or prober if a run time error occurs during a run.
SYNOPSIS int tl_disable_hp_after_rte_state(void)
tl_display_autosum_setup
Displays autosummary setup in station window.
SYNOPSIS int tl_display_autosum_setup();
tl_dlg_endwafer
Datalog end of wafer.
SYNOPSIS void tl_dlg_endwafer()
DESCRIPTION Declare the end of wafer event and construct and send the Wafer
Results Record (WRR) to dataserv.
ARGUMENTS None
RETURN VALUE None
SIDE EFFECTS Declares end of wafer event and puts WRR into datalog buffer.
tl_dlg_startwafer
Datalog start of wafer.
SYNOPSIS void tl_dlg_startwafer()
tl_dps_set_hotswitch_protection
Set test head relay delay flag and two kelvin flag.
SYNOPSIS void tl_dps_set_hotswitch_protection(delay_flag,
two_kelvin_flag)
int delay_flag;
int two_kelvin_flag;
DESCRIPTION This function gives you control over whether IMAGE waits for the
test head relays to open after executing an DPS disconnect
statement. If the delay_flag value passed to this function is
TRUE, IMAGE issues a delay to be sure the test head relays
have opened and avoid a possible hot switch. The
two_kelvin_flag tells IMAGE to allow/disallow connects with
two points of kelvin. This can also avoid a hotswitch in certain
situations.
With every DPS reset, these flags are reset to the default
settings:
delay_flag—FALSE
two_kelvin_flag—TRUE
tl_dsp_check_mem
Report on the DSP buffer and memory usage.
SYNOPSIS tl_dsp_check_mem()
DESCRIPTION This function dumps the current memory and buffer usage for the
array processor.
ARGUMENTS None
RETURN VALUE None
tl_dsp_dump_info
Print DSP memory and buffer information.
SYNOPSIS tl_dsp_dump_info();
tl_dsp_get_buffer_address
Get the real memory address of the DSP buffer.
SYNOPSIS (void*)tl_dsp_get_buffer_address()
DSP_BUFFER buf;
DESCRIPTION This function retrieves the real memory address of a buffer when
running under the simulator or with an MC860. An error results if
executed when a ZIP3232 is present. You are expected to cast
the returned pointer to the appropriate type.
NOTE
Take care in using this address. None of the error checking built into the DSP environment
is available when operating on data through its pointer.
RETURN VALUE The base pointer to the actual position in memory where the
DSP buffer data is stored
tl_dsp_get_mem_size
Report the size of usable data memory in bytes.
SYNOPSIS unsigned tl_dsp_get_mem_size()
DESCRIPTION Report the amount of data memory available to the user. Does
not take into account user allocated permanent buffers. Memory
size is
mem_size = tom - bom - dts - rf;
where:
tl_dsp_query_ap_type
Determine the type of DSP engine.
SYNOPSIS int tl_dsp_query_ap_type();
tl_dsp_sync
Synchronize the test program and Array Processor.
SYNOPSIS int tl_dsp_sync()
DESCRIPTION Wait until the Array Processor has completed an operation that
has been queued so that an asynchronous operation will happen
correctly. This function is called automatically by certain IMAGE
language statements such as DSP buffer create and move.
ARGUMENTS None
RETURN VALUE None
tl_dump_configuration
Writes valid configuration file to destination file.
NAME tl_dump_configuration
tl_dump_data
Dump datalog buffer.
SYNOPSIS tl_dump_data()
tl_edge_binary_search
Edge binary search.
SYNOPSIS double tl_edge_binary_search(
char *pattern_name,
char *start_vector_label,
char *pin_list[],
char *edgeset_list[],
int edge,
double from,
double to,
double resolution
);
tl_edge_linear_search
Edge linear search.
SYNOPSIS double tl_edge_linear_search(
char *pattern_name,
char *start_vector_label,
char *pin_list[],
char *edgeset_list[],
int edge,
double from,
double top,
double resolution
);
DESCRIPTION A linear search starts at one boundary and steps by the specified
resolution until the stop condition changes state. The linear
search algorithm allows the stop condition to be approached
either way: until a passing device starts failing, or until a failing
device starts passing. Once the stop condition changes state,
the search loop is terminated. The last pass parameter value is
returned.
In a linear search, the parameter is varied linearly in a stepwise
fashion.
A linear search has some disadvantages which must be kept in
mind when using it. If the resolution is small, the search can be
time-consuming because of the number of steps required. If the
parameter changes over time (due to device heating or other
factors), an inaccurate reading can result. If the device is failing
(or passing) over a large range, the entire search loop must be
run for several different points to reach this conclusion. The
algorithms which are better for most applications are the binary
search.
For example:
char *pin_list[] = { "PIN3", "1", NULL };
char *edgeset_list[] = { "ES2", "3", "ES4", NULL };
double pass_value;
tl_efd_is_enabled
Determine if Enhanced Functional Datalog setups exist.
SYNOPSIS int tl_efd_is_enabled(void);
tl_endlot
Close out the current lot and start a new lot.
SYNOPSIS int tl_endlot()
DESCRIPTION This function has the same effect as issuing the summary -auto
command from a station window. It closes out the current lot,
causes a summary report to be printed for that lot, and then
increments the lot ID (if the lot ID is numeric).
Note that sending a summary report to the printer and to an
STDF file is the default action for the setauto command, but you
can instead write to an ASCII file. For more information on doing
this, see “Automatic Summary Reports Using the setauto
Command” on page 6-96. If no parts have been tested in the
current lot, the auto endlot signal is ignored and no action is
taken.
This function is equivalent to doing an endlot (summary -final,
summary -auto, or setauto) from a station window or pressing
the END LOT button on the Start Switch. It increments the lot (or
sublot) number (if one exists) and generates a final summary
report for lot just closed.
ARGUMENTS None
RETURN VALUE None
SEE ALSO “tl_begin_lot”
tl_error_user
Define a user error message.
SYNOPSIS tl_error_user(umess, acode)
char * umess;
int acode;
DESCRIPTION This function can be used to define your own errors and call an
error function from a test program. This has the same effect as if
the system was handling a predefined run-time error. When this
function is executed, the error message you specify appears in
the error region and the action you specify is taken.
ARGUMENTS umess—A pointer to an error message you have defined.
acode—Action code that indicates the action you want the
system to take. The action codes are:
ERROR_FORCE_BIN—Bin the device in the error bin.
ERROR_FORCE_FAIL—Force the current test to fail.
ERROR_IGNORE—Ignore this error.
tl_exch_comment
Write comment to simulator stimulus stream
SYNOPSIS void tl_exch_comment(fmt, va_alist)
char *fmt;
va_dcl
tl_exch_is_dvx_mode
Determine if ExChange is in DVX mode.
SYNOPSIS int tl_exch_is_dvx_mode()
tl_exch_is_enabled
Determine if ExChange is enabled.
SYNOPSIS int tl_exch_is_enabled()
tl_fflush_nowait
Execute fflush without resetting nowait mode.
SYNOPSIS int tl_fflush_nowait(FILE *iop)
tl_force_jobstats
Force test program statistics even on handler runs.
SYNOPSIS tl_force_jobstats()
tl_fvs_cal_dump
Dump the FVS calibration table.
SYNOPSIS void tl_fvs_cal_dump(unit)
int unit;
tl_get_autocal_on
Return TRUE if autocal is on, FALSE if off.
SYNOPSIS int tl_get_autocal_on()
tl_get_autosetup
Retrieves setup information from data server.
SYNOPSIS int tl_get_autosetup(unsigned int key,
...)
all_tests = 0,
fail_tests = 0,
autosmy_off = 0;
tl_get_autosetup(SETAUTO_FILE, &file, SETAUTO_STDF, &stdf,
SETAUTO_STATWIN, &statwin,
SETAUTO_AUTOSUM_OFF, &autosmy_off,
SETAUTO_PRINTER, &printer,
SETAUTO_FAIL_TESTS_ONLY, &fail_tests,
SETAUTO_ALL_TESTS, &all_tests,
SETAUTO_FILE_NAME, &filename,
SETAUTO_PRINTER_NAME, &printername,
SETAUTO_SMY_FORMATTER, &formatter,
NULL);
if (autosmy_off)
printf("Autosummary disabled and off.\n");
if (file || *filename)
printf("Auto summary will be written to file %s\n",
filename ? filename : " ");
if (printer || *printername)
printf("Auto summary to printer %s\n",
printername ? printername : " ");
if (stdf)
printf("Auto summary will be written to STDF.\n");
if (statwin)
printf("Auto summary will be written to Station Window.\n");
if (*formatter)
printf("Summaries will be formatted by: %s\n", formatter);
if (fail_tests)
printf("Failing tests will appear on summary reports.\n");
if (all_tests)
printf("All tests will appear on summary reports.\n");
In the above example, all possible parameters are queried and
the results displayed to the operator. It is not necessary to query
all parameters. You can also determine the state of only the
parameters which are of interest to you. For example, you could
determine whether the autosummary is on or off by the following
function call:
tl_get_autosetup(SETAUTO_AUTOSUM_OFF, &autosmy_off, NULL);
if (autosmy_off)
printf("Autosummary disabled and off.\n");
else
printf("Autosummary enabled.\n");
To determine whether autosummaries will be written to the
station window, use the following function call:
tl_get_autosetup(SETAUTO_STATWIN, &statwin, NULL);
if (statwin)
printf("Auto summary output to Station Window.\n");
ARGUMENTS The following table summarizes the type of argument which must
follow each parameter. The argument must be terminated by
NULL.
tl_get_burn_tim
Get the burn-in time of the parts being tested.
SYNOPSIS int tl_get_burn_tim()
DESCRIPTION This function returns the burn-in time of the parts being tested
and returns them as an integer representing the number of
minutes the parts were burnt in.
ARGUMENTS None
RETURN VALUE Integer number of minutes of burn-in time.
tl_get_cabl_id
Get the interface cable ID of the parts being tested.
SYNOPSIS char * tl_get_cabl_id(s)
char s[];
DESCRIPTION This function returns the interface cable ID of the parts being
tested as a string.
ARGUMENTS An array in which to place the interface cable ID string
RETURN VALUE Its argument (the interface cable ID string)
tl_get_cabl_typ
Get the interface cable type of the parts being tested.
SYNOPSIS char * tl_get_cabl_typ(s)
char s[];
DESCRIPTION This function returns the interface cable type of the parts being
tested as a string.
ARGUMENTS An array in which to place the interface cable type string
RETURN VALUE Its argument (the interface cable type string)
tl_get_cont_id
Get the contactor ID of the parts being tested.
SYNOPSIS char * tl_get_cont_id(s)
char s[];
DESCRIPTION This function returns the contactor ID of the parts being tested as
a string.
ARGUMENTS An array in which to place the contactor ID string
RETURN VALUE Its argument (the contactor ID string)
tl_get_cont_typ
Read the contactor type of the parts being tested.
SYNOPSIS char * tl_get_cont_typ(s)
char s[];
DESCRIPTION This function returns the contactor type of the parts being tested
as a string.
ARGUMENTS An array in which to place the contactor type string
RETURN VALUE Its argument (the contactor type string)
tl_get_data_collection_state
Return the state of data collection.
SYNOPSIS int tl_get_data_collection_state()
DESCRIPTION This function evaluates the current state of data collection and
returns a value based on this state. It returns the appropriate
values regardless of what form of data collection is being used—
datalog, datastream, or histogram. Be careful in placing the call
to this function. For example, if you place this function in a test
function following a call to set testf_cond: datalog:
tl_get_data_collection_streams
Get names/IDs of currently enabled data collection streams.
SYNOPSIS char **tl_get_data_collection_streams()
DESCRIPTION This function uses the list of currently enabled data collection
streams returned by tl_update_data_collection_state() to
create an array of pointers to the names/IDs of the streams.
Datalog streams are identified by the following macros:
TL_DATALOG_STATWIN—datalog to station window
TL_DATALOG_DATAWIN—datalog to datalog window
TL_DATALOG_STDF—datalog to STDF file
TL_DATALOG_FILE—datalog to text file
TL_DATALOG_PRINTER—datalog to printer
TL_HISTOGRAMMING—histogram stream
tl_get_datalog
Get information regarding setup of datalog.
SYNOPSIS int tl_get_datalog(unsigned int key, ...)
TL_DLG_OUTPUT_FMT char **
RETURN VALUE 0—Error. Any values returned through the argument list are
considered invalid.
1—Success. Values returned through the argument list can be
valid depending on datalog setup.
SIDE EFFECTS Sends a command to IMAGE to retrieve the datalog setup.
SEE ALSO Description of tl_get_datalog in “Retrieving Datalog Setup
Information” on page 6-68 and “tl_set_datalog”
tl_get_datalog_directory
Get the name of the directory which dataserv is writing datalog files to.
SYNOPSIS char *tl_get_datalog_directory(int update);
tl_get_datalog_directory_for_stream
Get directory a stream is writing a file to.
SYNOPSIS char * tl_get_datalog_directory_for_stream
(char *sname);
DESCRIPTION This function looks at the filename associated with a file based
stream (either text or STDF) and returns NULL if the stream does
not exist or the stream is not writing a file.
The stream filename is parsed and the directory path associated
with it, if any, is returned. If the filename is not fully rooted, the
default datalog directory is returned, which is where the file is
written if not fully rooted.
If this information must be saved, be sure to copy it to some other
storage, as subsequent calls to this function will overwrite the
memory returned.
ARGUMENTS sname—stream name.
tl_get_datastream
Get information regarding setup of datastream
SYNOPSIS int tl_get_datastream(unsigned int key, ...);
Instead of:
tl_get_datastream(TL_DSTRM_ID, "streamname",
TL_DSTRM_PROG_NAME, &program_name, NULL);
tl_get_datastream(TL_DSTRM_ID, "streamname",
TL_DSTRM_TEST, &stream_crit, NULL);
do:
tl_get_datastream(TL_DSTRM_ID, "streamname",
TL_DSTRM_PROG_NAME, &program_name, TL_DSTRM_TEST,
&stream_crit, NULL);
TL_DLG_FILE_NAME char **
TL_DLG_PRINTER_NAME char **
TL_DSTRM_ID char *
TL_DSTRM_STDF_NAME char **
RETURN VALUE 0 - Error: Any values returned through the argument list are
considered invalid.
1 - Success: Values returned through the argument list may be
valid depending on datalog setup.
SIDE EFFECTS Sends a command to the data server to retrieve the datastream
setup.
SEE ALSO “Data Collection” on page 6-1, tl_add_datastream,
tl_set_datalog.
tl_get_degrees_d
Convert a double value from radians to degrees.
SYNOPSIS double tl_get_degrees_d(radian)
double radian;
tl_get_degrees_f
Convert a float value from radians to degrees.
SYNOPSIS float tl_get_degrees_f(radian)
float radian;
DESCRIPTION This function takes any floating point value representing radians
and returns the equivalent value in degrees.
ARGUMENTS radian—the value in radians to be converted to degrees
RETURN VALUE A floating point number from 0 through 360 representing degrees
tl_get_dib_id
Get the DIB board type of the parts being tested.
SYNOPSIS char * tl_get_dib_id(s)
char s[];
DESCRIPTION This function returns the DIB ID of the parts being tested as a
string.
NOTE
For this function to return a meaningful value, one of the following must first occur:
-The first part has been datalogged.
-The program explicitly has called tl_read_and_set_dib_info().
-The program explicitly has called tl_set_dib_id().
tl_get_dib_typ
Get the DIB board type of the parts being tested.
SYNOPSIS char * tl_get_dib_typ(s)
char s[];
DESCRIPTION This function returns the DIB board type of the parts being tested
as a string.
ARGUMENTS An array in which to place the DIB board type string
RETURN VALUE Its argument (the DIB board type string)
SEE ALSO “tl_get_dib_id”, “tl_read_and_set_dib_info”
tl_get_dsgn_rev
Get the device design revision of the parts being tested.
SYNOPSIS char * tl_get_dsgn_rev(s)
char s[];
DESCRIPTION This function returns the design revision of the parts being tested
as a string.
ARGUMENTS An array in which to place the design revision string.
RETURN VALUE Its argument (the design revision string)
tl_get_eng_id
Get the engineering lot ID of the parts being tested.
SYNOPSIS char * tl_get_eng_id(s)
char s[];
DESCRIPTION This function returns the engineering lot ID of the parts being
tested as a string.
ARGUMENTS An array in which to place the engineering lot ID string
RETURN VALUE Its argument (the engineering lot ID string)
tl_get_extr_id
Read the extra equipment ID of the parts being tested.
SYNOPSIS char * tl_get_extr_id(s)
char s[];
DESCRIPTION This function reads the extra equipment ID of the parts being
tested as a string.
ARGUMENTS An array in which to place the extra equipment ID string
RETURN VALUE Its argument (the extra equipment ID string)
tl_get_extr_typ
Get the extra equipment type of the parts being tested.
DESCRIPTION This function returns the extra equipment type of the parts being
tested as a string.
ARGUMENTS An array in which to place the extra equipment type string
RETURN VALUE Its argument (the extra equipment type string)
tl_get_facil_id
Get the test facility ID of the parts being tested.
SYNOPSIS char * tl_get_facil_id(s)
char s[];
DESCRIPTION This function returns the test facility ID of the parts being tested
as a string.
ARGUMENTS An array in which to place the testing facility ID string
RETURN VALUE Its argument (the testing facility ID string)
tl_get_famly_id
Get the device family ID of the parts being tested.
SYNOPSIS char * tl_get_famly_id(s)
char s[];
DESCRIPTION This function returns the device family ID of the parts being
tested as a string.
ARGUMENTS An array in which to place the device family ID string
RETURN VALUE Its argument (the device family ID string)
tl_get_floor_id
Get the test floor ID of the parts being tested.
SYNOPSIS char * tl_get_floor_id(s)
char s[];
DESCRIPTION This function returns the test floor ID of the parts being tested as
a string.
ARGUMENTS An array in which to place the test floor ID string
RETURN VALUE Its argument (the test floor ID string)
tl_get_flow_id
Get the test_flow ID of the parts being tested.
SYNOPSIS char * tl_get_flow_id(s)
char s[];
DESCRIPTION This function returns the test flow ID of the parts being tested as
a string.
ARGUMENTS An array in which to place the test flow ID string
RETURN VALUE Its argument (the test flow ID string)
tl_get_hbin_device_count
Return the device count for the desired hardware bin.
SYNOPSIS int tl_get_hbin_device_count(hbin)
int hbin;
DESCRIPTION This function returns the device count of the given hardware bin
as of the last device(s) tested. It does not include the current
device(s), even if it is used after the sort bin statement.
ARGUMENTS hbin—Hardware bin for device count
tl_get_hp_name
Get the name of the handler or prober.
SYNOPSIS int tl_get_hp_name(char * name)
DESCRIPTION Returns the name of the handler or prober being used in the
current lot using the function argument. Unless set using
tl_set_hp_name(), this is the name used in the last
handlerconf -connect <handler_name> command.
tl_get_hp_type
Get the name of the handler or prober.
SYNOPSIS int tl_get_hp_type(char * type)
DESCRIPTION This function returns the name of the handler or prober being
used in the current lot using the function argument. Unless set
using tl_set_hp_type(), this is e the name used in the last
handlerconf -connect <handler_name> command.
tl_get_hsd_type
Return type of digital subsystem.
SYNOPSIS int tl_get_hsd_type()
DESCRIPTION This function returns the setup type of the digital subsystem or -
1 if there is no digital subsystem or its type could not be
determined.
ARGUMENTS None
RETURN VALUE One of the macros defined in hsd50.h for this function.
Commonly used values include:
TL_HSD50_25 HSD25 (HSD50 architecture with 25 MHz
clock)
TL_HSD50_50 Standard HSD50
TL_CAT_100 Standard Catalyst digital
If none of these is correct -1 is returned.
tl_get_inker
Retrieve the inker number to fire when a bin result is received on a site.
SYNOPSIS int tl_get_inker(int stn, int site, int bin)
DESCRIPTION This function references the inker map for stn and returns the
inker number to fire when a particular bin result bin is received
on site. If no inker map is created, a 0, is returned. This result
will not fire any inker.
ARGUMENTS stn—Station number
site—site number
bin—bin result
tl_get_lasr_id
Get the laser ID of the parts being tested.
SYNOPSIS char * tl_get_lasr_id(s)
char s[];
DESCRIPTION This function reads the laser ID of the parts being tested as a
string.
ARGUMENTS An array in which to place the laser ID string
RETURN VALUE Its argument (the laser ID string)
tl_get_lasr_typ
Get the laser_type of the parts being tested.
SYNOPSIS char * tl_get_lasr_typ(s)
char s[];
DESCRIPTION This function returns the laser type of the parts being tested as a
string.
ARGUMENTS An array in which to place the laser type string
RETURN VALUE Its argument (the laser type string)
tl_get_last_seq_bin
Get bin number for last sequencer.
SYNOPSIS int tl_get_last_seq_bin();
DESCRIPTION This function returns the bin assignment in the last sequencer by
either a fail or pass clause (f() or p()). If called from within a
sequencer, it returns the bin assignment from that sequencer.
The value returned is not affected by the test results from any
previously called sequencers. If there are bin assignments in a
sequencer, the returned value is the bin number of the first
assignment. In a multisite test program, call this function only
from inside a serial block.
ARGUMENTS None
RETURN VALUE The first bin number assigned by the last sequencer.
NO_BINNING is returned if no bin number was assigned by the
last sequencer.
SEE ALSO “tl_get_seq_bin”
tl_get_load_id
Get the load board ID of the parts being tested.
SYNOPSIS char * tl_get_load_id(s)
char s[];
DESCRIPTION This function returns the load board ID of the parts being tested
as a string.
ARGUMENTS An array in which to place the load board ID string
RETURN VALUE Its argument (the load board ID string)
tl_get_load_path
Convert a filename into a full path name.
SYNOPSIS char * tl_get_load_path(<filename>)
char * filename;
DESCRIPTION Use this function to reference files without embedding full path
names in test programs. By mentioning the filename in a .load
file, this function constructs the full path name by adding the path
portion of the .load file name.
For example, you load a test program using a .load file in the
directory /usr/hrod/mpq and the .load file includes
data/values.dat. tl_get_load_path("values.dat")
returns:
/usr/hrod/mpq/data/values.dat
ARGUMENTS filename—the name of a file (usually without a leading path)
RETURN VALUE Full path of filename—if filename was mentioned in .load file
filename—if not mentioned in .load file
NULL—if filename includes a leading path component and there
is a conflict between that and the path name from the .load file
tl_get_load_typ
Get the load board type of the parts being tested.
SYNOPSIS char * tl_get_load_typ(s)
char s[];
DESCRIPTION This function returns the load board type of the parts being tested
as a string.
ARGUMENTS An array in which to place the load board type string
RETURN VALUE Its argument (the load board type string)
tl_get_number_of_testheads
Get the number of test heads.
SYNOPSIS int tl_get_number_of_testheads();
DESCRIPTION Returns the number of test heads on the system. When running
on a tester, this is the number of test heads the system controls.
When running on a simulator,
tl_get_number_of_testheads() returns the maximum
number of test heads for the type of tester being simulated.
ARGUMENTS None.
RETURN VALUE The number of test heads on the system.
tl_get_oper_frq
Get the test operation frequency of the parts being tested.
SYNOPSIS char * tl_get_oper_frq(s)
char s[];
DESCRIPTION This function returns the test operation frequency of the parts
being tested as a string.
ARGUMENTS An array in which to place the test operation frequency string
RETURN VALUE Its argument (the test operation frequency string)
tl_get_part_datalogged
Returns if the current set of parts will be datalogged in the standard datalog outputs.
SYNOPSIS int tl_get_part_datalogged()
DESCRIPTION This function returns 1 (TRUE) if the current set of parts for this
run of the test program will be datalogged in the standard datalog
outputs. It returns 0 (FALSE) if the current set of parts will not be
datalogged. Datastreams set up using the datastream
command or from the datastream setup window are not covered
by this function.
ARGUMENTS None
RETURN VALUE 1 (TRUE) if the current set of parts will be datalogged
0 (FALSE) if the current set of parts will not be datalogged
tl_get_pkg_typ
Get the package type of the parts being tested.
SYNOPSIS char * tl_get_pkg_typ(s)
char s[];
DESCRIPTION This function returns the package type of the parts being tested
as a string.
ARGUMENTS An array in which to place the package type string
RETURN VALUE Its argument (the package type string)
tl_get_prb_card
Get the probe card ID of the parts being tested.
SYNOPSIS char * tl_get_prb_card(s)
char s[];
DESCRIPTION This function returns the probe card ID of the parts being tested
as a string.
Note: For this function to return a meaningful value, one of the
following must first occur:
-The first part has been datalogged.
-The program explicitly has called
tl_read_and_set_prb_info().
-The program explicitly has called tl_set_prb_card().
If the IMAGE Behavior Chooser option
IBC_ACCURATE_EEPROM_STRINGS is disabled, this function
returns a pointer to a NULL string.
ARGUMENTS An array in which to place the probe card ID string
RETURN VALUE Its argument (the probe card ID string)
SEE ALSO “tl_get_prb_typ”, “tl_read_and_set_prb_info”, “tl_get_prb_card”
tl_get_prb_typ
Get the probe card type of the parts being tested.
SYNOPSIS char * tl_get_prb_typ(s)
char s[];
DESCRIPTION This function returns the probe card type of the parts being
tested as a string.
ARGUMENTS An array in which to place the probe card type string
tl_get_prog_nam_fullpath
Get the fully rooted path name of the test program.
SYNOPSIS int tl_get_prog_nam_fullpath(char *)
DESCRIPTION Copies the full path name of the test program to the storage
pointed to by argument and returns an error code.
ARGUMENTS Pointer to storage for test program with full path name. Allocate
MAXPATHLEN bytes for storage. MAXPATHLEN is defined in
<sys/param.h>.
tl_get_radians_d
Convert a double value from degrees to radians.
SYNOPSIS double tl_get_radians_d(degree)
double degree;
tl_get_radians_f
Convert a float value from degrees to radians.
SYNOPSIS float tl_get_radians_f(degree)
float degree;
DESCRIPTION This function takes any floating point value representing degrees
and returns the equivalent value in radians.
ARGUMENTS degree—the value in degrees to be converted to radians
tl_get_sbin_device_count
Return the device count for the desired software bin.
SYNOPSIS int tl_get_sbin_device_count(sbin)
int sbin;
DESCRIPTION This function returns the device count of the given software bin
as of the last device(s) tested. It does not include the current
device(s) even if it is used after the sort bin statement.
ARGUMENTS int sbin—Software bin for device count
tl_get_seq_bin
Get the sequencer bin number for a site.
SYNOPSIS int tl_get_seq_bin();
tl_get_setup_id
Get the test setup ID of the parts being tested.
SYNOPSIS char * tl_get_setup_id(s)
char s[];
DESCRIPTION This function returns the test setup ID of the parts being tested
as a string.
ARGUMENTS An array in which to place the test setup ID string
RETURN VALUE Its argument (the test setup ID string)
tl_get_slot_from_pin
Return test head slot number from pin.
SYNOPSIS int tl_get_slot_from_pin(pinnum);
DESCRIPTION This function returns the test head slot of the first analog
instrument behind the pin number pinnum as described in the
IMAGE pinmap. This function supports multisite test and will
return the slot of the analog instrument associated with the first
instrument behind the pin of the currently active site.
This function is valid in test programs for mixed signal, advanced
mixed-signal, and advanced linear (including PATH) test stations
only. This function is valid for analog instruments only.
ARGUMENTS int pinnum pin number of pin from pinmap
RETURN VALUE int slot test head slot of instrument
-1 error
tl_get_sort_bin
Get bin number assigned in sort bin statement.
SYNOPSIS int tl_get_sort_bin();
DESCRIPTION This function returns the software bin number assigned by the
sort bin statement. In a multisite test program, call this function
only from inside a serial block. In a multisite test program, the
software bin number assigned to a disabled site can only be
tl_get_sort_hbin
Get handler bin assigned in sort bin statement.
SYNOPSIS int tl_get_sort_hbin();
DESCRIPTION This function returns the handler bin number assigned by the
sort bin statement. In a multisite test program, call this function
only from inside a serial block. In a multisite test program, the
handler bin number assigned to a disabled site can only be
obtained by re-enabling the site. Generally, execute a set
site_enable_all statement before the serial block containing
the tl_get_sort_hbin function call.
ARGUMENTS None
RETURN VALUE The last handler bin number assigned.
NO_BINNING is returned if no bin number has been assigned.
NO_BINNING is also returned in a multisite test program if the site
is no longer active.
tl_get_spec_nam
Get the test spec. name of the parts being tested.
SYNOPSIS char * tl_get_spec_nam(s)
char s[];
DESCRIPTION This function returns the test spec. name of the parts being
tested as a string.
ARGUMENTS An array in which to place the test spec. name string
RETURN VALUE Its argument (the test spec. name string)
tl_get_spec_ver
Get the test spec. version of the parts being tested.
SYNOPSIS char * tl_get_spec_ver(s)
char s[];
DESCRIPTION This function returns the test spec. version of the parts being
tested as a string.
ARGUMENTS An array in which to place the test spec. version. string
RETURN VALUE Its argument (the test spec. version string)
tl_getstdftimeofday
Get the current time of day.
SYNOPSIS int tl_getstdftimeofday()
DESCRIPTION Gets the STDF notion of the current time of day. This time is the
GMT time of day, adjusted for local time (not including daylight
savings time). Explicitly, it is the timeval.tv_sec field returned
by:
gettimeofday() - (timezone.tz_minuteswest * 60);
ARGUMENTS None
RETURN VALUE Integer value representing the number of seconds since Jan. 1,
1970.
tl_get_stream_criteria
Get test criteria for the given stream.
SYNOPSIS int tl_get_stream_criteria(char *sname,
struct tl_tlist_element **lptr,
int *num_list_elements);
DESCRIPTION This function searches the list of currently enabled streams (both
datalog and datastream) searching for the stream identified by
sname.
If the stream name does not match any currently enabled data
streams, the function returns a value of Notexist. Otherwise, it
returns an enumerated value from the following list.
Before using this function,
tl_update_data_collection_state() must have been called
at least once to make sure the data collection state information
has been set.
If the tl_tlist_element argument is NULL, no test list
processing or return occurs. The memory associated with the
lists must not be freed. It is handled by subsequent calls to this
function. Subsequent calls to this function modify the test list.
Therefore, if the information is needed, copy it to more
permanent storage.
TL_ALL—All tests
TL_PASSANALOG—Passing analog tests
TL_FAILANALOG—Failing analog tests
TL_PASSDIGITAL—Passing digital tests
TL_FAILDIGITAL—Failing digital tests
tl_get_stream_filename
Return the name of the file the datalog stream is writing.
SYNOPSIS char *tl_get_stream_filename(char *sname);
DESCRIPTION This function first checks to see whether sname exists and
returns the name, if any, of the filename being written. This
function only applies to datalog streams to STDF and text files.
If no file is being written or the stream is not found, the function
returns NULL. This function returns the file name by a pointer to
static storage. If the name must be saved, it must be copied to
user allocated memory. Otherwise, it may be overwritten by a
subsequent call to this function.
Before using this function,
tl_update_data_collection_state() must have been called
at least once to make sure the data collection state information
has been set.
ARGUMENTS sname—name of data collection stream
RETURN VALUE (char *) NULL—error, stream does not exist or the stream in
question is not writing a file.
(char *)—name of file
SIDE EFFECTS Resets static storage used for filename with information in latest
call.
tl_get_stream_sample_info
Return streams sampling rate.
SYNOPSIS int tl_get_stream_sample_info(char *sname,
int *srate, int *slimit);
DESCRIPTION Looks up the stream whose name matches sname, if any, and
returns the sampling rate and sample limit through the
arguments list.
Before using this function,
tl_update_data_collection_state() must have been called
tl_get_tester_number
Read current tester number.
SYNOPSIS int tl_get_tester_number();
DESCRIPTION This function returns the tester number which the test program is
currently loaded into. This number is computed from the
TESTER_NUMBER environment variable.
ARGUMENTS None
RETURN VALUE Current tester number
tl_get_tst_temp
Get the testing temperature of the parts being tested.
SYNOPSIS char * tl_get_tst_temp(s)
char s[];
DESCRIPTION This function returns the testing temperature of the parts being
tested as a string.
ARGUMENTS An array in which to place the testing temperature string.
RETURN VALUE Its argument (the test temperature string)
tl_get_user_power
Read the current state of the user power relay.
SYNOPSIS tl_get_user_power();
DESCRIPTION Read the status of user power. Non-zero return indicates power
on and zero indicates power off.
ARGUMENTS None
RETURN VALUE int state of user power—Nonzero power on, zero power off
SEE ALSO “tl_set_user_power”
tl_get_wavefile_sample_size
Get the sample size from a waveform file.
SYNOPSIS int tl_get_wavefile_sample_size(filename);
DESCRIPTION This function opens the specified wavefile and gets the number
of samples. You must include the file libapps.a in the .load file
for the test program.
ARGUMENTS filename—name of the file to be read
tl_gigadig_report_ac_corr_spectrum
Return error correction spectrum.
SYNOPSIS void tl_gigadig_report_ac_corr_spectrum (int pin,
freq_band_type freq_list, double *err_array)
tl_gigadig_report_chan_mismatch_data
Report mismatch data between channels.
SYNOPSIS void tl_gigadig_report_chan_mismatch_data(ref_pin,
skew_p, offset_p, gain_p)
int ref_pin;
double * skew_p;
double * offset_p;
double * gain_p;
DESCRIPTION This routine reports the gain, clock skew and offset mismatches
between the two undersampling channels. Such mismatches
arise when user switches from one channel to another w/o
issuing any "set gigadig" statement in between two captures.
User *must* have programmed the instrument with the final
"vrng" and "level_freq" settings for the captures when calling this
function.
tl_gigadig_report_err
Report error at a single frequency.
SYNOPSIS double tl_gigadig_report_err(int pin, double freq)
RETURN VALUE Known instrument error at the given frequency point, or 0 if any
error.
SIDE EFFECTS Selects specified instrument.
tl_gigadig_skew_clock
Skew GigaDig capture clock.
SYNOPSIS int tl_gigadig_skew_clock(int pin, double skew_val)
DESCRIPTION User function to adjust the relative timing of the GigaDig capture
clock by the specified amount clock skew for the specified
GigaDig pin.
ARGUMENTS pin—Pin number or pin name of GigaDig to be adjusted
tl_gpib_dump_bus_info
Dump information about the GPIB.
SYNOPSIS int tl_gpib_dump_bus_info()
DESCRIPTION Debug function to dump the current state of the GPIB bus. Gives
such information as to who is a talker and listener as well as the
last data string sent over the bus.
ARGUMENTS None
RETURN VALUE None
tl_gpib_dump_gpibcap_info
Dump the driver’s copy of gpibcap.
SYNOPSIS int tl_gpib_dump_gpibcap_info()
tl_gpib_get_ifc_at_reset
Read whether IFC is asserted during reset.
SYNOPSIS int tl_gpib_get_ifc_at_reset()
DESCRIPTION This function returns whether the GPIB IFC is asserted during
test program resets. It returns FALSE (0) if IFC during reset is
turned off for all test programs. It returns TRUE (non-zero) if IFC
during reset is turned on for all loaded test programs.
ARGUMENTS None
RETURN VALUE None
tl_gpib_set_ifc_at_reset
Set whether IFC is asserted during reset.
SYNOPSIS void tl_gpib_set_ifc_at_reset(int ifc_on_reset)
DESCRIPTION This function sets whether the GPIB IFC is asserted during test
program resets. If passed FALSE (0), then IFC during reset is
turned off for all test programs. If passed TRUE (non-zero) then
IFC during reset is turned on for all loaded test programs.
ARGUMENTS int ifc_on_reset - Integer noting new state of IFC at reset:
TRUE (non-zero) - turn IFC at reset on
FALSE (zero) - turn IFC at reset off
RETURN VALUE None
SIDE EFFECTS This function changes the IFC at reset behavior for all test
programs.
tl_h50_channel_to_pin
Convert HSD channel number to pin.
SYNOPSIS int tl_h50_channel_to_pin(chan)
int chan;
DESCRIPTION This function takes the given HSD channel number, searches the
pinmap for the first DUT pin mapped to this channel, and returns
the pin number.
ARGUMENTS chan—The channel number to find (1 to system max)
RETURN VALUE Pin number (1 to the highest pin number in the pinmap), or zero
if no pin was found mapped to that channel.
tl_h50_check_pattern_running
Check if pattern is running.
SYNOPSIS int tl_h50_check_pattern_running (which_scm)
int which_scm;
tl_h50_check_pattern_running_or_in_ka
Check if pattern is running.
SYNOPSIS int tl_h50_check_pattern_running (which_scm)
int which_scm;
tl_h50_debug_pmtrc
Set the debug state variable for parametric testing.
SYNOPSIS void tl_h50_debug_pmtrc(state)
int state;
DESCRIPTION This function sets the state of the internal flag governing the
switch states during open_short and leakage testing.
ARGUMENTS state—
tl_h50_define_scan_headers
Set count of variable headers.
SYNOPSIS int tl_h50_define_scan_headers(name)
char *name;
DESCRIPTION The HSD50 pattern loader calls this function when loading a
pattern that defines or refers to symbols of the type
SCAN_HDR_VAR or SCAN_TLR_VAR. The function is given the
name of a symbol and returns the count; the loader patches the
pattern to implement the specified count.
The IMAGE library has a default version of this function which
always returns 2. A test program should replace the library
version by defining a function with the same name.
ARGUMENTS name—The string name of the symbol.
RETURN VALUE The desired total cycle count for the header, from 0 to 32769
tl_h50_dsim_roundtrip_delay_time
Set or get the DSim round trip time.
SYNOPSIS double tl_h50_dsim_roundtrip_delay_time(timeval)
double timeval;
DESCRIPTION This function sets and/or gets the round trip delay value for
DSim. If passed in value is < 0, only the current setting is
returned. The round trip delay value is used to detect conflicts
between the R2 and D0 edges on a channel caused by the time
required for signals to travel from the dut to the channel receiver.
NOTE
The value passed in must be of double type. Passing in an integer will result in problems.
tl_h50_get_pin_name
Look up DUT pin name from number.
SYNOPSIS char *tl_h50_get_pin_name(pin)
unsigned short pin;
RETURNS Pointer to pin name string, or 0 if specified pin number was not
found in the pinmap.
tl_h50_get_site_from_chan
Get HSD channel site.
SYNOPSIS int tl_h50_get_site_from_chan(chan)
int chan;
DESCRIPTION This function takes the given HSD channel number, and return
its site.
ARGUMENTS chan—The channel number to find (1 to system max)
RETURN VALUE Channel site number, or -1 if this channel is not in the pinmap.
tl_h50_highest_chan
Get highest channel number
SYNOPSIS int tl_h50_highest_chan()
DESCRIPTION Returns the highest HSD50 channel number in the system.
ARGUMENTS None
RETURN VALUE Highest channel number: maximum 192 for Advanced Mixed-
Signal (HSD50), 384 for Catalyst .
tl_h50_mcfreq
Get value of HSD50 master clock frequency.
SYNOPSIS double tl_h50_mcfreq(clk)
int clk;
tl_h50_pin_to_channel
Get HSD channel number for a pin.
DESCRIPTION Returns the digital channel number for the specified pin. If the pin
is not mapped to a digital channel, a runtime error is issued.
When used in a multisite test program, this function must be
called within a serial loop if the pin is not defined as a shared
resource in the pinmap.
ARGUMENTS pin—pin number
RETURN VALUE Channel number from 1 to max, or 0 if the current site is disabled.
tl_h50_read_dmc_divider
Read back DMC divider value.
SYNOPSIS int tl_h50_read_dmc_divider(scm, tset, clock)
int scm;
int tset;
int clock;
DESCRIPTION Reads back the t0 or c0 divider value for the specified SCM and
tset number. Converts the raw hardware value to user terms
before returning it.
ARGUMENTS scm—TL_FIRST_SCM to read value from first SCM,
TL_SECOND_SCM to read from second SCM.
tset—tset number from 1 to 1023.
clock—0 for t0 divider, 1 for c0 divider.
RETURN VALUE Programmed divider value, or 0 if value could not be read back.
tl_h50_supclk_to_dc
(Dis)connect supclk and matrix.
SYNOPSIS #include <itlh/h50scl.h>
void tl_h50_supclk_to_dc(inst, operation, src_var)
int inst;
int operation;
int src_var;
tlp puts out calls to this function when the user programs a set
<pinlist> supclk connect: or set <pinlist> supclk
disconnect: statement.
tl_handlerprober_exec_action
When using the GPIB interface, tell IMAGE to execute an action.
SYNOPSIS int tl_handlerprober_exec_action(char *action_name);
tl_hcps_connect_pinmap
Connect or disconnect HCPS.
SYNOPSIS tl_hcps_connect_pinmap(mode)
tl_hcps_debug_kelvin_pin
Utility to debug kelvin alarms.
SYNOPSIS int tl_hcps_debug_kelvin_pin(pin,range)
unsigned short pin;
int range;
tl_hcps_set_connect_ilim
Set current ilim for connection.
SYNOPSIS void tl_hcps_set_connect_ilim(ilim)
double ilim;
DESCRIPTION This function sets the current ilim during the connection of HCPS
channels in the pinmap using tl_hcps_connect_pinamp. The
ilim is restored to the original state (state before the
tl_hcps_connect_pinmap call) once the channel connection is
completed.
ARGUMENTS double ilim— Ilim during connections [Range:2A <= ilim <=
8A]. (default i.e. if this function is not called before a
tl_hcps_connect_pinmap is 8A)
tl_hcucal_src
Calibrate a single HCU source.
SYNOPSIS int tl_hcucal_src(arg, number)
int arg, number;
AD212 missing or
AD330 missing or
AD330 data retention failed
SIDE EFFECTS Function does a reset all.
tl_hcu_override
Overrides the High Current Unit (HCU) protection.
SYNOPSIS void tl_hcu_override(flag)
int flag;
tl_hfdig_report_err
Report error at a single frequency.
SYNOPSIS double tl_hfdig_report_err(pin, freq)
int pin;
double freq;
RETURN VALUE Known instrument error at the given frequency point, or 0 if any
error
SIDE EFFECTS Selects specified instrument if instrument is a VHFDIG.
tl_hfsc_ramp_cal
Perform ramp calibration.
SYNOPSIS tl_hfsc_ramp_cal()
tl_hp_abort_probing
Stop probing, break device contact.
SYNOPSIS int tl_hp_abort_probing();
tl_hp_assign_good_die_bins
Define what bin codes are considered “good” and what bin codes are “bad” die.
SYNOPSIS int tl_hp_assign_good_die_bins(goodbins)
int goodbins[];
DESCRIPTION Defines what bin codes are considered “good” and what bin
codes are “bad” die. This does not have anything to do with
inking. “Good” and “bad” are used in accumulating die total
counts. The first value in the array goodbins should contain the
number of valid elements to follow. Each of the following
elements should be the number of a bin to be considered a
“good” bin. All others will be considered fails.
ARGUMENTS goodbins[20]—Good bin values array
tl_hp_assign_logical_ink
Define what inkers are fired in response to a particular bin when a die is tested
SYNOPSIS int tl_hp_assign_logical_ink(inkbins)
int inkbins[];
DESCRIPTION Defines what inkers are fired in response to a particular bin when
a die is tested. The first value in the array inkbins should
contain the number of valid elements to follow. Each of the
following elements is the inking code for each bin, starting with
bin 0. The inking codes are defined as shown in table 26-5.
0 no ink 8 4
1 1 9 1,4
2 2 10 2,4
3 1,2 11 1,2,4
4 3 12 3,4
5 1,2 13 1,3,4
6 2,3 14 2,3,4
7 1,2,3 15 1,2,3,4
tl_hp_bin_to_category
Send binning command to handler or prober.
SYNOPSIS int tl_hp_bin_to_category(bins, idnumbers)
int bins[];
int idnumbers[];
tl_hp_break_device_contact
Open handler jaws at specified site.
SYNOPSIS tl_hp_break_device_contact(site);
int site;
tl_hp_clear_alarm
Clear alarm on the handler or prober.
SYNOPSIS int tl_hp_clear_alarm()
DESCRIPTION This function turns off the audible or visual alarm on the handler
or prober.
ARGUMENTS None
RETURN VALUE 1 operation succeeded
-1 operation failed
SIDE EFFECTS May set global variable tl_hp_errno if error
tl_hp_get_prober_info
Get status information from current prober over the RS232 interface.
SYNOPSIS int tl_hp_get_prober_info(data)
tl_hp_gpib_sendcmd
Send a command to a handler or prober over the GPIB.
SYNOPSIS int tl_hp_gpib_sendcmd(char *command, char *reply,
int replysize)
If the expected reply is by return from a serial poll, the status byte
value is returned in the first byte of reply, reply[0]. Again, the
value is NULL terminated.
If no reply is expected from the command, you can pass a (char
*) NULL for the reply argument and 0 for the replysize
argument.
ARGUMENTS char *command—Pointer to a valid command to send.
char *reply—Pointer to memory to hold handler or prober
response.
int replysize—Size of the reply buffer in bytes.
tl_hp_gpib_sendvarcmd
Send a command to the handler or prober over the GPIB, replacing any C format strings in
the command.
SYNOPSIS int tl_hp_gpib_sendvarcmd(char *command,
char *reply, int replysize, ...)
tl_hp_handlerconf_flags
Show handler setup with handcap information.
SYNOPSIS tl_hp_handlerconf_flags()
tl_hp_handlerconf_show
Print information on current handlers or probers.
SYNOPSIS tl_hp_handlerconf_show()
tl_hp_handler_isconnected
Detect if the handler is connected.
SYNOPSIS tl_hp_handler_isconnected()
tl_hp_handler_isenabled
Detect if the handler is enabled.
SYNOPSIS tl_hp_handler_isenabled()
ARGUMENTS None
RETURN VALUE Nonzero for handler enabled, 0 otherwise
tl_hp_input_empty_status
Determine which input tubes are empty.
SYNOPSIS int tl_hp_input_empty_status(inputs)
int inputs[];
DESCRIPTION This command polls the handler to determine which input tubes
are empty and returns the resulting information in the array
inputs. The first element of inputs is set to the number of
empty tubes. The following elements contain the numbers of the
empty tubes.
ARGUMENTS int inputs[20]—Integer array for empty inputs
tl_hp_is_handler
Detect if peripheral is handler.
SYNOPSIS tl_hp_is_handler()
tl_hp_is_prober
Detect if peripheral is a prober.
SYNOPSIS tl_hp_is_prober()
tl_hp_load_setup
Load the handler or prober setup from file.
SYNOPSIS int tl_hp_load_setup(filename)
char filename[];
DESCRIPTION This command requests the prober or handler to load all its setup
parameters from a file located within its own file system. Specify
the name of the file using the parameter filename, which must
be a null-terminated string.
ARGUMENTS filename—Name of file in handler or prober to use
tl_hp_load_wafer
Unload the current wafer on the prober chuck.
SYNOPSIS int tl_hp_load_wafer()
DESCRIPTION Unloads the current wafer on the prober chuck (if there is one),
loads and aligns a new wafer, and moves the first die under the
probes. After this command is complete, the Z stage is left out of
contact with the wafer.
ARGUMENTS None
RETURN VALUE 1 for success and -1 for failure
SIDE EFFECTS May set global variable tl_hp_errno if error
tl_hp_make_device_contact
Close handler jaws at specified site.
SYNOPSIS tl_hp_make_device_contact(site);
int site;
tl_hp_move_absolute_die
Move prober to absolute <x,y> coordinates.
SYNOPSIS int tl_hp_move_absolute_die(x, y)
int x, y;
DESCRIPTION The Z stage on the prober is lowered, the motor is moved to die
coordinate (x,y) in the prober’s coordinate system, and the Z
stage is raised again. The motor moves only in whole die steps,
not parts of a die.
ARGUMENTS int x—x coordinate of die to move to
int y—y coordinate of die to move to
tl_hp_move_relative_die
Move prober to <x,y> coordinates relative to current location.
SYNOPSIS int tl_hp_move_relative_die(x, y)
int x, y;
DESCRIPTION The Z stage on the prober is lowered, the prober steps x die
positions on the X axis, y positions on the Y axis, and the Z stage
is raised again (if it was up when the command was initiated).
The motor moves only in whole die steps, not parts of a die. If x
and y are positive, movement is in the direction in which the
coordinates increase. If x and y are negative, movement is in the
decreasing x/z direction.
ARGUMENTS int x—x offset to move
int y—y offset to move
tl_hp_move_relative_machine
Move prober <x,y> steps relative to current location in 0.1 mil steps.
SYNOPSIS int tl_hp_move_relative_machine(x, y)
int x, y;
DESCRIPTION The Z stage on the prober is lowered, the prober moves x 0.1 mil
steps on the X axis, y 0.1 mil steps on the Y axis, and the Z stage
is raised again (if it was up when the command was initiated).
See the specific prober manual for a description of coordinate
directions.
ARGUMENTS x—x offset to move
y—y offset to move
tl_hp_move_z_down
Move the Z stage of prober down (out of contact with the probes).
SYNOPSIS int tl_hp_move_z_down()
DESCRIPTION If the Z stage of the prober is up, it is moved down (that is, out of
contact with the probes). At the completion of this function the
probe tips are no longer in contact with the die.
ARGUMENTS None
RETURN VALUE 1 for success and -1 for failure
SIDE EFFECTS May set global variable tl_hp_errno if error
tl_hp_move_z_to_given_height
Move Z stage to specified height.
SYNOPSIS int tl_hp_move_z_to_given_height(z)
int z;
tl_hp_move_z_up
Move the Z stage of prober up (into contact with the probes).
SYNOPSIS int tl_hp_move_z_up()
DESCRIPTION If the Z stage of the prober is down, it is moved up (that is, into
contact with the probes). At the completion of this function the
probe tips are in contact with the die.
ARGUMENTS None
RETURN VALUE 1 for success and -1 for failure
SIDE EFFECTS May set global variable tl_hp_errno if error
tl_hp_output_full_status
Determine which output tubes are full.
DESCRIPTION This command polls the handler to determine which output tubes
are full and returns the resulting information in the array
outputs. The first element of outputs is set to the number of full
tubes. The following elements contain the numbers of the full
tubes.
ARGUMENTS outputs[20]—Integer array for full outputs
tl_hp_parallel_clear_all_start
Clear any latched start, retest, and reject signals on the parallel handler/prober interface.
SYNOPSIS void tl_hp_parallel_clear_all_start(unsigned port)
DESCRIPTION This function clears any latched start, retest, and reject signals
on a parallel interface. Any of the signals cleared using this
function will not be seen by the handler/prober polling software.
ARGUMENTS int port—Parallel handler/prober port on which to clear the
start, retest, and reject signals
RETURN VALUE None
SEE ALSO “tl_hp_parallel_clear_start”, “tl_hp_parallel_clear_autosum”,
“tl_hp_parallel_clear_reject”
tl_hp_parallel_clear_autosum
Clear a latched auto summary signal on the parallel handler/prober interface.
SYNOPSIS void tl_hp_parallel_clear_autosum(unsigned port)
tl_hp_parallel_clear_reject
Clear a reject signal latched on the parallel handler/prober interface.
tl_hp_parallel_clear_start
Clear any latched start and retest signals on the parallel handler/prober interface.
SYNOPSIS void tl_hp_parallel_clear_start(unsigned port)
DESCRIPTION This function clears any latched start and retest signals on a
parallel interface. Any start or retest cleared here will not be seen
by the handler/prober polling software.
ARGUMENTS int port—Parallel handler/prober port on which to clear the
start and retest signals
RETURN VALUE None
SEE ALSO “tl_hp_parallel_clear_autosum”, “tl_hp_parallel_clear_reject”,
“tl_hp_parallel_clear_all_start”
tl_hp_parallel_read_alarm
Read the current state of the handler alarm line.
SYNOPSIS int tl_hp_parallel_clear_alarm(unsigned port)
tl_hp_parallel_read_all_start
Get the state of any latched start, retest, reject, alarm, and auto summary signals.
SYNOPSIS void tl_hp_parallel_read_all_start(unsigned port,
unsigned * start,
unsigned * retest,
unsigned * autosum,
unsigned * reject, unsigned * alarm);
tl_hp_parallel_set_eos
Set the current state of the parallel handler/prober interface EOS line.
SYNOPSIS void tl_hp_parallel_set_eos(unsigned port,
unsigned value)
DESCRIPTION This function sets the state of the EOS line. Whether a value of
1 (TRUE) sets the line to Hi or Lo depends on how the port was
previously set up.
ARGUMENTS port—Handler number (0 - 3)
tl_hp_probe_wafer
Begin probing the wafer on the chuck.
SYNOPSIS int tl_hp_probe_wafer();
DESCRIPTION This command assumes that the first die is under the probes.
When executed, the prober begins probing the wafer on the
chuck.
ARGUMENTS None
RETURN VALUE 1 for success and -1 for failure
SIDE EFFECTS May set global variable tl_hp_errno if error
tl_hp_request_dut_id
Request DUT ID from handler or prober.
SYNOPSIS int tl_hp_request_dut_id(id_str, id_len)
char id_str[];
int id_len;
DESCRIPTION This function reads the ID string for the device currently being
tested and copies it into the array id_str, up to a maximum of
id_len characters. For probers, this corresponds to the wafer
ID.
ARGUMENTS id_str—Array to place ID into
id_len—Length of array
tl_hp_request_error_code
Get current handler or prober error code.
SYNOPSIS tl_hp_request_error_code()
tl_hp_request_error_msg
Get current handler or prober error message.
SYNOPSIS tl_hp_request_error_msg(estr, elen)
char estr[];
int elen;
tl_hp_request_peripheral_id
Read ID of handler or prober.
SYNOPSIS tl_hp_request_peripheral_id(istr, ilen)
char istr[];
int ilen;
DESCRIPTION This function reads back an ASCII identifying string from the
currently attached peripheral into the array passed as a
parameter. This function writes the ID into the array istr, up to
a maximum of ilen characters, and null terminates the array.
ARGUMENTS istr—Array to write handler or prober ID to
ilen—Maximum number of characters to write to istr
tl_hp_request_start
Poll handler or prober for start signal.
DESCRIPTION This function polls the current handler or prober for a start at the
given test head. If an error is encountered, a -1 is returned, and
the error code is placed in the variable tl_hp_errno, where it
can be accessed later. Otherwise, the number of sites with starts
is returned. Note that if the handler is not ready to start on any
sites, this function returns a 0, indicating that no sites are ready
to start.
For a multisite test program, the specific sites returned by the
handler or prober must agree with the number of sites supported
by the test program and with the current set of sites enabled
using the sites command.
In addition, this function also returns a set of flags in the array
parameter condition. The elements of the array are interpreted
as follows:
condition[0]—1 if peripheral is requesting a retest, 0
otherwise
condition[1]—1 if peripheral is signalling end-of-lot, 0
otherwise
condition[2]—1 if peripheral is signalling a reject, 0 otherwise
These condition flags are only set when using certain types of
interfaces. Some interfaces may be unable to return this status
every time a request-to-start is read.
ARGUMENTS condition—Described above
tl_hp_send_command
Send RS232 command to handler or prober.
SYNOPSIS int tl_hp_send_command(cmd)
char cmd[];
You can only use this function for commands which do not
require a response from the handler. A command which
generates a response from the peripheral requires the function
tl_hp_send_request. The main use of this function is to send
a command not already supported by the handler library.
For example, the following code sends the command AB1 to the
current handler or prober:
int success;
success = tl_hp_send_command("AB1");
Take care when using this command. Sending the wrong
command (that is, one requiring a response) may cause
unpredictable behavior in later operations.
ARGUMENTS cmd—Null terminated string containing command to send
tl_hp_send_request
Send a request to handler or prober and get a reply.
SYNOPSIS tl_hp_send_request(cmd, reply)
char cmd[], reply[];
tl_hp_unload_wafer
Unload the current wafer on the prober chuck.
SYNOPSIS int tl_hp_unload_wafer();
DESCRIPTION Unloads the current wafer on the prober chuck without loading a
new wafer.
ARGUMENTS None
RETURN VALUE 1 for success and -1 for failure
SIDE EFFECTS May set global variable tl_hp_errno if error
tl_hpd_user_fprintf
Print to the hpmonitor display and a stream simultaneously.
SYNOPSIS int tl_hpd_user_fprintf(FILE *stream, char * format,
...)
DESCRIPTION Formats the string as per fprintf, and then prints to the stream
and the Handler/prober Monitor display. The string always goes
out to the stream, but the function only tries to send the string to
the hpmonitor if the hpmonitor display is running.
ARGUMENTS FILE * stream—Stream to print to, usually stdout or stderr
char * format—Format string.
...—Format args.
tl_hpd_user_printf
Print to the hpmonitor display and station window stdout simultaneously.
SYNOPSIS int tl_hpd_user_printf(char * format, ...)
DESCRIPTION Formats the string as per printf, and then prints the string in the
station window and the Handler/prober Monitor display. The
string always goes to the station, but the function only tries to
send the string to the hpmonitor if the hpmonitor display is
running.
ARGUMENTS char * format—Format string as per printf
...—Format args as per printf
tl_hpm_reset
Reset the High Power Matrix.
SYNOPSIS tl_hpm_reset(unit)
int unit;
tl_hsd50_calibrate_all
Calibrate calsets that need it.
SYNOPSIS void tl_hsd50_calibrate_all(force)
int force;
tl_hsd_connect_pin_to_thads
Connect the THADs to a digital chan.
SYNOPSIS void tl_hsd_connect_pin_to_thads(pin)
int pin;
DESCRIPTION Connects the THADS bus to the digital channel behind the pin
passed to the function.
Changing the cal tree outside of this function will affect the
connection
Running Calibration will re-set this connection
ARGUMENTS pin—Pin number
tl_hsd_disconnect_pin_from_thads
Disconnect the THADs from TDR.
SYNOPSIS void tl_hsd_disconnect_pin_from_thads()
DESCRIPTION Disconnects the THADS bus from the TDR by resetting the THS
relays to the default position.
Running calibration should accomplish the same result
ARGUMENTS None
RETURN VALUE None
SIDE EFFECTS Sets the THS relays 22 and 23 to open.
tl_hsd_flush_stat_cache
Flush the stat system call cache when using load path in pattern name.
SYNOPSIS void tl_hsd_flush_stat_cache()
tl_hw_settle
Wait for hardware relays to settle.
SYNOPSIS int tl_hw_settle()
DESCRIPTION Waits for the settling timer to count down and for hardware busy.
ARGUMENTS None
RETURN VALUE 0 if timeout error
1 if successful
tl_i2c_construct_msg
Write specified Inter-IC Control bus (I2C) information.
SYNOPSIS tl_i2c_construct_msg(msg, cdig_slot)
char * msg[];
int cdig_slot;
tl_i2c_construct_msg_burst
Write specified Inter-IC Control bus (I2C) information.
SYNOPSIS tl_i2c_construct_msg_burst(name);
char *name;
SIDE EFFECTS Other SBCC channels on the board will be hi-Z during burst.
SEE ALSO “tl_i2c_construct_msg”, “tl_i2c_construct_msg_setup”,
“tl_i2c_construct_msg_burst”
tl_i2c_construct_msg_pin
Writes specified I2C information
SYNOPSIS tl_i2c_construct_msg_pin(msg, cdig_pin)
char * msg[];
int cdig_pin;
SIDE EFFECTS Other CDIG channels on the board are hi-Z during burst. A
pattern named data_test_pat is created or modified if it
already exists. A segment named data_test is created or
modified if it already exists.
tl_i2c_construct_msg_setup
Write specified Inter-IC Control bus (I2C) information.
SYNOPSIS tl_i2c_construct_msg_setup(msg, cdig_slot, name)
char * msg[];
int cdig_slot;
char * name;
This function only creates and stores the pattern and related
information. The actual burst happens during the call to
tl_i2c_construct_msg_burst(name). A maximum of 4096
message tokens can be sent in a single function call.
Description of message tokens:
start—This will drive the clock line high if it is not already high,
then drive the data line low, and then drive the clock line low.
stop—This will drive the data line low, then drive the clock line
high, and then drive the data line high.
read_byte—The next eight vectors of data appearing on the I2C
bus will be read back and placed in the array ReceivedData[].
Multiple reads can be placed in a message. A write_bit_zero
or a write_bit_one command must follow if a master
acknowledge to the DUT is to be sent.
write_byte=<n>—This is used for primary and secondary
addresses and data. Multiple writes can be placed in a message.
<n> should be an eight bit integer (0 ≤ n ≤ 255). A
read_bit_zero or a read_bit_one should follow if the state of
the acknowledge from the DUT is to be tested. A
write_bit_one should be sent if the state of the acknowledge
will not be tested, but a clock pulse is to be sent as a position
holder.
write_bit_zero, write_bit_one—Use these to write the
master acknowledge after a read and to write individual bits
during a write message.
read_bit_zero, read_bit_one—These are used to test the
state of the acknowledge from the DUT after a write of address
or data. These message tokens cause the PASS flag to be set to
FALSE if there is not a match between each of the read_bit
values and the state of the corresponding acknowledge from the
DUT.
ARGUMENTS msg[]—Array of up to 4096 message tokens, null terminated
cdig_slot—Test head slot in which Serial Bus channel card is
located
name—Name to use for future reference to this setup
tl_i2c_construct_msg_setup_pin
Write specified I2C information.
SYNOPSIS tl_i2c_construct_msg_setup_pin(msg, cdig_pin, name)
char * msg[];
int cdig_pin;
char * name;
This function only creates the pattern and stores the pattern and
related information. The actual burst occurs during the call to
tl_i2c_construct_msg_burst(name). A maximum of 4096
message tokens can be sent in a single function call.
Message tokens include:
start—Drives the clock line high if it is not already high, drives
the data line low, and then drives the clock line low.
stop—Drives the data line low, drives the clock line high, and
then drives the data line high.
read_byte—The next eight vectors of data appearing on the I2C
bus are read back and placed in the array ReceivedData[].
Multiple reads can be placed in a message. A write_bit_zero
or write_bit_one command must follow if a master
acknowledge to the DUT is to be sent.
write_byte=<n>—Used for primary and secondary addresses
and data. Multiple writes can be placed in a message. <n>
should be an 8 bit integer (0 <= n <= 255). A read_bit_zero or
read_bit_one should follow if the state of the acknowledge from
the DUT is to be tested. A write_bit_one should be sent if the
state of the acknowledge will not be tested but a clock pulse is to
be sent as a position holder.
write_bit_zero, write_bit_one—Use these to write the
master acknowledge after a read and to write individual bits
during a write message.
read_bit_zero, read_bit_one—Use these to test the state of
the acknowledge from the DUT after a write of address or data.
These message tokens cause the PASS flag to be set to FALSE
if there is no match between each of the read_bit values and
the state of the corresponding acknowledge from the DUT.
ARGUMENTS msg[]—Array of up to 4096 message tokens, null terminated
cdig_pin—Pin number in front of the desired CDIG slot
name—Name to use for future reference to this setup
tl_i2c_data_test
Write Inter-IC Control bus (I2C) data and check for acknowledge.
SYNOPSIS tl_i2c_data_test(primary, secondary, data,
cdig_slot)
int primary, secondary, data[];
int cdig_slot;
DESCRIPTION Writes the specified data to the specified I2C address. Checks for
address and data acknowledge and timeout. Returns a structure
indicating PASS, FAIL, or TIMEOUT. Timing, levels, and timeout
value must already have been set. SCL is on cdig_clk pin and
SDA is on cdig_io1 pin.
ARGUMENTS primary—Primary I2C address (including r/w bit)
secondary—Secondary I2C address if applicable, otherwise -1
data[]—Array of bytes of data to be written terminated in -1
cdig_slot—Test head slot in which Serial Bus channel card is
located
RETURN VALUE Pointer to a structure with
PASS/AddressFAIL/DataFAIL/TIMEOUT set to either TRUE or
FALSE. Pattern data is pointed to by Clock_Leading,
Clock_Trailing, Drive_Pat, and Receive_Pat.
SIDE EFFECTS Other CDIG channels on the board will be hi-Z during burst. A
pattern named data_test_pat is created, or modified if it
already exists. A segment named data_test is created, or
modified if it already exists.
tl_i2c_data_test_burst
Burst pattern and check for fail.
SYNOPSIS tl_i2c_data_test_burst(name)
char *name;
tl_i2c_data_test_pin
Writes data and checks for acknowledge.
SYNOPSIS tl_i2c_data_test_pin(primary, secondary, data,
cdig_pin)
int primary, secondary, data[];
int cdig_pin;
DESCRIPTION Writes the specified data to the specified I2C address. Checks for
address and data acknowledge, and timeout. Returns a structure
indicating PASS, FAIL, or TIMEOUT. Timing, levels, and timeout
value must already have been set. SCL is on cdig_clk pin and
SDA is on cdig_io1 pin.
ARGUMENTS primary—Primary I2C address (including r/w bit)
secondary—Secondary I2C address if applicable, otherwise -1
data[]—Array of bytes of data to be written terminated in -1
cdig_pin—Pin number in front of the desired CDIG card
SIDE EFFECTS Other CDIG channels on the board are hi-Z during burst. A
pattern data_test_pat is created or modified if it already exists.
A segment data_test is created or modified if it already exists.
tl_i2c_data_test_setup
Set up pattern for acknowledge.
SYNOPSIS tl_i2c_data_test_setup(primary, secondary, data,
cdig_slot, name, fast)
int primary, secondary, data[];
int cdig_slot;
char *name;
int fast;
DESCRIPTION Creates and loads a pattern named <name> (<name> is the string
that was passed in). The pattern has a segment named
<name>_seg containing the vectors which produce the specified
data for the specified I2C address. For example, if dtest1 is the
string passed in for the argument <name>, a segment named
dtest1_seg is created and used to define a pattern named
dtest1.
SIDE EFFECTS Pattern <name> and segment <name>_seg are redefined with
new information. Previously returned setup structure is
overwritten.
tl_i2c_data_test_setup_pin
Set up pattern for acknowledge.
SYNOPSIS tl_i2c_data_test_setup_pin(primary, secondary, data,
cdig_pin, name, fast)
int primary, secondary, data[];
int cdig_pin;
char *name;
int fast;
DESCRIPTION Creates and loads a pattern named <name> (<name> is the string
that was passed in). The pattern has a segment named
<name>_seg containing the vectors which produce the specified
data for the specified I2C address. For example, if dtest1 is the
string passed in for the argument <name>, a segment named
dtest1_seg is created and used to define a pattern named
dtest1.
SIDE EFFECTS Pattern <name> and segment <name>_seg are redefined with
new information. Previously returned setup structure is
overwritten.
tl_i2c_extended_addr_check
Write Inter-IC Control bus (I2C) addresses and check for acknowledge.
SYNOPSIS tl_i2c_extended_addr_check(addresses, cdig_slot)
int addresses[], cdig_slot;
SIDE EFFECTS Other CDIG channels on the board will be hi-Z during burst. A
pattern named data_test_pat is created, or modified if it
tl_i2c_extended_addr_check_pin
Write Inter-IC Control bus (I2C) addresses and check for acknowledge.
SYNOPSIS tl_i2c_extended_addr_check_pin(addresses, cdig_pin)
int addresses[], cdig_pin;
SIDE EFFECTS Other CDIG channels on the board are hi-Z during burst. A
pattern named data_test_pat is created, or modified if it
already exists. A segment named data_test is created, or
modified if it already exists.
tl_i2c_free_string_memory
Free string memory used by Inter-IC Control bus (I2C) functions.
SYNOPSIS void tl_i2c_free_string_memory();
tl_i2c_rcv_data_rpt_test
Read Inter-IC Control bus (I2C) data and check for acknowledge.
SYNOPSIS tl_i2c_rcv_data_rpt_test(primary, secondary, num,
cdig_slot)
int primary, secondary, num;
int cdig_slot;
DESCRIPTION Reads the specified number of bytes from the given I2C address.
The stop bit is not sent, and the last byte is acknowledged by the
master receiver. Checks for address acknowledge and timeout.
Returns a structure indicating PASS, FAIL or TIMEOUT, and the
data read. Timing, levels, and timeout value must already have
been set. Maximum number of bytes read is 8000. SCL is on
cdig_clk pin and SDA is on cdig_io1 pin.
SIDE EFFECTS Other SBCC channels on the board will be hi-Z during burst. A
pattern named data_test_pat is created, or modified if it
already exists. A segment named data_test is created, or
modified if it already exists.
SEE ALSO “tl_i2c_rcv_data_test”
tl_i2c_rcv_data_rpt_test_burst
Sets up rpt_test_setup patterns.
SYNOPSIS tl_i2c_rcv_data_rpt_test_burst(name)
char *name;
SIDE EFFECTS Other CDIG channels on the board will be hi-Z during burst.
SEE ALSO “tl_i2c_rcv_data_test”, “tl_i2c_rcv_data_test_burst”
tl_i2c_rcv_data_rpt_test_pin
Reads data and checks for acknowledge.
SYNOPSIS tl_i2c_rcv_data_rpt_test_pin(primary, secondary,
num, cdig_pin)
int primary, secondary, num;
int cdig_pin;
DESCRIPTION Reads the specified number of bytes from the given I2C address.
The stop bit is not sent, and the last byte is acknowledged by the
master receiver. Checks for address acknowledge and timeout.
Returns a structure indicating PASS, FAIL, or TIMEOUT and the
data read. Timing, levels, and timeout value must already have
been set. Maximum number of bytes read is 8000. SCL is on
cdig_clk pin and SDA is on cdig_io1 pin.
SIDE EFFECTS Other CDIG channels on the board are hi-Z during burst. A
pattern named data_test_pat is created or modified if it
already exists. A segment named data_test is created or
modified if it already exists.
SEE ALSO “tl_i2c_rcv_data_test”
tl_i2c_rcv_data_rpt_test_setup
Sets up rpt_test_setup patterns.
SYNOPSIS tl_i2c_rcv_data_rpt_test_setup(primary, secondary,
num, cdig_slot, name)
int primary, secondary, num;
int cdig_slot;
char *name;
DESCRIPTION Reads the specified number of bytes from the given I2C address.
The stop bit is not sent, and the last byte is acknowledged by the
master receiver. Checks for address acknowledge, and timeout.
Returns a structure indicating PASS, FAIL or TIMEOUT, and the
data read. Timing, levels, and timeout value must already have
been set. Maximum number of bytes read is 8000. SCL is on
cdig_clk pin and SDA is on cdig_io1 pin.
SIDE EFFECTS Pattern named <name> and segment named <name>_seg are
redefined. Previously returned setup structure is overwritten.
SEE ALSO “tl_i2c_rcv_data_test”, “tl_i2c_rcv_data_test_burst”
tl_i2c_rcv_data_rpt_test_setup_pin
Sets up rpt_test_setup patterns.
SYNOPSIS tl_i2c_rcv_data_rpt_test_setup_pin(primary,
secondary, num, cdig_pin, name)
int primary, secondary, num;
int cdig_pin;
char *name;
DESCRIPTION Reads the specified number of bytes from the given I2C address.
The stop bit is not sent, and the last byte is acknowledged by the
master receiver. Checks for address acknowledge and timeout.
Returns a structure indicating PASS, FAIL, or TIMEOUT and the
data read. Timing, levels, and timeout value must already have
been set. Maximum number of bytes read is 8000. SCL is on
cdig_clk pin and SDA is on cdig_io1 pin.
name—Reference name for this setup, also used as the basis for
the names used in creating segment and pattern
RETURN VALUE Pointer to a structure with PASS/AddressFAIL/TIMEOUT set to
either TRUE or FALSE and ReceivedData as an array of integer
values. Pattern data is pointed to by Clock_Leading,
Clock_Trailing, Drive_Pat, and Receive_Pat.
tl_i2c_rcv_data_test
Read Inter-IC Control bus (I2C) data and check for acknowledge.
SYNOPSIS tl_i2c_rcv_data_test(primary, secondary, num,
cdig_slot)
int primary, secondary, num;
int cdig_slot;
DESCRIPTION Reads the specified number of bytes from the given I2C address.
Checks for address acknowledge and timeout. Returns a
structure indicating PASS, FAIL or TIMEOUT, and the data read.
Timing, levels, and timeout value must already have been set.
Maximum number of bytes read is 8000. SCL is on cdig_clk pin
and SDA is on cdig_io1 pin.
ARGUMENTS primary—Primary I2C address
secondary—Secondary I2C address if applicable, otherwise -1
num—Number of bytes of data to be read, 8000 max
cdig_slot—Test head slot in which Serial Bus Channel Card is
located
RETURN VALUE Pointer to a structure with PASS/AddressFAIL/TIMEOUT set to
either TRUE or FALSE and ReceivedData as an array of integer
values. Pattern data is pointed to by Clock_Leading,
Clock_Trailing, Drive_Pat, and Receive_Pat.
SIDE EFFECTS Other SBCC channels on the board will be hi-Z during burst. A
pattern named data_test_pat is created, or modified if it
already exists. A segment named data_test is created, or
modified if it already exists.
SEE ALSO “tl_i2c_rcv_data_rpt_test”
tl_i2c_rcv_data_test_burst
Burst pattern and return read data.
SYNOPSIS tl_i2c_rcv_data_test_burst(name)
char *name;
SIDE EFFECTS Other CDIG channels on the board are hi-Z during burst.
SEE ALSO “tl_i2c_rcv_data_test_setup”
tl_i2c_rcv_data_test_pin
Reads data and checks for acknowledge.
SYNOPSIS tl_i2c_rcv_data_test_pin(primary, secondary, num,
cdig_pin)
int primary, secondary, num
int cdig_pin;
DESCRIPTION Reads the specified number of bytes from the given I2C address.
Checks for address acknowledge and timeout. Returns a
structure indicating PASS, FAIL, or TIMEOUT and the data read.
Timing, levels, and timeout value must already have been set.
Maximum number of bytes read is 8000. SCL is on cdig_clk pin
and SDA is on cdig_io1 pin.
ARGUMENTS primary—Primary I2C address (including r/w bit)
secondary—Secondary I2C address if applicable, otherwise -1
num—Number of bytes of data to be read, 8000 max
cdig_pin—Pin number in front of the desired CDIG card
SIDE EFFECTS Other CDIG channels on the board are hi-Z during burst. A
pattern data_test_pat is created or modified if it already exists.
A segment data_test is created or modified if it already exists.
SEE ALSO “tl_i2c_rcv_data_rpt_test”
tl_i2c_rcv_data_test_setup
Set up, read data, and check.
SYNOPSIS tl_i2c_rcv_data_test_setup(primary, secondary, num,
cdig_slot, name)
int primary, secondary, num
int cdig_slot;
char *name;
DESCRIPTION Creates segment and pattern that reads the specified number of
bytes from the given I2C address. The pattern will also check for
address acknowledge and timeout. Returns a structure that has
zero for PASS, FAIL or TIMEOUT, and the data read.
Maximum number of bytes read is 8000. SCL is on cdig_clk pin
and SDA is on cdig_io1 pin.
ARGUMENTS primary—Primary I2C address (including r/w bit)
secondary—Secondary I2C address if applicable, otherwise -1
num—Number of bytes of data to be read, 8000 max
cdig_slot—Test head slot in which SBCC channel card is
located
name—Name to use when creating segment and pattern
tl_i2c_rcv_data_test_setup_pin
Set up, read data, and check.
SYNOPSIS tl_i2c_rcv_data_test_setup_pin(primary, secondary,
num, cdig_pin, name)
int primary, secondary, num
int cdig_pin;
char *name;
DESCRIPTION Creates segment and pattern that reads the specified number of
bytes from the given I2C address. The pattern will also check for
address acknowledge and timeout. Returns a structure that has
zero for PASS, FAIL, or TIMEOUT and the data read.
Maximum number of bytes read is 8000. SCL is on cdig_clk pin
and SDA is on cdig_io1 pin.
ARGUMENTS primary—Primary I2C address (including r/w bit)
secondary—Secondary I2C address if applicable, otherwise -1
num—Number of bytes of data to be read, 8000 max
cdig_pin—The pin number in front of the desired CDIG card
name—Name to use when creating segment and pattern
tl_i2c_single_addr_check
Write Inter-IC Control bus (I2C) addresses and check for acknowledge.
SYNOPSIS tl_i2c_single_addr_check(addresses, cdig_slot)
int addresses[], cdig_slot;
DESCRIPTION Sends all extended addresses from 0x00 to 0xFF. Each address
is preceded by a start and followed by a stop condition. Tests that
only the specified addresses are acknowledged. Returns a
structure indicating PASS, FAIL, or TIMEOUT, and the
ADDRESSES that failed, if any. Timing, levels, and timeout value
must already have been set. SCL is on cdig_clk pin and SDA
is on cdig_io1 pin.
ARGUMENTS addresses[]—Array of primary addresses terminated in -1
cdig_slot—Test head slot in which Serial Bus Channel Card is
located
RETURN VALUE Pointer to a structure with PASS/AddressFAIL/TIMEOUT set to
either TRUE or FALSE and ADDRESSES as an array of integer
values, terminated in -1. Pattern data is pointed to by
Clock_Leading, Clock_Trailing, Drive_Pat, and
Receive_Pat.
SIDE EFFECTS Other SBCC channels on the board will be hi-Z during burst.
tl_i2c_single_addr_check_burst
Write addresses and check for acknowledge.
SYNOPSIS tl_i2c_single_addr_check_burst(addresses,
cdig_slot)
int addresses[], cdig_slot;
tl_i2c_single_addr_check_burst_pin
Write addresses and check for acknowledge.
SYNOPSIS tl_i2c_single_addr_check_burst_pin(addresses,
cdig_pin)
int addresses[], cdig_pin;
tl_i2c_single_addr_check_pin
Writes addresses and checks for acknowledge.
SYNOPSIS tl_i2c_single_addr_check_pin(addresses, cdig_pin)
int addresses[], cdig_pin;
SIDE EFFECTS Other CDIG channels on the board are hi-Z during burst
tl_i2c_single_addr_check_rcv
Write addresses and check for acknowledge.
SYNOPSIS tl_i2c_single_addr_check_rcv(addresses, cdig_slot)
int addresses[], cdig_slot;
SIDE EFFECTS Other SBCC channels on the board will be hi-Z during burst A
pattern named data_test_pat is created, or modified if it
already exists. A segment named data_test is created, or
modified if it already exists.
tl_i2c_single_addr_check_rcv_burst
Write addresses and check for acknowledge.
SYNOPSIS tl_i2c_single_addr_check_rcv_burst(name)
char *name;
tl_i2c_single_addr_check_rcv_pin
Writes addresses and checks for acknowledge.
SYNOPSIS tl_i2c_single_addr_check_rcv_pin(addresses,
cdig_pin)
int addresses[], cdig_pin;
SIDE EFFECTS Other CDIG channels on the board are hi-Z during burst. A
pattern data_test_pat is created or modified if it already exists.
A segment data_test is created or modified if it already exists.
tl_i2c_single_addr_check_rcv_setup
Write addresses and check for acknowledge.
SYNOPSIS tl_i2c_single_addr_check_rcv_setup(addresses,
cdig_slot, name)
int addresses[], cdig_slot;
char *name;
DESCRIPTION Creates and loads a pattern which sends all addresses from
0x00 to 0xFF. Each address is preceded by a start and followed
by a stop condition unless it is a receive address listed in
addresses[], in which case, cycles for the read byte are
included after the address is sent. The pattern will only test that
only the specified addresses are acknowledged.
A call to this function creates a setup with the name passed in as
the argument. This setup can be referenced in a call to
tl_i2c_single_addr_check_rcv_burst, which will burst the
pattern on the hardware.
SIDE EFFECTS Pattern named <name> and segment named <name>_seg are
defined if they do not exist and redefined if they do. Previously
returned setup structure is overwritten.
tl_i2c_single_addr_check_rcv_setup_pin
Write addresses and check for acknowledge.
SYNOPSIS tl_i2c_single_addr_check_rcv_setup_pin(addresses,
cdig_pin, name)
int addresses[], cdig_pin;
char *name;
DESCRIPTION Creates and loads a pattern which sends all addresses from
0x00 to 0xFF. Each address is preceded by a start and followed
by a stop condition unless it is a receive address listed in
addresses[], in which case, cycles for the read byte are
included after the address is sent. The pattern will only test that
only the specified addresses are acknowledged.
A call to this function creates a setup with the name passed in as
the argument. This setup can be referenced in a call to
tl_i2c_single_addr_check_rcv_burst, which will burst the
pattern on the hardware.
tl_i2c_single_addr_check_rcv_setup combined with
tl_i2c_single_addr_check_rcv_burst performs the same
function as tl_i2c_single_addr_check_rcv without the
overhead of recreating and loading the pattern every time the
function is run.
ARGUMENTS addresses[]—Array of primary addresses, terminated in -1
cdig_pin—Pin number in front of the desired CDIG card
name—Name of the setup to create
SIDE EFFECTS Pattern <name> and segment <name>_seg are defined if they do
not exist and redefined if they do. Previously returned setup
structure is overwritten.
tl_i2c_single_addr_check_setup
Set up pattern for address check.
SYNOPSIS tl_i2c_single_addr_check_setup(cdig_slot)
int cdig_slot;
tl_i2c_single_addr_check_setup_pin
Set up pattern for address check.
SYNOPSIS tl_i2c_single_addr_check_setup_pin(cdig_pin)
int cdig_pin;
tl_init
Initialize a test program.
SYNOPSIS tl_init()
{
<user statements>
}
tl_input_adjust
Find an appropriate input given an output.
SYNOPSIS enum Ia_returns
tl_input_adjust(adjust_func, lo_limit, hi_limit,
output_target, resolution, polarity,
max_loop_count, answer)
double (*adjust_func)();
double lo_limit;
double hi_limit;
double output_target;
double resolution;
enum Ia_adjust_polar_values polarity;
int max_loop_count;
double *answer;
between successive tests on the input is less than this value the
search is abandoned.
polarity—flag indicating search direction:
IA_POSITIVE_POLAR: input and output are expected to be
proportional.
IA_NEGATIVE_POLAR: input and output are expected to be
inversely proportional.
IA_AUTO_POLAR: program determines search direction.
max_loop_count—max number of iterations to find input.
answer—the answer: the input appropriate for output is written
here.
RETURN VALUE Returns an enumerated value. The enumerators and their values
are as follows:
enum Ia_returns{
IA_INVALID_ARGUMENT = -1,/* bad args */IA_RETURN_OK = 0,/* solution found */
IA_RETURN_NO_RESOLUTION = 1,/* exhausted search by max_loops tries */
IA_RETURN_INPUT_TOO_LOW = 2,/* lo_limit was too high */
IA_RETURN_INPUT_TOO_HIGH = 3};/* 'input' is above hi_limit */
tl_job_is_in_debug
Determine if test program is running in debug mode.
SYNOPSIS int tl_job_is_in_debug();
tl_legal_pin_array
Determine if variable is a legal pin number.
SYNOPSIS tl_legal_pin_array(var)
void *var;
tl_legal_pin_number
Determine if variable is a legal pin number.
SYNOPSIS tl_legal_pin_number(var)
void *var;
tl_lfacd_02_move_alarm_bit
Control whether alarm bit is moved.
SYNOPSIS void tl_lfacd_02_move_alarm_bit(setting)
int setting;
DESCRIPTION If called with TRUE, 18 bits are moved to include the alarm bit
with each sample. By default, or if called with FALSE, only the 16
bits of data are moved. This only affects the 949-660-02
LFACDIG.
ARGUMENTS setting—TRUE to cause alarm bit to be moved
SIDE EFFECTS Moves are slightly slower when the alarm bit is moved as well.
tl_lfacdig_set_precharge_time
Set the time for the precharge
SYNOPSIS double tl_lfacdig_set_precharge_time
(cap_charge_time)
tl_lfac_disable_dut_connects
Disable connections to the DUT.
SYNOPSIS void tl_lfac_disable_dut_connects()
ccgnd __
| Relays closed by
DC matrix
__| tl_lfac_disable_dut_connects
|
THADS Bus __|
|
Instrument HI __________|________ HI pin to DUT
ARGUMENTS None
tl_lfac_enable_dut_connects
Enable connections to the DUT.
SYNOPSIS void tl_lfac_enable_dut_connects
ccgnd__
|
DC matrix__| __These are the "DUT" relays in question
| |
THADS Bus__| v
|
Instrument HI__________|________HI pin to DUT
tl_lfacs_conn_deltabus
Connect LFACSRC output to delta bus.
SYNOPSIS int tl_lfacs_conn_deltabus(on_off, pin)
int on_off;
int pin;
tl_lfacs_get_wave_fs
Read back Fs of an LFACSRC waveform.
SYNOPSIS double tl_lfacs_get_wave_fs(wavename)
char *wavename;
tl_lfacs_multitone_ac_crest_factor
Get LFACSRC crest factor.
SYNOPSIS double tl_lfacs_multitone_ac_crest_factor()
tl_lfacsrc_get_grow_dir
Get LFACSRC segment growth direction.
SYNOPSIS int tl_lfacsrc_get_grow_dir(pinnumber)
int pinnumber;
RETURN VALUE Segment growth direction in memory. The valid “growth” codes
are 1 for down and 0 for up.
LFACSRC_MEM_GROWTH_DIR_NOT_FOUND (999) is returned if it
does not work.
SIDE EFFECTS Selects specified instrument if instrument is an LFACSRC.
tl_lfacs_sinxx_amp
Calculate sin x/x corrected amplitude of an LFACSRC waveform.
SYNOPSIS double tl_lfacs_sinxx_amp(fund_freq, wavename,
desired_amp)
double fund_freq;
char *wavename;
double desired_amp;
tl_matrix_bank_force
Override auto open and close of bank relays.
SYNOPSIS void tl_matrix_bank_force(state,bank)
unsigned state;
unsigned bank;
DESCRIPTION Overrides the automatic opening and closing of the line to bank
relays.
ARGUMENTS unsigned state—1 means keep the lines closed to this bank
0 means open and close the banks automatically
unsigned bank—Bank affected by this call
SIDE EFFECTS Forcing closed closes all line to bank switches. Re-enabling the
automatic function opens the switches for all unused lines.
tl_mcfd_clear_counter
Reset maximum consecutive failing device (MCFD) count for site.
SYNOPSIS int tl_mcfd_clear_counter();
DESCRIPTION Clears the MCFD counters for all sites, that is resets all current
counts to 0. This function can be called from within a serial block
to clear counters for specific sites.
To clear MCFD counters for all sites use:
tl_mcfd_clear_counter();
To clear counters for only a specific site use:
serial {
if (site_to_clear == tl_site)
tl_mcfd_clear_counter();
}
where site_to_clear is the number of some site whose
counter is to be cleared.
ARGUMENTS None
RETURN VALUE 0—Failure
1—Success counter cleared
SIDE EFFECTS Clears the current MCFC counts.
tl_mcfd_disable_site
Disable maximum consecutive failing device monitoring on one or more sites.
SYNOPSIS int tl_mcfd_disable_site()
DESCRIPTION Disables MCFD monitoring for all test sites. The trigger and
count for sites are cleared and, before MCFD can be monitored,
tl_mcfd_init() must be called.
tl_mcfd_init
Initialize maximum consecutive failure levels.
SYNOPSIS int tl_mcfd_init(int count);
break;
case 1: tl_mcfd_init(2);
break;
case 2: tl_mcfd_init(3);
break;
case 3: tl_mcfd_init(4);
break;
}
}
ARGUMENTS int count—Number of consecutive failures which will trigger
alarm.
RETURN VALUE 0—Indicates error or user has initialized an alarm to trigger after
0 failures, does nothing
>0—Indicates success and is the number of consecutive failing
devices which will trigger an alarm for that site
SIDE EFFECTS Initializes MCFD counters for a particular site, enabling MCFD to
be monitored for a site.
tl_mcfd_monitor_hbin
Monitor hardware bins for maximum consecutive device failure.
SYNOPSIS void tl_mcfd_monitor_hbin(void);
tl_mcfd_monitoring_on
Return the state (on or off) of maximum consecutive failing device (MCFD). monitoring.
SYNOPSIS int tl_mcfd_monitoring_on();
tl_mcfd_monitor_sbin
Monitor software bins for maximum consecutive device failure.
SYNOPSIS void tl_mcfd_monitor_sbin(void);
tl_mcfd_switch_off
Turn off maximum consecutive failing devices (MCFD) monitoring.
SYNOPSIS int tl_mcfd_switch_off(void)
DESCRIPTION Turns off MCFD monitoring. MCFD alarms will not be triggered
and MCFD counts will not be incremented.
ARGUMENTS None
RETURN VALUE Current state of MCFD monitoring. Usually 0. Any other value
indicates a serious system error.
SIDE EFFECTS Turns off MCFD monitoring.
SEE ALSO “tl_mcfd_switch_on”
tl_mcfd_switch_on
Turn on maximum consecutive failing devices monitoring.
SYNOPSIS int tl_mcfd_switch_on(void);
tl_measure_calibrate
Calibrate Low Current Ammeter raw measurement samples.
SYNOPSIS double tl_measure_calibrate(raw);
int raw;
tl_measure_calibrate_n
Calibrate N raw samples for Low Current Ammeter.
SYNOPSIS int tl_measure_calibrate_n(raw, cal, sample_size);
int *raw;
double *cal;
int sample_size;
tl_measure_sample_period
Return adjusted sample period.
SYNOPSIS double tl_measure_sample_period();
DESCRIPTION Returns the actual sample period, per measurable, that resulted
from the last set measure statement, adjusted to the resolution
of the selected clock.
ARGUMENTS None
RETURN VALUE Actual sample period.
tl_memman_recompact_off
Turn off memory recompaction.
SYNOPSIS int tl_memman_recompact_off();
tl_memman_recompact_on
Turn on memory recompaction.
SYNOPSIS int tl_memman_recompact_on();
tl_memman_recompact_pattern
Recompact pattern memory.
SYNOPSIS int tl_memman_recompact_pattern(newsize, mem_type)
register int newsize;
TL_MEMMAN_TYPE mem_type;
tl_meter_ave_time_and_n
Return average and number of readings over time.
SYNOPSIS double tl_meter_ave_time_and_n(t, n);
double t;
int *n;
DESCRIPTION This function averages the meter over time. It reads the A/D
repeatedly during the specified duration and averages the
results. The meter is read at least once. The specified time must
be a positive number greater than zero. If the duration is so long
that the counter (unsigned integer) rolls over, the accumulator is
reset at the same time. Sets n to the number of readings
averaged.
ARGUMENTS t—Time in seconds
n—Pointer to a variable to be filled in
tl_meter_filter_info
Return the status of the meter’s filter.
SYNOPSIS int tl_meter_filter_info()
tl_opamp_read_loop_alarm
Read the status of Quad Opamp channel card loop alarm.
SYNOPSIS int tl_opamp_read_loop_alarm(slot_num, inst_nbr)
int slot_num, inst_nbr;
RETURN VALUE 0 if OK
1 if alarm
tl_opamp_read_osc_alarm
Read the status of Quad Opamp channel card osc alarm.
SYNOPSIS int tl_opamp_read_osc_alarm(slot_num, inst_nbr)
int slot_num, inst_nbr;
RETURN VALUE 0 if OK
1 if alarm
tl_open_mux
Open the multiplexer.
SYNOPSIS void tl_open_mux();
tl_ovi_alarm_disable
Disable specified alarms for OVI channel.
SYNOPSIS int tl_ovi_alarm_disable(channel, alarm, disable)
int channel;
int alarm;
int disable;
tl_ovi_local_meter_reset
Reset local meters.
SYNOPSIS void tl_ovi_local_meter_reset(channel, meter)
int channel;
int meter;
DESCRIPTION Resets the specified local meters for a single OVI channel or all
OVI channels in the test system.
ARGUMENTS channel—1- based channel number or 0 for all OVI channels
tl_ovi_set_hotswitch_protection
Set test head relay delay flag and two Kelvin flag.
SYNOPSIS void tl_ovi_set_hotswitch_protection(delay_flag,
two_kelvin_flag)
int delay_flag;
int two_kelvin_flag;
DESCRIPTION Controls whether IMAGE waits for the test head relays to open
after executing an OVI disconnect statement. If delay_flag is
TRUE, IMAGE issues a delay to be sure the test head relays
have opened and avoid a possible hot switch. The
two_kelvin_flag tells IMAGE to allow or disallow connects
with two points of Kelvin. This can also avoid a hotswitch in
certain cases.
With every OVI reset, these flags are reset to the default
settings:
delay_flag = FALSE
two_kelvin_flag = TRUE
tl_ovi_set_thads_atten
Set THADS bus attenuation.
SYNOPSIS int tl_ovi_set_thads_atten(slot, thads, atten)
DESCRIPTION Sets the attenuation value for the CCBUS to THADS connection
of a particular OVI Disconnect Channel Card (DCC).
ARGUMENTS int slot—Slot number of DCC
int thads—OVI THADS bus, 1 or 2
double atten—25.0, 100.0, 200.0, or 1.0 (AC).
tl_ovi_set_wave_gain
Set gain for wave programming.
SYNOPSIS void tl_ovi_set_wave_gain(channel, gain);
int channel;
double gain;
DESCRIPTION Sets the gain applied to the voltage on the wave bus, used to
modulate the output of an Octal V/I. Valid values for gain are
10.0, 1.0, and 0.1.
ARGUMENTS channel—Channel of Octal V/I to program (1 based)
gain—Gain to apply to wave bus
tl_pacs2_cal_debug_flag
Set the PACS II calibration debug flag.
SYNOPSIS void tl_pacs2_cal_debug_flag(state)
int state;
tl_pacs2cal_dump_cal_tables
Print PACS II calibration table to station.
SYNOPSIS void tl_pacs2cal_dump_cal_tables(cage)
int cage;
DESCRIPTION Prints the calibration table for the specified cage to station
window.
ARGUMENTS cage—PACS II cage number whose calibration constants are of
interest. Valid cage numbers range from 1 <= x <= 4.
tl_pacs2_clk_cal
Perform PACS II clock calibration.
SYNOPSIS int tl_pacs2_clk_cal(msg_dest)
int msg_dest;
tl_pacs2_fetch_cal_val
Get PACS II calibration constants.
SYNOPSIS double tl_pacs2_fetch_cal_val(type, cage, amc,
mfslot, An, Seq, freq_index)
int type, cage, amc, mfslot, An, Seq, freq_index;
RETURN VALUE The value from the calibration table for the specified type.
tl_pacs2_set_cal_datalog
Enable or disable datalog during PACS II calibration.
SYNOPSIS void tl_pacs2_set_cal_datalog(on_off)
int on_off;
tl_pacs_sinxx_amp
Calculate sin x/x corrected amplitude.
SYNOPSIS double tl_pacs_sinxx_amp(freq, clock, cage, amp)
double freq;
int clock;
int cage;
double amp;
DESCRIPTION Function used to calculate sin x/x corrected amplitude for the
Precision AC Subsystem. Given the signal fundamental
frequency, the A(n) clock number, the PACS cage, and the
desired amplitude, this function returns the amplitude that must
be programmed to get the desired amplitude.
ARGUMENTS freq—The signal fundamental frequency
clock—Integer 0, 1, 2, or 3 to indicate which An clock is being
used
cage—Integer to indicate which PACS cage is being used
amp—The desired amplitude
tl_pause_data_collection
Pause data collection.
SYNOPSIS int tl_pause_data_collection()
DESCRIPTION Pauses data collection. That is, this function stops sending
datalog data to IMAGE, but still sends summary data. It turns off
all data collection, datalog, and data stream.
ARGUMENTS None
RETURN VALUE 1—(TRUE) Datalog was paused.
0—(FALSE) Datalog could not be paused. This may mean that
data collection is not on in the first place.
SIDE EFFECTS No datalog data is written to selected outputs until datalogging is
resumed.
SEE ALSO “tl_resume_data_collection”
tl_pgu_change_repeat
tl_pgu_change_loop
Change PGU repeat number, change PGU loop number
SYNOPSIS void tl_pgu_change_repeat(pattern, label, rep_num)
char *pattern;
char *label;
int rep_num;
void tl_pgu_change_loop(pattern, label, loop_num)
char *pattern;
char *label;
int loop_num;
DESCRIPTION These functions directly set the number of repeat and loop to the
register.
ARGUMENTS pattern— Pattern file name
label —Global label
rep_num —Number of repeat (from 1 to 4095)
loop_num— Number of loop (from 2 to 4095)
tl_pgu_read_repeat, tl_pgu_read_loop
Read PGU repeat number, read PGU loop number
tl_pgu_pattern_memory_size
Return the PGU pattern memory size.
SYNOPSIS int tl_pgu_pattern_memory_size();
DESCRIPTION This function returns the size of the Pattern Generator Unit
(PGU) pattern memory in vectors. The PGU supports either a 4K
vector or 16K vector pattern memory. The actual size of the
pattern memory is determined by the PGU software during
IMAGE initialization. The pattern memory manager is initialized
with the size of the PGU pattern memory when the test program
is loaded the first time.
ARGUMENTS None
RETURN VALUE Size of PGU pattern memory (number of vectors).
tl_pin_for_pin_id
Translate an alphanumeric pin ID into a pinmap index.
SYNOPSIS int tl_pin_for_pin_id(char *pin_id)
RETURN VALUE 0: not found; else: the index into the array
tl_pin_id_for_pin
Get alphanumeric pin ID for pin number.
SYNOPSIS char *tl_pin_id_for_pin(pinnum)
int pinnum;
DESCRIPTION This function matches the passed pin number in the user’s
pinmap and returns the associated alphanumeric pin ID.
ARGUMENTS pinnum—Pin number to match
tl_pinmap_name_for_dchan
Get pin name for passed digital channel.
SYNOPSIS char *tl_pinmap_name_for_dchan(chan_num)
int chan_num;
DESCRIPTION This function searches a pinmap for the passed channel number
of type digital (for any digital subsystem on any test head) and
returns the name found in the pinmap for the first matching pin.
ARGUMENTS chan_num—Digital channel number
RETURN VALUE Pointer to pin name in pinmap. Returns NULL if channel is not
matched, no pinmap, no pin name.
SEE ALSO “tl_pinmap_name_for_pin”
tl_pinmap_name_for_pin
Get pin name for pin number.
SYNOPSIS char *tl_pinmap_name_for_pin(pinnum)
int pinnum;
DESCRIPTION This function matches the passed pin number in a pinmap and
returns the associated name.
ARGUMENTS pinnum—Pin number to match
RETURN VALUE Pointer into pin name in pinmap structure. Returns NULL if pin is
not in pinmap or has no name or there is no pinmap.
SIDE EFFECTS Returns pointer into system data structure. Be careful.
SEE ALSO “tl_pinmap_name_for_dchan”
tl_plfd_cal_interval
Set the calibration interval for the Precision Low Frequency Digitizer.
SYNOPSIS void tl_plfd_cal_interval(amt)
int amt;
DESCRIPTION Sets the calibration interval for the Precision Low Frequency
Digitizer.
ARGUMENTS amt—Time interval
tl_plfd_set_optimization
Runs PLFDIG in optimized setup mode.
SYNOPSIS void tl_plfd_set_optimization(on_off)
tl_plfs_cal_interval
Set the calibration interval for the Precision Low Frequency Source.
SYNOPSIS void tl_plfs_cal_interval(amt)
int amt;
DESCRIPTION Sets the calibration interval for the Precision Low Frequency
Source.
ARGUMENTS amt—Time interval
tl_plfs_conn_deltabus
Connects PLFSRC output to the delta bus.
SYNOPSIS void tl_plfs_conn_deltabus(on_off)
int on_off;
tl_plfs_get_amp_filt
Apply filter correction to given amplitude for the PLFSRC.
SYNOPSIS double tl_plfs_get_amp_filt(amp, freq)
double amp, freq;
RETURN VALUE The corrected amplitude value for programming the Precision
Low Frequency AC Source.
CONFLICTS To select a low-pass filter other than 2kHz when using
tl_plfs_get_amp_filt, you must use two set pin statements
tl_plfs_get_amp_filt_spec
Apply filter correction to given amplitude for the PLFSRC.
SYNOPSIS double tl_plfs_get_amp_filt_spec(amp, freq,
filter_spec)
double amp, freq, filter_spec;
tl_plfs_undo_amp_filt
Undo filter correction to given amplitude for the PLFSRC.
SYNOPSIS double tl_plfs_undo_amp_filt(amp, freq)
double amp, freq;
DESCRIPTION Undo the filter correction to amplitude for a given frequency for
the Precision Low Frequency Source.
ARGUMENTS amp—Desired output amplitude level
freq—Frequency of the sine wave
tl_plfs_undo_amp_filt_spec
Undo filter correction to given amplitude for the PLFSRC.
SYNOPSIS double tl_plfs_undo_amp_filt_spec(amp, freq,
filter_spec)
double amp, freq, filter_spec;
DESCRIPTION Undo the filter correction to amplitude for a given frequency for
the Precision Low Frequency Source.
ARGUMENTS amp—Desired output amplitude level
freq—Frequency of the sine wave
filter_spec—Filter specified
tl_plfsrc_get_type_slot
Returns PLFSRC type given slot number.
SYNOPSIS int tl_plfsrc_get_type_slot(thSlot)
int thSlot;
tl_powerup
Variable indicating first execution since powerup.
SYNOPSIS int tl_powerup
DESCRIPTION This global integer variable indicates (nonzero) the first test
program execution since the program was loaded or since power
was cycled. If tl_powerup == 0, the program has been
executed at least once since load or test system power cycle.
(See “Initializing Memory-Dependent Data” on page 26-539.)
ARGUMENTS None
RETURN VALUE None
tl_prod_init
Initialize a test program.
SYNOPSIS tl_prod_init() { <user statements> }
tl_profile_end
Close out last bin during custom profiling.
SYNOPSIS void tl_profile_end()
DESCRIPTION Call this function when using the custom profiling feature to
declare the end of the last bin. You can also use the function to
skip sections where profiling is not desired (time from the
tl_profile_end call to the next tl_profile_mark call is
skipped). This function does nothing when profiling sequencers
is enabled.
ARGUMENTS None
RETURN VALUE None
SEE ALSO “tl_profile_mark”
tl_profile_mark
Specify a mark for custom profiling.
SYNOPSIS void tl_profile_mark(bin, name)
int bin;
char *name;
DESCRIPTION Calls to this function are placed in a test program to profile it. At
each call, the elapsed time since the previous call is added to the
previous call’s bin number. Call the function tl_profile_end()
at the end of the area being profiled to close out the last bin. If
omitted, all the time up to the tl_profile_print call is added
to the last bin.
This function does nothing when profiling sequencers rather than
custom is enabled.
ARGUMENTS bin—An arbitrary numerical profiling bin number. Multiple calls
with the same bin number accumulate time in a single bin.
name—String describing the bin, used in printout.
tl_psrr_lfacsrc_slot
Set LFACSRC amp and connect to waveform bus.
SYNOPSIS tl_psrr_lfacsrc_slot(slotnum, gain, connect)
int slotnum;
Gain Amp
≤2700 gain/3000
2701-3000 1.1
3001-4000 1.2
>4000 1.3
connect 1—connect
0—disconnect
RETURN VALUE None
tl_psrr_plfsrc_slot
Set PLFSRC amp and connect to waveform bus.
SYNOPSIS tl_psrr_plfsrc_slot(slotnum, gain, connect)
Gain Amp
≤2700 gain/3000
2701-3000 1.1
3001-4000 1.2
>4000 1.3
connect 1—connect
0—disconnect
RETURN VALUE None
NOTE
Before IMAGE V6.4, a signal amplitude inconsistency existed when a UB V/I was
modulated with a signal from the wave bus. This behavior caused amplitude differences in
the modulated signal depending upon the programming order of the connections made to
the wave bus for the modulation source and the UB V/I. For example, when the AC source
was connected to the wave bus before the UB V/I, the gain of the modulated signal from the
UB V/I was half of that expected.
In IMAGE V6.4 and later, this behavior has changed so that the modulated amplitude is
consistent regardless of programming order. An IMAGE Behavior Chooser (IBC) exists to
disable the fix and revert to the inconsistent behavior. See the IMAGE Quick Help file for a
description of the IBC called ubvi_wavebus_gain_consistency.
tl_psrr_plfsrc_to_wave
Connect an AC Source to the waveform bus or Delta bus
conn: Action
1: Connect
0: Disconnect
RETURN VALUE None.
tl_ptr_r
Read from pointer into Terabus space.
SYNOPSIS unsigned short tl_ptr_r(ptr)
unsigned short *ptr;
DESCRIPTION This function reads back the data at the specified virtual address.
ARGUMENTS ptr—Virtual address, in Terabus space. This value is typically
obtained by calling (ADDR) or by adding an offset (a Terabus
address) to the return value of tl_tbase_addr(0).
RETURN VALUE Data at address
tl_ptr_w
Write to pointer into Terabus space.
SYNOPSIS void tl_ptr_w(ptr, data)
unsigned short *ptr;
unsigned short data;
DESCRIPTION This function writes the data into the specified virtual address.
ARGUMENTS ptr—Virtual address, in Terabus space. This value is typically
obtained by calling tl_tbase_addr(ADDR), or by adding an
offset (a Terabus address) to the return value of
tl_tbase_addr(0).
data—Data value to be written
tl_qsc_map_dump
Dump synthesizer mapping to the station window.
SYNOPSIS struct tl_qsc_synth_info tl_qsc_map_dump();
tl_qsc_state
Dump synthesizer state to the station window.
SYNOPSIS void tl_qsc_state(source, unit)
int source, unit;
tl_qvs_alarm_disable
Disable specified alarms for QVS channel.
SYNOPSIS int tl_qvs_alarm_disable(channel, alarm, disable)
int channel;
int alarm;
int disable;
tl_qvs_combine
Combine two QVS channels into one.
tl_qvs_set_hotswitch_protection
Set test head relay delay flag and two kelvin flag.
SYNOPSIS void tl_qvs_set_hotswitch_protection(delay_flag,
two_kelvin_flag)
int delay_flag;
int two_kelvin_flag;
DESCRIPTION This function gives you control over whether IMAGE waits for the
test head relays to open after executing an QVS disconnect
statement. If the delay_flag value passed to this function is
TRUE, IMAGE issues a delay to be sure the test head relays
have opened and avoid a possible hot switch. The
two_kelvin_flag tells IMAGE to allow/disallow connects with
two points of kelvin. This can also avoid a hotswitch in certain
situations.
With every QVS reset, these flags will be reset to the default
settings:
delay_flag—FALSE
two_kelvin_flag—TRUE
int two_kelvin_flag
1—Allow connects with two kelvin points. This is the
default behavior and could result in hot switching.
0—Disallow connects with two kelvin points
RETURN VALUE None
SIDE EFFECTS Sets internal flags
tl_read_and_set_dib_info
Read and set the DIB ID and DIB type.
SYNOPSIS int tl_read_and_set_dib_info(enum
Eeprom_string_format format)
DESCRIPTION This function reads the DIB ID and DIB type, and sets them into
global variables. How this function works depends on two
factors: the test system type, and the format parameter.
For Linear test systems, the DIB ID and type are meaningless,
and the DIB ID is set to the Null String, and the DIB type is set to
the string 0.
For Mixsig test systems, the DIB ID will be set to the Null String,
and the DIB type will be set to a string representing a decimal
number from 0-511.
For Advanced Linear, Advanced Mixed-Signal, and Catalyst test
systems, this function actually queries the EEPROM and stores
the information it reads. The format of the DIB type string is
determined by the format parameter. If format ==
EEPROM_LONG_STRING, the string contains the board type, the
company ID, and the revision code (for example, 876-543-21
(5445[TE]) 9701-B.P1). If format == EEPROM_SHORT_STRING,
it contains the 8-character (hex) DIB type, with no hyphens (for
example, 87654321).
Calling this function not only sets the global variables, but also
causes these values to be written to the datalog. The variables
are stored in the Site Description Record, in the fields SDR,
dib_id, and SDR.dib_typ.
tl_read_and_set_prb_info
Read and set the probe card ID and type.
SYNOPSIS int tl_read_and_set_prb_info(enum
Eeprom_string_format format)
DESCRIPTION This function reads the probe card ID and probe card type, and
sets them into global variables. How this function works depends
on two factors: the test system type, and the format parameter.
For Linear and Mixsig test systems, the probe card ID and type
are meaningless, and the probe card ID is set to the Null String,
and the probe card type is set to the string "0".
For Advanced Linear, Advanced Mixed-Signal, and Catalyst test
systems, this function actually queries the EEPROM and stores
the information it reads. The format of the probe card type string
is determined by the format parameter.
If format == EEPROM_LONG_STRING, the string contains the
board type, the company ID, and the revision code (for example,
876-543-21 (5445[TE]) 9701-B.P1).
Calling this function not only sets the global variables, but also
causes these values to be written to the datalog.
The variables are stored in the Site Description Record, in the
fields SDR.card_id and SDR.card_typ.
This function can only be called before testing actually begins.
Once the first part has started testing, this function returns an
error code of -1, and will not set the global variables nor affect
the datalog.
ARGUMENTS enum Eeprom_string_format format—
tl_read_cmod_cod
Read the value of the command mode code.
SYNOPSIS char tl_read_cmod_cod()
DESCRIPTION This function reads the command mode code for the current lot.
The default value is a blank space.
The mode code is a string sent to the datalogger to describe the
mode that the tester is running in. The operating mode is set to
E (engineering) or P (production) when the test program is
loaded or when you change the mode of the workstation
environment. When setting the mode, a job_station_mode
event is issued.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 and the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS None
RETURN VALUE char—The character representing the current operating mode of
the station.
tl_read_datnum
Read the datalog (test) number.
SYNOPSIS int tl_read_datnum()
DESCRIPTION Reads the datalog (test) number for the test currently being
executed. This function is illegal outside of a TESTF. Example:
{
int tnum;
tnum = tl_read_datnum();
}
ARGUMENTS None
RETURN VALUE The test number for the currently executing TESTF (return
value>0). Function not called from within a TESTF; returns (-2).
tl_read_device
Read the value of the current DUT.
SYNOPSIS int tl_read_device()
DESCRIPTION Returns the number of the current device under test. Returns 0
if called from outside a serial loop in a test program using
multisite test. Also returns 0 if the part has been binned.
Example:
{
printf("Now Testing Device %d\n", tl_read_device());
}
ARGUMENTS None
RETURN VALUE The device number of the current DUT as an integer value, or 0
if no sites are enabled.
tl_read_device_site
Read the value of the DUT of given site
SYNOPSIS int tl_read_device(int site);
DESCRIPTION Returns the number of the device under test of the given site. Will
return 0 if given site is not valid.
ARGUMENTS int site
RETURN VALUE The device number of the DUT of the given site as an integer
value.
tl_read_dib_type_int
Read back DIB Type code as integer.
SYNOPSIS int tl_read_dib_type_int()
DESCRIPTION Reads back the state of the ID jumpers on the DIB board. The
jumpers are weighted in the following way:
DIBID # grounded 8 7 6 5 4 3 2 1
Value in readback 128 64 32 16 8 4 2 1
The DIBID-9 is reserved for Teradyne DIBs. Therefore a
customer DIB should always return a number less that 256 while
Teradyne DIB ID’s are 256 or greater.
ARGUMENTS None
RETURN VALUE Bit-mapped ID number from 0 to 511.
tl_read_disp_cod
Read the lot disposition code.
SYNOPSIS char tl_read_disp_cod()
DESCRIPTION Reads back the value of the lot disposition code as a character.
The default value is “ ” (space). Example:
{
printf("The status of the lot is: '%c'.\n",
tl_read_disp_cod());
}
ARGUMENTS None
RETURN VALUE The lot disposition code as a char.
SEE ALSO “tl_set_disp_cod”
tl_read_exec_typ
Return the name of the test executive.
SYNOPSIS char *tl_read_exec_typ(s);
tl_read_format
Read the datalog format for the current test.
SYNOPSIS int tl_read_format(s)
char *s;
DESCRIPTION Copies the format string for the current test into the user-
provided string, *s. Memory for this string must have been
allocated before this function was called and must be at least
S_FMT + 1 characters long. If this function is called from outside
a TESTF, it returns an error. The text of the error message will be:
"tl_read_label illegal outside of a TESTF"
Example:
{
char fstr[25];
tl_read_format(fstr);
printf("The format string is: '%s' \n",fstr);
}
ARGUMENTS None
RETURN VALUE The format of the current test as a character string through the
argument. As a function return:
0—for successful copy
-2—if an error occurred
tl_read_gigadig_hpfilt_slot
Returns status of hpfilt setting.
SYNOPSIS int tl_read_gigadig_hpfilt_slot(int slot)
tl_read_hand_id
Return the value of the handler id(obsolete).
SYNOPSIS char *tl_read_hand_id( s );
tl_read_hbin_is_pass
Is a hardware bin is a pass bin or a fail bin?
SYNOPSIS int tl_read_hbin_is_pass(bin)
int bin;
tl_read_hfdig_hpfilt
Return status of the HFDIG hpfilt setting.
SYNOPSIS int tl_read_hfdig_hpfilt(pin)
int pin;
DESCRIPTION Returns status of the hpfilt setting for the HFDIG specified.
ARGUMENTS pin—Pin number or pin name associated with the HFDIG in
question
RETURN VALUE 1—If the hpfilt is on
0—If the hpfilt is off
tl_read_hfdig_hpfilt_slot
Return status of the HFDIG hpfilt setting.
SYNOPSIS int tl_read_hfdig_hpfilt_slot(slot)
int slot;
DESCRIPTION Returns status of the hpfilt setting for the HFDIG specified.
ARGUMENTS slot—Test head slot number of the HFDIG in question
tl_read_highlim
Return value of upper test limit.
SYNOPSIS int tl_read_highlim(highlimit)
double *highlimit;
DESCRIPTION Reads the value of current test’s high limit. This function must be
called from within the TESTF whose high limit value is desired.
Example:
{
double high_limit;
if (tl_read_highlim(&high_limit) == 0)
printf("The high limit for test %d is:
%g \n",tl_read_datnum(), high_limit);
}
ARGUMENTS highlimit—A pointer to double which will contain the high limit.
RETURN VALUE The value of the high limit is returned through the argument. The
function return will indicate if any errors occurred.
0—Success
-1—No valid high limit for this test
-2—Errors
SEE ALSO “tl_read_lowlim”, “tl_write_lowlim”, “tl_write_highlim”
tl_read_ids
Read lot and sublot IDs.
SYNOPSIS char * tl_read_ids(s)
char s[];
DESCRIPTION Get a concatenation of the lot and sublot IDs. If the sublot ID is
set it returns:
<lot ID>:<sublot ID>
If the sublot ID is not set, it returns the lot ID. Example:
{
char IDS[S_STDF_STRING+1];
printf("The entire lot ID is: '%s' \n"
tl_read_ids(IDS));
}
ARGUMENTS [The address of] An array in which to place the lot ID string.
RETURN VALUE Its argument.
SEE ALSO “tl_read_lot_id”, “tl_read_sblot_id”, “tl_begin_lot”,
“tl_write_lot_id”, “tl_write_sblot_id”, “tl_write_lot_ids”
tl_read_job_nam
Return the name of the currently loaded test program.
SYNOPSIS char *tl_read_job_nam(s);
RETURN VALUE A character string containing the test program name, through the
argument.
SEE ALSO “tl_read_lot_id”, “tl_read_sblot_id”, “tl_begin_lot”,
“tl_write_lot_id”, “tl_write_sblot_id”, “tl_write_lot_ids”
tl_read_job_rev
Return the test program revision.
SYNOPSIS char *tl_read_job_rev(s);
tl_read_label
Returns the label assigned to the current test.
SYNOPSIS int tl_read_label(s);
char *s;
DESCRIPTION Copies the label for the current test into the user provided string,
*s. If this function is called from outside a TESTF it will return an
error. The text of the error message will be:
tl_read_label illegal outside of a TESTF.
ARGUMENTS s—A pointer to the buffer into which this function will write the
label. Memory for this string must have been allocated before
this function is called and must be at least size of the label being
read + 1 characters long. To determine the size of the label, call:
tl_read_label_size()
RETURN VALUE The label of the current test as a character string via the
argument. As a function return: 0 for successful copy, -2 if an
error occurred.
SIDE EFFECTS If the buffer passed in is not long enough to hold the label being
read, a memory overwrite will occur. Memory overwrites will
cause serious problems with the stability of the test program
calling this function.
tl_read_label_size
Return the size of the label assigned to the current test.
SYNOPSIS int tl_read_label_size();
DESCRIPTION Returns the length of the label string assigned to the current test.
The buffer allocated for the function tl_read_label must be at
least one byte longer than this length.
If this function is called from outside a TESTF it returns an error.
The text of the error message is:
tl_read_label illegal outside of a TESTF.
ARGUMENTS None
RETURN VALUE The size in bytes of the label of the current test. -2 if an error
occurred.
tl_read_label_truncate
Return the label assigned to the current test. Truncate it if necessary.
DESCRIPTION Copies the label for the current test into the user provided string,
*s. If this function is called from outside a TESTF it will return an
error. The text of the error message will be:
tl_read_label illegal outside of a TESTF.
ARGUMENTS s—A pointer to the buffer into which this function will write the
label. Memory for this string must have been allocated before
this function is called and must be at least len+1.
len—The label read will be truncated to this length.
RETURN VALUE The label of the current test as a character string via the
argument. As a function return: 0 for successful copy, -2 if an
error occurred.
tl_read_lot_id
Read the value of the current lot ID.
SYNOPSIS char *tl_read_lot_id(char *s);
DESCRIPTION This function copies the current lot ID into memory pointed to by
the argument. It is your responsibility to allocate sufficient
memory. No checking is performed to assure that this condition
is met. The lot ID is set using the lot command. (See “Setting
the Lot and Sublot” on page 6-3.) Initially its value is \0 (null).
Example:
{
char lotid[S_STDF_STRING+1];
printf("The Lot ID is: '%s' \n",
tl_read_lot_id(lotid));
}
ARGUMENTS Accepts a pointer to a character string. It is assumed that
memory has already been allocated.
RETURN VALUE A character string pointing to the current lot ID, through the
argument.
SEE ALSO “tl_read_sblot_id”, “tl_read_lot_id”, “tl_begin_lot”,
“tl_write_lot_id”, “tl_write_sblot_id”, “tl_write_lot_ids”
tl_read_lowlim
Return value of lower test limit.
SYNOPSIS int tl_read_lowlim(lowlimit)
double *lowlimit;
DESCRIPTION Reads the value of current test’s low limit. This function must be
called from within the TESTF whose low limit value is desired.
ARGUMENTS lowlimit—A pointer to double which will contain the low limit.
RETURN VALUE The value of the low limit is returned through the argument. The
function return will indicate if any errors occurred.
0—Success
-1—No valid low limit for this test
-2—Errors
SEE ALSO “tl_read_highlim”, “tl_write_lowlim”, “tl_write_highlim”
tl_read_meter_n_wmd_set
Set tl_read_meter_n_wmd to value.
SYNOPSIS void tl_read_meter_n_wmd_set(value)
double value;
tl_read_mode_cod
Read the operational mode code for the current lot.
SYNOPSIS char tl_read_mode_cod();
DESCRIPTION This function reads the operating mode code for the current lot.
The mode code is a string sent to the datalogger to describe the
mode the tester is running in.
The operating mode is set to E (engineering) or P (production)
when the test program is loaded or when you change the mode
of the workstation environment. A job_station_mode event is
issued when setting the mode. Example:
{
char mode;
mode = tl_read_mode_cod();
printf("The station is in mode: %c \n", mode);
}
tl_read_node_nam
Read the tester (network) node name.
SYNOPSIS char * tl_read_node_nam(s)
char s[];
DESCRIPTION Reads the tester (network) node name. This name is obtained
from the test system when the test program is loaded and cannot
be changed. Example:
{
char noden[S_STDF_STRING+1];
printf("The tester node is: %s\n",
tl_read_node_nam(noden));
}
ARGUMENTS [The address of] An array in which to place the node name.
RETURN VALUE The argument (node name)
tl_read_oper_nam
Return the name of the current operator.
SYNOPSIS char *tl_read_oper_nam(s);
tl_read_part_cnt
Read the number of parts tested for a lot.
SYNOPSIS unsigned int tl_read_part_cnt()
DESCRIPTION Reads back the number of parts tested for the current lot. This
number is incremented each time a sort bin statement with a
valid bin number (0-256) is executed for a device. Example:
{
printf("There have been %d parts tested.\n",
tl_read_part_cnt());
}
ARGUMENTS None
RETURN VALUE The number of parts tested for the current lot.
tl_read_part_id
Read the device number (or other ID) for the DUT.
SYNOPSIS char * tl_read_part_id(s)
char s[];
DESCRIPTION Reads back the device number (or other ID) for the DUT as a text
string. Unless specifically set using tl_set_device, IMAGE
assigns part IDs using a serial integer counter. This function
always reads back the value of that serial counter. Example:
{
char dutid[S_STDF_STRING+1];
printf("The DUT is device '%s'.\n",
tl_read_part_id(dutid));
}
ARGUMENTS [The address of] An array in which to place the part ID string.
RETURN VALUE Its argument (the part ID string) or 0 if no sites are enabled.
SIDE EFFECTS A runtime error is generated if called from a multisite test
program and not in a serial loop.
SEE ALSO “tl_read_device”
tl_read_part_typ
Read the Part Type text string.
SYNOPSIS char *tl_read_part_typ (s)
char s[];
DESCRIPTION Reads the Part Type text string. The default value for this field
is \0 (null). Example:
{
char pt[S_STDF_STRING+1];
printf("The part type is: '%s' \n",
tl_read_part_typ(pt));
}
ARGUMENTS [The address of] An array in which to place the part type string.
RETURN VALUE Its argument (part type).
SEE ALSO “tl_read_device”
tl_read_proc_id
Read the process ID of the parts being tested.
SYNOPSIS char * tl_read_proc_id(s)
char s[];
tl_read_prot_cod
Read the value of the data protection code.
SYNOPSIS char tl_read_prot_cod()
DESCRIPTION This function returns the value of the data protection code as a
character. Example:
{
char pcode;
pcode = tl_read_prot_cod();
printf("The data protection code is: '%c' \n",pcode);
}
ARGUMENTS None
RETURN VALUE The “data protection code” as a character. (Default value is “ ”
<space>)
tl_read_rtst_cod
Read the value of the retest code.
SYNOPSIS char tl_read_rtst_cod()
tl_read_sbin_is_pass
Is a software bin is a pass bin or a fail bin?
SYNOPSIS int tl_read_sbin_is_pass(bin)
int bin;
tl_read_sblot_id
Return the value of the sublot ID.
SYNOPSIS char *tl_read_sblot_id(s);
tl_read_sblot_id(lsbotid));
}
ARGUMENTS char *s—A pointer to user-allocated memory which will have
the sublot ID written to it. It is your responsibility to allocate
sufficient memory.
RETURN VALUE A character string containing the sublot ID, through the
argument.
SEE ALSO “tl_read_lot_id”, “tl_read_ids”, “tl_begin_lot”, “tl_write_lot_id”,
“tl_write_sblot_id”, “tl_write_lot_ids”
tl_read_setup_t
Read the value of the setup time variable.
SYNOPSIS unsigned int tl_read_setup_t()
DESCRIPTION Reads the time the test program was loaded as an integer which
represents the number of seconds since January 1, 1970 in
(GMT seconds - “seconds west of GMT” [adjusted for local time
zone]). This setup time is automatically set when the test
program is loaded and cannot be changed. Example:
#include <sys/time.h>
{
struct timeval tp;
struct timezone tzp;
unsigned int current_time;
extern char *ctime();
tl_read_start_t
Read the start time.
SYNOPSIS unsigned int tl_read_start_t()
DESCRIPTION Reads the time that the lot was started, as an integer which
represents the number of seconds since January 1, 1970 in
(GMT seconds - “seconds west of GMT” [adjusted for local time
zone]). Example:
#include <sys/time.h>
{
struct timeval tp;
struct timezone tzp;
unsigned int current_time;
extern char *ctime();
tl_read_station_num
Read the current station number.
SYNOPSIS int tl_read_station_num()
DESCRIPTION This function returns the station number the test program is
currently loaded into. This number can be distinct from the test
head number, since a test program can be loaded into an
auxiliary station and that station can then be switched to a
different test head. See “Choosing Test-Head Type When
Loading an Auxiliary Station” on page 5-10.
ARGUMENTS None
RETURN VALUE Current station number
tl_read_supr_nam
Return the current supervisor name.
SYNOPSIS char *tl_read_supr_nam(s);
tl_read_test_cod
Read the test code.
SYNOPSIS char * tl_read_test_cod(s)
char s[3];
DESCRIPTION Reads a three character test condition set using the testcond
command. (See “Setting Test Conditions Using the testcond
Command” on page 6-10.) Example:
{
char tcode[3];
tl_read_test_cod(tcode);
printf("Test code is: %c %c %c\n",tcode[0],
tcode[1],tcode[2]);
}
ARGUMENTS (The address of) A three character array to be filled in.
RETURN VALUE Its argument (that is, s)
tl_read_tja
Read measurement value from DARRAY
SYNOPSIS double tl_read_tja(raw_data)
DARRAY raw_data;
tl_read_tja_array
Read measurement array from DARRAY
SYNOPSIS void tl_read_tja_array(raw_data, array, array_size)
DARRAY raw_data;
double array[];
int array_size;
tl_read_tmscal_status
Return the calibration state of the Advanced Time Measurement Subsystem.
SYNOPSIS int tl_read_tmscal_status()
DESCRIPTION This function determines the status of the most recent ATMS
calibration attempt. This protects the user (or checker writer)
from going into shared memory for the results. This functions
checks the calibration status in shared memory for the current
station and also verifies the time stamp against the current time.
This means that if called twice during the same test program run
the calibration status may change.
ARGUMENTS None
RETURN VALUE -2 Last calibration attempt passed but has now expired.
-1 Last calibration attempt failed.
0 Uncalibrated, ATMS has not been calibrated since last
initialize.
1 Last calibration attempt passed and is still valid.
tl_read_tstr_typ
Read the tester type.
DESCRIPTION Reads the tester type (such as A550 or A530). The tester type is
automatically set when the test program is loaded and cannot be
changed. Example:
{
char text[S_STDF_STRING+1];
printf("The tester is: %s\n",
tl_read_tstr_typ(text));
}
ARGUMENTS (The address of) An array in which to place the tester type text.
RETURN VALUE Its argument.
tl_read_user_eeprom_all_data
Read all data from HUC ID PROM.
SYNOPSIS int tl_read_user_eeprom_all_data(which, buf)
EEPROM_ENUM_TYPE which;
unsigned short *buf;
DESCRIPTION Reads all data (16 words x 16 bits/word) from one of four ID
EEPROMS on the HUC. The argument which determines which
EEPROM is read from. The data is stored in a 16 element array
of unsigned short pointed to by the argument buf.
ARGUMENTS which—Determines which ID EEPROM on the HUC is read
from:
CONFIGA—Configuration Board A
CONFIGB—Configuration Board B
DIB—Device Interface Board (DIB)
TLDUT—Device Under Test (DUT)
tl_read_user_eeprom_id_data
Read coded data from HUC ID PROM.
SYNOPSIS int tl_read_user_eeprom_id_data(which, buf)
EEPROM_ENUM_TYPE which;
TER_EEPROM_ID *buf;
tl_read_usr_desc
Read the user description.
SYNOPSIS char * tl_read_usr_desc(s)
char s[];
DESCRIPTION Reads back the “user description” text string for the lot. The
default value is a null string. Example:
{
char desc[S_STDF_STRING+1];
printf("Lot Description: '%s'.\n",
tl_read_usr_desc(desc));
}
ARGUMENTS (The address of) An array in which to place the description string.
RETURN VALUE Its argument.
tl_read_uwrecv_digslot
Read back which slot of the digitizer the Microwave Receiver is using.
SYNOPSIS int tl_read_uwrecv_digslot(pin)
int pin;
DESCRIPTION Read back the digitizer slot the Microwave Receiver (UWRECV)
is using.
ARGUMENTS pin—Pin the UWRECV is behind
tl_read_uwrecv_digslot_slot
Read back which slot of the digitizer the UWRECV is using.
SYNOPSIS int tl_read_uwrecv_digslot_slot(slot, schan)
int slot;
int schan;
DESCRIPTION Read back the slot of the digitizer the Microwave Receiver
(UWRECV) is using.
ARGUMENTS slot—Slot the UWRECV is in
schan—Schan of the UWRECV
tl_read_uwrecv_thads
Read back which THADS the Microwave Receiver is using.
SYNOPSIS int tl_read_uwrecv_thads(pin)
int pin;
tl_read_uwrecv_thads_slot
Read back which THADS the UWRECV is using.
SYNOPSIS int tl_read_uwrecv_thads_slot(slot, schan)
int slot;
int schan;
tl_read_wafer
Read back wafer coordinates, if set.
SYNOPSIS int tl_read_wafer(xptr, yptr)
int *xptr, *yptr;
DESCRIPTION This function reads back the wafer die coordinates which have
been sent to the datalogger previously by the IMAGE software or
by a prior call to the function tl_set_device_info(). It expects
to be passed the addresses of two integer variables, into which
it will write the coordinates. Example:
int xc, yc;
tl_read_wafer(&xc, &yc);
ARGUMENTS xptr—Pointer to integer into which x coordinate will be stored
yptr—Pointer to integer into which y coordinate will be stored
tl_read_wafer_mapping_ink_bin
Return the value of the ink bin.
SYNOPSIS unsigned short tl_read_wafer_mapping_ink_bin()
DESCRIPTION This function returns the value of the ink bin variable.
ARGUMENTS None
RETURN VALUE Unsigned short value of the SECS ink bin.
tl_remove_datalog_output
Remove an output stream from datalog.
SYNOPSIS int tl_remove_datalog_output(unsigned int key...);
Multiple streams can be removed in one call. You must call this
function before the first device is tested. Once the program has
run, calls to tl_remove_datalog_output() are rejected.
tl_remove_datastream
Remove a data stream
SYNOPSIS int tl_remove_datastream(char * stream_id);
RETURN VALUE 0 - There was an error either connecting to the data server, or the
arguments were incorrectly specified, or testing has already
begun on this lot.
1 - Success, the command line was correct and the command
successfully processed by the data server.
tl_reprobing_device
Report whether the current set of devices under test are being reprobed.
SYNOPSIS int tl_reprobing_device()
the running sites for a test program, site number does not play
any role in the return value of this function. If the current device
is not being reprobed, it returns 0.
ARGUMENTS None
RETURN VALUE 1 (True) if the current set of devices are being reprobed
0 (False) if the current set of devices are not being reprobed.
tl_restore_site_state
Restore a saved site state.
SYNOPSIS void tl_restore_site_state(tl_site_state_buffer
*restore_buffer)
DESCRIPTION This function restores the site state variables from the provided
site state buffer structure pointer argument.
ARGUMENTS struct site_state_buffer * restore_buffer—Site state
buffer to use to restore the set of site related variables.
RETURN VALUE None
SEE ALSO tl_save_site_state
tl_resume_data_collection
Resume data collection if it was paused.
SYNOPSIS int tl_resume_data_collection(void)
DESCRIPTION This function can be used to restart data collection once it has
been paused. Data collection may have been paused using the
datalog command, the datalog display, or by calling
tl_pause_data_collection(), from the test program.
ARGUMENTS None
RETURN VALUE 1—Data collection has been resumed.
0—Data collection has not been resumed. This is probably
because it was not on.
SIDE EFFECTS Turns the flow of data back on.
SEE ALSO “tl_pause_data_collection”
tl_retesting_device
Report whether the current set of devices under test are being retested.
SYNOPSIS int tl_retesting_device()
tl_retrieve_d
Retrieve the value of a variable of type double.
SYNOPSIS double tl_retrieve_d(name)
char * name;
DESCRIPTION This function is used in multisite test programs to retrieve the site
specific value of a variable previously saved using a save ddata
statement. It is similar to the retrieve ddata statement, but
returns the value of the variable instead of setting the variable to
the value. Example:
test read_meter() - tl_retrieve_d("offset");
See also “Global Variables in Multisite Test Programs” on page
17-17.
ARGUMENTS name—The name of the double variable (in quotes).
RETURN VALUE The value of the double variable previously saved for the
currently active site. If no site is active, 0.0 is returned.
tl_retrieve_i
Retrieve the value of an integer variable.
SYNOPSIS int tl_retrieve_i(name)
char * name;
DESCRIPTION This function is used in multisite test programs to retrieve the site
specific value of a variable previously saved using a save idata
statement. It is similar to the retrieve idata statement, but
returns the value of the variable instead of setting the variable to
the value. Example:
num_samples = new_samples + tl_retrive_i("old_samples");
See also “Global Variables in Multisite Test Programs” on page
17-17.
RETURN VALUE The value of the integer variable previously saved for the
currently active site. If no site is active, 0 is returned.
tl_rs232_close
Close a device specified by device handle.
SYNOPSIS int tl_rs232_close(int devHandle);
tl_rs232_open
Open a tty (RS232) device.
SYNOPSIS int tl_rs232_open(char *devName);
DESCRIPTION This function opens a tty device. In this function, the name of the
device can be fully rooted (/some/hath/device_name) or only
the device name (device_name) as it appears in the /dev
directory. If the name is not a full path name, /dev/ is assumed.
For example, to open /dev/ttyb you can use:
int ttyb_fh;
ttyb_fh = tl_rs232_open("ttyb");
if (ttyb_fh < 0) {
<Perform error processing>
}
For a full path name, you can use:
ttyb_fh = tl_rs232_open("/dev/ttyb");
if (ttyb_fh < 0) {
<Perform error processing>
}
If the device is a link, the link is resolved and the device the link
pointed to is opened.
IMAGE RS232 functions can be used to support a maximum of
10 tty (RS232) devices simultaneously. Once devices are no
tl_rs232_open_remote_port
Open remote RS232 port.
SYNOPSIS tl_rs232_open_remote_port(port,test_computer)
int port;
char *test_computer;
DESCRIPTION This function will only operate on rs232 ports that are accessible
either directly or remotely. This currently includes the resident
cpu tty ports and ports provided via the terminal server option.
Note that ports that are bound to the CPU refer to those of the
calling computer. Care should be taken in regard to utilizing this
function on the system computer in a dual computer environment
since /dev/ttyb is used by the IMAGE software.
The ALM1 and ALM2 specified ports are not accessible if they
are not resident.
To create a stand-alone program which can access rs232 ports
(other than from a test program), use the following compile line:
cc -o foo foo.c /image/bin.rls/librs232.a /image/bin.rls/lib/libsys.a
where "foo" is the name of your program.
Note: the use of an rs232cap file is required. Remember that this
file must live in /image/tester/<host> and that the
test_computer parameter, above, corresponds to the <host> in
the path.
tl_rs232_read
Read from a tty (RS232) device.
SYNOPSIS int tl_rs232_read(int devHandle,
char *buf, int bufSize);
tl_rs232_write
Write a to a tty (RS232) device.
tl_send_to_SECS_GEM
Send a string to SECS/GEM
SYNOPSIS int tl_send_to_SECS_GEM(char * message);
tl_set_alarm_msg_mode
Set destination for alarm messages.
SYNOPSIS enum TL_MSG_MODE tl_set_alarm_msg_mode(newmode)
enum TL_MSG_MODE newmode;
tl_set_autocal_onoff
Turn autocal on or off.
SYNOPSIS void tl_set_autocal_onoff(flag)
tl_set_autosummary
Sets autosummary from a test program.
SYNOPSIS int tl_set_autosummary
When this function is called it sets the auto summary setup to the
criteria used in the most recent call of the function.
There are two restrictions when using this function:
-AUTOSUM_OFF flag must be used alone, as in:
tl_set_autosummary(AUTOSUM_OFF, NULL)
-FAIL_TESTS_ONLY and ALL_TESTS flags cannot be used at the
same time
Beyond these two exceptions, there are no restrictions on the
use of arguments.
The SMY_FORMATTER will apply to formatted (ASCII) outputs.
These are:
FILE,
STATWIN
PRINTER
The SMY_FORMATTER argument must be specified for formatted
(ASCII) outputs; it does not default to sumfmt as it does when
using the setauto command does.
Examples:
Enable autosummary to the station window, file, and printer
using printer name speedy and summary formatting process
my_formatter:
err = tl_set_autosummary(SETAUTO_FILE,SETAUTO_STATWIN,
SETAUTO_PRINTER_NAME, "speedy",
SETAUTO_SMY_FORMATTER, "my_formatter",
NULL);
Because the printer name for the summary is being specified, it
is not necessary to use the SETAUTO_LPR argument.
Enable autosummary to an ASCII file called my_ascii_file and
to the default printer for failing tests only:
err = tl_set_autosummary(SETAUTO_FILE_NAME,
"my_ascii_file", SETAUTO_LPR,
SETAUTO_SMY_FORMATTER, "sumfmt",
SETAUTO_FAIL_TESTS_ONLY, NULL);
Because the name of the ASCII file for the summary is specified,
the SETAUTO_FILE parameter is unnecessary.
ARGUMENTS Variable number of arguments, generally in pairs <flag,
argument>. The arguments can be unsigned integer flags or
character strings. The entire argument list library must be
terminated by NULL.
RETURN VALUE 0— Failure—an error occurred because of conflicting
parameters or connection to the data server was not possible.
1— Success—auto summary set up.
SEE ALSO For more information regarding the setauto command, see
“Automatic Summary Reports Using the setauto Command” on
page 6-96.
SIDE EFFECTS Changes the setup of the auto summary.
tl_set_burn_tim
Set burn-in time for the current lot.
SYNOPSIS int tl_set_burn_tim(i)
int i;
DESCRIPTION Sets the burn-in time in units of minutes for the current lot being
tested.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the burn-in time for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2, and/or
the Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS i—Burn-in time in minutes for the current lot.
tl_set_cabl_id
Set interface cable ID for the current lot.
SYNOPSIS int tl_set_cabl_id(s)
char *s;
DESCRIPTION This function sets the interface cable ID for the current lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the interface cable id for
the current lot, you must call this function before execution of the
first sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2, and/or
the Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing interface cable ID
tl_set_cabl_typ
Set interface cable type for the current lot.
SYNOPSIS int tl_set_cabl_typ(s)
char *s;
DESCRIPTION Sets the interface cable type for the current lot.
tl_set_cmod_cod
Set command mode code for the current lot.
SYNOPSIS int tl_set_cmod_cod(c)
char c;
DESCRIPTION Sets the command mode code for the current lot. The command
mode code is a single-character, user-defined field sent to the
datalogger as part of the lot setup information.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the command mode code
for the current lot, you must call this function before execution of
the first sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS c—Single character containing command mode code
tl_set_cont_id
Set contactor ID for the current lot.
SYNOPSIS int tl_set_cont_id(s)
char *s;
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing the contactor ID
tl_set_cont_typ
Set contactor type for the current lot.
SYNOPSIS int tl_set_cont_typ(s)
char *s;
DESCRIPTION This function sets the contactor type for the current lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the contactor type for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing contactor type
tl_set_datalog
Controls datalog from a test program.
SYNOPSIS int tl_set_datalog(unsigned int key...);
DESCRIPTION Controls datalog from the test program. Use this function rather
than calling the datalog command from the test program using
the tl_system() function. If IMAGE is busy (that is, processing
data from the previous test program run) this function waits until
IMAGE is free.
Use of this function is similar to using the datalog command.
You must minimally specify the state for datalog (on or off), the
datalog criteria (such as passing, failing, or all) and one or more
Flag Value
TL_DLG_STATE TL_DLG_ON
TL_DLG_OFF
TL_DLG_ON No value
TL_DLG_OFF No value
TL_DLG_OUTPUT TL_DLG_O_DWIN
TL_DLG_O_STATWIN
TL_DLG_O_FILE
TL_DLG_O_STDF
TL_DLG_O_PRINTER
Flag Value
TL_DLG_TEST TL_DLG_ALL_TEST
TL_DLG_PASS_TEST
TL_DLG_FAIL_TEST
TL_DLG_ANALOG_TEST
TL_DLG_DIGITAL_TEST
TL_DLG_PIN_OUTPUT TL_DLG_PIN_NAMES
TL_DLG_PIN_NUMBERS
TL_DLG_FILE_NAME char *—Name for datalog text file for ASCII datalog output
TL_DLG_WAFER_MAP No value. Get X/Y data for all devices in sample datalog
tl_set_datalog_disk_usage
Set expected datalog disk usage for the Disk Monitor.
SYNOPSIS int tl_set_datalog_disk_usage
(int amount);
DESCRIPTION This function tells dataserv the expected amount of KB/s worth
of datalog output generated by the test program.
ARGUMENTS amount—Expected number of KB/s
RETURN VALUE int 0: command failed. Either Disk Monitor not active or bad
arguments.
int 1: command succeeded
tl_set_device
Set device ID for current run.
SYNOPSIS int tl_set_device(id)
int id;
DESCRIPTION This function sets the part ID for the device currently being
tested. A legal part ID number is a positive integer.
You must call this function before the start of any testing or
datalogging within a run of a program. In other words, if you want
to change the device ID for a given run of the test program, the
call to this function must come before any sequencers are called
and before any information is sent to the datalogger. A TL error
will result if this function not called before these events.
This function is provided mainly to allow you to override the value
which the IMAGE test system software fills in by default. By
default, IMAGE will start the part ID number at 1 and increment
the number with each run of the test program.
In a multisite test program, this function must be called within a
serial loop. Even when called from within a serial loop, this
function always sets the device id for the lowest numbered site,
typically site 0. All other sites are incrementally set relative to the
lowest numbered site.
ARGUMENTS id—Integer containing device ID number
tl_set_dib_id
Set DIB ID for the current lot.
SYNOPSIS int tl_set_dib_id(s)
char *s;
DESCRIPTION This function sets the DIB ID for the current lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the DIB board type for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4, part
number 555-611-01.
If the IMAGE Behavior Chooser option
IBC_ACCURATE_EEPROM_STRINGS is disabled, this function has
no effect.
ARGUMENTS s—String containing DIB ID
tl_set_dib_typ
Set DIB board type for the current lot.
SYNOPSIS int tl_set_dib_typ(s)
char *s;
DESCRIPTION Sets the DIB board type for the current lot.
tl_set_disp_cod
Set the disposition code for the current lot.
SYNOPSIS int tl_set_disp_cod(c)
char c;
DESCRIPTION This function sets the disposition code for the current lot. The
disposition code is a single character sent to the datalogger
which allows you to set the status of the lot.
Unlike many other tl_set_ functions, this function can be called
at any time until the lot is closed using a final summary or auto
endlot. If this function is called more than once during a lot, only
the disposition code from the last call is used.
For details on information recorded by the IMAGE datalogger in
STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4, part
number 555-611-01.
ARGUMENTS c—Character containing lot disposition code
tl_set_dlg_enable
Enable or disable datalog.
SYNOPSIS int tl_set_dlg_enable(state)
int state;
tl_set_dsgn_rev
Set the device design revision for the current lot.
SYNOPSIS int tl_set_dsgn_rev(s)
char *s;
DESCRIPTION Sets the device design revision string for the current lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the device design revision
for the current lot, you must call this function before execution of
the first sequencer of the first run of the test program.
For details on information recorded by the IMAGE datalogger in
STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4, part
number 555-611-01.
ARGUMENTS s—String containing device design revision string
tl_set_efd_datalog
Provides user control of EFD (Enhanced Functional Datalog)
SYNOPSIS int tl_set_efd_datalog(unsigned int key...);
tl_set_eng_id
Set the engineering lot ID for the current lot.
SYNOPSIS int tl_set_eng_id(s)
char *s;
tl_set_extr_id
Set extra equipment ID for the current lot.
SYNOPSIS int tl_set_extr_id(s)
char *s;
tl_set_extr_typ
Set extra equipment type for the current lot.
SYNOPSIS int tl_set_extr_typ(s)
char *s;
DESCRIPTION Sets the extra equipment type for the current lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the extra equip. type for
the current lot, you must call this function before execution of the
first sequencer of the first run of the test program.
For details on information recorded by the IMAGE datalogger in
STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4, part
number 555-611-01.
ARGUMENTS s—String containing the extra equipment type
tl_set_facil_id
Set the test facility ID for the current lot.
SYNOPSIS int tl_set_facil_id(s)
char *s;
tl_set_famly_id
Set device family ID for the current lot.
SYNOPSIS int tl_set_famly_id(s)
char *s;
DESCRIPTION This function sets the device family ID for the current lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the device family ID for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on information recorded by the IMAGE datalogger in
STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4, part
number 555-611-01.
ARGUMENTS s—String containing family ID
tl_set_floor_id
Set test floor ID for the current lot.
SYNOPSIS int tl_set_floor_id(s)
char *s;
DESCRIPTION Sets the test floor ID string for the current lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the test floor ID for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on information recorded by the IMAGE datalogger in
STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4, part
number 555-611-01.
ARGUMENTS s—String containing test floor ID
tl_set_flow_id
Set test flow ID for the current lot.
SYNOPSIS int tl_set_flow_id(s)
char *s;
DESCRIPTION Sets the test flow ID for the current lot. The test flow ID is a string
sent to the datalogger to identify the name of the test program
flow used to test the current lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the test flow ID for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on information recorded by the IMAGE datalogger in
STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4, part
number 555-611-01.
ARGUMENTS s—String containing test flow ID
tl_set_hand_id
Set handler id for the current lot (obsolete)
SYNOPSIS int tl_set_hand_id(s)
char *s;
DESCRIPTION This routine sets the handler id for the current lot. The handler id
is a string sent to the datalogger to record the name of the
handler used to test the lot. This routine MUST be called before
any testing or datalogging is done for the lot. In other words, in
order to set the handler id for the current lot, you must call this
routine prior to the execution of the first sequencer of the first run
of the test program.
For more details on the information recorded by the IMAGE
datalogger in ".stdf" files, see Appendix "D" of the User's Manual,
entitled "Standard Test Data Format", and the Standard Test
Data Format Specification, version 4, part number 555-611-01.
ARGUMENTS s—String containing the handler id
tl_set_hp_name
Set the handler or prober ID string.
SYNOPSIS int tl_set_hp_name(char * hp_name)
DESCRIPTION Sets the handler or prober ID string in the STDF file. It appears
in the HAND_ID field of the Site Description Record (SDR). If the
argument is NULL the handler ID is set to a NULL string (that is,
a zero length string) and does not appear in the SDR HAND_ID
field. Calling the function with no argument rather than a NULL
argument is different. If called with no argument, what is written
to the STDF is undefined and will probably cause problems.
The handler name (or ID) is the name used to distinguish
individual devices of a particular model or type. This can be the
serial number or any other identifier used on the production floor
to distinguish between devices of a particular model.
This function cannot be called after testing for a lot has begun,
that is, after any SEQUENCER statements are called, after an
new lot has begun. If called after testing for a lot has begun, a
runtime error is generated.
ARGUMENTS char * hp_name—A character string containing the name (or ID
string) of a particular handler or prober. If this string is NULL the
no name is written to the STDF file, and the SDR HAND_ID field
is NULL.
RETURN VALUE 0—lot already begun, could not update name
1—success
SIDE EFFECTS If called after testing has begun, a runtime error is generated.
If successful, the handler name is written to the SDR HAND_ID
field, and the datalog buffer is dumped.
SEE ALSO “tl_get_hp_name”, “tl_set_hp_type”, “tl_get_hp_type”
tl_set_hp_type
Set the handler or prober type.
SYNOPSIS int tl_set_hp_type(char *hp_type)
DESCRIPTION Stores the handler type and writes it to the HAND_TYP field for the
Site Description Record (SDR). The argument is a character
string pointer containing the type of handler or prober. By default
this is the name used when issuing a handlerconf -connect
<hp_name> command. In this case, hp_name, is the handler type.
tl_set_inker_map
Create a mapping of inker to site and define which bin numbers will cause the inker to fire.
SYNOPSIS int tl_set_inker_map(int stn, int site, int inker,
int *bins);
If you set a bin number to incorrectly fire an inker, you can call
this function passing the site, the incorrect bin number, and a 0
for inker number. For example, assume that for site 0, bin
number 3 is incorrectly set to fire inker 1. Bin number 3 should
fire inker 2. Call this function as follows:
int bins[5];
Set bins 1, 2, and 3 to fire inker 1:
bins[0] = 1;
bins[1] = 2;
bins[2] = 3;
bins[3] = -1;
err = tl_set_inker_map(station_num, 0, 1, bins);
The error is discovered. To correct it, use:
bins[0] = 3;
bins[1] = -1;
err = tl_set_inker_map(station_num, 0, 2, bins);
ARGUMENTS stn—Station number
site—Site to map inker:bin number to
inker—Inker number to map to site:bin
bins—List of bin numbers which fire inker. Terminated by -1.
tl_set_job_nam
Set program name for the current lot.
SYNOPSIS int tl_set_job_nam(s)
char *s;
tl_set_job_rev
Set the test program revision for the current lot.
SYNOPSIS int tl_set_job_rev(s)
char *s;
DESCRIPTION This function sets the test program revision for the current lot.
The test program revision is a string sent to the datalogger to
identify which revision of the program was used to test the lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the test program revision
for the current lot, you must call this function before execution of
the first sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4, part
number 555-611-01.
ARGUMENTS s—String containing job plan or test program revision
tl_set_lasr_id
Set laser ID for the current lot.
SYNOPSIS int tl_set_lasr_id(s)
char *s;
tl_set_load_id
Set load board ID for the current lot.
SYNOPSIS int tl_set_load_id(s)
char *s;
tl_set_load_typ
Set load board type for the current lot.
SYNOPSIS int tl_set_load_typ(s)
char *s;
DESCRIPTION Sets the load board type for the current lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the load board type for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4, part
number 555-611-01.
ARGUMENTS s—String containing load board type
tl_set_lot_id
Set the lot ID for the current lot.
SYNOPSIS int tl_set_lot_id(s)
char *s;
DESCRIPTION This function sets the lot ID for the current lot. The lot ID is a
string sent to the datalogger to identify the lot being tested.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the lot ID for the current
lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4, part
number 555-611-01.
ARGUMENTS s—String containing lot ID
tl_set_lot_ids
Set both lot and sublot ID for the current lot.
SYNOPSIS int tl_set_lot_ids(s)
char *s;
DESCRIPTION This function sets the lot and sublot for the current lot. The lot ID
and sublot ID are strings used to identify a particular lot.
tl_set_mode_cod
Set mode code for the current lot.
SYNOPSIS int tl_set_mode_cod(c)
char c;
DESCRIPTION This function sets the “mode code” for the current lot. The mode
code is a string sent to the datalogger to describe the mode that
the tester is running in (for example, engineering or production).
IMAGE automatically calls this function to set the mode code to
E when in engineering mode and P for production mode.
tl_set_msg_mode
Set destination for error or alarm messages.
SYNOPSIS enum TL_MSG_MODE tl_set_msg_mode(newmode)
enum TL_MSG_MODE newmode;
DESCRIPTION This function controls the destination to which error and alarm
messages are sent. The argument to the function determines
where the messages are sent:
MSG_MODE_PRINT_MSGS—print messages in station window
MSG_MODE_LOG_MSGS—log messages to file
MSG_MODE_PRINT_AND_LOG_MSGS—print and log messages
MSG_MODE_SHOW—no change; return value only
tl_set_next_device
Set device ID for next run.
SYNOPSIS int tl_set_next_device(id)
int id;
DESCRIPTION This function sets the part ID for the next device to be tested. A
legal part ID number is a positive integer.
If this function is used with the function tl_set_device, the call
to this function must follow the call to tl_set_device. This is
because a call to tl_set_device(N) implicitly sets the device
ID for the next run to N+1.
This function is provided mainly to allow you to override the value
which IMAGE fills in by default. By default, IMAGE starts the part
tl_set_ONLY_test_condition
Set the test condition for the current lot without changing the test_cod field.
SYNOPSIS int tl_set_ONLY_test_condition(tc);
int tc;
tl_set_oper_frq
Set the testing operation frequency for the current lot.
SYNOPSIS int tl_set_oper_frq(s)
char *s;
DESCRIPTION Sets the testing operation frequency for the current lot. The
testing operation frequency is the sort frequency or step for the
current lot as a string.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the operation frequency for
the current lot, you must call this function before execution of the
first sequencer of the first run of the test program.
tl_set_oper_nam
Set operator name for the current lot.
SYNOPSIS int tl_set_oper_nam(s)
char *s;
DESCRIPTION This function sets the operator name for the current lot. The
operator name is a string sent to the datalogger to identify the
person operating the tester while the lot was tested.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the operator name for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing operator name
tl_set_part_datalogged
Set whether or not the current set of parts will be datalogged in the standard datalog outputs.
SYNOPSIS void tl_set_part_datalogged(int datalogged)
DESCRIPTION Sets whether or not the current set of parts will be datalogged in
the standard datalog outputs. If given an argument whose value
is nonzero (TRUE), the current set of parts for this run of the test
program will be datalogged in the standard datalog outputs.
If given a 0 (FALSE), the current set of parts will not be
datalogged. Datastreams set up using the datastream
command or from the datastream setup window are not affected
tl_set_part_fix
Set user-defined part fix string.
SYNOPSIS int tl_set_part_fix(num_bytes, s, site)
unsigned char num_bytes;
char *s;
int site;
DESCRIPTION This function sets the user-defined part fix string in the Part
Results Record (PRR) for each device for each site being used.
A check is first made to make sure the site does not exceed the
maximum allowable number of sites.
ARGUMENTS num_bytes—Unsigned number of bytes of data
s—String containing information to write to datalogger
site—Site number this corresponds to
tl_set_part_typ
Set part type for the current lot.
SYNOPSIS int tl_set_part_typ(s)
char *s;
DESCRIPTION This function sets the part type for the current lot. The part type
is a string (defined by the user) sent to the datalogger to describe
the type of part being tested.
You must call this function before testing or datalogging a lot. In
other words, to set the part type for the current lot, you must call
this function before execution of the first sequencer of the first
run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing part type
tl_set_pkg_typ
Set the package type for the current lot.
SYNOPSIS int tl_set_pkg_typ(s);
char *s;
tl_set_plfdig_legacy_filter_settling_times
Set or clear a flag to use the old PLFDIG filter settling times.
SYNOPSIS void tl_set_plfdig_legacy_filter_settling_times
(filt_flag)
DESCRIPTION Set or clear a flag to use the old plfdig filter settling times. If
cleared, the newly calculated filter settling times will be used. If
set, the times will be set as they have been in previous versions
of the code. The default is to have the flag cleared, and use the
new settings.
ARGUMENTS filt_flag—0 indicates use new settings, non-zero indicates
use of the older calculations.
RETURN VALUE None.
tl_set_prb_card
Set probe card ID for the current lot.
DESCRIPTION This function sets the probe card ID for the current lot. The probe
card ID is a string sent to the datalogger to identify which probe
card was used to test the lot of parts.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the probe card ID for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing probe card ID
tl_set_prb_typ
Set probe card type for the current lot.
SYNOPSIS int tl_set_prb_typ(s)
char *s;
DESCRIPTION Sets the probe card type for the current lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the probe card type for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing the probe card type
tl_set_proc_id
Set process ID for the current lot.
DESCRIPTION This function sets the process ID for the current lot. The process
ID (not to be confused with the UNIX process ID) is a string sent
to the datalogger to identify the name of the manufacturing
process used to produce the lot being tested.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the process ID for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing process ID
tl_set_prog_nam
Set program name for the current lot.
SYNOPSIS int tl_set_prog_nam(s)
char *s;
DESCRIPTION This function sets the program name for the current lot. The
program name is a string sent to the datalogger to identify the
test program used to generate the test data. This affects only the
name of the program that appears in any STDF file generated for
during the lot. This function will not alter the name of the file or
the module that the program resides in.
This function is called automatically by IMAGE when a test
program is loaded. It is provided mainly to allow you to override
the name set by IMAGE in the STDF file.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the program name for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing program name
tl_set_prot_cod
Set protection code for the current lot.
SYNOPSIS int tl_set_prot_cod(c)
char c;
DESCRIPTION This function sets the protection code for the current lot. The
protection code is a single-character field sent to the datalogger
which can be used to record a protection level for the test data in
a lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the protection code for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS c—Single character containing protection code
tl_set_rom_cod
Set the ROM code id for the current lot.
SYNOPSIS int tl_set_rom_cod(s)
char *s;
DESCRIPTION This function sets the ROM code ID for the current lot. The ROM
code is in a string format and sent to the datalogger to be
recorded by IMAGE in an .stdf file.
You must call this function before you do any testing or
datalogging for the lot. In other words, in order to set the tester
serial number for the current lot, you must call this function
before the execution of the first sequencer of the first run of the
test program.
For more details on the information recorded by the IMAGE
datalogger in .stdf files, see “Standard Test Data Format” on
page 24-1 and/or the Standard Test Data Format (STDF)
Specification, Version 4.
tl_set_rtst_cod
Set the retest code for the current lot.
SYNOPSIS int tl_set_rtst_cod(c)
char c;
DESCRIPTION This function sets the retest code for the current lot. The retest
code is a single-character field sent to the datalogger which
records whether the lot is a retest of a previous lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the retest code for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS c—Character containing retest code
tl_set_sblot_id
Set sublot ID for the current lot.
SYNOPSIS int tl_set_sblot_id(s)
char *s;
DESCRIPTION This function sets the sublot ID for the current lot. The sublot ID
is a string sent to the datalogger which is used (in addition to the
lot ID) to identify the lot being tested.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the sublot ID for the current
lot, you must call this function before execution of the first
sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
tl_set_serl_num
Set the tester serial number for the current lot.
SYNOPSIS int tl_set_serl_num(s)
char *s;
DESCRIPTION This function sets the tester serial number for the current lot. The
tester serial number (found on each Teradyne tester) is input in
a string format and sent to the datalogger to be recorded by
IMAGE in an .stdf file.
You must call this function before you do any testing or
datalogging for the lot. In other words, in order to set the tester
serial number for the current lot, you must call this function
before the execution of the first sequencer of the first run of the
test program.
For more details on the information recorded by the IMAGE
datalogger in .stdf files, see “Standard Test Data Format” on
page 24-1 and/or the Standard Test Data Format (STDF)
Specification, Version 4.
ARGUMENTS s—String containing tester serial number
tl_set_setup_id
Set setup ID for the current lot.
SYNOPSIS int tl_set_setup_id(s)
char *s;
DESCRIPTION Sets the test setup ID for the current lot. The test setup ID is a
string sent to the datalogger to identify the name of the testing
setup used to test the current lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the test setup ID for the
current lot, you must call this function before execution of the first
sequencer of the first run of the test program.
tl_set_spec_nam
Set test specification name for the current lot.
SYNOPSIS int tl_set_spec_nam(s);
char *s;
DESCRIPTION Sets the test specification name for the current lot being tested.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the test specification name
for the current lot, you must call this function before execution of
the first sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing test specification name
tl_set_spec_ver
Set test specification version for the current lot.
SYNOPSIS int tl_set_spec_ver(s)
char *s;
DESCRIPTION Sets the test specification version for the current lot being tested.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the test specification
version for the current lot, you must call this function before
execution of the first sequencer of the first run of the test
program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
tl_set_supr_nam
Set supervisor name for the current lot.
SYNOPSIS int tl_set_supr_nam(s)
char *s;
DESCRIPTION Sets the supervisor name for the current lot. The supervisor
name is a string sent to the datalogger to identify the person
supervising during the time the lot was tested.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the supervisor name for
the current lot, you must call this function before execution of the
first sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing supervisor name
tl_set_test_cod
Set test code for the current lot.
SYNOPSIS int tl_set_test_cod(c)
char c[3];
DESCRIPTION This function sets the test code for the current lot. The test code
is a three-character field sent to the datalogger which records the
conditions under which the lot was tested. (The
test_conditions command provides a more complete system
of test conditions. See “Declaring Test Conditions” on page
15-27 for information on the test_conditions command.)
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the test code for the current
lot, you must call this function before execution of the first
sequencer of the first run of the test program.
tl_set_test_condition
Set the test condition for a lot.
SYNOPSIS int tl_set_test_condition(tc)
int tc;
DESCRIPTION This function can only be called before executing the first
sequencer during the first run after starting a new lot.
The function sets the test condition to be used in testing the
current lot of devices. The test condition specified as a
parameter to this function must have been declared using a
test_conditions declaration. The test condition affects the test
limits used in a sequencer. For example:
tl_set_test_condition(HOT);
ARGUMENTS tc—Name of a test condition or 0 to deselect a test condition
(that is, to use default limits in sequencers).
RETURN VALUE 1 successful
0 test condition not found
tl_set_test_condition_during_lot
Set the test condition for a lot. Can be called during the lot.
SYNOPSIS int tl_set_test_condition_during_lot(int tc)
tl_set_tmode
Set program termination mode.
SYNOPSIS enum Tmode tl_set_tmode(tmode)
enum Tmode tmode;
DESCRIPTION This function allows you to set the termination mode of a test
program or to return the current termination mode. The
termination mode controls whether the program will stop
execution for failures or runtime errors or both. (See “Setting
Program Termination Modes” on page 5-24.)
ARGUMENTS tmode—one of the following constants:
TMODE_STOP_ON_FAIL
TMODE_CONT_ON_FAIL
TMODE_CONT_ON_ERROR
TMODE_SHOW (returns the current termination mode)
tl_set_tsr_test_tim
Set the Average Test Time Field in the Test Synopsis Record.
SYNOPSIS int tl_set_tsr_test_tim(int testnumber,
float test_time)
DESCRIPTION This function sets the TEST_TIM field for a specified test, which
will be written to the Test Synopsis Record (TSR) for that test in
the STDF file. Note that there is only one TSR per test, so if this
function is called multiple times for the same test, the last value
will be the one written.
ARGUMENTS int testnumber—The test number. When called from inside a
TESTF, you can use tl_read_datnum() as the first argument.
When called from outside a TESTF, call tl_read_datnum()
inside the TESTF and save the test number in a variable.
float test_time—The value you want to set as the TSR
TEST_TIM value for this test.
tl_set_tst_temp
Set the testing temperature for the current lot.
SYNOPSIS int tl_set_tst_temp(s)
char *s;
tl_set_user_power
Turn user power on and off.
SYNOPSIS int tl_set_user_power(onoff);
DESCRIPTION Set user power to the indicated value, TRUE for power on and
FALSE for power off. Returns new value of power setting.
ARGUMENTS int onoff—TRUE for power on, FALSE for power off
RETURN VALUE int new value of power setting—TRUE for power on, FALSE for
power off
tl_set_usr_desc
Set user-defined lot information string.
SYNOPSIS int tl_set_usr_desc(s)
char *s;
tl_set_wafer
Set wafer coordinates for current device.
SYNOPSIS int tl_set_wafer(x, y)
int x, y;
tl_set_wafer_id
Set wafer ID for the current wafer.
SYNOPSIS void tl_set_wafer_id(char *wafer_id)
DESCRIPTION Sets the wafer ID for the current wafer. You must call this function
before a devices is tested for the current lot. The Wafer
Information Record is constructed using the wafer ID when the
first sequencer in a new lot is entered.
ARGUMENTS char *wafer_id—The new wafer ID.
tl_set_wafer_mapping_ink_bin
Set the bin number for the ink bin.
SYNOPSIS void tl_set_wafer_mapping_ink_bin(bin_num)
unsigned short bin_num;
DESCRIPTION This function sets the ink bin variable. It assumes that you are
using the wafer mapping software and have designated certain
dice on the wafer as INK die.
ARGUMENTS unsigned short bin_num—Bin number to be used for inking
tl_set_wait
Set a retriggerable wait time.
SYNOPSIS void tl_set_wait(delay_time)
double delay_time;
tl_set_wait_timeout
Set user retriggerable wait timeout.
SYNOPSIS void tl_set_wait_timeout(timeout)
DESCRIPTION Set the timeout for the wait of the user retriggerable wait feature
(tl_set_wait()/tl_wait_wait()). tl_wait_wait()
calculates how much wait time remains and issues a run time
error if this wait time exceeds the timeout. The default timeout is
2 minutes.
ARGUMENTS double timeout—Timeout in seconds
tl_simwave_name
Set the filename for the AC wave source simulator.
SYNOPSIS void tl_simwave_name(char *format, ...)
DESCRIPTION This function sets a global variable, which will be used as the
filename for the IMAGE AC source simulator. When the test
program executes an AC source start statement, the IMAGE
simulator generates a wave file which contains one execution of
the programmed wave segment. The wave file has a default
name of the form simwave_<instr><num>.wav. The function
tl_simwave_name allows you to change the name of this output
file.
ARGUMENTS format—String for file name or printf-style format
string—If format is printf-style format string, the printf-style
arguments follows
RETURN VALUE None
SIDE EFFECTS Sets global in IMAGE AC source simulator for next file write.
Causes run time error if string pointer is not valid pointer, or if file
name will not be a valid UNIX file name, (for example, contains
nonprinting or shell-reserved characters).
tl_sinxx_amp
Calculate sin x/x corrected amplitude.
tl_site
Global variable indicating current site number.
SYNOPSIS int tl_site;
DESCRIPTION This global integer variable indicates which site is currently being
tested in a multisite test program inside a serial block. tl_site
takes on the value of each active site, one at a time. Sites are
numbered 0, 1, 2, and so on. When outside a serial block in a
multisite test program, tl_site normally has the value
TL_SITES_ALL. tl_site may also take on the value
TL_SITES_NONE. This means that the site has failed and testing
is no longer taking place on that site. In a nonmultisite test
program tl_site only takes on the values 0 and
TL_SITES_NONE.
tl_site_active
Determine if sites are still qualified.
SYNOPSIS int tl_site_active();
tl_site_shutdown
Call user function when site fails.
SYNOPSIS void tl_site_shutdown()
tl_smem_read_wave_sample_max
Return the wave sample size maximum.
SYNOPSIS int tl_smem_read_wave_sample_max()
tl_smem_set_wave_sample_max
Set the wave sample size maximum
SYNOPSIS int tl_smem_set_wave_sample_max(new_sample_size)
int new_sample_size;
tl_sps_ammeter_connect
Set the HVA connect bit.
SYNOPSIS tl_sps_ammeter_connect(unit,connect)
int unit, connect;
tl_sps_ammeter_disable_alarm
Disable the selected SPS alarm.
SYNOPSIS tl_sps_ammeter_disable_alarm(unit, alarm)
int unit, alarm;
tl_sps_ammeter_enable_alarm
Enable the selected SPS alarm.
SYNOPSIS tl_sps_ammeter_enable_alarm(unit,alarm)
int unit, alarm;
tl_sps_ammeter_reset
Resets the HVA.
SYNOPSIS tl_sps_ammeter_reset(unit)
int unit;
tl_sps_discon_meter_input
Disconnect SPS from meter input.
SYNOPSIS tl_sps_discon_meter_input()
tl_sps_gateoff
Set the SPS gate enable bit off.
SYNOPSIS tl_sps_gateoff()
tl_sps_gateon
Set the SPS gate enable bit.
SYNOPSIS tl_sps_gateon()
tl_sps_get_amm_cal_stat
Return the HVA calibration status.
SYNOPSIS tl_sps_get_amm_cal_stat(unit)
int unit;
tl_sps_get_amm_cal_time
Return HVA calibration time.
SYNOPSIS tl_sps_get_amm_cal_time(unit)
int unit;
tl_sps_get_fvs_status
Get FVS alarm status.
SYNOPSIS int tl_sps_get_fvs_status(unit)
int unit;
tl_sps_get_hccs_status
Get HCCS alarm status.
SYNOPSIS int tl_sps_get_hccs_status(unit)
int unit;
tl_sps_get_hcvs_status
Get HCVS alarm status.
SYNOPSIS int tl_sps_get_hcvs_status(unit)
int unit;
tl_sps_get_hpvi_status
Get HPVI alarm status.
SYNOPSIS int tl_sps_get_hpvi_status(unit)
int unit;
tl_sps_get_hvs_status
Get HVS alarm status.
SYNOPSIS int tl_sps_get_hvs_status(unit)
int unit;
tl_sps_hccs_comp
Set HCCS compensation.
SYNOPSIS tl_sps_hccs_comp(unit,hilow)
int unit, hilow;
tl_sps_hccs_connect
Connect the HCCS to the DUT.
SYNOPSIS tl_sps_hccs_connect(unit)
int unit;
tl_sps_hccs_disconnect
Disconnect the HCCS from the DUT.
SYNOPSIS tl_sps_hccs_disconnect(unit)
int unit;
DESCRIPTION Disconnects the High Current Current Source from the DUT.
ARGUMENTS unit—Instrument number
tl_sps_hcvs_comp
Set HCVS compensation.
SYNOPSIS tl_sps_hcvs_comp(unit,hilow)
int unit, hilow;
tl_sps_hcvs_connect
Connect the HCVS to the DUT.
SYNOPSIS tl_sps_hcvs_connect(unit)
int unit;
tl_sps_hcvs_disconnect
Disconnect the HCVS from the DUT.
SYNOPSIS tl_sps_hcvs_disconnect(unit)
int unit;
DESCRIPTION Disconnects the High Current Voltage Source from the DUT.
ARGUMENTS unit—Instrument number
tl_sps_hpvcc_alarm_clear
Sets HPVI alarm clear bit.
SYNOPSIS tl_sps_hpvcc_alarm_clear(unit)
int unit;
tl_sps_hpvcc_connect
Connect the HPVCC to the DUT.
SYNOPSIS tl_sps_hpvcc_connect(unit)
int unit;
tl_sps_hpvcc_connect_bvcs
Optimized connect from the HPVCC to the BVCS.
SYNOPSIS tl_sps_hpvcc_connect_bvcs(unit)
int unit;
tl_sps_hpvcc_disconnect
Disconnect the HPVCC from the DUT.
SYNOPSIS tl_sps_hpvcc_disconnect(unit)
int unit;
DESCRIPTION Disconnects the High Power V/I Source from the DUT.
ARGUMENTS unit—Instrument number
tl_sps_hpvcc_gateoff
Set the HPVCC gate enable bit off.
SYNOPSIS tl_sps_hpvcc_gateoff(unit)
int unit;
DESCRIPTION Sets the High Power V/I Source gate enable bit off.
ARGUMENTS unit—Instrument number
tl_sps_hpvcc_gateon
Set the HPVCC gate enable bit on.
SYNOPSIS tl_sps_hpvcc_gateon(unit)
int unit;
DESCRIPTION Sets the High Power V/I Source gate enable bit on.
ARGUMENTS unit—Instrument number
tl_sps_hpvcc_reset
Reset the HPVI.
SYNOPSIS tl_sps_hpvcc_reset(unit)
int unit;
tl_sps_hpvi_comp
Set HPVI compensation.
SYNOPSIS tl_sps_hpvi_comp(unit,hilow)
int unit, hilow;
tl_sps_hvs_connect
Connect the HVS to the DUT.
SYNOPSIS tl_sps_hvs_connect(unit)
int unit;
tl_sps_hvs_disconnect
Disconnect the HVS from the DUT.
SYNOPSIS tl_sps_hvs_disconnect(unit)
int unit;
tl_sps_reset
Reset all Synchronized Power Subsystem instruments.
SYNOPSIS tl_sps_reset(rtype)
register int rtype;
tl_sps_set_ammeter
Set up the HVA.
SYNOPSIS tl_sps_set_ammeter(unit,himux,lomux, range)
int unit,himux,lomux,range;
tl_sps_set_hpvcc
Set the HPVCC voltage and current.
SYNOPSIS tl_sps_set_hpvcc(unit,von,voff,ion,ioff,vrng,irng)
int unit;
double von, voff, ion, ioff, vrng, irng;
DESCRIPTION Sets voltage and current on the High Power V/I Source.
ARGUMENTS unit—Instrument number
tl_sps_testfor_safety
Read the safety bit.
SYNOPSIS int tl_sps_testfor_safety()
tl_statmon_memo
Write a memo string to the station monitor window.
SYNOPSIS int tl_statmon_memo(s)
char *s;
DESCRIPTION This function writes a string to the memo field of the station
monitor window if the window is up. If the window is not currently
on the screen, the function returns a -1. Note that the memo field
tl_system
Execute system command from inside a test program.
SYNOPSIS tl_system(command)
char * command;
tl_system_timeout
Execute system command from inside a test program.
SYNOPSIS tl_system_timeout(command, timeout)
char * command;
int timeout
tl_tach_trg_ctrl
Connect the TACH trigger bus to the TSY.
SYNOPSIS tl_tach_trg_ctrl (trg, action)
int trg;
int action;
DESCRIPTION Connect the specified trigger bus in the test head to the trigger
switchyard (TSY) in the mainframe. Trigger buses are numbered
from 0 to (n-1) for internal code and from 1 to n for the TLP
syntax. So you must program trigger bus <n> in the set trigger
syntax and <n-1> in tl_tach_trg_ctrl() function.
ARGUMENTS trg—Trigger to be affected (zero based) [0..7]
tl_tba_read_timer
Use the Terabus timer to time something.
SYNOPSIS unsigned tl_tba_read_timer(v)
unsigned v;
DESCRIPTION This function reads the timer of the Terabus adapter and returns
the difference between this value and the 32 bit value passed as
a parameter. Only works on a test system; always returns zero
on the simulator.
An example which times execution of some code would be:
unsigned tl;
extern unsigned tl_tba_read_timer();
tl = tl_tba_read_timer(0);
.
. /*code to time goes here*/
.
fprintf(stderr,"Elasped time in microseconds: %u\n",
tl_tba_read_timer(t1));
ARGUMENTS v—Number to subtract from reading to give difference in time.
tl_tbase_addr
Get pointer to word of Terabus space.
SYNOPSIS tl_tbase_addr(addr)
int addr;
tl_tdef_remaining
Get number of test statements left.
SYNOPSIS int tl_tdef_remaining()
DESCRIPTION Gets number of test statements remaining for the current TESTF
function (for compound seq line). Must be called from within a
test function (TESTF). Causes a run time error otherwise.
ARGUMENTS None
RETURN VALUE Number of test statements remaining, or negative number on
error.
SIDE EFFECTS Calls tl_error() when called from outside a TESTF function
and returns -1.
tl_testfor_safety
Determine if tester safety signal is asserted.
SYNOPSIS tl_testfor_safety();
DESCRIPTION This function checks if the safety signal is asserted in the tester.
Operation without it represents an unsafe condition where an
operator could be exposed to dangerous voltages at the test
head.
ARGUMENTS None
RETURN VALUE 1 safety on
0 safety not asserted
tl_tj306_delta_drives_wave
Set delta bus to drive AABUS II wave bus.
SYNOPSIS tl_tj306_delta_drives_wave(value)
int value;
SIDE EFFECTS Possibly changes relay state and programs Terabus settle timer.
tl_tj306_wave_drives_delta
Set AABUS II wave bus to drive the delta bus.
SYNOPSIS tl_tj306_aabus2_delta(value)
int value;
SIDE EFFECTS Possibly changes relay state and programs Terabus settle timer.
tl_tja_calc_avg_clock
Calculate clock period based on event list.
SYNOPSIS double tl_tja_calc_avg_clock(stamp_array,
stamp_array_size, expected_period)
double stamp_array[];
int stamp_array_size;
double expected_period;
DESCRIPTION Calculate the average clock period based on events in the list. It
is assumed that the captured events are synchronized to an
underlying clock signal. This function returns the period of that
underlying clock signal.
The events in the list may not be periodic. For example, even if
the input signal to the capture instrument is periodic, the period
may be such that the instrument capture teeters between
capturing every second and every third event. Another example
is a data signal which, while synchronized to an underlying clock,
is not periodic itself.
Because the events in the list may not be periodic, Texp (the
expected period of the underlying clock) is used to fill in the
blanks in the event list. It is assumed that captured events are
separated from the underlying clock tick by no more than one
half the expected period of the underlying clock.
ARGUMENTS stamp_array—The list of time stamps for which to calculate the
underlying clock period. [ptr to an array of doubles]
stamp_array_size—The number of elements in the list. [0, 1,
2...]
expected_period—Specifies the expected period of the
underlying clock in seconds. This value is required in order to
analyze 1) events that occur too close together for the TJA to
capture every event, and 2) events that are not periodic. [The
period in seconds.]
RETURN VALUE The calculated period of the underlying clock. [The period in
seconds]
tl_tja_calc_deviations
Calculate event deviations from underlying clock.
SYNOPSIS int tl_tja_calc_deviations(deviation_array,
stamp_array, num_events, clock_period)
double deviation_array[];
double stamp_array[];
int num_events;
double clock_period;
DESCRIPTION Calculate the list of deviations between events in a list and the
underlying clock. Events are assumed to occur synchronous to
an underlying clock. This function calculates how much each
event deviates from that underlying clock. A negative deviation
means the event occurred early, and a positive deviation means
the event occurred late.
An event may not be captured for every tick of the clock.
Therefore, it is assumed that captured events are separated
from the underlying clock tick by no more than one half the period
of the underlying clock.
ARGUMENTS deviation_array—The destination to return the deviations. [ptr
to an array of doubles large enough to hold the number of
deviations to be calculated]
stamp_array—The list of time stamps from which to calculate
the deviations. [ptr to an array of doubles]
num_events—The number of deviations to calculate. [0 to the
number of time stamps in the event list]
clock_period—The period of the underlying clock in seconds.
[The period in seconds]
RETURN VALUE The number of calculated deviations.
tl_tja_calc_intervals
Calculate the event intervals between the 2 lists.
SYNOPSIS int tl_tja_calc_intervals(num_intervals,
interval_array, from_array, to_array)
int num_intervals;
double interval_array[];
double from_array[];
double to_array[];
tl_tja_calc_max
Calculate the maximum of the list of numbers.
SYNOPSIS double tl_tja_calc_max(list, list_size)
double list[];
int list_size;
tl_tja_calc_mean
Calculate the mean of the list of numbers.
SYNOPSIS double tl_tja_calc_mean(list, list_size)
double list[];
int list_size;
DESCRIPTION Calculate the mean of the list of double precision floating point
numbers.
ARGUMENTS list—The list of double precision floating point numbers for
which to calculate the mean. [ptr to an array of doubles]
list_size—The number of elements in the list [0, 1, 2...]
tl_tja_calc_min
Calculate the minimum of the list of numbers.
SYNOPSIS double tl_tja_calc_min(list, list_size)
double list[];
int list_size;
tl_tja_calc_periods
Calculate the periods between event pairs.
SYNOPSIS int tl_tja_calc_periods (num_periods, period_array,
stamp_array)
int num_periods;
double period_array[];
double stamp_array[];
DESCRIPTION Calculate the period between each pair of time stamps in the
stamp_array. The results are returned in the period_array.
Each period is the difference defined as period[i] = event[i+1] -
event[i]. Note that to calculate N periods, there must be at least
N+1 events in the stamp_array.
ARGUMENTS num_periods—The number of periods to calculate (0 to one less
than the number of time stamps in the event list)
period_array—The destination to return the periods (pointer to
an array of doubles large enough to hold the number of periods
to be calculated)
stamp_array—The list of time stamps from which to calculate
the periods (pointer to an array of doubles)
RETURN VALUE The number of periods calculated (0 to the number of time
stamps in each of the from and to lists)
tl_tja_calc_pkpk
Calculate the peak to peak of the list of numbers.
DESCRIPTION Calculate the peak to peak value of the list of double precision
floating point numbers. The peak to peak value is the difference
between the maximum and the minimum values.
ARGUMENTS list—The list of double precision floating point numbers for
which to calculate the peak to peak value (pointer to an array of
doubles)
list_size—The number of elements in the list [0, 1, 2...]
RETURN VALUE The peak to peak value of the list of numbers (a double)
tl_tja_calc_std_dev
Calculate the standard deviation of the numbers.
SYNOPSIS double tl_tja_calc_std_dev(list, list_size)
double list[];
int list_size;
tl_tja_move_raw_data_to_darray
Moves the uncalibrated data into a DARRAY without the use of compute blocks.
SYNOPSIS void tl_tja_move_raw_data_to_darray(raw_data)
DARRAY raw_data;
DESCRIPTION This routine does the error checking and moving for a TJA
measurement without using compute blocks and the move
tl_tja_num_stamps_captured
Return number of stamps captured.
SYNOPSIS tl_tja_num_stamps_captured(raw_data, stamper)
DARRAY raw_data;
int stamper;
NOTE
Call this function only from within a compute block.
tl_tja_read_duty_cycle
Compute the duty cycle from a DARRAY.
SYNOPSIS double tl_tja_read_duty_cycle(raw_data)
DARRAY raw_data;
DESCRIPTION Given a DARRAY, this function returns the average duty cycle
value. Use this function only in duty cycle measurements.
ARGUMENTS DARRAY raw_data—DARRAY handle
tl_tja_read_duty_cycle_array
Compute the array of duty cycles from a DARRAY.
DESCRIPTION Given a DARRAY, this function calculates the duty cycles from
the data in the DARRAY. This duty cycles are placed in an array.
Use this function only with duty cycle measurements.
ARGUMENTS DARRAY raw_data—DARRAY handle
double array[]—Array that contains the values
int array_size—Size of the array
tl_tja_read_event_count
Read event_count value from DARRAY.
SYNOPSIS tl_tja_read_event_count(raw_data)
DARRAY raw_data;
DESCRIPTION Given a DARRAY, this function returns the event count value.
This is equal to the number of timestamps that were captured in
stamper A while a gate_input signal was high or low.
NOTE
Call this function only from within a compute block.
tl_tja_read_frequency
Read frequency val from DARRAY.
SYNOPSIS double tl_tja_read_frequency(raw_data)
DARRAY raw_data;
DESCRIPTION Given a DARRAY, this function returns the frequency value. This
is calculated from the following formulas:
Note that “# samples” equals the number of timestamps actually
taken, while “# events” is the number of periods used to calculate
the frequency.
holdoff counter automatically set to max value (255 = 0xFF
# events = (1 million)/(accuracy)
# samples = [(# events) / (256)] + 1 and rounded up to the next
whole #
frequency = (# events) / (total_test_time)
= [(# samples -1) * 256] / (last timestamp - first
timestamp)
NOTE
Call this function only from within a compute block.
tl_tja_read_period
Compute the period value from a DARRAY.
SYNOPSIS double tl_tja_read_period(raw_data)
DARRAY raw_data;
DESCRIPTION Given a DARRAY, this function returns the average period value.
Use this function only with period measurements.
ARGUMENTS DARRAY raw_data—DARRAY handle
tl_tja_read_period_array
Compute the array of periods from a DARRAY.
SYNOPSIS void tl_tja_read_period_array(raw_data, array,
array_size)
DARRAY raw_data;
double array[];
int array_size;
DESCRIPTION Given a DARRAY, this function calculates the periods from the
data in the DARRAY. This periods are placed in an array. Use this
function only with period measurements.
ARGUMENTS DARRAY raw_data—DARRAY handle
double array []—Array that contains the values
int array_size—Size of the array
tl_tja_read_pin_to_pin_delay
Compute the pin-to-pin delay from a DARRAY
SYNOPSIS double tl_tja_read_pin_to_pin_delay(raw_data)
DARRAY raw_data;
tl_tja_read_pin_to_pin_delay_array
Compute the array of pin-to-pin delays from a DARRAY.
SYNOPSIS void tl_tja_read_pin_to_pin_delay_array(raw_data,
array)
DARRAY raw_data;
double array[];
int array_size;
tl_tja_read_pulse_width
Compute the pulse width from a DARRAY.
SYNOPSIS double tl_tja_read_pulse_width(raw_data)
DARRAY raw_data;
DESCRIPTION Given a DARRAY, this function returns the average pulse width
value. Use this function only with pulse width measurements.
ARGUMENTS DARRAY raw_data—DARRAY handle
tl_tja_read_pulse_width_array
Compute the array of pulse widths from a DARRAY.
DESCRIPTION Given a DARRAY, this function calculates the pulse widths from
the data in the DARRAY. This pulse widths are placed in an array.
Use this function only with pulse width measurements.
ARGUMENTS DARRAY raw_data—DARRAY handle
double array[]—Array that contains the values
int array_size—Size of the array
tl_tja_read_ratio_count
Read ratio_count value from DARRAY.
SYNOPSIS tl_tja_read_ratio_count(raw_data)
DARRAY raw_data;
DESCRIPTION Given a DARRAY, this function returns the ratio count value. This
is the ratio of the number of timestamps captured by A to the
number of timestamps captured by B. (The B number should
equal the “count value” parameter defined in the software data
structure.)
NOTE
Call this function only from within a compute block.
tl_tja_read_rise_or_fall_time
Compute the rise-or-fall time from a DARRAY
SYNOPSIS double tl_tja_read_rise_or_fall_time(raw_data)
DARRAY raw_data;
DESCRIPTION Given a DARRAY, this function returns the average rise or fall
time value. Use this function only in rise or fall time
measurements.
ARGUMENTS DARRAY raw_data—DARRAY handle
tl_tja_read_rise_or_fall_time_array
Compute the array of rise-or-fall times from a DARRAY.
SYNOPSIS void tl_tja_read_rise_or_fall_time_array(raw_data,
array)
DARRAY raw_data;
double array[];
int array_size;
tl_tja_read_status
Return the status of last capture.
SYNOPSIS int tl_tja_read_status (meas_index)
char meas_index;
tl_tja_read_timestamps
Get the array of time stamps from a DARRAY.
SYNOPSIS void tl_tja_read_timestamps(darray_name,
stamp_array, offset, size, stamper)
DARRAY darray_name;
double *stamp_array;
int offset;
int size;
int stamper;
tl_tjd_calc_avg_clock
Calculate TJD clock period based on event list.
tl_tjd_calc_deviations
Calculate event deviations from the underlying TJD clock.
SYNOPSIS int tl_tjd_calc_deviations(deviation_list,
event_list, num_events, clock_period)
double deviation_list [];
double event_list [];
int num_events;
double clock_period;
tl_tjd_calc_intervals
Calculate the TJD event intervals between the two lists.
SYNOPSIS int tl_tjd_calc_intervals(num_intervals,
interval_list, from_list, to_list)
int num_intervals;
double interval_list [];
double from_list [];
double to_list [];
tl_tjd_calc_max
Calculate the maximum of the list of TJD numbers.
tl_tjd_calc_mean
Calculate the mean of the list of TJD numbers.
SYNOPSIS double tl_tjd_calc_mean(list, list_size)
double list [];
int list_size;
tl_tjd_calc_min
Calculate the minimum of the list of TJD numbers.
SYNOPSIS double tl_tjd_calc_min(list, list_size)
double list [];
int list_size;
tl_tjd_calc_periods
Calculate the periods between TJD event pairs.
SYNOPSIS int tl_tjd_calc_periods(num_periods, period_list,
event_list)
int num_periods;
double period_list [];
double event_list [];
tl_tjd_calc_pkpk
Calculate the peak-to-peak of the list of TJD numbers.
SYNOPSIS double tl_tjd_calc_pkpk(list, list_size)
double list [];
int list_size;
tl_tjd_calc_std_dev
Calculate the standard deviation of the TJD numbers.
SYNOPSIS double tl_tjd_calc_std_dev(list, list_size)
double list [];
int list_size;
tl_tms_cal_has_run
Status indicating whether TMS calibration ran.
SYNOPSIS unsigned tl_tms_cal_has_run()
tl_tms_cal_set_interval
Set the Time Measurement Subsystem calibration interval.
SYNOPSIS tl_tms_cal_set_interval(interval)
time_t interval;
DESCRIPTION This function allows you to set the TMS autocalibration time
interval from a test program. The parameter is the time interval.
ARGUMENTS interval—Time interval in seconds
SIDE EFFECTS Affects the time between required calibration. If set longer that
the default, this can allow the test system specifications to drift
outside expected limits.
tl_tsy_cpu_trg_clr
Clears the specified TSY trigger latches.
SYNOPSIS tl_tsy_cpu_trg_clr(mask)
unsigned mask;
DESCRIPTION Clears all TSY trigger latches specified by mask, where any
trigger is connected to the CPU wait function.
ARGUMENTS mask—(unsigned) The bits in mask correspond to trigger latches:
bit 0 (0x01) corresponds to trigger latch 1 for trigger line 1. Bit 7
(0x80) corresponds to trigger latch 8 for trigger line 8. A one in
the mask clears the corresponding trigger latch. A zero leaves
the corresponding trigger latch unchanged.
RETURN VALUE None
tl_tsy_trg_ctrl
Connect the mainframe trigger bus to test head.
SYNOPSIS tl_tsy_trg_ctrl(trg, src, head, tsy_bp, global)
int trg;
int src;
int head;
int tsy_bp;
int global;
DESCRIPTION Connect the specified trigger bus in the mainframe to the to the
test head (TACH). Enable this connection and calm the other two
connections (TSY backplane and TSY Global Bus).
Trigger buses are numbered from 0 to (n-1) for internal code and
from 1 to n for the TLP syntax. So you must program trigger bus
<n> in the set trigger syntax and <n-1> in
tl_tach_trg_ctrl() function.
tl_turbo_apply_downconverter_compensation
Applies Turbo AC downconverter calibration compensations to signal spectrum
SYNOPSIS void tl_turbo_apply_downconverter_compensation(pin,
h_in, down_conv_freq, down_conv_if_freq,
down_conv_attenuator)
int pin;
DARRAY h_in;
double down_conv_freq;
double down_conv_if_freq;
int down_conv_attenuator;
tl_turbo_apply_downconverter_compensation_full
Applies full Turbo AC downconverter calibration compensations to signal spectrum
SYNOPSIS void tl_turbo_apply_downconverter_compensation_full
(pin, h_in, down_conv_freq, down_conv_if_freq,
down_conv_attenuator, fs)
int pin;
DARRAY h_in;
double down_conv_freq;
double down_conv_if_freq;
int down_conv_attenuator;
double fs;
tl_turbo_disable_dut_connects
Disable connections to the DUT.
SYNOPSIS void tl_turbo_disable_dut_connects()
tl_turbo_disable_linearity_corrections
Disable linearity corrrection.
SYNOPSIS void tl_turbo_disable_linearity_corrections(pin)
int pin;
DESCRIPTION Disables the Turbo AC linearity corrections for the specified pin.
tl_turbo_enable_dut_connects
Enable connections to the DUT.
SYNOPSIS void tl_turbo_enable_dut_connects()
tl_turbo_enable_linearity_corrections
Enable linearity corrrections.
SYNOPSIS void tl_turbo_enable_linearity_corrections(pin)int
pin;
DESCRIPTION Enables the Turbo AC linearity corrections for the specified pin.
ARGUMENTS pin—pinmap identifier
RETURN VALUE None
SIDE EFFECTS This function will trigger the re-calibration of both the PACS and
the Turbo AC instrument if the pin specified refers to a Turbo AC
capture channel and the Turbo AC has not been calibrated since
one of the following:
a) the job was loaded
b) the tester was re-initialized
c) mainframe loopback mode was used (checker only)
tl_turbo_get_1knotch_compensation
Report attenuation through 1k notch for a given frequency.
SYNOPSIS double tl_turbo_get_1knotch_compensation(pin,
frequency)
int pin;
double frequency;
DESCRIPTION Report the compensation for the attenuation through the 1kHz
notch for a given frequency. The compensation includes the
attenuation due to the notch filter and the roughly 30dB fixed
gain which follows the notch. As a result the compensation will
always be much smaller than 1.0. In order to apply the
compensation, it should be multiplied by the measured voltage
amplitude of a signal component at a particular frequency.
ARGUMENTS pin—Identifies the specific Turbo AC capture channel. A pin of
-1 means to use the global tl_achan.
frequency—The frequency for which to report the
compensation_factor.
RETURN VALUE compensation_factor
tl_turbo_get_downconverter_compensation
Retrieves Turbo AC downconverter calibration compensation for specific frequencies.
SYNOPSIS double tl_turbo_get_downconverter_compensation(pin,
rf_freq, if_freq, down_conv_attenuator)
int pin;
double rf_freq;
double if_freq;
int down_conv_attenuator;
rf_freq—RF frequency
if_freq—IF frequency
tl_turbo_measure_src_vrms
Measure Vrms amplitude of source channel.
SYNOPSIS double tl_turbo_measure_src_vrms(pin)
int pin;
tl_turbo_set_cw_cal_amp_tolerance
Set amplitude tolerance of CW level calibration.
SYNOPSIS void tl_turbo_set_cw_cal_amp_tolerance(pin,
new_tolerance)
int pin;
double new_tolerance;
tl_turbo_set_cw_cal_freq_tolerance
Set frequency tolerance of CW level calibration
SYNOPSIS void tl_turbo_set_cw_cal_freq_tolerance(pin,
new_tolerance)
int pin;
double new_tolerance;
tl_turbosrc_lp_filter_auto_set
Set Turbo AC Source low-pass filter.
SYNOPSIS double tl_turbosrc_lp_filter_auto_set(pin, freq)
int pin;
double freq;
DESCRIPTION This function will automatically select the most appropriate low-
pass filter on the Turbo AC source channel given the frequency
of the signal being sourced. The filter with the smallest passband
will be selected such that the given frequency will still be within
the passband. If the signal frequency is less than or equal to 0.0
or if it is greater than 150MHz, then the filters will be bypassed.
ARGUMENTS pin—Any Turbo AC Source pin number
tl_turn_multi_threaded
Turns multithreading on or off or reads current mode.
SYNOPSIS int tl_turn_multi_threaded(int mode);
tl_ubvi100_set_supply_reset_state
Changes reset state of power supply selector
SYNOPSIS int tl_ubvi100_set_supply_reset_state(srcnum, read,
state)
int srcnum;
int read;
int state;
DESCRIPTION This function reads/writes the reset state of the UBVI100 power
supply selector. This allows you to control whether the UBVI100
resets to normal mode or high voltage mode. Unless the reset
state of the power supply selector is changed with this function,
it defaults to normal mode.
ARGUMENTS srcnum—Source number UBVI100 is installed as or 0 for all
read— 1 = read
0 = write
state— 1 = reset board to 60 V mode
0 = reset board to high voltage mode
RETURN VALUE 0 if error
1 if successful
SIDE EFFECTS Sets tl_ubvi100_regs
tl_uhfmm_read_freq
Return the UFHMM freq parameter setting.
SYNOPSIS double tl_uhfmm_read_freq(pin)
int pin;
tl_uhfmm_read_if_freq
Return the UHFMM if_freq parameter setting.
SYNOPSIS double tl_uhfmm_read_if_freq(pin)
int pin;
tl_uhfsrc_cal_interval
Set the UHFSRC calibration interval.
SYNOPSIS void tl_uhfsrc_cal_interval(amt)
int amt;
tl_uhfsrc_get_freq
Return the current frequency of the UHFSRC.
SYNOPSIS double tl_uhfsrc_get_freq()
tl_uhfsrc_is_lin_cal_data_valid
Print out if linearity calibration data are valid.
SYNOPSIS void tl_uhfsrc_is_lin_cal_data_valid()
int on_off;
tl_uhfsrc_level_table_valid
Returns whether the UHFSRC leveling table is valid.
SYNOPSIS int tl_uhfsrc_level_table_valid(pin_num)
int pin_num;
DESCRIPTION Returns whether the leveling table for the Microwave Source
specified by pin_num is valid.
ARGUMENTS pin_num—UWSRC pin number
tl_uhfsrc_level_table_valid_slot
Returns whether the Microwave Source leveling table is valid.
SYNOPSIS int tl_uhfsrc_level_table_valid_slot(slotnum)
int slotnum;
DESCRIPTION Returns whether the leveling table for the Microwave Source
specified by the test head slot number is valid.
ARGUMENTS slotnum—UWSRC test head slot number
tl_uhfsrc_max_freq
Return the maximum CW frequency for the selected UHFSRC.
SYNOPSIS double tl_uhfsrc_max_freq()
tl_uhfsrc_max_mod_freq
Return the maximum allowable carrier frequency for the selected Microwave Source.
SYNOPSIS double tl_uhfsrc_max_mod_freq()
tl_uhfsrc_mod_synth_freq
Inquire UHFSRC for its current synthesizer frequency setting if this UHFSRC is in
modulation mode.
SYNOPSIS double tl_uhfsrc_mod_synth_freq(uhf_unum)
tl_uhfsrc_set_table_size
Set the maximum size of table for the Microwave Source.
DESCRIPTION Sets the maximum size of look-up table (BCD and pre-level data)
for the Microwave Source.
ARGUMENTS num—Number of entries in the table
tl_uhfsrc_use_lin_cal_data
Set uhfsrc_use_lin_cal_data on or off.
SYNOPSIS void tl_uhfsrc_use_lin_cal_data(on_off)
int on_off;
DESCRIPTION Find the linearity cal correction given freq and amp_dbm
ARGUMENTS on_off—1 - use linearity cal data, 0 - not use linearity cal data
tl_update_data_collection_state
Update data structures in test program with latest data collection setup information.
SYNOPSIS int tl_update_data_collection_state(void)
DESCRIPTION This function first establishes with the dataserv process for the
given test program and sends it a command requesting the latest
data collection setup information. This information is then
retrieved and stored in local data structures in the test program
and can be accessed by the following functions:
tl_get_data_collection_streams()
tl_get_stream_criteria()
tl_get_stream_sample_rate()
tl_get_stream_sample_limit()
tl_get_stream_filename()
tl_get_stream_datalog_directory()
See the individual functions for more information.
Unless tl_update_data_collection_state() is called, the
stream information is not guaranteed to be up to date. These
functions assume that data collection is set at the beginning of a
lot and remains fairly static from that point on, or changes only
infrequently. If data collection has changed (using datalog,
datastream, or the data collection display) after this function has
been called, the state will be incorrect.
tl_user_datalog_changed
User function to take action when datalog setup has changed.
SYNOPSIS void tl_user_datalog_changed()
tl_user_eeprom_present
Determine whether EEPROM is present.
SYNOPSIS int tl_user_eeprom_present(type)
EEPROM_ENUM_TYPE type;
tl_user_endlot
User callable function for custom endlot processing.
SYNOPSIS (void) tl_user_endlot(void)
tl_user_mcfd_handler
User defined function which is called whenever a site experiences maximum consecutive
failing devices (MCFD).
SYNOPSIS void tl_user_mcfd_handler(int site, int mcfd_count)
tl_user_postautocal
Called after any instrument calibration from autocal.
SYNOPSIS void tl_user_postautocal()
DESCRIPTION This function is called from the autocal utility after any
instruments are calibrated by autocal if any instruments required
calibration.
ARGUMENTS None
RETURN VALUE None
tl_user_preautocal
Called before any instrument calibration from autocal.
SYNOPSIS void tl_user_preautocal()
DESCRIPTION This function is called from the autocal utility before any
instruments are calibrated by autocal if any instruments require
calibration.
ARGUMENTS None
RETURN VALUE None
tl_user_resetall
Call user function at end of reset all.
SYNOPSIS void tl_user_resetall()
tl_user_shutdown
Get user function when site fails.
SYNOPSIS void tl_user_shutdown()
NOTE
To re-enable the device, use set site_enable_all; as the first line in this function. If this
statement is not used, instrument statements in the function are not executed.
ARGUMENTS None
RETURN VALUE None
SEE ALSO “tl_site_shutdown”
tl_user_startup
Call user function at start of test program.
SYNOPSIS void tl_user_startup(argc, argv)
int argc;
char* argv[];
ARGUMENTS None
RETURN VALUE None
SEE ALSO “tl_user_shutdown”, “Passing Command Line Parameters to
main()” on page 5-23
tl_using_simulator
Flag indicating tester is in simulator mode.
SYNOPSIS extern int tl_using_simulator;
tl_uwmm_dump
Prints ASCII representation of UHFMM state.
tl_uwms_present
Return modulation option of the source directly behind the specified UWPORT pin (no add
path).
SYNOPSIS int tl_uwms_present(uwport_pin)
int uwport_pin;
tl_uwms_present_slot
Return modulation option of the source behind a UWPORT pin specified by UWPORT slot
number and schan number.
SYNOPSIS int tl_uwms_present_slot(uwport_slot, uwport_schan)
int uwport_slot;
int uwport_schan;
tl_uwport_caldib_find_interpolated_ENR
Find the interpolated ENR and the source match at the given schan of the UWPORT.
SYNOPSIS UWPORT_CALDIB_ENUM_FIND_RESULT
tl_uwport_caldib_find_interpolated_ENR(slot, schan,
freq, enr, gamma_cold, gamma_hot,
max_interpole_interval)
int slot;
int schan;
double freq;
double *enr;
D_COMPLEX *gamma_cold;
D_COMPLEX *gamma_hot;
double max_interpole_interval;
DESCRIPTION Looks up the ENR/gamma data of the internal noise source for
the given UWPORT slot/schan from the caldib data cache.
If the data point interval meeting the given max interval limit is
found, it returns linearly interpolated ENR and gamma data in the
ptrs provided.
If the suitable data interval is not found, the values in the ptrs are
unmodified.
The result of the data search is indicated by the return value:
UWPORT_CALDIB_FIND_NO_CACHE—Caldib cache does not exist
UWPORT_CALDIB_FIND_FAIL—Could not find the requested data
UWPORT_CALDIB_FIND_SUCCESS—Successfully found the
requested data
ARGUMENTS slot—Slot # of UWPORT
schan—Schan # of UWPORT [1-2 or 5-6]: ENR data are not
applicable to side 2 channels
freq—Requested freq point
enr—Ptr to return ENR value
gamma_cold—Ptr to return gamma cold
gamma_hot—Ptr to return gamma hot
max_interpole_interval—Max allowable interpolation
interval. if <= 0.0, the function applies the system default of
40.0MHz
RETURN VALUE One of UWPORT_CALDIB_ENUM_FIND_RESULT
tl_uwport_caldib_find_interpolated_system_NF
Find the interpolated system NF at the given UWPORT slot/schan
SYNOPSIS UWPORT_CALDIB_ENUM_FIND_RESULT
tl_uwport_caldib_find_interpolated_system_NF(slot,
schan,freq, nf_rfl, nf_lna, max_interpole_interval)
int slot;
int schan;
double freq;
double *nf_rfl;
double *nf_lna;
double max_interpole_interval;
tl_uwport_cal_s_params
Calibrate s-parameters from autocal
SYNOPSIS int tl_uwport_cal_s_params(slot)
int slot;
tl_uwport_config
Return a bit vector of UWPORT configuration information.
SYNOPSIS int tl_uwport_config(slot)
int slot;
tl_uwport_current_pin
Pin on which power de-embedding is done.
SYNOPSIS int tl_uwport_current_pin(pin);
int pin;
tl_uwport_current_pin_slot
Pin on which power de-embedding is done.
SYNOPSIS int tl_uwport_current_pin_slot(slot, schan)
int slot, schan;
tl_uwport_do_s11
Hook to replace driver s-param code (use DSP).
SYNOPSIS int tl_uwport_do_s11(source_slot, source_schan,
sample_freq, if_freq, uwrecv_sample_size,
ignore, driver_num_samples,
driver_window_samples, incident, reflect,
two_port, measure_slot, measure_schan,
transmit)
int source_slot;
int source_schan;
double sample_freq;
double if_freq;
int uwrecv_sample_size;
int ignore;
int driver_num_samples;
int driver_window_samples;
D_COMPLEX *incident;
D_COMPLEX *reflect;
int two_port;
int measure_slot;
int measure_schan;
D_COMPLEX *transmit;
tl_delay(xxx); * optional *
if (two_port) {
tl_delay(xxx); * optional *
tl_uwport_set_slot(measure_slot, measure_schan,
two_port_op);
}
incident->real = real;
incident->imag = imaginary;
reflect->real = real;
reflect->imag = imaginary;
if (two_port) {
* fft of last N samples of capture *
transmit->real = real;
transmit->imag = imaginary;
}
NOTE
This function must be used consistently for all s-parameter measurements. S-parameter
calibration relies on the same phase relationship between the incident, reflect, and
transmitted portions of the waves. Using this function for only some of the captures will not
work.
tl_uwport_do_spar_proc
Perform s-parameter processing.
SYNOPSIS int tl_uwport_do_spar_proc(sample_freq,
if_freq,number_samples, start_reflect,
start_transmit, incident, reflect, transmit,
snr_segment, noise_test_fail,data_error)
double sample_freq;
double if_freq;
int number_samples;
int start_reflect;
int start_transmit;
D_COMPLEX *incident;
D_COMPLEX *reflect;
D_COMPLEX *transmit;
int snr_segment;
int *noise_test_fail;
int *data_error;
DESCRIPTION If this function is defined in a test program (that is, it returns a 1),
the UWPORT driver’s s-parameter processing is bypassed. This
function is only called when the s-parameter hardware timer is
present and is being used for one or two port s-parameter
measurements. This function is called when the s-parameter
capture has been initiated.
This user supplied function will be provided the following inputs:
the sample frequency of the digitizer, the IF frequency of the
receiver, the number of samples in each data window (incident,
reflect and transmit), the reflect offset in the capture memory, the
transit offset in the capture memory and segment number (1,2,3)
if noise testing is requested or zero otherwise. If this is a one port
capture the transmit offset will be zero. The user supplied
function will be expected to return D_COMPLEX values for
incident, reflect and transmit. If noise testing is requested and
the user supplied noise test fails, the function must return a
TRUE value for noise_test_fail and a FALSE value
otherwise. If noise testing is not requested this value is not
tested. The user function is also expected to return TRUE for
data_error if the capture does not complete or there is a move
data failure and FALSE otherwise.
The purpose of this function is to allow the user the option of
using the DSP processor to compute the incident, reflect and
transmit values for the s-parameter measurement while not
having to be responsible for the mechanics of the capture. The
s-parameter capture will be initiated prior to this function call. It
is the user’s responsibility to move this data and perform the
appropriate processing based on whether this is a one port or
two port capture. Do not re-program or modify, via functions or
set syntax, the microwave port module within this function.
ARGUMENTS sample_freq—Sample frequency of digitizer
if_freq—IF frequency of receiver
number_samples—Number of samples in each data window
start_reflect—Reflect offset in capture memory
start_transmit—Transmit offset in capture memory
incident—Pointer to D_COMPLEX incident value
reflect—Pointer to D_COMPLEX reflect value
transmit—Pointer to D_COMPLEX transmit value
snr_segment—Segment number to perform noise testing
(1-incident, 2-reflect, 3-transmit) 0 if no testing is required.
noise_test_fail—If noise testing, TRUE for fail, FALSE for
pass
data_error—TRUE if capture or move data failure, FALSE
otherwise
tl_uwport_dump
Dump UWPORT block diagram for debugging.
SYNOPSIS void tl_uwport_dump(slot)
int slot;
tl_uwport_dump_1port
Debug s-parameter cal.
SYNOPSIS void tl_uwport_dump_1port(slot, schan)
int slot, schan;
DESCRIPTION Prints values of 1-port cal standards (open, short, load) for each
frequency in the station window. There should be multiple entries
for a frequency if there are multiple amplitudes at that frequency
or multiple pins connected to that schan calibrated at that
frequency.
If you see a column of <INVALID>, it means you did not calibrate
with that standard. If you see two columns of valid data followed
by one column of valid data, it means there is a difference
between the ways the cal standards were measured. See
tl_uwport_dump_port() for details of what the difference is.
tl_uwport_dump_closest_freq
Print closest calibrated frequency.
tl_uwport_dump_closest_freq_slot
Print closest calibrated frequency.
SYNOPSIS int tl_uwport_dump_closest_freq_slot(slot, schan,
freq)
int slot, schan;
double freq;
tl_uwport_dump_de_embed_file
Print de_embed_file.
SYNOPSIS int tl_uwport_dump_de_embed_file(pin)
int pin;
tl_uwport_dump_de_embed_file_slot
Print de_embed_file.
SYNOPSIS int tl_uwport_dump_de_embed_file_slot(slot, schan)
int slot;
int schan
DESCRIPTION Prints the de_embed_file for slot and schan in the station
window.
ARGUMENTS slot—UWPORT slot
schan—UWPORT schan
tl_uwport_dump_fixture
S-parameter debugging function.
SYNOPSIS void tl_uwport_dump_fixture(pin, index)
int pin, index;
DESCRIPTION Prints the de-embed files and their combined value to the station
window for the fixture with the specified index.
fixture 299 refers to 1-port 899; next fixture is -1
index to 1-port data --^ other pin or de-embed file
de_embed_file (299) = ("")
^--- no de-embed file selected
(default)
valid = 1
fixt (299) = {s11 = ( 0.0000 0.00) s21 = ( 1.0000 0.00)
s12 = ( 1.0000 0.00) s22 = ( 0.0000 0.00)}
^--- cascaded value of all .s2p files
Note that the fixture printed is not necessarily associated with the
passed pin. Fixture information is stored separately for each of
the four UWPORT schans, not by pin. So if multiple pins are
connected to a single UWPORT schan (DIB switching), the
fixture you see will have the index you request, but not
necessarily the correct pin number. To make sure you are
looking at the right pin, use
tl_uwport_dump_one_port(pin, <index_1port>)
ARGUMENTS pin—A UWPORT pin
index—Fixture to look at
tl_uwport_dump_fixture_slot
s-parameter debugging function.
SYNOPSIS void tl_uwport_dump_fixture_slot(slot, schan, index)
int slot, schan, index;
DESCRIPTION Prints the de-embed files and their combined value to the station
window for the “fixture” with the specified index.
fixture 299 refers to 1-port 899; next fixture is -1
index to 1-port data --^ other pin or de-embed file
de_embed_file (299) = ("")
^--- no de-embed file selected
(default)
valid = 1
fixt (299) = {s11 = ( 0.0000 0.00) s21 = ( 1.0000 0.00)
s12 = ( 1.0000 0.00) s22 = ( 0.0000 0.00)}
^--- cascaded value of all .s2p files
ARGUMENTS slot—UWPORT slot number (typically 4 or 21)
schan—UWPORT schan number (1-4)
index—Fixture to look at (0 - ???)
tl_uwport_dump_one_port
S-parameter debugging function.
SYNOPSIS void tl_uwport_dump_one_port(pin, index)
int pin, index;
Fields you are most likely to find important are flagged in the left
margin with ***.
Data for the following example was generated using this
statement after calibrating but forgetting to measure the short
standard:
imm "tl_uwport_dump_one_port_slot(21, 1, 899)"
tl_uwport_dump_one_port_slot
S-parameter debugging function.
SYNOPSIS void tl_uwport_dump_one_port_slot(slot,schan, index)
int slot, schan, index;
tl_uwport_dump_port
S-parameter debugging function.
SYNOPSIS void tl_uwport_dump_port(slot, schan)
int slot, schan;
tl_uwport_dump_s_param_timing
Debug s-parameter captures.
SYNOPSIS void tl_uwport_dump_s_param_timing(set_samp_size)
int set_samp_size;
tl_uwport_dump_two_port
2-port s-parameter debug.
SYNOPSIS void tl_uwport_dump_two_port(pin, idx)
int pin, idx;
DESCRIPTION Dumps the appropriate 2-port data struct to the station window.
2-port data describes the results of measuring the thru and
isolate calibration standards. 2-port data is usually only useful
when combined with 1-port data. As with the 1-port data, IMAGE
stores this information in an array, and any entry can be
accessed using the idx parameter.
Usually the idx parameter can be found by looking at the 2-port
indices = { 1 } section of a 1-port dump function output. To
send all of the values to a file, use:
imm "int i;for(i=0; i<300; i++)tl_uwport_dump_two_port(TX_OUT,i);
">two_port_TX_OUT.log
Lining the 2-port files up with the 1-port files can help make
everything make more sense.
2-port 1 of 31:
^---- max idx + 1
pin 0 (<NULL>), slot 21, schan 1: 1-port = 0 (10.000 MHz)
-^-
pass this index to tl_uwport_dump_one_port()
pin 0 (<NULL>), slot 21, schan 4: 1-port = 0 (10.000 MHz)
^ frequencies had better match! ---^
+--- If one of these has a pin number, both should have
pin numbers. No pin number means either slot
programming or internal cal standard data.
Note that this is not necessarily the pin you
asked for!
Cal data associated with slot 21 schan 1:
source termination = PA,
^--- VERY IMPORTANT - 1-port cal data
must exist for this termination
load termination = ADD
VERY IMPORTANT ---^ This must
describe the termination seen by
the pin attached to the pin named above.
See tl_uwport_dump_port(<slot>).
load match = (0.00, 0.00)
^--- ideally this is a small number;
it is gamma of the receive channel.
be calibrated.
For the 949-310-12 uwport:
PA --> source amp > -30 dBm
-20 dB --> source amp > -73 dBm
-64 dB --> source amp < -73 dBm
or add path used to
send signal across uwport
ADD --> "normal" termination
(terminated switch of
add path)
LNA --> lna: on
The three GAIN settings are also legal
for s-parameters, but not for power
(uwrecv) de-embedding. They probably
indicate a bug. (source not
disconnected from receive pin)
load match = < NOT COMPUTED >
^--- this is OK because raw load match is OK
xmit track = < NOT COMPUTED >
^--- this is OK because raw xmit track is OK
isolation = < NOT MEASURED (OK) >
^--- isolation cal is optional --> there
does not have to be a number here.
raw load match = < NOT MEASURED --> *** BAD *** >
^--- This is very bad. Without the
load match, cannot do 2-port
s-parameters or power de-embedding.
(Measured with THRU std attached.)
raw xmit track = (0.00, 0.00)
^--- This is bad! it will cause a CPU
floating point operand ALARM (divide by
zero) in the s-param cal math.
(Caused by using a 1-port s-param .wav
file on the simulator when 2-port
capture needed.) (Should be a
relatively large number.)
raw xmit track is needed for 2-port
measurements. (measured with thru)
thru std 14 = /u/checkers/standards/ideal_thru.s2p
^--- sample non-eeprom thru standard data.
(will not co-exist with internal data)
{ s11 = ( 0.0000 0.00) s21 = ( 1.0000 0.00)
s12 = ( 1.0000 0.00) s22 = ( 0.0000 0.00)}
^--- an ideal thru std has
s11 = s22 = (0, 0) and s21 = s12 = (1, 0).
thru std is reversed
valid = 0x6
This function was written for debugging software code. It
contains some useful information and some that is less useful.
This function provides access to all the information.
tl_uwport_dump_two_port_slot
2-port s-parameter debug.
SYNOPSIS void tl_uwport_dump_two_port_slot(slot_in, schan_in,
idx)
int slot_in, schan_in, idx;
DESCRIPTION Dumps the appropriate 2-port data struct to the station window.
See tl_uwport_dump_two_port for details.
ARGUMENTS slot_in—UWPORT slot number
schan_in—UWPORT schan number (1-8)
idx—Index of 2-port s-parameter structure
tl_uwport_free_data
Free() memory used by s-parameter cal.
SYNOPSIS void tl_uwport_free_data()
tl_uwport_get_num_chans_slot
Find number of channels for the given UWPORT.
tl_uwport_hw_version
Return UWPORT hardware version number.
SYNOPSIS int tl_uwport_hw_version(slot)
int slot;
tl_uwport_inst_slot
Slot number for connected source/measure.
SYNOPSIS int tl_uwport_inst_slot(slot, inst)
int slot, inst;
tl_uwport_invalidate_s_param_cal
Invalidate s-parameter calibration for one UWPORT.
SYNOPSIS void tl_uwport_invalidate_s_param_cal(pin)
int pin;
tl_uwport_invalidate_s_param_cal_all
Invalidate s-parameter calibration on all UWPORTs.
SYNOPSIS void tl_uwport_invalidate_s_param_cal_all()
Calling this function while current cal data is still valid causes the
next calibration to reset the calibration time.
To change the files used for de-embedding or characterizing
external cal standards, use tl_uwport_free_data.
tl_uwport_free_data also allows you to change between internal
and external standard calibration.
ARGUMENTS None
RETURN VALUE None
SIDE EFFECTS Invalidates s-parameter calibration.
SEE ALSO “tl_uwport_free_data”
tl_uwport_invalidate_s_param_cal_slot
Invalidate s-parameter calibration for one UWPORT.
SYNOPSIS void tl_uwport_invalidate_s_param_cal(slot)
int slot;
tl_uwport_lna
Report whether the UWPORT lna is on or not.
SYNOPSIS int tl_uwport_lna(pin)
int pin;
tl_uwport_noise_source_present
Noise source option present?
SYNOPSIS int tl_uwport_noise_source_present(pin)
int pin
DESCRIPTION Returns an integer indicating the noise is or is not present for the
indicated pin.
ARGUMENTS pin—UWPORT pin
tl_uwport_noise_source_present_slot
Noise source present?
SYNOPSIS int tl_uwport_noise_source_present_slot(slot, schan)
int slot;
int schan;
tl_uwport_num_user_chans
Return the number of user channels.
SYNOPSIS int tl_uwport_num_user_chans(slot)
int slot;
DESCRIPTION Return the number of user channels for the UWPORT module at
the given slot #: 4 or 8
tl_uwport_pin_to_slot_and_schan
Convert UWPORT pin to slot and schan.
SYNOPSIS int tl_uwport_pin_to_slot_and_schan(pin,slot, schan)
int pin, *slot, *schan;
DESCRIPTION Returns the slot and schan for a pin connected to a UWPORT in
the variables slot and schan. slot and schan are set to 0 in the
event of an error. NULL pointers can be passed for slot or
schan.
tl_uwport_read_match_and_measure_gain
Power de-embed data.
SYNOPSIS int tl_uwport_read_match_and_measure_gain(pin, freq,
match, gain)
int pin;
double freq;
D_COMPLEX *match;
double *gain;
DESCRIPTION Returns the test system load match and gain for the current
hardware state.
If power_de_embed:off, the load match is at the configuration
board plane and the gain is zero.
If power_de_embed:on, the load match is looking into the de-
embed files and gain represents the gain from the end of the de-
embed files to the configuration board (signal traveling from DUT
to system).
This function takes a frequency parameter so multi-tone or
modulated signals and harmonics can be calibrated.
The following parameters affect the values returned by this
function:
lna: on/off
add: on/off
source amp
de_embed_file
power_de_embed: on/off
gamma
connect
As always, the care with which s-parameter calibration is done
and with which the de-embed files were generated directly
affects the results.
The gain returned by this function is identical to the gain from
tl_uwport_read_match_and_source_gain if the fixture is
reciprocal. Match is always the same.
ARGUMENTS pin—UWPORT pin number
freq—Frequency
match—Gamma of the system (and fixture if
power_de_embed:on)
gain—Gain to config board
tl_uwport_read_match_and_measure_gain_slot
Power de-embed data.
SYNOPSIS int
tl_uwport_read_match_and_measure_gain_slot(slot,
schan, freq, match, gain)
int slot;
int schan;
double freq;
D_COMPLEX *match;
double *gain;
DESCRIPTION Returns the test system load match and gain for the current
hardware state. See tl_uwport_read_match_and_measure_gain
for details. If you used pin programming to calibrate for
s-parameters, use tl_uwport_read_match_and_measure_gain.
ARGUMENTS slot, schan—UWPORT slot and schan
freq—Frequency
match—Gamma of the system
gain—Gain to config board
tl_uwport_read_match_and_source_gain
Power de-embed data.
SYNOPSIS int tl_uwport_read_match_and_source_gain(pin, freq,
match, gain)
int pin;
double freq;
D_COMPLEX *match;
double *gain;
DESCRIPTION Returns the test system source match and gain for the current
hardware state. If power_de_embed:off, the source match is at
the config board and the gain is zero. If power_de_embed:on, the
source match is looking into the de-embed files and gain
represents the gain from the end of the de-embed files to the
config board (signal traveling from system to DUT).
This function takes a frequency parameter so multitone or
modulated signals and harmonics can be calibrated.
The following parameters affect the values returned by this
function:
lna: on/off
add: on/off
source amp
de_embed_file
power_de_embed
gamma
connect
As always, the care with which s-parameter calibration is done
and with which the de-embed files were generated directly
affects the results.
The gain returned by this function is the same as the gain from
tl_uwport_read_match_and_measure_gain if the fixture is
reciprocal. Match is always the same.
ARGUMENTS pin—UWPORT pin number
freq—Frequency
match—Gamma of the system
gain—Gain to specified cal_plane
tl_uwport_read_match_and_source_gain_slot
Power de-embed data.
SYNOPSIS int tl_uwport_read_match_and_source_gain_slot(slot,
schan, freq, match, gain)
int slot;
int schan;
double freq;
D_COMPLEX *match;
double *gain;
DESCRIPTION Returns the test system source match and gain for the current
hardware state. See tl_uwport_read_match_and_source_gain
for details. If you used pin programming to calibrate for
s-parameters, use tl_uwport_read_match_and_source_gain.
ARGUMENTS slot, schan—UWPORT slot and schan
freq—Frequency
match—Gamma of the system
gain—Gain to end of de_embed_file if power_de_embed:on
tl_uwport_read_power_de_embed
Read power_de_embed state.
SYNOPSIS int tl_uwport_read_power_de_embed(pin)
int pin;
tl_uwport_read_power_de_embed_slot
Read power_de_embed state.
tl_uwport_read_s1p
Read 2-port s-parameter file (.s1p).
SYNOPSIS int tl_uwport_read_s1p(filename, freqs, s_params,
max_num_s_params)
char *filename;
double *freqs;
D_COMPLEX *s_params;
int max_num_s_params;
DESCRIPTION Reads the named .s1p file into the arrays freqs and s_params,
up to the max_num_s_params such that freqs[i] corresponds
to s_params[i]. The actual number of s-parameters read is
returned. Only the first 255 characters on a line are significant.
ARGUMENTS filename—String such as /u/checkers/data/lna_in.s1p
freqs[LENGTH]—Double precision array of frequencies, filled in
by function
s_params[LENGTH]—D_COMPLEX array of s-parameter data in
(real, imaginary) format. Filled in by function.
max_num_s_params—Typically LENGTH of arrays.
tl_uwport_read_s2p
Read 2-port s-parameter file (.s2p).
SYNOPSIS int tl_uwport_read_s2p(filename, freqs, s11, s21,
s12, s22, max_num_s_params)
char *filename;
double freqs[];
D_COMPLEX s11[];
D_COMPLEX s12[];
D_COMPLEX s21[];
D_COMPLEX s22[];
int max_num_s_params;
DESCRIPTION Reads the named .s2p file into the arrays freqs, s11, s21, s12,
and s22 up to the max_num_s_params such that freqs[i]
corresponds to s11[i], s21[i], and so on. The actual number
of s-parameters read is returned. Note that the order of the
columns in a .s2p file is:
frequency s11 s21 s12 s22
Each of the four s-parameters takes two columns, corresponding
to “real” and “imaginary” for the RI format, magnitude and angle
(argument) for the MA format, and 20*log10(magnitude) and
angle for the DB format.
Regardless of the format of the data in the file, the values written
into the s11, s12, s21, and s22 arrays will be in (real, imaginary)
format.
Only the first 255 characters on a line are significant.
ARGUMENTS filename—String such as /u/checkers/data/lna.s2p or
hi.s2p
freqs[LENGTH]—Frequencies for each s-parameter
measurement
s11[LENGTH]—(real, imaginary) formatted D_COMPLEX value of
s11
s21[LENGTH]—(real, imaginary) formatted D_COMPLEX value of
s21
s12[LENGTH]—(real, imaginary) formatted D_COMPLEX value of
s12
s22[LENGTH]—(real, imaginary) formatted D_COMPLEX value of
s22
max_num_s_params—Typically LENGTH of arrays
tl_uwport_receiver_slot
Find slot of UWMM attached to UWPORT.
SYNOPSIS int tl_uwport_receiver_slot(port_slot)
int port_slot;
tl_uwport_set_gain_error_limits
Power de-embed error check.
SYNOPSIS int tl_uwport_set_gain_error_limits(pin,lower,
upper)
int pin;
double lower;
double upper;
DESCRIPTION Sets the error threshold for the gain power de-embedding will
apply for a given UWPORT channel. Example:
You have a DIB with a 20 dB pad on it. By default, IMAGE will
complain because it assumes there will be less than 10 dB of
loss. Since you know the loss will always be there, you want to
make sure power de-embedding is working correctly, so you set
the new limits accordingly using:
tl_uwport_set_gain_error_limits(<pin>, -15.0, -25.0);
Leaving headroom is a good idea because loss will change from
fixture to fixture and tester to tester.
Note that these limits are on a per-schan basis. If you have two
pins on a single UWPORT channel, they will both have the same
limits.
ARGUMENTS pin—Pin number these limits are to apply to
lower—Lower limit
upper—Upper limit
tl_uwport_set_gain_error_limits_slot
Power de-embed error check
SYNOPSIS int tl_uwport_set_gain_error_limits_slot(slot,
schan,
lower, upper)
int slot;
int schan;
double lower;
double upper;
DESCRIPTION Sets the error threshold for the gain power de-embedding will
apply for a given UWPORT channel.
Example: you have a DIB with a 20 dB pad on it. By default, the
driver will complain because it assumes there will be less than
10dB of loss. Since you know the loss will always be there, you
want to make sure power de-embedding is working correctly, so
you set the new limits accordingly:
tl_uwport_set_gain_error_limits_slot(21, 1, -15.0, -25.0);
Leaving headroom is a good idea because loss will change from
fixture to fixture and tester to tester.
ARGUMENTS slot—UWPORT slot number
schan—UWPORT schan
lower—Lower limit
upper—Upper limit
tl_uwport_set_interpolation_frequency_range
Power de-embedding interpolation.
SYNOPSIS void tl_uwport_set_interpolation_frequency_range
(range)
double range;
Note that range is the maximum distance a point can be from the
two closest s-parameter cal points. If you calibrate every 20MHz,
setting range to 20E6 allows you to program any frequency
between the two.
Extrapolation beyond s-parameter cal points is not allowed as
errors get very large quickly.
ARGUMENTS range—Maximum distance a point can be from the closest s-
parameter cal points for interpolation to be allowed
RETURN VALUE None
tl_uwport_simulate_capture
Set results of s-parameter capture.
SYNOPSIS void tl_uwport_simulate_capture(pin, s11, s21)
int pin;
D_COMPLEX s11;
D_COMPLEX s21;
DESCRIPTION Replaces the results of the most recent start statement with the
passed s-parameter values.
start uwport: s_params: s11—Passed value of s21 is
ignored.
start uwport: s_params: forward—s11 and s21 are filled in
with passed values.
start uwport: s_params: reverse—s22 and s12 are filled in
with passed values.
This allows you to make actual s-parameter measurements on
hardware then use them on the simulator. This can be used for
raw device and cal standard measurements.
Note: This function is not ignored on hardware. If you do not
want this function to be used except on the simulator, use:
if (tl_using_simulator)
tl_uwport_simulate_capture(PIN, s11, s21);
A possible use of this function on hardware is averaging. Make
multiple raw captures, average them, then write the result back
into the driver with this function, then call the normal calibrated
readback function.
ARGUMENTS pin—UWPORT pin number. Must have been used in a start
uwport statement for readbacks to work correctly.
s11—Value of reflect portion of s-param measurement
s21—Value of transmit portion of s-param measurement
tl_uwport_simulate_capture_slot
Set results of s-parameter capture.
SYNOPSIS void tl_uwport_simulate_capture_slot(slot, schan,
s11, s21)
int slot, schan;
D_COMPLEX s11;
D_COMPLEX s21;
DESCRIPTION Replaces the results of the most recent start statement with the
passed s-parameter values.
start uwport: s_params: s11—passed value of s21 is
ignored.
start uwport: s_params: forward—s11 and s21 are filled in
with passed values.
start uwport: s_params: reverse—s22 and s12 are filled in
with passed values.
This allows you to make actual s-parameter measurements on
hardware then use them on the simulator. This can be used for
raw device and cal standard measurements.
Note: This function is not ignored on the hardware. If you do not
want this function to be used except on the simulator, use
if (tl_using_simulator)
tl_uwport_simulate_capture_slot
(slot, schan, s11, s21);
A possible use of this function on hardware is averaging. Make
multiple raw captures, average them, then write the result back
into the driver with this function, then call the normal calibrated
readback function.
ARGUMENTS slot—UWPORT slot number
schan—UWPORT schan number (1-4)
s11—Value of reflect portion of s-param measurement
s21—Value of transmit portion of s-param measurement
tl_uwport_source_freq_range
Maximum and minimum UWPORT source frequencies.
tl_uwport_source_freq_range_slot
Maximum and minimum UWPORT source frequencies
SYNOPSIS int tl_uwport_source_freq_range_slot(slot, schan,
max, min)
int slot;
int schan;
double *max;
double *min;
tl_uwport_s_param_sample_size
Read back s-parameter capture size.
SYNOPSIS int tl_uwport_s_param_sample_size()
tl_uwport_s_param_snr_test_enable
S-param capture quality testing.
SYNOPSIS int tl_uwport_s_param_snr_test_enable(enable)
int enable;
tl_uwport_sparam_timer
S-param hardware timer supported?
SYNOPSIS int tl_uwport_sparam_timer(pin)
int pin
DESCRIPTION Determines whether the LA310 controller for the port module has
the s-parameter hardware timer feature as well as detecting
whether the Trigger Switchyard is present.
ARGUMENTS pin—Pin number connected to the port module
RETURN VALUE TRUE—If LA310 controller has s-parameter timer and TSY is
present
FALSE—If either of the above conditions are false
SEE ALSO “tl_uwport_sparam_timer_slot”
tl_uwport_sparam_timer_slot
Hardware s-parameter timing supported?
SYNOPSIS int tl_uwport_sparam_timer_slot(slot)
int slot
DESCRIPTION Determines whether the LA310 controller for the port module has
the s-parameter hardware timer feature as well as detecting
whether the Trigger Switchyard is present.
ARGUMENTS slot—Slot number of the port module
RETURN VALUE TRUE—If LA310 controller has s-parameter timer and TSY is
present
FALSE—If either of the above conditions are false
tl_uwport_thinfo
Return UWPORT info structure.
SYNOPSIS THINFO tl_uwport_thinfo(slot)
int slot;
DESCRIPTION This function packets the data that are displayed in setupdisp.
ARGUMENTS slot—UWPORT slot number
tl_uwport_user_cal_std_func
Demand calibration function for user.
SYNOPSIS char *tl_uwport_user_cal_std_func(pin_num, slot_num,
schan_num, cal_std, pin_num2, slot_num2,
schan_num2)
int pin_num, slot_num, schan_num;
enum tl_uwport_cal_std_type cal_std;
int pin_num2, slot_num2, schan_num2;
result = TL_UWPORT_CAL_OK;
break;
}
case TL_UWPORT_CAL_END: {
* put dib switches back where they belong *
* be sure to handle both ports if this is a 2-port *
printf("S-parameter calibration done.\n");
result = TL_UWPORT_CAL_OK;
}
case TL_UWPORT_CAL_OPEN: {
* attach open standard *
printf("OPEN standard attached.\n");
result = "open_std_00123.s1p";
* If want to assume standards are ideal,
set results to TL_UWPORT_CAL_OK *
* If something is wrong, return
TL_UWPORT_CAL_ERROR to make calibration fail *
}
.
. * rest of standards are the same *
.
default: {
...
result = TL_UWPORT_CAL_DEFAULT;
}
}
return result;
}
ARGUMENTS pin_num—Pin on a UWPORT which needs to be calibrated or
about which information is being requested If pin_num = 0, use
slot_num instead.
tl_uwport_write_s1p
Write one-port s-parameter file (.s1p).
SYNOPSIS int tl_uwport_write_s1p(filename, freqs, s_params,
num_spars, pin)
char *filename;
double *freqs;
D_COMPLEX *s_params;
int num_spars;
int pin;
tl_uwport_write_s1p_fmt
Write one-port s-parameter file (.s1p).
SYNOPSIS int tl_uwport_write_s1p_fmt(filename, freqs,
s_params, num_s_params, pin, data_fmt,
freq_unit)
char *filename;
double *freqs;
D_COMPLEX *s_params;
int num_s_params;
int pin;
char *data_fmt;
char *freq_unit;
tl_uwport_write_s2p
Write 2-port s-parameter file (.s2p).
SYNOPSIS int tl_uwport_write_s2p(filename, freqs, s11, s21,
s12, s22, num_s_params, pin1, pin2)
char *filename;
double freqs[];
D_COMPLEX s11[];
D_COMPLEX s21[];
D_COMPLEX s12[];
D_COMPLEX s22[];
int num_s_params;
int pin1;
int pin2;
tl_uwport_write_s2p_fmt
Write 2-port s-parameter file (.s2p).
SYNOPSIS int tl_uwport_write_s2p_fmt(filename, freqs, s11,
s21, s12, s22, num_s_params, pin1, pin2,
data_fmt, freq_unit)
char *filename;
double freqs[];
D_COMPLEX s11[];
D_COMPLEX s21[];
D_COMPLEX s12[];
D_COMPLEX s22[];
int num_s_params;
int pin1;
int pin2;
char *data_fmt;
char *freq_unit;
tl_uwrecv_ap_read_uncal_amp
User’s Array Processor based code for UWRECV reads.
SYNOPSIS int tl_uwrecv_ap_read_uncal_amp(slot, schan,
freq_of_interest, mm_freq, f_if, fs,
sample_size, uncal_amp, rfp, vrng);
int slot;
int schan;
double freq_of_interest;
double mm_freq;
double f_if;
double fs;
int sample_size;
double *uncal_amp;
int rfp;
double vrng;
tl_uwrecv_characterize_phase_noise_PSD
Get the complete characterization of the phase noise power spectral density.
SYNOPSIS int tl_uwrecv_characterize_phase_noise_PSD(pin,
freq_array, psd_array, num_avg)
RETURN VALUE -1 : for any errors or the number of valid data points in
freq_array[]/psd_array[]
tl_uwrecv_czt
Evaluate and return all DFT samples using CZT.
SYNOPSIS int tl_uwrecv_czt(t_samples, f_samples, size,
perm_buffer)
float *t_samples, *f_samples;
int size;
int perm_buffer;
NOTE
This function does not provide the full capability of Chirp-Z Xform which allows evaluation
of Z-Xform on equally spaced points on a spiral contour starting at an arbitrary point with an
arbitrary sampling interval on the Z-plane.
tl_uwrecv_get_PSD_use_AP
Return the current state of “use Array Processor” flag.
SYNOPSIS int tl_uwrecv_get_PSD_use_AP()
DESCRIPTION Returns the current state of “use Array Processor Flag.” The
meaning of the return values are:
0—Disable
1—Use radix 2 FFT
2—Perform DFT
tl_uwrecv_phase_noise_signal_check
Enable or disable checks on the input signal to the phase noise analyzer.
SYNOPSIS int tl_uwrecv_phase_noise_signal_check(flag)
int flag;
tl_uwrecv_read_ampval
Return amp parameter setting.
SYNOPSIS double tl_uwrecv_read_ampval(pin)
int pin;
RETURN VALUE amp (in whatever unit is currently being used) to which
UWRECV is programmed
tl_uwrecv_read_ampval_slot
Return amp parameter setting.
SYNOPSIS double tl_uwrecv_read_ampval_slot(slot)
int slot;
RETURN VALUE amp (in whatever unit is currently being used) to which
UWRECV is programmed
tl_uwrecv_read_level
Readback UWRECV “level” parameter.
SYNOPSIS int tl_uwrecv_read_level(pin)
int pin;
tl_uwrecv_read_level_slot
Readback UWRECV “level” parameter.
SYNOPSIS int tl_uwrecv_read_level(slot, schan)
int slot, schan;
tl_uwrecv_set_PSD_turbo_avg
Enable or disable the Turbo Avg feature in the PSD estimators.
SYNOPSIS int tl_uwrecv_set_PSD_turbo_avg(flag)
int flag;
DESCRIPTION Enables or disables the Turbo Averaging feature for the PSD
estimation functions. This feature enables you to effectively
double the average count specified to any of the power spectral
density estimation functions by forming overlapping segments
from the time domain data in computing the power spectral
density.
Scope of impact: general PSD functions, phase noise PSD
functions
Benefit: the measurement variance or the repeatability in the
multiple measurements is directly related to the number of
averaging performed. Consequently, this function allows you to
approximately double the repeatability performance with a given
number of time domain data.
Note that the advantage of this function is specifically in reducing
the sample size requirement rather than the test time.
Since the effectiveness of this feature somewhat depends on
individual cases, you are advised to measure and evaluate the
repeatability improvement versus the test time increase for each
case.
The default state of this feature is disabled.
ARGUMENTS 0: disable
1: HAMMING WINDOW
2: HANN WINDOW
3: Triangular Window
RETURN VALUE Current value
tl_uwrecv_set_PSD_use_AP
Enable or disable usage of the Array Processor/radix2 FFT in the PSD estimator functions.
SYNOPSIS int tl_uwrecv_set_PSD_use_AP(flag)
int flag;
Note that the differences in the freq sampling points and the
average count should not be an issue unless particular
frequency points need to be sampled exactly as in measuring the
amplitude of known discrete frequency components (that is,
spurs or harmonics). For these cases, set the total sample size
exactly as the desired radix 2 segment size times the desired
average count.
ARGUMENTS 0—DFT
1—FFT
2—CZT
tl_uwrecv_spectrum_reversed
Returns 1 if IF spectrum reversed.
SYNOPSIS int tl_uwrecv_spectrum_reversed(pin)
int pin;
tl_uwrecv_spectrum_reversed_slot
IF spectrum reversed?
SYNOPSIS int tl_uwrecv_spectrum_reversed_slot(slot, schan)
int slot, schan;
tl_uwrecv_suggest_digitizer
Find a digitizer for UWRECV.
SYNOPSIS int tl_uwrecv_suggest_digitizer(pin)
int pin;
tl_uwrecv_suggest_digitizer_slot
Find a digitizer for UWRECV.
SYNOPSIS int tl_uwrecv_suggest_digitizer_slot(slot, schan)
int slot;
int schan;
tl_uwsrc_read_amp_dbm_slot
Read back source amplitude in dBm.
SYNOPSIS int tl_uwsrc_read_freq_slot(slot, schan, amp)
int slot, schan;
double *amp;
RETURN VALUE 0 if OK
-1 if error
SIDE EFFECTS “Selects” UWSRC
SEE ALSO “tl_uwsrc_read_freq_slot”, “tl_uwsrc_read_connection_slot”
tl_uwsrc_read_connection_slot
Returns UWSRC connection state.
SYNOPSIS int tl_uwsrc_read_connection_slot(slot, schan, conn)
int slot, schan;
int *conn;
RETURN VALUE 0 = OK
-1 = error
SEE ALSO “tl_uwsrc_read_freq_slot”, “tl_uwsrc_read_amp_dbm_slot”
tl_uwsrc_read_freq_slot
Read back UWSRC freq parameter.
SYNOPSIS int tl_uwsrc_read_freq_slot(slot, schan, freq)
int slot, schan;
double *freq;
DESCRIPTION Writes the current value of the UWSRC freq parameter into the
variable freq.
ARGUMENTS slot—UWSRC or UWPORT slot number
schan—UWSRC or UWPORT schan
freq—Address double precision variable to write frequency into
RETURN VALUE 0 if OK
-1 if error
SIDE EFFECTS “Selects” UWSRC
SEE ALSO “tl_uwsrc_read_amp_dbm_slot”,
“tl_uwsrc_read_connection_slot”
tl_vhfawg_cal_interval
Set the VHFAWG calibration interval.
SYNOPSIS void tl_vhfawg_cal_interval(amt)
int amt;
tl_vhfawg_fs_sclk_cond
Prevent VHFAWG fs and SCLK race condition which occurs if fs or fs_div is programmed
on the fly when the VHFAWG is running.
SYNOPSIS void tl_vhfawg_fs_sclk_cond(bugfix_enable)
int bugfix_enable;
tl_vhfawg_get_dccal_size
Return dccal table size.
SYNOPSIS int tl_vhfawg_get_dccal_size(pin_num)
int pin_num;
DESCRIPTION Returns the dccal table size for the VHFAWG specified by
pin_num.
tl_vhfawg_get_dccal_size_slot
Return dccal table size.
SYNOPSIS int tl_vhfawg_get_dccal_size_slot(slot_num)
int slot_num;
DESCRIPTION Returns the dccal table size for the VHFAWG specified by
pin_num.
tl_vhfawg_get_level_table_size
Return leveling table size.
SYNOPSIS int tl_vhfawg_get_level_table_size(pin_num)
int pin_num;
DESCRIPTION Returns the leveling table size for the VHFAWG specified by
pin_num. A size of zero indicates an invalid table for the
specified AWG.
ARGUMENTS pin_num—Pin number of the VHFAWG.
tl_vhfawg_get_level_table_size_slot
Return leveling table size.
SYNOPSIS int tl_vhfawg_get_level_table_size_slot(slot_num)
int slot_num;
DESCRIPTION Returns the leveling table size for the VHFAWG specified by
pin_num. A size of zero indicates an invalid table for the
specified AWG.
ARGUMENTS slot_num—Test head slot number of the VHFAWG.
tl_vhfawg_get_pll_value
Read back VHFAWG phase-lock loop value.
SYNOPSIS int tl_vhfawg_get_pll_value()
NOTE
Programming the VHFAWG using the method described below is not recommended. The
fs_div syntax is obsolete. Do not use it in new test programs. Program sample rate using
the fs parameter instead.
tl_vhfawg_get_type
Return VHFAWG option type given pin number.
SYNOPSIS int tl_vhfawg_get_type(pin_num)
int pin_num;
DESCRIPTION Given a pin number, return VHFAWG option type behind that pin.
ARGUMENTS pin_num—Pin number
tl_vhfawg_get_type_slot
Return VHFAWG type given slot number.
SYNOPSIS int tl_vhfawg_get_type_slot(th_slot)
int th_slot;
DESCRIPTION Given a test head slot number, return VHFAWG option type.
ARGUMENTS th_slot—Test head slot number
tl_vhfawg_level_table_valid
Return whether the VHFAWG leveling table is valid.
SYNOPSIS int tl_vhfawg_level_table_valid(pin_num)
int pin_num;
DESCRIPTION Returns whether the leveling table for the Very High Frequency
Arbitrary Waveform Generator specified by pin_num is valid. The
leveling table is considered valid if ANY information in it is valid.
ARGUMENTS pin_num—VHFAWG pin number
tl_vhfawg_level_table_valid_slot
Return whether the VHFAWG leveling table is valid.
SYNOPSIS int tl_vhfawg_level_table_valid_slot(slotnum)
int slotnum;
DESCRIPTION Returns whether the leveling table for the Very High Frequency
Arbitrary Waveform Generator specified by the test head slot
number is valid. The leveling table is considered valid if any
information in it is valid.
ARGUMENTS slotnum—VHFAWG test head slot number
tl_vhfawg_move_event
Move event pulses within a VHFAWG segment after the segment is defined.
SYNOPSIS void tl_vhfawg_move_event(seg_var, eventnum,
old_start, old_stop, new_start, new_stop);
SEGMENT seg_var;
int eventnum, old_start, old_stop, new_start,
new_stop;
tl_vhfawg_segment_ltable_valid
Return whether a VHFAWG segment has valid leveling data.
SYNOPSIS int tl_vhfawg_segment_ltable_valid(pin_num, seg_var)
int pin_num;
SEGMENT seg_var;
tl_vhfawg_segment_ltable_valid_slot
Return whether a VHFAWG segment has valid leveling data.
SYNOPSIS int tl_vhfawg_segment_ltable_valid_slot(slot_num,
seg_var)
int slot_num;
SEGMENT seg_var;
tl_vhfawg_set_dccal_size
Set the maximum number of dccal entries in look-up table.
SYNOPSIS void tl_vhfawg_set_dccal_size(entries)
int entries;
tl_vhfawg_set_level_size
Set maximum number of prelevel entries.
SYNOPSIS void tl_vhfawg_set_level_size(entries)
int entries;
tl_vhfawg_sine_gen_debug
Set leveling sine generation debug flag.
tl_vhfawg_wave_freq
Report actual frequency.
SYNOPSIS double tl_vhfawg_wave_freq(wave_name, mclk,
tone_index)
char *wave_name;
double mclk;
int tone_index;
tl_vhfawg_wave_fs
Report actual sample rate.
SYNOPSIS double tl_vhfawg_wave_fs(wave_name)
char *wave_name;
tl_vhfawg_wave_size
Report sample size.
tl_vhfcw_cal_interval
Set the VHFCW calibration interval.
SYNOPSIS void tl_vhfcw_cal_interval(amt)
int amt;
tl_vhfcw_level_table_valid
Return whether the VHFCW leveling table is valid.
SYNOPSIS int tl_vhfcw_level_table_valid(pin_num)
int pin_num;
DESCRIPTION Returns whether the leveling table for the Very High Frequency
Continuous Waveform Source specified by pin_num is valid.
ARGUMENTS pin_num—VHFCW pin number
tl_vhfcw_level_table_valid_slot
Return whether the VHFCW leveling table is valid.
SYNOPSIS int tl_vhfcw_level_table_valid_slot(slotnum)
int slotnum;
DESCRIPTION Returns whether the leveling table for the Very High Frequency
Continuous Waveform Source specified by the test head slot
number is valid.
ARGUMENTS slotnum—VHFCW test head slot number
tl_vhfcw_set_dccal_size
Set the maximum VHFCW dccal setups.
SYNOPSIS void tl_vhfcw_set_dccal_size(num)
int num;
tl_vhfcw_set_level_max
Program the number of maximum allowable VHFCW leveling setups.
SYNOPSIS void tl_vhfcw_set_level_max(num)
int num;
tl_vmcu_busy_wait
Wait until VMCU is idle.
SYNOPSIS tl_vmcu_busy_wait(vmcu_num)
int vmcu_num;
tl_vreg_dutsrc_to_channel
Which channel am I?
SYNOPSIS int tl_vreg_dutsrc_to_channel(dutsrc_num)
DESCRIPTION Find the channel number for vreg for a given DUTSRC.
ARGUMENTS int dutsrc_num;—DUTSRC number (1-8)
tl_vreg_dutsrc_to_slot
Which slot am I in?
SYNOPSIS int tl_vreg_dutsrc_to_slot(dutsrc_num)
DESCRIPTION Find the slot number for vreg cc for a given DUTSRC.
ARGUMENTS int dutsrc_num—DUTSRC number (1-8)
tl_vreg_image_dump
Dump information about the state of the Vreg.
SYNOPSIS void tl_vreg_image_dump(dutsrc_num)
DESCRIPTION Dumps information to the station window about the state of the
Vreg for a given DUT source. This includes the slot, voltage,
mode, stored parameters, and connection state for the Vreg.
ARGUMENTS int dutsrc_num—DUTSRC number (1-8)
tl_vreg_slot_to_dutsrc
Which DUTSRC am I cabled to?
SYNOPSIS int tl_vreg_slot_to_dutsrc(vreg_slot, schan)
DESCRIPTION Find the DUTSRC number for a given slot and schan of a vreg
cc.
ARGUMENTS int vreg_slot—Slot number of vreg cc
int schan—Schan (1-4) for current channel
tl_wait
Execute a delay.
SYNOPSIS void tl_wait(ftime)
double ftime;
tl_wait_wait
Start Terabus settling delay timer.
SYNOPSIS void tl_wait_wait();
DESCRIPTION Wait for wait timer done. In case of timer hardware problems
there is a two minute timeout on the wait. If the remaining wait
period will be legitimately longer than two minutes, tl_set_wait
and tl_wait_wait are not recommended.
ARGUMENTS None
RETURN VALUE None
SEE ALSO “tl_set_wait”, “tl_set_wait_timeout”
tl_wf_cal_temp_diff
Set the calibration temperature interval.
SYNOPSIS void tl_wf_cal_temp_diff(amt)
int amt;
tl_wf_cal_time_interval
Set the calibration interval.
SYNOPSIS void tl_wf_cal_time_interval(amt)
int amt;
tl_wfcap_current_bank
Return the current memory bank number.
DESCRIPTION Returns the memory bank currently being used for capture.
ARGUMENTS int pin—The pin number for the instrument
RETURN VALUE A one-based number for the memory bank currently being used
for capture, or 0 if there was an error.
tl_wfcap_get_actual_sample_rate
Return the actual programmed sample rate for the instrument.
SYNOPSIS double tl_wfcap_get_actual_sample_rate(pin)
DESCRIPTION This function returns the actual sample rate that was
programmed. This rate is calculated by clock manager while
taking into account all frequencies in the clock setup being
loaded.
ARGUMENTS int pin—The pin number for the instrument
RETURN VALUE The sample rate, or 0.0 if it has not yet been programmed.
tl_wfcap_num_samples_captured
Get number of captured samples.
SYNOPSIS unsigned int tl_wfcap_num_samples_captured(pin)
RETURN VALUE The number of samples captured during the last capture. If
capture is in progress but has not completed, returns the number
of samples captured so far. If capture has been enabled but not
started, returns 0.
If the instrument is actively capturing IMAGE issues an error,
because the samples captured are read from two registers, and
it is likely to read back a confusing value while they are
incrementing.
There is a very small but finite chance that a test program could
start capturing from a pattern after IMAGE reads the capture
state but before getting the count from both registers. Be aware
of this potential problem if using the function while a pattern is
running.
tl_wfcap_num_samples_overranged
Get number of overranged samples.
RETURN VALUE The number of samples overranged during the last capture. If
capture is in progress but has not completed, returns the number
of samples overranged so far. If capture has been enabled but
not started, returns 0.
tl_wf_disable_80MHz_clock
Disable clocks on all WF instruments.
SYNOPSIS void tl_wf_disable_80MHz_clock
tl_wf_enable_80MHz_clock
Enable clocks on all WF instruments.
SYNOPSIS void tl_wf_enable_80MHz_clock
tl_wfsrc_get_crest_factor
Return crest factor of segment.
SYNOPSIS double tl_wfsrc_get_crest_factor(pin, pName)
int pin;
char *pName;
tl_wfsrc_get_frequency
Return frequency of segment.
SYNOPSIS double tl_wfsrc_get_frequency(pin, pName)
int pin;
char pName;
tl_wfsrc_get_last_sample_rate
Return sample rate of last started segment.
SYNOPSIS double tl_wfsrc_get_last_sample_rate(pin)
int pin;
DESCRIPTION Retrieves the sample rate of the segment that was sourced last.
ARGUMENTS pin—Pinmap identifier
tl_wfsrc_get_sample_rate
Return sample rate of segment.
SYNOPSIS double tl_wfsrc_get_sample_rate(pin, pName)
int pin;
char *pName;
tl_wfsrc_get_segment_data
Return segment data.
SYNOPSIS int *tl_wfsrc_get_segment_data(pin, pName)
int pin;
char *pName;
DESCRIPTION Retrieves segment data for the named segment. The int pointer
that is returned must be freed by the caller.
tl_wfsrc_get_segment_memory_size
Return total memory size.
SYNOPSIS int tl_wfsrc_get_segment_memory_size(pin)
int pin;
tl_wfsrc_get_segment_size
Return segment size.
SYNOPSIS int tl_wfsrc_get_segment_size(pin, pName)
int pin;
char *pName;
tl_wfsrc_show_segment_info
Print segment info.
SYNOPSIS void tl_wfsrc_show_segment_info(pin, pName)
int pin;
char *pName;
tl_write_datnum
Change the test datalog number.
DESCRIPTION Changes the datalog number of a test (the test number). This
function must be called from within a TESTF function. Otherwise,
the function return an error value (-2) and generates a runtime
error.
The new test number is first checked to see if it is within bounds
(greater than 0). If the test number is less than or equal to 0, a
runtime error is generated.
If successful, the function returns the old test number.
Possible error messages:
tl_write_datnum() illegal outside of a TESTF
tl_write_datnum() illegal test number <#>
ARGUMENTS newnum—New test number
tl_write_format
Change the test result datalog format.
SYNOPSIS int tl_write_format(newfmt)
char *newfmt;
tl_write_highlim
Change the upper limits for a test.
SYNOPSIS int tl_write_highlim(newlim)
double newlim;
DESCRIPTION Changes the upper limit for a test to the value in newlim. The
original limit is erased and all future test statements will use the
new limit.
tl_write_label
Change the test label string.
SYNOPSIS int tl_write_label(s)
char *s;
DESCRIPTION Changes the test’s label string. Should not exceed 18 characters
(not including the null at end). Subsequent output displays the
new label.
This function can be used to change the label if repeat has been
used on the sequencer line, giving each test iteration a unique
label. For example:
SEQUENCER HBINTEST()
{
seq test_val() "Dummy" $9000 repeat = 3 >5.0v <10.0v f(0);
}
TESTF test_val()
{
int i;
char buffer[1024];
for (i = 0; i < 3; i++) {
sprintf(buffer, "New test label %d", i);
tl_write_label(buffer);
test 5.8v;
}
}
The ability to generate a unique test label per test in a repeat is
the new default behavior for this function. You can defeat it by
including the following line in a .load file or a .image_behavior
file:
-behavior variable_labels_in_repeat disable
This causes the function, when used in with repeat, to modify
the label only for the first test.
ARGUMENTS s—Pointer to character string containing new test label.
tl_write_lowlim
Change the lower test limit.
SYNOPSIS int tl_write_lowlim(newlim)
double newlim;
DESCRIPTION Changes the lower limit for a test to the value in newlim. The
original limit is erased and all future test statements will use the
new limit.
ARGUMENTS newlim—Double variable containing the new low limit.
tl_write_user_eeprom_all_data
Write all data to HUC ID PROM.
SYNOPSIS int tl_write_user_eeprom_all_data(which, buf)
EEPROM_ENUM_TYPE which;
unsigned short *buf;
CONFIGA—Configuration Board A
CONFIGB—Configuration Board B
DIB—Device Interface Board (DIB)
TLDUT—Device Under Test (DUT)
tl_write_user_eeprom_id_data
Write coded data to HUC ID PROM.
SYNOPSIS int tl_write_user_eeprom_id_data(which, buf)
EEPROM_ENUM_TYPE which;
TER_EEPROM_ID *buf;
CONFIGA—Configuration board A
CONFIGB—Configuration board B
DIB—Device interface board (DIB)
TLDUT—Device under test (DUT)
tl_xachan
Read or write a register in the mixed-signal test head (analog).
SYNOPSIS int tl_xachan(achan, echo, reg, write, data)
char *achan;
int echo, reg, write, data;
DESCRIPTION This function is the low-level I/O function used to read or write a
register in the analog part of the mixed-signal (A500/550) test
head, given an analog channel string, such as 4A.
ARGUMENTS achan—Analog Channel string, such as 4A.
echo—Set to 1 if echo RAM, 0 for no echo
reg—Register number, 0 to 63
write—Set to 1 for write, 0 for read
data—Data when transfer is a write
tl_xath
Read or write a register in the mixed-signal test head (analog).
DESCRIPTION This function is the low-level I/O function used to read or write a
register in the analog part of the mixed-signal (A500/A550) test
head, given a slot number in the head.
ARGUMENTS slot—Test head slot number
echo—Set to 1 if echo RAM, 0 for no echo
reg—Register number, 0 to 63
write—Set to 1 for write, 0 for read
data—Data when transfer is a write
tl_xcc
Read or write a register in a mixed-signal conversion cage.
SYNOPSIS int tl_xcc(mapsel, brdsel, field, reg, write, data)
int mapsel, brdsel, field, reg, write, data;
DESCRIPTION This function is the low-level I/O function used to read or write a
register in a mixed-signal (A500/A550) conversion cage. An
address in the conversion cage is made up of the following
components: a map select, a board select, a field, and a register
number.
ARGUMENTS mapsel—The map select value from 0 to 31.
brdsel—Board select value 0 to 63
field—Field number, 0, 1, 2, or 3
reg—Register number, 0 to 31
write—Set to 1 for write, 0 for a read
data—16 bit data to write when transfer is a write
tl_xpacs
Read or write a register in a Precision AC cage.
SYNOPSIS int tl_xpacs(brdsel, field, reg, write, data)
int brdsel, field, reg, write, data;
DESCRIPTION This function is the low-level I/O function used to read or write a
register in a Precision AC Subsystem cage. An address in the
Precision AC cage is made up of the following components: a
board select, a field, and a register number.
tl_xvb
Read or write a register in a mixed-signal vector bus cage.
SYNOPSIS int tl_xvb(mapsel, brdsel, field, reg, write, data)
int mapsel, brdsel, field, reg, write, data;
DESCRIPTION This function is the low-level I/O function used to read or write a
register in a mixed-signal (A500/A550) vector bus cage. An
address in the vector bus cage is made up of the following
components: a map select, a board select, a field, and a register
number.
ARGUMENTS mapsel—The map select value from 0 to 31.
field—Field number, 0, 1, 2, or 3
reg—Register number, 0 to 31
wait_until_cdig_halt
Check for stopped Serial Bus Channel Card (SBCC) hardware.
SYNOPSIS int wait_until_cdig_halt(pinnum);
int pinnum;
DESCRIPTION This function checks the SBCC board(s) referenced by the pin
number and returns from the call when the board(s) have either:
a) finished executing the current segment, or
b) timed out in either hardware or software
If the pin is multisite, the function waits for the boards from both
sites to halt or timeout. The maximum number of sites is limited
by the maximum number of SBCC boards per test head, which
is 2.
If software timeout is enabled and the segment was started
by_cpu, the timeout period begins when the start <spec>
If the segment times out and the segment is still running, the
segment is halted, and the pattern address is set to 1 past the
end of the timed-out segment.
On the simulator, patterns never fail and never time out.
ARGUMENTS pinnum—Pin number that references card(s) to be checked
wait_until_cdig_halt_slot
Check for stopped Serial Bus Channel Card (SBCC) hardware.
SYNOPSIS int wait_until_cdig_halt_slot(slot);
int slot;
DESCRIPTION This function checks the SBCC board(s) referenced by the slot
number and returns from the call when the board has finished
executing the current segment or has timed out while trying to do
so.
If software timeout is enabled and the segment was started
by_cpu, the timeout period begins when the start <spec>
cdig:by_cpu was executed. If the segment was set up to start
by_trigger or by_event, the timeout period begins when
wait_until_cdig_halt is called.
If the segment times out and the segment is still running, the
segment is halted, and the pattern address is set to 1 past the
end of the timed-out segment.
On the simulator, patterns never fail and never time out.
ARGUMENTS slot—Slot number that references card to be checked
wait_until_h50_halt
Check if SCM is still running.
SYNOPSIS int wait_until_h50_halt()
DESCRIPTION Waits for either the pattern timeout to expire (if timeout is
enabled) or for the pattern to halt on the first sequencer. If
timeout is enabled and expires the pattern will be halted by this
function before returning.
Note that if timeout is NOT enabled, and the pattern has an
infinite loop, this function may never return.
Under simulation, timeout will never occur. The pattern will run
forever if it has an infinite loop regardless of timeout state.
If all sites have been disabled, then stop the pattern that is
running on this sequencer. Note that a sequencer in keepalive is
not considered running.
ARGUMENTS None
RETURN VALUE TL_H50_TIMEOUT if pattern was still running, timeout was
enabled and timeout expired. else TL_H50_NOREADCODE if
pattern returned no readcode. else the readcode returned by the
pattern (from 0 to 2047).
SEE ALSO wait_until_h50_halt_scm()
wait_until_h50_halt_scm
Check if SCM is still running.
SYNOPSIS int wait_until_h50_halt_scm(scm)
int scm;
DESCRIPTION Waits for either the pattern timeout to expire (if timeout is
enabled) on scm number scm, or for the pattern to halt.
If timeout is enabled and expires the pattern will be halted by this
function before returning.
Note that if timeout is NOT enabled, and the pattern has an
infinite loop, this function may never return. Under simulation,
timeout will never occur. The pattern will run forever if it has an
infinite loop regardless of timeout state.
ARGUMENTS int which_scm—TL_FIRST_SCM for scm 1
TL_SECOND_SCM for scm 2
RETURN VALUE TL_H50_TIMEOUT if pattern was still running, timeout was
enabled and timeout expired. else TL_H50_NOREADCODE if
Obsolete Functions
Obsolete functions remain in IMAGE and continue to work, provided the hardware they
control does not change. Use of obsolete functions is discouraged in new programs. New
functions are provided to replace obsolete functions for functionality that is still needed. Use
the new functions in new programs and to update programs that must work with new
hardware.
The obsolete IMAGE functions in table 26-11 are listed for reference.
Function Action
Function Action
handlerprober_bin
Send bin command to handler (obsolete).
SYNOPSIS handlerprober_bin()
handlerprober_start
Wait for handler start (obsolete).
SYNOPSIS handlerprober_start()
read_apu_pin
Read results APU local meter measurement. Obsolete; replaced by
“read_apu_pin_multisite”.
SYNOPSIS double read_apu_pin(pin_number_array, result_array)
short *pin_number_array;
double *result_array;
DESCRIPTION Note: This function does not work properly on multisite programs
and exists only for legacy purposes. It is replaced by
read_apu_pin_multisite.
serial {
read_apu_pin(APU_PINS, results);
for (i = 0; i < NUMBER_OF_PINS; i++)
test results[tl_site][i];
}
For the UB APU, this function reads the results of an APU local
meter measurement which was simulated via the measure driver
and measure bus.
ARGUMENTS short *pin_number_array—Pointer to list of APU pin numbers
double *result_array—Pointer to list of APU results
tl_apu_read_pin
Read results of APU local meter measurement. Obsolete; replaced by
“read_apu_pin_multisite”.
SYNOPSIS double
tl_apu_read_pin(pin_number_array,result_array)
short *pin_number_array;
double *result_array;
test results[tl_site][i];
}
serial {
tl_apu_read_pin(APU_PINS, results);
for (i = 0; i < NUMBER_OF_PINS; i++)
test results[tl_site][i];
}
For the UB APU, this function reads the results of an APU local
meter measurement which was simulated via the measure driver
and measure bus.
ARGUMENTS pin_number_array—Pointer to list of APU pin numbers
result_array—Pointer to list of APU results
tl_apucal_subr
Calibrate all installed APU channels.
SYNOPSIS short tl_apucal_subr(output_mode)
int output_mode;
tl_hand_id
This global variable contains either the name of the handler (or prober) selected or a null
(zero-length) string. The variable is set either when the command handlerconf -connect
is executed or when the handlerprober_init function is passed the name of a peripheral (see
NOTE
The handlerconf -connect command must be given before the test program has been
run to ensure that tl_hand_id is set correctly to name given in the handlerconf -connect
command.
tl_hsds_dsim_clear
Reset simulation parameters.
SYNOPSIS void tl_hsds_dsim_clear();
tl_hsds_dsim_clutch1
Simulate clutch1.
SYNOPSIS void tl_hsds_dsim_clutch1(patname, vec_first,
vec_last, cycle_first, cycle_last)
char *patname;
int vec_first, vec_last;
int cycle_first, cycle_last;
DESCRIPTION Simulate the clutch1 for the specified range of vectors and/or
cycles.
ARGUMENTS patname—Pattern name
vec_first, vec_last—First and last vector numbers
cycle_first, cycle_last—First and last cycle numbers
tl_hsds_dsim_clutch2
Simulate clutch2.
SYNOPSIS void tl_hsds_dsim_clutch2(patname, vec_first,
vec_last, cycle_first, cycle_last)
char *patname;
DESCRIPTION Simulate the clutch2 for the specified range of vectors and/or
cycles.
ARGUMENTS patname—Pattern name
vec_first, vec_last—First and last vector numbers
cycle_first, cycle_last—First and last cycle numbers
tl_hsds_dsim_cond1
Simulate hardware condition 1.
SYNOPSIS void tl_hsds_dsim_cond1(patname, vec_first,
vec_last, cycle_first, cycle_last)
char *patname;
int vec_first, vec_last;
int cycle_first, cycle_last;
tl_hsds_dsim_cond2
Simulate hardware condition 2.
SYNOPSIS void tl_hsds_dsim_cond2(patname, vec_first,
vec_last, cycle_first, cycle_last)
char *patname;
int vec_first, vec_last;
int cycle_first, cycle_last;
tl_hsds_dsim_cond3
Simulate hardware condition 3.
SYNOPSIS void tl_hsds_dsim_cond3(patname, vec_first,
vec_last, cycle_first, cycle_last)
char *patname;
int vec_first, vec_last;
int cycle_first, cycle_last;
tl_hsds_dsim_cycles_per_pass
Set cycles per pass.
SYNOPSIS void tl_hsds_dsim_cycles_per_pass
int ct;
DESCRIPTION Sets the number of cycles executed per pass through the pattern
simulator.
ARGUMENTS ct—Cycles per pass
tl_hsds_dsim_fail
Simulate failing results.
SYNOPSIS void tl_hsds_dsim_fail(patname, chan_first,
chan_last, vec_first, vec_last)
char *patname;
int chan_first, chan_last;
int vec_first, vec_last;
tl_hsds_dsim_io_timing
Simulate I/O channel operation.
SYNOPSIS void tl_hsds_dsim_io(patname)
char *patname;
tl_hsds_dsim_max_cycles
Set maximum HRAM cycle count.
SYNOPSIS void tl_hsds_dsim_max_cycles(max_ct)
int max_ct;
tl_hsds_dsim_nopatsim
Disable pattern execution simulation.
SYNOPSIS void tl_hsds_dsim_nopatsim(patname)
char *patname;
tl_hsds_dsim_pass
Simulate passing results.
SYNOPSIS void tl_hsds_dsim_pass(patname, chan_first,
chan_last, vec_first, vec_last)
char *patname;
int chan_first, chan_last;
int vec_first, vec_last;
tl_hsds_dsim_patsim
Simulate pattern execution.
SYNOPSIS void tl_hsds_dsim_patsim(patname)
char *patname;
tl_read_dib_id
Obsolete function. Read back DIB ID code.
SYNOPSIS int tl_read_dib_id()
DESCRIPTION OBSOLETE—Actually reads the DIB type, not the DIB ID, but is
maintained for backwards compatibility. Use
“tl_read_dib_type_int” instead.
ARGUMENTS None
RETURN VALUE Integer board type value from the board type field as described
in the appendix, “Test Head EEPROMs”. Returns 0 if EEPROM
can’t be read.
tl_read_hand_id
Return the value of the handler or prober ID.
SYNOPSIS char *tl_read_hand_id(s);
tl_read_prb_card
Read the DIB (or probe card) ID.
SYNOPSIS char * tl_read_prb_card(s)
char s[];
tl_set_hand_id
Set handler ID for the current lot.
SYNOPSIS int tl_set_hand_id(s)
char *s;
DESCRIPTION This function sets the handler ID for the current lot. The handler
ID is a string sent to the datalogger to record the name of the
handler used to test the lot.
You must call this function before any testing or datalogging is
done for the lot. In other words, to set the handler ID for the
current lot, you must call this function before the execution of the
first sequencer of the first run of the test program.
For details on the information recorded by the IMAGE datalogger
in STDF files, see “Generating STDF Files” on page 24-2 or the
Standard Test Data Format (STDF) Specification, Version 4.
ARGUMENTS s—String containing the handler ID
tl_set_trouble_indicator
Control station trouble indicator.
SYNOPSIS int tl_set_trouble_indicator(flag)
int flag;
DESCRIPTION This function controls the setting of the “trouble” indicator for the
station in which the test program is loaded. When the trouble
indicator is turned on, the “station status” window flashes the
appropriate station number, signalling the operator that an error
condition exists for the test station. This function has no effect if
the station status window is not running.
ARGUMENTS flag—if nonzero, indicator is turned on
if zero, indicator is turned off
RETURN VALUE None
tl_touch_pages_record_faults
Record page faults before run. This function is no longer user-callable. Use the memory
profiling feature introduced in IMAGE V5.6 instead.
SYNOPSIS int tl_touch_pages_record_faults;
int tl_touch_pages_faults;
tl_uwport_std_cal_one_port
Calibrate one port s-parameter for all frequencies and amplitudes used with a pin.
SYNOPSIS int tl_uwport_std_cal_one_port(pin, freqs, amps,
open_vals, short_vals, load_vals, num_vals,
open_filename, short_filename, load_filename);
int pin;
double freqs[], amps[];
D_COMPLEX open_vals[], short_vals[], load_vals[];
int num_vals;
char open_filename[], short_filename[],
load_filename[];
DESCRIPTION Calibrates s-parameter for a single pin. Builds the one port error
adapter for a single pin on a UWPORT at each
frequency/amplitude pair given. You write a function to gather
raw s-parameter measurements of each calibration standard on
each pin of interest, then call this function for each pin with the
corresponding cal standard data.
ARGUMENTS pin—pin name or pin number (must correspond to a UWPORT)
tl_uwport_std_cal_one_port_slot
One port s-parameter calibration for all frequencies and amplitudes used with a pin.
tl_write_device
Set the device number for the next device to be tested.
SYNOPSIS int tl_write_device;
DESCRIPTION Sets the device number for the next device to be tested. The
device number for the current device under test cannot be
changed.
ARGUMENTS None
RETURN VALUE Old number for the next device
SEE ALSO “tl_read_device”, “tl_read_part_id”
tl_write_dib_id_to_stdf
Write the DIB ID to the datalog stream.
SYNOPSIS void tl_write_dib_id_to_stdf();
tl_write_job_rev
Set the test program revision ID.
SYNOPSIS tl_write_job_rev(s)
char *s;
tl_write_lot_id
Set the lot or sublot ID.
SYNOPSIS tl_write_lot_id(s)
char *s;
tl_write_sblot_id(s)
char *s;
DESCRIPTION Sets the lot or sublot ID for the lot about to be tested. Set the lot
and sublot IDs before calling tl_begin_lot (or issuing the
startlot command) as they set up the data which will be used
for the next device lot. Example:
{
/* IN SETUP MODE: Read the bar code reader to get
the lot ID and open/start testing the new lot */
char lotid_from_reader[S_STDF_STRING+1];
get_barcode_text(lotid_from_reader);
tl_write_lot_id(lotid_from_reader);
tl_begin_lot(TRUE);
exit(); /*The next run will be the first part*/
}
ARGUMENTS The lot ID or sublot ID (text) to be assigned.
RETURN VALUE None
SEE ALSO “tl_read_lot_id”, “tl_read_sblot_id”, “tl_begin_lot”, “tl_read_ids”,
“tl_write_lot_ids”
tl_write_lot_ids
Set the lot or sublot ID in a single function call.
SYNOPSIS tl_write_lot_ids(s)
char *s;
DESCRIPTION Sets the lot or sublot ID or both for the lot which is about to be
tested in a single function call. This function scans the lot ID text
string for a “:” and if present sets both the lot and sublot IDs
accordingly. If one of the fields is “unspecified,” (that is, ":12" ==>
missing lot ID) then that field is set to NULL. If the “:” is not
present, the lot ID is set to the specified text, and the sublot ID is
unaffected. Example:
{
char lsid[[S_STDF_STRING+1];
sprintf(lsid,"Wafer:%d",wafer_number);
tl_write_lot_ids(lsid);
tl_begin_lot(TRUE);
exit();
}
ARGUMENTS A text string of the form: <lot ID>:<sublot ID> where either
item may be NULL.
RETURN VALUE None
SEE ALSO “tl_read_ids”, “tl_read_lot_id”, “tl_read_sblot_id”, “tl_begin_lot”,
“tl_write_lot_id”, “tl_write_sblot_id”
tl_write_sblot_id
See “tl_write_lot_id” on page 26-534.
tl_write_newtest
Create a new test and test number at runtime or modify the characteristics on an existing
one.
SYNOPSIS #include <limit_ops.h>
tl_write_newtest (num, label, format, loflag, lolim,
hiflag, hilim)
int num;
char *label, *format
unsigned char loflag, hiflag
double lolim, hilim;
DESCRIPTION This function is called from with a test function to change the
characteristics of that test function. Use this function sparingly.
You can accomplish most tasks requiring this capability using
variable test numbers at the sequencer level.
tl_write_wafer
Write device wafer coordinates, for wafer mapping (obsolete). You must explicitly write them
for each device if wafer mapping reporting is desired. There are no default coordinates.
(This function is obsolete. Use tl_set_wafer instead.)
SYNOPSIS tl_write_wafer(x, y);
tl_write_wavefile
Write wavefile data.
SYNOPSIS int tl_write_wavefile(fn, array, samples, rate,
gain, offset, flag)
char *fn; /* filename */
float *array; /* wave float array */
int *samples;
float *rate;
float *gain;
float *offset;
int *flag; /* 0 = fract2, 1 = real */
DESCRIPTION This function writes fract2 and real wavefile data. Any value <
0 returned by this function is an error. The user code calling this
function should check the return value for every call. You must
include the file, libapps.a, in the .load file for the test program.
ARGUMENTS fn—name of file to be read. The name must include a .wav
extension. If you do not add one, one is added automatically
array—floating point array to receive waveform data
samples—Number of samples actually read
rate—sample frequency
gain—gain for fract2 data or the maximum data point for real
data
offset—offset for fract2 data or the minimum data point for
real data
flag—0=fract2 data, 1=real data.
tl_write_wavefile_struct
Write wavefile using struct header.
SYNOPSIS int tl_write_wavefile_struct(fn, array, head, data,
databytes, param_id)
char *fn;
float *array;
struct wavefilehead *head;
char *data;
int databytes,param_id;
convert_double_to_frac
convert_double_to_frac(d_source, i_dest, size);
Parameter definitions:
double *d_source
unsigned *i_dest
int size
This function takes a pointer to an array of double precision floating point numbers and
converts each element to a fractional twos complement number. The result is placed in the
unsigned array pointed to by i_dest. You must specify the number of points to convert. Be
sure that the i_dest array is large enough to hold the results.
convert_frac_to_double
convert_frac_to_double(i_source, d_dest, size);
Parameter definitions:
unsigned *i_source
double *d_dest
int size
This function takes a pointer to an array of unsigned integers that represent fractional twos
complement numbers and converts each element to a double precision floating point
number. The result is placed in the double array pointed to by d_dest. You must specify the
number of points to convert. Be sure that the d_dest array is large enough to hold the
results.
convert_frac_to_float
convert_frac_to_float(i_source, f_dest, size);
Parameter definitions:
unsigned *i_source
float *f_dest
int size
This function takes a pointer to an array of unsigned integers that represent fractional twos
complement numbers and converts each element to a floating point number. The result is
placed in the float array pointed to by f_dest. You must specify the number of points to
convert. Be sure that the f_dest array is large enough to hold the results.
convert_float_to_frac
convert_float_to_frac(f_source, i_dest, size);
Parameter definitions:
float *f_source
unsigned *i_dest
int size
This function takes a pointer to an array of floats and converts each element to a fractional
twos complement number. The result is placed in the unsigned array pointed to by i_dest.
You must specify the number of points to convert. Be sure that the i_dest array is large
enough to hold the results.
convert_alaw_to_float
convert_alaw_to_float(i_source, f_dest, size);
Parameter definitions:
unsigned *i_source
float *f_dest
int size
This function takes a pointer to an array of unsigned integers whose rightmost eight bits
represent alaw data and converts them to floating point numbers. The result is placed in the
float array pointed to by f_dest. You must specify the number of points to convert. Be sure
that the f_dest array is large enough to hold the results.
NOTE
This function expects the input alaw data to have its even bits inverted.
convert_ulaw_to_float
convert_ulaw_to_float(i_source, f_dest, size);
Parameter definitions:
unsigned *i_source
float *f_dest
int size
This function takes a pointer to an array of unsigned integers whose rightmost bits represent
ulaw data and converts them to floating point numbers. The result is placed in the float array
pointed to by f_dest. You must specify the number of points to convert. Be sure that the
f_dest array is large enough to hold the results.
NOTE
This function expects the input ulaw data to be inverted.
convert_analog_to_alaw
convert_analog_to_alaw(f_source, i_dest, size);
Parameter definitions:
float *f_source
unsigned *i_dest
int size
This function takes a pointer to an array of ±1.0 normalized floating point numbers and
converts them to right-justified alaw codes. The result is placed in the unsigned integer array
pointed to by i_dest. You must specify the number of points to convert. Be sure that the
i_dest array is large enough to hold the results.
NOTE
This function produces alaw codes that are even bit inverted.
convert_analog_to_ulaw
convert_analog_to_ulaw(f_source, i_dest, size);
Parameter definitions:
float *f_source
unsigned *i_dest
int size
This function takes a pointer to an array of ±1.0 normalized floating point numbers and
converts them to right-justified ulaw codes. The result is placed in the unsigned integer array
pointed to by i_dest. You must specify the number of points to convert. Be sure that the
i_dest array is large enough to hold the results.
NOTE
This function produces inverted ulaw codes.
To Use
To Use
To Use
Convert vector elements from double precision floating point to single da_dpsp
precision floating point
Convert vector elements from double precision floating point to fract2 da_double_to_frac
Convert vector elements from double precision floating point to integer da_fix32d
Convert vector elements from single precision floating point to integer da_flt32d
Convert vector elements from fract2 to double precision floating point da_frac_to_double
Convert vector elements from fract2 to single precision floating point da_frac_to_real
Convert vector elements from offset binary to single precision floating da_offset_binary_to_real
point
Convert vector elements from rectangular coordinate form to polar da_polar
coordinate form
Convert vector elements from single precision floating point to fract2 da_real_to_frac
Convert vector elements from polar coordinate form to rectangular da_rect
coordinate form
Convert vector elements from single precision floating point to double da_spdp
precision floating point
Convert vector elements from single or double precision floating point da_vfix
to integer
Convert vector elements from integer to single precision floating point da_vfloat
Convert vector elements from integer to double precision floating point da_vfloatd
Convert (truncate) vector elements from single precision floating point da_vifix
numbers to integers
Extract the imaginary part from each vector element da_vimag
Extract the real part from each vector element da_vreal
To Use
To Use
To Use
To Use
To Use
Logical Operators
To Use
To Use
To Use
Matrix Operations
To Use
To Use
Find value of vector element with the maximum magnitude (absolute da_maxmgv
value)
Find value and index of the vector element with the maximum value da_maxv
Find value of vector element with the minimum magnitude (absolute da_minmgv
value)
Find value and index of the vector element with the minimum value da_minv
Calculate vector elements that are the maximum valued element at da_vmax
each index in two input vectors
Calculate vector elements that are the maximum magnitude (absolute da_vmaxmg
value) of the elements at each index in two input vectors
To Use
Calculate vector elements that are the minimum valued element at da_vmin
each index in two input vectors
Calculate vector elements that are the minimum magnitude (absolute da_vminmg
value) of the elements at each index in two input vectors
To Use
Miscellaneous
To Use
Scalar Math
To Use
To Use
To Use
Sum
To Use
Trigonometric Functions
To Use
Vector Math
To Use
Windows, Data
To Use
Data Fitting
To Use
Generate new DARRAY that fits a given slope and offset da_best_fit_ramp
Calculate amplitude, phase, and offset of a sine wave to fit da_best_fit_sine
the input
Calculate amplitude, phase, and offset of a sine wave to fit da_best_fit_sine_full
the input with control parameters
Calculate least-squares fit slope and offset to a sampled da_best_fit_slope_and_offset
period of a ramp waveform
Calculate least-squares fit slope and offset to a sampled da_best_fit_slope_and_offset_full
period of a ramp waveform with control parameters
Sampling Simulation
To Use
Generate new DARRAY that fits a given slope and offset da_best_fit_ramp
Simulate sampling of a continuous-time waveform da_cosine
Simulate sampling of a multitone cosine waveform da_multitone
Simulate sampling of a continuous periodic pulse waveform da_pulse
Simulate sampling of a continuous periodic ramp waveform da_ramp
To Use
To Use
da_3rd_order_imd
Calculate the third order intermodulation distortion of a two-tone sine wave.
This function performs a third order intermodulation calculation. The input waveform is the
sum of two sine waves of equal power and different frequencies. Input parameters include
the two frequencies of the sine waves. The sampling frequency of the waveform is taken
from the input DARRAY.
The result of this algorithm is a ratio of the power in the signal to the power in the third order
intermodulation harmonics. The signal power is the magnitude of the FFT of the input at
either frequency, Ft1 or Ft2 (since they are equal). The harmonic power is the sum of the
magnitude at four specific frequencies. These frequencies are:
2(Ft1) +/- Ft2
Ft1 +/- 2(Ft2)
Note that the power of negative frequencies equals the corresponding power at the positive
frequency for all real signals. The algorithm finds those four powers, sums them, and divides
the signal power by the result to calculate the final result.
Synopsis
double da_3rd_order_imd(DARRAY input, double Ft1, double Ft2)
Arguments
input Input variable containing the input two-tone sine wave. The
signal power of the two tones must be approximately equal.
The input data array must have a length which is a power of 2
and contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
Ft1 Frequency of the first tone. Value must be between 0 and Fs/2.
Ft2 Frequency of the second tone. Value must be between 0 and
Fs/2.
A run-time error results from choosing frequencies such that the
harmonic frequencies are undersampled. The sampling
frequency must be greater than both 2*Ft1 + Ft2 and Ft1 + 2*Ft2.
Returns
The ratio of the signal power to the harmonic power, or TL_DA_ERROR.
See Also
“da_3rd_order_imd_full”
da_3rd_order_imd_full
Calculate the third order intermodulation distortion of a two-tone sine wave, with additional
parameter sample frequency.
This function performs a third order intermodulation calculation. The input waveform is the
sum of two sine waves of equal power and different frequencies. Input parameters include
the two frequencies of the sine waves and the sample frequency of the waveform.
The result of this algorithm is a ratio of the power in the signal to the power in the third order
intermodulation harmonics. The signal power is the magnitude of the FFT of the input at
either frequency, Ft1 or Ft2 (since they are equal). The harmonic power is the sum of the
magnitude at four specific frequencies. These frequencies are:
2(Ft1) +/- Ft2
Ft1 +/- 2(Ft2)
Note that the power of negative frequencies equals the corresponding power at the positive
frequency for all real signals. The algorithm finds those four powers, sums them, and divides
the signal power by the result to calculate the final result.
Synopsis
double da_3rd_order_imd_full(DARRAY input, double Ft1, double Ft2,
double Fs)
Arguments
input Input variable containing the input two-tone sine wave. The
signal power of the two tones must be approximately equal.
The input data array must have a length which is a power of 2
and contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
Ft1 Frequency of the first tone. Value must be between 0 and Fs/2.
Ft2 Frequency of the second tone. Value must be between 0 and
Fs/2.
Fs Sample frequency. Value must be greater than both 2*Ft1 + Ft2
and Ft1 + 2*Ft2.
Returns
The ratio of the signal power to the harmonic power, or TL_DA_ERROR.
See Also
“da_3rd_order_imd”
da_aint
Vector real to whole number.
da_aint converts a vector of real numbers to a vector of whole numbers. This function
applies the integer truncation function to each element of the input data array
where
truncate(t) = n, if n ≤ t < n+1, and n is an integer.
Synopsis
DARRAY da_aint(DARRAY h_in)
Arguments
h_in The input DARRAY can have any length > 0. Data must be a
floating point type, DA_REAL or DA_DREAL.
Returns
A DARRAY handle to the data array containing the output data.
In normal operation, the output DARRAY is the same length as the input DARRAY. The output
DARRAY type is the same as the input type.
da_amplitude
Compute the amplitude at a given frequency.
The amplitude is the value of the Fourier component at the input frequency. The input
should be a spectrum. The sample rate must be in the input data array.
The amplitude can be the magnitude in a complex spectrum or the magnitude squared in a
power spectrum, depending on the data array contents.
See “Notes on Using Block Algorithms When Calculating FFTs and Spectra”.
Synopsis
double da_amplitude(DARRAY input, double f_i)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input spectrum data.
f_i The frequency of interest.
Returns
The amplitude at the given frequency. da_amplitude_full includes only those frequencies
that occur before Fs/2. However, if the sample is not band-limited to Fs/2, images of noise
and harmonics may interfere with the correct calculation of the amplitude.
See Also
“da_amplitude_full”, “da_phase”, “da_phase_full”
da_amplitude_full
Calculate amplitude at a given frequency, with additional parameter sample rate.
The amplitude is the value of the Fourier component at the input frequency. The input
should be a spectrum. The sample rate is specified using parameter f_s.
The amplitude can be the magnitude in a complex spectrum or the magnitude squared in a
power spectrum, depending on the data array contents. The elements of the array can have
any of the legal types.
Synopsis
double da_amplitude_full(DARRAY input,
double f_i,
double f_s)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input spectrum data.
f_i The frequency of interest.
f_s The sample frequency.
Returns
The amplitude at the given frequency. da_amplitude_full includes only those frequencies
that occur before Fs/2. However, if the sample is not band-limited to Fs/2, images of noise
and harmonics may interfere with the correct calculation of the amplitude.
See Also
“da_amplitude”, “da_phase”, “da_phase_full”
da_best_fit_ramp
Return a new DARRAY that fits a given slope and offset.
This function generates a DARRAY containing a ramp waveform that corresponds to the
specified slope (in volts/second) and offset (in volts). A new DARRAY is allocated, its size
specified by num_samples. The type of the new DARRAY is DA_REAL. The sample frequency
is set to Fs and the ramp waveform is filled in according to the slope and offset. The resulting
handle is returned.
Synopsis
DARRAY da_best_fit_ramp(da_size_t num_samples, double Fs, double slope,
double offset)
Arguments
num_samples The number of elements in the new DARRAY. Must be 8 or larger.
Fs Sample frequency of the new DARRAY. Value must be 8 or larger.
slope Slope of the waveform in volts/s.
offset Offset of the waveform in volts.
Returns
DARRAY with the new waveform.
Side Effects
Allocates memory.
See Also
“da_best_fit_slope_and_offset”
da_best_fit_sine
Calculate the amplitude, phase, and offset of a sine wave to fit the input.
This function calculates a least-squares fit approximation to a sampled real sine wave. You
provide the sample data in an input DARRAY and pointers to where the function returns the
amplitude, phase, and offset values. The sample and waveform frequencies are taken from
the input DARRAY.
The least-squares fit algorithm for a known frequency sine wave is given in ANSI/IEEE 1057
(Standard for Digitizing Waveform Recorders), Section 4.1.3.1 “An algorithm for Three
Parameter (Known Frequency) Least Squared Fit to Sine Wave Data.” The algorithm
returns values for the amplitude (in volts), phase angle (in radians), and DC offset (in volts)
such that the theoretical waveform described by those values matches the real sample data.
The matching criteria is that the squares of the voltage differences between the real data
and the theoretical data is minimized when summed over all of the available samples. For
a full description of the algorithm used to calculate these values, see ANSI/IEEE 1057.
Synopsis
void da_best_fit_sine(DARRAY input, double *amplitude, double *phase,
double *offset)
Arguments
input Input variable containing the input waveform.
The data array must have a length which is a power of 2 and
contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
Side Effects
Writes values A, P, and C to amplitude, phase, and offset, such that A*sin(Wx+P)+C is the
least-squares fit to the input waveform of frequency W.
See Also
“da_best_fit_sine_full”
da_best_fit_sine_full
Calculate the amplitude, phase, and offset of a sine wave to fit the input, with additional
parameters, test frequency and sample frequency.
This function calculates a least-squares fit approximation to a sampled real sine wave. You
provide the sample data in an input DARRAY and pointers to where the function returns the
amplitude, phase, and offset values. The sample and waveform frequencies are specified
as parameters.
The least-squares fit algorithm for a known frequency sine wave is given in ANSI/IEEE 1057
(Standard for Digitizing Waveform Recorders), Section 4.1.3.1 “An algorithm for Three
Parameter (Known Frequency) Least Squared Fit to Sine Wave Data.” The algorithm
returns values for the amplitude (in volts), phase angle (in radians), and DC offset (in volts)
such that the theoretical waveform described by those values matches the real sample data.
The matching criteria is that the squares of the voltage differences between the real data
and the theoretical data is minimized, when summed over all of the available samples. For
a full description of the algorithm used to calculate these values, see ANSI/IEEE 1057.
Synopsis
void da_best_fit_sine_full(DARRAY input, double *amplitude, double *phase,
double *offset, double Fs, double Ft)
Arguments
input Input variable containing the input waveform.
Side Effects
Writes values A, P, and C to amplitude, phase, and offset, such that A*sin(Wx+P)+C is the
least-squares fit to the input waveform of frequency W.
See Also
“da_best_fit_sine”
da_best_fit_slope_and_offset
Calculate the least-squares fit slope and offset to a sampled period of a ramp waveform.
This function calculates a least-squares fit approximation on a real sampled ramp waveform
to find the best theoretical slope and DC offset for the equation describing that ramp. The
slope is in volts per second and the offset in volts. You provide the sample data in an input
DARRAY and pointers to where the function returns the slope and offset values. The sample
frequency is taken from the input DARRAY.
The least-squares fit algorithm finds the equation of a line that approximates the real
waveform. This line has the property that the squares of the voltage differences between
the actual data and the theoretical data summed over every data point, is minimized. In
other words, on one sample, subtract the real data from the theoretical data, and square the
result. Do that to every sample and add up the results. The slope and offset computed by
this function describe the line that minimizes that result.
Synopsis
void da_best_fit_slope_and_offset(DARRAY input, double *slope, double *offset)
Arguments
input Input variable containing the input waveform.
The data array must have a length which is a power of 2 and
contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
*slope A pointer which represents where to write the slope data. Value
must not be zero.
*offset A pointer which represents where to write the offset data. Value
must not be zero.
Side Effects
Writes values to the pointers, slope and offset.
See Also
“da_best_fit_slope_and_offset_full”
da_best_fit_slope_and_offset_full
Calculate the least-squares fit slope and offset to a sampled period of a ramp waveform with
additional parameter sample frequency.
This function calculates a least-squares fit approximation on a real sampled ramp waveform
to find the best theoretical slope and DC offset for the equation describing that ramp. The
slope is in volts per second and the offset in volts. You provide the sample data in an input
DARRAY and pointers to where the function returns the slope and offset values. Also, you
specify the sample frequency as a parameter.
The least-squares fit algorithm finds the equation of a line that approximates the real
waveform. This line has the property that the squares of the voltage differences between
the actual data and the theoretical data, summed over every data point, is minimized. In
other words, on one sample, subtract the real data from the theoretical data and square the
result. Do that to every sample and add up the results. The slope and offset computed by
this function describe the line that minimizes that result.
Synopsis
void da_best_fit_slope_and_offset_full(DARRAY input, double *slope,
double *offset, double Fs)
Arguments
input Input variable containing the input waveform.
The data array must have a length which is a power of 2 and
contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
*slope A pointer which represents where to write the slope data. Value
must not be zero.
*offset A pointer which represents where to write the offset data. Value
must not be zero.
Fs Sample frequency. Value must be greater than 0.
Side Effects
Writes values to the pointers, slope and offset.
See Also
“da_best_fit_slope_and_offset”
da_blkman
Blackman window.
da_blkman applies the Blackman window to a vector of input data.
This function applies the Blackman windowing function to each element of the input vector
π π
out [ n ] = in [ n ] × 0.42 – 0.5 × cos n × 2.0 × ---- + 0.08 × cos n × 4.0 × ---- (27–2)
N N
Synopsis
DARRAY da_blkman(DARRAY h_in)
Arguments
h_in The input DARRAY must have input data size of a power of 2. Data
can be any noncomplex type.
Returns
A DARRAY handle to the data array containing the windowed data.
The output data is the smallest type compatible with the input type and DA_REAL. Data will
have type DA_DREAL if the input type is DA_DREAL and DA_REAL in all other cases. Output
vector length is the same as the input vector.
Zero is returned in the case of a run-time error which is ignored or continued.
da_cdotpr
Complex dot product.
da_cdotpr performs the complex dot product operation on two complex input vectors
Synopsis
D_COMPLEX da_cdotpr(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data arrays can contain data of either single or double
precision complex type. h_in1 must have the same length as
h_in2.
h_in2 The input data arrays may contain data of either single or double
precision complex type. h_in2 must have the same length as
h_in1.
Returns
A double precision complex number.
Zero is returned in the case of a run-time error which is ignored or continued.
da_cfft
In-place complex FFT.
This function does not return any value. It changes the program state by replacing the input
DARRAY data with its discrete Fourier transform
N–1 2π
-j ------- nk
N
out [ n ] = ∑ in [ k ]e (27–4)
n=0
where N is the size of the input sequence, and j is the square root of -1. The function uses
a standard radix 8 FFT algorithm.
da_cfft computes the full spectrum for the complex waveform input. Both the positive and
negative frequencies are represented in the output spectrum. This algorithm is scaled so
that the transform of a pure real cosine wave, 1024 samples, peaking at -1 and 1, will appear
as two spikes of amplitude 512 at the appropriate frequencies.
Synopsis
da_cfft(DARRAY h_in)
Arguments
h_in The input DARRAY can have any complex input type. That is, the
input DARRAY can have type DA_CMPLX or DA_DCMPLX. Since the
input is complex, the full spectrum is represented. In normal
operation, after the function’s execution, the length of the input
DARRAY will be the same as the original length. The input
DARRAY’s type will be unaltered.
Side Effects
The input data is overwritten by the result.
da_cfftb
Not-in-place complex FFT.
Performs a not-in-place complex FFT on the input vector (output not the same as input).
Synopsis
DARRAY da_cfftb(DARRAY h_in)
Arguments
h_in Data array handle for input vector. Type must be complex.
Returns
Data array handle (float/double complex)
See Also
“da_cfft”
da_cifft
In-place complex inverse FFT.
This function does not return any value. It replaces the input data with the inverse discrete
Fourier transform
N–1 2π
j ------- nk
N
out [ n ] = ∑ in [ k ]e (27–5)
n=0
where N is the size of the input sequence, and j is the square root of -1.
The function uses a standard radix 8 FFT algorithm.
Note that, unlike the real FFT algorithm, the results are scaled. If the input is the zero vector
except for bin k, at which the input is
A
out [ k ] = ---- e jφ (27–6)
2
then the output will be k cycles of a real cosine function with zero imaginary component, with
amplitude 2 × A and initial phase φ.
Since the input is complex, the full spectrum is represented in the input, and the full time
domain signal is computed. In normal operation, after the function’s execution, the input
DARRAY’s type and length will be unaltered.
Synopsis
da_cifft(DARRAY h_in)
Arguments
h_in The input data array must have data which is a complex input
type: DA_CMPLX or DA_DCMPLX.
Side Effects
The input DARRAY’s data is overwritten by the result.
da_cifftb
Not-in-place complex inverse FFT.
The result of this function is a DARRAY handle whose data is the discrete inverse Fourier
transform of the input data
N–1 2π
j ------- nk
N
out [ n ] = ∑ in [ k ]e (27–7)
n=0
where N is the size of the input DARRAY, and j is the square root of -1.
The function uses a standard radix 8 FFT algorithm.
Note that, unlike the real FFT algorithm, the results are scaled. If the input is k cycles of a
real cosine function with zero imaginary component, with amplitude A and initial phase φ,
then the output is the zero vector except for bin k:
A
out [ k ] = ---- e jφ (27–8)
2
Synopsis
DARRAY da_cifftb(DARRAY h_in)
Arguments
h_in The input data must be a complex type: DA_CMPLX or DA_DCMPLX.
Returns
In normal operation, the output is a DARRAY handle whose length and type are the same as
the length and type of the input DARRAY.
Zero is returned in the case of a run-time error which is ignored or continued.
da_complex_spectrum
Calculate a complex spectrum using time domain sample data.
This function returns a handle to a data array which contains the complex spectrum
calculated from the input sample data. The input vector must be in the time domain but can
be real or complex, single or double precision, or fixed point. The output vector is in the
frequency domain. The type of the output vector is given in table 27-21, where the requested
type is the value of the parameter type.
Based on the input type and requested type, da_complex_spectrum uses the appropriate
FFT algorithm to compute the complex spectrum.
Table 27-21. Output vector type vs. input type and requested type
Summary:
• If the requested type is (double precision) DA_DCMPLX, the output data is DA_DCMPLX for
any input data type. The data is converted to DA_DCMPLX during the computation.
• If the requested type is (single precision) DA_CMPLX, the output vector is DA_CMPLX if the
input is DA_INT, DA_FRACT2, DA_REAL, DA_DREAL, DA_CMPLX, or DA_DCMPLX. If the input
data is (double precision) DA_DREAL or DA_DCMPLX and the requested type is (single
precision) DA_DREAL, it is an error.
• Any other combination of requested type and input type is an error.
Synopsis
DARRAY da_complex_spectrum (DARRAY input, da_numeric_data_type type,
da_window_function window_function)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input sample data.
type Requested output vector type. See table 27-21 for valid
combinations with input data types.
window_function Windowing function applied to sample data. If no windowing is
needed, use da_null_window.
Returns
A handle to a data array which contains the complex spectrum.
See Also
“da_phase_full”
da_conv
Convolution.
This function computes the convolution of two vectors. If the length of the vectors are |h_in1|
and |h_in2|, then the convolution is defined to be
h_in2 – 1
for k = 0..|h_in1|-|h_in2|.
Note that the indices to h_in2 are processed in inverse numeric order, and the indices to
h_in1 are processed in forward numeric order. This means that there are |h_in1|-|h_in2|+1
output elements.
Synopsis
DARRAY da_conv(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 DARRAY handle for first input data array. Must contain data of a
noncomplex type. The length of h_in1 must be greater than or
equal to the length of h_in2 so that the output length is positive.
h_in2 DARRAY handle for second input data array. Must contain data of
a noncomplex type. The length of h_in2 must less than or equal
to than the length of h_in1 so that the output length is positive.
Returns
In normal operation, the return value is a DARRAY handle for a data array containing data
that is of the smallest type compatible with the types of the two input DARRAYs and also with
DA_REAL. The length of the output vector is as given above.
da_corr
Correlation.
Computes the correlation of two vectors. If the length of the vectors are |h_in1| and |h_in2|,
the correlation is defined to be
h_in2 – 1
for k = 0..|h_in1|-|h_in2|.
Note that the indices for both h_in1 and h_in2 are processed in numeric order. This means
that there are |h_in1|-|h_in2|+1 output elements.
Synopsis
DARRAY da_corr(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input DARRAY handles must have a noncomplex type. The
length of h_in1 must be greater than or equal to the length of
h_in2 so that length of the output is positive.
h_in2 The input DARRAY handles must have a noncomplex type. The
length of h_in2 must be less than or equal to the length of h_in1
so that length of the output is positive.
Returns
In normal operation, the output is a DARRAY handle for a data array whose length is given as
above. The data type is the smallest type compatible with the types of the two input data
arrays and also with DA_REAL. That is, the output type is DA_DREAL if the one of the input
types is DA_DREAL and is DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_cosine
Simulate the sampling of a continuous-time cosine waveform.
This function simulates the sampling of a continuous-time cosine waveform. You specify the
parameters of the sampling, including the sample frequency and the number of samples,
and the parameters of the continuous-time waveform, including frequency, amplitude, DC
offset, and phase angle in radians.
This function allocates a new DARRAY with a vector of data large enough to accommodate
the number of samples and the vector for the current site filled in with data representing
the specified sampling. The sample and waveform frequencies of the DARRAY’s current data
are filled in. The handle of the new DARRAY is returned.
Synopsis
DARRAY da_cosine(double Fs, da_size_t num_samples, double Ft,
double amplitude, double offset, double phase)
Arguments
Fs Sample frequency of the output waveform.
num_samples The number of samples in the output waveform.
Ft Frequency of the cosine.
amplitude Amplitude of the cosine.
offset Offset of the cosine.
phase Phase angle (in radians) of the cosine.
Returns
DARRAY with a cosine waveform. In the case of a run-time error, DA_NULL is returned without
allocating a new DARRAY.
Side Effects
Allocates a new DARRAY.
See Also
“da_multitone”
da_cvcomb
Complex vector combine.
This function returns a DARRAY handle whose data are the complex numbers whose real
parts are given by the first input DARRAY’s data, and whose imaginary parts are given by the
second input DARRAY’s data
Synopsis
DARRAY da_cvcomb(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The first input data array must have a length greater than zero,
equal to length of h_in2. Data can be any noncomplex type.
h_in2 The second input data array must have a length greater than
zero, equal to length of h_in1. Data can be any noncomplex
type.
Returns
The return value has the same length as the input data arrays. Data has the smallest type
compatible with the input data array types and also with DA_CMPLX.
da_cvconj
Complex conjugate.
The result of this function is a DARRAY handle whose data is the result of applying the
complex conjugate function element-wise to the input vector
Synopsis
DARRAY da_cvconj(DARRAY h_in)
Arguments
h_in The input data array must have a complex type. Length must be
greater than zero.
Returns
In normal operation, the return value is a DARRAY handle for a data array whose type and
length are the same as those of the input.
Zero is returned in the case of a run-time error which is ignored or continued.
da_cvexp
Complex vector natural exponent.
The input to this function is a DARRAY handle whose data are a vector of angles, measured
in radians. The output is a complex DARRAY whose data are the complex numbers on the
unit circle which have the given phase angles
Synopsis
DARRAY da_cvexp(DARRAY h_in)
Arguments
h_in The input data array must have a noncomplex type. Length must
be greater than zero.
Returns
In normal operation, the output data array will have a complex type. It will be double
precision complex if the input is DA_DREAL and single precision complex in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_cvmags
Complex vector magnitude squared.
This function returns a DARRAY whose data is the element-wise application of the absolute
value or magnitude squared function to the input DARRAY’s data
0 ≤ out [ n ]
(27–14)
out [ n ] = ( in [ n ].real ) 2 + ( in [ n ].imag ) 2
Synopsis
DARRAY da_cvmags(DARRAY h_in)
Arguments
h_in The input data array must have a length greater than zero. Data
can be any type.
Returns
In normal operation, the output DARRAY will have the same length as the input. It will have
type DA_DREAL if the input type is DA_DREAL or DA_DCMPLX. It will have type DA_REAL in all
other cases.
da_cvrcip
Complex vector reciprocal.
Calculates elementwise reciprocal of a complex vector.
Synopsis
DARRAY da_cvrcip(DARRAY h_in)
Arguments
h_in Data array handle for input vector. Data can be any type.
Returns
Data array handle (complex or double complex)
da_dB
Convert a fraction to decibels.
Given a fraction, compute the fraction’s value in dB using 10*log(fraction).
Synopsis
double da_dB(double fraction)
Arguments
fraction Fraction (ratio) to be converted to dB.
Returns
Value in dB.
da_dbcon
Vector convert to decibels.
The result of this function is a DARRAY handle whose data is the element-wise application of
the decibel function to the input DARRAY’s data
where:
conv is 20 if flag == 0, and 10 if flag == 1
Synopsis
DARRAY da_dbcon(DARRAY h_in, double scalar, int flag)
Arguments
h_in The input data array can have any length. Data must be a
noncomplex type.
scalar A double precision floating point number.
flag An integer.
Returns
In normal operation, the return value’s data has the same length as the length of the DARRAY
input parameter h_in. The type of the return value’s data is the smallest type compatible
with the type of the DARRAY input’s data and also with DA_REAL. That is, the output type is
DA_DREAL if the input type is DA_DREAL and DA_REAL in all other cases.
da_decimate
Decimate.
The result of this function is a DARRAY handle whose data is the nth element of the input
DARRAY’s data
out [ k ] = in [ k × n ] (27–16)
Synopsis
DARRAY da_decimate(DARRAY h_in, int n)
Arguments
h_in The data array can have any length. Data can be any type.
n The decimation factor is an integer.
Returns
The return value has length
n × ceil ( N ⁄ n ) (27–17)
where N is the length of the input vector, and ceil(t) is the smallest integer which is greater
than or equal to t.
da_define
Allocates a new data array.
Creates a new data array, with the specified type (such as DA_REAL or DA_CMPLX) and size.
If the handle argument is a valid DARRAY handle, that handle is re-used, and the old
DARRAY represented by that handle is re-allocated. In normal cases, however, it is
customary to pass DA_NULL as the first argument, in which case da_define will use the next
available handle.
Examples:
To define a new DARRAY:
DARRAY foo = DA_NULL;
foo = da_define(DA_NULL, DA_REAL, 64);
To redefine a pre-existing DARRAY:
da_define(foo, DA_REAL, 128);
Synopsis
DARRAY da_define(DARRAY handle, unsigned int type, unsigned int size)
Arguments
handle Data array handle. If this is DA_NULL (or any invalid handle),
da_define will allocate a new handle and DARRAY from scratch.
If it is a valid handle, the DARRAY and handle are re-allocated.
type A data type for the sample data in the data array. An unsigned
integer. Valid types are DA_REAL, DA_DREAL, DA_CMPLX,
DA_DCMPLX, DA_INT, DA_FRACT2.
Returns
Handle number which references the data array.
Side Effects
May allocate memory and a handle for the new DARRAY. May re-allocate the memory of
the handle argument.
da_dotpr
Dot product.
This function computes the inner, or dot, product of two real vectors
Synopsis
double da_dotpr(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data array must contain data of a non-complex type.
h_in1 must be the same length as h_in2.
h_in2 The input data array must contain data of a non-complex type.
h_in2 must be the same length as h_in1.
Returns
The output value is a double precision floating point number.
Zero is returned in the case of a run-time error which is ignored or continued.
da_double_to_frac
Vector double to frac2.
The result of this function is a DARRAY handle whose data is the element-wise application to
the input DARRAY’s data of the function which converts double precision floating point
numbers to DA_FRACT2 numbers.
If double_to_fract2(t) is the result of converting the double precision floating point
number t to DA_FRACT2, then
Synopsis
DARRAY da_double_to_frac(DARRAY h_in)
Arguments
h_in The input data array length must be greater than zero. Data must
have type DA_DREAL.
Returns
In normal operation, the output DARRAY will have the same length as the input DARRAY. It will
always have type DA_FRACT2.
Zero is returned in the case of a run-time error which is ignored or continued.
da_dpsp
Vector double to float.
The result of this function is a DARRAY handle whose data is the element-wise application to
the input data of the function which converts double precision floating point numbers to
single precision floating point numbers:
Synopsis
DARRAY da_dpsp(DARRAY h_in)
Arguments
h_in The input data array length must be greater than zero. Data must
be type DA_DREAL.
Returns
In normal operation, the output DARRAY has the same length as the input DARRAY. Its type is
always DA_REAL.
Zero is returned in the case of a run-time error which is ignored or continued.
da_enob_best_fit
Calculate effective number of bits in sample data by best fit.
This function calculates the effective number of bits in sample data. The input is a sinusoidal
output from the device, at a given frequency (in Hz) and a nominal number of bits. The
output is the effective number of bits, given by
where:
2 lg(x) = x (27–22)
rms_error The RMS error between the best-fit approximation to the input
and the input. The best-fit sinusoidal function is computed using
an algorithm from ANSI/IEEE Std 1057 - An Algorithm for Three
Parameter (Known Frequency) Least Squared Fit to Sine Wave
Data.
Synopsis
double da_enob_best_fit(DARRAY input, da_size_t nominal_number_of_bits)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input sample data.
nominal_number_of_bits
The nominal number of bits represented by the input, calculated
using equation 27–21 above.
Returns
The effective number of bits.
If an error in the parameters is detected, 0.0 is returned.
da_enob_snr
Calculate the effective number of bits using the signal-to-noise ratio.
This function calculates of the effective number of bits using the signal-to-noise ratio of the
input waveform. The input waveform must be in the time domain, and the nominal number
of bits is specified as a parameter. The sample and waveform frequencies are taken from
the input DARRAY.
The result returned by this function is
Synopsis
double da_enob_snr(DARRAY input, da_size_t number_of_bits)
Arguments
input Input variable containing the input sine waveform.
The data array must have a length which is a power of 2 and
contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
Returns
The effective number of bits.
See Also
“da_enob_snr_full”, “da_enob_best_fit”
da_enob_snr_full
Calculate the effective number of bits using the signal-to-noise ratio, with input parameters:
number of harmonics, test frequency, and sample frequency.
This function calculates the effective number of bits, using the signal-to-noise ratio of the
input waveform. The input waveform must be in the time domain, and the nominal number
of bits is specified as a parameter. The sample and test frequency of the input waveform
and the number of harmonics to consider in the SNR calculation must be specified as
parameters.
The result returned by this function is
Result = (------------------------------------------------------------------------------
SNR ( input ) – 20 log ( 6 ) ⁄ 2 )
- (27–24)
20 log ( 2 )
Synopsis
double da_enob_snr_full(DARRAY input, da_size_t number_of_bits,
da_size_t number_of_harmonics, double Fs, double Ft)
Arguments
input Input variable containing the input sine waveform.
The data array must have a length which is a power of 2 and
contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
Returns
The effective number of bits.
See Also
“da_enob_snr”, “da_enob_best_fit”
da_expand
Expand.
The result of this function is a DARRAY whose data is zero everywhere except at indices
which are multiples of n. At index k*n the output is the kth element of the input DARRAY’s
data.
Synopsis
DARRAY da_expand(DARRAY h_in, int n)
Arguments
h_in The input data array can have any size and any data type.
n The expansion increment. Must be positive.
Returns
Data array handle.
da_fft
In-place FFT.
This function does not return a value. It changes the program state by replacing the input
DARRAY’s data with its discrete Fourier transform
N–1
where N is the size of the input sequence, and j is the square root of -1.
The function uses a standard radix 8 FFT algorithm.
Note that, as is usual with the DFT, the output is N times the values the Fourier series might
supply. For example, the cosine function can be written as
A
A × cos ( ωt ) ≡ ---- ( e jωt + e –jωt ) (27–26)
2
The Fourier series coefficients are A/2 at ω and -ω. If ω = 2 × π × n/N, then out[n] is N × A/2.
Synopsis
da_fft(DARRAY h_in)
Arguments
h_in The input data array must have a length which is a power of 2.
The input data must have a floating point type: DA_REAL or
DA_DREAL. Since the input is real, the full spectrum is conjugate
Side Effects
Input data is overwritten by the result.
See Also
“da_set_number_samples”
da_fftb
Not-in-place FFT.
The result of this function is the discrete Fourier transform of the input data
N–1
where N is the size of the input sequence, and j is the square root of -1.
Note that, as is usual with the DFT, the output is N times the values the Fourier series might
supply. For example, the cosine function may be written as
A
A × cos ( ωt ) ≡ ---- ( e jωt + e –jωt ) (27–28)
2
The Fourier series coefficients are A/2 at ω and -ω. If ω = 2 × π × n/N, then out[n] is N × A/2.
Synopsis
DARRAY da_fftb(DARRAY h_in)
Arguments
h_in The input data array must have a length which is either a power
of two or 400, or 800. Data must be a floating-point type:
DA_REAL or DA_DREAL.
Returns
Since the input is not complex, the full spectrum is conjugate symmetric and, therefore, only
half the output spectrum needs to be represented. In normal operation, the length of the
output DARRAY will be half of the input DARRAY’s length. The type will be the smallest type
compatible with the input type and also with DA_CMPLX. That is, the output type will be
DA_DCMPLX if the input type is DA_DREAL and DA_CMPLX if the input type is DA_REAL.
See Also
“da_set_number_samples”
da_fix32d
Vector double to integer.
The result of this function is a data array whose data is the element-wise application to the
data of the input data array of the function which converts double precision floating point
integers to DA_INT.
Synopsis
DARRAY da_fix32d(DARRAY h_in)
Arguments
h_in The input data array must have type DA_DREAL. It can have any
nonpositive length.
Returns
In normal operation, the output DARRAY has the length of the input DARRAY and has type
DA_DREAL.
da_flt32d
Vector float to integer.
The result of this function is a DARRAY handle whose data is the element-wise application to
the input DARRAY’s data of the function which converts single precision floating point
numbers to DA_INT.
Synopsis
DARRAY da_flt32d(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data type
must be DA_REAL.
Returns
In normal operation, the output DARRAY will have type DA_INT and will have the same length
as the input DARRAY.
Zero is returned in the case of a run-time error which is ignored or continued.
da_frac_to_double
Vector frac2 to double.
The result of the function is a data array whose data is the element-wise application to the
input data of the function which converts DA_FRACT2 data to double precision floating point
data.
If fract2_to_double(t) is the result of converting the DA_FRACT2 number t to double precision
floating point
Synopsis
DARRAY da_frac_to_double(DARRAY h_in)
Arguments
h_in The input data array length must be greater than zero. Data must
be type DA_FRACT2.
Returns
In normal operation, the output DARRAY will have the same length as the input DARRAY and
will have type DA_DREAL.
Zero is returned in the case of a run-time error which is ignored or continued.
da_frac_to_real
Vector frac2 to float.
The result of this function is a DARRAY whose data is the element-wise application to the
input DARRAY’s data of the function which converts DA_FRACT2 data to single precision
floating point.
If fract2_to_real(t) is the result of converting the DA_FRACT2 number t to single precision
floating point
Synopsis
DARRAY da_frac_to_real(DARRAY h_in)
Arguments
h_in The input data array length must be greater than zero. Data must
have type DA_FRACT2.
Returns
In normal operation, the output DARRAY has the same length as the input DARRAY. Its type is
always DA_REAL.
Zero is returned in the case of a run-time error which is ignored or continued.
da_free
Frees a DARRAY associated with a handle. Deallocates a DARRAY by freeing the
associated data memory. It sets the content of passed DARRAY handle pointer to DA_NULL.
Synopsis
int da_free(DARRAY *handle)
RESTRICTIONS
1. Side threads that are called from a TESTF that has been called from a SEQUENCER
can only free DARRAYs with lifetime of DA_TESTF. Otherwise,
the return value will be TL_DA_CANT_FREE but no runtime
error is thrown.
2. Side threads that are not called from a TESTF that has been
called from a SEQUENCER can only free DARRAYs with
lifetime of DA_TESTF or DA_RUN. Otherwise, the return value
will be TL_DA_CANT_FREE but no run-time error is thrown.
3. If da_free() is called in the main thread, it calls
tl_compute_sync(). That is, it waits for all side threads to finish
before freeing a Data array.
4. The DARRAYs with a lifetime of DA_JOB can only be freed
(by calling da_free()) by the main thread. Side threads are not
allowed to free DARRAYs with a lifetime of DA_JOB.
These restrictions are forced to ensure that you do not
accidentally free a DARRAY that is intended to be used or is
being used by other threads.
Note, however, that it is still logically possible to free a DARRAY
which may be intended to be used later. So, it is your
responsibility to free only those DARRAYs that will not be used
later.
Arguments
*handle - address of Data array handle
Returns
TL_DA_SUCCESS The memory associated with the DARRAY has been freed.
TL_DA_NOT_FOUND The attempt to free memory failed because the DARRAY does
not exist, or there was an error getting to the DARRAY.
TL_DA_CANT_FREE The attempt to free memory failed because you are not allowed
to free this DARRAY.
da_get_domain
Get the data domain of a DARRAY. Locates the data darray referenced by handle and
returns the data domain.
Synopsis
DA_DataDomain da_get_domain(DARRAY handle)
Arguments
DARRAY handle The data array handle
Returns
The data domain of the DARRAY or TL_DA_ERROR.
da_get_Fs
Locates the data array referenced by the parameter handle and returns the value of the
sampling frequency field.
Synopsis
double da_get_Fs(DARRAY handle)
Arguments
handle A handle for a data array or the data array name (type DARRAY).
An unsigned integer.
Returns
The value of the sample frequency field of the data array or TL_DA_ERROR.
da_get_Ft
Locates the data array referenced by the parameter handle and gets the value of the
fundamental or “test” frequency.
Synopsis
double da_get_Ft(DARRAY handle)
Arguments
handle A handle for a data array or the data array name (type DARRAY).
An unsigned integer.
Returns
The value of the test frequency field of the data array or TL_DA_ERROR.
da_get_lifetime
Locates the queue a darray is on and sets the lifetime parameter to that queue value.
Returns a 1 if the darray was found, 0 if not found.
Synopsis
int da_get_lifetime(DARRAY handle, DA_DATA_LIFETIME lifetime)
Arguments
handle the handle of the darray you wish to locate lifetime - a pointer to
the lifetime value
Returns
1 for successfully found darray 0 if not found
da_get_number_samples
Returns the number of samples. For time domain signals this is exactly equal to
da_get_size. for frequency domain signals or power spectra this operation tells how many
samples the original signal had. If the original signal was purely real, this will be twice the
value of da_get_size().
Synopsis
int da_get_number_samples(DARRAY handle)
Arguments
handle Data array handle
Returns
The number of samples.
da_get_size
Locates the data array referenced by the parameter handle and returns the value of the size
field.
Synopsis
int da_get_size(DARRAY handle)
Arguments
handle A handle for a data array or the data array name (type DARRAY).
An unsigned integer.
Returns
The value of the size field of the data array or TL_DA_ERROR.
da_get_type
Locates the data array referenced by parameter handle and returns the value of the
datatype field.
Synopsis
int da_get_type(DARRAY handle)
Arguments
handle A handle for a data array or the data array name (type DARRAY).
An unsigned integer.
Returns
The value of the datatype field of the data array or TL_DA_ERROR. Possible types and return
values are DA_REAL (1), DA_DREAL (6), DA_CMPLX (2), DA_DCMPLX (7), DA_INT (3), and
DA_FRACT2 (5).
da_get_vector
Locates the data array referenced by the parameter handle and returns a pointer to the data
vector.
Synopsis
void *da_get_vector(DARRAY handle)
Arguments
handle A handle for a data array or the data array name (type DARRAY).
An unsigned integer.
Returns
A pointer to the data vector or nil.
da_hamm
Hamming window.
This function returns the handle of a DARRAY whose data is the result of applying the
Hamming window to the input vector
Synopsis
DARRAY da_hamm(DARRAY h_in)
Arguments
h_in The input data array size must be a power of 2. Data must be a
noncomplex type.
Returns
In normal operation, the function returns the handle of a DARRAY which contains the
windowed signal. The type of the output DARRAY is the smallest type compatible with the
input type and DA_REAL. That is, it is DA_DREAL if the input is DA_DREAL and DA_REAL in all
other cases. Its length is the length of the input vector.
Zero is returned in the case of a run-time error which is ignored or continued.
da_hamming_window
Hamming window function.
This name denotes the Hamming window function. It is not a callable function. It is only used
as a parameter to da_complex_spectrum. The hamming window is defined by
Synopsis
da_window_function da_hamming_window
See Also
“da_3rd_order_imd”
da_hann
Hanning window.
The function returns the result of applying the Hanning window to the input vector
Synopsis
DARRAY da_hann(DARRAY h_in)
Arguments
h_in The input data array length must be a power of 2. Data type must
be a noncomplex type.
Returns
In normal operation, the return value is the handle to a DARRAY which contains the
conditioned signal. The type of the output DARRAY is DA_DREAL if the input is DA_DREAL and
DA_REAL in all other cases. Its length is the length of the input vector.
da_hanning_window
Hanning window function.
This name denotes the Hanning window function. It is not a callable function. It is only used
as a parameter to da_complex_spectrum. The Hanning window is defined by
Synopsis
da_window_function da_hanning_window
See Also
“da_3rd_order_imd”
da_hd
Calculate the harmonic distortion of an input sine wave.
This function calculates harmonic distortion. Harmonic distortion is a measure of the power
of a sine wave signal at the fundamental frequency as compared to the power in the first
few harmonic frequencies. The input DARRAY contains the sine wave to be analyzed and its
sample and test frequency. (These can be set using da_set_Fs and da_set_Ft.)
The result is the ratio of the fundamental power to the maximum power in any of the first few
harmonics. (The fundamental power is the magnitude of the FFT of the input waveform at
frequency Fs, and the harmonic power is at 2*Fs, 3*Fs, and so on.) The number of
harmonics considered is the IMAGE default value (5). An FFT is used to find the power of
the signal at given frequencies.
Synopsis
double da_hd(DARRAY input)
Arguments
input Input variable containing the input sine waveform.
The data array must have a length which is a power of 2 and
contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
Returns
The harmonic distortion, expressed as a ratio, or TL_DA_ERROR, in the case of a run-time
error.
See Also
“da_hd_full”
da_hd_full
Calculate the harmonic distortion of an input sine wave, with input parameters: sample
frequency, test frequency, and the number of harmonics.
This function calculates harmonic distortion. Harmonic distortion is a measure of the power
of a sine wave signal at the fundamental frequency as compared to the power in the first
few harmonic frequencies. The test and sampling frequencies are specified as input
parameters as are the number of harmonics.
The result is the ratio of the fundamental power to the maximum power in any of the first few
harmonics. (The fundamental power is the magnitude of the FFT of the input waveform at
frequency Fs, and the harmonic power is at 2*Fs, 3*Fs, and so on.) The number of
harmonics considered is determined by the input parameter num_harmonics. An FFT is
used to find the power of the signal at given frequencies.
Synopsis
double da_hd_full(DARRAY input, double Fs, double Ft, da_size_t num_harmonics)
Arguments
input Input variable containing the input sine waveform.
The data array must have a length which is a power of 2 and
contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
Returns
The harmonic distortion, expressed as a ratio, or TL_DA_ERROR, in the case of a run-time
error.
See Also
“da_hd”
da_hist
Histogram.
This function returns no results. It changes the program state by side-effects on its
parameters. It calculates a histogram for h_in1 and stores the results in h_in2. The
histogram is defined as follows:
If |h_in2| is the length of the vector h_in2:
• h_in1 is never changed
• h_in2[0] is increased by the number of elements of h_in1 which are less than min
• h_in2[|h_in2|-1] is increased by the number of elements of h_in1 which are greater
than or equal to max
• in2[k] is incremented by the number of elements of h_in1 which are in the range [min +
(k-1) * (max - min)/|h_in2|, min + k * (max - min)/|h_in2|) for integer k in the range
[1,|h_in2|-1]
This latter calculation divides range [min, max] into |h_in2| bins. Then the kth element
of in2 is increased by the number of elements which fall in the kth bin.
NOTE
The parameter h_in2 may already contain a histogram, in which case the result of calling
this function will be to add values to each existing value in h_in2. h_in2 is not cleared
before use.
Synopsis
da_hist(DARRAY h_in1, DARRAY h_in2, double max, double min)
Arguments
h_in1 The first input data array can have any length. Data must be a
noncomplex type.
h_in2 The second input data array, also an output parameter, can have
any length. Data must be a floating point type: DA_REAL or
DA_DREAL. The second input data array type is not automatically
promoted to DA_DREAL. If the first input data array type is
DA_DREAL, and the second data array type is DA_REAL, an error
results.
max The maximum value for the range of the histogram. This value is
a double precision floating point number.
min The minimum value for the range of the histogram. This value is
a double precision floating point number.
Side Effects
The elements of the input parameter h_in2 are increased by the histogram counts.
da_ifft
In-place inverse FFT.
This function does not return a value. It changes the program state by replacing the input
DARRAY data with its inverse discrete Fourier transform
N–1 k
-j2π × n × ------- 2N – 2 k
-j2π × n × -------
- -
2N 2N
out [ n ] = ∑ in [ k ]e + ∑ conj ( in [ 2N – k – 1 ] )e (27–35)
k=0 k=N
where N is the size of the input sequence, conj(c) is the complex conjugate of the complex
number c, and j is the square root of -1.
The function uses a standard radix 8 FFT algorithm. The input vector of length N represents
a length 2N spectrum, whose negative frequency bins are the complex conjugates of the
positive bins.
Note that the amplitude of the input data is assumed to be scaled as with da_rfftsc. For
example, if the spectrum is zero at all points except for bin k, and the value of k is 1.0 + 0.0j,
the result of the ifft is k cycles of the cosine whose amplitude is 2.0.
Synopsis
da_ifft(DARRAY h_in)
Arguments
h_in The data must be a complex type: DA_CMPLX or DA_DCMPLX.
In normal operation, after the function’s execution the length of the input DARRAY will be half
the original length. The input DARRAY’s type will be set to DA_REAL if it is initially DA_CMPLX
and DA_DREAL if the initial type is DA_DCMPLX.
On errors, data is not altered.
Side Effects
The data in the input data array is overwritten by the result.
da_ifftb
Not-in-place inverse FFT.
The result of this function is a DARRAY handle whose data is the inverse discrete Fourier
transform of the input DARRAY’s data
N–1 k
-j2π × n × ------- 2N – 2 k
-j2π × n × -------
- -
2N 2N
out [ n ] = ∑ in [ k ]e + ∑ conj ( in [ 2N – k – 1 ] )e (27–36)
k=0 k=N
where N is the size of the input sequence, conj(c) is the complex conjugate of the complex
number c, and j is the square root of -1.
The function uses a standard radix 8 FFT algorithm. The input vector of length N represents
a length 2N spectrum whose negative frequency bins are the complex conjugates of the
positive bins.
Note that the amplitude of the input data is assumed to be scaled as with da_rfftsc. For
example, if the spectrum is zero at all points except for bin k, and the value of k is 1.0 + 0.0j,
the result of the ifft is k cycles of the cosine whose amplitude is 2.0.
Synopsis
DARRAY da_ifftb(DARRAY h_in)
Arguments
h_in The input data must be a complex type.
Returns
In normal operation, the return DARRAY will have twice the length of the input DARRAY. The
output type will be DA_DREAL if the input type is DA_DCMPLX. The output type will be DA_REAL
if the input type is DA_CMPLX.
da_imd
Calculate the intermodulation distortion.
This function calculates the intermodulation distortion of a two-tone sine wave. The time
domain waveform and its two fundamental frequencies are specified as parameters, f1, and
f2, respectively. Also specified is an output buffer containing allocated memory for six
double-precision results.
The function takes the FFT of the input waveform and records the magnitude of that
spectrum at six key frequencies. Those six values are written in sequence to six locations
in the output buffer. The frequencies of interest are
f1 + f2
f1 - f2
f1 + 2*f2
f1 - 2*f2
2*f1 + f2
2*f1 - f2
Negative frequencies are acceptable (and, in fact, unavoidable), since by definition, the
value of the spectrum of a real signal at frequency -f is the same as it is at frequency f. Note
that the value computed is I[f1+f2] and not I[f1] + I[f2] (assuming I[f] is the value of the input
spectrum at frequency f.)
Synopsis
void da_imd(DARRAY input, double f1, double f2, double *output)
Arguments
input Input variable containing the input two-tone sine wave.
The input data array must have a length which is a power of 2
and contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
*output A pointer which represents where to write the results. In the case
of an error, the function writes six TL_DA_ERRORs here.
Side Effects
Writes six double-precision numbers.
See Also
“da_imd_full”
da_imd_full
Calculate the intermodulation distortion with additional parameter sample frequency.
This function calculates the intermodulation distortion of a two-tone sine wave. The sample
frequency of the waveform and its two fundamental frequencies are specified as
parameters, f1, and f2, respectively. Also specified is an output buffer containing allocated
memory for six double-precision results.
The function takes the FFT of the input waveform and records the magnitude of that
spectrum at six key frequencies. Those six values are written in sequence to six locations
in the output buffer. The frequencies of interest are
f1 + f2
f1 - f2
f1 + 2*f2
f1 - 2*f2
2*f1 + f2
2*f1 - f2
Negative frequencies are acceptable (and, in fact, unavoidable), since by definition, the
value of the spectrum of a real signal at frequency -f is the same as it is at frequency f. Note
that the value computed is I[f1+f2] and not I[f1] + I[f2] (assuming I[f] is the value of the input
spectrum at frequency f.)
Synopsis
void da_imd_full(DARRAY input, double f1, double f2, double *output,
double Fs)
Arguments
input Input variable containing the input two-tone sine wave.
The input data array must have a length which is a power of 2
and contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
*output A pointer which represents where to write the results. In the case
of an error, the function writes six TL_DA_ERRORs here.
Fs Sample frequency. Value must be positive.
Side Effects
Writes six double-precision numbers.
See Also
“da_imd”
da_lookup
Lookup.
The result of this function is a DARRAY handle whose elements are a rearranging of the
elements of h_in1, using the elements of h_in2 to determine the rearrangement
Synopsis
DARRAY da_lookup(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The first input data array must have type DA_INT. It can have any
length greater than zero.
h_in2 The second input data array must have a noncomplex type. It
can have any length greater than zero.
Returns
In normal operation, the return value has the same type as the smallest type compatible with
the type of the second input data array (h_in2) and also DA_REAL. That is, the output
DARRAY type is DA_DREAL if the second parameter (h_in2) has type DA_DREAL and is
DA_REAL in all other cases. The return value has the same length as the first input
parameter, h_in1.
da_lveq
Logical vector equal.
This function returns the handle of a data array whose value represents the element-wise
logical equality of the two input vectors:
Synopsis
DARRAY da_lveq(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data array h_in1 must have the same length as h_in2.
Data must be a noncomplex type.
h_in2 The input data array h_in2 must have the same length as h_in1.
Data must be a noncomplex type.
Returns
In normal operation, the output DARRAY type is the smallest type compatible with the input
types and DA_REAL. That is, it is DA_DREAL if either of the input vectors have type DA_DREAL
and DA_REAL otherwise. Its length is the common length of the input vectors.
Zero is returned in the case of a run-time error which is ignored or continued.
da_lvge
Logical vector greater than or equal.
This function returns the handle of a data array whose elements represent the element-wise
comparison of the two input vectors for greater than or equality
Synopsis
DARRAY da_lvge(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data array h_in1 must have the same length as h_in2.
Data must be a noncomplex type.
h_in2 The input data array h_in2 must have the same length as h_in1.
Data must be a noncomplex type.
Returns
In normal operation, the output data array type is the smallest type compatible with the types
of the inputs and DA_REAL. That is, its type is DA_DREAL if either of the input vectors have
type DA_DREAL and DA_REAL otherwise. Its length is the common length of the input vectors.
Zero is returned in the case of a run-time error which is ignored or continued.
da_lvgt
Logical vector greater than.
This function returns the handle of a DARRAY whose elements represent the element-wise
comparison of the two input vectors
Synopsis
DARRAY da_lvgt(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data array h_in1 must have the same length as h_in2.
Data must be a noncomplex type.
h_in2 The input data array h_in2 must have the same length as h_in1.
Data must be a noncomplex type.
Returns
In normal operation, the output DARRAY type is the smallest type compatible with the types
of the input vectors. This is DA_DREAL if either of the input vectors have type DA_DREAL and
DA_REAL otherwise. Its length is the common length of the input vectors.
da_lvne
Logical vector not equal.
This function returns the handle of a DARRAY whose elements represent the element-wise
comparison of the two input vectors for inequality
Synopsis
DARRAY da_lvne(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data array h_in1 must have the same length as h_in2.
Data must be a noncomplex type.
h_in2 The input data array h_in2 must have the same length as h_in1.
Data must be a noncomplex type.
Returns
In normal operation, the output DARRAY type is the smallest type compatible with the two
input vectors. That is, this type is DA_DREAL if either of the input vectors have type DA_DREAL
and DA_REAL otherwise. Its length is the common length of the input vectors. On errors, zero
is returned.
Zero is returned in the case of a run-time error which is ignored or continued.
da_lvnot
Logical vector not.
This function returns the handle of a DARRAY whose elements are the element-wise
application of the real complement function to the elements of the input vector
Synopsis
DARRAY da_lvnot(DARRAY h_in)
Arguments
h_in The input data array length must be greater than zero. Data must
be a noncomplex type.
Returns
In normal operation, the output DARRAY type is the smallest type compatible with DA_REAL.
That is, its type is DA_DREAL if the input vector has type DA_DREAL and DA_REAL in all other
cases. Its length is the length of the input vector.
Zero is returned in the case of a run-time error which is ignored or continued.
da_maxmgv
Maximum magnitude.
This function returns a double precision floating point number whose value is the maximum
of the absolute values (magnitudes) of the elements of the input vector.
For the returned maximum value r
in [ n ] ≤ r (27–43)
Synopsis
double da_maxmgv(DARRAY h_in)
Arguments
h_in The input data array length must be greater than zero. Data must
be a noncomplex type.
Returns
In normal operation, the return value is a scalar whose type is double precision floating point
number.
Zero is returned in the case of a run-time error which is ignored or continued.
da_maxv
Maximum value.
This function returns the maximum of all the elements of the input vector and its index.
If r is the result of this function, then for all indices n
in [ n ] ≤ r (27–44)
in [ *outIndex ] = r (27–45)
Synopsis
double da_maxv(DARRAY h_in, int *outIndex)
Arguments
h_in The input data array can be any length. The data must be a
noncomplex type.
Returns
In normal operation, the result is a scalar whose type is double precision floating point.
Zero is returned in the case of a run-time error which is ignored or continued.
Side Effects
The address at which outIndex points is set to the index of the element at which the
maximum element occurs.
da_meamgv
Mean of element absolute values.
The value of this function is the mean of the absolute value of the elements in the input
vector
Synopsis
double da_meamgv(DARRAY h_in)
Arguments
h_in The input data array can be any length. The data must be a
noncomplex type.
Returns
In normal operation, the output is a double precision floating point number.
Zero is returned in the case of a run-time error which is ignored or continued.
da_meanv
Mean of elements.
The value of this function is the mean of the values of the elements in the input vector
Synopsis
double da_meanv(DARRAY h_in)
Arguments
h_in The input data array can be any length. The data must be a
noncomplex type.
Returns
In normal operation, the output is a double precision floating point number, even if the input
is DA_INT, DA_FRACT2, or DA_REAL.
Zero is returned in the case of a run-time error which is ignored or continued.
da_measqv
Mean of element squares.
The value of this function is the mean of the squares of the values of the elements in the
input vector
Synopsis
double da_measqv(DARRAY h_in)
Arguments
h_in The input data array can be any length. The data must be a
noncomplex type.
Returns
In normal operation, the output is a double precision floating point number, even if the input
is DA_INT, DA_FRACT2, or DA_REAL.
Zero is returned in the case of a run-time error which is ignored or continued.
da_merge
Merge.
The result of this function is a data array whose data is a copy of the data of the input data
array with handle h_in1, with the following changes. Starting at offset, each nth element
of h_in1 in the copy is replaced by the corresponding element of h_in2 data.
Output data will have the same type as the input array which has the highest type.
For each index k,
Synopsis
DARRAY da_merge(DARRAY h_in1, DARRAY h_in2, int offset, int n)
Arguments
h_in1 The first input data array length |h_in1| must be greater than or
equal to (offset + n * (|h_in2|-1)) + 1. The input data arrays can
have any data type.
h_in2 The second input data array length must obey the inequality
listed for h_in1. The input data arrays can have any data types.
offset The element of h_in1 to begin replacing with elements of h_in2.
offset must be an integer, with value greater than zero.
Returns
Data array handle of the data array with the merged data.
da_minmgv
Minimum magnitude.
This function returns a double precision floating point number whose value is the minimum
of the absolute values (magnitudes) of the elements of the input vector.
If the result is denoted r, then for each index n
r ≤ in [ n ] (27–51)
where |in[n]| denotes the absolute value, or magnitude, of the number in[n].
Synopsis
double da_minmgv(DARRAY h_in)
Arguments
h_in The input data array must have a noncomplex type.
Returns
In normal operation, the return value is a scalar whose type is double precision floating
point.
Zero is returned in the case of a run-time error which is ignored or continued.
da_minv
Minimum value.
This function returns the minimum of all the elements of the input vector and its index.
If r is the result of this function, then for all indices n
r ≤ in [ n ] (27–52)
in [ *outIndex ] = r (27–53)
Synopsis
double da_minv(DARRAY h_in, int *outIndex)
Arguments
h_in The input data must be a noncomplex type.
*outIndex This is the output data. If it is not null, it is a pointer to the element
index.
Returns
In normal operation, the result is a scalar whose type is double precision floating point.
Zero is returned in the case of a run-time error which is ignored or continued.
da_multitone
Simulate the sampling of a multitone cosine waveform.
This function generates a DARRAY containing a multitone cosine wave. You specify the size
of the waveform and the sample frequency. Additionally, you pass to it an array of
structures, one for every tone in the waveform. Each structure contains the frequency,
amplitude, offset, and phase of one tone. The number of tones to be added in the waveform
is the final parameter.
This function allocates a new DARRAY of size num_samples and fills the vector in the current
site with a waveform representing the sum of all the cosine waves described in the tones
array. The sample frequency of the DARRAY will also be filled in, and the handle of this new
DARRAY is returned.
Synopsis
DARRAY da_multitone(double Fs, da_size_t num_samples, DA_TONE *tones,
da_size_t num_tones)
typedef struct da_tone {
double frequency;
double amplitude;
double offset;
double phase;
} DA_TONE;
Arguments
Fs Sample frequency of the DARRAY.
num_samples Size of the DARRAY.
*tones An array of structures, one for each tone, containing the
amplitude, frequency, offset, and phase of each.
num_tones The number of tones and the number of structures in array
tones.
Returns
A newly allocated DARRAY containing a multitone cosine waveform (the sum of several
cosine waves at the specified parameters). If an error in the parameters is detected,
DA_NULL is returned without allocating a new array.
Side Effects
Allocates a new DARRAY.
See Also
“da_cosine”
da_null_window
Identity window function.
This name denotes the identity window function. It is not a callable function. It is only used
as a parameter to da_complex_spectrum. The identity window function does not scale or
alter the data at all.
Synopsis
da_window_function da_null_window
See Also
“da_3rd_order_imd”
da_offset_binary_to_real
Vector offset binary to real.
This function returns a DARRAY whose data is the result of converting every element of the
input data array from a binary value type to DA_REAL type. Input values are assumed to be
no more than res bits wide but this constraint is not enforced.
The function subtracts a given power of two from the input and then scales it by multiplying
by the scale parameter. The power of two value which is subtracted is (1 << (res - 1)).
An element of the output DARRAY has the value
Synopsis
DARRAY da_offset_binary_to_real(DARRAY h_in, double scale, int res)
Arguments
h_in The input data array length must be greater than 0. Data must be
type DA_INT or DA_FRACT2.
scale The scale factor applied to every element of the h_in after the
element is converted to D_REAL.
res The bit width range of the data before the scale is applied. The
value of res must fall in the range 2 <= res <= 32.
Returns
In normal operation, the output DARRAY has the type DA_REAL. Its length is the length of the
input DARRAY.
Zero is returned in the case of a run-time error which is ignored or continued.
da_peak_to_peak
Calculate the peak to peak voltage of the sample data.
This function calculates the difference between the maximum and minimum elements of a
vector.
Synopsis
double da_peak_to_peak(DARRAY input)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input sample data.
Returns
The difference between the maximum and minimum elements.
da_phase
Compute the phase at a given frequency.
The phase is the angle of the complex Fourier coefficient of the given frequency. It is in the
range [-π, π]. Both extremes are possible, since the real part of the Fourier coefficient can
be ±0.0. The input should be a spectrum. Sample frequency must be in the input data array.
Synopsis
double da_phase(DARRAY input, double f_i)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input spectrum data.
f_i Frequency of interest.
Returns
The phase.
See Also
“da_amplitude”, “da_amplitude_full”, “da_phase_full”
da_phase_full
Compute the phase at a given frequency, with additional parameter sample frequency.
The sample rate is specified using parameter f_s.
The phase is the angle of the complex Fourier coefficient of the given frequency. It is in the
range [-π, π]. Both extremes are possible, since the real part of the Fourier coefficient can
be ±0.0. The input should be a spectrum.
Synopsis
double da_phase_full(DARRAY input, double f_i, double f_s)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input spectrum data.
f_i Frequency of interest.
f_s Sample frequency.
Returns
The phase.
See Also
“da_amplitude”, “da_amplitude_full”, “da_phase”
da_phase_gain_change
Calculate the difference in phase and amplitude in two sine waves.
This function compares the phase and amplitude of two waveform segments. The input
DARRAY contains both waveform segments. The first segment begins at start1 and is
length1 elements long, and the second begins at start2 and is length2 elements long.
The two results, phase difference and amplitude difference, are written to pointers that you
provide. The sample and test frequencies of the segments are taken from the input DARRAY.
The result of this function is the difference (in radians) in phase between the two segments
and the difference (in volts) in amplitude. Simply expressed, it is phase(2) - phase(1) written
to the pointer phase, and amplitude(2) - amplitude(1), written to the pointer gain.
Synopsis
void da_phase_gain_change(DARRAY input, da_size_t start1, da_size_t length1,
da_size_t start2, da_size_t length2, double *phase, double *gain)
Arguments
input Input variable containing the input vector. Data type must be
DA_REAL or DA_DREAL.
Side Effects
Writes to pointers phase and gain.
See Also
“da_phase_gain_change_full”
da_phase_gain_change_full
Calculate the difference in phase and amplitude in two sine waves with additional
parameters, test frequency and sample frequency.
This function compares the phase and amplitude of two waveform segments. The input
DARRAY contains both waveform segments. The first segment begins at start1 and is
length1 elements long, and the second begins at start2 and is length2 elements long.
The two results, phase difference and amplitude difference, are written to pointers that you
provide. Additionally, the sample and test frequency of the segments are specified as
parameters.
The result of this function is the difference (in radians) in phase between the two segments
and the difference (in volts) in amplitude. Simply expressed, it is phase(2) - phase(1) written
to the pointer phase, and amplitude(2) - amplitude(1), written to the pointer gain.
Synopsis
void da_phase_gain_change_full(DARRAY input, da_size_t start1,
da_size_t length1, da_size_t start2, da_size_t length2,
double *phase, double *gain, double Fs, double Ft)
Arguments
input Input variable containing the input vector. Data type must be
DA_REAL or DA_DREAL.
Side Effects
Writes to pointers phase and gain.
See Also
“da_phase_gain_change”
da_phase_noise
Calculate the noise present in a sinusoid at a given frequency.
This function calculates the relative amount of noise present at a given frequency of a
sampled sinusoid. The input DARRAY contains a sine wave. Two important waveform
frequencies are the reference frequency Fc and the phase noise frequency, Fc + offset. You
specify the values for Fc and offset as parameters. The sample frequency is taken from the
input DARRAY.
The calculation is a ratio of power in the input signal at frequency Fc to power at Fc + offset.
An FFT of the input waveform finds the power at those two frequencies.
Synopsis
double da_phase_noise(DARRAY input, double Fc, double offset)
Arguments
input Input variable containing the input waveform.
Returns
Returns the ratio of the spectrum magnitudes at frequency Fc and Fc + offset.
See Also
“da_phase_noise_full”
da_phase_noise_full
Calculate the noise present in a sinusoid at a given frequency with additional parameter
sample frequency.
This function calculates the relative amount of noise present at a given frequency of a
sampled sinusoid. The input DARRAY contains a sine wave. Two important waveform
frequencies are the reference frequency Fc, and the phase noise frequency, Fc + offset.
You specify the values for Fc, offset, and sample frequency as parameters.
The calculation is a ratio of power in the input signal at frequency Fc to power at Fc + offset.
An FFT of the input waveform finds the power at those two frequencies.
Synopsis
double da_phase_noise_full(DARRAY input, double Fc, double offset, double Fs)
Arguments
input Input variable containing the input waveform.
The input data array must have a length which is a power of 2
and contain at least 8 elements. Data type must be DA_REAL or
DA_DREAL.
Returns
Returns the ratio of the spectrum magnitudes at frequency Fc and Fc + offset.
See Also
“da_phase_noise”
da_polar
Vector rectangular to polar.
This function returns a DARRAY handle to a data array whose elements are the polar
coordinate forms of the elements of the input DARRAY. The magnitude of the polar
coordinates are stored in the real part, and the angle of the polar coordinates are stored in
the imaginary part
where atan2 and hypot are the standard UNIX math library functions to compute arctangent
and hypotenuse.
The magnitude is always nonnegative, and the angle is in the range π to -π.
Synopsis
DARRAY da_polar(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data can
have any type. If the type is noncomplex, however, the
magnitude part of the output, stored in the real part, is set to the
input value, and the angle part, stored in the imaginary part, is
set to zero.
Returns
In normal operation, the output has the same length as the input and has the smallest type
compatible with the input type and with DA_CMPLX. That is, the output type is DA_DCMPLX if
the input type is DA_DREAL and is DA_CMPLX in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
NOTE
The input array must be of type COMPLEX.
NOTE
The input and output buffers must be different for this algorithm.
da_power_spectrum
Calculate a power spectrum using frequency domain sample data.
This function returns a handle to a data array which contains the power spectrum calculated
from the input sample data. The input data must be in the frequency domain. The output
data is a vector of real numbers.
The input must be complex data of type DA_CMPLX (single precision) or DA_DCMPLX (double
precision). The output data is DA_REAL or DA_DREAL depending on the value of type. Table
27-22 lists valid combinations with input data types.
See “Notes on Using Block Algorithms When Calculating FFTs and Spectra”.
Table 27-22. Output vector type vs. input type and requested type
Synopsis
DARRAY da_power_spectrum(DARRAY input, da_numeric_data_type type)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input sample data.
type Requested output vector type. See table 27-22 for valid
combinations with input data types.
Returns
A handle to a data array which contains the power spectrum.
See Also
“da_3rd_order_imd”, “da_set_number_samples”
da_print_darray
Prints the contents of a data array. Used mainly for debugging the DARRAY system. Prints
the contents of a DARRAY.
Synopsis
da_print_darray(FILE *outfile, char *label, DARRAY d, int detail)
Arguments
*outfile A file pointer which represents where to write the data. A NULL
pointer is replaced with stdout.
*label A label to identify the DARRAY.
d The DARRAY to print.
detail Higher numbers provide more data. detail == 3 gives
essentially everything including the data.
Returns
The input parameter d.
Side Effects
None
da_pulse
Simulate the sampling of a continuous periodic pulse waveform.
This function creates a new DARRAY with a pulse train corresponding to the parameters you
specify. The DARRAY is allocated as it is in other signal generating functions (such as
da_cosine). The waveform consists of a periodic pulse train of frequency Ft with amplitude,
DC offset, and phase that you specify. The duty cycle parameter is the duration of time into
each period when the pulse transitions from low to high (low being at voltage offset, high
being at amplitude + offset). The wave transitions from high to low at the end of each period.
The phase is specified in radians. The sampling and test frequencies of the new DARRAY are
set by this algorithm.
Synopsis
DARRAY da_pulse(double Fs, da_size_t num_samples, double Ft, double amplitude,
double offset, double duty_cycle, double phase)
Arguments
Fs Sample frequency in the new DARRAY.
num_samples Number of samples in the new DARRAY.
Ft Frequency of the pulse waveform.
Returns
A newly allocated DARRAY containing the pulse waveform. In the case of a run-time error,
DA_NULL is returned without allocating a new DARRAY.
Side Effects
Allocates a new DARRAY.
da_ramp
Simulate the sampling of a continuous periodic ramp waveform.
This function generates and returns a ramp waveform with the parameters you specify. A
new DARRAY is allocated, with num_samples elements. The sampling and test frequencies
of the DARRAY are set. The periodic waveform begins each period at a voltage equal to the
offset parameter, and climbs (or falls) at the rate specified by the slope for the duration of
the period. After each period, there is a discontinuity from the peak of the ramp back to the
original offset. The frequency of the waveform is specified by Ft, and the sampling
frequency by Fs.
Synopsis
double da_ramp(double Fs, da_size_t num_samples, double Ft, double slope,
double offset, double phase)
Arguments
Fs Sample frequency of the array.
num_samples The size of the ramp waveform to generate.
Ft Frequency of the ramp waveform.
slope The slope of the ramp in volts/s.
offset The DC offset of the waveform.
phase The phase angle, in radians.
Returns
A newly allocated DARRAY containing the ramp waveform. In the case of a run-time error,
DA_NULL is returned without allocating a new DARRAY.
Side Effects
Allocates a new DARRAY.
da_ramp_dnl
Calculate the differential nonlinearity of a ramp waveform.
This function calculates differential nonlinearity of converter devices. The input used to drive
the device is a ramp waveform. The reference histogram is a flat line, with value N/M, for N
output samples and M codes.
Synopsis
double da_ramp_dnl(DARRAY input, double full_scale, int num_bits)
Arguments
input Input variable containing the input waveform.
The input data array must contain at least 8 elements. Data type
must be DA_REAL or DA_DREAL.
full_scale The full-scale voltage of the converter device. The range must to
be from 0V to full-scaleV. Value must be a positive voltage.
num_bits The number of bits of the converter device. Value must be a
positive integer.
Returns
The differential nonlinearity of the input waveform in least significant bits. Returns
TL_DA_ERROR in the case of a run-time error.
See Also
“da_ramp_dnl_and_inl”
da_ramp_dnl_and_inl
Calculate the differential and integral nonlinearity of a ramp waveform.
This function calculates differential and integral nonlinearity of converter devices. The input
used to drive the device is a ramp waveform. The reference histogram is a flat line, with
value N/M, for N output samples and M codes. Calling the compound function is more
efficient than calling the two simple functions in sequence.
Synopsis
void da_ramp_dnl_and_inl(DARRAY input, double full_scale, int num_bits,
double *dnl, double *inl)
Arguments
input Input variable containing the input waveform.
The input data array must contain at least 8 elements. Data type
must be DA_REAL or DA_DREAL.
full_scale The full-scale voltage of the converter device. The range must be
from 0V to full-scaleV. Value must be a positive voltage.
num_bits The number of bits of the converter device. Value must be a
positive integer.
*dnl A pointer which represents where to write the dnl. Value must
not be zero.
*inl A pointer which represents where to write the inl. Value must
not be zero.
Side Effects
Writes to the pointers dnl and inl.
See Also
“da_ramp_dnl”, “da_ramp_inl”
da_ramp_inl
Calculate the integral nonlinearity of a ramp waveform.
This function calculates integral nonlinearity of converter devices. The input used to drive
the device is a ramp waveform. The reference histogram is a flat line, with value N/M, for N
output samples and M codes.
Synopsis
double da_ramp_inl(DARRAY input, double full_scale, int num_bits)
Arguments
input Input variable containing the input waveform.
The input data array must contain at least 8 elements. Data type
must be DA_REAL or DA_DREAL.
full_scale The full-scale voltage of the converter device. The range must to
be from 0V to full-scaleV. Value must be a positive voltage.
num_bits The number of bits of the converter device. Value must be a
positive integer.
Returns
The integral nonlinearity of the input waveform in least significant bits. Returns
TL_DA_ERROR in the case of a run-time error.
See Also
“da_ramp_dnl_and_inl”
da_real_to_frac
Vector real to frac2.
The result of this function is a DARRAY handle whose data is the element-wise application to
the input data of the function which converts single precision floating point data to
DA_FRACT2 data. If real_to_fract2(t) is the result of converting the single precision number t
to type DA_FRACT2, then
Synopsis
DARRAY da_real_to_frac(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must
have type DA_REAL.
Returns
In normal operation, the output DARRAY will have the same length as the input DARRAY. It will
have type DA_FRACT2.
Zero is returned in the case of a run-time error which is ignored or continued.
da_rect
Vector polar to rectangular.
The result of this function is a DARRAY whose elements are the rectangular coordinate form
of the input data, interpreting the input data as complex numbers in polar coordinates as for
da_polar:
Synopsis
DARRAY da_rect(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data can be
any type. If data is a noncomplex type, the magnitude is the input
value and the angle is 0.0.
Returns
In normal operation the output DARRAY has the same length as the input DARRAY. It has the
smallest type compatible with the type of the input DARRAY and also with DA_CMPLX. If the
input data array has type DA_DREAL or DA_DCMPLX the output DARRAY will have type
DA_DCMPLX. The output DARRAY will have type DA_CMPLX in all other cases.
NOTE
The input array must be of type COMPLEX.
NOTE
The input and output buffers must be different for this algorithm.
da_rfftsc
In-place FFT scale and format.
This function does not return a value. Instead, it replaces the input data array data by a
scaled and formatted version. This function can perform two different, independent data
manipulations:
• The raw FFT algorithm leaves the frequency domain data larger than it would normally
be by a factor of the length of the (real) time domain data. For example, if 1024 points
of the function cos(2*π*t) are sampled, the expected coefficient in bins 1 and -1 would
be 1/2. However, the FFT function returns 512 in bin 1 and does not return bin -1. The
scaling function corrects this by dividing the size of the time-domain data by half. Also,
when performing a time-domain convolution by a frequency-domain multiplication, a
scale factor of twice the input length is used. The scaling function can provide this as
well.
• When the FFT function operates on a length N real vector, the result is nominally a
length N/2+1 vector of complex numbers. For real input, the output is (almost) half the
length, since the Fourier transform is conjugate symmetric, and the coefficients for the
negative frequencies can be determined from those of the positive frequencies. These
are in the N/2 frequency bins 0 through N/2-1. The extra Fourier coefficient is the
coefficient at the Nyquist frequency. This is always purely real. The formatting
parameter chooses one of three operations:
– Reduce the N/2+1 length vector to one of length N/2 by packing the real part of the
spectrum at Nyquist into the imaginary part of bin 0. This is guaranteed to be zero.
– Unpack the output by putting the imaginary value of bin 0 into a new element at bin
N/2, whose real value is the originally imaginary value at 0 and whose imaginary
value is 0.0. This requires adding to the existing storage, so some data may be
allocated for this operation.
– Reduce the spectrum vector to size N/2 by ignoring the value at Nyquist. In most
normal operation, this is what is wanted, since the input signal will be band-limited,
and there will be little or no signal energy at the Nyquist frequency.
The description of the effect of the scale and format parameters below depends on the
following definitions: in[-] is the data array element value before the execution of the
function, out[-] is the data array element value after the execution of the function, and N is
the length of the input data array after the execution of the function.
• scale parameter
This is the scale flag. It determines a scaling factor sf used by the format flag. Possible
values are -1 to +1. The meanings of these values are
1: sf == 1/(2*N)
0: sf == 1.0 - No scaling is done.
-1: sf == 1/(4*e) - This value is used in the correlation function.
• format parameter
This is the formatting flag. Possible values are -3 to +3. The value of the scaling flag is
set to the scaling factor sf (see above). The basic scheme is:
– A format parameter value of -1, 0, or 1 does no special formatting at all.
– A format parameter value of 2 or -2 unpacks from or packs into N/2 elements.
– A format parameter value of 3 or -3 unpacks from or packs into N/2+1 elements.
– Positive format parameters unpack.
– Negative format parameters pack.
For each value of sf, the output data array is defined as follows:
• 1,0,-1:
out [ 0 ] = sf × in [ 0 ]
(27–59)
out [ N ] = sf × in [ N ]
Synopsis
da_rfftsc(DARRAY h_in, int format, int scale)
Arguments
h_in The input data array may have any length. Data must be a
complex type.
format See description above. This parameter can have any integer
between -3 and 3 inclusive. The symbolic names for the values
of this parameter are:
3: DA_RFFTSC_UNPACKED_LARGE
2: DA_RFFTSC_UNPACKED_SMALL
1,0,-1: DA_RFFTSC_NOCHANGE
-2: DA_RFFTSC_PACKED_SMALL
-3: DA_RFFTSC_PACKED_LARGE
scale See description above. This parameter can have any integer
value between -1 and 2 inclusive. The named constants for
these values are:
2: DA_RFFTSC_SCALE_BY_N
1: DA_RFFTSC_SCALE_BY_2XN
0: DA_RFFTSC_NOSCALE
-1: DA_RFFTSC_SCALE_BY_4XN
Side Effects
The input data array is overwritten. Data type and size can also be changed, depending on
the format flag used.
da_rmmul
Vector matrix multiply.
The DARRAY handle input parameters to this function are vectors which represent a matrix.
The result is a DARRAY handle whose data represent the product of the two input
parameters. For the single-index output vector and the input vectors as matrices, with two
indices
then
Synopsis
DARRAY da_rmmul(DARRAY h_in1, DARRAY h_in2, int rows13, int cols23,
int cols1rows2)
Arguments
h_in1 DARRAY parameters can have any type. The size of input
parameter h_in1 must be no less than rows13*cols1rows2.
h_in2 DARRAY parameters can have any type. The size of input
parameter h_in2 must be no less than cols23*cols1rows2.
rows13 Number of rows in h_in1.
cols23 Number of columns in h_in2.
cols1rows2 Number of columns in h_in1 and rows in h_in2.
Returns
In normal operation, the return value is a DARRAY handle. Its type is the smallest type
compatible with the types of the input vectors. Its length is rows13*cols23 exactly.
Zero is returned in the case of a run-time error which is ignored or continued.
da_rms
Calculate rms voltage of the sample data.
Compute the square root of the average value (mean) of the squares of the elements of a
data array. For a data array with n elements
n
2
∑ xi
rms = i=1 -
--------------- (27–66)
n
Synopsis
double da_rms(DARRAY input)
Arguments
input The input value. The name of variable of type DARRAY which is
the name of the data array containing the input sample data.
Returns
The rms value of the elements of the data array.
da_rmsqv
RMS computation.
The result of this function is the square root of the mean of the squares of the elements in
the input vector
N–1
( in [ n ] ) 2
output = n ∑ --------------------
N
(27–67)
n=0
where in[n] in the nth element, and N is the size of the vector.
Synopsis
double da_rmsqv(DARRAY h_in)
Arguments
h_in The input vector can have any length. Data must be a
noncomplex type.
Returns
A floating point number whose type is double precision.
da_rmtran
Vector matrix transpose.
The DARRAY handle input parameter to this function is a vector which represents a matrix.
The result is a DARRAY handle whose data represent the matrix transpose of a submatrix of
the input matrix. The submatrix is anchored in the upper left corner of the source matrix
(element 0,0).
For the single-index output vector and the input vectors as two-dimensional matrices, with
two indices
in [r ,c ] = in [ r × full_input_columns + c ]
(27–68)
out [r ,c ] = out [ r × full_output_columns + c ]
then
out [r ,c ] = in [c ,r ] (27–69)
Synopsis
DARRAY da_rmtran(DARRAY h_in, int full_input_rows, int full_input_columns,
int submatrix_input_rows, int submatrix_input_columns)
Arguments
h_in The DARRAY parameter can have any type. The DARRAY
parameter must have size greater than
full_input_columns*submatrix_input_rows.
submatrix_input_rows
Number of rows in the submatrix you want to transform.
submatrix_input_columns
Number of columns in the submatrix you want to transform.
Returns
In normal operation, the return value is a DARRAY handle. Its type is the smallest type
compatible with the types of the input vectors. Its length is exactly full_input_columns ×
submatrix_input_rows.
da_set_Fs
Locates the data array referenced by the parameter handle and sets the value of the
sampling frequency.
Synopsis
void da_set_Fs(DARRAY handle, double new_Fs)
Arguments
handle A handle for a data array or the data array name (type DARRAY).
An unsigned integer.
new_Fs Value of new sampling frequency.
da_set_Ft
Locates the data array referenced by handle and sets the value of the fundamental or “test”
frequency.
Synopsis
void da_set_Ft(DARRAY handle, double new_Ft)
Arguments
handle A handle for a data array or the data array name (type DARRAY).
An unsigned integer.
new_Ft Value of new test frequency.
da_set_lifetime
Locates the data array referenced by handle and changes its lifetime by removing it from
one queue and inserting it in another. The data array memory manager structure lock is
used to protect the queues.
Synopsis
void da_set_lifetime(DARRAY *handle,DA_DATA_LIFETIME lifetime)
Arguments
handle Address of the data array handle number.
lifetime How long the data array will persist, one of:
DA_TESTF - Until the end of the TESTF with the compute block
containing the computations using the data array
DA_RUN - Until the test program run is completed
DA_JOB - Until the test program is unloaded
da_set_number_samples
Changes the logical number of samples of the data array. It is used primarily to compensate
for the fact that da_FFT followed by da_power_spectrum reduces the number of real
samples by half (from real plus imaginary samples into complex samples). When the data
array containing the transformed data is copied, the number of samples in the data array is
cut in half. You can use da_set_number_samples to set the correct number of samples.
Synopsis
void da_set_number_samples(DARRAY handle, int number_samples)
Arguments
handle Data array handle
number_samples New number of samples for handle
Side Effects
Modifies handle to reflect the new number of samples.
See Also
“da_fft”, “da_fftb”, “da_power_spectrum”
da_sfdr
Calculate the spurious free dynamic range of the sample data.
This function calculates the spurious free dynamic range of a sampled signal. This is the
ratio of the signal power to the power of the largest harmonic. The fundamental frequency
and sampling frequency are taken from the input data array. The number of harmonics to
consider is the default value (5). The input can be either a spectrum or a power spectrum.
Synopsis
double da_sfdr(DARRAY input)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input sample data.
Returns
The value of the ratio of the signal power to the maximum distortion power.
In the case of errors, or if the maximum noise power is numerically less than the machine
epsilon, the largest double precision floating point value DBL_MAX is returned.
If there are fewer than the specified number of harmonics before the Fs/2 frequency,
da_sfdr considers only those harmonics that occur before Fs/2. However, if the sample is
not band-limited to Fs/2, images of noise and harmonics may interfere with the correct
calculation of the range.
See Also
“da_sfdr_full”
da_sfdr_full
Calculate the spurious free dynamic range of the sample data, with input parameters:
number of harmonics, fundamental frequency, and sample frequency.
This function calculates the spurious free dynamic range of a sampled signal. This is the
ratio of the signal power to the power of the largest harmonic. The fundamental frequency
and sampling frequency are taken from the input DARRAY. The input can be either a
spectrum or a power spectrum.
Synopsis
double da_sfdr_full(DARRAY input, da_size_t number_harmonics, double f_i,
double f_s)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input sample data.
number_harmonics Number of harmonics to consider when looking for the largest
amplitude or power.
f_i Frequency of interest. The fundamental frequency of the input
signal.
f_s Sample rate of the sample data.
Returns
The value of the ratio of the signal power to the maximum distortion power.
In the case of errors, or if the maximum noise power is numerically less than the machine
epsilon, the largest double precision floating point value DBL_MAX is returned.
If there are fewer than the specified number of harmonics before the Fs/2 frequency,
da_sfdr_full considers only those harmonics that occur before Fs/2. However, if the
sample is not band-limited to Fs/2, images of noise and harmonics may interfere with the
correct calculation of the range.
See Also
“da_sfdr”
da_sine_dnl
Calculate the differential nonlinearity of a sine waveform.
This function calculates the differential nonlinearity of a converter device using a sine
waveform input. The device is driven by a sine wave, and the resulting output sine wave is
captured and passed into the function as the input DARRAY. The full-scale voltage of the
device and its number of bits are also specified as parameters.
To calculate differential nonlinearity, a histogram of the input waveform is plotted to count
the number of times each code of the device appears in the output. From this histogram, a
reference histogram is subtracted, one which a theoretical device of zero nonlinearity would
produce. (This reference histogram is deduced by looking at the number of zeros and the
number of maximal codes in the input waveform.) The resulting difference represents a
graph with output codes on the x-axis and difference in occurrence frequency on the y-axis.
The y-axis is scaled and normalized to be in units of least significant bits (1 LSB = voltage
width of one output code of the device). The entry in the scaled graph that has the maximum
magnitude is the differential nonlinearity of the device. Entries with positive sign mean the
code occurred more frequently than expected, negative signs mean less frequently.
Regardless of the sign of the nonlinearity, it is reported as a positive number of least
significant bits.
Synopsis
double da_sine_dnl(DARRAY input, double full_scale, int num_bits)
Arguments
input Input variable containing the input sine wave.
The input data array must contain at least 8 elements. Data type
must be DA_REAL or DA_DREAL.
full_scale The full-scale voltage of the converter device. The range must to
be from 0V to full-scaleV. Value must be a positive voltage.
num_bits The number of bits of the converter device. Value must be a
positive integer.
Returns
The differential nonlinearity of the input waveform in least significant bits. Returns zero in
the case of a run-time error.
See Also
“da_sine_dnl_and_inl”
da_sine_dnl_and_inl
Calculate the differential and integral nonlinearity of a sine waveform.
This function calculates the differential and integral nonlinearity of a converter device using
a sine waveform input. The device is driven by a sine wave, and the resulting output sine
wave is captured and passed into the function as the input DARRAY. The full-scale voltage of
the device and its number of bits are also specified as parameters.
Calling the compound function is more efficient than calling the two simple functions in
sequence.
To calculate differential nonlinearity, a histogram of the input waveform is plotted to count
the number of times each code of the device appears in the output. From this histogram, a
reference histogram is subtracted, one which a theoretical device of zero nonlinearity would
produce. (This reference histogram is deduced by looking at the number of zeros and the
number of maximal codes in the input waveform.) The resulting difference represents a
graph with output codes on the x-axis and difference in occurrence frequency on the y-axis.
The y-axis is scaled and normalized to be in units of least significant bits (1 LSB = voltage
width of one output code of the device). The entry in the scaled graph that has the maximum
magnitude is the differential nonlinearity of the device. Entries with positive sign mean the
code occurred more frequently than expected, negative signs mean less frequently.
Regardless of the sign of the nonlinearity, it is reported as a positive number of least
significant bits.
Integral nonlinearity is related to differential nonlinearity. To calculate integral nonlinearity,
you start with the differential nonlinearity graph and construct a second graph by keeping a
running-sum total of the entries in the first. In effect, the second is the integral of the first.
The maximum magnitude of the integral graph is the integral nonlinearity. It is returned in
positive least significant bits.
Synopsis
void da_sine_dnl_and_inl(DARRAY input, double full_scale, int num_bits,
double *dnl, double *inl)
Arguments
input Input variable containing the input waveform.
The input data array must contain at least 8 elements. Data type
must be DA_REAL or DA_DREAL.
full_scale The full-scale voltage of the converter device. The range must be
from 0V to full-scaleV. Value must be a positive voltage.
num_bits The number of bits of the converter device. Value must be a
positive integer.
*dnl A pointer which represents where to write the dnl. Value must
not be zero.
*inl A pointer which represents where to write the inl. Value must
not be zero.
Side Effects
Writes to the pointers dnl and inl.
See Also
“da_sine_dnl”, “da_sine_inl”
da_sine_inl
Calculate the integral nonlinearity of a sine waveform.
This function calculates the integral nonlinearity of a converter device using a sine
waveform input. The device is driven by a sine wave, and the resulting output sine wave is
captured and passed into the function as the input DARRAY. The full-scale voltage of the
device and its number of bits are also specified as parameters.
Integral nonlinearity is related to differential nonlinearity. To calculate integral nonlinearity,
you start with the differential nonlinearity graph and construct a second graph by keeping a
running-sum total of the entries in the first. In effect, the second is the integral of the first.
The maximum magnitude of this integral graph is the integral nonlinearity. It is returned in
positive least significant bits.
Synopsis
double da_sine_inl(DARRAY input, double full_scale, int num_bits)
Arguments
input Input variable containing the input waveform.
The input data array must contain at least 8 elements. Data type
must be DA_REAL or DA_DREAL.
full_scale The full-scale voltage of the converter device. The range must be
from 0V to full-scaleV. Value must be a positive voltage.
num_bits The number of bits of the converter device. Value must be a
positive integer.
Returns
The integral nonlinearity of the waveform in least significant bits. Returns zero in the case
of a run-time error.
See Also
“da_sine_dnl_and_inl”
da_snr
Calculate the signal-to-noise ratio of the spectrum.
The input must be in the frequency domain. The test and sampling frequencies must be
known in the input data array. The noise is computed by summing the power of all
nonharmonic bins of the spectrum. The number of harmonics to consider is the default value
(5). The signal is the power in the test frequency bin. The output is a double precision
number (DA_DREAL).
Synopsis
double da_snr(DARRAY input)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input spectrum data.
Returns
The signal-to-noise ratio.
In the case of error, the largest double precision value DBL_MAX is returned.
If there are fewer than the specified number of harmonics before the Fs/2 frequency,
da_snr_full includes only those harmonics that occur before Fs/2. However, if the sample
is not band-limited to Fs/2, images of noise and harmonics may interfere with the correct
calculation of the ratio.
See Also
“da_snr_full”
da_snr_full
Calculate the signal-to-noise ratio of the spectrum, with input parameters: test frequency,
sample frequency, and number of harmonics.
The input must be in the frequency domain. The test and sampling frequencies must be
specified as input parameters. The noise is computed by summing the power of all
nonharmonic bins of the spectrum. The number of harmonics to consider is specified by the
parameter number_harmonics. The signal is the power in the test frequency bin. The output
is a double precision number (DA_DREAL).
Synopsis
double da_snr_full(DARRAY input, da_size_t number_harmonics, double Ft,
double Fs)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input spectrum data.
number_harmonics Number of harmonics to exclude from noise power.
Returns
The signal-to-noise ratio.
In the case of error, the largest double precision value DBL_MAX is returned.
If there are fewer than the specified number of harmonics before the Fs/2 frequency,
da_snr_full includes only those harmonics that occur before Fs/2. However, if the sample is
not band-limited to Fs/2, images of noise and harmonics may interfere with the correct
calculation of the ratio.
See Also
“da_snr”
da_spdp
Vector float to double.
The result of this function is a data array whose data is the element-wise application to the
input data of the function which converts single precision floating point numbers to double
precision floating point numbers
Synopsis
DARRAY da_spdp(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
type DA_REAL.
Returns
In normal operation, the output DARRAY has the same length as the input DARRAY. Data type
is always DA_DREAL.
Zero is returned in the case of a run-time error which is ignored or continued.
da_sve
Sum of vector elements.
This function computes the sum of the elements of the input vector:
Synopsis
double da_sve(DARRAY h_in)
Arguments
h_in The input data must be a noncomplex type.
Returns
The return value is always a double precision floating point number.
Zero is returned in the case of a run-time error which is ignored or continued.
da_svemg
Sum of element magnitudes.
This function computes the sum of the magnitudes of the elements of the input vector
Synopsis
double da_svemg(DARRAY h_in)
Arguments
h_in The input data array can have any length. Data must be a
noncomplex type.
Returns
A double precision floating point number.
Zero is returned in the case of a run-time error which is ignored or continued.
da_svesq
Sum of element squares.
This function computes the sum of the squares of the elements of the input vector
Synopsis
double da_svesq(DARRAY h_in)
Arguments
h_in The input data array can have any length. Data must be a
noncomplex type.
Returns
A double precision floating point number.
Zero is returned in the case of a run-time error which is ignored or continued.
da_svessq
Sum of element signed squares.
This function computes the sum of the signed square function of element. The signed
squared function is the product of the element’s sign and its square. It can also be
expressed as the product of the element and its absolute value
Synopsis
double da_svessq(DARRAY h_in)
Arguments
h_in The input data must be a noncomplex type.
Returns
A double precision floating point number.
Zero is returned in the case of a run-time error which is ignored or continued.
da_thd
Calculate total harmonic distortion.
The total harmonic distortion is the ratio of the signal power to the sum of the power in the
first five harmonics. The test frequency and sampling frequencies are obtained from the
input data array. The input data array can be either a spectrum or a power spectrum.
Synopsis
double da_thd(DARRAY input)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input spectrum data.
Returns
The total harmonic distortion, expressed as a ratio.
In the case of errors, or if the distortion is less than the machine epsilon, the largest double
precision floating point value DBL_MAX is returned. If there are fewer than five harmonics
before the Fs/2 frequency, da_thd includes only those harmonics that occur before Fs/2.
However, if the sample is not band-limited to Fs/2, images of noise and harmonics may
interfere with the correct calculation of the distortion.
See Also
“da_thd_full”, “da_phase_full”
da_thd_full
Calculate total harmonic distortion, with input parameters: test frequency, sample
frequency, and number of harmonics.
The total harmonic distortion is the ratio of the signal power to the sum of the power in the
harmonics specified by the parameter number_harmonics. The test frequency and
sampling frequencies are specified as input parameters. The input DARRAY can be either a
spectrum or a power spectrum.
Synopsis
double da_thd_full(DARRAY input, da_size_t number_harmonics, double Ft,
double Fs)
Arguments
input Input variable. The name of the variable of type DARRAY which
contains the input spectrum data.
number_harmonics Number of harmonics to include in distortion power.
Ft The fundamental frequency of the signal spectrum.
Fs The sample frequency of the sample data.
Returns
The total harmonic distortion, expressed as a ratio.
In the case of errors, or if the distortion is less than the machine epsilon, the largest double
precision floating point value DBL_MAX is returned. If there are fewer than the specified
number of harmonics before the Fs/2 frequency, da_thd_full includes only those
harmonics that occur before Fs/2. However, if the sample is not band-limited to Fs/2,
images of noise and harmonics may interfere with the correct calculation of the distortion.
See Also
“da_thd”
da_triangle
Simulate the sampling of a periodic triangle waveform.
This function creates a new DARRAY with a triangle waveform corresponding to the given
parameters. This function is similar to da_cosine. Specifically, a triangle waveform of
period 2*π would have value 1 at t = 0, value 0 at t = π / 2, value -1 at t = π, value 0 at t =
3*π / 2, and value 1 at t = 2*π, exactly like a cosine wave. However, these points would be
connected with straight lines, rather than the curve of the cosine.
The algorithm generates the triangle waveform information and fills a newly allocated
DARRAY with the data for the current site. It also sets the sample and test frequency in the
internal structure of the DARRAY.
Synopsis
DARRAY da_triangle(double Fs, da_size_t num_samples, double Ft,
double amplitude, double offset, double phase)
Arguments
Fs Sample frequency in the new DARRAY.
num_samples The number of samples in the new DARRAY.
Ft Frequency of the triangle waveform.
amplitude The peak-to-peak amplitude of the triangle waveform.
offset Offset of the triangle waveform.
phase Phase angle (in radians) of the triangle waveform.
Returns
A newly allocated DARRAY containing the output waveform. In the case of a run-time error,
DA_NULL is returned without allocating a new DARRAY.
Side Effects
Allocates a new DARRAY.
da_triangular_window
Triangular window function.
This name denotes the triangular window function. It is not a callable function. It is only used
as a parameter to da_complex_spectrum. The triangular window is defined by
if (i < N/2) then
data[i] *= 2*(i/N)
else
data[i] *= 2*((N-i)/N
where N is the size of the data vector.
Synopsis
da_window_function da_triangular_window
See Also
“da_3rd_order_imd”
da_vabs
Vector absolute value.
This function returns the handle of a DARRAY whose elements are the element-wise
application of the absolute value function to the input vector
out [ n ] = in [ n ] (27–75)
Synopsis
DARRAY da_vabs(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type.
Returns
In normal operation, the output is a DARRAY handle whose type is the smallest type
compatible with the input DARRAY type and DA_REAL. That is, the output type is DA_DREAL if
one the input parameter is DA_DREAL and DA_REAL otherwise. Its length is the length of the
input vector.
da_vadd
Vector add.
This function returns the handle of a data array whose elements are the element-wise
application of the arithmetic addition function to the input vector
Synopsis
DARRAY da_vadd(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The first input data array length equal the second data array
length. Data in each data array can be any type.
h_in2 The second input data array length equal the first data array
length. Data in each data array can be any type.
Returns
In normal operation, the output data type is the smallest type compatible with the two input
types and also with DA_REAL:
• DA_DCMPLX if one or more parameters are complex, and one or more parameters are
double precision
• DA_CMPLX if one or more parameters are complex, and no parameters are double
precision
• DA_DREAL if neither parameter is complex, and one or both parameters are double
precision
• DA_REAL if neither parameter is complex, and neither parameter is double precision.
da_vam
Vector add and multiply.
The result of this function is a data array containing elements defined by
Synopsis
DARRAY da_vam(DARRAY h_in1, DARRAY h_in2, DARRAY h_in3)
Arguments
h_in1 The first input data array must have a noncomplex type. All input
data arrays must all have the same length.
h_in2 The second input data array must have a noncomplex type. All
input data arrays must all have the same length.
h_in3 The third input data array must have a noncomplex type. All input
data arrays must all have the same length.
Returns
In normal operation, the output is a DARRAY handle which has the same length as the input
DARRAYs. The output type is the smallest type compatible with the types of both the input
DARRAYs and also with DA_REAL. The output type is DA_DREAL if either of the types of the
input DARRAYs are DA_DREAL and DA_REAL otherwise.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vandi
Bitwise logical AND.
This function returns the handle of a data array whose elements are the element-wise
application of the conjunction function to the input vector
Synopsis
DARRAY da_vandi(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The two input vectors h_in1 and h_in2 must have equal
lengths. Data must be type DA_INT.
h_in2 The two input vectors h_in1 and h_in2 must have equal
lengths. Data must be type DA_INT.
Returns
In normal operation, the output DARRAY type is DA_INT. Output data array length is equal to
the length of either input vector, both of which must be equal.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vatan
Vector arctangent.
This function returns a DARRAY whose data are the element-wise application of the
arctangent function to the input DARRAY’s data.
If atan(t) is the arctangent of t, then
Synopsis
DARRAY da_vatan(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type.
Returns
In normal operation, the output data array will have the same length as the input. It will have
the smallest type compatible with the input data type and also DA_REAL. The output type is
DA_DREAL if the input is DA_DREAL and DA_REAL in all other cases.
See Also
“da_vatan2”
da_vatan2
Vector arctangent of ratio.
This function returns a DARRAY handle whose data is the element-wise application of the
atan2 function to the two input vectors. The atan2 function takes two parameters, y and x in
this order, and computes the arctangent of y/x
If, for example, V is a vector of points in the plane, whose y coordinates are h_in1 and
whose x coordinates are h_in2, then da_vatan2(h_in1, h_in2) would be the angles
made between the x axis and the lines from the origin to the points.
The atan2 function returns the standard math library results, with values between -π and +π.
Synopsis
DARRAY da_vatan2(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The first input data array length must be greater than 0. The
length of h_in1 must equal the length of h_in2. Data must be a
noncomplex type.
h_in2 The second input data array length must be greater than 0. The
length of h_in1 must equal the length of h_in2. Data must be a
noncomplex type.
Returns
In normal operation, the output DARRAY length is that of the two input DARRAYs. The output
type is the smallest type compatible with the types of the two input DARRAYs and also with
DA_REAL. The output type is DA_DREAL if either of the two input DARRAYs have type DA_DREAL
and DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vclip
Vector clip.
The result of this function is a data array handle whose data is the element-wise application
of the clipping function
Synopsis
DARRAY da_vclip(DARRAY h_in, double min, double max)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type.
min The lower clip limit. Data point must be double precision floating
point.
max The upper clip limit. Data point must be double precision floating
point.
Returns
The output DARRAY has the same length as the input DARRAY. The output DARRAY type is the
smallest type compatible with both the input DARRAY type and also with DA_REAL.
da_vclr
Vector clear.
This function returns no value. It sets each element of the input data array to zero
in [ n ] = 0 (27–83)
Synopsis
da_vclr(DARRAY h_in)
Arguments
h_in The input data array can have any length. Data must be a
floating point type: DA_REAL or DA_DREAL.
Side Effects
The data in the input data array is modified.
da_vcopy
Copy and subsample.
The output data array is whose type is the same as the input vector, whose size is the
parameter output_size and whose elements are given by
Synopsis
DARRAY da_vcopy(DARRAY h_in, int offset, int stride, int output_size)
Arguments
The values of the offset, stride, and output_size parameters must satisfy the following
inequality:
Returns
The return value has the given output size. It has the same type as the DARRAY input
parameter h_in.
da_vcos
Vector cosine.
This function returns a DARRAY handle whose data is the element-wise application of the
cosine function to the input data
Synopsis
DARRAY da_vcos(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type.
Returns
In normal operation, the output DARRAY will have the same length as the input. It will have
the smallest type compatible with the input data type and also DA_REAL. The output type is
DA_DREAL if the input is DA_DREAL and DA_REAL in all other cases.
da_vdiv
Vector divide.
This function returns the handle of a DARRAY whose elements are the element-wise
application of the arithmetic division function to the input vectors
Synopsis
DARRAY da_vdiv(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The first input data array length must equal the length of the
second. Data must be a noncomplex type.
h_in2 The second input data array length must equal the length of the
first. Data must be a noncomplex type.
Returns
In normal operation, the output is a DARRAY handle whose type is the smallest type
compatible with both types of the input DARRAYs and with DA_REAL. The output type is
DA_DREAL if either of the input vectors have type DA_DREAL and DA_REAL in all other cases.
Its length is the length of the two input vectors.
Zero is returned in the case of a run-time error which is ignored or continued.
da_veqvi
Bitwise logical equality.
The operator equiv computes the bitwise equality of its operands. For each bit position p
from 0 to 31, the value of out[n] at bit p is 1 exactly when the values of in_1[n] and in_2[n]
at bit p are the same, and 0 if they are different
Synopsis
DARRAY da_veqvi(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The first input data array length must equal the length of the
second. Data must be type DA_INT.
h_in2 The second input data array length must equal the length of the
first. Data must be type DA_INT.
Returns
In normal operation, the output data type is always DA_INT. Its length is the length of the
input vector.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vexp
Vector natural exponent.
This function returns the handle of a data array whose elements are the element-wise
application of the real exponential function to the real input vector
out [ n ] = e in [ n ] (27–89)
Synopsis
DARRAY da_vexp(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type. Each input element must have a value at
which the exponential is defined for the given type.
Returns
In normal operation, the output is a DARRAY handle which has the same length as the input
vector. Its type is the smallest type compatible with the type input of the input DARRAY, and
with DA_REAL. The output type is DA_DREAL if the type of the input DARRAY vector is
DA_DREAL and DA_REAL in all other cases.
da_vexp10
Vector base-10 exponent.
This function returns a DARRAY handle whose data is the application of the common antilog
function to each input element
out [ n ] = 10 in [ n ] (27–90)
Synopsis
DARRAY da_vexp10(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type. Each input element must have a value at
which the base 10 antilog is representable with the appropriate
numeric precision.
Returns
In normal operation, the return DARRAY will have the same length as the input DARRAY. The
type of the output will be the smallest type compatible with the input an with DA_REAL. The
output will be DA_DREAL if the input is DA_DREAL and DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vfill
Vector fill.
This function does not return a value. It fills the input data array with the constant value given
by the parameter fill:
in [ n ] = fill (27–91)
Synopsis
da_vfill(DARRAY h_in, double fill)
Arguments
h_in The input data array length must be greater than 0. Data must be
a floating point type: DA_REAL or DA_DREAL.
fill The constant value to be stored in each element of the data
array. Must be a double precision floating point number.
da_vfix
Vector real to integer.
The result of this function is a data array whose data is the element-wise application to the
input DARRAY data, of the function which converts single or double precision floating point
data to DA_INT.
Synopsis
DARRAY da_vfix(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex floating-point type: DA_REAL or DA_DREAL.
Returns
In normal operation, the output data array has the length of the input data array. Data will
be type DA_INT.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vfloat
Vector integer to float.
The result of this function is a DARRAY handle whose data is the element-wise application to
the input DARRAY data of the function which converts from integer to single precision floating
point
Synopsis
DARRAY da_vfloat(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data type
must be DA_INT.
Returns
In normal operation, the output data type is always DA_REAL. Output data array length is the
length of the input data array.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vfloatd
Vector integer to double.
The result of this function is a data array containing double precision floating point data
which was converted from integer input data
Synopsis
DARRAY da_vfloatd(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must
have type DA_INT.
Returns
In normal operation, the output data type is DA_DREAL. Output data array length is the length
of the input data array.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vifix
Vector fix to integer.
The result of this function is a data array containing integer data which was converted from
single precision floating point input data
Synopsis
DARRAY da_vifix(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
type DA_REAL.
Returns
In normal operation, the output data array has the same length as the input DARRAY. Output
data type is DA_INT.
da_vimag
Extract imaginary components.
The result of this function is a data array whose data is the element-wise application of the
imaginary part projection function to the input data
Synopsis
DARRAY da_vimag(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a complex type.
Returns
In normal operation, the output has the same length as the input DARRAY. The output type
is DA_DREAL if the input type is DA_DCMPLX and is DA_REAL if the input type is DA_CMPLX.
da_vlim
Vector limit.
The result of this function is a DARRAY handle whose data is the element wise application to
the input DARRAY’s data, of the limit function:
Synopsis
DARRAY da_vlim(DARRAY h_in, double threshold, double replacement)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type.
threshold The value against which input data is compared. The value must
be a double precision floating point number.
replacement The value used to replace elements of the input data array based
on comparison to threshold. The value must be a double
precision floating point value.
Returns
In normal operation, the length of the output data array is the length of the input data array.
The type of the output data is the smallest type compatible with the type of the DARRAY input,
h_in, and also with DA_REAL.
da_vlog
Vector natural log.
This function results in a data array whose data is the application of the natural logarithm
function to each of the input vector’s elements
out [ n ] = ln ( in [ n ] ) (27–98)
Synopsis
DARRAY da_vlog(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type.
Returns
In normal operation, the output data array has the same length as the input data array. The
output type is the smallest type compatible with the input type and also with DA_REAL. The
output type is DA_DREAL if the input type is DA_DREAL and DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vlog10
Vector base-10 log.
This function returns a DARRAY handle whose data is the element-wise application of the
common, or base-10 logarithm to the input vector. That is, if log(t) is the common logarithm
of t, then out[n] = log(in[n]) for each index n.
Synopsis
DARRAY da_vlog10(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must
have a noncomplex type.
Returns
In normal operation, the output data array will have the same length as the input data array.
It will have the smallest type compatible with the input data type and also DA_REAL. The
output type is DA_DREAL if the input is DA_DREAL and DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vma
Vector multiply and add.
The output is a DARRAY handle whose elements are defined by the rule
Synopsis
DARRAY da_vma(DARRAY h_in1, DARRAY h_in2, DARRAY h_in3)
Arguments
h_in1 The input data arrays must all be the same length. Data must be
a noncomplex type.
h_in2 The input data arrays must all be the same length. Data must be
a noncomplex type.
h_in3 The input data arrays must all be the same length. Data must be
a noncomplex type.
Returns
In normal operation, the output is a handle for a data array which has the same length as
the input data arrays. The output type is the smallest type compatible with the types of all
three input data arrays and also with DA_REAL. The output type is DA_DREAL if any of the
input data array data is type DA_DREAL and DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vmax
Vector maximum.
This function returns the handle of a data array whose elements are the element-wise
application of the maximum function to the input vectors
Synopsis
DARRAY da_vmax(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data arrays must have the same length. Data must be
a noncomplex type.
h_in2 The input data arrays must have the same length. Data must be
a noncomplex type.
Returns
In normal operation, the output data type is the smallest type compatible with the input types
and DA_REAL. It is DA_DREAL if one of the input parameters is DA_DREAL and DA_REAL
otherwise. The output data array length is the length of the input data array.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vmaxmg
Vector maximum magnitude.
This function returns the handle of a data array whose elements are the element-wise
application of the maximum magnitude function to the input vector
for each index n, where |x| is the absolute value of x, and max(x,y) is the maximum function
Synopsis
DARRAY da_vmaxmg(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data arrays must have the same length. Data must be
a noncomplex type.
h_in2 The input data arrays must have the same length. Data must be
a noncomplex type.
Returns
In normal operation, the output data type is the smallest type compatible with the two input
types, and DA_REAL. It is DA_DREAL if one of the input parameters is DA_DREAL and DA_REAL
otherwise. Output data array length is the length of the input vector.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vmin
Vector minimum.
This function returns the handle of a data array whose elements are the element-wise
application of the minimum function to the input vector
Synopsis
DARRAY da_vmin(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data arrays must have the same length. Data must be
a noncomplex type.
h_in2 The input data arrays must have the same length. Data must be
a noncomplex type.
Returns
In normal operation, the output data type is the smallest type compatible with the types of
the input data and with DA_REAL. It is DA_DREAL if one of the input parameters has type
DA_DREAL and DA_REAL otherwise. Output data array length is the length of the input data
array.
da_vminmg
Vector maximum magnitude.
This function returns the handle of a data array whose elements are the element-wise
application of the minimum magnitude function to the input vector
for each index n, where |x| is the absolute value of x, or magnitude function and min(x,y) is
the minimum function
Synopsis
DARRAY da_vminmg(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data arrays must have the same length. Data must be
a noncomplex type.
h_in2 The input data arrays must have the same length. Data must be
a noncomplex type.
Returns
In normal operation, the output data type is the smallest type compatible with the input data
type and also with DA_REAL. The output type is DA_DREAL if one of the input parameters is
DA_DREAL and DA_REAL otherwise. Output data array length is the length of the input data
array.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vmsa
Vector multiply scalar add.
The result of this function is a data array whose elements are defined by
Synopsis
DARRAY da_vmsa(DARRAY h_in1, DARRAY h_in2, double scalar)
Arguments
h_in1 The input data arrays must have the same length. Data must be
a noncomplex type.
h_in2 The input data arrays must have the same length. Data must be
a noncomplex type.
scalar A scalar value added to a vector product. The scalar input value
must be a double precision floating point number.
Returns
In normal operation, the output data array length is the same length as the input data arrays.
Output data type is the smallest type compatible with the types of the two data array inputs
and also with DA_REAL. The output type is DA_DREAL if either of the types of the input data
are DA_DREAL and DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vmsb
Vector multiply and subtract.
The output is a data array whose elements are defined by
Synopsis
DARRAY da_vmsb(DARRAY h_in1, DARRAY h_in2, DARRAY h_in3)
Arguments
h_in1 The input data arrays must all have the same length. Data must
be a noncomplex type.
h_in2 The input data arrays must all have the same length. Data must
be a noncomplex type.
h_in3 The input data arrays must all have the same length. Data must
be a noncomplex type.
Returns
In normal operation, the output is a data array which has the same length as the input data
arrays. The output type is the smallest type compatible with all three input types and also
with DA_REAL. The output type is DA_DREAL if any of the data of the input data arrays is
DA_DREAL and DA_REAL in all other cases.
da_vmul
Vector multiply.
This function returns the handle of a DARRAY whose elements are the element-wise
application of the arithmetic multiplication function to the input vector
for each index n, where complex_conjugate(a+jb) denotes the complex conjugate, a-jb.
Synopsis
DARRAY da_vmul(DARRAY h_in1, DARRAY h_in2, int option_flag)
Arguments
h_in1 The input data arrays must have the same length. Data can be
any type.
h_in2 The input data arrays must have the same length. Data can be
any type.
option_flag Controls whether the computation uses the complex conjugate
of the elements of the second input data array. Value must be an
integer.
option_flag = 1 causes multiplication by in2[n].
option_flag = -1 causes multiplication by the complex
conjugate of in2[n].
Returns
In normal operation, the output value is a data array whose length is the length of the input
data arrays. Its type is the smallest type compatible with the types of the input parameters
and also with DA_REAL.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vneg
Vector negate.
This function returns the handle of a DARRAY whose elements are the element-wise
application of the arithmetic negation function to the input vector
out [ n ] = - in [ n ] (27–111)
Synopsis
DARRAY da_vneg(DARRAY h_in)
Arguments
h_in The input vector can have any length. Data must be a
noncomplex type.
Returns
In normal operation, the output data type is the smallest type compatible with both the type
of the input data and DA_REAL. The output type is DA_DREAL if one of the input parameters
is DA_DREAL and DA_REAL otherwise. Output data array length is the length of the input data
array.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vori
Bitwise logical OR.
This function returns the handle of a data array whose elements are the element-wise
application of the disjunction function to the input vector
Synopsis
DARRAY da_vori(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data arrays must have the same lengths. Data must be
type DA_INT.
h_in2 The input data arrays must have the same lengths. Data must be
type DA_INT.
Returns
In normal operation, the output data type is DA_INT. Output data array length is the length
of the input data array.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vpoly
Vector polynomial.
The result of this function is a data array whose data is the result of evaluating a polynomial
whose coefficients are given by the first data array, at the points given by the second data
array
out [ n ] = in1 [ 0 ]
+ in1 [ 1 ] × in2 [ n ]
+ in1 [ 2 ] × in2 [ n ] 2
(27–113)
+ ...
+ in1 [ order – 1 ] × in2 [ n ] ( order – 1 )
+ in1 [ 1 ] × in2 [ n ]
Synopsis
DARRAY da_vpoly(DARRAY h_in1, DARRAY h_in2, int order)
Arguments
h_in1 Coefficients of the polynomial. The input data array length must
be greater than 0. Data must be a noncomplex type.
h_in2 Points at which the polynomial is evaluated. The input data array
length must be greater than 0. Data must be a noncomplex type.
order Order of the polynomial being evaluated. Value must be an
integer.
Returns
In normal operation, the length of the output data array is the length of the second input data
array. The type of the output data is the smallest type compatible with the types of the two
input data arrays and also with DA_REAL. The output type is DA_DREAL if either of input data
array has data of type DA_DREAL and DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vramp
Vector ramp.
The result of this function is a data array containing elements with values that increase (or
decrease) linearly from the initial value to the final value determined by parameters
initial, increment, and size:
Synopsis
DARRAY da_vramp(double initial, double increment, int size)
Arguments
initial The initial value of the ramp. Value must be a double precision
floating point number.
increment The increment between values of the ramp. Value must be a
double precision floating point number.
size The number of elements or length of the data array containing
the ramp. Value must be an integer.
Returns
The return value’s length is the given size. Output data type is DA_DREAL.
da_vreal
Extract real components.
This function returns a data array containing data generated by the element-wise
application of the real part projection function to the input data
Synopsis
DARRAY da_vreal(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a complex type.
Returns
In normal operation, the output data array has the same length as the input data array. The
output data is type is DA_DREAL if the input type is DA_DCMPLX and is DA_REAL if the input
type is DA_CMPLX.
da_vrvrs
In-place reverse order.
This function does not return a value. It reverses the order of the data elements in the input
data array
for each index n, where |h_in| is the length of the input data array.
Synopsis
da_vrvrs(DARRAY h_in)
Arguments
h_in The input data array can have any length. Data must be a
floating point type: DA_REAL or DA_DREAL. This type and length
are not changed.
Side Effects
The input vector is modified.
da_vsadd
Scalar add.
The result of this function is a data array whose data elements are the result of adding the
specified scalar to each of the elements of the input vector
Synopsis
DARRAY da_vsadd(DARRAY h_in, double scalar)
Arguments
h_in The input data array can have any length. Data must be a
noncomplex type.
scalar The scalar value added to each element of the array. The scalar
value must be a double precision floating point number.
Returns
In normal operation, the return value is a data array whose length is the length of the input
data array. Output data type is the smallest type compatible with the types of the input
parameters and with DA_REAL. It is DA_DREAL if the input data is type DA_DREAL and DA_REAL
in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vsbm
Vector subtract and multiply.
The result of this function is a data array whose elements are defined by the rule
Synopsis
DARRAY da_vsbm(DARRAY h_in1, DARRAY h_in2, DARRAY h_in3)
Arguments
h_in1 The input data arrays must all have the same length. Data must
be a noncomplex type.
h_in2 The input data arrays must all have the same length. Data must
be a noncomplex type.
h_in3 The input data arrays must all have the same length. Data must
be a noncomplex type.
Returns
In normal operation, the output is a data array which has the same length as the input data
arrays. The data type is the smallest type compatible with the types of the three input data
arrays and also with DA_REAL. The output type is DA_DREAL if any of the types of the input
data are DA_DREAL and DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vsdiv
Scalar divide.
The result of this function is a data array whose data elements are the result of dividing each
of the elements of the input vector by the specified scalar
Synopsis
DARRAY da_vsdiv(DARRAY h_in, double scalar)
Arguments
h_in The input data array can have any length. Data must be a
noncomplex type.
scalar The specified divisor of each element of the data array. The
value must be a double precision floating point number.
Returns
In normal operation, the return value is a handle for a data array whose length is the length
of the input data array. Output data type is the smallest type compatible with the input data
array and DA_REAL. The output type is DA_DREAL if the input data has type DA_DREAL and
DA_REAL in all other cases.
da_vsin
Vector sine.
This function returns a data array whose data is the element-wise application of the sine
function to the input data
Synopsis
DARRAY da_vsin(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type.
Returns
In normal operation, the output data array will have the same length as the input data array.
Output data will have the smallest type compatible with the input data type and DA_REAL.
The output type is DA_DREAL if the input is DA_DREAL and DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vsma
Vector scalar multiply and vector add.
The result of this function is a data array whose elements are defined by the rule
Synopsis
DARRAY da_vsma(DARRAY h_in1, double scalar, DARRAY h_in2)
Arguments
h_in1 The input data arrays must have the same lengths. Data must be
a noncomplex type.
scalar The specified multiplier for each element of the input data array.
The value must be a double precision floating point number.
h_in2 The input data arrays must have the same lengths. Data must be
a noncomplex type.
Returns
In normal operation, the output is a data array which has the same length as the input data
arrays. Output data type is the smallest type compatible with the two inputs and DA_REAL.
The output type is DA_DREAL if either of the types of the input data arrays are DA_DREAL and
is DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vsmsa
Scalar multiply scalar add.
The result of this function is a data array whose elements are defined by
Synopsis
DARRAY da_vsmsa(DARRAY h_in, double scalar1, double scalar2)
Arguments
h_in The input data array can have any length. Data must be a
noncomplex type.
scalar1 The specified multiplier for each element of the input data array.
The value must be a double precision floating point number.
Returns
In normal operation, the output is a data array which has the same length as the input data
array. The type of the output data is the smallest type compatible with the input data type
and DA_REAL. The input type is DA_DREAL if either of the types of the input data array are
DA_DREAL and DA_REAL in all other cases.
da_vsmsb
Vector scalar multiply and vector subtract.
The result of this function is a DARRAY handle whose elements are defined by
Synopsis
DARRAY da_vsmsb(DARRAY h_in1, double scalar, DARRAY h_in2)
Arguments
h_in1 The input data arrays must have the same lengths. Data must be
a noncomplex type.
scalar The specified multiplier for each element of the input data array.
The value must be a double precision floating point number.
h_in2 The input data arrays must have the same lengths. Data must be
a noncomplex type.
Returns
In normal operation, the output is a data array which has the same length as the input data
arrays. The output data is the smallest type compatible with the two inputs and DA_REAL.
The output type is DA_DREAL if either of the input data types are DA_DREAL and DA_REAL in
all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vsmul
Scalar multiply.
The result of this function is a data array whose data elements are the result of multiplying
to each of the elements of the input vector by the specified scalar
Synopsis
DARRAY da_vsmul(DARRAY h_in, double scalar)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type.
scalar The specified multiplier for each element of the input data array.
The value must be a double precision floating point number.
Returns
In normal operation, the return value is a data array whose length is the length of the input
data array. The output data is the smallest type compatible with the type of the input data
and DA_REAL. It is DA_DREAL if the type of the input data is DA_DREAL and DA_REAL in all
other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vsq
Vector square.
This function returns a DARRAY handle whose data is the element-wise application of the
squaring function to the input data
out [ n ] = in [ n ] × in [ n ] (27–125)
Synopsis
DARRAY da_vsq(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type.
Returns
In normal operation, the output data array will have the same length as the input data array.
The output data will have the smallest type compatible with the input data type and DA_REAL.
The output type is DA_DREAL if the input is DA_DREAL and DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vsqrt
Vector square root.
This function returns a data array whose data is the element-wise application of the square
root function to each element of the input data
out [ n ] = in [ n ]
(27–126)
out [ n ] ≥ 0
Synopsis
DARRAY da_vsqrt(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type.
Returns
In normal operation, the output data array will have the same length as the input data array.
The output data will have the smallest type compatible with the input data type and DA_REAL.
The output type is DA_DREAL if the input is DA_DREAL and DA_REAL in all other cases.
Zero is returned in the case of a run-time error which is ignored or continued.
da_vssq
Vector signed square.
This function returns a data array whose data is the element-wise application of the signed
square function to each element of the input data
out [ n ] = in [ n ] × in [ n ] (27–127)
Synopsis
DARRAY da_vssq(DARRAY h_in)
Arguments
h_in The input data array length must be greater than 0. Data must be
a noncomplex type.
Returns
In normal operation, the output data array will have the same length as the input data array.
The output data will have the smallest type compatible with the input data type and DA_REAL.
The output type is DA_DREAL if the input is DA_DREAL and DA_REAL in all other cases.
da_vsub
Vector subtract.
This function returns the handle of a data array whose elements are the element-wise
application of the arithmetic subtraction function to the input vector
for each index n, between 0 and the smaller of the lengths of in1 and in2.
Synopsis
DARRAY da_vsub(DARRAY h_in1, DARRAY h_in2)
Arguments
h_in1 The input data arrays can have any length. Data can be any
type.
h_in2 The input data arrays can have any length. Data can be any
type.
Returns
In normal operation, the output is a data array whose length is the lesser of the lengths of
the two input vectors. The output data is the smallest type compatible with the types of the
two input parameters and DA_REAL. The output type is one of the following:
• DA_DCMPLX if one or both parameters are complex and one or both parameters are
double precision
• DA_CMPLX if one or both parameters are complex and no parameters are double
precision
• DA_DREAL if neither parameter is complex and one or both parameters are double
precision
• DA_REAL if neither parameter is complex and neither parameter is double precision.
da_vsum
Running sum.
The output of this function is a data array whose nth value is the sum of all the input values
of index less than or equal to n:
Synopsis
DARRAY da_vsum(DARRAY h_in)
Arguments
h_in The input data array must have a length greater than 0. Data
must be a noncomplex type.
Returns
In normal operation, the output is a data array whose data is the smallest type compatible
with both the type of the input data array and DA_REAL. It is DA_DREAL if the input parameter
is DA_DREAL and DA_REAL in all other cases. The output data array length is the length of
the input data array.
Zero is returned in the case of a run-time error which is ignored or continued.
Representing a Waveform
All signals are comprised of sinusoids. Any sinusoid can be represented as the sum of real
(Re) and imaginary (Im) components as seen in the following equation:
A cos ( f i × t + θ ) (27–130)
The following is a vector representation of the sinusoid with magnitude A and phase θ. (A
is amplitude in volts peak and θ is phase in radians.)
A Imaginary
A sinθ
Real
A cosθ
Using da_fft
This waveform was sampled in the time domain and the sample contains N points (where
N is a power of 2). You can convert from the time domain to the frequency domain using
“da_fft”.
real component
N x A cosq
imaginary
N x A sinq component
fi ⁄ fs = M ⁄ N (27–131)
f res = f s ⁄ N (27–132)
therefore,
M = f i × N ⁄ f s = f i ⁄ f res (27–133)
where:
fi test tone
fs sampling rate
fres bin width
M bin number corresponding to fi. Also, the number of tone cycles
over fres period.
N number of samples over fres period.
Each bin in the complex spectrum contains a pair of array elements. The even element is
real. The odd element is imaginary.
Rule: To locate the real component of the tone fi, look at the complex array index 2 x M. In
this case, the array index (k) = 2 x M.
To locate the imaginary component of the tone fi, look at the complex array index 2 x M + 1.
N2 A 2
Each frequency component of the power spectrum is the magnitude squared of the
corresponding complex frequency pair in the complex spectrum.
2 2
power_spec m = ( RE m ) + ( Im m ) (27–134)
2 2
power_spec m = ( complex_spec k ) + ( complex_spec k + 1 )
= ( N × A cos θ ) 2 + ( N × A sin θ ) 2
= ( N 2 ⋅ A 2 ⋅ cos2 θ + N 2 ⋅ A 2 ⋅ cos2 θ ) (27–135)
= ( N 2 ⋅ A 2 ⋅ ( cos2 θ + sin2 θ ) )
= ( N2 ⋅ A2 )
Using da_amplitude
Use “da_amplitude” to get the amplitude of a spectral component at a certain fi.
da_amplitude() can operate on either a complex spectrum or a power spectrum.
result magnitude = ( Re ) 2 + ( Im ) 2
= ( N ⋅ A ⋅ cos θ ) 2 + ( N ⋅ A ⋅ sin θ ) 2
= N 2 ⋅ A 2 ⋅ ( cos2 θ + sin2 θ ) (27–137)
= N2 ⋅ A2
= N×A
NOTE
Identity:
( cos2 θ + sin2 θ ) = 1
28 TESTER API
Function Description
Function Description
Function Description
Function Description
tl_run_test_program
Run the test program.
SYNOPSIS Tl_run_status tl_run_test_program(stn, cmd, string,
results, output_func)
int stn;
char *cmd;
char *string;
int results[];
Tapi_OFunc output_func;
DESCRIPTION This function executes the test program loaded on station stn.
ARGUMENTS stn—station on which to execute a test program.
cmd—one of run, runtotrap, or cont.
string—string of arguments to pass to the test program.
results—array in which to return binning information.
output_func—function to use to write output produced by call.
The function should be declared as:
int output_funct(int fd, char *data, int len)
where:
fd—file descriptor that can be either 1 (stdout) or 2 (stderr).
data—text to be output.
len—length of text.
tl_run_test_program_cached
Run the test program using cached probe card location and site mask.
SYNOPSIS Tl_run_status tl_run_test_program_cached(stn, cmd,
string, results, output_func)
int stn;
char *cmd;
char *string;
int results[];
Tapi_OFunc output_func;
data—text to be output.
len—length of text.
tl_define_bins
Define device bins for test program using default output handler.
SYNOPSIS int tl_define_bins(stn, num_pass_bins, pass_bins,
num_fail_bins, fail_bins)
int stn;
int num_pass_bins, pass_bins[];
int num_fail_bins, fail_bins[];
tl_define_sites
Define device sites for test program using default output function.
SYNOPSIS int tl_define_sites(stn, num_sites, sites)
int stn;
int num_sites;
struct image_site_info sites[];
tl_locate_site
Define location of a site on a wafer.
SYNOPSIS int tl_locate_site(stn, site, waf_x, waf_y)
int stn;
int site;
int waf_x, waf_y;
DESCRIPTION This function defines the location on the wafer of the sites on the
probe card. It must be called every time the probe card is moved.
However, it is unnecessary to call tl_locate_site for each
active site. Once is enough. Additionally, the site for which a
location is specified need not be an active site. If multiple calls
are made to tl_locate_site with inconsistent information, the
last call is implemented.
ARGUMENTS stn—station for which a site is being located.
site—site number for which a location is being defined.
waf_x, waf_y—coordinates on the wafer of the die under the
specified site.
RETURN VALUE -1 for failure, 1 for success.
tl_get_image_version
Retrieve the version number of IMAGE.
SYNOPSIS char *tl_get_image_version()
DESCRIPTION This function retrieves the version number and date of IMAGE.
For example: V5.4 031694 or V5.3 D2 022594.
ARGUMENTS None
RETURN VALUE NULL for failure or a pointer to a STATIC null-terminated string
for success.
NOTE
Callers wishing to cache this value must make a copy of it.
tl_get_last_image_error_ofunc
Retrieve information about the last IMAGE error.
SYNOPSIS struct image_error
*tl_get_last_image_error_ofunc(stn, output_func)
int stn;
Tapi_OFunc output_func;
DESCRIPTION This function retrieves information about the last error that
occurred within IMAGE.
ARGUMENTS stn—station for which error information should be retrieved.
output_func—function to use to write output produced by call.
The function should be declared as:
int output_funct(int fd, char *data, int len)
where:
fd—file descriptor that can be either 1 (stdout) or 2 (stderr).
data—text to be output.
len—length of text.
NOTE
Callers wishing to cache this value must make a copy of it.
tl_switchvar
Manipulate IMAGE switchvar using default output function.
SYNOPSIS int tl_switchvar(stn, numops, ops);
int stn;
int numops;
Tapi_Switchvar ops[];
tl_tapi_hp_connect
Connect a handler or prober to IMAGE.
SYNOPSIS int tl_tapi_hp_connect(station, name, port)
int station;
char *name;
int port;
tl_tapi_hp_disconnect
Disconnect a handler or prober from IMAGE.
SYNOPSIS int tl_tapi_hp_disconnect(station, name)
int station;
char *name;
tl_tapi_hp_enable
Add a handler or prober to the IMAGE handler or prober polling queue.
SYNOPSIS int tl_tapi_hp_enable(station, name)
int station;
char *name;
tl_tapi_hp_disable
Remove a handler or prober from the IMAGE handler or prober polling queue.
SYNOPSIS int tl_tapi_hp_disable(station, name)
int station;
char *name;
tl_tapi_hp_disconnect_all
Disconnect all handler or prober devices from one IMAGE station.
SYNOPSIS int tl_tapi_hp_disconnect_all(station)
int station;
tl_tapi_hp_get_start
Asynchronously get polling conditions from a handler or prober.
SYNOPSIS int tl_tapi_hp_get_start(station, name, return_cond,
return_sites, return_x_coord, return_y_coord,
timeout_milliseconds)
int station;
char *name;
int *return_cond;
int *return_sites;
int *return_x_coord;
int *return_y_coord;
int timeout_milliseconds;
DESCRIPTION This function polls the specified handler or prober device for
starts until the device asserts a start or a notable event. The
function will also cease polling after a user-specified timeout.
This function does not interrupt the operation of the handler/
prober software. Other handler or prober devices will continue to
operate. You cannot call this function on a handler or prober
device that is enabled for polling.
ARGUMENTS name—name of the handler/prober as it appears in the handcap
file.
station—station to which the device is connected.
return_cond—a user-allocated return storage space
parameter. The function returns a bit field vector that describes
which event caused the termination of polling the device. The
macros for the bits are as follows:
HP_START_COND
HP_TIMEOUT_COND
HP_EOW_COND
HP_EOC_COND
HP_EOL_COND
HP_SOW_COND
HP_SOC_COND
return_sites—a user-allocated return storage space
parameter. The function returns a bit field vector representing on
which sites a start has been detected.
return_x_coord, return_y_coord—user-allocated return
storage space parameters. These functions return the
coordinates of the site 0 die.
timeout_milliseconds—shortest time to poll the device before
returning the HP_TIMEOUT_COND event. The function will
minimally wait as long as the value given here but may actually
wait longer.
RETURN VALUE -1 for failure, 0 for success.
tl_tapi_hp_exec_callback
Execute test program callbacks based on a condition vector.
SYNOPSIS int tl_tapi_hp_exec_callback(station, conditions,
arg)
int station;
int conditions;
void *arg;
tl_tapi_hp_send_binning
Send binning to a handler or prober device.
SYNOPSIS int tl_tapi_hp_send_binning(station, name,
bin_sites, bin_vector[], inker_vector[],
passfail_vector[])
int station;
char *name;
int bin_sites;
int bin_vector[];
int inker_vector[];
int passfail_vector[];
29 CUSTOM DIRECTORY
The custom directory (/custom) is shipped with IMAGE software. This directory is located
in $IMAGEBIN/custom. It contains subdirectories and files which enable you to install
software, set up menu displays, modify defaults, and perform other functions in IMAGE.
Table 29-1 lists the contents of the $IMAGEBIN/custom directory. Files are described as
fixed, dynamic, or change. Fixed files are read only. Dynamic files change due to some
action in IMAGE. Files you can change are used to customize IMAGE.
.production_window_info_3
.startup.ps Fixed
.stlogout IMAGE equivalent of .logout
.ttyswrc Empty file Change
.usermenu Station user button menu Change
ImageLoadJobScript PMC job load script
MAKEDEV.image.4.1.1 /dev/MAKEDEV for tester Fixed
MADEDEV.image.4.1.1.3ce /dev/MAKEDEV for tester Fixed
README.extract Document for extract_license Fixed
S95rc.Teradyne Boot start-up script for Solaris 2 Fixed
TeradyneLoadJobScript STG production user interface
a500.im1
a500.im8
cgb458_package.script
cgb458_probe.mdl
cgb458_probe.script
cgb459.mdl
im_utilities.mdl
menuprogram.svr4
INDEX
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Auxiliary files (Production Menu Control), 9-41 closed bins, 14-16, 15-8
Auxiliary stations, 3-17 determine if bin open or closed, 26-49, 26-69
icon, 3-13 determine pass or fail, 24-26, 26-49
loading, 5-6, 5-10 direct, 15-6
use with checkers, 19-1 disqualify binning, 14-16, 15-8
AWGLAN (Arbitrary Waveform Generator Local error bins, 15-31
Area Network) fail actions, 14-12, 14-15, 14-22, 15-7
alarms, 22-8 get hardware bin number, 26-220
get last bin number, 26-213, 26-218
B get software bin number, 26-219
BACK control button (Production Menu Control), multisite test, 17-6
9-10 open bins, 15-8, 15-12
BACK keyword (Production Menu Control), 9-51 pass actions, 15-6
BAD_UNITS keyword (Production Menu Control), read hardware bin count, 26-211
9-52 read open bin, 26-70
Bank relays, function, 26-289 read software bin count, 26-217
Base language, help, 3-26 send command to handler or prober, 26-238
BBAC set fail bin, 26-157
waveform clock, 26-507 set pass bin, 26-157
BBACCAP (Broadband AC Capture) BINNING_ITEM keyword (Production Menu
calibration, 21-7, 21-32, 21-36 Control), 9-52
manual, 21-36 binstatus command, 15-12
BBACSRC (Broadband AC Source) Bitwise logical operators; see Logical operators
calibration, 21-7, 21-32, 21-36 Body of a function, 13-7
Begin datalog of new device, 26-177 BPS (Begin Program Section Record),
Begin Program Section Record, see BPS 24-6, 24-12
Behavior Chooser, 5-12 Braces, in IMAGE, 8-21, 8-31, 13-6, 13-9
.bin files, see Binary files Brackets, in IMAGE, 13-6
Bin numbers, see Binning Branching, 2-3, 13-19, 13-22
Bin totals in summary report, 6-89 break statement, 13-19, 13-22
Binary files, 5-2, 5-5, 5-11 Breakdown Voltage Current Source, connections,
changing for conditional compiling, 5-18, 5-19 26-396
determining type, 7-43 Breaktraps, 7-11
saving, 7-32 arrow, 7-12, 7-15, 7-18
Solaris 2, 7-27, 7-28, 7-40, 7-43 ATE, 7-11
SUN3 and SUN4, 5-10, 7-27, 7-28, 7-40 deleting, 7-14
binfile command, 7-43 during editing, 7-22, 7-24
Binning, 5-24, 13-4, 14-9, 14-12 in alarms, 7-11
and alarms, 22-3 in for statements, 7-21
assigning bin numbers, 15-6, 15-8 in functions, 7-11
bin numbers, 15-11, 17-27 in patterns, 7-11
hardware, 6-89, 6-134, 10-3, 15-12, 15-18 in test numbers, 7-11
software, in tests, 7-11
5-22, 6-89, 6-135, 10-3, 15-12, 15-18 line number, 7-11
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Fail actions, 14-12, 14-15, 14-22, 15-7 pattern, 5-5, 5-9, 5-11
Fail bin setting, 26-157 renaming, 2-23
Failing tests source, 5-2, 5-11
breaktraps, 7-11 viewing, 2-23
datalog and summary, 3-38 waveform, 5-9
datalogging, 6-92, 6-97 Final summary reports, 6-89, 6-90, 6-93, 6-104
monitoring maximum consecutive, 15-16 find command, 2-25
showing first in production, 8-54 FIRMS (Factory Integration and Resource
sleep state, 17-23 Management System), 1-4
writing EPS record, 6-77 send datastream files, 3-38
Failing vectors, 6-27 send event messages, 26-181
FAR (File Attributes Record), 24-6, 24-14 send files, 3-38
Fast load, 5-6 send tester utilization events, 3-38
Fast load checkers, 19-11 store data, 6-38
fclose function, 16-2, 16-10 support for wafer mapping, 10-19
fflush function, 16-4, 16-15 use with IMAGE, 3-76
fgetc function, 16-13 FLEX License Manager, 3-56
field data type, 13-11 .flexlmrc file, 3-57
FIELD keyword (Production Menu Control), 9-61 float data type, 13-11
Field width specifier Floating point constants, 13-11, 13-17, 13-18
in datalog, 6-75 Floating Voltage Source, calibration, 26-196
in printf, 16-6 Flow control statements, 13-19
Fields Flushing the standard I/O buffer, 16-15
limitations in datalog reports, 6-46 FONT keyword, 8-11, 8-53, 8-59
specification in datalog, 6-75 Font, controlling in production mode, 3-34, 8-10
File Attributes Record, see FAR FONTSIZE keyword (Production Menu Control),
FILENAME keyword (Production Menu Control), 9-61
9-61 fopen function, 16-2, 16-10
Files, 2-22 for statement, 13-19, 13-20
adding to test program, 7-8 breaktraps, 7-21
appending, 2-22 Force next device to be a retest, 26-42
binary, 5-2, 5-5, 5-11 Forcing tests to pass or fail, 5-27
changing test program, 7-8 Formatting text files, 2-25
commands, 2-20 fprintf function, 16-2, 16-11
copying, 2-23 fputc function, 16-12
deleting, 2-23 Frames in functions, 7-19
.ibclog files, 5-16 free function, use in Solaris 2, 13-38
.image_behavior files, 5-13, 5-14 fscanf function, 16-2, 16-11
input and output, 16-10 ftoi function, 26-39
library, 5-5, 5-9, 5-11 FTR (Functional Test Result Record),
.load, 5-2 6-105, 24-6, 24-15
.make, 5-11, 5-12 Full format datalog reports, 6-41, 6-42
manipulating test program, 7-31 fulldlgfmt datalog filter, 6-41, 6-82
object, 5-5, 5-9 Function keys
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
G H
GAP keyword, 8-11 halt button and command, 8-13
GEMsl halt command, 7-19
send string message, 26-346 halt_sys command, 2-34
General Purpose Interface Bus, see GPIB halt_tst command, 2-34
Generating histogram reports, 6-124 Halting
Generating summary reports, 6-89 test programs, 5-28, 7-19, 7-24
getc function, 16-2, 16-12 tester computer, 2-34
getchar function, 16-2, 16-4, 16-7 user computer, 2-34
Getting a character, 16-16 handcap database, 8-30
GFXPRINTER environment variable, 3-21, 3-39 show enabled options, 26-242
GigaDig Handler bins, see Hardware bins
alarms, 22-9 handler button, 8-7
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Memory Profiler, 5-39, 5-40, 5-42, 5-46 Mode code, 26-318, 26-369
Memory recompaction control, 26-295 more command, 2-23
Memory usage, 5-37, 5-40 Mouse, operating without, 8-15
Menu Description File, see MDF MOVABLE_WINDOWS keyword, 8-9
Menu Description Language, see MDL Mprintf function, 26-42
MENU keyword, 8-12, 8-21, 8-36 MRR (Master Results Record),
MENU keyword (Production Menu Control), 24-7, 24-23, 24-33, 26-384
9-25, 9-67 MSG control button (Production Menu Control),
Menu screens (Production Menu Control) 9-10
Datalog, 9-9, 9-31 Multiplexer, opening, 26-297
Job I/O, 9-9, 9-31 Multiplexing, and test time, 5-32
Runtime/Binning, 9-9, 9-34 Multisite testing, 17-1
MENU_DEFAULTS keyword, 8-36 advanced mixed-signal, 17-10
MENU_ITEM keyword, 8-22, 8-24, 8-36 disqualify binning, 15-11
MENU_ITEM keyword (Production Menu get bin number, 26-213, 26-218
Control), 9-27, 9-68 get site number, 26-181
menufile menu description file, 8-20, 8-30 loading test programs, 5-5
adding handler/prober items, 8-30 retrieve site value, 26-342
changing datalog, 8-31 serial blocks, 17-8, 17-24
compiler, 8-42 Simulator DataBase files, 12-2, 12-8
keywords for, 8-32 sites,
using different languages, 8-31 17-19, 17-21, 26-342, 26-388, 26-389, 26
menuprogram file, 8-42 -434
Menus sleep state, 17-21
customizing, 8-10, 8-20 wafer mapping, 10-3
setting submenus, 3-34 waking sites, 17-22
source window, 7-6 with digital signal source and capture, 17-14
temporary, 8-32 with match mode, 17-12
MERGE_COLLECTIONS keyword (Production without match mode, 17-11
Menu Control), 9-69 mv command, 2-23
merge_histo program, 6-139
Merging histogram files, 6-139 N
Messages to station monitor, 8-54 Names
MIR (Master Information Record), test program, 3-12, 3-13, 8-7, 8-16
6-105, 24-6, 24-18, 26-156, 26-186 Namestripe, 3-12
Mixed-signal Help window, 3-27
read and write conversion cage registers, source window, 7-5
26-514 station window, 3-12
read and write vector bus cage registers, Network node name, reading, 26-328
26-515 Network/user computer, 1-2
selecting head type, 5-3 New Station menu item, 3-6, 3-15, 3-23
test head registers, 26-513, 26-514 New Station windows, 3-15
mkdir command, 2-20 NEWROW keyword, 8-11
Mod-8 rule, 17-5, 17-10 newversion command, 7-23, 7-33
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
26-437 tl_uwport_read_match_and_source_gain
tl_uwport_caldib_find_interpolated_system_NF function, 26-469
function, 26-438 tl_uwport_read_match_and_source_gain_slot
tl_uwport_config function, 26-439 function, 26-470
tl_uwport_current_pin function, 26-440 tl_uwport_read_power_de_embed function,
tl_uwport_current_pin_slot function, 26-441 26-470
tl_uwport_do_s11 function, 26-441 tl_uwport_read_power_de_embed_slot function,
tl_uwport_do_spar_proc function, 26-444 26-471
tl_uwport_dump function, 26-446 tl_uwport_read_s1p function, 26-471
tl_uwport_dump_1port function, 26-448 tl_uwport_read_s2p function, 26-471
tl_uwport_dump_closest_freq function, 26-449 tl_uwport_receiver_slot function, 26-472
tl_uwport_dump_closest_freq_slot function, tl_uwport_s_param_sample_size function,
26-449 26-478
tl_uwport_dump_de_embed_file function, 26-449 tl_uwport_s_param_snr_test_enable function,
tl_uwport_dump_de_embed_file_slot function, 26-478
26-449 tl_uwport_set_gain_error_limits function, 26-473
tl_uwport_dump_fixture function, 26-450 tl_uwport_set_gain_error_limits_slot function,
tl_uwport_dump_fixture_slot function, 26-450 26-473
tl_uwport_dump_one_port function, 26-451 tl_uwport_set_interpolation_frequency_range
tl_uwport_dump_one_port_slot function, 26-454 function, 26-474
tl_uwport_dump_port function, 26-454 tl_uwport_simulate_capture function, 26-475
tl_uwport_dump_s_param_timing function, tl_uwport_simulate_capture_slot function, 26-476
26-458 tl_uwport_source_freq_range function, 26-476
tl_uwport_dump_two_port function, 26-459 tl_uwport_source_freq_range_slot function,
tl_uwport_dump_two_port_slot function, 26-462 26-477
tl_uwport_free_data function, 26-462 tl_uwport_sparam_timer function, 26-479
tl_uwport_get_num_chans_slot function, 26-463 tl_uwport_sparam_timer_slot function, 26-479
tl_uwport_hw_version function, 26-463 tl_uwport_std_cal_one_port function, 26-531
tl_uwport_inst_slot function, 26-463 tl_uwport_std_cal_one_port_slot function, 26-532
tl_uwport_invalidate_s_param_cal function, tl_uwport_user_cal_std_func function, 26-480
26-464, 26-465 tl_uwport_write_s1p function, 26-483
tl_uwport_invalidate_s_param_cal_all function, tl_uwport_write_s1p_fmt function, 26-483
26-464 tl_uwport_write_s2p function, 26-484
tl_uwport_lna function, 26-465 tl_uwport_write_s2p_fmt function, 26-485
tl_uwport_noise_source_present function, 26-466 tl_uwrecv_ap_read_uncal_amp function, 26-486
tl_uwport_noise_source_present_slot function, tl_uwrecv_cal_interval function, 21-31
26-466 tl_uwrecv_characterize_phase_noise_PSD
tl_uwport_num_user_chans function, 26-466 function, 26-487
tl_uwport_pin_to_slot_and_schan function, tl_uwrecv_czt function, 26-488
26-467 tl_uwrecv_get_PSD_use_AP function, 26-489
tl_uwport_read_match_and_measure_gain tl_uwrecv_phase_noise_signal_check function,
function, 26-467 26-489
tl_uwport_read_match_and_measure_gain_slot tl_uwrecv_read_ampval function, 26-490
function, 26-468 tl_uwrecv_read_ampval_slot function, 26-490
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z