19
Option Explicit
'' ---------------------------------------------------------------------------------------------------------------------
'' Constants
'' ---------------------------------------------------------------------------------------------------------------------
Const MAXLEN = 6400 ' Constant used with ENTER function.
Const LENGTH = 6400 ' Constant used with ENTER function.
Const ENTER_TIMEOUT = 3000 ' Length of time the ENTER function will
' wait for a query.
Const ADDRESS = 16 ' DMM setup address.
'' Slot assignments.
Const SLOT_7700 = 1
Const SLOT_7711 = 2
Const SLOT_7705 = 3
'' Number of configurations, power supply units, and functions.
Const NUMBER_OF_DUTS = 4
Const NUMBER_OF_FUNCTIONS = 4
' DCV, ACV, CONT, and TEMP.
Const NUMBER_OF_SUPPLY_CONFIGURATIONS = 4
' Includes HIGH/ LOW line and 10%/90% load.
Const N_READINGS = NUMBER_OF_DUTS * NUMBER_OF_FUNCTIONS * NUMBER_OF_SUPPLY_CONFIGURATIONS
'' Constants to define limits for the different measurements.
Const POWER_SUPPLY_VOLTAGE = 5
' Voltage output of power supplies.
Const DCV_MAX = POWER_SUPPLY_VOLTAGE * 1.1
' Allow power supply to vary by 10%.
Const DCV_MIN = POWER_SUPPLY_VOLTAGE * 0.9
Const ACV_MAX = 132
' ACV input voltage to power supply limits.
Const ACV_MIN = 108
Const CONT_MAX = 2 ' Limit failure will occur at 2 ohms or more.
Const CONT_MIN = -0.01
Const TEMP_MAX = 125
' Max. and min. limits for temperature.
Const TEMP_MIN = 70
'' Constants to define power supply configurations.
Const HIGH_LINE = 1
Const LOW_LINE = 2
Const TEN_PERCENT_LOAD = 1
Const NINETY_PERCENT_LOAD = 2
' Global variables.
Dim Status As Integer
' Variable used by the send() function.
Dim Readings(N_READINGS) As String ' Array to store readings.
Dim Reading_Counter As Integer
' Index to Readings().
'' ---------------------------------------------------------------------------------------------------------------------
'' 7700 Channel Configurations
'' ---------------------------------------------------------------------------------------------------------------------
'' Configure_Limits(,,) -
'' Sets the limits for a given channel given by the constants defined above.
''
'' Configure_7700_DCV(,) -
'' Sets a channel to measure DCV.
''
'' Configure_7700_ACV() -
'' Configures a channel to measure ACV.
''
'' Cofigure_CONT() -
'' Configures the channel to measure 2W ohms.
'' This measurement is used instead of CONT, so we can select the ohm's limits.
''
'' Configure_7700_TEMP() -
'' Sets a channel to measure temperature using *RST default.
''
'' Configure_Channel() -
'' Uses the above functions to do the following on the 7700:
'' 1. Sets channels 1,5,9, and 13 to DCV.
'' 2. Sets channels 2,6,10, and 14 to ACV.
'' 3. Sets channels 3,7,11, and 15 to CONT.
'' 4. Sets channels 4,8,12, and 16 to TEMP.
'' 5. Places the box into Auto-Configuration Mode.
''
'' Note: Auto-configuration mode brings in the individual channels'
'' settings when that channel is closed.
'' ---------------------------------------------------------------------------------------------------------------------
Private Sub Configure_7700_Limits(Channel_Num As Integer, Ulimit As Integer, Llimit As Integer)
Dim Channel_Str As String
Dim Upper_Limit As String
Dim Lower_Limit As String
Channel_Str = ",(@" & CStr(Channel_Num) & ")"
' Converts a number to an ASCII channel parameter.
Upper_Limit = CStr(Ulimit)
Lower_Limit = CStr(Llimit)
Call send(ADDRESS, "CALC3:LIM1:STAT ON" & Channel_Str, Status)
' Enable Limit1 for DCV.
Call send(ADDRESS, "CALC3:LIM1:UPP:DATA " & Upper_Limit & Channel_Str, Status)
' Set upper limit.
Call send(ADDRESS, "CALC3:LIM1:LOW:DATA " & Lower_Limit & Channel_Str, Status)
' Set lower limit.
End Sub
Private Sub Configure_7700_DCV(Channel_Num As Integer, Power_Supply_DCV As Integer)
Dim Channel_Str As String
Channel_Str = ",(@" & CStr(Channel_Num) & ")"
Call send(ADDRESS, "SENS:FUNC 'VOLT:DC'" & Channel_Str, Status) ' Set channel to measure DCV.
Call send(ADDRESS, "SENS:VOLT:DC:RANG 100" & Channel_Str, Status) ' Set voltage range(Power Supply is at 5V).
Call Configure_7700_Limits(Channel_Num, DCV_MAX, DCV_MIN)
End Sub
Private Sub Configure_7700_ACV(Channel_Num As Integer)
Dim Channel_Str As String
Channel_Str = ",(@" & CStr(Channel_Num) & ")"
Call send(ADDRESS, "SENS:FUNC 'VOLT:AC'" & Channel_Str, Status)
' Set channel to measure ACV.
Call send(ADDRESS, "SENS:VOLT:AC:RANG 150" & Channel_Str, Status)
' Set voltage range.
Call Configure_7700_Limits(Channel_Num, ACV_MAX, ACV_MIN)
End Sub
Summary of Contents for 7711
Page 30: ...26 Figure 12 Model 7711 component layout...
Page 31: ...27 Figure 13 Model 7712 component layout...
Page 37: ......