bench.common module

class bench.common.Common(address: str | None = None, use_config_file=False)

Bases: object

auto_connect = True

Automatically connect to hardware when running methods

property auto_reconnect

Automatically reconnect if connection dropped

property config_file
config_locations = ['.', '/etc/']

Paths to search for config

connect()
disconnect()
query_error()

Queries for PXA error

Raises:

AttributeError – Error

use_config_file = False

Use config file to get address for instrument(s)

use_py_resource_manager = True

Use @py resource manager

bench.common.check_connected(func)
class bench.common.instrument(rm, address, auto_reconnect=True, use_py_resource_manager=True)

Bases: object

Shim layer between pyvisa instrument class and pybench instruments

close()
query(cmd)
query_ascii_values(cmd, converter=None)
read_raw()
property timeout
write(cmd)