editors/SFCViewer.py
changeset 1742 92932cd370a4
parent 1740 b789b695b5c6
child 1743 c3c3d1318130
equal deleted inserted replaced
1741:dd94b9a68c61 1742:92932cd370a4
   340             blockName = block.Type
   340             blockName = block.Type
   341         return blockName
   341         return blockName
   342 
   342 
   343     # This method check the IEC 61131-3 compatibility between two SFC blocks
   343     # This method check the IEC 61131-3 compatibility between two SFC blocks
   344     def BlockCompatibility(self, startblock = None, endblock = None, direction = None):
   344     def BlockCompatibility(self, startblock = None, endblock = None, direction = None):
   345         if startblock!= None and endblock != None and (isinstance(startblock, SFC_Objects)\
   345         if startblock != None and endblock != None and (isinstance(startblock, SFC_Objects)\
   346                                                                or isinstance(endblock, SFC_Objects)):
   346                                                                or isinstance(endblock, SFC_Objects)):
   347             # Full "SFC_StandardRules" table would be symmetrical and
   347             # Full "SFC_StandardRules" table would be symmetrical and
   348             # to avoid duplicate records and minimize the table only upper part is defined.
   348             # to avoid duplicate records and minimize the table only upper part is defined.
   349             if (direction == SOUTH or direction == EAST):
   349             if (direction == SOUTH or direction == EAST):
   350                 startblock, endblock = endblock, startblock
   350                 startblock, endblock = endblock, startblock