Controlling the instrument by sending individual command messages ..................................... 7-1
Queries ..................................................................................................................................... 7-3
Information on scripting and programming ................................................................................ 7-3
About TSP commands ......................................................................................................... 7-3
Beeper control ........................................................................................................................... 7-3
Bit manipulation and logic operations ........................................................................................ 7-4
Data queue................................................................................................................................ 7-5
Digital I/O .................................................................................................................................. 7-5
Display ...................................................................................................................................... 7-6
Error queue ............................................................................................................................... 7-6
Event log ................................................................................................................................... 7-6
File I/O ...................................................................................................................................... 7-7
GPIB ......................................................................................................................................... 7-9
Instrument identification ............................................................................................................ 7-9
LAN and LXI .............................................................................................................................. 7-9
Miscellaneous ......................................................................................................................... 7-10
Parallel script execution .......................................................................................................... 7-11
Queries and response messages ............................................................................................ 7-11
Reading buffer ......................................................................................................................... 7-11
Reset ....................................................................................................................................... 7-12
RS-232 .................................................................................................................................... 7-12
Saved setups .......................................................................................................................... 7-12
Scripting .................................................................................................................................. 7-13
SMU ........................................................................................................................................ 7-13
SMU calibration ....................................................................................................................... 7-15
Status model ........................................................................................................................... 7-15
Time ........................................................................................................................................ 7-16
Triggering ................................................................................................................................ 7-16
TSP-Link ................................................................................................................................. 7-18
TSP-Net .................................................................................................................................. 7-19
Userstrings .............................................................................................................................. 7-20
Factory scripts .................................................................................................................... 7-20
Running a factory script .......................................................................................................... 7-21
Retrieving and modifying a factory script listing ...................................................................... 7-21
KISweep factory script ............................................................................................................ 7-22
KIPulse factory script .............................................................................................................. 7-22
KIHighC factory script ............................................................................................................. 7-24
KIParlib factory script .............................................................................................................. 7-24
KISavebuffer factory script ...................................................................................................... 7-24
Instrument programming ......................................................................................... 8-1
Fundamentals of scripting for TSP ....................................................................................... 8-1
What is a script? ........................................................................................................................ 8-2
Runtime and nonvolatile memory storage of scripts .................................................................. 8-2
What can be included in scripts? ............................................................................................... 8-2
Commands that cannot be used in scripts ................................................................................ 8-3
Manage scripts .......................................................................................................................... 8-3
Working with scripts in nonvolatile memory............................................................................. 8-10
Programming example: Interactive script ................................................................................ 8-12
Fundamentals of programming for TSP ............................................................................. 8-13
What is Lua? ........................................................................................................................... 8-14
Lua basics ............................................................................................................................... 8-14
Standard libraries .................................................................................................................... 8-29
Programming example: User script ......................................................................................... 8-32
Password management ..................................................................................................... 8-32
Setting the password from a command or web interface ........................................................ 8-33
Unlocking the remote interface ................................................................................................ 8-34