This commit is contained in:
@@ -20,15 +20,23 @@ class Motor(epics.Motor):
|
||||
raise MotorException("must supply motor name")
|
||||
|
||||
if name.endswith('.VAL'):
|
||||
print("Before :", name, "\n")
|
||||
name = name[:-4]
|
||||
print("After :", name, "\n")
|
||||
if name.endswith('.'):
|
||||
print("Before :", name, "\n")
|
||||
name = name[:-1]
|
||||
print("After :", name, "\n")
|
||||
|
||||
|
||||
self._prefix = name
|
||||
print("LATER:", getattr(self, '_prefix'), "\n")
|
||||
print("Prefix :", name, "\n")
|
||||
Device.__init__(self, name, delim='.',
|
||||
attrs=self._init_list,
|
||||
timeout=timeout)
|
||||
|
||||
print("LATER:", getattr(self, '_prefix'), "\n")
|
||||
print("After device :", name, "\n")
|
||||
# speed up: do not get any data from PVs during construction
|
||||
# # make sure this is really a motor!
|
||||
# rectype = self.get('RTYP')
|
||||
@@ -38,8 +46,10 @@ class Motor(epics.Motor):
|
||||
for key, val in self._extras.items():
|
||||
pvname = "%s%s" % (name, val)
|
||||
self.add_pv(pvname, attr=key)
|
||||
|
||||
print("After add_pv:", name, "\n")
|
||||
self._callbacks = {}
|
||||
print("LATER:", getattr(self, '_prefix'), "\n")
|
||||
print("End :", name, "\n")
|
||||
|
||||
|
||||
# speed up: used by Motor.get_pv() with connect=True, i.e., waiting for connection
|
||||
|
||||
Reference in New Issue
Block a user