runtime/PLCObject.py
branchfix_PLC_runtime_shutdown
changeset 2602 19dc6b830e7d
parent 2600 0e20a0d48fae
child 2608 a332f989f0b8
--- a/runtime/PLCObject.py	Thu Apr 18 14:29:55 2019 +0200
+++ b/runtime/PLCObject.py	Thu Apr 18 14:32:43 2019 +0200
@@ -477,8 +477,14 @@
             return True
         return False
 
-    @RunInMain
     def GetPLCstatus(self):
+        try:
+            return self._GetPLCstatus()
+        except EOFError:
+            return (PlcStatus.Disconnected, None)
+
+    @RunInMain
+    def _GetPLCstatus(self):
         return self.PLCStatus, map(self.GetLogCount, xrange(LogLevelsCount))
 
     @RunInMain