From df890ca81437dbbb2942210f17d49dcb45405c35 Mon Sep 17 00:00:00 2001 From: Daniel Brown Date: Sat, 2 Mar 2019 01:33:58 -0800 Subject: [PATCH] Removing offset param for locks, setting this to just a normal variable. Loose end from when trying to have offsets tunable with xaxis and such --- pykat/commands.py | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/pykat/commands.py b/pykat/commands.py index 86b7e7a..a344750 100644 --- a/pykat/commands.py +++ b/pykat/commands.py @@ -38,7 +38,6 @@ class Command(object): self.__removed = False self.__name = name.strip("*") self._putters = [] - def __deepcopy__(self, memo): """ @@ -53,7 +52,7 @@ class Command(object): for _ in result._putters: _._updateOwner(result) - + result._freeze() return result @@ -203,11 +202,10 @@ class lock(Command): def __init__(self, name, variable, gain, accuracy, offset=None, singleLock=False): Command.__init__(self, name, False) - self.__params = [] self.__variable = variable self.__gain = gain self.__accuracy = accuracy - self.__offset = Param("offset", self, SIfloat(offset)) + self.__offset = offset self.singleLock = singleLock self.enabled = True @@ -217,9 +215,6 @@ class lock(Command): self._putters.append(self.output) self._freeze() - - def _register_param(self, param): - self.__params.append(param) @property def offset(self): return self.__offset @@ -245,7 +240,7 @@ class lock(Command): gain=str(self.gain), accuracy=str(self.accuracy)) - if self.offset.value is not None: + if self.offset is not None: cmds += " %s" % str(self.offset) if self.singleLock: @@ -255,9 +250,6 @@ class lock(Command): rtn.extend(self.output._getPutFinesseText()) - for p in self.__params: - rtn.extend(p.getFinesseText()) - return rtn else: return None -- GitLab