Section 8: TSP command reference
Model 2461 Interactive SourceMeter® Instrument Reference Manual
8-28
2461-901-01 A/November 2015
bufferVar.relativetimestamps
This attribute contains the timestamps, in seconds, when each reading occurred, relative to the timestamp of the
first entry in the reading buffer.
Type
TSP-Link accessible
Affected by
Where saved
Default value
Attribute (R)
Yes
Restore configuration
Instrument reset
Power cycle
Not applicable
Not applicable
Usage
timestamp
=
bufferVar
.relativetimestamps[
N
]
timestamp
The timestamp, in seconds
bufferVar
The name of the reading buffer, which may be a default buffer (
defbuffer1
or
defbuffer2
) or a user-defined buffer
N
The reading number
N
; can be any value from 1 to the number of readings in
the buffer; use the
bufferVar.
n
command to determine the number of
readings in the buffer
Details
This read-only attribute is an array (a Lua table) of timestamps, in seconds, of when each reading
occurred relative to the timestamp of the first entry in the reading buffer. These timestamps are equal
to the time that has lapsed for each reading since the first reading was stored in the buffer. Therefore,
the relative timestamp for the first entry number in the reading buffer equals 0.
Example
reset()
testData = buffer.make(50)
trigger.model.load("SimpleLoop", 3, 0, testData)
trigger.model.initiate()
waitcomplete()
print(testData.relativetimestamps[1])
printbuffer(1, 3, testData.relativetimestamps)
Create a reading buffer named
testData
, configure the instrument to
make three measurements, and store
the readings in the buffer.
Print the relative timestamp for the first
reading in the buffer.
Example output:
0
Print the relative timestamp for the
reading 1 through 3 in the buffer.
Example output:
0, 0.383541, 0.772005
Also see
(on page 8-11)
(on page 8-14)
(on page 8-19)
(on page 8-92)
(on page 8-93)
(on page 3-2)
(on page 3-23)