def __del__(self): if self.protocol == 'serial': SerialInstrument.__del__(self) if self.protocol == 'socket': self.write('END') SocketInstrument.__del__(self)
def __del__(self): return if self.protocol == 'serial': SerialInstrument.__del__(self) if self.protocol == 'VISA': VisaInstrument.__del__(self)