equal
deleted
inserted
replaced
21 # License along with this library; if not, write to the Free Software |
21 # License along with this library; if not, write to the Free Software |
22 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
22 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
23 |
23 |
24 |
24 |
25 from __future__ import absolute_import |
25 from __future__ import absolute_import |
26 from threading import Thread, Lock, Semaphore, Event, Condition |
26 from threading import Thread, Lock, Semaphore, Event |
27 import ctypes |
27 import ctypes |
28 import os |
28 import os |
29 import sys |
29 import sys |
30 import traceback |
30 import traceback |
31 from time import time |
31 from time import time |
56 |
56 |
57 |
57 |
58 def PLCprint(message): |
58 def PLCprint(message): |
59 sys.stdout.write("PLCobject : "+message+"\n") |
59 sys.stdout.write("PLCobject : "+message+"\n") |
60 sys.stdout.flush() |
60 sys.stdout.flush() |
61 |
|
62 |
61 |
63 |
62 |
64 def RunInMain(func): |
63 def RunInMain(func): |
65 def func_wrapper(*args, **kwargs): |
64 def func_wrapper(*args, **kwargs): |
66 return MainWorker.call(func, *args, **kwargs) |
65 return MainWorker.call(func, *args, **kwargs) |