beautypg.com

Digital interface, Overview – Teledyne LeCroy WaveExpert series Automation Manual User Manual

Page 47

background image

C

HAPTER

T

WO

Overview

Const COLOFFSET = 7
Dim numColumns As Long
Dim numRows As Long
Dim startColumn As Long
Dim startRow As Long
Dim wform

numColumns = Cells(9, 5)
numRows = Cells(10, 5)
startColumn = Cells(11, 5)
startRow = Cells(12, 5)
wform = app.SDA.Eye.Out.Result.DataArray(numColumns, numRows, startColumn,
startRow)
For i = 0 To numRows - 1
For j = 0 To numColumns - 1
Cells(i + ROWOFFSET, j + COLOFFSET) = wform(i, j)
Next j
Next i

Digital Interface:

Description:

Retrieves a 2D array containing the state of each sample on each line. The value 1 is returned if he

sample was above the threshhold, 0 if below.

Arguments (optional):

numSamples as Long

Default value: -1, retrieve all data
Number of samples to retreived

numLines as Long

Default value: -1, retrieve all lines.
Number of digital lines to retrieve.


startIndex as Long

Default value: 0, first index
Index of the first sample to retrieve. (0-based)

startLine as Long

Default value: 0, first digital line
Index of the first digital line to retrieve (0-based). The user selects which lines to enable; only

data from enabled lines are included in the DataArray


Example:

‘Reads values to use for DataArray arguments from a spreadsheet, and then
loops through
‘the retrieved array, saving the data to the spreadsheet.

Const ROWOFFSET = 10
Const COLOFFSET = 7
Dim nSamples As Long
Dim nLines As Long
Dim startIndex As Long
Dim startLine As Long
Dim wform

916435 RevA

2-11