AMETEK Lx Series II Programming Manual User Manual
Page 148

Programming Manual
Lx \ Ls Series II
144
OUTP:DFI:STATE ON
To enable the OCP signal to get to the STAT:QUES register, send:
STAT:QUES:PTR 2
STAT:QUES:ENAB 2
After sending these commands, the DFI output will indicate when the RMS OCP goes active.
Note that when an OCP fault happens, the PROT lamp comes on indicating that one has to send
OUTP:PROT:CLEAR to re-enable the source once the over current condition is removed. Note
also that the DFI output will stay low until the questionable status register (STAT:QUES?) is read.
6.9
Controlling the Instantaneous Voltage and Current Data Buffers
Measurements taken by the Lx\Ls Series measurement systems are based on a digital
representation of the voltage and current waveforms. Both waveforms are digitized with 24 bits of
amplitude resolution and down to 10.4 or 31.25 sec of time resolution. (96 Ks/sec real-time
sampling rate in single-phase / three-phase mode). The available memory depth to hold this
information is 4K (4096 samples) for each waveform. This section covers the SCPI commands
that can be used to control the sampling rate and the position of the trigger point in the 4K deep
data buffer.
6.9.1 Retrieving Measurement Acquistion Data
Data can be retrieved by sending the “MEAS:ARR:VOLT?” or “MEAS:ARR:CURR?” queries. The
data returned will be in either binary or ASCII format depending on the state of the
“MEAS:ARR:MOD” command. The sample below assumes the binary data mode is used and
only 1K samples are requested from the measurement data buffer.
Public Sub QueryMeasBuffer(ByRef Buffer() As Single)
'=============================================================
'Sample uses fixed 1K block size (4 sections)
'=============================================================
Dim i,j As Integer
Dim iBlkSize As Integer
Dim iMaxPoints As Integer
Dim iPointer As Integer
Dim s1 As String
Dim gl_bAsciiTransfer as boolean
'=============================================================
'Initialize Size
gl_bAsciiTransfer = True
iBlkSize = 4
iMaxPoints = iBlkSize * 256
'Add block size of iBlkSize and offset of 0 parameters to measurement command
cmd = "FETCH:ARR:VOLT? " + Cstr(iBlkSize) + ",0"
'Allocate buffer space
s1 = Space(4 * (iBlkSize * 256) + 6) 'Allow 6 extra bytes for #46384
'Send query command using GPIB I/F Ctrlr 0
SendGPIB 0, cmd
ReceiveGPIB 0, AC_GPIB_Adr, s1, STOPend
'Process received data
If Len(s1) Then
'Start at first char after header #44096
If Left$(s1, 1) = "#" Then
iPointer = Val(Mid$(s1, 2, 1))
'Add 2 for #n and 1 to point to first actual data byte
iPointer = iPointer + 3
For i = 0 To iMaxPoints
s = ""
For j = 0 To iBlkSize - 1
s = s + Mid$(s1, iPointer + j, 1)
Next j
iPointer = iPointer + iBlkSize