# HG changeset patch # User lbessard # Date 1184087994 -7200 # Node ID ad3fa27521063c44cf71d8d218c2d6e3522a37e5 # Parent 0dd4a876392feff4ac407c9985f2b16366d157bf Bugs on ST generation fixed diff -r 0dd4a876392f -r ad3fa2752106 PLCControler.py --- a/PLCControler.py Tue Jul 10 19:09:28 2007 +0200 +++ b/PLCControler.py Tue Jul 10 19:19:54 2007 +0200 @@ -552,12 +552,14 @@ # Extract varlists from a list of vars def ExtractVarLists(self, vars): + print "extract varlist" varlist_list = [] current_varlist = None current_type = None for var in vars: - if current_type != (var["Class"], var["Retain"], var["Constant"], var["Location"] != ""): - current_type = (var["Class"], var["Retain"], var["Constant"], var["Location"] != "") + print var["Class"], var["Retain"], var["Constant"], var["Location"] + if current_type != (var["Class"], var["Retain"], var["Constant"], var["Location"] in ["", None]): + current_type = (var["Class"], var["Retain"], var["Constant"], var["Location"] in ["", None]) current_varlist = plcopen.varList() varlist_list.append((var["Class"], current_varlist)) if var["Retain"] == "Yes":