![background image](http://html1.mh-extra.com/html/keithley/sourcemeter-2600-series/sourcemeter-2600-series_reference-manual_4098633325.webp)
Series 2600 System SourceMeters Reference Manual
Instrument Control Library 12-51
Return to
2600S-901-01 Rev. A / May 2006
Example
Creates a getter function called
getlevel
:
getlevel = makegetter(smua.source, "levelv")
...
v = getlevel()
When
getlevel
is called, it returns the value of
smua.source.levelv
.
makesetter
Function
Creates a function to set the value of an attribute.
Usage
setter = makesetter(table, attributename)
table
Read-only table were the attribute is located.
attributename
The string name of the attribute.
setter
Function that sets the value of the given attribute.
Remarks
• This function creates a function that when called sets the value of the attribute. This
function is useful for aliasing attributes to improve execution speed. Calling the
setter
function will execute faster than accessing the attribute directly.
• Creating a
setter
function is only useful if it is going to be called several times.
Otherwise the overhead of creating the
setter
function outweighs the overhead of
accessing the attribute directly.
Example
Creates a
setter
function called
setlevel
:
setlevel = makesetter(smua.source, "levelv")
for v = 1, 10 do
setlevel(v)
end
Using
setlevel
in the loop sets the value of
smua.source.levelv
, thereby
performing a source sweep.
Summary of Contents for SourceMeter 2600 Series
Page 575: ...AppendixF DisplayCharacterCodes Appendix F topics Introduction page F 2...
Page 592: ......
Page 593: ......