EasyManuals Logo

Tektronix KEITHLEY 2600B Series User Manual

Tektronix KEITHLEY 2600B Series
834 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #235 background image
Section 8: Instrument programming Series 2600B System SourceMeter® instrument Reference Manual
8-14 2600BS-901-01 Rev. F/August 2021
What is Lua?
Lua is a programming language that can be used with TSP-enabled instruments. Lua is an efficient
language with simple syntax that is easy to learn.
Lua is also a scripting language, which means that scripts are compiled and run when they are sent to
the instrument. You do not compile them before sending them to the instrument.
Lua basics
This section contains the basics about the Lua programming language to allow you to start adding
Lua programming commands to your scripts quickly.
For more information about Lua, see the Lua website (lua.org). Another source of useful information
is the Lua users group (lua-users.org), created for and by users of Lua programming language.
Comments
You can start a comment anywhere outside a string by typing a double hyphen (--). If the text
immediately after -- is anything other than double left brackets ([[), the comment is a short
comment, which continues until the end of the line.
If -- is followed by [[, the following characters are a long comment, which continues until double
right brackets (]]) close the comment. Long comments may continue for several lines and may
contain nested [[ . . . ]] pairs. The example below shows how to use code comments.
An example of a short comment is:
-- Turn off the front-panel display.
An example of a long comment is:
--[[Display a menu with three menu items. If the second menu item is selected,
the selection is given the value Test2.]]
Function and variable name restrictions
You cannot use factory script names, functions created by factory scripts, Lua reserved words and
top-level command names for function or variable names.
For information on factory script names, see Factory scripts (on page 7-20).

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Tektronix KEITHLEY 2600B Series and is the answer not in the manual?

Tektronix KEITHLEY 2600B Series Specifications

General IconGeneral
BrandTektronix
ModelKEITHLEY 2600B Series
CategoryMeasuring Instruments
LanguageEnglish

Related product manuals