ser = serial.Serial(port='/dev/ttyUSB1', baudrate=9600, parity=serial.
    PARITY_ODD, stopbits=serial.STOPBITS_TWO, bytesize=serial.SEVENBITS)
ser.open()
Interacting programmatically with serial terminal