API for Keithley 4200 ATV#
The available commands are divided into General, SMU and CVU. This distinction is made for the sake of clarity. However, all functions are called on the same device (see examples).
Note#
All Python functions in this API are mapped internally to a corresponding C# function.
Some C# methods use the out
keyword which causes arguments to be passed by reference.
Since the concept of out arguments does not apply to Python and you must pass as many arguments as the C# method requires the trick is to pass some dummy arguments of the expected type.
So if you encounter a int@
(or double@, string@
) in a function signature (the corresponding C# method uses the out
keyword for this parameter) the @
sign means you have to pass
a dummy value of the type written before the @
sign for this parameter to match the C# method signature.
See the following example for better understanding:
getinstid(string,int@)
This command returns the instrument identifier (ID) from the instrument name string.
Name | Description |
---|---|
idstring: | The instrument name string |
instrId: | The instrument identification code |
Returns: instrId : int The instrument identification code |
# get instrument id for CVU1
cvuId = k4200.getinstid("CVU1", 0)