Tue, 31 Mar 2009 00:13:05 +0200
fixes in HP8904 device description
pygpibtoolkit/HP8904.py | file | annotate | diff | comparison | revisions |
--- a/pygpibtoolkit/HP8904.py Mon Mar 30 21:32:14 2009 +0200 +++ b/pygpibtoolkit/HP8904.py Tue Mar 31 00:13:05 2009 +0200 @@ -18,7 +18,9 @@ from pygpibtoolkit.pygpib import Constants, Command from pygpibtoolkit.pygpib import Mode, ModeCommand -from pygpibtoolkit.pygpib import VoltageValue +from pygpibtoolkit.pygpib import VoltageValue, FrequencyValue +from pygpibtoolkit.pygpib import FloatUnitValue + from pygpibtoolkit.pygpib import SimpleMode from pygpibtoolkit.gpibcontroller import AbstractGPIBDevice, deviceRegister @@ -53,8 +55,8 @@ def build_set_cmd(self, value): # XXX HERE: todo: make it work with value not in self._cmds # (eg. value=="AU", cmds == ['FS1AU') - assert value in self._cmds - return value, value + assert self._prefix+value in self._cmds + return self._prefix+value, value class Filter1(_PerOutputMode):