Skip to content

USB to Serial devices #82

@vascotenner

Description

@vascotenner

I am using several USB to serial devices. I want to recognize them before connecting (via pyvisa-py). To do that I use the following code:

def find_device_VISA(vid=None, pid=None, vendor=None, serial=None,
                    fmt='ASRL{}::INSTR'):
    '''Find a USB to serial converter and format VISA identifier'''
    tty = find_port.list_devices(vid=vid, pid=pid, vendor=vendor,
                                  serial=serial)[0][3]
    return fmt.format(tty)

Where find_port is in the package: https://github.com/vascotenner/usb-ser-mon/tree/package

Can Lantz provide a more familiar way? Should this be included in lantz? How?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions