Browse Source

Added explanation of file

Yentl Van Tendeloo 9 years ago
parent
commit
77b9f14dbb
1 changed files with 13 additions and 1 deletions
  1. 13 1
      src/python_sccd/python_sccd_runtime/socket2event.py

+ 13 - 1
src/python_sccd/python_sccd_runtime/socket2event.py

@@ -1,5 +1,17 @@
-import threading
+"""
+Socket 2 Event wrapper
+
+Author: Yentl Van Tendeloo
+
+This maps socket communication to events, and vice versa, allowing for a
+Statechart to use (blocking) sockets. It sends events to the socket_in port,
+and listens for commands on the socket_out port.  As this runs on its own
+thread, you will need to start the code by running
+"boot_translation_service(controller)" before using the ports.
+"""
+
 from sccd.runtime.statecharts_core import Event
+import threading
 import socket
 
 send_data_queues = {}