Fix Version/s: None
Sprint:TSSW Sprint - Aug 01 - Aug 15
Team:Telescope and Site
Scott Sandwith requested new code to exercise our connection to their T2SA alignment system. They have old code provided by Colin, but will want something new if they are to make any changes to the API.
Please try out the code with the real T2SA and let me know if it works.
Looks mostly good to me, connected right away and prints responses ok.
Did an exit and tried to reconnect, but T2SA had crashed on exit command
Repeated the crash on exit so at least Scott can debug it now
measure M1M3 returned a
WARNING:root Took 17.96 seconds to read b'ACK-300 EMP
and never printed the measurement result
Regarding "but T2S had crashed on exit command": the exit command just makes this test code close the connection and quit. It does not send anything to the T2SA. So I wonder if the T2SA had just not realized that the connection was lost, and thus was not allowing a new connection? Trying to read a closed socket should immediately return a useful error, so the T2SA ought to be able to handle that quickly and reliably.
Version 3 and 4 (attached) fix an incompatibility with Windows. Version 4 exits more cleanly.
Code sent to Scott and Dave and attached to this ticket. (Code updated 2022-08-08 to remove an import of ts_tcpip).