2600S-901-01 Rev. C / January 2008 Return to Section Topics 12-43
Series 2600 System SourceMeter® Instruments Reference Manual Section 12: Instrument Control Library
opc function
This function sets the OPC bit in the status register when all overlapped commands are
completed.
Function Sets the Operation Complete status bit when all overlapped commands are completed.
Usage opc()
Remarks • This function will cause the Operation Complete bit in the Standard Event Status Register
to be set when all previously started local overlapped commands are
complete. Note that each node will independently set their Operation Complete bits in
their own status models.
• Any nodes not actively performing overlapped commands will set their bits
immediately. All remaining nodes will set their own bits as they complete their own
overlapped commands.
Details See Appendix D.
Also see waitcomplete
printbuffer and printnumber functions
These functions are used to print data and numbers.
makesetter
Function Creates a function to set the value of an attribute.
Usage setter = makesetter(table, attributename)
table Read-only table where 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.
opc
printbuffer
Function Prints data from tables and reading buffer sub-tables.