3- 6
Keysight E5260/E5270 Programming Guide, Edition 4
Programming Examples
Programming Basics for Visual Basic .NET Users
Table 3-1
Example Template Program Code for Visual Basic .NET
Imports Ivi.visa.interop
Module Module1
Sub Main() ’5
Dim E5270 As IResourceManager
Dim session As IMessage
E5270 = New ResourceManager
session = E5270.Open("GPIB0::17::INSTR")
session.WriteString("*RST" & vbLf)
MsgBox("Click OK to start measurement.", vbOKOnly, "")
Console.WriteLine("Measurement in progress. . ." & Chr(10))
Dim t() As Integer = {5, 4, 3, 1} ’Drain, Gate, Source, Sub ’14
Dim term As String = t(0) & "," & t(1) & "," & t(2) & "," & t(3)
session.WriteString("CN " & term & vbLf)
perform_meas(session, t)
session.WriteString("CL" & vbLf) ’19
session.Close()
MsgBox("Click OK to stop the program.", vbOKOnly, "")
Console.WriteLine("Measurement completed." & Chr(10))
End Sub ’23
Line
Description
1
This line is required to use the VISA COM library.
5 to 23
Main subprogram establishes the software connection with the Keysight E5260/E5270,
resets the E5260/E5270, opens a message box to confirm the start of measurement, and
pauses program execution until OK is clicked on the message box. By clicking OK, the
program displays a message on the console window, enables the SMUs, and calls the
perform_meas subprogram that will be used to perform measurement.
After the measurement, the program disables all SMUs, disables the software connection
with the E5260/E5270, and opens a message box to confirm the end of the program. Finally,
by clicking OK on the message box, the program displays a message on the console window.
9
The above example is for the E5260/E5270 of the GPIB address 17 on the interface GPIB0.
“GPIB0” is the VISA name. Confirm your GPIB settings, and set them properly.
14 to 15
The above example uses the SMUs installed in the E5260/E5270 slots 1, 3, 4, and 5. Change
the slot numbers for matching your configuration.
Summary of Contents for E5260 Series
Page 1: ...Keysight Technologies E5260 E5270 Series of Parametric Measurement Solutions Programming Guide...
Page 3: ...User s Guide B2900 9001x xxxx 201x Edition x...
Page 13: ...1 Programming Basics...
Page 63: ...2 Remote Mode Functions...
Page 108: ...2 46 Keysight E5260 E5270 Programming Guide Edition 4 Remote Mode Functions Initial Settings...
Page 109: ...3 Programming Examples...
Page 185: ...4 Command Reference...
Page 335: ...5 Error Messages...
Page 349: ......