Loading Common/Servers/PyDewarPositioner/test/README.rst +23 −3 Original line number Diff line number Diff line ******************* Containers to start ******************* - acsStartContainer -py AntennaBossSimContainer - acsStartContainer -py DerotatorContainer - acsStartContainer -py DerotatorPositionerContainer Modify SRT/CDB/MACI/Components/ANTENNA/Boss/Boss.xml in the following way:: <?xml version='1.0' encoding='ISO-8859-1'?> <Component xmlns="urn:schemas-cosylab-com:Component:1.0" xmlns:baci="urn:schemas-cosylab-com:BACI:1.0" xmlns:cdb="urn:schemas-cosylab-com:CDB:1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" Name="Boss" Code="AntennaBossSim.AntennaBossSimImpl" Type="IDL:alma/Antenna/AntennaBoss:1.0" Container="AntennaBossSimContainer" Default="true" KeepAliveTime="-1" ImplLang="py" /> Run ACS and the three containers:: $ acsStart $ acsStartContainer -py AntennaBossSimContainer $ acsStartContainer -py DerotatorContainer $ acsStartContainer -py DerotatorPositionerContainer ***************************** Content of the test directory Loading Common/Servers/PyDewarPositioner/test/functional/test_rewind.py +2 −1 Original line number Diff line number Diff line Loading @@ -83,6 +83,7 @@ class StartUpdatingTest(unittest.TestCase): # after prepare_negative_oor(), startUpdating() will cause oor self.positioner.startUpdating(MNG_TRACK, ANT_SOUTH, az, el, 0, 0) time.sleep(0.5) self.assertTrue(self.positioner.isRewindingRequired()) steps = 2 self.positioner.rewind(steps) self.assertTrue(self.positioner.isUpdating()) Loading Loading @@ -309,7 +310,7 @@ class StartUpdatingTest(unittest.TestCase): # -7.7330295207687838 az = math.radians(170) el = math.radians(45) parallactic = PosGenerator.getParallacticAngle(self.lat, az, el) # -0.77 parallactic = PosGenerator.getParallacticAngle(self.lat, az, el) # -7.7 min_limit = self.device.getMinLimit() # -85.77 degrees for the K Band self.antenna.setOffsets(az, el, ANT_HORIZONTAL) target = Pis + parallactic Loading Common/Simulators/Components/PyAntennaBossSim/src/AntennaBossSim/AntennaBossSimImpl.py +2 −3 Original line number Diff line number Diff line Loading @@ -62,8 +62,8 @@ class AntennaBossSimImpl(AntennaBoss, CI, Subsystem, CC, Services, Lcycle): def getApparentCoordinates(self, t): """Return (az, el, ra, dec) + (jepoch, lon, lat)""" coordinates = self.history.get(t) + (0, 0, 0) return tuple(coordinates) coordinates = tuple(self.history.get(t)) + (0, 0, 0) return coordinates def getRawCoordinates(self, t): """Return (az, el)""" Loading Loading @@ -100,7 +100,6 @@ class History(object): self.history.append(data) self.history.sort(key=operator.itemgetter(0)) self.history = self.history[-2**15:] # Last 2**15 positions # print 'position inserted in the history: ', position def clean(self, since=0): target_time = since if since else getTimeStamp().value Loading Loading
Common/Servers/PyDewarPositioner/test/README.rst +23 −3 Original line number Diff line number Diff line ******************* Containers to start ******************* - acsStartContainer -py AntennaBossSimContainer - acsStartContainer -py DerotatorContainer - acsStartContainer -py DerotatorPositionerContainer Modify SRT/CDB/MACI/Components/ANTENNA/Boss/Boss.xml in the following way:: <?xml version='1.0' encoding='ISO-8859-1'?> <Component xmlns="urn:schemas-cosylab-com:Component:1.0" xmlns:baci="urn:schemas-cosylab-com:BACI:1.0" xmlns:cdb="urn:schemas-cosylab-com:CDB:1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" Name="Boss" Code="AntennaBossSim.AntennaBossSimImpl" Type="IDL:alma/Antenna/AntennaBoss:1.0" Container="AntennaBossSimContainer" Default="true" KeepAliveTime="-1" ImplLang="py" /> Run ACS and the three containers:: $ acsStart $ acsStartContainer -py AntennaBossSimContainer $ acsStartContainer -py DerotatorContainer $ acsStartContainer -py DerotatorPositionerContainer ***************************** Content of the test directory Loading
Common/Servers/PyDewarPositioner/test/functional/test_rewind.py +2 −1 Original line number Diff line number Diff line Loading @@ -83,6 +83,7 @@ class StartUpdatingTest(unittest.TestCase): # after prepare_negative_oor(), startUpdating() will cause oor self.positioner.startUpdating(MNG_TRACK, ANT_SOUTH, az, el, 0, 0) time.sleep(0.5) self.assertTrue(self.positioner.isRewindingRequired()) steps = 2 self.positioner.rewind(steps) self.assertTrue(self.positioner.isUpdating()) Loading Loading @@ -309,7 +310,7 @@ class StartUpdatingTest(unittest.TestCase): # -7.7330295207687838 az = math.radians(170) el = math.radians(45) parallactic = PosGenerator.getParallacticAngle(self.lat, az, el) # -0.77 parallactic = PosGenerator.getParallacticAngle(self.lat, az, el) # -7.7 min_limit = self.device.getMinLimit() # -85.77 degrees for the K Band self.antenna.setOffsets(az, el, ANT_HORIZONTAL) target = Pis + parallactic Loading
Common/Simulators/Components/PyAntennaBossSim/src/AntennaBossSim/AntennaBossSimImpl.py +2 −3 Original line number Diff line number Diff line Loading @@ -62,8 +62,8 @@ class AntennaBossSimImpl(AntennaBoss, CI, Subsystem, CC, Services, Lcycle): def getApparentCoordinates(self, t): """Return (az, el, ra, dec) + (jepoch, lon, lat)""" coordinates = self.history.get(t) + (0, 0, 0) return tuple(coordinates) coordinates = tuple(self.history.get(t)) + (0, 0, 0) return coordinates def getRawCoordinates(self, t): """Return (az, el)""" Loading Loading @@ -100,7 +100,6 @@ class History(object): self.history.append(data) self.history.sort(key=operator.itemgetter(0)) self.history = self.history[-2**15:] # Last 2**15 positions # print 'position inserted in the history: ', position def clean(self, since=0): target_time = since if since else getTimeStamp().value Loading