'Close port'

def close(self):

    if self.is_open:
        if self.sPort:
            self._instream.close()
            self._outstream.close()
            self.sPort.close()
            self.sPort = None
        self.is_open = False
