EasyManuals Logo

Agilent Technologies 4156C User Manual

Agilent Technologies 4156C
312 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #134 background imageLoading...
Page #134 background image
3-46 Agilent 4155C/4156C VXIplug&play Driver User’s Guide, Edition 4
Programming Examples for Visual Basic Users
Staircase Sweep with Pulsed Bias Measurements
Sub save_data(nop1 As Long, nop2 As Long, dvg() As Double, md() As Double, st() As
Long, sc() As Double, vi As Long, ret As Long, m() As Long) ’1
Dim i As Integer ’array counter for primary sweep ’3
Dim j As Integer ’array counter for secondary sweep
Dim val As String ’data to be saved to a file
val = "Vg (V), Vd (V), Id (mA), Status"
For j = 1 To nop2
For i = nop1 * (j - 1) To nop1 * j - 1
val = val & Chr(13) & Chr(10) & dvg(j - 1) & "," & sc(i) & "," & md(i) *
1000 & "," & st(i)
Next i
Next j
Dim fname As String ’data file name ’13
Dim fnum As Integer ’file number
fname = "C:\Agilent\data\data6.txt"
fnum = 1
Open fname For Output Access Write Lock Read Write As fnum
Print #fnum, val
Close fnum
Dim title As String ’21
Dim rbx As Integer
title = "Sweep Measurement Result"
val = val & Chr(10) & Chr(10) & "Data save completed."
val = val & Chr(10) & Chr(10) & "Do you want to perform measurement again?"
rbx = MsgBox(val, vbYesNo, title)
If rbx = vbYes Then
sweep_meas vi, ret, m()
End If
End Sub ’31
Line Description
1 Beginning of the save_data subprogram.
3 to 11 Declares variables, and creates data to be saved and displayed on a message box.
13 to 19 Saves measurement data into a file (C:\Agilent\data\data6.txt, CSV file).
21 to 29 Displays measurement data on a message box. If Yes is clicked on the message box,
performs the sweep_meas subprogram again. If No is clicked, returns to the
perform_meas subprogram.
31 End of the save_data subprogram.

Table of Contents

Other manuals for Agilent Technologies 4156C

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Agilent Technologies 4156C and is the answer not in the manual?

Agilent Technologies 4156C Specifications

General IconGeneral
BrandAgilent Technologies
Model4156C
CategoryMeasuring Instruments
LanguageEnglish

Related product manuals