![background image](http://html1.mh-extra.com/html/keithley/3700-series/3700-series_reference-manual_3931523147.webp)
Series 3700 System Switch/Multimeter Reference Manual
Section 9
:
Instrument Control Library (ICL)
Document Number: 3700S-901-01 Rev. A / August 2007
9-3
digio.writeport(15)
....................... ' Sets digital I/O lines 1, 2, 3 and 4 high.
digio.writebit(3, 0)
.................................................... ' Sets line 3 low (0).
dmm.reset('all')
............................. ' Returns the DMM to its default settings.
digio.readport()
.................................................. ' Reads the digital I/O port.
The results of a function call are used by assigning the return values to variables and accessing
those variables. The following code will measure voltage and return the reading:
dmm.func = "dcvolts"
reading = dmm.measure()
print(reading)
Output: 2.00
The above output indicates that the voltage reading is 2.36V.
Attributes
An attribute is a characteristic of an instrument feature or operation. For example, some
characteristics of a DMM include the measurement function and range.
Assigning a value to an attribute
An attribute-based command can be used to assign a new value to an attribute. For many
attributes, the value can be in the form of a discrete number or a predefined identifier. For
example, dmm.autorange is an attribute. The autorange attribute is enabled by assigning the
attribute to either of the following values:
1
or
dmm.ON
Either of the following command messages will configure the DMM for the moving average filter:
dmm.filter.type = 0
dmm.filter.type = dmm.FILTER_MOVING_AVG
Reading an attribute
Reading an attribute is accomplished by passing it to a function call as a parameter or by
assigning it to another variable.
Parameter passing example:
The following command reads the filter type for the DMM by passing the attribute to the print
function, which outputs a value:
print(dmm.filter.type)
Output: 0.00
The above output indicates that the moving average filter is selected.