Loading SRT/Servers/SRTMinorServo/src/SRTMinorServoTest/mscu/mscu.py +3 −7 Original line number Diff line number Diff line Loading @@ -9,7 +9,7 @@ import sys import commands import posutils from parameters import headers, closers, commands, app_nr, filtered from parameters import headers, closers, app_nr, filtered class MSCU(object): Loading Loading @@ -94,7 +94,7 @@ class MSCU(object): continue # Print a general error message if we received an invalid command if header not in headers or cmd not in commands: if header not in headers or not hasattr(commands, cmd): cause = "Unexpected command or header.\n" print cause # Send a general error message Loading Loading @@ -162,10 +162,6 @@ class MSCU(object): if __name__ == "__main__": mscu = MSCU() try: mscu.run() finally: db = posutils.PositionDB() db.clear() SRT/Servers/SRTMinorServo/src/SRTMinorServoTest/mscu/parameters.py +1 −14 Original line number Diff line number Diff line Loading @@ -4,22 +4,9 @@ # Message portions headers = ('#', '!', '?', '@') closers = ('\r\n', '\n\r', '\r', '\n') closers = ('\r\n', '\n\r') socket_timeout = 3.0 # Available commands commands = ( 'stow', 'setup', 'getstatus', 'setpos', 'getpos', 'getspar', 'getappstatus', 'getstatus', 'clean', ) # Available properties properties = ( 'actPos', Loading Loading
SRT/Servers/SRTMinorServo/src/SRTMinorServoTest/mscu/mscu.py +3 −7 Original line number Diff line number Diff line Loading @@ -9,7 +9,7 @@ import sys import commands import posutils from parameters import headers, closers, commands, app_nr, filtered from parameters import headers, closers, app_nr, filtered class MSCU(object): Loading Loading @@ -94,7 +94,7 @@ class MSCU(object): continue # Print a general error message if we received an invalid command if header not in headers or cmd not in commands: if header not in headers or not hasattr(commands, cmd): cause = "Unexpected command or header.\n" print cause # Send a general error message Loading Loading @@ -162,10 +162,6 @@ class MSCU(object): if __name__ == "__main__": mscu = MSCU() try: mscu.run() finally: db = posutils.PositionDB() db.clear()
SRT/Servers/SRTMinorServo/src/SRTMinorServoTest/mscu/parameters.py +1 −14 Original line number Diff line number Diff line Loading @@ -4,22 +4,9 @@ # Message portions headers = ('#', '!', '?', '@') closers = ('\r\n', '\n\r', '\r', '\n') closers = ('\r\n', '\n\r') socket_timeout = 3.0 # Available commands commands = ( 'stow', 'setup', 'getstatus', 'setpos', 'getpos', 'getspar', 'getappstatus', 'getstatus', 'clean', ) # Available properties properties = ( 'actPos', Loading