Fixture Compensation

Other topics about Preparing for Accurate Measurement

Overview

The program listed in the below section is written in VISA-COM with Excel VBA. It can be executed from the external PC controller. The program demonstrates how to perform fixture compensation.

Fixture Compensation Sample Program in Excel VBA

    ' The memory area of the resource manager and the instrument I/O are acquired

    Dim iomgr As VisaComLib.ResourceManager

    Dim Analyzer As VisaComLib.FormattedIO488

 

Sub FixtureCompen()

    Dim Dmy As Integer, Flg As Integer

    Set iomgr = New VisaComLib.ResourceManager

    Set Analyzer = New VisaComLib.FormattedIO488

 

    ' Open the instrument. Set the GPIB address.

    Set Analyzer.IO = iomgr.Open("USB0::0x0957::0x1809::KPR0200015::0::INSTR")

 

    ' TimeOut time should be greater than the measurement time.

    Analyzer.IO.timeout = 50000

   

    ' Select compensation point

    ' Set compensation point at fix

    Analyzer.WriteString ":SENS1:CORR:COLL:FPO FIX", True

    ' Select fixture model           

    Analyzer.WriteString ":SENS1:FIXT:SEL FIXT16047A", True         

    '

    Call DefineTermination

    '

    ' Perform Fixture Compensation

    Flg = MsgBox("Do you perform Open Fixture Compensation?", vbYesNo, "Fixture Compensation")

    If Flg = vbYes Then

        MsgBox "Connect Open Termination"

        ' Execute open in fixture compensation

        Analyzer.WriteString ":SENS1:CORR2:COLL:ACQ:OPEN", True

        ' Wait for measurement end

        Analyzer.WriteString "*OPC?", True                          

        Dmy = Analyzer.ReadNumber

    End If

    

    Flg = MsgBox("Do you perform Short Fixture Compensation?", vbYesNo, "Fixture Compensation")

    If Flg = vbYes Then

        MsgBox "Connect Short Termination"

        ' Execute short in fixture compensation

        Analyzer.WriteString ":SENS1:CORR2:COLL:ACQ:SHOR", True

        ' Wait for measurement end

        Analyzer.WriteString "*OPC?", True                          

        Dmy = Analyzer.ReadNumber

    End If

    Flg = MsgBox("Do you perform Load Fixture Compensation?", vbYesNo, "Fixture Compensation")

    If Flg = vbYes Then

        MsgBox "Connect LOAD Termination"

        ' Execute load in fixture compensation

        Analyzer.WriteString ":SENS1:CORR2:COLL:ACQ:LOAD", True

       ' Wait for measurement end

        Analyzer.WriteString "*OPC?", True                          

        Dmy = Analyzer.ReadNumber

    End If

    

    ' Close IO

    Analyzer.IO.Close

        

End Sub

 

Sub DefineTermination()

    '

    Dim LoadF() As String, n As Integer, i As Integer

    ' Define Short termination by equivalent circuit model

    ' Set equivalent circuit model for short

    Analyzer.WriteString ":SENS1:CORR2:CKIT:SHOR:MOD EQU", True

    ' Set short termination parameter (L)

    Analyzer.WriteString ":SENS1:CORR2:CKIT:SHOR:L 1E-9", True

    ' Set short termination parameter (R)  

    Analyzer.WriteString ":SENS1:CORR2:CKIT:SHOR:R 1E-4", True      

    '

    ' Define Load by f-Z table model

    ' Set f-Z table model for short

    Analyzer.WriteString ":SENS1:CORR2:CKIT:LOAD:MOD TABL", True    

    n = 4

    ReDim LoadF(n)

    ' Define f-Z table (freq, real, imaginary)

    LoadF(1) = "20, 49.5, 1E-3"

    LoadF(2) = "1E3, 49.9, 1.2E-3"

    LoadF(3) = "1E6, 50, 1.5E-3"

    LoadF(4) = "120E6, 50.9, 2E-3"

    ' :SENS1:CORR2:CKIT:LOAD:TABL {n}, {freq 1}, {real 1}, {imaginary 1}, ... , {freq n}, {real n}, {imaginary n}

    Analyzer.WriteString ":SENS1:CORR2:CKIT:LOAD:TABL " & Str(n) & ",", False ' Set f-Z table

    For i = 1 To n - 1

        Analyzer.WriteString LoadF(i) & ",", False

    Next i

    Analyzer.WriteString LoadF(n), True

End Sub