tools/pyboard.py: Rename ProcessPtyToTerminal member "ser" to "serial".

So that this file doesn't need to be excluded from codespell.

Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
Damien George 2023-03-13 09:29:18 +11:00
parent e131b53fdf
commit e160fe7bc6

View File

@ -245,7 +245,7 @@ class ProcessPtyToTerminal:
pty = m.group()
# rtscts, dsrdtr params are to workaround pyserial bug:
# http://stackoverflow.com/questions/34831131/pyserial-does-not-play-well-with-virtual-port
self.ser = serial.Serial(pty, interCharTimeout=1, rtscts=True, dsrdtr=True)
self.serial = serial.Serial(pty, interCharTimeout=1, rtscts=True, dsrdtr=True)
def close(self):
import signal
@ -253,13 +253,13 @@ class ProcessPtyToTerminal:
os.killpg(os.getpgid(self.subp.pid), signal.SIGTERM)
def read(self, size=1):
return self.ser.read(size)
return self.serial.read(size)
def write(self, data):
return self.ser.write(data)
return self.serial.write(data)
def inWaiting(self):
return self.ser.inWaiting()
return self.serial.inWaiting()
class Pyboard: