Section 6: Reading buffers
Example:
The following programming example illustrates how to output mean and standard deviation statistics
from buffer 1:
statistics = smua.buffer.getstats(smua.nvbuffer1)
print(statistics.mean, statistics.stddev)
Reading buffer attributes
Use the reading buffer attributes to access the reading buffer data. The table below displays the
attributes that you can use to access the reading buffer data.
Recall attribute*
measurefunctions
measureranges
readings
sourcefunctions
sourceoutputstates
sourceranges
sourcevalues
statuses
timestamps
* The default attribute is readings, which can be omitted.
Examples:
The following programming example illustrates how to output 100 channel A readings from buffer 1:
printbuffer(1, 100, smua.nvbuffer1.readings)
Similarly, the following outputs 100 channel A corresponding source values from buffer 1:
printbuffer(1, 100, smua.nvbuffer1.sourcevalues)
The default reading attribute is readings, which can be omitted. If readings is omitted, the
following also outputs 100 channel A readings from buffer 1:
printbuffer(1, 100, smua.nvbuffer1)
6-12
Model 2606B System SourceMeter® Instrument Reference Manual
Description
An array (a Lua table) of strings indicating the function measured for
the reading (current, voltage, ohms, or watts).
An array (a Lua table) of full-scale range values for the measure range
used when the measurement was made.
An array (a Lua table) of the readings stored in the reading buffer. This
array holds the same data that is returned when the reading buffer is
accessed directly; that is, rb[2] and rb.readings[2] access the
same value.
An array (a Lua table) of strings indicating the source function at the
time of the measurement (current or voltage).
An array (a Lua table) of strings indicating the state of the source (off
or on).
An array (a Lua table) of full-scale range values for the source range
used when the measurement was made.
If enabled, an array (a Lua table) of the sourced values in effect at the
time of the reading.
An array (a Lua table) of status values for all the readings in the buffer.
The status values are floating-point numbers that encode the status
value into a floating-point value. See
If enabled, an array (a Lua table) of timestamps, in seconds, of when
each reading occurred. These are relative to the basetimestamp for
the buffer. See
Reading buffer commands
Buffer status
(on page 6-13).
(on page 6-7).
2606B-901-01 Rev. C November 2021
Need help?
Do you have a question about the KEITHLEY SourceMeter 2606B and is the answer not in the manual?