Download PyVISA Documentation
Transcript
PyVISA Documentation, Release 1.9.dev0 query_values(message, delay=None) Query the device for values returning an iterable of values. The datatype expected is obtained from values_format Parameters • message (str) – the message to send. • delay – delay in seconds between write and read operations. if None, defaults to self.query_delay Returns the answer from the device. Return type list read(termination=None, encoding=None) Read a string from the device. Reading stops when the device stops sending (e.g. by setting appropriate bus lines), or the termination characters sequence was detected. Attention: Only the last character of the termination characters is really used to stop reading, however, the whole sequence is compared to the ending of the read string message. If they don’t match, a warning is issued. All line-ending characters are stripped from the end of the string. Return type str read_raw(size=None) Read the unmodified string sent from the instrument to the computer. In contrast to read(), no termination characters are stripped. Return type bytes read_stb() Service request status register. read_termination Read termination character. read_termination_context(*args, **kwds) read_values(fmt=None, container=<type ‘list’>) Read a list of floating point values from the device. Parameters • fmt – the format of the values. If given, it overrides the class attribute “values_format”. Possible values are bitwise disjunctions of the above constants ascii, single, double, and big_endian. Default is ascii. • container – the output datatype Returns the list of read values Return type list register(interface_type, resource_class) resource_class VI_ATTR_RSRC_CLASS specifies the resource class (for example, “INSTR”) as defined by the canonical resource name. VISA Attribute VI_ATTR_RSRC_CLASS (3221159937) 3.6. API 65