Agilent 4155C/4156C VXIplug&play Driver User’s Guide, Edition 4 3-53
Programming Examples for Visual Basic Users
Stress Force
Stress Force
This section explains example subprograms that enable/disable measurement
channels (perform_meas), perform stress measurement (stress_meas), and display
measurement result data (disp_data1 and disp_data2). This example measures
current of a device that has two high terminals and a low terminal.
Table 3-13 Stress Force Example
Sub perform_meas(vi As Long, ret As Long) ’1
Dim m(3) As Long ’SMU port numbers ’3
m(0) = 1 ’SMU1: t1
m(1) = 2 ’SMU2: t2
m(2) = 3 ’SMU3: low
ret = hp4156b_setSwitch(vi, m(2), 1) ’8
ret = hp4156b_setSwitch(vi, m(1), 1)
ret = hp4156b_setSwitch(vi, m(0), 1)
check_err vi, ret
stress_meas vi, ret, m() ’13
ret = hp4156b_setSwitch(vi, hp4156b_CH_ALL, 0) ’15
check_err vi, ret
End Sub ’18
Line Description
1 Beginning of the perform_meas subprogram.
3 to 6 Declares variables, and defines the value.
8 to 10 Enables measurement channels.
13 Calls the stress_meas subprogram (next page) to perform stress
measurement.
15 Disables measurement channels.
11 and 16 Calls the check_err subprogram (shown in Table 3-1) to check if
an error status is returned for the previous line.
18 End of the perform_meas subprogram.