![background image](http://html2.mh-extra.com/html/keithley/2657a/2657a_reference-manual_4007750288.webp)
Model 2657A High Power System SourceMeter® Instrument Reference Manual
Section 6: Instrument programming
2657A-901-01 Rev. B/December 2012
6-39
Figure 95: Global variables and scripts in the runtime environment
Create a script using the script.new() command
Use the
script.new()
function to copy an existing script from the local node to a remote node. This
enables parallel script execution.
You can create a script with the
script.new()
function using the command:
scriptVar
= script.new(
code, name
)
Where:
scriptVar
= Name of the variable created when the script is loaded into the run-time environment
code
= Content of the script
name
= Name that is added to the
script.user.scripts
table
X
Name
Value
beepDisable
reference to script
named beepDisable
script.user.scripts table
beepTwoSec
reference to script named
beepT
woSec
1
Y
hello
Global variables
Scripts in the runtime environment
display.clear()
display.settext("This is
anonymous")
print("This is anonymous")
script name
source
Autorun
No
anonymous script
beepDisable
reference to script
named beepDisabled
beepTwoSec
reference to script
named beepTwoSec
No
Autorun
beeper.enable = 1
beeper.beep(2, 2400)
script name
source
beepTwoSec
Yes
Autorun
beeper.enable = 0
script name
source
beepDisable
No
Autorun
script name
source
display.clear()
display.settext("hello")
reference to unnamed
script. There is no
script.user.scripts
table entry for the
unnamed script
5
Содержание 2657A
Страница 3: ......