Home | History | Annotate | Download | only in i2c

Lines Matching refs:serial

13 import serial
104 '''Connects to NXP via serial port.
106 @param device_path: The device path of serial port.
109 self.logger.info('Setup serial device... [%s]', device_path)
111 self.serial = serial.Serial(port=self.device_path,
113 bytesize=serial.EIGHTBITS,
114 parity=serial.PARITY_NONE,
115 stopbits=serial.STOPBITS_ONE,
120 serial.VERSION, self.serial.__repr__())
122 self.serial.flush()
125 '''Converts data to bytearray and writes to the serial port.'''
126 self.serial.write(bytearray(data))
127 self.serial.flush()
130 '''Reads data from serial port(Non-Blocking).'''
131 ret = self.serial.read(self.serial.inWaiting())