def disable_channel(self, channel): result = usbtc08.usb_tc08_set_channel(self.handle, channel, ord(' ')) if result == 0: raise usbtc08_error(usbtc08.usb_tc08_get_last_error(self.handle), 'Disabling channel.') else: if DEBUG: print 'Disabled channel %i.' % (channel)
def set_channel(self, channel, tc): result = usbtc08.usb_tc08_set_channel(self.handle, channel, ord(tc)) if result == 0: raise usbtc08_error(usbtc08.usb_tc08_get_last_error(self.handle), 'Setting channel.') else: if DEBUG: print 'Set channel %i to %s-type thermocouple.' % (channel, tc)
def disable_channel(self, channel): result = usbtc08.usb_tc08_set_channel(self.handle, channel, ord(' ')) if result == 0: raise usbtc08_error(usbtc08.usb_tc08_get_last_error(self.handle), 'Disabling channel.') else: if self.debugMode: cprint('\tDisabled channel %i.' % (channel), 'yellow')
def set_channel(self, channel, tc): result = usbtc08.usb_tc08_set_channel(self.handle, channel, ord(tc)) if result == 0: raise usbtc08_error(usbtc08.usb_tc08_get_last_error(self.handle), 'Setting channel.') else: if self.debugMode: cprint( '\tSet channel %i to %s-type thermocouple.' % (channel, tc), 'green')