Adding error message when SFC Transition body is not well formatted (no reference to transition name)
--- a/PLCGenerator.py Wed Feb 15 00:26:30 2012 +0100
+++ b/PLCGenerator.py Wed Feb 15 00:27:31 2012 +0100
@@ -1186,6 +1186,8 @@
transition_infos["content"] = [("\n%s:= "%self.CurrentIndent, ())] + expression + [(";\n", ())]
self.SFCComputedBlocks += self.Program
self.Program = []
+ if not transition_infos.has_key("content"):
+ raise PLCGenException, _("Transition \"%s\" body must contain an output variable or coil referring to its name") % transitionValues["value"]
self.TagName = previous_tagname
elif transitionValues["type"] == "connection":
body = pou.getbody()