def __init__(self, board): if board != 0: raise ValueError("only board 0 is supported") device0 = PMD.FindInterface(PMD.USB1208FS_PID) PMD.usbDConfigPort_USB1208FS(device0, PMD.DIO_PORTA, PMD.DIO_DIR_OUT) PMD.usbDConfigPort_USB1208FS(device0, PMD.DIO_PORTB, PMD.DIO_DIR_IN) self.devices = [device0]
def __init__(self, board): if board != 0: raise ValueError("only board 0 is supported") device0 = PMD.FindInterface(PMD.USB1208FS_PID) PMD.usbDConfigPort_USB1208FS(device0, PMD.DIO_PORTA, PMD.DIO_DIR_OUT) PMD.usbDConfigPort_USB1208FS(device0, PMD.DIO_PORTB, PMD.DIO_DIR_IN) self.devices = [device0]
def cbDConfigPort(board, port, direction): device = _get_device(board) return PMD.usbDConfigPort_USB1208FS(device, port, direction)
def cbDConfigPort(board, port, direction): device = _get_device(board) return PMD.usbDConfigPort_USB1208FS(device, port, direction)