How to use the pyvisa.attributes.RangeAttribute function in PyVISA

To help you get started, we’ve selected a few PyVISA examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github pyvisa / pyvisa / pyvisa / attributes.py View on Github external
(constants.InterfaceType.vxi, 'INSTR'),
                 (constants.InterfaceType.vxi, 'SERVANT')]

    py_name = 'send_end'

    visa_name = 'VI_ATTR_SEND_END_EN'

    visa_type = 'ViBoolean'

    default = True

    read, write, local = True, True, True


# noinspection PyPep8Naming
class AttrVI_ATTR_SLOT(RangeAttribute):
    """VI_ATTR_SLOT specifies the physical slot location of the device. If
    the slot number is not known, VI_UNKNOWN_SLOT is returned.
    """
    resources = [(constants.InterfaceType.pxi, 'INSTR'),
                 (constants.InterfaceType.vxi, 'INSTR')]

    py_name = ''

    visa_name = 'VI_ATTR_SLOT'

    visa_type = 'ViInt16'

    default = NotAvailable

    read, write, local = True, False, False
github pyvisa / pyvisa / pyvisa / attributes.py View on Github external
py_name = ''

    visa_name = 'VI_ATTR_INTF_INST_NAME'

    visa_type = 'ViString'

    default = NotAvailable

    read, write, local = True, False, False

    # [u'N/A']


# noinspection PyPep8Naming
class AttrVI_ATTR_INTF_NUM(RangeAttribute):
    """VI_ATTR_INTF_NUM specifies the board number for the given interface.
    """
    resources = AllSessionTypes

    py_name = 'interface_number'

    visa_name = 'VI_ATTR_INTF_NUM'

    visa_type = 'ViUInt16'

    default = 0

    read, write, local = True, False, False

    min_value, max_value, values = 0x0, 0xFFFF, []
github pyvisa / pyvisa / pyvisa / attributes.py View on Github external
py_name = 'manufacturer_name'

    visa_name = 'VI_ATTR_MANF_NAME'

    visa_type = 'ViString'

    default = NotAvailable

    read, write, local = True, False, False

    # [u'N/A']


# noinspection PyPep8Naming
class AttrVI_ATTR_MAX_QUEUE_LENGTH(RangeAttribute):
    """VI_ATTR_MAX_QUEUE_LENGTH specifies the maximum number of events that
    can be queued at any time on the given session. Events that occur
    after the queue has become full will be discarded.
    """
    resources = AllSessionTypes

    py_name = ''

    visa_name = 'VI_ATTR_MAX_QUEUE_LENGTH'

    visa_type = 'ViUInt32'

    default = 50

    read, write, local = True, True, True
github pyvisa / pyvisa / pyvisa / attributes.py View on Github external
py_name = ''

    visa_name = 'VI_ATTR_USB_NUM_PIPES'

    visa_type = 'ViInt16'

    default = NotAvailable

    read, write, local = True, False, False

    min_value, max_value, values = 0, 30, []


# noinspection PyPep8Naming
class AttrVI_ATTR_USB_PROTOCOL(RangeAttribute):
    """VI_ATTR_USB_PROTOCOL specifies the USB protocol used by this USB
    interface.
    """
    resources = [(constants.InterfaceType.usb, 'INSTR'),
                 (constants.InterfaceType.usb, 'RAW')]

    py_name = 'usb_protocol'

    visa_name = 'VI_ATTR_USB_PROTOCOL'

    visa_type = 'ViInt16'

    default = NotAvailable

    read, write, local = True, False, False
github pyvisa / pyvisa / pyvisa / attributes.py View on Github external
py_name = 'io_protocol'

    visa_name = 'VI_ATTR_IO_PROT'

    visa_type = 'ViUInt16'

    default = constants.VI_PROT_NORMAL

    read, write, local = True, True, True

    min_value, max_value, values = 0, 65535, []


# noinspection PyPep8Naming
class AttrVI_ATTR_MAINFRAME_LA(RangeAttribute):
    """VI_ATTR_MA.infRAME_LA specifies the lowest logical address in the
    mainframe. If the logical address is not known, VI_UNKNOWN_LA is
    returned.
    """
    resources = [(constants.InterfaceType.vxi, 'INSTR'),
                 (constants.InterfaceType.vxi, 'BACKPLANE')]

    py_name = ''

    visa_name = 'VI_ATTR_MAINFRAME_LA'

    visa_type = 'ViInt16'

    default = NotAvailable

    read, write, local = True, False, False
github pyvisa / pyvisa / pyvisa / attributes.py View on Github external
py_name = ''

    visa_name = 'VI_ATTR_USB_CLASS'

    visa_type = 'ViInt16'

    default = NotAvailable

    read, write, local = True, False, False

    min_value, max_value, values = 0, 0xFF, []


# noinspection PyPep8Naming
class AttrVI_ATTR_USB_CTRL_PIPE(RangeAttribute):
    """VI_ATTR_USB_CTRL_PIPE specifies the endpoint address of the USB
    control pipe used by the given session. A value of 0 signifies
    that the default control pipe will be used. This endpoint is used
    in viUsbControlIn and viUsbControlOut operations. Nonzero values
    may not be supported on all platforms.
    """
    resources = [(constants.InterfaceType.usb, 'RAW')]

    py_name = ''

    visa_name = 'VI_ATTR_USB_CTRL_PIPE'

    visa_type = 'ViInt16'

    default = 0x00
github pyvisa / pyvisa / pyvisa / attributes.py View on Github external
py_name = ''

    visa_name = 'VI_ATTR_USB_BULK_IN_PIPE'

    visa_type = 'ViInt16'

    default = NotAvailable

    read, write, local = True, True, True

    min_value, max_value, values = 0x81, 0x8F, [-1]


# noinspection PyPep8Naming
class AttrVI_ATTR_USB_BULK_IN_STATUS(RangeAttribute):
    """VI_ATTR_USB_BULK_IN_STATUS specifies whether the USB bulk-in pipe used
    by the given session is stalled or ready. This attribute can be
    set to only VI_USB_PIPE_READY.
    """
    resources = [(constants.InterfaceType.usb, 'RAW')]

    py_name = ''

    visa_name = 'VI_ATTR_USB_BULK_IN_STATUS'

    visa_type = 'ViInt16'

    default = NotAvailable

    read, write, local = True, True, True
github pyvisa / pyvisa / pyvisa / attributes.py View on Github external
py_name = 'stop_bits'

    visa_name = 'VI_ATTR_ASRL_STOP_BITS'

    visa_type = 'ViUInt16'

    default = constants.StopBits.one

    read, write, local = True, True, False

    enum_type = constants.StopBits


# noinspection PyPep8Naming
class AttrVI_ATTR_ASRL_WIRE_MODE(RangeAttribute):
    """

    """
    resources = [(constants.InterfaceType.asrl, 'INSTR')]

    py_name = ''

    visa_name = 'VI_ATTR_ASRL_WIRE_MODE'

    visa_type = 'ViInt16'

    default = NotAvailable

    read, write, local = True, True, False

    min_value, max_value, values = -32768, 32767, []
github pyvisa / pyvisa / pyvisa / attributes.py View on Github external
py_name = ''

    visa_name = 'VI_ATTR_PXI_DEV_NUM'

    visa_type = 'ViUInt16'

    default = NotAvailable

    read, write, local = True, False, False

    min_value, max_value, values = 0, 31, []


# noinspection PyPep8Naming
class AttrVI_ATTR_PXI_DSTAR_BUS(RangeAttribute):
    """VI_ATTR_PXI_DSTAR_BUS specifies the differential star bus number of
    this device. A value of –1 means the chassis is unidentified or
    does not have a timing slot.
    """
    resources = [(constants.InterfaceType.pxi, 'INSTR')]

    py_name = ''

    visa_name = 'VI_ATTR_PXI_DSTAR_BUS'

    visa_type = 'ViInt16'

    default = NotAvailable

    read, write, local = True, False, False
github pyvisa / pyvisa / pyvisa / attributes.py View on Github external
py_name = ''

    visa_name = 'VI_ATTR_WIN_ACCESS'

    visa_type = 'ViUInt16'

    default = constants.VI_NMAPPED

    read, write, local = True, False, True

    min_value, max_value, values = 0, 65535, []


# noinspection PyPep8Naming
class AttrVI_ATTR_WIN_ACCESS_PRIV(RangeAttribute):
    """VI_ATTR_WIN_ACCESS_PRIV specifies the address modifier to be used in
    low-level access operations, such as viMapAddress(), viPeekXX(),
    and viPokeXX(), when accessing the mapped window.
    """
    resources = [(constants.InterfaceType.vxi, 'INSTR'),
                 (constants.InterfaceType.vxi, 'MEMACC')]

    py_name = ''

    visa_name = 'VI_ATTR_WIN_ACCESS_PRIV'

    visa_type = 'ViUInt16'

    default = constants.VI_DATA_PRIV

    read, write, local = True, True, True